public abstract class AbstractIdentityValidator<T> extends Object implements IdentityValidator<T>
| Constructor and Description |
|---|
AbstractIdentityValidator() |
| Modifier and Type | Method and Description |
|---|---|
protected byte[] |
decryptTokenData(Session session,
SecurityAlgorithm algorithm,
byte[] dataBytes)
Decrypt the data contained in a
UserNameIdentityToken or IssuedIdentityToken. |
protected T |
validateAnonymousToken(Session session,
AnonymousIdentityToken token,
UserTokenPolicy tokenPolicy,
SignatureData tokenSignature)
Validate an
AnonymousIdentityToken and return an identity Object that represents the user. |
T |
validateIdentityToken(Session session,
UserIdentityToken token,
UserTokenPolicy tokenPolicy,
SignatureData tokenSignature)
Validate the provided
UserIdentityToken and return an identity Object that represents the user. |
protected T |
validateIssuedIdentityToken(Session session,
IssuedIdentityToken token,
UserTokenPolicy tokenPolicy,
SignatureData tokenSignature)
Validate an
IssuedIdentityToken and return an identity Object that represents the user. |
protected T |
validateUsernameToken(Session session,
UserNameIdentityToken token,
UserTokenPolicy tokenPolicy,
SignatureData tokenSignature)
Validate a
UserNameIdentityToken and return an identity Object that represents the user. |
protected T |
validateX509Token(Session session,
X509IdentityToken token,
UserTokenPolicy tokenPolicy,
SignatureData tokenSignature)
Validate an
X509IdentityToken and return an identity Object that represents the user. |
public T validateIdentityToken(Session session, UserIdentityToken token, UserTokenPolicy tokenPolicy, SignatureData tokenSignature) throws UaException
IdentityValidatorUserIdentityToken and return an identity Object that represents the user.
This Object should implement equality in such a way that a subsequent identity validation for the same user yields a comparable Object.
validateIdentityToken in interface IdentityValidator<T>session - the Session the request is arriving on.token - the UserIdentityToken.tokenPolicy - the UserTokenPolicy specified by the policyId in token.tokenSignature - the SignatureData sent in the ActivateSessionRequestT that represents the authenticated user.UaException - if the token is invalid, rejected, or user access is denied.protected T validateAnonymousToken(Session session, AnonymousIdentityToken token, UserTokenPolicy tokenPolicy, SignatureData tokenSignature) throws UaException
AnonymousIdentityToken and return an identity Object that represents the user.
This Object should implement equality in such a way that a subsequent identity validation for the same user yields a comparable Object.
session - the Session the request is arriving on.token - the AnonymousIdentityToken.tokenPolicy - the UserTokenPolicy specified by the policyId in token.tokenSignature - the SignatureData sent in the ActivateSessionRequest.UaException - if the token is invalid, rejected, or user access is denied.protected T validateUsernameToken(Session session, UserNameIdentityToken token, UserTokenPolicy tokenPolicy, SignatureData tokenSignature) throws UaException
UserNameIdentityToken and return an identity Object that represents the user.
This Object should implement equality in such a way that a subsequent identity validation for the same user yields a comparable Object.
session - the Session the request is arriving on.token - the UserNameIdentityToken.tokenPolicy - the UserTokenPolicy specified by the policyId in token.tokenSignature - the SignatureData sent in the ActivateSessionRequest.UaException - if the token is invalid, rejected, or user access is denied.protected T validateX509Token(Session session, X509IdentityToken token, UserTokenPolicy tokenPolicy, SignatureData tokenSignature) throws UaException
X509IdentityToken and return an identity Object that represents the user.
This Object should implement equality in such a way that a subsequent identity validation for the same user yields a comparable Object.
session - the Session the request is arriving on.token - the X509IdentityToken.tokenPolicy - the UserTokenPolicy specified by the policyId in token.tokenSignature - the SignatureData sent in the ActivateSessionRequest.UaException - if the token is invalid, rejected, or user access is denied.protected T validateIssuedIdentityToken(Session session, IssuedIdentityToken token, UserTokenPolicy tokenPolicy, SignatureData tokenSignature) throws UaException
IssuedIdentityToken and return an identity Object that represents the user.
This Object should implement equality in such a way that a subsequent identity validation for the same user yields a comparable Object.
session - the Session the request is arriving on.token - the IssuedIdentityToken.tokenPolicy - the UserTokenPolicy specified by the policyId in token.tokenSignature - the SignatureData sent in the ActivateSessionRequest.UaException - if the token is invalid, rejected, or user access is denied.protected byte[] decryptTokenData(Session session, SecurityAlgorithm algorithm, byte[] dataBytes) throws UaException
UserNameIdentityToken or IssuedIdentityToken.
See UserNameIdentityToken.getPassword() and IssuedIdentityToken.getTokenData().
session - the current Session.dataBytes - the encrypted data.UaException - if decryption fails.Copyright © 2021. All rights reserved.