From: AK47 <250200715@qq.com>
To: musl <musl@lists.openwall.com>
Subject: [musl] Question about SIGTIMER in musl
Date: Tue, 19 Nov 2024 10:42:43 +0800 [thread overview]
Message-ID: <tencent_6AA362284986B012F97905C28CD39DE96806@qq.com> (raw)
[-- Attachment #1: Type: text/plain, Size: 932 bytes --]
Hi
We found a problem. The bottom-layer logic creates a timing thread through timer_create, but the upper-layer user is unaware of this behavior and reset the signal mask of this thread which will unmask 32 signal. As a result, the process will exit unexpectly.
The signal 32(SIGTIMER) will only used in musl timer and block for the SIGEV_THREAD. I think it can be seen as a special internal signal like 34. But in sigprocmask and pthread_sigmask, musl lacks protection for this signal. Users can modify the shielding status of such signals. Like in android, there is a function "filter_reserved_signals" used in sigprocmask to protect the internal signals state from being modified.
Considering that upper-layer users may not know the signal 32 has been blocked, should we add a default block for SIGTIMER in pthread_sigmask like android? Or is there other considerations?
Best
Li
[-- Attachment #2: Type: text/html, Size: 2024 bytes --]
reply other threads:[~2024-11-19 2:43 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=tencent_6AA362284986B012F97905C28CD39DE96806@qq.com \
--to=250200715@qq.com \
--cc=musl@lists.openwall.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.vuxu.org/mirror/musl/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).