-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Inject the UK federation trust roots in the aggregator version of the…
… UK federation collect flow.
- Loading branch information
Showing
3 changed files
with
100 additions
and
0 deletions.
There are no files selected for viewing
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,60 @@ | ||
| <?xml version="1.0" encoding="UTF-8"?> | ||
| <!-- | ||
| trust_roots.xsl | ||
| XSL stylesheet that adds the UK federation's trust roots in to an | ||
| EntitiesDescriptor aggregate. | ||
| --> | ||
| <xsl:stylesheet version="1.0" | ||
| xmlns:md="urn:oasis:names:tc:SAML:2.0:metadata" | ||
|
|
||
| xmlns="urn:oasis:names:tc:SAML:2.0:metadata" | ||
| xmlns:xsl="http://www.w3.org/1999/XSL/Transform" | ||
| exclude-result-prefixes="md"> | ||
|
|
||
| <!--Force UTF-8 encoding for the output.--> | ||
| <xsl:output omit-xml-declaration="no" method="xml" encoding="UTF-8" indent="yes"/> | ||
|
|
||
| <!-- | ||
| The key authorities document is passed in as a parmeter. This is an EntitiesDescriptor | ||
| with the KeyAuthority list as a child Extensions element. | ||
| --> | ||
| <xsl:param name="trustRootsDocument"/> | ||
|
|
||
| <!-- | ||
| Inject the key authorities into the document EntitiesDescriptor element. | ||
| --> | ||
| <xsl:template match="/md:EntitiesDescriptor"> | ||
| <xsl:copy> | ||
| <xsl:text> </xsl:text> | ||
| <xsl:apply-templates select="$trustRootsDocument//md:Extensions"/> | ||
| <xsl:text> </xsl:text> | ||
| <xsl:apply-templates/> | ||
| </xsl:copy> | ||
| </xsl:template> | ||
|
|
||
|
|
||
| <!-- | ||
| ********************************************* | ||
| *** *** | ||
| *** D E F A U L T T E M P L A T E S *** | ||
| *** *** | ||
| ********************************************* | ||
| --> | ||
|
|
||
|
|
||
| <!--By default, copy text blocks, comments and attributes unchanged.--> | ||
| <xsl:template match="text()|comment()|@*"> | ||
| <xsl:copy/> | ||
| </xsl:template> | ||
|
|
||
| <!--By default, copy all elements from the input to the output, along with their attributes and contents.--> | ||
| <xsl:template match="*"> | ||
| <xsl:copy> | ||
| <xsl:apply-templates select="node()|@*"/> | ||
| </xsl:copy> | ||
| </xsl:template> | ||
|
|
||
| </xsl:stylesheet> |
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
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