public class SAML2MetaManager extends Object
SAML2MetaManager
provides methods to manage both the
standard entity descriptor and the extended entity configuration.Modifier and Type | Field and Description |
---|---|
static String |
NAME_META_ALIAS_IN_URI
Constant used to identify meta alias.
|
Constructor and Description |
---|
SAML2MetaManager()
Constructor for
SAML2MetaManager . |
SAML2MetaManager(Object callerToken)
Constructor for
SAML2MetaManager . |
Modifier and Type | Method and Description |
---|---|
void |
createEntity(String realm,
EntityDescriptorElement descriptor,
EntityConfigElement config)
Creates the standard and extended metadata under the realm.
|
void |
createEntityConfig(String realm,
EntityConfigElement config)
Creates the extended entity configuration under the realm.
|
void |
createEntityDescriptor(String realm,
EntityDescriptorElement descriptor)
Creates the standard metadata entity descriptor under the realm.
|
void |
deleteEntityConfig(String realm,
String entityId)
Deletes the extended entity configuration under the realm.
|
void |
deleteEntityDescriptor(String realm,
String entityId)
Deletes the standard metadata entity descriptor under the realm.
|
AffiliationConfigElement |
getAffiliationConfig(String realm,
String entityId)
Returns affiliation configuration in an entity under the realm.
|
AffiliationDescriptorType |
getAffiliationDescriptor(String realm,
String entityId)
Returns affiliation descriptor in an entity under the realm.
|
Set |
getAllEntities(String realm)
Returns all entities under the realm.
|
List |
getAllHostedEntities(String realm)
Returns all hosted entities under the realm.
|
List |
getAllHostedIdentityProviderEntities(String realm)
Returns all hosted identity provider entities under the realm.
|
List |
getAllHostedIdentityProviderMetaAliases(String realm)
Returns metaAliases of all hosted identity providers under the realm.
|
List<String> |
getAllHostedMetaAliasesByRealm(String realm)
Returns all the hosted entity metaAliases for a realm.
|
List |
getAllHostedPolicyDecisionPointEntities(String realm)
Returns all hosted policy decision point entities under the realm.
|
List |
getAllHostedPolicyDecisionPointMetaAliases(String realm)
Returns meta aliases of all hosted policy decision point under the realm.
|
List |
getAllHostedPolicyEnforcementPointEntities(String realm)
Returns all hosted policy enforcement point entities under the realm.
|
List |
getAllHostedPolicyEnforcementPointMetaAliases(String realm)
Returns meta aliases of all hosted policy enforcement point under the
realm.
|
List |
getAllHostedServiceProviderEntities(String realm)
Returns all hosted service provider entities under the realm.
|
List |
getAllHostedServiceProviderMetaAliases(String realm)
Returns metaAliases of all hosted service providers under the realm.
|
List |
getAllRemoteEntities(String realm)
Returns all remote entities under the realm.
|
List |
getAllRemoteIdentityProviderEntities(String realm)
Returns all remote identity provider entities under the realm.
|
List |
getAllRemotePolicyDecisionPointEntities(String realm)
Returns all remote policy decision point entities under the realm.
|
List |
getAllRemotePolicyEnforcementPointEntities(String realm)
Returns all remote policy enforcement point entities under the realm.
|
List |
getAllRemoteServiceProviderEntities(String realm)
Returns all remote service provider entities under the realm.
|
AttributeAuthorityConfigElement |
getAttributeAuthorityConfig(String realm,
String entityId)
Returns first attribute authority configuration in an entity under
the realm.
|
AttributeAuthorityDescriptorElement |
getAttributeAuthorityDescriptor(String realm,
String entityId)
Returns attribute authority descriptor in an entity under the
realm.
|
AttributeQueryConfigElement |
getAttributeQueryConfig(String realm,
String entityId)
Returns first attribute query configuration in an entity under
the realm.
|
AttributeQueryDescriptorElement |
getAttributeQueryDescriptor(String realm,
String entityId)
Returns attribute query descriptor in an entity under the
realm.
|
AuthnAuthorityConfigElement |
getAuthnAuthorityConfig(String realm,
String entityId)
Returns first authentication authority configuration in an entity under
the realm.
|
AuthnAuthorityDescriptorElement |
getAuthnAuthorityDescriptor(String realm,
String entityId)
Returns authentication authority descriptor in an entity under the
realm.
|
String |
getEntityByMetaAlias(String metaAlias)
Returns entity ID associated with the metaAlias.
|
EntityConfigElement |
getEntityConfig(String realm,
String entityId)
Returns extended entity configuration under the realm.
|
EntityDescriptorElement |
getEntityDescriptor(String realm,
String entityId)
Returns the standard metadata entity descriptor under the realm.
|
IDPSSOConfigElement |
getIDPSSOConfig(String realm,
String entityId)
Returns first identity provider's SSO configuration in an entity under
the realm.
|
IDPSSODescriptorElement |
getIDPSSODescriptor(String realm,
String entityId)
Returns first identity provider's SSO descriptor in an entity under the
realm.
|
XACMLPDPConfigElement |
getPolicyDecisionPointConfig(String realm,
String entityId)
Returns first policy decision point configuration in an entity under
the realm.
|
XACMLPDPDescriptorElement |
getPolicyDecisionPointDescriptor(String realm,
String entityId)
Returns first policy decision point descriptor in an entity under the
realm.
|
XACMLAuthzDecisionQueryConfigElement |
getPolicyEnforcementPointConfig(String realm,
String entityId)
Returns first policy enforcement point configuration in an entity under
the realm.
|
XACMLAuthzDecisionQueryDescriptorElement |
getPolicyEnforcementPointDescriptor(String realm,
String entityId)
Returns first policy enforcement point descriptor in an entity under the
realm.
|
String |
getRoleByMetaAlias(String metaAlias)
Returns role of an entity based on its metaAlias.
|
SPSSOConfigElement |
getSPSSOConfig(String realm,
String entityId)
Returns first service provider's SSO configuration in an entity under
the realm.
|
SPSSODescriptorElement |
getSPSSODescriptor(String realm,
String entityId)
Returns first service provider's SSO descriptor in an entity under the
realm.
|
boolean |
isTrustedProvider(String realm,
String entityId,
String trustedEntityId)
Determines whether two entities are in the same circle of trust
under the realm.
|
boolean |
isTrustedXACMLProvider(String realm,
String entityId,
String trustedEntityId,
String role)
Determines whether two entities are in the same circle of trust
under the realm.
|
void |
setEntityConfig(String realm,
EntityConfigElement config)
Sets the extended entity configuration under the realm.
|
void |
setEntityDescriptor(String realm,
EntityDescriptorElement descriptor)
Sets the standard metadata entity descriptor under the realm.
|
void |
validateMetaAliasForNewEntity(String realm,
List<String> newMetaAliases)
Checks that the provided metaAliases are valid for a new hosted entity in the specified realm.
|
public static final String NAME_META_ALIAS_IN_URI
public SAML2MetaManager() throws SAML2MetaException
SAML2MetaManager
.SAML2MetaException
- if unable to construct
SAML2MetaManager
public SAML2MetaManager(Object callerToken) throws SAML2MetaException
SAML2MetaManager
.callerToken
- session token for the caller.SAML2MetaException
- if unable to construct
SAML2MetaManager
public EntityDescriptorElement getEntityDescriptor(String realm, String entityId) throws SAML2MetaException
realm
- The realm under which the entity resides.entityId
- ID of the entity to be retrieved.EntityDescriptorElement
for the entity or null if
not found.SAML2MetaException
- if unable to retrieve the entity descriptor.public SPSSODescriptorElement getSPSSODescriptor(String realm, String entityId) throws SAML2MetaException
realm
- The realm under which the entity resides.entityId
- ID of the entity to be retrieved.SPSSODescriptorElement
for the entity or null if
not found.SAML2MetaException
- if unable to retrieve the first service
provider's SSO descriptor.public AttributeAuthorityDescriptorElement getAttributeAuthorityDescriptor(String realm, String entityId) throws SAML2MetaException
realm
- The realm under which the entity resides.entityId
- ID of the entity to be retrieved.AttributeAuthorityDescriptorElement
object for
the entity or null if not found.SAML2MetaException
- if unable to retrieve attribute authority
descriptor.public AttributeQueryDescriptorElement getAttributeQueryDescriptor(String realm, String entityId) throws SAML2MetaException
realm
- The realm under which the entity resides.entityId
- ID of the entity to be retrieved.AttributeQueryDescriptorElement
object for
the entity or null if not found.SAML2MetaException
- if unable to retrieve attribute query
descriptor.public AuthnAuthorityDescriptorElement getAuthnAuthorityDescriptor(String realm, String entityId) throws SAML2MetaException
realm
- The realm under which the entity resides.entityId
- ID of the entity to be retrieved.AuthnAuthorityDescriptorElement
object for
the entity or null if not found.SAML2MetaException
- if unable to retrieve authentication
authority descriptor.public XACMLPDPDescriptorElement getPolicyDecisionPointDescriptor(String realm, String entityId) throws SAML2MetaException
realm
- The realm under which the entity resides.entityId
- ID of the entity to be retrieved.SAML2MetaException
- if unable to retrieve the descriptor.public XACMLAuthzDecisionQueryDescriptorElement getPolicyEnforcementPointDescriptor(String realm, String entityId) throws SAML2MetaException
realm
- The realm under which the entity resides.entityId
- ID of the entity to be retrieved.SAML2MetaException
- if unable to retrieve the descriptor.public IDPSSODescriptorElement getIDPSSODescriptor(String realm, String entityId) throws SAML2MetaException
realm
- The realm under which the entity resides.entityId
- ID of the entity to be retrieved.IDPSSODescriptorElement
for the entity or null if
not found.SAML2MetaException
- if unable to retrieve the first identity
provider's SSO descriptor.public AffiliationDescriptorType getAffiliationDescriptor(String realm, String entityId) throws SAML2MetaException
realm
- The realm under which the entity resides.entityId
- ID of the entity to be retrieved.AffiliationDescriptorType
for the entity or
null if not found.SAML2MetaException
- if unable to retrieve the affiliation
descriptor.public void setEntityDescriptor(String realm, EntityDescriptorElement descriptor) throws SAML2MetaException
realm
- The realm under which the entity resides.descriptor
- The standard entity descriptor object to be set.SAML2MetaException
- if unable to set the entity descriptor.public void createEntityDescriptor(String realm, EntityDescriptorElement descriptor) throws SAML2MetaException
realm
- The realm under which the entity descriptor will be
created.descriptor
- The standard entity descriptor object to be created.SAML2MetaException
- if unable to create the entity descriptor.public void createEntity(String realm, EntityDescriptorElement descriptor, EntityConfigElement config) throws SAML2MetaException
realm
- The realm under which the entity descriptor will be
created.descriptor
- The standard entity descriptor object to be created.config
- The extended entity config object to be created.SAML2MetaException
- if unable to create the entity.public void deleteEntityDescriptor(String realm, String entityId) throws SAML2MetaException
realm
- The realm under which the entity resides.entityId
- The ID of the entity for whom the standard entity
descriptor will be deleted.SAML2MetaException
- if unable to delete the entity descriptor.public EntityConfigElement getEntityConfig(String realm, String entityId) throws SAML2MetaException
realm
- The realm under which the entity resides.entityId
- ID of the entity to be retrieved.EntityConfigElement
object for the entity or null
if not found.SAML2MetaException
- if unable to retrieve the entity
configuration.public SPSSOConfigElement getSPSSOConfig(String realm, String entityId) throws SAML2MetaException
realm
- The realm under which the entity resides.entityId
- ID of the entity to be retrieved.SPSSOConfigElement
for the entity or null if not
found.SAML2MetaException
- if unable to retrieve the first service
provider's SSO configuration.public XACMLPDPConfigElement getPolicyDecisionPointConfig(String realm, String entityId) throws SAML2MetaException
realm
- The realm under which the entity resides.entityId
- ID of the entity to be retrieved.SAML2MetaException
- if unable to retrieve the configuration.public XACMLAuthzDecisionQueryConfigElement getPolicyEnforcementPointConfig(String realm, String entityId) throws SAML2MetaException
realm
- The realm under which the entity resides.entityId
- ID of the entity to be retrieved.SAML2MetaException
- if unable to retrieve the configuration.public IDPSSOConfigElement getIDPSSOConfig(String realm, String entityId) throws SAML2MetaException
realm
- The realm under which the entity resides.entityId
- ID of the entity to be retrieved.IDPSSOConfigElement
for the entity or null if not
found.SAML2MetaException
- if unable to retrieve the first identity
provider's SSO configuration.public AttributeAuthorityConfigElement getAttributeAuthorityConfig(String realm, String entityId) throws SAML2MetaException
realm
- The realm under which the entity resides.entityId
- ID of the entity to be retrieved.AttributeAuthorityConfigElement
for the entity or
null if not found.SAML2MetaException
- if unable to retrieve the first attribute
authority configuration.public AttributeQueryConfigElement getAttributeQueryConfig(String realm, String entityId) throws SAML2MetaException
realm
- The realm under which the entity resides.entityId
- ID of the entity to be retrieved.AttributeQueryConfigElement
for the entity or
null if not found.SAML2MetaException
- if unable to retrieve the first attribute
query configuration.public AuthnAuthorityConfigElement getAuthnAuthorityConfig(String realm, String entityId) throws SAML2MetaException
realm
- The realm under which the entity resides.entityId
- ID of the entity to be retrieved.AuthnAuthorityConfigElement
for the entity or
null if not found.SAML2MetaException
- if unable to retrieve the first authentication
authority configuration.public AffiliationConfigElement getAffiliationConfig(String realm, String entityId) throws SAML2MetaException
realm
- The realm under which the entity resides.entityId
- ID of the entity to be retrieved.AffiliationConfigElement
for the entity or
null if not found.SAML2MetaException
- if unable to retrieve the affiliation
configuration.public void setEntityConfig(String realm, EntityConfigElement config) throws SAML2MetaException
realm
- The realm under which the entity resides.config
- The extended entity configuration object to be set.SAML2MetaException
- if unable to set the entity configuration.public void createEntityConfig(String realm, EntityConfigElement config) throws SAML2MetaException
realm
- The realm under which the entity configuration will be
created.config
- The extended entity configuration object to be created.SAML2MetaException
- if unable to create the entity configuration.public void deleteEntityConfig(String realm, String entityId) throws SAML2MetaException
realm
- The realm under which the entity resides.entityId
- The ID of the entity for whom the extended entity
configuration will be deleted.SAML2MetaException
- if unable to delete the entity descriptor.public List getAllHostedEntities(String realm) throws SAML2MetaException
realm
- The realm under which the hosted entities reside.List
of entity ID String
.SAML2MetaException
- if unable to retrieve the entity ids.public List getAllHostedServiceProviderEntities(String realm) throws SAML2MetaException
realm
- The realm under which the hosted service provider entities
reside.List
of entity ID String
.SAML2MetaException
- if unable to retrieve the entity ids.public List getAllHostedPolicyDecisionPointEntities(String realm) throws SAML2MetaException
realm
- The realm under which the hosted policy decision point
entities reside.SAML2MetaException
- if unable to retrieve the entity ids.public List getAllRemotePolicyDecisionPointEntities(String realm) throws SAML2MetaException
realm
- The realm under which the remote policy decision point
entities reside.SAML2MetaException
- if unable to retrieve the entity ids.public List getAllHostedPolicyEnforcementPointEntities(String realm) throws SAML2MetaException
realm
- The realm under which the hosted policy enforcement point
entities reside.SAML2MetaException
- if unable to retrieve the entity ids.public List getAllRemotePolicyEnforcementPointEntities(String realm) throws SAML2MetaException
realm
- The realm under which the remote policy enforcement point
entities reside.SAML2MetaException
- if unable to retrieve the entity ids.public List getAllHostedIdentityProviderEntities(String realm) throws SAML2MetaException
realm
- The realm under which the hosted identity provider entities
reside.List
of entity ID String
.SAML2MetaException
- if unable to retrieve the entity ids.public List getAllRemoteEntities(String realm) throws SAML2MetaException
realm
- The realm under which the hosted entities reside.List
of entity ID String
.SAML2MetaException
- if unable to retrieve the entity ids.public List getAllRemoteServiceProviderEntities(String realm) throws SAML2MetaException
realm
- The realm under which the remote service provider entities
reside.List
of entity ID String
.SAML2MetaException
- if unable to retrieve the entity ids.public List getAllRemoteIdentityProviderEntities(String realm) throws SAML2MetaException
realm
- The realm under which the remote identity provider entities
reside.List
of entity ID String
.SAML2MetaException
- if unable to retrieve the entity ids.public String getEntityByMetaAlias(String metaAlias) throws SAML2MetaException
metaAlias
- The metaAlias.SAML2MetaException
- if unable to retrieve the entity ids.public List<String> getAllHostedMetaAliasesByRealm(String realm) throws SAML2MetaException
realm
- The given realm.SAML2MetaException
- if unable to retrieve the entity ids.public String getRoleByMetaAlias(String metaAlias) throws SAML2MetaException
metaAlias
- Meta alias of the entity.SAML2Constants.IDP_ROLE
; or
SAML2Constants.SP_ROLE
or
SAML2Constants.UNKNOWN_ROLE
SAML2MetaException
- if there are issues in getting the entity
profile from the meta alias.public List getAllHostedIdentityProviderMetaAliases(String realm) throws SAML2MetaException
realm
- The realm under which the identity provider metaAliases
reside.List
of metaAliases String
.SAML2MetaException
- if unable to retrieve meta aliases.public List getAllHostedServiceProviderMetaAliases(String realm) throws SAML2MetaException
realm
- The realm under which the service provider metaAliases
reside.List
of metaAliases String
.SAML2MetaException
- if unable to retrieve meta aliases.public List getAllHostedPolicyDecisionPointMetaAliases(String realm) throws SAML2MetaException
realm
- The realm under which the policy decision point resides.SAML2MetaException
- if unable to retrieve meta aliases.public List getAllHostedPolicyEnforcementPointMetaAliases(String realm) throws SAML2MetaException
realm
- The realm under which the policy enforcement point resides.SAML2MetaException
- if unable to retrieve meta aliases.public boolean isTrustedProvider(String realm, String entityId, String trustedEntityId) throws SAML2MetaException
realm
- The realm under which the entity resides.entityId
- The ID of the entitytrustedEntityId
- The ID of the entitySAML2MetaException
- if unable to determine the trusted
relationship.public boolean isTrustedXACMLProvider(String realm, String entityId, String trustedEntityId, String role) throws SAML2MetaException
realm
- The realm under which the entity resides.entityId
- the hosted entity Identifier (PEP or PDP).trustedEntityId
- the remote entity identifier (PEP or PDP).role
- the role of the hosted entity.SAML2MetaException
- if unable to determine the trusted
relationship.public Set getAllEntities(String realm) throws SAML2MetaException
realm
- The realm under which the entities reside.Set
of entity ID String
.SAML2MetaException
- if unable to retrieve the entity ids.public void validateMetaAliasForNewEntity(String realm, List<String> newMetaAliases) throws SAML2MetaException
realm
- The realm in which we are validating the metaAliases.newMetaAliases
- values we are using to create the new metaAliases.SAML2MetaException
- if duplicate values found.Copyright © 2010–2025 Open Identity Platform Community. All rights reserved.