summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/providers/ldap/ldap_auth.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/providers/ldap/ldap_auth.c b/src/providers/ldap/ldap_auth.c
index 58cc2d35..ea28ba66 100644
--- a/src/providers/ldap/ldap_auth.c
+++ b/src/providers/ldap/ldap_auth.c
@@ -908,7 +908,8 @@ static void sdap_pam_chpass_done(struct tevent_req *req)
}
}
- if (dp_opt_get_bool(state->ctx->opts->basic,
+ if (state->pd->pam_status == PAM_SUCCESS &&
+ dp_opt_get_bool(state->ctx->opts->basic,
SDAP_CHPASS_UPDATE_LAST_CHANGE)) {
lastchanged_name = state->ctx->opts->user_map[SDAP_AT_SP_LSTCHG].name;