Package org.xrpl.xrpl4j.crypto
Interface KeyMetadata
- All Known Implementing Classes:
ImmutableKeyMetadata
,KeyMetadata.AbstractKeyMetadata
public interface KeyMetadata
Metadata about a particular key, public or private. This interface acts like a pointer to a key without having to
pass around the key itself. This pattern enables a single API to operate with keys that exist in the same JVM as the
running program, but also allows the API to operate on keys that exist outside of the JVM, such as in an external
key-store like an HSM or other hardware wallet.
-
Nested Class Summary
Modifier and TypeInterfaceDescriptionstatic class
To satisfy immutables. -
Field Summary
Modifier and TypeFieldDescriptionstatic final KeyMetadata
Any empty instance that conformas to this interface but is otherwise empty. -
Method Summary
Modifier and TypeMethodDescriptionstatic ImmutableKeyMetadata.Builder
builder()
A Builder for immutables.The unique identifier for the private-key used to encrypt this encoded secret.An optional password that will unlock this particular key.The unique identifier of the keyring that holds the the private-key used to encrypt this encoded secret.The version of the encryption key used to encrypt this secret.The unique identifier of the platform that can decode this secret.
-
Field Details
-
EMPTY
Any empty instance that conformas to this interface but is otherwise empty. The purpose of this instance is to enable the signing interface to work with implementations that don't have more than a single private key internally without having to introduce null values into the API.
-
-
Method Details
-
builder
A Builder for immutables.- Returns:
- A
ImmutableKeyMetadata.Builder
.
-
platformIdentifier
String platformIdentifier()The unique identifier of the platform that can decode this secret.- Returns:
- A
String
.
-
keyringIdentifier
String keyringIdentifier()The unique identifier of the keyring that holds the the private-key used to encrypt this encoded secret.- Returns:
- A
String
.
-
keyIdentifier
String keyIdentifier()The unique identifier for the private-key used to encrypt this encoded secret.- Returns:
- A
String
.
-
keyVersion
String keyVersion()The version of the encryption key used to encrypt this secret.- Returns:
- A
String
.
-
keyPassword
An optional password that will unlock this particular key.
-