parseEncrypted

Parses and validates a JWE compact token, returning the decrypted JwtInstance.Jwe.

The token is decrypted using the key registered via JwtParserBuilder.decryptWith, and the decrypted payload is then subjected to time-claim and custom-claim validation (RFC 7516).

Return

the parsed and decrypted JwtInstance.Jwe

Parameters

token

the JWE compact serialization to parse (must be exactly 5 dot-separated parts)

See also

Throws

if the token is not a valid 5-part JWE

if the key algorithm or content algorithm is unrecognised

if decryption or authentication tag verification fails

if the token is past its expiration

if the token is not yet valid

if a required claim is absent

if a required claim has an unexpected value