public class ExplicitKeyTrustEngine extends Object implements TrustedCredentialTrustEngine<Credential>
Trust engine that evaluates a credential's key against key(s) expressed within a set of trusted credentials obtained from a trusted credential resolver. The credential being tested is valid if its public key or secret key matches the public key, or secret key respectively, contained within any of the trusted credentials produced by the given credential resolver.
Constructors Constructor Description
Modifier and Type Method Description
()Gets the credential resolver used to recover trusted credentials that may be used to validate tokens.
Credential untrustedCredential, CriteriaSet trustBasisCriteria)(Validates the token against trusted information obtained in an implementation-specific manner.
getCredentialResolver@Nonnull public CredentialResolver getCredentialResolver()Gets the credential resolver used to recover trusted credentials that may be used to validate tokens.
validatepublic boolean validate(@Nonnull Credential untrustedCredential, @Nullable CriteriaSet trustBasisCriteria) throws SecurityExceptionValidates the token against trusted information obtained in an implementation-specific manner.
- Specified by:
untrustedCredential- security token to validate
trustBasisCriteria- criteria used to describe and/or resolve the information which serves as the basis for trust evaluation
- true iff the token is trusted and valid
SecurityException- thrown if there is a problem validating the security token