@ApiAudience.Public @ApiStability.Unstable public interface KeyStore
Modifier and Type | Method and Description |
---|---|
EncryptedPrivateKey |
export(Authentication authentication,
java.lang.String password)
Export an private key encrypted.
|
java.util.List<Identity> |
listIdentities()
Get all the stored identities.
|
Signer |
load(Authentication authentication)
Load signer with
authentication . |
void |
remove(Authentication authentication)
Remove an
AergoKey corresponding to authentication . |
void |
save(Authentication authentication,
AergoKey key)
Store an
AergoKey to the keystore. |
void |
store(java.lang.String path,
char[] password)
Store keystore to the
path with password . |
void save(Authentication authentication, AergoKey key)
AergoKey
to the keystore.authentication
- an authentication to save keykey
- an aergo key to storeInvalidAuthenticationException
- on invalid authenticationKeyStoreException
- on keystore errorSigner load(Authentication authentication)
authentication
.authentication
- an authenticationInvalidAuthenticationException
- on invalid authenticationKeyStoreException
- on keystore errorvoid remove(Authentication authentication)
AergoKey
corresponding to authentication
.authentication
- an authentication to remove keyInvalidAuthenticationException
- on invalid authenticationKeyStoreException
- on keystore errorEncryptedPrivateKey export(Authentication authentication, java.lang.String password)
authentication
- an authentication to used in exporting keypassword
- a password to encryptInvalidAuthenticationException
- on invalid authenticationKeyStoreException
- on keystore errorjava.util.List<Identity> listIdentities()
KeyStoreException
- on keystore errorvoid store(java.lang.String path, char[] password)
path
with password
.path
- a path to store keystorepassword
- a password to encrypt keystoreKeyStoreException
- on keystore error