Class DecodedSecret

    • Method Detail

      • withExpiration

        public DecodedSecret withExpiration​(@Nullable Date expDate)
        Returns a new decoded secret with the specified expiration date.
        Parameters:
        expDate - The expiration date, null if not specified.
        Returns:
        The new decoded secret.
      • getEncodedValue

        public @Nullable String getEncodedValue()
        Returns the encoded (stored) value.
        Returns:
        The encoded value, null if not specified.
      • withEncodedValue

        public DecodedSecret withEncodedValue​(@Nullable String encodedValue)
        Returns a new decoded secret associating the specified encoded (stored) value with it.
        Parameters:
        encodedValue - The encoded (stored) value, null if not specified.
        Returns:
        The new decoded secret.
      • equals

        public boolean equals​(Object o)
        Overrides:
        equals in class com.nimbusds.oauth2.sdk.auth.Secret
      • createForPlainSecret

        public static DecodedSecret createForPlainSecret​(String plainValue)
        Creates a new decoded plain secret.
        Parameters:
        plainValue - The plain secret value. Must not be empty or null.
        Returns:
        The decoded secret.
      • createForHashedSecret

        public static DecodedSecret createForHashedSecret​(SecretVerifier verifier)
        Creates a new decoded hashed secret.
        Parameters:
        verifier - Verifier to check secrets against the hash. Must not be null.
        Returns:
        The decoded secret.