From: bugzilla-daemon@kernel.org
To: linux-man@vger.kernel.org
Subject: [Bug 217001] New: Undocumented behavior of ptrace(2) when a seized process gets SIGCONT
Date: Sat, 04 Feb 2023 08:15:43 +0000 [thread overview]
Message-ID: <bug-217001-11311@https.bugzilla.kernel.org/> (raw)
https://bugzilla.kernel.org/show_bug.cgi?id=217001
Bug ID: 217001
Summary: Undocumented behavior of ptrace(2) when a seized
process gets SIGCONT
Product: Documentation
Version: unspecified
Hardware: All
OS: Linux
Status: NEW
Severity: normal
Priority: P1
Component: man-pages
Assignee: documentation_man-pages@kernel-bugs.osdl.org
Reporter: takahashi.shuhei@gmail.com
Regression: No
When we use ptrace(PTRACE_SEIZE) to attach to a process, sending SIGCONT to the
tracee causes the tracer to get notified with PTRACE_EVENT_STOP with SIGTRAP,
but this behavior is not documented in the ptrace(2) man page.
The man page says:
> PTRACE_EVENT_STOP
> Stop induced by PTRACE_INTERRUPT command, or group-stop,
> or initial ptrace-stop when a new child is attached (only
> if attached using PTRACE_SEIZE).
Here's code to reproduce the behavior (in Rust):
https://github.com/nix-rust/nix/pull/1996/files#diff-65efa0db9bf3f9cbccfee8c987cb6c98ecf77576e0b46a87cab7ec4cfcbff172R324
I saw this behavior is explained in the following stackoverflow entry.
https://stackoverflow.com/a/49468347
--
You may reply to this email to add a comment.
You are receiving this mail because:
You are watching the assignee of the bug.
next reply other threads:[~2023-02-04 8:15 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-02-04 8:15 bugzilla-daemon [this message]
2023-05-19 12:12 ` [Bug 217001] Undocumented behavior of ptrace(2) when a seized process gets SIGCONT bugzilla-daemon
2023-05-19 12:12 ` bugzilla-daemon
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=bug-217001-11311@https.bugzilla.kernel.org/ \
--to=bugzilla-daemon@kernel.org \
--cc=linux-man@vger.kernel.org \
/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.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox