public class CachingPublicKeyAuthenticator extends AbstractLoggingBean implements PublickeyAuthenticator
OpenSSH
behavior where it sends 2 requests with the same key
(see SSHD-300
).Modifier and Type | Field and Description |
---|---|
protected PublickeyAuthenticator |
authenticator |
static AttributeRepository.AttributeKey<Map<PublicKey,Boolean>> |
CACHE_ATTRIBUTE
The
AttributeKey used to store the cached
authentication results on the session instance |
log
Constructor and Description |
---|
CachingPublicKeyAuthenticator(PublickeyAuthenticator authenticator) |
Modifier and Type | Method and Description |
---|---|
boolean |
authenticate(String username,
PublicKey key,
ServerSession session)
Check the validity of a public key.
|
protected Map<PublicKey,Boolean> |
resolveCachedResults(String username,
PublicKey key,
ServerSession session) |
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, toString, wait, wait, wait
fromAuthorizedEntries
public static final AttributeRepository.AttributeKey<Map<PublicKey,Boolean>> CACHE_ATTRIBUTE
AttributeKey
used to store the cached
authentication results on the session instanceprotected final PublickeyAuthenticator authenticator
public CachingPublicKeyAuthenticator(PublickeyAuthenticator authenticator)
public boolean authenticate(String username, PublicKey key, ServerSession session)
PublickeyAuthenticator
authenticate
in interface PublickeyAuthenticator
username
- the usernamekey
- the keysession
- the server sessionCopyright © 2008–2024 The Apache Software Foundation. All rights reserved.