Class JsonWebToken

    • Constructor Detail

      • JsonWebToken

        public JsonWebToken()
    • Method Detail

      • getId

        public String getId()
      • getExp

        public Long getExp()
      • isExpired

        public boolean isExpired()
      • getNbf

        public Long getNbf()
      • isNotBefore

        public boolean isNotBefore​(int allowedTimeSkew)
      • isActive

        public boolean isActive()
        Tests that the token is not expired and is not-before.
        Returns:
      • isActive

        public boolean isActive​(int allowedTimeSkew)
      • getIat

        public Long getIat()
      • issuedNow

        public JsonWebToken issuedNow()
        Set issuedAt to the current time
      • getIssuer

        public String getIssuer()
      • getAudience

        public String[] getAudience()
      • hasAudience

        public boolean hasAudience​(String audience)
      • getSubject

        public String getSubject()
      • setSubject

        public void setSubject​(String subject)
      • getType

        public String getType()
      • getIssuedFor

        public String getIssuedFor()
        OAuth client the token was issued for.
        Returns:
      • getOtherClaims

        public Map<String,​Object> getOtherClaims()
        This is a map of any other claims and data that might be in the IDToken. Could be custom claims set up by the auth server
        Returns:
      • setOtherClaims

        public void setOtherClaims​(String name,
                                   Object value)