Commit 1fc10f15 authored by Benjamin Berg's avatar Benjamin Berg
Browse files

pam: Stop authorization if we couldn't parse signals

This really should never ever happen. If it does, don't continue but
stop instead.
parent c24badfd
......@@ -208,6 +208,7 @@ verify_result (sd_bus_message *m,
if ((r = sd_bus_message_read (m, "sb", &result, &done)) < 0)
{
pam_syslog (data->pamh, LOG_ERR, "Failed to parse VerifyResult signal: %d", r);
data->verify_ret = PAM_AUTHINFO_UNAVAIL;
return 0;
}
......@@ -255,6 +256,7 @@ verify_finger_selected (sd_bus_message *m,
if (sd_bus_message_read_basic (m, 's', &finger_name) < 0)
{
pam_syslog (data->pamh, LOG_ERR, "Failed to parse VerifyFingerSelected signal: %d", errno);
data->verify_ret = PAM_AUTHINFO_UNAVAIL;
return 0;
}
......@@ -630,6 +632,7 @@ name_owner_changed (sd_bus_message *m,
if (sd_bus_message_read (m, "sss", &name, &old_owner, &new_owner) < 0)
{
pam_syslog (data->pamh, LOG_ERR, "Failed to parse NameOwnerChanged signal: %d", errno);
data->verify_ret = PAM_AUTHINFO_UNAVAIL;
return 0;
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment