Class CachedJWT

java.lang.Object
org.opencastproject.security.jwt.CachedJWT

public class CachedJWT extends Object
Class used for caching JWTs.
  • Constructor Details

    • CachedJWT

      public CachedJWT(com.nimbusds.jwt.SignedJWT jwt, String username) throws ParseException
      Creates a cached JWT form a decoded JWT and a username.
      Parameters:
      jwt - The decoded JWT.
      username - The username extracted from the JWT.
      Throws:
      ParseException
  • Method Details

    • hasExpired

      public boolean hasExpired()
      Returns true if the cached JWT expired, false otherwise.
      Returns:
      Boolean indicating whether the cached JWT has expired.
    • getSignature

      public String getSignature()
      Getter for the signature.
      Returns:
      The signature.
    • getExpiresAt

      public Date getExpiresAt()
      Getter for the expiry date.
      Returns:
      The expiry date.
    • getUsername

      public String getUsername()
      Getter for the username.
      Returns:
      The username.