openldapの代わりに採用が増えてきたldap serverの「389 Directory Server(389DS)」
ここでは rockylinux9 を対象にこの 389DS を入れてみた
構成としては
とかにしてみる
docker版389DS/docker
環境はこんな感じ
[root@ds ~]# cat /etc/redhat-release
Rocky Linux release 9.8 (Blue Onyx)
[root@ds ~]# cat /etc/resolv.conf
# Generated by NetworkManager
search sybyl.local
nameserver 192.168.0.3
[root@ds ~]# hostname
ds
[root@ds ~]# hostname -f
ds.sybyl.local
[root@ds ~]# cat /etc/hosts
127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4
::1 localhost localhost.localdomain localhost6 localhost6.localdomain6
192.168.0.186 ds.sybyl.local ds
[root@ds ~]#っでアプリを入れて、fwを調整
[root@ds ~]# dnf install 389-ds-base -y
[root@ds ~]# firewall-cmd --add-service=ldap --add-service=ldaps --zone=public --permanent
[root@ds ~]# firewall-cmd --reload「openldap-clients」も同時に入ります
「dscreate」コマンドで設定しますが、方法に対話方式とかありますが、ここでは設定値を入れたファイル(ds.inf)を作ってそこから作るようにします
再利用も可能なのでね
[root@ds ~]# vi ds.inf
[general]
config_version = 2
full_machine_name = ds.sybyl.local
[slapd]
instance_name = sybyl
root_dn = cn=Directory Manager
root_password = xxxxxxxxxxxxxxxxxxxx *平文でokです
self_sign_cert = True *自己証明書でldapsを有効にします
[backend-userroot]
suffix = dc=sybyl,dc=local
create_suffix_entry = True
[root@ds ~]#っで構築
[root@ds ~]# dscreate from-file /root/ds.inf
:
:
[root@ds ~]# ls -l /etc/dirsrv/
total 4
drwxr-xr-x. 2 root root 55 Aug 2 03:02 config
drwxr-xr-x. 2 root root 25 Aug 2 03:02 schema
drwxrwx---. 3 dirsrv dirsrv 4096 Aug 2 03:37 slapd-sybyl <-- 作られる
drwxrwx---. 2 root root 156 Aug 2 03:36 ssca
[root@ds ~]#作成と同時に service が登録されて起動状態になります
[root@ds ~]# systemctl status dirsrv@sybyl
● dirsrv@sybyl.service - 389 Directory Server sybyl.
Loaded: loaded (/usr/lib/systemd/system/dirsrv@.service; enabled; preset: disabled) <-- 動いてます.
Drop-In: /usr/lib/systemd/system/dirsrv@.service.d
mqcustom.conf
:
[root@ds ~]#
[root@ds ~]# dsctl --list <-- 立ち上げっているインスタンス
slapd-sybyl
[root@ds ~]# dsctl sybyl status
Instance "sybyl" is running
[root@ds ~]#作ったインスタンスを削除して再度作り直すには「dsctl <インスタンス> remove --do-it」とします。
インスタンスは複数作れて、なにが構築されているかは「dsctl --list」で見れる
[root@ds ~]# dsctl sybyl remove --do-itldap(389), ldaps(636), ソケットでそれぞれ繋げてみた
[root@ds ~]# ldapwhoami -H ldap://ds:389 -D "cn=Directory Manager" -w xxxxxxxxxxxxxxxxxxxx
dn: cn=directory manager
[root@ds ~]# LDAPTLS_CACERT=/etc/dirsrv/slapd-sybyl/ca.crt ldapwhoami -H ldaps://ds.sybyl.local:636 -D "cn=Directory Manager" -w xxxxxxxxxxxxxxxxxxxx <- 「/etc/dirsrv/slapd-sybyl/ca.crt」は自己 CA証明書
dn: cn=directory manager
(ソケット通信)
[root@ds ~]# ldapwhoami -H ldapi://%2Frun%2Fslapd-sybyl.socket -D "cn=Directory Manager" -w xxxxxxxxxxxxxxxxxxxx <-「dsconf sybyl config get nsslapd-ldapifilepath」の値から接続先を付ける
dn: cn=directory manager
[root@ds ~]#openldapならスキーマを1つずつ「独立した設定エントリ(子ノード)」として管理され、そのため、
「ldapsearch -x -LLL -W -D cn=config -b cn=config dn」とすると
と別々の DN(データの住所) が作られてた.
一方 389DS では
すべてのスキーマ(標準・カスタム問わず)を cn=schema という1つのエントリの中に集約していて、標準で cosine、nis、inetorgperson のスキーマが最初から組み込まれているみたい.
取り込まれているスキーマは「/usr/share/dirsrv/schema/」に存在している
[root@ds ~]# ls -l /usr/share/dirsrv/schema/
total 380
-rw-r--r--. 1 root root 29137 Jul 8 04:54 00core.ldif *core.schema
:
-rw-r--r--. 1 root root 10481 Jul 8 04:54 05rfc4524.ldif *cosine.schema
:
-rw-r--r--. 1 root root 4962 Jul 8 04:54 06inetorgperson.ldif *inetorgperson.schema
:
-rw-r--r--. 1 root root 3285 Jul 8 04:54 10automember-plugin.ldif *memberOf関連
-rw-r--r--. 1 root root 8850 Jul 8 04:54 10rfc2307compat.ldif *nis.schema
:
-rw-r--r--. 1 root root 17109 Jul 8 04:54 60samba3.ldif *samba
-rw-r--r--. 1 root root 3599 Jul 8 04:54 60sudo.ldif *sudo
:
[root@ds ~]#なので、まぁー389DSについてはスキーマ拡張は不要っぽい
「10automember-plugin.ldif」スキーマが入っているので「MemberOf プラグイン」向けに属性、設定用スキーマは既に入っている
現在「MemberOf プラグイン」の状態を確認します。有効なのか無効なのか
[root@ds ~]# ldapsearch -w xxxxxxxxxxxxxxxxxxxx -H ldap://ds:389 -D "cn=Directory Manager" -b "cn=plugins,cn=config" -s one "cn=*MemberOf*" cn nsslapd-pluginEnabled
# extended LDIF
#
# LDAPv3
# base <cn=plugins,cn=config> with scope oneLevel
# filter: cn=*MemberOf*
# requesting: cn nsslapd-pluginEnabled
#
# MemberOf Plugin, plugins, config
dn: cn=MemberOf Plugin,cn=plugins,cn=config
cn: MemberOf Plugin
nsslapd-pluginEnabled: off <-- ここ
# search result
search: 2
result: 0 Success
# numResponses: 2
# numEntries: 1
[root@ds ~]#結果から「nsslapd-pluginEnabled: off」なので memberOf の機能は無効(off)になっている。
これを有効にしてみる
[root@ds ~]# ldapmodify -D "cn=Directory Manager" -w xxxxxxxxxxxxxxxxxxxx << EOF
dn: cn=MemberOf Plugin,cn=plugins,cn=config
changetype: modify
replace: nsslapd-pluginEnabled
nsslapd-pluginEnabled: on
EOF
[root@ds ~]#これで「modifying entry "cn=MemberOf Plugin,cn=plugins,cn=config"」と応答があって、再度ldapsearch コマンドで確認すると「nsslapd-pluginEnabled: on」となる
LDAP/dataと同じようにldifファイルを用意してldapaddコマンドで登録できますが、
389DSでは便利な dsidm コマンドがあります。このコマンドで ou やgroup/accountが登録できます
[root@ds ~]# dsidm -b "dc=sybyl,dc=local" sybyl organizationalunit create --ou groups
Successfully created groups
[root@ds ~]# dsidm -b "dc=sybyl,dc=local" sybyl organizationalunit create --ou people
Successfully created people
(削除は)
[root@ds ~]# dsidm -b "dc=sybyl,dc=local" sybyl organizationalunit delete ou=groups,dc=sybyl,dc=local
Deleting OrganizationalUnit ou=groups,dc=sybyl,dc=local :
Type 'Yes I am sure' to continue: Yes I am sure <-- 'Yes I am sure' と入力します
Successfully deleted ou=groups,dc=sybyl,dc=local
[root@ds ~]# dsidm -b "dc=sybyl,dc=local" sybyl organizationalunit delete ou=people,dc=sybyl,dc=local
Deleting OrganizationalUnit ou=people,dc=sybyl,dc=local :
Type 'Yes I am sure' to continue: Yes I am sure <-- 'Yes I am sure' と入力します
Successfully deleted ou=people,dc=sybyl,dc=local
[root@ds ~]#rootで行う分には「-D "cn=Directory Manager"」と「-w xxxxxxxxxxxxxxxxxxxx」の指定はなくても行けるみたい.
確認としてLDAP/Browseの「LDAP Admin」で行ってみた. 「Username:」を「cn=Directory Manager」にしてアクセスします

そうすれば、下記のように確認ができます

■autofs
「OU=automount,dc=sybyl,dc=local」を作る
[root@ds ~]# dsidm -b "dc=sybyl,dc=local" sybyl organizationalunit create --ou automount
Successfully created automount
[root@ds ~]#次に「OU=Automount,dc=sybyl,dc=local」の配下に「nisMapName=auto.master」を入れたいのですが、dsidmは
「account,group,initialise,init,organizationalunit,ou,posixgroup,user,client_config,role,service,uniquegroup」なオブジェクトクラスには対応なのですが、
nisMapName, nisMap な対象外のオブジェクトクラスの場合は、従来のldifファイルとかで構築が必要です.
[root@ds ~]# ldapadd -D "cn=Directory Manager" -w xxxxxxxxxxxxxxxxxxxx <<_EOF_
dn: nisMapName=auto.master,ou=automount,dc=sybyl,dc=local
objectClass: top
objectClass: nisMap
nisMapName: auto.master
_EOF_
[root@ds ~]# ldapadd -D "cn=Directory Manager" -w xxxxxxxxxxxxxxxxxxxx <<_EOF_
dn: nisMapName=auto.home,ou=automount,dc=sybyl,dc=local
objectClass: top
objectClass: nisMap
nisMapName: auto.home
_EOF_
[root@ds ~]#
■sudo
グループ「supervisor」に所属しているユーザがsudoを使えるとしてます
[root@ds ~]# dsidm -b "dc=sybyl,dc=local" sybyl organizationalunit create --ou sudoers
[root@ds ~]# ldapadd -D "cn=Directory Manager" -w xxxxxxxxxxxxxxxxxxxx <<_EOF_
dn: cn=supervisor,ou=sudoers,dc=sybyl,dc=local
objectClass: top
objectClass: sudorole
cn: supervisor
sudoUser: %supervisor
sudoCommand: ALL
sudoHost: ALL
sudoOption: nopasswd
_EOF_
[root@ds ldif]#
groupのOUを作ったのでグループを登録してみます
こちらも従来のldifファイルを作ってldapaddで登録もいいのですが、dsidmが使えます
[root@ds ~]# dsidm -b "dc=sybyl,dc=local" sybyl posixgroup create --cn em --gidNumber 2000
[root@ds ~]#dsidmを使うと、BASEDN(dc=sybyl,dc=local) に 「posixgroup」 なら ou=Groups に、「user」 なら ou=People に決め打ちでデータ登録になるので、OUの名称には注意が必要
そしてアカウント登録.
[root@ds ~]# dsidm -b "dc=sybyl,dc=local" sybyl user create --uid illya --cn "Illyasviel von Einzbern" --displayName illya --uidNumber 2001 --gidNumber 2000 --homeDirectory /home/illya --password '初期パスワード'
[root@ds ~]# dsidm -b "dc=sybyl,dc=local" sybyl account modify-by-dn "uid=illya,ou=people,dc=sybyl,dc=local" add:loginShell:/bin/bashloginShellは dsidm の user create では直接では無理のようで、別途account情報を修正して行う

ldap接続専用クライアントを用意します. クライアントの sssd に使われるアカウントですね.
基本アカウントなのですが、peopleとは違うouに入れます.
作成するアカウントには「posixAccount オブジェクトクラス」を含ませないのが肝みたい.
[root@ds ~]# dsidm -b "dc=sybyl,dc=local" sybyl organizationalunit create --ou ServiceAccounts
[root@ds ~]# ldapadd -D "cn=Directory Manager" -w xxxxxxxxxxxxxxxxxxxx <<_EOF_
dn: uid=sssd-auth,ou=ServiceAccounts,dc=sybyl,dc=local
objectClass: top
objectClass: account
objectClass: simpleSecurityObject
uid: sssd-auth
description: LDAP client search account
userPassword: yyyyyyyyyyyy
_EOF_
[root@ds ~]#
(接続テスト)
[root@ds ~]# LDAPTLS_CACERT=/etc/dirsrv/slapd-sybyl/ca.crt ldapwhoami -x -H ldaps://ds.sybyl.local:636 -D "uid=sssd-auth,ou=ServiceAccounts,dc=sybyl,dc=local" -w yyyyyyyyyyyy
dn: uid=sssd-auth,ou=serviceaccounts,dc=sybyl,dc=local
[root@ds ~]#
権限とか
[root@ds ~]# ldapsearch -D "cn=Directory Manager" -w xxxxxxxxxxxxxxxxxxxx -b "dc=sybyl,dc=local" "(objectClass=*)" aci -o ldif-wrap=no
:
# sybyl.local
dn: dc=sybyl,dc=local
aci: (targetattr="dc || description || objectClass")(targetfilter="(objectClass=domain)")(version 3.0; acl "Enable anyone domain read"; allow (read, search, compare)(userdn="ldap:///anyone");)
:
[root@ds ~]#となって、「dc=sybyl,dc=local」の「dc, description, objectClass」だけは、誰でも読めるとの意.
ここでは ou単位「ou=people,dc=sybyl,dc=local」で uid, uidnumber, gidnumber, loginShell, homeDirectoryは読めるが、userPasswordは読めないと定義して
[root@ds ~]# ldapmodify -D "cn=Directory Manager" -w xxxxxxxxxxxxxxxxxxxx <<_EOF_
dn: ou=people,dc=sybyl,dc=local
changetype: modify
add: aci
aci: (targetattr != "userPassword || aci")
(version 3.0;
acl "SSSD read";
allow (read,search,compare)
userdn="ldap:///uid=sssd-auth,ou=ServiceAccounts,dc=sybyl,dc=local";)
_EOF_
[root@ds ~]#次にou=groupsにも
[root@ds ~]# ldapmodify -D "cn=Directory Manager" -w xxxxxxxxxxxxxxxxxxxx <<_EOF_
dn: ou=groups,dc=sybyl,dc=local
changetype: modify
add: aci
aci: (targetattr != "userPassword || aci")
(version 3.0;
acl "SSSD read";
allow (read,search,compare)
userdn="ldap:///uid=sssd-auth,ou=ServiceAccounts,dc=sybyl,dc=local";)
_EOF_
[root@ds ~]#sudoersにも
[root@ds ~]# ldapmodify -D "cn=Directory Manager" -w xxxxxxxxxxxxxxxxxxxx <<_EOF_
dn: ou=sudoers,dc=sybyl,dc=local
changetype: modify
add: aci
aci: (targetattr != "userPassword || aci")
(version 3.0;
acl "SSSD read";
allow (read,search,compare)
userdn="ldap:///uid=sssd-auth,ou=ServiceAccounts,dc=sybyl,dc=local";)
_EOF_
[root@ds ~]#Automountにも
[root@ds ~]# ldapmodify -D "cn=Directory Manager" -w xxxxxxxxxxxxxxxxxxxx <<_EOF_
dn: ou=automount,dc=sybyl,dc=local
changetype: modify
add: aci
aci: (targetattr != "userPassword || aci")
(version 3.0;
acl "SSSD read";
allow (read,search,compare)
userdn="ldap:///uid=sssd-auth,ou=ServiceAccounts,dc=sybyl,dc=local";)
_EOF_
[root@ds ~]#あと全体へも決め打ちで uid=sssd-auth,ou=ServiceAccounts,dc=sybyl,dc=local がアクセス可能にしておきます
[root@ds ~]# ldapmodify -D "cn=Directory Manager" -w xxxxxxxxxxxxxxxxxxxx <<_EOF_
dn: dc=sybyl,dc=local
changetype: modify
add: aci
aci: (targetattr="dc || ou || objectClass || description")(version 3.0; acl "SSSD base read"; allow (read,search,compare) userdn="ldap:///uid=sssd-auth,ou=ServiceAccounts,dc=sybyl,dc=local";)
_EOF_
[root@ds ~]#これでaclは下記のようになります
[root@ds ~]# ldapsearch -D "cn=Directory Manager" -w xxxxxxxxxxxxxxxxxxxx -b "dc=sybyl,dc=local" "(objectClass=*)" aci -o ldif-wrap=no
:
dn: dc=sybyl,dc=local
aci: (targetattr="dc || description || objectClass")(targetfilter="(objectClass=domain)")(version 3.0; acl "Enable anyone domain read"; allow (read, search, compare)(userdn="ldap:///anyone");)
aci: (targetattr="dc || ou || objectClass || description")(version 3.0; acl "SSSD base read"; allow (read,search,compare) userdn="ldap:///uid=sssd-auth,ou=ServiceAccounts,dc=sybyl,dc=local";)
:
# groups, sybyl.local
dn: ou=groups,dc=sybyl,dc=local
aci: (targetattr != "userPassword || aci")(version 3.0; acl "SSSD read"; allow (read,search,compare) userdn="ldap:///uid=sssd-auth,ou=ServiceAccounts,dc=sybyl,dc=local";)
:
# people, sybyl.local
dn: ou=people,dc=sybyl,dc=local
aci: (targetattr != "userPassword || aci")(version 3.0; acl "SSSD read"; allow (read,search,compare) userdn="ldap:///uid=sssd-auth,ou=ServiceAccounts,dc=sybyl,dc=local";)
:
# automount, sybyl.local
dn: ou=automount,dc=sybyl,dc=local
aci: (targetattr != "userPassword || aci")(version 3.0; acl "SSSD read"; allow (read,search,compare) userdn="ldap:///uid=sssd-auth,ou=ServiceAccounts,dc=sybyl,dc=local";)
:
# sudoers, sybyl.local
dn: ou=sudoers,dc=sybyl,dc=local
aci: (targetattr != "userPassword || aci")(version 3.0; acl "SSSD read"; allow (read,search,compare) userdn="ldap:///uid=sssd-auth,ou=ServiceAccounts,dc=sybyl,dc=local";)
:
[root@ds ~]#この上でldap接続専用クライアントでテスト
[root@ds ~]# LDAPTLS_CACERT=/etc/dirsrv/slapd-sybyl/ca.crt ldapsearch -x -H ldaps://ds.sybyl.local:636 -D "uid=sssd-auth,ou=ServiceAccounts,dc=sybyl,dc=local" -w yyyyyyyyyyyy -b "dc=sybyl,dc=local" "(uid=illya)" dn
:
# illya, people, sybyl.local
dn: uid=illya,ou=people,dc=sybyl,dc=local
:
[root@ds ~]#となればok.
ldapsな通信をしたければ、389DSの「/etc/dirsrv/slapd-sybyl/ca.crt」をクライアントの「/opt/389ds/」あたりに置いておく
もしSELinuxを有効にしているなら
[root@rockylinux9 ~]# restorecon -Rv /opt/389dsとしておく.
そして先ほど作った「uid=sssd-auth,ou=ServiceAccounts,dc=sybyl,dc=local」をsssdに載せてクライアントからアカウント情報を引き出してみる
[root@rockylinux9 ~]# cat /etc/redhat-release
Rocky Linux release 9.8 (Blue Onyx)
[root@rockylinux9 ~]# dnf -y install sssd-ldap oddjob-mkhomedir sssd-tools openldap-clients
[root@rockylinux9 ~]# LDAPTLS_CACERT=/opt/389ds/ca.crt ldapsearch -x -H ldaps://ds.sybyl.local:636 -D "uid=sssd-auth,ou=ServiceAccounts,dc=sybyl,dc=local" -w yyyyyyyyyyyy -b "dc=sybyl,dc=local" "(uid=illya)" dn
:
# illya, people, sybyl.local
dn: uid=illya,ou=people,dc=sybyl,dc=local
:
[root@rockylinux9 ~]#とコマンドレベルでは引けることを確認して
[root@rockylinux9 ~]# vi /etc/sssd/sssd.conf
[sssd]
services = nss, pam
domains = default
[nss]
[domain/default]
id_provider = ldap
auth_provider = ldap
ldap_uri = ldaps://ds.sybyl.local:636
ldap_search_base = dc=sybyl,dc=local
ldap_default_bind_dn = uid=sssd-auth,ou=ServiceAccounts,dc=sybyl,dc=local
ldap_default_authtok_type = password
ldap_default_authtok = yyyyyyyyyyyy
ldap_tls_cacert = /opt/389ds/ca.crt
ldap_tls_reqcert = demand
[root@rockylinux9 ~]#
[root@rockylinux9 ~]# chown root:root /etc/sssd/sssd.conf
[root@rockylinux9 ~]# chmod 600 /etc/sssd/sssd.conf「/etc/sssd/sssd.conf」は600なので誰からも読めないのですが、よりセキュアにするなら文字列を暗号化してみます. 参照 LDAP/Client#g2ccf901
その上で
[root@rockylinux9 ~]# systemctl restart sssdそして確認
[root@rockylinux9 ~]# getent passwd illya
illya:*:2001:2000:Illyasviel von Einzbern:/home/illya:/bin/bash
[root@rockylinux9 ~]#と出ればok
あとは LDAP/data と同じようにコンテンツを乗せて、LDAP/ClientのようにLDAP接続すればいいのかなと。
こちらもデフォで用意されているようで、既定値はこんな感じ
[root@ds ~]# dsctl --list
slapd-sybyl
[root@ds ~]# dsconf sybyl pwpolicy get
Global Password Policy: cn=config
------------------------------------
nsslapd-pwpolicy-local: off
passwordstoragescheme: PBKDF2-SHA512
passwordchange: on
passwordmustchange: off
passwordhistory: off
passwordinhistory: 6
passwordadmindn:
passwordadminskipinfoupdate: off
passwordtrackupdatetime: off
passwordwarning: 86400
passwordisglobalpolicy: off
passwordexp: off
passwordmaxage: 8640000
passwordminage: 0
passwordgracelimit: 0
passwordsendexpiringtime: off
passwordlockout: off
passwordunlock: on
passwordlockoutduration: 3600
passwordmaxfailure: 3
passwordresetfailurecount: 600
passwordchecksyntax: off
passwordminlength: 8
passwordmindigits: 0
passwordminalphas: 0
passwordminuppers: 0
passwordminlowers: 0
passwordminspecials: 0
passwordmin8bit: 0
passwordmaxrepeats: 0
passwordpalindrome: off
passwordmaxsequence: 0
passwordmaxseqsets: 0
passwordmaxclasschars: 0
passwordmincategories: 3
passwordmintokenlength: 3
passwordbadwords:
passworduserattributes:
passworddictcheck: off
passworddictpath:
nsslapd-allow-hashed-passwords: off
nsslapd-pwpolicy-inherit-global: off
passwordTPRMaxUse: -1
passwordTPRDelayExpireAt: -1
passwordTPRDelayValidFrom: -1
[root@ds ~]#ここで
にするなら
[root@ds ~]# dsconf sybyl pwpolicy set \
--pwdchecksyntax=off \
--pwdhistory=off \
--pwdminlen=3 \
--pwdminage=0 \
--pwdlockout=on \
--pwdmaxfailures=5 \
--pwdlockoutduration=3600 \
--pwdresetfailcount=600
[root@ds ~]#「パスワードを5回間違えて、ロックされて、管理者がパスワードを再発行するが、そのパスワードでログインすると即座に変更を求められる」
まぁー欲しい機能ですね。
まず、初期パスワードでログインに成功したら即座に自分のパスワードに変更しなきゃいけないようにするには
[root@ds ~]# dsconf sybyl pwpolicy set --pwdmustchange=on
[root@ds ~]# dsconf sybyl pwpolicy get | grep passwordmustchange
passwordmustchange: on
[root@ds ~]#とします。
次に管理者権限でユーザのパスワードを再定義するには
[root@ds ~]# dsidm -D "cn=Directory Manager" -w xxxxxxxxxxxxxxxxxxxx sybyl account reset_password uid=illya,ou=people,dc=sybyl,dc=local
Enter new password for uid=illya,ou=people,dc=sybyl,dc=local : <--仮パスワード発行
CONFIRM - Enter new password for uid=illya,ou=people,dc=sybyl,dc=local :
reset password for uid=illya,ou=people,dc=sybyl,dc=local
[root@ds ~]#とします。これでそのユーザにフラグが付きます
っでクライアントからそのユーザが仮パスワードで入ると即座に自分のパスワード定義になるのですが、
これはクライアント側が Password Policy を実装していかに寄ります。SSSDなら大丈夫みたい。nslcdは無理っぽい
あとこの「pwdmustchange=on」とすると先ほど作った接続用アカウント「uid=sssd-auth,ou=ServiceAccounts,dc=sybyl,dc=local」にもパスワード変更要求がでるので中継としての役目ができなくなる.
なのでこのアカウントだけ「pwdmustchange=on」を回避させるようにします
[root@ds ~]# dsconf localhost pwpolicy set --pwdlocal on
[root@ds ~]# dsconf localhost localpwp adduser --pwdmustchange off "uid=sssd-auth,ou=ServiceAccounts,dc=sybyl,dc=local"
(パスワードの再定義)
[root@ds ~]# ldapmodify -D "cn=Directory Manager" -w xxxxxxxxxxxxxxxxxxxx <<_EOF_
dn: uid=sssd-auth,ou=ServiceAccounts,dc=sybyl,dc=local
changetype: modify
replace: userPassword
userPassword: yyyyyyyyyyyy
_EOF_
[root@ds ~]#