You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The howdy pam module uses wait in order to wait for the python compare script to finish.
But wait blocks until ANY child process finishes. If the authentication client uses child processes as well, one of them could exit with 0 at the right time and it would unlock.
Just using waitpid instead would fix this issue.
wait to waitpid patch
diff --git a/howdy/src/pam/main.cc b/howdy/src/pam/main.cc
index d1b8e34..8498655 100644
--- a/howdy/src/pam/main.cc+++ b/howdy/src/pam/main.cc@@ -290,7 +290,7 @@ auto identify(pam_handle_t *pamh, int flags, int argc, const char **argv,
// zombie process)
optional_task<int> child_task([&] {
int status;
- wait(&status);+ waitpid(child_pid, &status, 0);
{
std::unique_lock<std::mutex> lock(mutx);
if (confirmation_type == ConfirmationType::Unset) {
Howdy version (
sudo howdy version
): aa75c76The howdy pam module uses
wait
in order to wait for the python compare script to finish.But
wait
blocks until ANY child process finishes. If the authentication client uses child processes as well, one of them could exit with 0 at the right time and it would unlock.Just using
waitpid
instead would fix this issue.wait to waitpid patch
Discovered here: hyprwm/hyprlock#535
The text was updated successfully, but these errors were encountered: