public class FileKeyPairProvider extends AbstractResourceKeyPairProvider<java.nio.file.Path>
KeyPair
result is
cached and not re-loaded.AbstractResourceKeyPairProvider.KeyPairIterator
Modifier and Type | Field and Description |
---|---|
private java.util.Collection<? extends java.nio.file.Path> |
files |
log
ECDSA_SHA2_NISTP256, ECDSA_SHA2_NISTP384, ECDSA_SHA2_NISTP521, EMPTY_KEYPAIR_PROVIDER, SSH_DSS, SSH_ED25519, SSH_RSA
EMPTY_KEYS_PROVIDER, LOADER
Constructor and Description |
---|
FileKeyPairProvider() |
FileKeyPairProvider(java.util.Collection<? extends java.nio.file.Path> files) |
FileKeyPairProvider(java.nio.file.Path... files) |
FileKeyPairProvider(java.nio.file.Path path) |
Modifier and Type | Method and Description |
---|---|
protected java.security.KeyPair |
doLoadKey(java.nio.file.Path resource) |
java.util.Collection<? extends java.nio.file.Path> |
getPaths() |
java.lang.Iterable<java.security.KeyPair> |
loadKeys()
Load available keys.
|
protected java.io.InputStream |
openKeyPairResource(java.lang.String resourceKey,
java.nio.file.Path resource) |
void |
setFiles(java.util.Collection<java.io.File> files) |
void |
setPaths(java.util.Collection<? extends java.nio.file.Path> paths) |
doLoadKey, doLoadKey, getPasswordFinder, loadKeys, resetCacheMap, setPasswordFinder
getSimplifiedLogger
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getKeyTypes, loadKey, wrap, wrap
iterableOf, iteratorOf, iteratorOf, iteratorOf, multiProvider, multiProvider, providerOf, resolveKeyIdentityProvider, wrapKeyPairs, wrapKeyPairs
public FileKeyPairProvider()
public FileKeyPairProvider(java.nio.file.Path path)
public FileKeyPairProvider(java.nio.file.Path... files)
public FileKeyPairProvider(java.util.Collection<? extends java.nio.file.Path> files)
public java.util.Collection<? extends java.nio.file.Path> getPaths()
public void setFiles(java.util.Collection<java.io.File> files)
public void setPaths(java.util.Collection<? extends java.nio.file.Path> paths)
public java.lang.Iterable<java.security.KeyPair> loadKeys()
KeyIdentityProvider
Iterable
instance of available keys - ignored if null
protected java.security.KeyPair doLoadKey(java.nio.file.Path resource) throws java.io.IOException, java.security.GeneralSecurityException
doLoadKey
in class AbstractResourceKeyPairProvider<java.nio.file.Path>
java.io.IOException
java.security.GeneralSecurityException
protected java.io.InputStream openKeyPairResource(java.lang.String resourceKey, java.nio.file.Path resource) throws java.io.IOException
openKeyPairResource
in class AbstractResourceKeyPairProvider<java.nio.file.Path>
java.io.IOException