mirror of
https://github.com/opnsense/src.git
synced 2026-06-09 00:32:25 -04:00
login: Missed an instance of getpwnam().
Fixes: a3d80dd8aa
MFC after: 1 week
Sponsored by: Klara, Inc.
Reviewed by: allanjude
Differential Revision: https://reviews.freebsd.org/D43423
This commit is contained in:
parent
899837e8f5
commit
1e25eb287f
1 changed files with 4 additions and 2 deletions
|
|
@ -704,8 +704,10 @@ auth_pam(void)
|
|||
pam_err = pam_get_item(pamh, PAM_USER, &item);
|
||||
if (pam_err == PAM_SUCCESS) {
|
||||
tmpl_user = (const char *)item;
|
||||
if (strcmp(username, tmpl_user) != 0)
|
||||
pwd = getpwnam(tmpl_user);
|
||||
if (strcmp(username, tmpl_user) != 0) {
|
||||
(void)getpwnam_r(tmpl_user, &pwres, pwbuf,
|
||||
sizeof(pwbuf), &pwd);
|
||||
}
|
||||
} else {
|
||||
pam_syslog("pam_get_item(PAM_USER)");
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue