Skip to content

Commit

Permalink
Add SDSS Policy label to all entities. Discard this label in SDSS Fed…
Browse files Browse the repository at this point in the history
…eration metadata. Make SDSS/UK Federation threshold at 200 per UKFTS 1.0pre.
  • Loading branch information
iay committed Nov 22, 2006
1 parent 9e173a4 commit a3d0433
Showing 1 changed file with 23 additions and 4 deletions.
27 changes: 23 additions & 4 deletions build/master_sdss.xsl
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
Author: Ian A. Young <ian@iay.org.uk>
$Id: master_sdss.xsl,v 1.4 2006/11/15 16:10:06 iay Exp $
$Id: master_sdss.xsl,v 1.5 2006/11/22 22:21:10 iay Exp $
-->
<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
Expand All @@ -19,14 +19,15 @@
xmlns:md="urn:oasis:names:tc:SAML:2.0:metadata"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:wayf="http://sdss.ac.uk/2006/06/WAYF"
xmlns:uklabel="http://ukfederation.org.uk/2006/11/label"
xmlns="urn:oasis:names:tc:SAML:2.0:metadata"
exclude-result-prefixes="wayf">
exclude-result-prefixes="wayf uklabel">

<!--
Version information for this file. Remember to peel off the dollar signs
before dropping the text into another versioned file.
-->
<xsl:param name="cvsId">$Id: master_sdss.xsl,v 1.4 2006/11/15 16:10:06 iay Exp $</xsl:param>
<xsl:param name="cvsId">$Id: master_sdss.xsl,v 1.5 2006/11/22 22:21:10 iay Exp $</xsl:param>

<!--
Add a comment to the start of the output file.
Expand Down Expand Up @@ -77,10 +78,28 @@
<!--
Drop any entities defined after the UK Federation went live.
-->
<xsl:template match="md:EntityDescriptor[number(substring-after(@ID, 'uk'))>=1000]">
<xsl:template match="md:EntityDescriptor[number(substring-after(@ID, 'uk'))>=200]">
<!-- nothing -->
</xsl:template>

<!--
Drop UK Federation SDSS policy labels; not relevant to SDSS Federation users.
-->
<xsl:template match="md:EntityDescriptor/md:Extensions">
<xsl:variable name="otherExtensions" select="*[local-name()!='SDSSPolicy']"/>
<xsl:choose>
<xsl:when test="count($otherExtensions)=0">
<!-- nothing -->
</xsl:when>
<xsl:otherwise>
<Extensions>
<xsl:apply-templates
select="text()|comment()|*[local-name()!='SDSSPolicy']"/>
</Extensions>
</xsl:otherwise>
</xsl:choose>
</xsl:template>

<!--By default, copy text blocks, comments and attributes unchanged.-->
<xsl:template match="text()|comment()|@*">
<xsl:copy/>
Expand Down

0 comments on commit a3d0433

Please sign in to comment.