-2

I am a newbie with openldap 2.4 and I need to restrict read access to anonymous. Actually, if someone write ldapsearch -x -H ldap://myipaddrr he can see all entries of my HDB database.

How can I solve this using cn=config (dynamic configuration). By default there is a lot of olcAccess setup...

thank you

Cyrill Gremaud
  • 63
  • 3
  • 12

1 Answers1

0

I have found a solution.

dn: cn=config
changetype: modify
add: olcDisallows
olcDisallows: bind_anon
-

dn: olcDatabase={-1}frontend,cn=config
changetype: modify
add: olcRequires
olcRequires: authc

Now, when someone try to read data with ldapsearch -x -H ldap://myipaddrr , he can't and receive this error message:

ldap_bind: Inappropriate authentication (48)
    additional info: anonymous bind disallowed
user207421
  • 990
  • 5
  • 16
Cyrill Gremaud
  • 63
  • 3
  • 12