我正在尝试在ubuntu 9.10上建立一个OpenLDAP服务器,该服务器使用slapd版本2.4.18.
初始化并填充新的hdb数据库后,一切似乎都没问题,但我无法让服务器返回根DSE.运行
- ldapsearch -x -W -D 'cn=manager,dc=example,dc=org' \
- -b '' -s base '(objectclass=*)' +
回来
- # extended LDIF
- #
- # LDAPv3
- # base <> with scope baSEObject
- # filter: (objectclass=*)
- # requesting: +
- #
- # search result
- search: 2
- result: 0 Success
- # numResponses: 1
我的hdb数据库ACL设置如下:
- olcAccess: to attrs=userPassword,shadowLastChange
- by self write
- by anonymous auth
- by dn.base="cn=manager,dc=org" write
- by * none
- olcAccess: to dn.base=""
- by * read
- olcAccess: to *
- by self write
- by dn.base="cn=manager,dc=org" write
- by * read
根据我的经验,这个设置应该返回一个有效的根DSE,所以如果有人能给我一个关于发生了什么的线索……
这实际上是作为bug
#427842再次提交Ubuntu 9.10(karmic).
要解决此问题,请将以下内容复制到fixRootDSE.ldif:
- dn: olcDatabase={-1}frontend,cn=config
- changetype: modify
- add: olcAccess
- olcAccess: to dn.base="" by * read
- olcAccess: to dn.base="cn=subschema" by * read
并执行
- sudo ldapmodify -Y EXTERNAL -H ldapi:/// -f fixRootDSE.ldif
这应该提供对根DSE的匿名访问.