比較バージョン

キー

  • この行は追加されました。
  • この行は削除されました。
  • 書式設定が変更されました。

...

IDの追加方法

以下の利用者をLDAPへ登録する例を示します。

uiduserPasswordoueduPersonAffiliation
test004test004technologystudent

1. ldifファイル(sample1.ldif)の作成

パネル
borderColor#cccccc
bgColor#eeeeee
borderStylesolid
dn: ou=technology,o=test_o,dc=ac,c=JP
objectClass: organizationalUnit
ou: technology

# test004, technology, test_o, ac, JP
dn: uid=test004,ou=technology,o=test_o,dc=ac,c=JP
objectClass: eduPerson
objectClass: inetOrgPerson
ou: technology
sn: test_sn_4
cn: test_cn_4
uid: test004
userPassword: test004
eduPersonAffiliation: student  

 


2. 上記1のldifファイルを用いた登録

パネル
borderColor#cccccc
bgColor#eeeeee
borderStylesolid
# ldapadd -x -h localhost -D "cn=olmgr,o=test_o,dc=ac,c=JP" -w csildap -f sample1.ldif

...

パネル
borderColor#cccccc
bgColor#eeeeee
borderStylesolid
dn: uid=test004,ou=technology,o=test_o,dc=ac,c=JP
changetype: modify
add: displayName
displayName: Test4

...


2. 上記1のldifファイルを用いた登録

パネル
borderColor#cccccc
bgColor#eeeeee
borderStylesolid
# ldapmodify -x -h localhost -D "cn=olmgr,o=test_o,dc=ac,c=JP" -w csildap -f sample2.ldif

...

パネル
borderColor#cccccc
bgColor#eeeeee
borderStylesolid
(中略)
# displayName
# When displaying an entry, especially within a one-line summary list, it 
# is useful to be able to identify a name to be used. Since other attri-
# bute types such as 'cn' are multivalued, an additional attribute type is
# needed. Display name is defined for this purpose. attributetype ( 2.16.840.1.113730.3.1.241 NAME 'displayName' DESC 'RFC2798: preferred name to be used when displaying entries' EQUALITY caseIgnoreMatch SUBSTR caseIgnoreSubstringsMatch SYNTAX 1.3.6.1.4.1.1466.115.121.1.15 SINGLE-VALUE ) (中略)

...


2. /opt/shibboleth-idp/conf/attribute-resolver.xmlへの登録

パネル
borderColor#cccccc
bgColor#eeeeee
borderStylesolid
<resolver:AttributeResolver
       xmlns:resolver="urn:mace:shibboleth:2.0:resolver"
        xmlns:pc="urn:mace:shibboleth:2.0:resolver:pc"
        xmlns:ad="urn:mace:shibboleth:2.0:resolver:ad"
        xmlns:dc="urn:mace:shibboleth:2.0:resolver:dc"
        xmlns:enc="urn:mace:shibboleth:2.0:attribute:encoder"
        xmlns:sec="urn:mace:shibboleth:2.0:security"
        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
        xsi:schemaLocation="urn:mace:shibboleth:2.0:resolver http://shibboleth.net/schema/idp/shibboleth-attribute-resolver.xsd
                            urn:mace:shibboleth:2.0:resolver:pc http://shibboleth.net/schema/idp/shibboleth-attribute-resolver-pc.xsd
                            urn:mace:shibboleth:2.0:resolver:ad http://shibboleth.net/schema/idp/shibboleth-attribute-resolver-ad.xsd
                            urn:mace:shibboleth:2.0:resolver:dc http://shibboleth.net/schema/idp/shibboleth-attribute-resolver-dc.xsd
                            urn:mace:shibboleth:2.0:attribute:encoder http://shibboleth.net/schema/idp/shibboleth-attribute-encoder.xsd
                            urn:mace:shibboleth:2.0:security http://shibboleth.net/schema/idp/shibboleth-security.xsd">
(中略)

   

<resolver:AttributeDefinition

<AttributeDefinition xsi:type="

ad:

Simple"

id

="displayName" sourceAttributeID

="displayName">
       

<resolver:Dependency

<InputDataConnector ref="myLDAP" attributeNames="displayName"

/>

        <resolver:AttributeEncoder<AttributeEncoder xsi:type="enc:SAML1String" name="urn:mace:dir:attribute-def:displayName" encodeType="false" />
        <resolver:AttributeEncoder<AttributeEncoder xsi:type="enc:SAML2String" name="urn:oid:2.16.840.1.113730.3.1.241" friendlyName="displayName" encodeType="false" />
    </resolver:AttributeDefinition> "displayName" の AttributeDefinition を追加(SAML2Stringのnameでは1.で確認したoidを指定)
(中略)
</AttributeResolver>

...


3. /opt/shibboleth-idp/conf/attribute-filter.xmlへの登録

...