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: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Wed, 2 Mar 2011 16:25:50 +0100
From:	Tejun Heo <tj@...nel.org>
To:	Denys Vlasenko <vda.linux@...glemail.com>
Cc:	Oleg Nesterov <oleg@...hat.com>,
	Roland McGrath <roland@...hat.com>, jan.kratochvil@...hat.com,
	linux-kernel@...r.kernel.org, torvalds@...ux-foundation.org,
	akpm@...ux-foundation.org
Subject: Re: [RFC] Proposal for ptrace improvements

Hey,

On Wed, Mar 02, 2011 at 04:16:50PM +0100, Denys Vlasenko wrote:
> Assuming the program is run under simple debugger which
> resumes execution using PTRACE_CONT(sig) on signal delivery stops,
> with PTRACE_CONT(0) on ptrace stops,
> and doesn't do any PTRACE_CONT on job control stops,
> with your proposal the debugger will see and perform
> the following actions:
> 
> waitpid...
>   <------ kill -STOP 16382
> waitpid returns WSTOPPED, WSTOPSIG = SIGSTOP
> ptrace(PTRACE_GETSIGINFO) doesn't fail (=> it's signal delivery)
> ptrace(PTRACE_CONT, SIGSTOP)
> waitpid returns WSTOPPED, WSTOPSIG = SIGSTOP
> ptrace(PTRACE_GETSIGINFO) fails (=> it's job control stop)
> waitpid...
>   <------ kill -ABRT 16382
> ...debugger doesn't wake up...
>   <------ kill -WINCH 16382
> ...debugger doesn't wake up...
>   <------ kill -CONT 16382
> waitpid returns WSTOPPED, WSTOPSIG = SIGTRAP (it's a ptrace-stop)
> ptrace(PTRACE_CONT, 0)
> waitpid returns WSTOPPED, WSTOPSIG = SIGWINCH
> ptrace(PTRACE_CONT, SIGWINCH)
> waitpid returns WSTOPPED, WSTOPSIG = SIGCONT
> ptrace(PTRACE_CONT, SIGCONT)
> waitpid returns WSTOPPED, WSTOPSIG = SIGABRT
> ptrace(PTRACE_CONT, SIGABRT)
> 
> Correct?

Yeah, seems correct to me.

Thanks.

-- 
tejun
--
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