Class VaultSignatureVerificationRequest

java.lang.Object
org.springframework.vault.support.VaultSignatureVerificationRequest

public class VaultSignatureVerificationRequest extends Object
Request for a signature verification.
Since:
2.0
Author:
Luander Ribeiro, Mark Paluch, My-Lan Aragon, James Luke, Nanne Baars
  • Method Details

    • builder

      Returns:
      a new instance of VaultSignatureVerificationRequest.VaultSignatureVerificationRequestBuilder.
    • create

      public static VaultSignatureVerificationRequest create(Plaintext plaintext, Signature signature)
      Create a new VaultSignatureVerificationRequest given Plaintext and Signature.
      Parameters:
      plaintext - the plaintext, must not be null.
      signature - the signature, must not be null.
      Returns:
      a new VaultSignatureVerificationRequest for Plaintext and Signature.
    • create

      public static VaultSignatureVerificationRequest create(Plaintext plaintext, Hmac hmac)
      Create a new VaultSignatureVerificationRequest given Plaintext and Hmac.
      Parameters:
      plaintext - the plaintext, must not be null.
      hmac - the hmac, must not be null.
      Returns:
      a new VaultSignatureVerificationRequest for Plaintext and Hmac.
    • getPlaintext

      public Plaintext getPlaintext()
      Returns:
      plain text input used as basis to verify the signature.
    • getSignature

      public @Nullable Signature getSignature()
      Returns:
      signature resulting of a sign operation, can be null if HMAC is used.
    • getHmac

      public @Nullable Hmac getHmac()
      Returns:
      digest resulting of a Hmac operation, can be null if Signature is used.
    • getHashAlgorithm

      public @Nullable String getHashAlgorithm()
      Returns:
      hash algorithm used for verifying the signature or null to use the default algorithm.
      Since:
      2.4
    • getSignatureAlgorithm

      public @Nullable String getSignatureAlgorithm()
      Returns:
      signature algorithm used for verifying the signature when using an RSA key or null to use the default algorithm.
      Since:
      2.4
    • isPrehashed

      public boolean isPrehashed()
      Returns:
      true if the input is already hashed.
      Since:
      3.1