Class AuthenticationJWTClaimsSetAdapter

java.lang.Object
io.micronaut.security.token.jwt.validator.AuthenticationJWTClaimsSetAdapter
All Implemented Interfaces:
Authentication, Serializable, Principal

public class AuthenticationJWTClaimsSetAdapter extends Object implements Authentication
Adapter from JWTClaimsSet to Authentication.
Since:
1.0
Author:
Sergio del Amo
See Also:
  • Constructor Details

    • AuthenticationJWTClaimsSetAdapter

      public AuthenticationJWTClaimsSetAdapter(@Nullable @Nullable com.nimbusds.jwt.JWTClaimsSet claimSet)
      Parameters:
      claimSet - JSON Web Token (JWT) claims set.
  • Method Details

    • getAttributes

      @NonNull public @NonNull Map<String,Object> getAttributes()
      Description copied from interface: Authentication
      In order to correctly implement the Serializable specification, this map should be Map<String, Serializable>, however that would place a burden on those not requiring serialization, forcing their values to conform to that spec. This is left intentionally as Object in order to meet both use cases and those requiring serialization must ensure all values in the map implement Serializable.
      Specified by:
      getAttributes in interface Authentication
      Returns:
      Any additional attributes in the authentication
    • getName

      @Nullable public @Nullable String getName()
      Specified by:
      getName in interface Principal