Class SignedThenEncryptedJwt

java.lang.Object
org.forgerock.json.jose.jwe.EncryptedJwt
org.forgerock.json.jose.jwe.SignedThenEncryptedJwt
All Implemented Interfaces:
Jwt, Payload

public class SignedThenEncryptedJwt extends EncryptedJwt
A nested signed-then-encrypted JWT.
  • Constructor Details

    • SignedThenEncryptedJwt

      public SignedThenEncryptedJwt(EncryptedJwt encryptedJwt)
      Constructs a fresh signed-then-encrypted JWT from an encrypted JWT. To use if you know that the encrypted JWT is actually containing a JWS.
      Parameters:
      encryptedJwt - the encrypted JWT.
    • SignedThenEncryptedJwt

      public SignedThenEncryptedJwt(JweHeader header, SignedJwt payload, Key publicKey)
      Constructs a fresh signed-then-encrypted JWT with the given signed JWT payload, JWE headers and encryption key.
      Parameters:
      header - the JWE headers.
      payload - the signed JWT payload.
      publicKey - the encryption key.
    • SignedThenEncryptedJwt

      public SignedThenEncryptedJwt(JweHeader header, String encodedHeader, byte[] encryptedContentEncryptionKey, byte[] initialisationVector, byte[] ciphertext, byte[] authenticationTag)
      Reconstructs a signed-then-encrypted JWT from components parts of the encrypted JWT string.
      Parameters:
      header - the decoded headers.
      encodedHeader - the encoded headers.
      encryptedContentEncryptionKey - the encrypted content encryption key (CEK), or null if not used.
      initialisationVector - the initialisation vector (IV).
      ciphertext - the encrypted ciphertext payload.
      authenticationTag - the authentication MAC tag.
  • Method Details