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:   Fri, 29 Nov 2019 10:19:59 -0800
From:   Andy Lutomirski <luto@...capital.net>
To:     Oleg Nesterov <oleg@...hat.com>
Cc:     Linus Torvalds <torvalds@...ux-foundation.org>,
        Kees Cook <keescook@...omium.org>,
        Andrew Morton <akpm@...ux-foundation.org>,
        Andy Lutomirski <luto@...nel.org>,
        Borislav Petkov <bp@...en8.de>, Ingo Molnar <mingo@...nel.org>,
        Jan Kratochvil <jan.kratochvil@...hat.com>,
        Pedro Alves <palves@...hat.com>, Peter Anvin <hpa@...or.com>,
        Thomas Gleixner <tglx@...utronix.de>,
        Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
        the arch/x86 maintainers <x86@...nel.org>
Subject: Re: [PATCH] ptrace/x86: introduce TS_COMPAT_RESTART to fix get_nr_restart_syscall()



> On Nov 29, 2019, at 9:32 AM, Oleg Nesterov <oleg@...hat.com> wrote:
> 
> On 11/28, Andy Lutomirski wrote:
>> 
>> I think this doesn’t work for x32.
> 
> Why? get_nr_restart_syscall() can still rely on the "orig_ax & __X32_SYSCALL_BIT"
> check, debugger should restore regs->orig_ax correctly.

Right. Although relying on this is IMO a ridiculous bit of ABI.

> 
>> Let’s either save the result of syscall_get_arch()
> 
> We can save the result of syscall_get_arch(), but it doesn't distinguish
> x32/x86_64 tasks, so it doesn't really differ from TS_COMPAT.

Duh. Never mind.

> 
>> or just actually calculate and save the restart_syscall nr here.
> 
> sure, we we can do this.

I like this the best unless we can renumber the syscalls.

> 
>> Before we commit to this, Kees, do you think we can manage to just renumber
>> restart_syscall()?  That’s a much better solution if we can pull it off.
> 
> Agreed.
> 
> Oleg.
> 

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ