Class AbstractResourceKeyPairProvider<R>
java.lang.Object
org.apache.sshd.common.util.logging.AbstractLoggingBean
org.apache.sshd.common.keyprovider.AbstractKeyPairProvider
org.apache.sshd.common.keyprovider.AbstractResourceKeyPairProvider<R>
- Type Parameters:
R- Type of resource from which theKeyPairis generated
- All Implemented Interfaces:
KeyIdentityProvider,KeyPairProvider
- Direct Known Subclasses:
ClassLoadableResourceKeyPairProvider,FileKeyPairProvider
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsFields inherited from class org.apache.sshd.common.util.logging.AbstractLoggingBean
logFields inherited from interface org.apache.sshd.common.keyprovider.KeyIdentityProvider
EMPTY_KEYS_PROVIDERFields inherited from interface org.apache.sshd.common.keyprovider.KeyPairProvider
ECDSA_SHA2_NISTP256, ECDSA_SHA2_NISTP384, ECDSA_SHA2_NISTP521, EMPTY_KEYPAIR_PROVIDER, SSH_DSS, SSH_DSS_CERT, SSH_ECDSA_SHA2_NISTP256_CERT, SSH_ECDSA_SHA2_NISTP384_CERT, SSH_ECDSA_SHA2_NISTP521_CERT, SSH_ED25519, SSH_ED25519_CERT, SSH_RSA, SSH_RSA_CERT -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiondoLoadKeys(SessionContext session, NamedResource resourceKey, InputStream inputStream, FilePasswordProvider provider) doLoadKeys(SessionContext session, NamedResource resourceKey, R resource, FilePasswordProvider provider) doLoadKeys(SessionContext session, R resource) protected IoResource<?> getIoResource(SessionContext session, R resource) loadKeys(SessionContext session, Collection<? extends R> resources) protected InputStreamopenKeyPairResource(SessionContext session, NamedResource resourceKey, R resource) protected voidresetCacheMap(Collection<?> resources) Checks which of the new resources we already loaded and can keep the associated key pairvoidsetPasswordFinder(FilePasswordProvider passwordFinder) Methods inherited from class org.apache.sshd.common.util.logging.AbstractLoggingBean
debug, debug, debug, debug, debug, error, error, error, error, error, getSimplifiedLogger, info, info, warn, warn, warn, warn, warn, warn, warn, warnMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.apache.sshd.common.keyprovider.KeyIdentityProvider
loadKeysMethods inherited from interface org.apache.sshd.common.keyprovider.KeyPairProvider
getKeyTypes, loadKey
-
Field Details
-
passwordFinder
-
cacheMap
-
-
Constructor Details
-
AbstractResourceKeyPairProvider
protected AbstractResourceKeyPairProvider()
-
-
Method Details
-
getPasswordFinder
-
setPasswordFinder
-
resetCacheMap
Checks which of the new resources we already loaded and can keep the associated key pair- Parameters:
resources- The collection of new resources - can benull/empty in which case the cache is cleared
-
loadKeys
-
getIoResource
-
doLoadKeys
protected Iterable<KeyPair> doLoadKeys(SessionContext session, R resource) throws IOException, GeneralSecurityException - Throws:
IOExceptionGeneralSecurityException
-
doLoadKeys
protected Iterable<KeyPair> doLoadKeys(SessionContext session, NamedResource resourceKey, R resource, FilePasswordProvider provider) throws IOException, GeneralSecurityException - Throws:
IOExceptionGeneralSecurityException
-
openKeyPairResource
protected InputStream openKeyPairResource(SessionContext session, NamedResource resourceKey, R resource) throws IOException - Throws:
IOException
-
doLoadKeys
protected Iterable<KeyPair> doLoadKeys(SessionContext session, NamedResource resourceKey, InputStream inputStream, FilePasswordProvider provider) throws IOException, GeneralSecurityException - Throws:
IOExceptionGeneralSecurityException
-