...
展開 |
---|
computedIdでの設定を下記に示します。 conf/saml-nameid.xml
<ref bean="shibboleth.SAML2PersistentGenerator" /> をアンコメントして有効にします。
コード ブロック |
---|
language | xml |
---|
title | conf/saml-nameid.xml |
---|
| <!-- Uncommenting this bean requires configuration in saml-nameid.properties. -->
<!-- -->
<ref bean="shibboleth.SAML2PersistentGenerator" />
<!-- --> |
conf/saml-nameid.properties
idp.persistentId.generator のデフォルトはComputedId の設定のため、idp.persistentId.sourceAttribute とidp.persistentId.salt のみを設定します。 コード ブロック |
---|
language | sass |
---|
title | conf/saml-nameid.properties |
---|
| # Set to shibboleth.StoredPersistentIdGenerator for db-backed storage
# and uncomment/name the PersistentIdStore bean to use
#idp.persistentId.generator = shibboleth.ComputedPersistentIdGenerator
# Otherwise for computed PersistentIDs set the source attribute and salt.
idp.persistentId.sourceAttribute = uid4persistentId
idp.persistentId.salt = changethistosomethingrandom |
conf/attribute-resolver.xml とconf/attribute-filter.xml
idp.persistentId.sourceAttribute の値をconf/attribute-resolver.xml の//resolver:AttributeDefinition で定義して、conf/attribute-filter.xml で送信設定を行います。
コード ブロック |
---|
language | xml |
---|
title | conf/attribute-resolver.xml |
---|
| <!-- ========================================== -->
<!-- PersistentId Definition -->
<!-- ========================================== -->
<!-- Attribute Definition for %{idp.persistentId.sourceAttribute} -->
<resolver:AttributeDefinition id="%{idp.persistentId.sourceAttribute}" xsi:type="ad:Simple"
sourceAttributeID="uid">
<resolver:Dependency ref="myLDAP" />
</resolver:AttributeDefinition> |
コード ブロック |
---|
language | xml |
---|
title | conf/attribute-filter.xml |
---|
| <!-- Release to anyone -->
<afp:AttributeFilterPolicy id="PolicyforAnyone">
<afp:PolicyRequirementRule xsi:type="basic:ANY" />
<afp:AttributeRule attributeID="%{idp.persistentId.sourceAttribute}">
<afp:PermitValueRule xsi:type="basic:ANY" />
</afp:AttributeRule>
</afp:AttributeFilterPolicy> |
conf/intercept/consent-intercept-config.xml ユーザ同意画面にて%{idp.persistentId.sourceAttribute} を表示しないように、//util:list[@id="shibboleth.consent.attribute-release.BlacklistedAttributeIDs"] に%{idp.persistentId.sourceAttribute} を追加します。
コード ブロック |
---|
language | xml |
---|
title | conf/intercept/consent-intercept-config.xml |
---|
| <util:list id="shibboleth.consent.attribute-release.BlacklistedAttributeIDs">
<value>transientId</value>
<value>persistentId</value>
<value>eduPersonTargetedID</value>
<value>%{idp.persistentId.sourceAttribute}</value>
</util:list> |
|
storedId
...
...
storedIdでの設定を下記に示します。
Shibboleth IdP 3.
...
1の情報
storedIdでの設定を下記に示します。
...
をアンコメントして有効にします。
コード ブロック |
---|
language | xml |
---|
title | conf/aml-nameid.xml |
---|
|
|
...
...
...
...
...
<!-- Use this file to define any custom beans needed globally. -->
<bean id="MyDataSource"
class="org.apache.tomcat.dbcp.dbcp.BasicDataSource"
p:driverClassName="com.mysql.jdbc.Driver"
p:url="jdbc:mysql://localhost:3306/shibboleth"
p:username="username"
p:password="password"
p:maxActive="10"
p:maxIdle="5"
p:maxWait="15000"
p:testOnBorrow="true"
p:validationQuery="select 1"
p:validationQueryTimeout="5" />
<bean id="PersistentIdStore"
class="net.shibboleth.idp.saml.nameid.impl.JDBCPersistentIdStore"
p:dataSource-ref="MyDataSource" /> |
コード ブロック |
---|
language | xml |
---|
title | conf/global.xml (Tomcat 8の場合) |
---|
|
|
...
...
<!-- Use this file to define any custom beans needed globally. -->
<bean id="MyDataSource"
class="org.apache.tomcat.dbcp.dbcp2.BasicDataSource"
p:driverClassName="com.mysql.jdbc.Driver"
p:url="jdbc:mysql://localhost:3306/shibboleth"
p:username="username"
p:password="password"
p:maxIdle="5"
p:maxTotal="10"
p:maxWaitMillis="15000"
p:testOnBorrow="true"
p:validationQuery="select 1"
p:validationQueryTimeout="5" />
<bean id="PersistentIdStore"
class="net.shibboleth.idp.saml.nameid.impl.JDBCPersistentIdStore"
p:dataSource-ref="MyDataSource" /> |
情報 |
---|
Tomcat 8付属のDBCP2から、p:maxActive はp:maxTotal に、p:maxWait はp:maxWaitMillis に変更になりました。 |
conf/attribute-resolver.
|
...
...
...
<!-- ========================================== -->
<!-- PersistentId Definition -->
<!-- ========================================== -->
<!-- Attribute Definition for %{idp.persistentId.sourceAttribute} -->
<resolver:AttributeDefinition id="%{idp.persistentId.sourceAttribute}" xsi:type="ad:Simple"
sourceAttributeID="uid">
<resolver:Dependency ref="myLDAP" />
</resolver:AttributeDefinition> |
コード ブロック |
---|
language | xml |
---|
title | conf/attribute-filter.xml |
---|
|
|
...
...
| <util:list id="shibboleth.consent.attribute-release.BlacklistedAttributeIDs">
<value>transientId</value>
<value>persistentId</value>
<value>eduPersonTargetedID</value>
<value>%{idp.persistentId.sourceAttribute}</value>
</util:list> |
|
eduPersonTargetedID 属性の送信
...
conf/attribute-resolver.xml
展開 |
---|
コード ブロック |
---|
language | xml |
---|
title | conf/attribute-resolver.xml |
---|
| <!-- ========================================== -->
<!-- Data Connectors -->
<!-- ========================================== -->
<!-- Computed targeted ID connector -->
<resolver:DataConnector xsi:type="ComputedId" xmlns="urn:mace:shibboleth:2.0:resolver:dc"
id="computedID"
generatedAttributeID="computedID"
sourceAttributeID="%{idp.persistentId.sourceAttribute}"
salt="%{idp.persistentId.salt}">
<resolver:Dependency ref="%{idp.persistentId.sourceAttribute}" />
</resolver:DataConnector> |
注意 |
---|
Shibboleth IdP 3.1.2では、salt 属性は%{idp.persistentId.salt} で置き換えられませんので、ご注意ください。[IDP-771] |
|
storedId
storedIdでの設定を下記に示します。Shibboleth IdP 2と同じ設定で送信可能です。
...