public class TcpipClientChannel extends AbstractClientChannel implements ForwardingTunnelEndpointsProvider
Modifier and Type | Class and Description |
---|---|
static class |
TcpipClientChannel.Type
Type of channel being created.
|
AbstractChannel.GracefulChannelCloseable, AbstractChannel.GracefulState
AbstractCloseable.State
AttributeRepository.AttributeKey<T>
StreamingChannel.Streaming
Modifier and Type | Field and Description |
---|---|
protected SshdSocketAddress |
localEntry |
protected ChannelToPortHandler |
port |
protected SshdSocketAddress |
remote |
private SshdSocketAddress |
tunnelEntrance |
private SshdSocketAddress |
tunnelExit |
private TcpipClientChannel.Type |
typeEnum |
asyncErr, asyncIn, asyncOut, err, exitSignalHolder, exitStatusHolder, in, invertedErr, invertedIn, invertedOut, opened, openFailureLang, openFailureMsg, openFailureReason, openFuture, out, redirectErrorStream, streaming
channelListenerProxy, channelListeners, closeSignaled, eofReceived, eofSent, gracefulFuture, gracefulState, initialized, RESPONSE_BUFFER_GROWTH_FACTOR, service, unregisterSignaled
closeFuture, futureLock, state
log
CHANNEL_EXEC, CHANNEL_SHELL, CHANNEL_SUBSYSTEM
EMPTY
NONE
Constructor and Description |
---|
TcpipClientChannel(TcpipClientChannel.Type type,
IoSession serverSession,
SshdSocketAddress remote) |
Modifier and Type | Method and Description |
---|---|
protected ChannelToPortHandler |
createChannelToPortHandler(IoSession session) |
protected void |
doOpen() |
protected void |
doWriteData(byte[] data,
int off,
long len) |
protected void |
doWriteExtendedData(byte[] data,
int off,
long len) |
protected Closeable |
getInnerCloseable() |
TcpipClientChannel.Type |
getTcpipChannelType() |
SshdSocketAddress |
getTunnelEntrance() |
SshdSocketAddress |
getTunnelExit() |
void |
handleEof()
Invoked when
SSH_MSG_CHANNEL_EOF received |
OpenFuture |
open() |
void |
updateLocalForwardingEntry(LocalForwardingEntry entry) |
addChannelSignalRequestHandlers, getAsyncErr, getAsyncIn, getAsyncOut, getChannelState, getChannelType, getErr, getExitSignal, getExitStatus, getIn, getInvertedErr, getInvertedIn, getInvertedOut, getOut, getStreaming, handleOpenFailure, handleOpenSuccess, handleWindowAdjust, isRedirectErrorStream, mayWrite, open, setErr, setIn, setOut, setRedirectErrorStream, setStreaming, updateCurrentChannelState, waitFor
addChannelListener, addPendingRequest, addRequestHandler, attributeKeys, clearAttributes, computeAttributeIfAbsent, configureWindow, getAttribute, getAttributesCount, getChannelId, getChannelListenerProxy, getChannelStreamWriterResolver, getExecutorService, getLocalWindow, getParentPropertyResolver, getProperties, getRecipient, getRemoteWindow, getRequestHandlers, getSession, handleChannelRegistrationResult, handleChannelRequest, handleChannelUnregistration, handleClose, handleData, handleExtendedData, handleFailure, handleInternalRequest, handleRequest, handleSuccess, handleUnknownChannelRequest, init, invokeChannelSignaller, isEofSent, isEofSignalled, isInitialized, notifyStateChanged, notifyStateChanged, preClose, removeAttribute, removeChannelListener, removePendingRequest, removeRequestHandler, resolveChannelStreamWriterResolver, sendEof, sendResponse, sendWindowAdjust, setAttribute, setChannelStreamWriterResolver, setRecipient, signalChannelClosed, signalChannelClosed, signalChannelInitialized, signalChannelInitialized, signalChannelOpenFailure, signalChannelOpenFailure, signalChannelOpenSuccess, signalChannelOpenSuccess, toString, validateIncomingDataSize, writePacket
doCloseGracefully, doCloseImmediately
addCloseFutureListener, builder, close, getFutureLock, isClosed, isClosing, removeCloseFutureListener
debug, debug, debug, debug, debug, error, error, error, error, error, getSimplifiedLogger, info, info, warn, warn, warn, warn, warn, warn, warn, warn
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
getClientSession, validateCommandExitStatusCode, waitFor
addRequestHandler, addRequestHandlers, getLocalWindow, getRecipient, getRemoteWindow, getRequestHandlers, handleChannelRegistrationResult, handleChannelUnregistration, handleClose, handleData, handleExtendedData, handleFailure, handleRequest, handleSuccess, init, isEofSignalled, isInitialized, removeRequestHandler, removeRequestHandlers, resolveAttribute, resolveAttribute, writePacket
getSession, getSessionContext
getChannelId
addChannelListener, getChannelListenerProxy, removeChannelListener
getBoolean, getBooleanProperty, getCharset, getInteger, getIntProperty, getLong, getLongProperty, getObject, getParentPropertyResolver, getProperties, getString, getStringProperty, isEmpty, isEmpty
clearAttributes, computeAttributeIfAbsent, removeAttribute, setAttribute
attributeKeys, getAttribute, getAttributesCount, ofAttributesMap, ofKeyValuePair
getChannelStreamWriterResolver, resolveChannelStreamWriter, resolveChannelStreamWriterResolver, setChannelStreamWriterResolver
addCloseFutureListener, close, close, close, getMaxCloseWaitTime, isClosed, isClosing, isOpen, removeCloseFutureListener
protected final SshdSocketAddress remote
protected final ChannelToPortHandler port
protected SshdSocketAddress localEntry
private final TcpipClientChannel.Type typeEnum
private SshdSocketAddress tunnelEntrance
private SshdSocketAddress tunnelExit
public TcpipClientChannel(TcpipClientChannel.Type type, IoSession serverSession, SshdSocketAddress remote)
protected ChannelToPortHandler createChannelToPortHandler(IoSession session)
public TcpipClientChannel.Type getTcpipChannelType()
public void updateLocalForwardingEntry(LocalForwardingEntry entry)
public OpenFuture open() throws java.io.IOException
open
in interface ClientChannel
open
in class AbstractClientChannel
java.io.IOException
protected void doOpen() throws java.io.IOException
doOpen
in class AbstractClientChannel
java.io.IOException
protected Closeable getInnerCloseable()
getInnerCloseable
in class AbstractClientChannel
protected void doWriteData(byte[] data, int off, long len) throws java.io.IOException
doWriteData
in class AbstractClientChannel
java.io.IOException
protected void doWriteExtendedData(byte[] data, int off, long len) throws java.io.IOException
doWriteExtendedData
in class AbstractClientChannel
java.io.IOException
public void handleEof() throws java.io.IOException
Channel
SSH_MSG_CHANNEL_EOF
receivedhandleEof
in class AbstractChannel
java.io.IOException
- If failed to handle the messagepublic SshdSocketAddress getTunnelEntrance()
getTunnelEntrance
in interface ForwardingTunnelEndpointsProvider
public SshdSocketAddress getTunnelExit()
getTunnelExit
in interface ForwardingTunnelEndpointsProvider