public abstract class StaticServerKeyVerifier extends AbstractLoggingBean implements ServerKeyVerifier
true/false regardless| Modifier and Type | Field and Description |
|---|---|
private boolean |
acceptance |
log| Modifier | Constructor and Description |
|---|---|
protected |
StaticServerKeyVerifier(boolean acceptance) |
| Modifier and Type | Method and Description |
|---|---|
protected void |
handleAcceptance(ClientSession sshClientSession,
java.net.SocketAddress remoteAddress,
java.security.PublicKey serverKey) |
protected void |
handleRejection(ClientSession sshClientSession,
java.net.SocketAddress remoteAddress,
java.security.PublicKey serverKey) |
boolean |
isAccepted() |
boolean |
verifyServerKey(ClientSession sshClientSession,
java.net.SocketAddress remoteAddress,
java.security.PublicKey serverKey)
Verify that the server key provided is really the one of the host.
|
getSimplifiedLoggerpublic final boolean isAccepted()
public final boolean verifyServerKey(ClientSession sshClientSession, java.net.SocketAddress remoteAddress, java.security.PublicKey serverKey)
ServerKeyVerifierverifyServerKey in interface ServerKeyVerifiersshClientSession - the current ClientSessionremoteAddress - the host's SocketAddressserverKey - the presented server PublicKeytrue if the key is accepted for the hostprotected void handleAcceptance(ClientSession sshClientSession, java.net.SocketAddress remoteAddress, java.security.PublicKey serverKey)
protected void handleRejection(ClientSession sshClientSession, java.net.SocketAddress remoteAddress, java.security.PublicKey serverKey)