Package org.opensaml.security.x509.impl
Class StaticPKIXValidationInformationResolver
java.lang.Object
org.opensaml.security.x509.impl.StaticPKIXValidationInformationResolver
- All Implemented Interfaces:
Resolver<PKIXValidationInformation,
,CriteriaSet> PKIXValidationInformationResolver
public class StaticPKIXValidationInformationResolver
extends Object
implements PKIXValidationInformationResolver
An implementation of
PKIXValidationInformationResolver
which always returns a static, fixed set of
information.-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final List<PKIXValidationInformation>
The PKIX validation information to return.private boolean
Flag indicating whether dynamic trusted names should be extracted from criteria set.The set of trusted names to return. -
Constructor Summary
ConstructorsConstructorDescriptionConstructor.StaticPKIXValidationInformationResolver
(List<PKIXValidationInformation> info, Set<String> names, boolean supportDynamicNames) Constructor. -
Method Summary
Modifier and TypeMethodDescriptionresolve
(CriteriaSet criteria) resolveSingle
(CriteriaSet criteria) resolveTrustedNames
(CriteriaSet criteriaSet) Resolve a set of trusted names associated with the entity indicated by the criteria.boolean
Check whether resolution of trusted names is supported.
-
Field Details
-
pkixInfo
The PKIX validation information to return. -
trustedNames
The set of trusted names to return. -
supportDynamicTrustedNames
private boolean supportDynamicTrustedNamesFlag indicating whether dynamic trusted names should be extracted from criteria set.
-
-
Constructor Details
-
StaticPKIXValidationInformationResolver
public StaticPKIXValidationInformationResolver(@Nullable @ParameterName(name="info") List<PKIXValidationInformation> info, @Nullable @ParameterName(name="names") Set<String> names) Constructor.Dynamic trusted names will not be supported.
- Parameters:
info
- list of PKIX validation information to returnnames
- set of trusted names to return
-
StaticPKIXValidationInformationResolver
public StaticPKIXValidationInformationResolver(@Nullable @ParameterName(name="info") List<PKIXValidationInformation> info, @Nullable @ParameterName(name="names") Set<String> names, @ParameterName(name="supportDynamicNames") boolean supportDynamicNames) Constructor.- Parameters:
info
- list of PKIX validation information to returnnames
- set of trusted names to returnsupportDynamicNames
- whether resolver should support dynamic extraction of trusted names from an instance ofTrustedNamesCriterion
in the criteria set
-
-
Method Details
-
resolveTrustedNames
@Nonnull public Set<String> resolveTrustedNames(@Nullable CriteriaSet criteriaSet) throws ResolverException Resolve a set of trusted names associated with the entity indicated by the criteria. This method is optional to implement.- Specified by:
resolveTrustedNames
in interfacePKIXValidationInformationResolver
- Parameters:
criteriaSet
- set of criteria used to determine or resolve the trusted names- Returns:
- the set of certificate names trusted for an entity
- Throws:
ResolverException
- thrown if there is an error resolving the trusted names
-
supportsTrustedNameResolution
public boolean supportsTrustedNameResolution()Check whether resolution of trusted names is supported.- Specified by:
supportsTrustedNameResolution
in interfacePKIXValidationInformationResolver
- Returns:
- true if the implementation supports resolution of trusted names, otherwise false
-
resolve
@Nonnull public Iterable<PKIXValidationInformation> resolve(@Nullable CriteriaSet criteria) throws ResolverException - Specified by:
resolve
in interfaceResolver<PKIXValidationInformation,
CriteriaSet> - Throws:
ResolverException
-
resolveSingle
@Nullable public PKIXValidationInformation resolveSingle(@Nullable CriteriaSet criteria) throws ResolverException - Specified by:
resolveSingle
in interfaceResolver<PKIXValidationInformation,
CriteriaSet> - Throws:
ResolverException
-