Class SAMLSupport

java.lang.Object
net.shibboleth.metadata.dom.saml.SAMLSupport

@ThreadSafe public final class SAMLSupport extends Object
Helper class for dealing with SAML documents.
Since:
0.9.0
  • Field Details

    • SAML_NS

      @Nonnull public static final String SAML_NS
      Namespace URI for SAML elements.
      See Also:
    • SAML_PREFIX

      @Nonnull public static final String SAML_PREFIX
      Conventional prefix for SAML elements.
      See Also:
    • ATTRIBUTE_NAME

      @Nonnull public static final QName ATTRIBUTE_NAME
      saml:Attribute element.
    • ATTRNAME_FORMAT_UNSPECIFIED

      @Nonnull public static final String ATTRNAME_FORMAT_UNSPECIFIED
      Unspecified default NameFormat value for Attribute elements.
      See Also:
    • ATTRIBUTE_VALUE_NAME

      @Nonnull public static final QName ATTRIBUTE_VALUE_NAME
      saml:AttributeValue element.
    • EXTENSIONS_MATCHER

      @Nonnull public static final ElementMatcher EXTENSIONS_MATCHER
      Matcher for the Extensions element, for use with the Container system.
      Since:
      0.10.0
    • EXTENSIONS_MAKER

      @Nonnull public static final ElementMaker EXTENSIONS_MAKER
      Maker for the Extensions element, for use with the Container system.
      Since:
      0.10.0
  • Constructor Details

    • SAMLSupport

      private SAMLSupport()
      Constructor.
  • Method Details

    • ancestorEntity

      @Nullable private static Element ancestorEntity(@Nonnull Element element)
      Returns the Element representing the EntityDescriptor which is the closest-containing ancestor of the given element.
      Parameters:
      element - Element to locate the ancestor Entity of.
      Returns:
      ancestor EntityDescriptor Element, or null.
    • errorPrefix

      @Nonnull public static String errorPrefix(@Nonnull Element element)
      Computes an entity-specific prefix to be put in front of a message.
      Parameters:
      element - Element forming the context for the prefix
      Returns:
      a prefix for the error message
    • extractAttributeNameFormat

      @Nonnull public static String extractAttributeNameFormat(@Nonnull Element attribute)
      Extract an Attribute element's NameFormat, applying the SAML standard's specified default if the XML attribute is not present.
      Parameters:
      attribute - Attribute Element
      Returns:
      NameFormat value, or the "unspecified" default