Allow NULL PAM auth token. This would allow to have password authentication on certain users that have a certificate.

This commit is contained in:
Nikos Mavrogiannopoulos
2013-02-12 21:12:35 +01:00
parent 0e31edee4a
commit e49fbbe547

View File

@@ -64,14 +64,14 @@ struct passwd * pwd;
return -1;
}
pret = pam_authenticate(ph, PAM_SILENT|PAM_DISALLOW_NULL_AUTHTOK);
pret = pam_authenticate(ph, PAM_SILENT);
if (pret != PAM_SUCCESS) {
syslog(LOG_AUTH, "Error in PAM authentication: %s", pam_strerror(ph, pret));
ret = -1;
goto fail;
}
pret = pam_acct_mgmt(ph, PAM_SILENT|PAM_DISALLOW_NULL_AUTHTOK);
pret = pam_acct_mgmt(ph, PAM_SILENT);
if (pret != PAM_SUCCESS) {
syslog(LOG_AUTH, "Error in PAM account management: %s", pam_strerror(ph, pret));
ret = -1;