|
|
458e05 |
From 606b7b6a45f6e2014119d0716774323f30862e0c Mon Sep 17 00:00:00 2001
|
|
|
458e05 |
From: Mark Reynolds <mreynolds@redhat.com>
|
|
|
458e05 |
Date: Fri, 2 Aug 2019 12:07:07 -0400
|
|
|
458e05 |
Subject: [PATCH] Issue 50529 - LDAP server returning PWP controls in
|
|
|
458e05 |
different sequence
|
|
|
458e05 |
|
|
|
458e05 |
Description: The server returns password policy controls in different orders
|
|
|
458e05 |
depending on the state of grace logins. The requested control,
|
|
|
458e05 |
if any, should be returned first, followed by any controls the
|
|
|
458e05 |
server might add.
|
|
|
458e05 |
|
|
|
458e05 |
relates: https://pagure.io/389-ds-base/issue/50529
|
|
|
458e05 |
|
|
|
458e05 |
Reviewed by: mreynolds (one line commit rule)
|
|
|
458e05 |
---
|
|
|
458e05 |
ldap/servers/slapd/pw_mgmt.c | 2 +-
|
|
|
458e05 |
1 file changed, 1 insertion(+), 1 deletion(-)
|
|
|
458e05 |
|
|
|
458e05 |
diff --git a/ldap/servers/slapd/pw_mgmt.c b/ldap/servers/slapd/pw_mgmt.c
|
|
|
458e05 |
index befac50cd..ca76fc12f 100644
|
|
|
458e05 |
--- a/ldap/servers/slapd/pw_mgmt.c
|
|
|
458e05 |
+++ b/ldap/servers/slapd/pw_mgmt.c
|
|
|
458e05 |
@@ -207,10 +207,10 @@ skip:
|
|
|
458e05 |
|
|
|
458e05 |
/* password expired and user exceeded limit of grace attemps.
|
|
|
458e05 |
* Send result and also the control */
|
|
|
458e05 |
- slapi_add_pwd_control(pb, LDAP_CONTROL_PWEXPIRED, 0);
|
|
|
458e05 |
if (pwresponse_req) {
|
|
|
458e05 |
slapi_pwpolicy_make_response_control(pb, -1, -1, LDAP_PWPOLICY_PWDEXPIRED);
|
|
|
458e05 |
}
|
|
|
458e05 |
+ slapi_add_pwd_control(pb, LDAP_CONTROL_PWEXPIRED, 0);
|
|
|
458e05 |
slapi_send_ldap_result(pb, LDAP_INVALID_CREDENTIALS, NULL,
|
|
|
458e05 |
"password expired!", 0, NULL);
|
|
|
458e05 |
|
|
|
458e05 |
--
|
|
|
458e05 |
2.21.0
|
|
|
458e05 |
|