lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <201105082358.20159.vda.linux@googlemail.com>
Date:	Sun, 8 May 2011 23:58:20 +0200
From:	Denys Vlasenko <vda.linux@...glemail.com>
To:	Tejun Heo <tj@...nel.org>
Cc:	oleg@...hat.com, jan.kratochvil@...hat.com,
	linux-kernel@...r.kernel.org, torvalds@...ux-foundation.org,
	akpm@...ux-foundation.org, indan@....nu
Subject: Re: [PATCH 04/11] ptrace: implement PTRACE_INTERRUPT

On Sunday 08 May 2011 17:48, Tejun Heo wrote:
> Currently, there's no way to trap a running ptracee short of sending a
> signal which has various side effects.  This patch implements
> PTRACE_INTERRUPT which traps ptracee without any signal or job control
> related side effect.

What are the rules for the userspace? You said about PTRACE_SEIZE:

> After PTRACE_SEIZE, tracee will trap.  Which trap will happen isn't
> fixed.  If other trap conditions exist (signal delivery or group
> stop), they might be taken; otherwise, a trap with exit_code SIGTRAP |
> (PTRACE_EVENT_INTERRUPT << 8) is taken.  The followings are
> guaranteed.
> 
> * A trap will happen in finite amount of userland time.
> 
> * The trap can be PTRACE_EVENT_INTERRUPT which doesn't have any side
>   effect.  If a different trap is taken, no INTERRUPT trap is pending.
> 
> IOW, no matter what, one trap will happen, which might be INTERRUPT.

Are rules for PTRACE_INTERRUPT the same? That is, what happens
if a different trap is taken?

Can you add API notes in the header, above corresponding defines? -

--- a/include/linux/ptrace.h
+++ b/include/linux/ptrace.h
@@ -48,6 +48,7 @@
 #define PTRACE_SETREGSET       0x4205
 
<============================================ ADD COMMENT HERE
 #define PTRACE_SEIZE           0x4206
<============================================ ADD COMMENT HERE
+#define PTRACE_INTERRUPT       0x4207


They will be much more visible and up-to-date there than in Documentation,
git logs etc...

And finally, thanks for working on the long-needed evolutionary fixes to ptrace!

-- 
vda
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ