]> git.ipfire.org Git - thirdparty/systemd.git/commit - src/home/pam_systemd_home.c
Fix misuse of PAM_PROMPT_ECHO_OFF in systemd-homed
authorJoel Shapiro <joel.shapiro7@gmail.com>
Sat, 9 May 2020 05:38:41 +0000 (00:38 -0500)
committerLennart Poettering <lennart@poettering.net>
Mon, 11 May 2020 22:27:08 +0000 (00:27 +0200)
commitd423294394a411a3fe98884993f9c1686edffb1b
tree4b8f4e8adee6c6915926376965f76b66665b7326
parent9b107000ab24cabbb229ddafa6babdaa25621fe3
Fix misuse of PAM_PROMPT_ECHO_OFF in systemd-homed

Previously pam_systemd_home.so was relying on `PAM_PROMPT_ECHO_OFF` to
display error messages to the user and also display the next prompt.
`PAM_PROMPT_ECHO_OFF` was never meant as a way to convey information to
the user, and following the example set in pam_unix.so you can see that
it's meant to _only_ display the prompt. Details about why the
authentication failed should be done in a `PAM_ERROR_MSG` before
displaying a short prompt as per usual using `PAM_PROMPT_ECHO_OFF`.
src/home/pam_systemd_home.c