Class JwtClaims

java.lang.Object
io.jans.as.model.jwt.JwtClaimSet
io.jans.as.model.jwt.JwtClaims

public class JwtClaims extends JwtClaimSet
Author:
Javier Rojas Blum Date: 11.09.2012
  • Constructor Details

  • Method Details

    • setExpirationTime

      public void setExpirationTime(Date expirationTime)
      Identifies the expiration time on or after which the token MUST NOT be accepted for processing.
      Parameters:
      expirationTime - The expiration time.
    • setNotBefore

      public void setNotBefore(Date notBefore)
      Identifies the time before which the token MUST NOT be accepted for processing. The processing of the "nbf" claim requires that the current date/time MUST be after or equal to the not-before date/time listed in the "nbf" claim.
      Parameters:
      notBefore - The not-before date.
    • setNbf

      public void setNbf(Date notBefore)
    • setIssuedAt

      public void setIssuedAt(Date issuedAt)
      Identifies the time at which the JWT was issued. This claim can be used to determine the age of the token.
      Parameters:
      issuedAt - The issue date.
    • setIatNow

      public void setIatNow()
    • setIat

      public void setIat(Date issuedAt)
    • setIssuer

      public void setIssuer(String issuer)
      Identifies the principal that issued the JWT.
      Parameters:
      issuer - The issuer of the JWT.
    • setIssuer

      public void setIssuer(URI issuer)
      Identifies the principal that issued the JWT.
      Parameters:
      issuer - The issuer of the JWT.
    • addAudience

      public void addAudience(String audience)
    • setAudience

      public void setAudience(String audience)
      Identifies the audience that the JWT is intended for. The principal intended to process the JWT MUST be identified with the value of the audience claim. If the principal processing the claim does not identify itself with the identifier in the "aud" claim value then the JWT MUST be rejected.
      Parameters:
      audience - The audience of the JWT.
    • setAudience

      public void setAudience(URI audience)
      Identifies the audience that the JWT is intended for. The principal intended to process the JWT MUST be identified with the value of the audience claim. If the principal processing the claim does not identify itself with the identifier in the "aud" claim value then the JWT MUST be rejected.
      Parameters:
      audience - The audience of the JWT.
    • setSubjectIdentifier

      public void setSubjectIdentifier(String subjectIdentifier)
      Identifies the subject of the JWT.
      Parameters:
      subjectIdentifier - The subject of the JWT.
    • setSubjectIdentifier

      public void setSubjectIdentifier(URI subjectIdentifier)
      Identifies the subject of the JWT.
      Parameters:
      subjectIdentifier - The subject of the JWT.
    • setJwtId

      public void setJwtId(String jwtId)
      Provides a unique identifier for the JWT.
      Parameters:
      jwtId - Unique identifier for the JWT.
    • setJwtId

      public void setJwtId(UUID jwtId)
      Provides a unique identifier for the JWT.
      Parameters:
      jwtId - Unique identifier for the JWT.
    • setType

      public void setType(JwtType type)
      Declare a type for the contents of this JWT Claims Set.
      Parameters:
      type - The type of the JWT claims set.