public class ExitCircuitImpl extends CircuitImpl implements ExitCircuit
logger, prechosenPathDASHBOARD_CIRCUITS, DASHBOARD_CONNECTIONS, DASHBOARD_CONNECTIONS_VERBOSE, DASHBOARD_PREDICTED_PORTS, DASHBOARD_STREAMS| Modifier and Type | Method and Description |
|---|---|
boolean |
canHandleExitTo(ExitTarget target)
Return true if the final node of this circuit is believed to be able to connect to
the specified
ExitTarget. |
boolean |
canHandleExitToPort(int port) |
protected List<Router> |
choosePathForCircuit(CircuitPathChooser pathChooser) |
protected String |
getCircuitTypeLabel() |
Stream |
openExitStream(IPv4Address address,
int port,
long timeout)
Open an exit stream from the final node in this circuit to the
specified target address and port.
|
Stream |
openExitStream(String target,
int port,
long timeout)
Open an exit stream from the final node in this circuit to the
specified target hostname and port.
|
void |
recordFailedExitTarget(ExitTarget target)
Records the specified
ExitTarget as a failed connection so that ExitCircuit.canHandleExitTo(ExitTarget) will
no longer return true for this exit destination. |
appendNode, createNewStream, createNewStream, createRelayCell, dashboardRender, deliverControlCell, deliverRelayCell, destroyCircuit, getActiveStreams, getCircuitId, getConnection, getFinalCircuitNode, getSecondsDirty, isClean, isConnected, isMarkedForClose, isPending, markForClose, pathToString, processStreamOpenException, receiveRelayCell, removeStream, sendRelayCell, sendRelayCellToFinalNode, toStringclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitappendNode, createRelayCell, deliverControlCell, deliverRelayCell, destroyCircuit, getActiveStreams, getCircuitId, getConnection, getFinalCircuitNode, getSecondsDirty, isClean, isConnected, isMarkedForClose, isPending, markForClose, receiveRelayCell, sendRelayCellpublic Stream openExitStream(IPv4Address address, int port, long timeout) throws InterruptedException, TimeoutException, StreamConnectFailedException
ExitCircuitopenExitStream in interface ExitCircuitaddress - The network address of the exit target.port - The port of the exit target.InterruptedExceptionTimeoutExceptionStreamConnectFailedExceptionpublic Stream openExitStream(String target, int port, long timeout) throws InterruptedException, TimeoutException, StreamConnectFailedException
ExitCircuitopenExitStream in interface ExitCircuittarget - The network hostname of the exit target.port - The port of the exit target.InterruptedExceptionTimeoutExceptionStreamConnectFailedExceptionpublic void recordFailedExitTarget(ExitTarget target)
ExitCircuitExitTarget as a failed connection so that ExitCircuit.canHandleExitTo(ExitTarget) will
no longer return true for this exit destination.recordFailedExitTarget in interface ExitCircuittarget - The ExitTarget to which a connection has failed through this circuit.public boolean canHandleExitTo(ExitTarget target)
ExitCircuitExitTarget. Returns false if the target destination is
not permitted by the exit policy of the final node in this circuit or if the target
has been previously recorded to have failed through this circuit.canHandleExitTo in interface ExitCircuittarget - The exit destination.public boolean canHandleExitToPort(int port)
canHandleExitToPort in interface ExitCircuitprotected List<Router> choosePathForCircuit(CircuitPathChooser pathChooser) throws InterruptedException, PathSelectionFailedException
choosePathForCircuit in class CircuitImplInterruptedExceptionPathSelectionFailedExceptionprotected String getCircuitTypeLabel()
getCircuitTypeLabel in class CircuitImplCopyright © 2015. All rights reserved.