Módosítások

Shib2IdpARP

4 079 bájt hozzáadva, 2008. október 15., 11:02
Kiadási szabálycsoportok megadása
== Kiadási szabálycsoportok megadása ==
Egy kiadási szabályt szabálycsoportot a <code><AttributeFilterPolicy></code> elemmel definiálhatunk, melynek kötelező aleleme egy <code><PolicyRequirementRule xsi:type="MATCHING_RULE_TYPE"></code> elem, amely meghatározza, hogy a szabály mely attribútumok esetén aktivizálódjon. A működése kifejezetten egyszerű, a kiadási szabály akkor lesz aktív, mikor a <code>PolicyRequirementRule</code> elem attribútumában meghatározott egyezési feltétel igaz értéket ad.
Egy kiadási szabálycsoport (attribute filters) meghatározhatja egy sor attribútum számára, hogy mikor, milyen feltételek teljesülése mellett adhatók ki értékeik.
=== Egy kiadási szabály megadása ===
 
Egy attribútumra vonatkozó szabályt a <code><AttributeRule></code> elemmel határozunk meg, melynek kötelező attrubútuma annak az attribútumnak az azonosítója, melyre a szabályokat vonatkoztatni szeretnénk, és egy elem, amely meghatározza, hogy milyen illeszkedés esetében aktív a szabály.
 
 
''Példa I.''
 
<source lang="xml">
 
<AttributeRule attributeID="transientId">
<PermitValueRule xsi:type="basic:ANY" />
</AttributeRule>
 
</source>
 
Egy attribútumra vonatkozó szabályban természetesen további finomításokat megadhatunk.
 
''Példa II.''
 
 
<source lang="xml">
 
<AttributeRule attributeID="eduPersonAffiliation">
<PermitValueRule xsi:type="basic:OR">
<Rule xsi:type="basic:AttributeValueString" value="faculty" ignoreCase="true"/>
<Rule xsi:type="basic:AttributeValueString" value="student" ignoreCase="true"/>
<Rule xsi:type="basic:AttributeValueString" value="staff" ignoreCase="true"/>
<Rule xsi:type="basic:AttributeValueString" value="alum" ignoreCase="true"/>
<Rule xsi:type="basic:AttributeValueString" value="member" ignoreCase="true"/>
<Rule xsi:type="basic:AttributeValueString" value="affiliate" ignoreCase="true"/>
<Rule xsi:type="basic:AttributeValueString" value="employee" ignoreCase="true"/>
<Rule xsi:type="basic:AttributeValueString" value="library-walk-in" ignoreCase="true"/>
</PermitValueRule>
</AttributeRule>
 
</source>
 
Magyarázat: a kiadási szabály, akkor adja ki az <code>eduPersonAffiliation</code> attribútumot, amennyiben annak értéke egyezik a felsoroltak valamelyikével (<code>OR</code> szabály - tehát elég, hogy egyikkel egyezzen).
 
Az alábbi listában található egyezési szabályok alkalmazhatók egy-egy <code><PermitValueRule></code> megadásakor:
* ANY - Always evaluates to true
* AND - Evaluates to true if all contained rules are true
* OR - Evaluated to true if any contained rule is true
* NOT - Evaluates to true if the contained rule evaluates to false
* AttributeRequesterString - Evaluates to true if the attribute requester's entity ID matches a given string
* AttributeIssuerString - Evaluates to true if the attribute issuer's entity ID matches a given string
* PrincipalNameString - Evaluates to true if the user's principal name matches a given string
* AuthenticationMethodString - Evaluates to true if the method used to authenticate the user matches a given string
* AttributeValueString - Evaluates to true if the value of a given attribute matches a given string
* AttributeScopeString - Evaluates to the true if the scope of a value of a given attribute matches a given string
* AttributeRequesterRegex - Evaluates to true if the attribute requester's entity ID matches a given regular expression
* AttributeIssuerRegex - Evaluates to true if the attribute issuer's entity ID matches a given regular expression
* PrincipalNameRegex - Evaluates to true if the user's principal name matches a given regular expression
* AuthenticationMethodRegex - Evaluates to true if the method used to authenticate the user matches a given regular expression
* AttributeValueRegex - Evaluates to true if the value of a given attribute matches a given regular expression
* AttributeScopeRegex - Evaluates to the true if the scope of a value of a given attribute matches a given regular expression
* Script - Evaluates a scriptlet to determine if the rule evaluates to true
* AttributeRequesterInEntityGroup - Evaluates to true if the attribute requester is defined within a given entity group in SAML metadata
* AttributeIssuerInEntityGroup - Evaluates to true if the attribute issuer is defined within a given entity group in SAML metadata
* AttributeScopeMatchesShibMDScope - Evaluates to true the scope of an attribute value matches the scope defined in the attribute issuer's metadata.

Navigációs menü