Class HolderOfKeyMetadataSupport
java.lang.Object
se.swedenconnect.opensaml.saml2.metadata.HolderOfKeyMetadataSupport
Support methods for holder-of-key specific metadata elements.
- Author:
- Martin Lindström (martin@idsec.se)
-
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionstatic AssertionConsumerService
getHokAssertionConsumerService
(SPSSODescriptor ssoDescriptor, String binding) Given anSPSSODescriptor
element and a binding URI, the method locates a matchingAssertionConsumerService
Holder-of-key element.static List
<AssertionConsumerService> getHokAssertionConsumerServices
(SPSSODescriptor ssoDescriptor) Given anSPSSODescriptor
element the method locates allAssertionConsumerService
elements that have aBinding
attribute set to "urn:oasis:names:tc:SAML:2.0:profiles:holder-of-key:SSO:browser", i.e., an endpoint for Holder-of-key.static SingleSignOnService
getHoKSingleSignOnService
(IDPSSODescriptor ssoDescriptor, String binding) Given anIDPSSODescriptor
element and a binding (redirect/post), the method locates a matchingSingleSignOnService
Holder-of-key element.static List
<SingleSignOnService> getHokSingleSignOnServices
(IDPSSODescriptor ssoDescriptor) Given anIDPSSODescriptor
element the method locates allSingleSignOnService
elements that have aBinding
attribute set to "urn:oasis:names:tc:SAML:2.0:profiles:holder-of-key:SSO:browser", i.e., a service element for Holder-of-key.static boolean
Predicate that tells if the suppliedAssertionConsumerService
is a HoK endpoint.static boolean
Predicate that tells if the suppliedSingleSignOnService
is a HoK endpoint.
-
Field Details
-
HOK_WEBSSO_PROFILE_URI
URI identifier for the Holder-of-key profile URI.- See Also:
-
HOK_PROTOCOL_BINDING_ATTRIBUTE
The QName for the HoK ProtocolBinding attribute.
-
-
Method Details
-
getHokSingleSignOnServices
Given anIDPSSODescriptor
element the method locates allSingleSignOnService
elements that have aBinding
attribute set to "urn:oasis:names:tc:SAML:2.0:profiles:holder-of-key:SSO:browser", i.e., a service element for Holder-of-key.- Parameters:
ssoDescriptor
- the IDPSSODescriptor- Returns:
- a (possible empty) list of matching SingleSignOnService objects
-
getHoKSingleSignOnService
public static SingleSignOnService getHoKSingleSignOnService(IDPSSODescriptor ssoDescriptor, String binding) Given anIDPSSODescriptor
element and a binding (redirect/post), the method locates a matchingSingleSignOnService
Holder-of-key element.- Parameters:
ssoDescriptor
- the IDPSSODescriptorbinding
- the actual binding URI- Returns:
- a SingleSignOnService or null if no matching element is found
-
isHoKSingleSignOnService
Predicate that tells if the suppliedSingleSignOnService
is a HoK endpoint.- Parameters:
sso
- the SingleSignOnService to test- Returns:
- true if the supplied object is a HoK endpoint and false otherwise
-
getHokAssertionConsumerServices
public static List<AssertionConsumerService> getHokAssertionConsumerServices(SPSSODescriptor ssoDescriptor) Given anSPSSODescriptor
element the method locates allAssertionConsumerService
elements that have aBinding
attribute set to "urn:oasis:names:tc:SAML:2.0:profiles:holder-of-key:SSO:browser", i.e., an endpoint for Holder-of-key.- Parameters:
ssoDescriptor
- the SPSSODescriptor- Returns:
- a (possible empty) list of matching AssertionConsumerService objects
-
getHokAssertionConsumerService
public static AssertionConsumerService getHokAssertionConsumerService(SPSSODescriptor ssoDescriptor, String binding) Given anSPSSODescriptor
element and a binding URI, the method locates a matchingAssertionConsumerService
Holder-of-key element.- Parameters:
ssoDescriptor
- the SPSSODescriptorbinding
- the actual binding URI- Returns:
- a AssertionConsumerService or null if no matching element is found
-
isHoKAssertionConsumerService
Predicate that tells if the suppliedAssertionConsumerService
is a HoK endpoint.- Parameters:
acs
- the AssertionConsumerService to test- Returns:
- true if the supplied object is a HoK endpoint and false otherwise
-