Package com.eka.middleware.auth.manager
Class SignedJwtSignatureConfiguration
java.lang.Object
org.pac4j.core.util.InitializableObject
org.pac4j.jwt.config.signature.AbstractSignatureConfiguration
com.eka.middleware.auth.manager.SignedJwtSignatureConfiguration
- All Implemented Interfaces:
org.pac4j.jwt.config.signature.SignatureConfiguration
public class SignedJwtSignatureConfiguration
extends org.pac4j.jwt.config.signature.AbstractSignatureConfiguration
-
Constructor Summary
ConstructorDescriptionSignedJwtSignatureConfiguration
(byte[] secret) SignedJwtSignatureConfiguration
(byte[] secret, com.nimbusds.jose.JWSAlgorithm algorithm) SignedJwtSignatureConfiguration
(String secret, com.nimbusds.jose.JWSAlgorithm algorithm) -
Method Summary
Modifier and TypeMethodDescriptionbyte[]
void
void
setSecretBase64
(String secret) void
setSecretBytes
(byte[] secretBytes) com.nimbusds.jwt.SignedJWT
sign
(com.nimbusds.jwt.JWTClaimsSet claims) boolean
supports
(com.nimbusds.jose.JWSAlgorithm algorithm) toString()
boolean
verify
(com.nimbusds.jwt.SignedJWT jwt) Methods inherited from class org.pac4j.jwt.config.signature.AbstractSignatureConfiguration
getAlgorithm, setAlgorithm
Methods inherited from class org.pac4j.core.util.InitializableObject
getLastAttempt, getMaxAttempts, getMinTimeIntervalBetweenAttemptsInMilliseconds, getNbAttempts, init, init, isInitialized, reinit, setMaxAttempts, setMinTimeIntervalBetweenAttemptsInMilliseconds
-
Constructor Details
-
SignedJwtSignatureConfiguration
public SignedJwtSignatureConfiguration() -
SignedJwtSignatureConfiguration
-
SignedJwtSignatureConfiguration
public SignedJwtSignatureConfiguration(byte[] secret) -
SignedJwtSignatureConfiguration
-
SignedJwtSignatureConfiguration
public SignedJwtSignatureConfiguration(byte[] secret, com.nimbusds.jose.JWSAlgorithm algorithm)
-
-
Method Details
-
supports
public boolean supports(com.nimbusds.jose.JWSAlgorithm algorithm) -
sign
public com.nimbusds.jwt.SignedJWT sign(com.nimbusds.jwt.JWTClaimsSet claims) -
verify
public boolean verify(com.nimbusds.jwt.SignedJWT jwt) throws com.nimbusds.jose.JOSEException - Throws:
com.nimbusds.jose.JOSEException
-
getSecret
-
setSecret
-
getSecretBytes
public byte[] getSecretBytes() -
setSecretBytes
public void setSecretBytes(byte[] secretBytes) -
getSecretBase64
-
setSecretBase64
-
toString
-