mirror of
https://gitea.psi.ch/ELOG/elog.git
synced 2026-09-08 17:13:56 +00:00
Fixed LDAP issues
This commit is contained in:
parent
b255121091
commit
b69352d2aa
2
Makefile
2
Makefile
@ -28,7 +28,7 @@ USE_SSL = 1
|
||||
USE_KRB5 = 0
|
||||
|
||||
# flag for LDAP support, please turn on if you need LDAP
|
||||
USE_LDSP = 0
|
||||
USE_LDAP = 0
|
||||
|
||||
#############################################################
|
||||
|
||||
|
||||
@ -486,8 +486,7 @@ int auth_verify_password(LOGBOOK * lbs, const char *user, const char *password,
|
||||
// if user not in password file (external authentication!) and "LDAP register" is allowed (>0),
|
||||
// obtain user info from LDAP and add locally
|
||||
if (verified) {
|
||||
status = get_user_line(lbs, user, NULL, NULL, NULL, NULL, NULL, &inactive);
|
||||
if (status == 2) {
|
||||
if (get_user_line(lbs, user, NULL, NULL, NULL, NULL, NULL, NULL) == 2) {
|
||||
if (getcfg(lbs->name, "LDAP register", str, sizeof(str)) && atoi(str) > 0)
|
||||
ldap_adduser_file(lbs, user, password, error_str, error_size);
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user