Author Topic: OpenLDAP  (Read 2134 times)

mlanner

  • Zen Apprentice
  • *
  • Posts: 13
  • Karma: +0/-0
    • View Profile
OpenLDAP
« on: June 02, 2013, 12:58:27 am »
Hi,

I've configured LDAP in Zentyal and set up a few groups and users to test with. I've successfully been able to auth against the Samba/LDAP module running on port 389. Now, I would prefer to use OpenLDAP, which apparently runs on port 390. I've specifically created a new firewall rule for port 390 and allowed that. (I also double-checked using Nmap that 390 is open.) However, I still can't auth against OpenLDAP.

The LDAP config, as presented by Zentyal, looks as follows:
Code: [Select]
Base DN: dc=mydomain,dc=com
Root DN: cn=zentyal,dc=mydomain,dc=com
Password: kHlHiKqLL/5vRDWk/G2z
Read-only root DN: cn=zentyalro,dc=mydomain,dc=com
Read-only password: gmXM1THl7eSbFA03DK7S
Users DN: ou=Users,dc=mydomain,dc=com
Groups DN: ou=Groups,dc=mydomain,dc=com

Now, if I run ldapsearch against my Zentyal server, I get:
Code: [Select]
# search result
search: 2
result: 32 No such object

Other applications I'm trying to integrate with just returns: "Could not connect to the LDAP server." or similar.

Can anyone tell me what strings I should be using as for bind DN?

I've successfully used other OpenLDAP servers with the same applications before, so my sense is that something is wrong with my Zentyal setup, something that I don't understand.

Thanks in advance for any suggestions or ideas of how I can get this working.

christian

  • Guest
Re: OpenLDAP
« Reply #1 on: June 02, 2013, 05:47:59 am »
I wonder how you have been able to authenticate against OpenLDAP on port 389.
Would you mind sharing your settings?

For what concerns port 390, I suggest that you share your ldapsearch command.
No such object looks like wrong baseDN or it could also be due to anonymous access that is not authorized even using ldap on port 390.

mlanner

  • Zen Apprentice
  • *
  • Posts: 13
  • Karma: +0/-0
    • View Profile
Re: OpenLDAP
« Reply #2 on: June 02, 2013, 04:31:43 pm »
Sorry if I was unclear. I have not used OpenLDAP on port 389, but rather the MS AD functionality that runs on 389.

As for my ldapsearch, this is what I used and the output:

Code: [Select]
$ ldapsearch -h 192.168.10.2 -p 390 -x -b "dc=mydomain,dc=com"
# extended LDIF
#
# LDAPv3
# base <dc=mydomain,dc=com> with scope subtree
# filter: (objectclass=*)
# requesting: ALL
#

# search result
search: 2
result: 32 No such object

# numResponses: 1

christian

  • Guest
Re: OpenLDAP
« Reply #3 on: June 02, 2013, 04:48:03 pm »
pretty clear, you can access LDAP anonymously.
Unfortunately, you do have to authenticate or change LDAP ACL in order to permit anonymous access if this is the only way you can access LDAP

christian

  • Guest
Re: OpenLDAP
« Reply #4 on: June 02, 2013, 05:04:35 pm »
try something like:
Code: [Select]
ldapsearch -h 192.168.10.2 -p 390 -D cn=zentyalro,dc=mydomain,dc=com -W -x -b dc=mydomain,dc=local

mlanner

  • Zen Apprentice
  • *
  • Posts: 13
  • Karma: +0/-0
    • View Profile
Re: OpenLDAP
« Reply #5 on: June 04, 2013, 11:03:21 pm »
Christian,

Excellent advise! Thanks so much. It worked fine based on your input.