Dies ist eine alte Version des Dokuments!


Attribute Filter Konfiguration - Beispiele

Änderung in attribute-filter.xml gegenüber IdP 2.x

  • Syntax vereinfacht (u.a. nur noch ein Namespace)
  • Filtern von NameIDs (transientID und persistentID) enfällt.

Zum grundlegenden Verständnis des Zusammenspiels von Attributgenerierung, Weitergabe und Verarbeitung siehe die Präsentation vom 13. DFN-AAI-Workshop.

Siehe auch Dokumentation im Shibboleth Wiki

Beispiele für Shibboleth IdP 2.4.x finden sich in der alten Online-Dokumentation.

Ausführliches Beispiel, das alle Eventualitäten abdecken sollte:

/opt/shibboleth-idp/conf/attribute-filter.xml
    <AttributeFilterPolicy id="releaseToCoCo">
 
       <PolicyRequirementRule 
               xsi:type="EntityAttributeExactMatch"
               attributeName="http://macedir.org/entity-category"
               attributeValue="http://www.geant.net/uri/dataprotection-code-of-conduct/v1" />
 
       <!--onlyIfRequired="true" kann hier weggelassen werden, da ab IdPv3.2 Default--> 
 
       <AttributeRule attributeID="displayName">
          <PermitValueRule xsi:type="AttributeInMetadata"/>
       </AttributeRule>
 
       <AttributeRule attributeID="eduPersonScopedAffiliation">
          <PermitValueRule xsi:type="AttributeInMetadata"/>
       </AttributeRule>
 
       <AttributeRule attributeID="eduPersonAffiliation">
          <PermitValueRule xsi:type="AttributeInMetadata"/>
       </AttributeRule>
 
       <AttributeRule attributeID="mail">
          <PermitValueRule xsi:type="AttributeInMetadata"/>
       </AttributeRule>
 
       <AttributeRule attributeID="cn">
         <PermitValueRule xsi:type="AttributeInMetadata"/>
       </AttributeRule>
 
       <AttributeRule attributeID="givenName">
         <PermitValueRule xsi:type="AttributeInMetadata"/>
       </AttributeRule>
 
       <AttributeRule attributeID="sn">
          <PermitValueRule xsi:type="AttributeInMetadata"/>
       </AttributeRule>
 
       <AttributeRule attributeID="eduPersonPrincipalName">
          <PermitValueRule xsi:type="AttributeInMetadata"/>
       </AttributeRule>
 
       <AttributeRule attributeID="schacHomeOrganization">
         <PermitValueRule xsi:type="AttributeInMetadata"/>
       </AttributeRule>
 
       <AttributeRule attributeID="schacHomeOrganizationType">
          <PermitValueRule xsi:type="AttributeInMetadata"/>
       </AttributeRule>
 
       <AttributeRule attributeID="eduPersonTargetedID">
          <PermitValueRule xsi:type="AttributeInMetadata"/>
       </AttributeRule>
 
       <AttributeRule attributeID="o">
          <PermitValueRule xsi:type="AttributeInMetadata"/>
       </AttributeRule>
 
</AttributeFilterPolicy>
/opt/shibboleth-idp/conf/attribute-filter.xml
    <AttributeFilterPolicy id="releaseEverythingToClarin">
        <PolicyRequirementRule xsi:type="AND">
           <Rule xsi:type="EntityAttributeExactMatch"
                 attributeName="http://macedir.org/entity-category"
                 attributeValue="http://clarin.eu/category/clarin-member" />
           <!--
               wer sichergehen will, dass nur SPs bedient werden, die europäischen 
               Datenschutzrichtlinien genügen, nimmt noch den Code-of-Conduct dazu
               (https://www.aai.dfn.de/der-dienst/datenschutz/data-protection-code-of-conduct/)
           -->
           <Rule xsi:type="EntityAttributeExactMatch"
                 attributeName="http://macedir.org/entity-category"
                 attributeValue="http://www.geant.net/uri/dataprotection-code-of-conduct/v1" />
        </PolicyRequirementRule>
 
        <AttributeRule attributeID="eduPersonAffiliation">
           <!--onlyIfRequired="true" kann hier weggelassen werden, da ab IdPv3.2 Default-->
           <PermitValueRule xsi:type="AttributeInMetadata"/>
        </AttributeRule>
 
        <!-- entweder eduPersonPrincipalName *oder* eduPersonTargetedID-->
        <AttributeRule attributeID="eduPersonPrincipalName">
           <PermitValueRule xsi:type="AttributeInMetadata"/>
        </AttributeRule>
 
        <AttributeRule attributeID="eduPersonTargetedID">
           <PermitValueRule xsi:type="AttributeInMetadata"/>
        </AttributeRule>
 
        <AttributeRule attributeID="sn">
           <PermitValueRule xsi:type="AttributeInMetadata"/>
        </AttributeRule>
 
        <!-- einige SPs verlangen 'cn', andere 'displayName' -->
 
        <AttributeRule attributeID="cn">
           <PermitValueRule xsi:type="AttributeInMetadata"/>
        </AttributeRule>
 
        <AttributeRule attributeID="displayName">
           <PermitValueRule xsi:type="AttributeInMetadata"/>
        </AttributeRule>
 
        <AttributeRule attributeID="mail">
           <PermitValueRule xsi:type="AttributeInMetadata"/>
        </AttributeRule>
 
        <!-- einige SPs verlangen 'o', andere 'schacHomeOrganization' -->
 
        <AttributeRule attributeID="o">
           <PermitValueRule xsi:type="AttributeInMetadata"/>
        </AttributeRule>
 
        <AttributeRule attributeID="schacHomeOrganization">
           <PermitValueRule xsi:type="AttributeInMetadata"/>
        </AttributeRule>
 
        <AttributeRule attributeID="schacHomeOrganizationType">
           <PermitValueRule xsi:type="AttributeInMetadata"/>
        </AttributeRule>
 
</AttributeFilterPolicy>
/opt/shibboleth-idp/conf/attribute-filter.xml
<AttributeFilterPolicy id="releaseToRandS">
 
   <PolicyRequirementRule 
           xsi:type="EntityAttributeExactMatch"
           attributeName="http://macedir.org/entity-category"
           attributeValue="http://refeds.org/category/research-and-scholarship" />
 
   <AttributeRule attributeID="eduPersonScopedAffiliation">
       <PermitValueRule xsi:type="ANY"/>
   </AttributeRule>
 
   <!-- falls eduPersonPrincipalName neu vergeben werden kann,
        muss  eduPersonTargetedID mit uebertragen werden -->
   <AttributeRule attributeID="eduPersonPrincipalName">
      <PermitValueRule xsi:type="ANY"/>
   </AttributeRule>
 
   <AttributeRule attributeID="eduPersonTargetedID">
      <PermitValueRule xsi:type="ANY"/>
   </AttributeRule>
 
   <!-- entweder sn + givenName oder displayName -->
   <AttributeRule attributeID="givenName">
      <PermitValueRule xsi:type="ANY"/>
   </AttributeRule>
 
   <AttributeRule attributeID="sn">
      <PermitValueRule xsi:type="ANY"/>
   </AttributeRule>
 
   <AttributeRule attributeID="displayName">
      <PermitValueRule xsi:type="ANY"/>
   </AttributeRule>
 
   <AttributeRule attributeID="mail">
      <PermitValueRule xsi:type="ANY"/>
   </AttributeRule>
 
</AttributeFilterPolicy>

ELIXIR ist eine Forschungsinfrastruktur für Daten aus dem Bereich Life Science (v.a. Genom-Datenbanken). Weiterführende Informationen finden sich auf der Homepage des Projekts unter http://www.elixir-europe.org/ und in dem hier verlinkten Anschreiben.

Der Zugang zu den ELIXIR Diensten erfolgt über einen SP Proxy (Entity ID: https://login.elixir-czech.org/proxy/), der über eduGAIN verfügbar ist.

Benötigte Attribute (+ NameID):

  • Persistent NameID / eduPersonPrincipalName / eduPersonTargetedID
  • eduPersonAffiliation / eduPersonScopedAffiliation (von besonderer Relevanz ist der Wert „faculty“)
  • schacHomeOrganization

Dieser Service Provider (und die dahinter liegenden Dienste) verpflichtet sich dem GÉANT Data Protection Code of Conduct for Service Providers in EU/EEA (siehe oben). Falls hierfür bereits eine Filter Policy nach dem angeführten Beispiel implementiert ist, sollte der Zugriff auf die ELIXIR Dienste ohne zusätzliche Maßnahmen funktionieren.

Ob alle benötigten Angaben übertragen werden, lässt sich anhand dieses Attribute Checks überprüfen:

https://perun.elixir-czech.cz/attribute-check/

Hier noch ein Beispiel für eine dienstspezifische Attribute Filter Policy (zu Persistent NameID vs. eduPersonTargetedID siehe hier):

/opt/shibboleth-idp/conf/attribute-filter.xml
<AttributeFilterPolicy id="elixir">
   <PolicyRequirementRule xsi:type="Requester" value="https://login.elixir-czech.org/proxy/" />
 
   <AttributeRule attributeID="schacHomeOrganization" permitAny="true"/>
   <AttributeRule attributeID="eduPersonScopedAffiliation" permitAny="true"/>
   <!-- nur wenn keine Persistent NameID üertragen wird -->
   <AttributeRule attributeID="eduPersonTargetedID" permitAny="true"/>
 
</AttributeFilterPolicy>
  • Zuletzt geändert: vor 7 Jahren