내 OpenLDAP 서버에이 dlif을 적용하는 노력 해왔다에 레코드를 업데이트 할 수 있도록 나는 그것을 검색 할 때어떻게 올바르게 지정된 사용자 액세스가 각각 openldap
$ sudo ldapmodify -Y EXTERNAL -H ldapi:/// -f acl.ldif
SASL/EXTERNAL authentication started
SASL username: gidNumber=0+uidNumber=0,cn=peercred,cn=external,cn=auth
SASL SSF: 0
modifying entry "olcDatabase={1}hdb,cn=config"
내가 내 업데이트 된 전자를 찾을 수 있습니다 : "cn=ldap-city-thedomain-com,dc=repl,dc=thedomain,dc=com"
이 잘 적용하는 것에 ipServicePort과 설명 속성 n 다음 : 나는 이러한 자격 증명을 사용하여 변경하려고 할 때
는$ sudo ldapsearch -Y EXTERNAL -H ldapi:// -b cn=config 'olcDatabase={1}hdb'
SASL/EXTERNAL authentication started
SASL username: gidNumber=0+uidNumber=0,cn=peercred,cn=external,cn=auth
SASL SSF: 0
# extended LDIF
#
# LDAPv3
# base <cn=config> with scope subtree
# filter: olcDatabase={1}hdb
# requesting: ALL
#
# {1}hdb, config
dn: olcDatabase={1}hdb,cn=config
objectClass: olcDatabaseConfig
objectClass: olcHdbConfig
olcDatabase: {1}hdb
olcDbDirectory: /var/lib/ldap
olcSuffix: dc=thedomain,dc=com
olcAccess: {0}to attrs=userPassword,shadowLastChange by self write by anonymou
s auth by dn="cn=admin,dc=domain,dc=ie,dc=aws,dc=thedomain,dc=net" write by * n
one
olcAccess: {1}to dn.base="" by * read
olcAccess: {2}to * by dn="cn=admin,dc=domain,dc=ie,dc=aws,dc=thedomain,dc=net" w
rite by * read
olcAccess: {3}to dn.exact="cn=ldap-city-thedomain-com,dc=repl,dc=thedomain,
dc=com" attrs="ipServicePort,description" by dn="[email protected],ou=p
eople,dc=thedomain,dc=com" write by * read
olcLastMod: TRUE
olcRootDN: cn=admin,dc=thedomain,dc=com
olcRootPW: {SSHA}HASHEDPW
olcSyncrepl: {0}rid=003 provider=ldap://ldap.city.thedomain.com binddn="cn
=admin,dc=thedomain,dc=com" bindmethod=simple credentials=Cju8MJZhegnEgKp2nU s
earchbase="dc=thedomain,dc=com" type=refreshAndPersist interval=00:00:00:10 re
try="5 5 300 5" timeout=1
olcSyncrepl: {1}rid=004 provider=ldap://ldap1.domain.ie.aws.thedomain.net binddn
="cn=admin,dc=thedomain,dc=com" bindmethod=simple credentials=Cju8MJZhegnEgKp2
nU searchbase="dc=thedomain,dc=com" type=refreshAndPersist interval=00:00:00:1
0 retry="5 5 300 5" timeout=1
olcMirrorMode: TRUE
olcDbCheckpoint: 512 30
olcDbConfig: {0}set_cachesize 0 2097152 0
olcDbConfig: {1}set_lk_max_objects 1500
olcDbConfig: {2}set_lk_max_locks 1500
olcDbConfig: {3}set_lk_max_lockers 1500
olcDbIndex: objectClass eq
olcDbIndex: entryCSN eq
olcDbIndex: entryUUID eq
# search result
search: 2
result: 0 Success
# numResponses: 2
# numEntries: 1
그러나, 여전히 실패
$ cat /tmp/modify.ldif
dn: cn=ldap-city-thedomain-com,dc=repl,dc=thedomain,dc=com
changetype: modify
replace: ipServicePort
ipServicePort: 1485176342
dn: cn=ldap-city-thedomain-com,dc=repl,dc=thedomain,dc=com
changetype: modify
replace: description
description: Updated by ldap.city.thedomain.com on Mon Jan 23 12:59:02 UTC 2017
실행 : 나는 또한 내 ACL이 약간 덜 만드는 시도
$ ldapmodify -H ldap://localhost -w PASSWORD -D "[email protected],ou=people,dc=thedomain,dc=com" -f /tmp/modify.ldif
modifying entry "cn=ldap-city-thedomain-com,dc=repl,dc=thedomain,dc=com"
ldap_modify: Insufficient access (50)
제한적으로 작동하지 않는 것을 이해하려고 시도한 후 다음 acl.ldif 파일을 시도했습니다.
dn: olcDatabase={1}hdb,cn=config
changetype: modify
add: olcAccess
olcAccess: {3}to dn="cn=ldap-city-thedomain-com,dc=repl,dc=thedomain,dc=com" attrs="ipServicePort,description" by dn="[email protected],ou=people,dc=thedomain,dc=com" write by * read
결과는 내가 피하기 위해 바라고 같은
dn: olcDatabase={1}hdb,cn=config
changetype: modify
add: olcAccess
olcAccess: {3}to dn="cn=ldap-city-thedomain-com,dc=repl,dc=thedomain,dc=com" by dn="[email protected],ou=people,dc=thedomain,dc=com" write by * read
결과이 같은
dn: olcDatabase={1}hdb,cn=config
changetype: modify
add: olcAccess
olcAccess: {3}to * by dn="[email protected],ou=people,dc=thedomain,dc=com" write by * read
결과는 아직 시도하지 않았다 같은
있는 유일한 방법이었다이었다 테스트 중에도 db를 불안전하게 만드는 것은 *이 레코드를 쓰거나 * 모든 레코드에 쓰도록 허용하는 것이 었습니다. 같은에서
DN: cn=ldap-city-thedomain-com,dc=repl,dc=thedomain,dc=com
그리고 내 사용자 DN :
은 내가 나를 보여줍니다 아파치 디렉터리 스튜디오에서의 편집을 허용 할 레코드의 DN을 촬영했습니다
DN: [email protected],ou=people,dc=thedomain,dc=com
Idon't 한 무엇인가 명백하게하고있는 I 'm 확실한 Idap의 나의 지식이 가난하고, 문서를 읽는 것은 나를 위해 괴롭다. 나는 누군가가 나의 명백한 오류를 발견하고 수정을 제안 할 수 있기를 바라고있다. 나는 많은 시간 동안 땜질을 한 후에 내가 잘못한 것을 볼 수 없기 때문이다.