public final class NimbusReactiveJwtDecoder extends java.lang.Object implements ReactiveJwtDecoder
JwtDecoder
that "decodes" a
JSON Web Token (JWT) and additionally verifies it's digital signature if the JWT is a
JSON Web Signature (JWS). The public key used for verification is obtained from the
JSON Web Key (JWK) Set URL
supplied via the constructor.
NOTE: This implementation uses the Nimbus JOSE + JWT SDK internally.
JwtDecoder
,
JSON Web Token (JWT),
JSON Web Signature (JWS),
JSON Web Key (JWK),
Nimbus JOSE + JWT SDKConstructor and Description |
---|
NimbusReactiveJwtDecoder(java.security.interfaces.RSAPublicKey publicKey) |
NimbusReactiveJwtDecoder(java.lang.String jwkSetUrl)
Constructs a
NimbusJwtDecoderJwkSupport using the provided parameters. |
Modifier and Type | Method and Description |
---|---|
reactor.core.publisher.Mono<Jwt> |
decode(java.lang.String token)
Decodes the JWT from it's compact claims representation format and returns a
Jwt . |
public NimbusReactiveJwtDecoder(java.security.interfaces.RSAPublicKey publicKey)
public NimbusReactiveJwtDecoder(java.lang.String jwkSetUrl)
NimbusJwtDecoderJwkSupport
using the provided parameters.jwkSetUrl
- the JSON Web Key (JWK) Set URL
public reactor.core.publisher.Mono<Jwt> decode(java.lang.String token) throws JwtException
ReactiveJwtDecoder
Jwt
.decode
in interface ReactiveJwtDecoder
token
- the JWT valueJwt
JwtException
- if an error occurs while attempting to decode the JWT