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] [day] [month] [year] [list]
Message-ID: <20210113153408.GA26690@redhat.com>
Date:   Wed, 13 Jan 2021 16:34:08 +0100
From:   Oleg Nesterov <oleg@...hat.com>
To:     Marcus Huewe <suse-tux@....de>,
        Andrew Morton <akpm@...ux-foundation.org>
Cc:     linux-kernel@...r.kernel.org
Subject: Re: [PATCH] ptrace: Remove redundant code in ptrace_attach

Acked-by: Oleg Nesterov <oleg@...hat.com>


On 01/13, Marcus Huewe wrote:
>
> In case of a PTRACE_SEIZE request, the PT_SEIZED flag is always set
> at the beginning of ptrace_attach. Hence, there is no need to set
> it again (neither "flags" nor "seize" are modified in between/after
> the initial assignment).
> 
> Signed-off-by: Marcus Huewe <suse-tux@....de>
> ---
>  kernel/ptrace.c | 2 --
>  1 file changed, 2 deletions(-)
> 
> diff --git a/kernel/ptrace.c b/kernel/ptrace.c
> index 61db50f7ca86..059fce2ad53c 100644
> --- a/kernel/ptrace.c
> +++ b/kernel/ptrace.c
> @@ -402,8 +402,6 @@ static int ptrace_attach(struct task_struct *task, long request,
>  	if (task->ptrace)
>  		goto unlock_tasklist;
> 
> -	if (seize)
> -		flags |= PT_SEIZED;
>  	task->ptrace = flags;
> 
>  	ptrace_link(task, current);
> --
> 2.29.2
> 

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ