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 ofPKIXValidationInformationResolverwhich always returns a static, fixed set of information.
-
-
Field Summary
Fields Modifier and Type Field Description private List<PKIXValidationInformation>pkixInfoThe PKIX validation information to return.private booleansupportDynamicTrustedNamesFlag indicating whether dynamic trusted names should be extracted from criteria set.private Set<String>trustedNamesThe set of trusted names to return.
-
Constructor Summary
Constructors Constructor Description StaticPKIXValidationInformationResolver(List<PKIXValidationInformation> info, Set<String> names)Constructor.StaticPKIXValidationInformationResolver(List<PKIXValidationInformation> info, Set<String> names, boolean supportDynamicNames)Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Iterable<PKIXValidationInformation>resolve(CriteriaSet criteria)PKIXValidationInformationresolveSingle(CriteriaSet criteria)Set<String>resolveTrustedNames(CriteriaSet criteriaSet)Resolve a set of trusted names associated with the entity indicated by the criteria.booleansupportsTrustedNameResolution()Check whether resolution of trusted names is supported.
-
-
-
Field Detail
-
pkixInfo
private final List<PKIXValidationInformation> pkixInfo
The PKIX validation information to return.
-
supportDynamicTrustedNames
private boolean supportDynamicTrustedNames
Flag indicating whether dynamic trusted names should be extracted from criteria set.
-
-
Constructor Detail
-
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 ofTrustedNamesCriterionin the criteria set
-
-
Method Detail
-
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:
resolveTrustedNamesin 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:
supportsTrustedNameResolutionin 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:
resolvein interfaceResolver<PKIXValidationInformation,CriteriaSet>- Throws:
ResolverException
-
resolveSingle
@Nullable public PKIXValidationInformation resolveSingle(@Nullable CriteriaSet criteria) throws ResolverException
- Specified by:
resolveSinglein interfaceResolver<PKIXValidationInformation,CriteriaSet>- Throws:
ResolverException
-
-