Class IntrospectionResponse

java.lang.Object
io.micronaut.security.endpoints.introspection.IntrospectionResponse

public class IntrospectionResponse extends Object
Author:
Sergio del Amo
See Also:
  • Constructor Details

    • IntrospectionResponse

      public IntrospectionResponse(boolean active, @Nullable @Nullable String tokenType, @Nullable @Nullable String scope, @Nullable @Nullable String clientId, @Nullable @Nullable String username, @Nullable @Nullable Long exp, @Nullable @Nullable Long iat, @Nullable @Nullable Long nbf, @Nullable @Nullable String sub, @Nullable @Nullable String aud, @Nullable @Nullable String iss, @Nullable @Nullable String jti, @Nullable @Nullable Map<String,Object> extensions)
      Parameters:
      active - Boolean indicator of whether or not the presented token is currently active.
      tokenType - Type of token.
      scope - A JSON string containing a space-separated list of scopes associated with this token.
      clientId - Client identifier for the OAuth 2.0 client that requested this token.
      username - Human-readable identifier for the resource owner who authorized this token.
      exp - Integer timestamp, measured in the number of seconds since January 1 1970 UTC, indicating when this token will expire as defined in JWT.
      iat - Integer timestamp, measured in the number of seconds since January 1 1970 UTC, indicating when this token was originally issued, as defined in JWT.
      nbf - Integer timestamp, measured in the number of seconds since January 1 1970 UTC, indicating when this token is not to be used before, as defined in JWT.
      sub - Subject of the token, as defined in JWT [RFC7519]. Usually a machine-readable identifier of the resource owner who authorized this token.
      aud - Service-specific string identifier or list of string identifiers representing the intended audience for this token, as defined in JWT.
      iss - String representing the issuer of this token, as defined in JWT.
      jti - String identifier for the token, as defined in JWT.
      extensions - Extensions
  • Method Details

    • addExtension

      public void addExtension(String key, Object value)
      Parameters:
      key - Key
      value - Value
    • getExtensions

      public Map<String,Object> getExtensions()
      Returns:
      Extensions
    • isActive

      public boolean isActive()
      Returns:
      Boolean indicator of whether or not the presented token is currently active.
    • getScope

      @Nullable public @Nullable String getScope()
      Returns:
      A JSON string containing a space-separated list of scopes associated with this token.
    • getClientId

      @Nullable public @Nullable String getClientId()
      Returns:
      Client identifier for the OAuth 2.0 client that requested this token.
    • getUsername

      @Nullable public @Nullable String getUsername()
      Returns:
      Human-readable identifier for the resource owner who authorized this token.
    • getTokenType

      @Nullable public @Nullable String getTokenType()
      Returns:
      Type of token.
    • getExp

      @Nullable public @Nullable Long getExp()
      Returns:
      Integer timestamp, measured in the number of seconds since January 1 1970 UTC, indicating when this token will expire as defined in JWT.
    • getIat

      @Nullable public @Nullable Long getIat()
      Returns:
      Integer timestamp, measured in the number of seconds since January 1 1970 UTC, indicating when this token was originally issued, as defined in JWT.
    • getNbf

      @Nullable public @Nullable Long getNbf()
      Returns:
      Long timestamp, measured in the number of seconds since January 1 1970 UTC, indicating when this token is not to be used before, as defined in JWT.
    • getSub

      @Nullable public @Nullable String getSub()
      Returns:
      Subject of the token, as defined in JWT [RFC7519]. Usually a machine-readable identifier of the resource owner who authorized this token.
    • getAud

      @Nullable public @Nullable String getAud()
      Returns:
      Service-specific string identifier or list of string identifiers representing the intended audience for this token, as defined in JWT
    • getIss

      @Nullable public @Nullable String getIss()
      Returns:
      Long timestamp, measured in the number of seconds since January 1 1970 UTC, indicating when this token was originally issued, as defined in JWT.
    • getJti

      @Nullable public @Nullable String getJti()
      Returns:
      String identifier for the token, as defined in JWT.