public abstract class AbstractAgentProxy extends AbstractLoggingBean implements SshAgent, ExecutorServiceConfigurer
Modifier and Type | Field and Description |
---|---|
private java.lang.String |
channelType |
private java.util.concurrent.ExecutorService |
executor |
private boolean |
shutdownExecutor |
log
SSH_AUTHSOCKET_ENV_NAME
Modifier | Constructor and Description |
---|---|
protected |
AbstractAgentProxy() |
Modifier and Type | Method and Description |
---|---|
void |
addIdentity(java.security.KeyPair kp,
java.lang.String comment) |
void |
close() |
protected Buffer |
createBuffer(byte cmd) |
protected Buffer |
createBuffer(byte cmd,
int extraLen) |
java.lang.String |
getChannelType() |
java.util.concurrent.ExecutorService |
getExecutorService() |
java.util.List<? extends java.util.Map.Entry<java.security.PublicKey,java.lang.String>> |
getIdentities() |
boolean |
isShutdownOnExit() |
protected Buffer |
prepare(Buffer buffer) |
void |
removeAllIdentities() |
void |
removeIdentity(java.security.PublicKey key) |
protected abstract Buffer |
request(Buffer buffer) |
void |
setChannelType(java.lang.String channelType) |
void |
setExecutorService(java.util.concurrent.ExecutorService service) |
void |
setShutdownOnExit(boolean shutdown) |
byte[] |
sign(java.security.PublicKey key,
byte[] data) |
getSimplifiedLogger
private java.util.concurrent.ExecutorService executor
private boolean shutdownExecutor
private java.lang.String channelType
public java.lang.String getChannelType()
public void setChannelType(java.lang.String channelType)
public java.util.concurrent.ExecutorService getExecutorService()
getExecutorService
in interface ExecutorServiceCarrier
ExecutorService
to usepublic void setExecutorService(java.util.concurrent.ExecutorService service)
setExecutorService
in interface ExecutorServiceConfigurer
public boolean isShutdownOnExit()
isShutdownOnExit
in interface ExecutorServiceCarrier
true
then the ExecutorService.shutdownNow()
will be called (unless it is an internally allocated service which is always
closed)public void setShutdownOnExit(boolean shutdown)
setShutdownOnExit
in interface ExecutorServiceConfigurer
public java.util.List<? extends java.util.Map.Entry<java.security.PublicKey,java.lang.String>> getIdentities() throws java.io.IOException
getIdentities
in interface SshAgent
java.io.IOException
public byte[] sign(java.security.PublicKey key, byte[] data) throws java.io.IOException
public void addIdentity(java.security.KeyPair kp, java.lang.String comment) throws java.io.IOException
addIdentity
in interface SshAgent
java.io.IOException
public void removeIdentity(java.security.PublicKey key) throws java.io.IOException
removeIdentity
in interface SshAgent
java.io.IOException
public void removeAllIdentities() throws java.io.IOException
removeAllIdentities
in interface SshAgent
java.io.IOException
public void close() throws java.io.IOException
close
in interface java.io.Closeable
close
in interface java.lang.AutoCloseable
close
in interface java.nio.channels.Channel
java.io.IOException
protected Buffer createBuffer(byte cmd)
protected Buffer createBuffer(byte cmd, int extraLen)