Interface DelegatedTransactionSigner

All Superinterfaces:
DelegatedPublicKeyProvider
All Known Subinterfaces:
DelegatedSignatureService
All Known Implementing Classes:
AbstractDelegatedSignatureService, AbstractDelegatedTransactionSigner

public interface DelegatedTransactionSigner extends DelegatedPublicKeyProvider
Defines how to sign XRPL transactions and claims using private key material that is not accessible to the JVM running implementations of this interface. For example, an implementation might make a call to an HSM that never exposes private-key material. Alternatively, an implementation may use key meta-data to lookup key material in some custom manner (e.g., by deriving it from a secret value).
  • Method Details

    • sign

      <T extends Transaction> SingleSingedTransaction<T> sign(KeyMetadata keyMetadata, T transaction)
      Obtain a signature for the supplied transaction using the private-key that corresponds to keyMetadata.
      Type Parameters:
      T - The type of the transaction to be signed.
      Parameters:
      keyMetadata - A KeyMetadata that describes the public/private Keypair to use for signing operations.
      transaction - The Transaction to sign.
      Returns:
      A SingleSingedTransaction containing binary data that can be submitted to the XRP Ledger in order to effect a transaction.
    • sign

      Signature sign(KeyMetadata keyMetadata, UnsignedClaim unsignedClaim)
      Obtain a signature for the supplied unsigned payment channel claim using the private-key that corresponds to keyMetadata.
      Parameters:
      keyMetadata - A KeyMetadata that describes the public/private Keypair to use for signing operations.
      unsignedClaim - The UnsignedClaim to sign.
      Returns:
      A SingleSingedTransaction containing binary data that can be submitted to the XRP Ledger in order to effect a transaction.
    • multiSign

      <T extends Transaction> Signature multiSign(KeyMetadata keyMetadata, T transaction)
      Obtain a multi-sig signature for the supplied transaction using keyMetadata.
      Type Parameters:
      T - The type Transaction to be signed.
      Parameters:
      keyMetadata - A KeyMetadata that refers to a private key that can be used to sign transaction.
      transaction - The Transaction to sign.
      Returns:
      A SingleSingedTransaction of type DelegatedTransactionSigner containing everything related to a signed transaction.