self-service-password
self-service-password copied to clipboard
Cannot access LDAP directory
hi! I can't set up a connection to my ldap in any way
$ ldap_url = "ldap://localhost:389";
$ ldap_starttls = false;
$ ldap_binddn = "";
$ ldap_bindpw = "";
$ ldap_base = "ou=users,dc=test,dc=com";
$ ldap_login_attribute = "uid";
$ ldap_fullname_attribute = "cn";
$ ldap_filter = "($ldap_login_attribute={login})";
$ who_change_password = "user";
with this configuration, an error appears that there is no connection to the ldap directory. maybe I configured ldap_filter incorrectly? I tried different options. the screenshot shows the user whose password I want to change, but I just can't get the configuration right. ldap and self-service-password are on the same server
You did not define $ldap_binddn
, can you browse your LDAP directory anonymously?
You did not define
$ldap_binddn
, can you browse your LDAP directory anonymously?
when I set
$ ldap_url = "ldap://localhost:389"; $ ldap_starttls = false; $ ldap_binddn = "cn=dmin,dc=test,dc=com"; $ ldap_bindpw = "PASS"; $ ldap_base = "ou=users,dc=test,dc=com"; $ ldap_login_attribute = "uid"; $ ldap_fullname_attribute = "cn"; $ ldap_filter = "($ldap_login_attribute={login})";
$ who_change_password = "manager";
the error is the same
You should set $debug
to true
and see the logs.
You should set
$debug
totrue
and see the logs.
yes, I set $debug = true, but where I can see debug logs?
You should set
$debug
totrue
and see the logs.
I see in httpd logs
[Tue Mar 30 13:11:00.188877 2021] [php7:notice] [pid 23048:tid 23048] [client 10.2.10.16:0] PHP Notice: Undefined variable: use_recaptcha in /usr/share/self-service-password/index.php on line 30, referer: http://ldap.loc/
[Tue Mar 30 13:11:00.189113 2021] [php7:notice] [pid 23048:tid 23048] [client 10.2.10.16:0] PHP Notice: Undefined variable: use_pwnedpasswords in /usr/share/self-service-password/index.php on line 35, referer: http://ldap.loc/
[Tue Mar 30 13:11:00.196064 2021] [php7:notice] [pid 23048:tid 23048] [client 10.2.10.16:0] LDAP - Search error 2 (Protocol error), referer: http://ldap.loc/
Can you add in your config file:
ldap_set_option(NULL, LDAP_OPT_DEBUG_LEVEL, 7);
And in the logs if you have more details about LDAP operations?
Can you add in your config file:
ldap_set_option(NULL, LDAP_OPT_DEBUG_LEVEL, 7);
And in the logs if you have more details about LDAP operations?
added this parameter to config next to $debug = true
$ldap_set_option(NULL, LDAP_OPT_DEBUG_LEVEL, 7);
and where else can I see the logs? I have enabled debug, but where can I see them?
In the apache error logs.
In the apache error logs.
in apache also enabled debug of logs. these are all the logs that are in the apache....
[Tue Mar 30 17:59:48.848861 2021] [authz_core:debug] [pid 25183:tid 25183] mod_authz_core.c(818): [client 10.2.10.16:0] AH01626: authorization result of Require all granted: granted, referer: http://ldap.loc/
[Tue Mar 30 17:59:48.848946 2021] [authz_core:debug] [pid 25183:tid 25183] mod_authz_core.c(818): [client 10.2.10.16:0] AH01626: authorization result of <RequireAny>: granted, referer: http://ldap.loc/
[Tue Mar 30 17:59:48.852473 2021] [php7:notice] [pid 25183:tid 25183] [client 10.2.10.16:0] PHP Notice: Undefined variable: use_recaptcha in /usr/share/self-service-password/index.php on line 30, referer: http://ldap.loc/
[Tue Mar 30 17:59:48.852641 2021] [php7:notice] [pid 25183:tid 25183] [client 10.2.10.16:0] PHP Notice: Undefined variable: use_pwnedpasswords in /usr/share/self-service-password/index.php on line 35, referer: http://ldap.loc/
[Tue Mar 30 17:59:48.859858 2021] [php7:notice] [pid 25183:tid 25183] [client 10.2.10.16:0] LDAP - Search error 2 (Protocol error), referer: http://ldap.loc/
There should be other logs.
Please provide your full config file.
ldap_set_option is a function, so set this in the file:
$debug = true;
ldap_set_option(NULL, LDAP_OPT_DEBUG_LEVEL, 7);
Check also that you don't have a config.inc.local.php in the same directory, or if you have one, prefer to edit this file to set your own configuration settings.
ldap_set_option is a function, so set this in the file:
$debug = true; ldap_set_option(NULL, LDAP_OPT_DEBUG_LEVEL, 7);
Check also that you don't have a config.inc.local.php in the same directory, or if you have one, prefer to edit this file to set your own configuration settings.
ok i did as you said
I have no other files in /conf