public class SymmetricKeyTokenGenerator extends BaseTokenGenerator
ALLOWED_CLOCK_SKEW, PREIMAGE_LENGTH| Constructor and Description |
|---|
SymmetricKeyTokenGenerator(SymmetricKeyManager keyManager) |
| Modifier and Type | Method and Description |
|---|---|
java.lang.String |
getIssuerName(java.lang.String context)
Method to retrieve the issuer claim in generated JWT tokens.
|
protected void |
populateJWEDecryptionAlgAndKey(TokenContext context,
org.jose4j.jwe.JsonWebEncryption jwe)
Method to set the encryption algorithm and key used to deencrypt the token.
|
protected void |
populateJWEEncryptionAlgAndKey(TokenContext context,
java.lang.String recipientSubject,
org.jose4j.jwe.JsonWebEncryption jwe)
Method to set the encryption algorithm and key used to encrypt the token.
|
protected void |
populateJWSSignatureAlgAndKey(TokenContext context,
org.jose4j.jws.JsonWebSignature jws)
Populates the JWS Signature with HMAC_SHA256 and the used symmetric key.
|
protected void |
populateJWSVerifyAlgAndKey(TokenContext context,
org.jose4j.jws.JsonWebSignature jws)
Populates the JWS Signature with HMAC_SHA256 whitelisting and the used symmetric key.
|
generateInvoiceToken, generatePaymentToken, generateSettlementToken, generateToken, genPreImageData, getSecureRandom, parseTokenpublic SymmetricKeyTokenGenerator(SymmetricKeyManager keyManager)
protected void populateJWSSignatureAlgAndKey(TokenContext context, org.jose4j.jws.JsonWebSignature jws) throws java.io.IOException, InternalErrorException
populateJWSSignatureAlgAndKey in class BaseTokenGeneratorjws - the JsonWebSignature to populate.context - the related token context.java.io.IOException - if communication problems occurred with underlying systems.InternalErrorException - if internal error occurred accessing the symmetric key.protected void populateJWSVerifyAlgAndKey(TokenContext context, org.jose4j.jws.JsonWebSignature jws) throws java.io.IOException, InternalErrorException
populateJWSVerifyAlgAndKey in class BaseTokenGeneratorcontext - the related token context.jws - the JsonWebSignature to populate.java.io.IOException - if communication problems occurred with underlying systems.InternalErrorException - if internal error occurred accessing the symmetric key.protected void populateJWEEncryptionAlgAndKey(TokenContext context, java.lang.String recipientSubject, org.jose4j.jwe.JsonWebEncryption jwe) throws java.io.IOException, InternalErrorException
populateJWEEncryptionAlgAndKey in class BaseTokenGeneratorcontext - the related token context.recipientSubject - not used for symmetric token generator.jwe - the encryption object to populate used algorithm and key for.java.io.IOException - if communication problems occurred with underlying systems.InternalErrorException - if internal problem occurred setting the JWE properties.protected void populateJWEDecryptionAlgAndKey(TokenContext context, org.jose4j.jwe.JsonWebEncryption jwe) throws java.io.IOException, InternalErrorException
populateJWEDecryptionAlgAndKey in class BaseTokenGeneratorcontext - the related token context.jwe - the encryption object to populate used algorithm and key for.java.io.IOException - if communication problems occurred with underlying systems.InternalErrorException - if internal problem occurred setting the JWE properties.public java.lang.String getIssuerName(java.lang.String context)
throws InternalErrorException
context - the related token context.InternalErrorException - if internal problems occurred retrieving the issuer name for the given context.