-
Notifications
You must be signed in to change notification settings - Fork 247
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Passkey: Add child timeout handler #6893
Passkey: Add child timeout handler #6893
Conversation
Please add "Resolves:" line. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
I added this patch to the COPR repo so it's easier to test.
8f4947a
to
da4f62b
Compare
Done. |
src/responder/pam/pamsrv_passkey.c
Outdated
struct pam_passkey_auth_send_state *state = | ||
tevent_req_data(req, struct pam_passkey_auth_send_state); | ||
|
||
DEBUG(SSSDBG_CRIT_FAILURE, "Timeout reached for passkey child\n"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi,
since there is the passkey_child_timeout
option, what do you think about mention it here, e.g. similar to p11_child_timeout()
.
bye,
Sumit
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Agreed, updated.
src/responder/pam/pamsrv_passkey.c
Outdated
child_handler_destroy(state->child_ctx); | ||
state->child_ctx = NULL; | ||
state->child_status = ETIMEDOUT; | ||
tevent_req_error(req, ERR_PASSKEY_CHILD); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi,
I think it is worth to add a dedicated ERR_PASSKEY_CHILD_TIMEOUT
error code her.
bye,
Sumit
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done.
da4f62b
to
22821a6
Compare
If passkey auth times out, the SIGCHLD handler needs to be destroyed otherwise the SIGCHLD handler tries to access the tevent_req which was already freed from the timeout. Resolves: SSSD#6889
22821a6
to
26c1ca3
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi,
thanks for the updates, ACK.
bye,
Sumit
If passkey auth times out, the SIGCHLD handler needs to be destroyed otherwise the SIGCHLD handler tries to access the
tevent_req *req
which was already freed from the timeout.This can be reproduced with
local
passkey auth - after entering a PIN don't press the passkey device tactile trigger, invoking the passkey child timeout.