public class FilePrivateKeyDataProvider extends Object implements PrivateKeyDataProvider
PrivateKeyDataProvider that reads the private key from a file.| Constructor and Description |
|---|
FilePrivateKeyDataProvider(File privateKeyFile)
Create a new provider, specifying the file from which the private key can be read.
|
FilePrivateKeyDataProvider(String privateKeyFileName)
Create a new provider, specifying the name of the file from which the private key can be read.
|
| Modifier and Type | Method and Description |
|---|---|
byte[] |
getEncryptedPrivateKeyData()
This method returns the data from the file containing the encrypted
private key from the public/private key pair.
|
File |
getPrivateKeyFile()
Gets the file that the private key is located at.
|
public FilePrivateKeyDataProvider(File privateKeyFile)
privateKeyFile - the private key filepublic FilePrivateKeyDataProvider(String privateKeyFileName)
privateKeyFileName - The private key file namepublic byte[] getEncryptedPrivateKeyData()
throws KeyNotFoundException
getEncryptedPrivateKeyData in interface PrivateKeyDataProviderKeyNotFoundException - if the key data could not be retrieved; an acceptable message or chained cause must be provided.public File getPrivateKeyFile()
Copyright © 2010-2013 NWTS Java Code. All Rights Reserved. Licensed Under the Apache License version 2.0.