仕様
名称 | eduPersonAffiliation |
概要 | 利用者の職種等を表します。 |
参照スキーマ | eduPerson Object Class Specification (200806) |
name【Shib1.3】 | "urn:mace:dir:attribute-def:eduPersonAffiliation" |
name【Shib2.x】 | "urn:oid:1.3.6.1.4.1.5923.1.1.1.1" |
friendlyName | eduPersonAffiliation |
属性値or形式 | "faculty","staff","student","member",無し(空白) |
照合順序 | caseIgnoreMatch |
複数値 | 複数値 |
説明等 | 利用者の職位として,5つの値が利用可能です。IdPサイトでは,組織内の実際の詳細職位とのマッピングが必要です。また,利用できる値は,「卒業生」等,必要に応じて追加を検討します。 |
※ なお,SPに対して複数の値が送られてきた場合,Shibbolethでは";"を用いて結合された文字列がアプリケーションに渡されます(例:"staff;member")。
属性定義の例:その1 (attribute-resolver.xml)
LDAPにfaculty/staff等の値がダイレクトに格納されている場合
パネル | ||||||
---|---|---|---|---|---|---|
| ||||||
<!-- Attribute Definition for eduPersonAffiliation -->
<resolver:AttributeDefinition id="eduPersonAffiliation" xsi:type="Simple" xmlns="urn:mace:shibboleth:2.0:resolver:ad"
sourceAttributeID="eduPersonAffiliation">
<resolver:Dependency ref="myLDAP" />
<resolver:AttributeEncoder xsi:type="SAML1String" xmlns="urn:mace:shibboleth:2.0:attribute:encoder"
name="urn:mace:dir:attribute-def:eduPersonAffiliation" />
<resolver:AttributeEncoder xsi:type="SAML2String" xmlns="urn:mace:shibboleth:2.0:attribute:encoder"
name="urn:oid:1.3.6.1.4.1.5923.1.1.1.1" friendlyName="eduPersonAffiliation" />
</resolver:AttributeDefinition>
|
属性定義の例:その2 (attribute-resolver.xml)
他の属性値からeduPersonAffiliationを生成する場合
パネル | ||||||
---|---|---|---|---|---|---|
| ||||||
<resolver:AttributeDefinition id="eduPersonAffiliation" xsi:type="Script" xmlns="urn:mace:shibboleth:2.0:resolver:ad" sourceAttributeID="ソースとなる属性">
<resolver:Dependency ref="myLDAP" />
<resolver:AttributeEncoder xsi:type="SAML1String" xmlns="urn:mace:shibboleth:2.0:attribute:encoder"
name="urn:mace:dir:attribute-def:eduPersonAffiliation" />
<resolver:AttributeEncoder xsi:type="SAML2String" xmlns="urn:mace:shibboleth:2.0:attribute:encoder"
name="urn:oid:1.3.6.1.4.1.5923.1.1.1.1" friendlyName="eduPersonAffiliation" />
<Script>
<![CDATA[
importPackage(Packages.edu.internet2.middleware.shibboleth.common.attribute.provider);
// Create attribute to be returned from definition
eduPersonAffiliation = new BasicAttribute("eduPersonAffiliation");
// faculty
if (条件マッチ) {
eduPersonAffiliation.getValues().add("faculty");
}
// staff
if (条件マッチ) {
eduPersonAffiliation.getValues().add("staff");
}
// student
if (条件マッチ) {
eduPersonAffiliation.getValues().add("student");
}
// adding member
eduPersonAffiliation.getValues().add("member");
]]>
</Script>
</resolver:AttributeDefinition> |