OpenLDAP authentication issue

OpenLDAP authentication issue

by Andrei Vida-Rațiu -
Number of replies: 5

Hello

I'm trying to set up LDAP authentication.

Moodle version: 3.2.1+ (Build: 20170127)

I tested from the server, command line, and the connection to the LDAP server works.

When I try to authenticate with LDAP it says: The user account "test@cunbm.utcluj.ro" is not available on this site.

The user test exists on the LDAP server.

The relevant settings:



Average of ratings: -
In reply to Andrei Vida-Rațiu

Re: OpenLDAP authentication issue

by Leon Stringer -
Picture of Core developers Picture of Particularly helpful Moodlers

Are you sure about that Object class value inetOrgPerson? The docs say "unless you need something special, you don't need to fill this in". Have you tried leaving this blank?

In reply to Leon Stringer

Re: OpenLDAP authentication issue

by Andrei Vida-Rațiu -

I did test without changing any values in User lookup settings section.

I get the same error: that the account doesn't exist on the site.

In reply to Andrei Vida-Rațiu

Re: OpenLDAP authentication issue

by Andrei Vida-Rațiu -

Interesting that. If I enter the username and password of an existing LDAP user, it says that "The user account "test@mail" is not available on this site".

However, if I enter the wrong password, it says "Invalid login, please try again".

This makes me believe that it isn't a LDAP connection issue but rather the fact that Moodle doesn't create the LDAP user in the local db, when it tries to logon for the first time,



In reply to Andrei Vida-Rațiu

Re: OpenLDAP authentication issue

by Leon Stringer -
Picture of Core developers Picture of Particularly helpful Moodlers

What have you got Prevent account creation when authenticating set to (under Site administrationPluginsAuthenticationManage authentication)?

This needs to be unticked for LDAP authentication to create the account.

In reply to Leon Stringer

Re: OpenLDAP authentication issue

by Andrei Vida-Rațiu -

Yes, that was it! I didn't set up this Moodle server. My job was only to set up the LDAP auth. But that checkbox was ticked...

Problem solved. Thank you.