Last active
April 18, 2023 16:40
-
-
Save trscavo/551e257c3ea59a454e9f3c9aa87ea2bc to your computer and use it in GitHub Desktop.
Extract an entity descriptor from a SAML metadata aggregate
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="UTF-8"?> | |
<!-- | |
extract_entity.xsl | |
An XSL transform that takes a SAML V2.0 metadata file and | |
extracts a single entity descriptor. | |
--> | |
<xsl:stylesheet version="1.0" | |
xmlns:xsl="http://www.w3.org/1999/XSL/Transform" | |
xmlns:md="urn:oasis:names:tc:SAML:2.0:metadata"> | |
<xsl:param name="entityID" required="yes"/> | |
<xsl:template match="/"> | |
<xsl:copy-of select="/md:EntitiesDescriptor/md:EntityDescriptor[@entityID=$entityID]"/> | |
</xsl:template> | |
</xsl:stylesheet> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Thank you. This is very helpful.