~kennylevinsen/greetd-devel

1

Re: Plaintext passwords potentially being exposed through format macro

Details
Message ID
<CANHUFVpTZrkOB48aTsvONE1Zkyt6zmao2MsVhxXxUXvQFQgvbA@mail.gmail.com>
DKIM signature
pass
Download raw message
I have the same issue, I think the problem is with the pam
fprintd-grosshack and greetedd module because there is the same
problem with other greeters that use fprintd-grosshack and greetedd.
In my greeter (tuigreet) logs I found these events:
1. tuigreet sends "CreateSesssion"
2. tuigreet receives from greeted an "AuthMessage" of type "Secret"
3. At this moment the screen is waiting for password or fingerprint
(fingerprint reader is up and running)
4. Now if you use fingerprint for authentication, the fingerprint
reader is disabled (I think because the fingerprint reading was
successful) but nothing happens, no message sent by tuigreet or
greeted.
5. If after using the fingerprint you type a password, even if it is
incorrect, tuigreet sends a "PostAuthMessageResponse" with the
password and always receives a "Success" message from greetedd
6. Now tuigreet sends a "StartSession" but receives a greeted error,
in the greetd logs now appears the error "error: expected Args or
Cancel, got: PamResponse { resp: Some("aaaa") }" (this is the random
text entered as password in point 5)
7. tuigreet cancels the session

This only happens if you use the fprintd-grosshack module, with the
pam_fprintd module everything works as it should

Re: Plaintext passwords potentially being exposed through format macro

Details
Message ID
<518589ea-bdf0-49c3-b06e-b9216a926d53@kl.wtf>
In-Reply-To
<CANHUFVpTZrkOB48aTsvONE1Zkyt6zmao2MsVhxXxUXvQFQgvbA@mail.gmail.com> (view parent)
DKIM signature
pass
Download raw message
Looking at pam-fprintf-grosshack, that thing is unsafe and broken beyond 
repair, and will cause anything from corrupt greetd states (likely the 
issue you're seeing) to outright memory corruption. There is no way to 
safely use that in greetd, nor a way for greetd to guard against issues 
when using it.

A valid PAM module cannot retract or interrupt a question. Once you have 
been asked a question, the only way for the process to continue is by 
answering the question.

Maybe we should change logging so that the message content can never get 
included, but that's a separate thing - this PAM module will never work 
or be safe to use.

Best regards,
Kenny Levinsen
Reply to thread Export thread (mbox)