LDAP Connection Issue on Redmine Docker instance

Added by Sedat Kestepe over 1 year ago

Hello,

I am trying to setup an environment for my team. I decided on Redmine as issue tracker and Apacheds as LDAP server. To have a practical and scalable environment i have used Docker images which is hosted on Docker hub: https://hub.docker.com/_/redmine/ and went for MySQL stack deployment.

The problem is i couldn't retrieve users from Apacheds. As I configure LDAP settings I see a green (bar) notification on top of configuration page but no users added.

I have followed log file /usr/src/redmine/log/production.log and below was the only output as I try saving configuration:

Started PATCH "/auth_sources/1" for 192.168.1.3 at 2018-02-08 19:52:08 +0000
Processing by AuthSourcesController#update as HTML
Parameters: {"utf8"=>"✓", "authenticity_token"=>"beSvPfs4zWzdAsJqu5HY5JnqPZLPBbpQvJ+Pxjh+IhrLUpzyA5EfcjkhpYpbbLeC9Ktqli6/IhNHyE84jj6W7A==", "auth_source"=>{"name"=>"myldapinstance", "host"=>"192.168.1.23", "port"=>"389", "tls"=>"0", "account"=>"uid=admin,ou=system", "account_password"=>"[FILTERED]", "base_dn"=>"ou=people,ou=accounts,dc=myorg,dc=com", "filter"=>"", "timeout"=>"20", "onthefly_register"=>"0", "attr_login"=>"cn", "attr_firstname"=>"", "attr_lastname"=>"", "attr_mail"=>""}, "commit"=>"Kaydet", "id"=>"1"}
Current user: admin (id=1)
Redirected to http://192.168.1.20:8060/auth_sources
Completed 302 Found in 20ms (ActiveRecord: 8.9ms)
Started GET "/auth_sources" for 192.168.1.3 at 2018-02-08 19:52:08 +0000
Processing by AuthSourcesController#index as HTML
Current user: admin (id=1)
Rendered auth_sources/index.html.erb within layouts/admin (5.3ms)
Rendered admin/_menu.html.erb (4.1ms)
Rendered layouts/base.html.erb (13.4ms)
Completed 200 OK in 38ms (Views: 21.8ms | ActiveRecord: 9.1ms)

The configuration I made should be alright since it was successful with ldapsearch command and also with another application (Rocketchat).

Do you have any comment on log lines? Is there any possibility to make forther debugging?

Thanks in advance.

Replies (3)

RE: LDAP Connection Issue on Redmine Docker instance - Added by Sedat Kestepe over 1 year ago

Follow up post.

Pls any comment appreciated.

RE: LDAP Connection Issue on Redmine Docker instance - Added by Sedat Kestepe over 1 year ago

I am supposed to fill in all fields even though they are not marked as required. Most probably it needs email attribute but form was not validated this rule.

Then you just login using ldap credentials.

RE: LDAP Connection Issue on Redmine Docker instance - Added by Siddharth Kaul over 1 year ago

Let me provide you with information that will probably help but not guaranteed.

If you go to the database created by redmine and to users table you will see that the first name, last name and email are search-able attributes. Once the redmine gets the user data from the ldap it will search against this database.

You have not provided redmine with variable whose value to compare against to.

Moreover you have on the fly user registration disabled. So probable chance is that the user that is trying to log in has a difference in user information than what is available in the database. Or the user is not at all available in the database.

First try with turning the on the fly user registration on and may be then check the logs again.

Hope this helps.

(1-3/3)