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]
Date:	Tue, 11 Nov 2014 12:49:16 -0800
From:	Andy Lutomirski <luto@...capital.net>
To:	Andi Kleen <andi@...stfloor.org>, X86 ML <x86@...nel.org>
Cc:	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
	Andi Kleen <ak@...ux.intel.com>, Borislav Petkov <bp@...en8.de>
Subject: Re: [PATCH 4/8] x86: Add support for rd/wr fs/gs base

On Tue, Nov 11, 2014 at 12:05 PM, Andy Lutomirski <luto@...capital.net> wrote:
> On 11/10/2014 03:55 PM, Andi Kleen wrote:
>> To prevent recursive interrupts clobbering this
>> state in the task_struct this is only done for interrupts
>> coming directly from ring 3.
>
> Since this just came up in a different context today, I'd like to
> propose a different solution to this piece of the problem.
>
> Can we change the paranoid entry to check if the entry came from ring 3
> and to just switch stacks immediately to the standard kernel stack and
> run the non-paranoid entry code?  This eliminates paranoid_userspace
> entirely, and there are no special gsbase machinations any more for the
> entry-from-userspace path.
>
> In fact, I think that this will result in the MSR KERNEL_GS_BASE value
> *always* matching the userspace gs value from any C code in the kernel,
> since we'll always swapgs exactly once on entry from userspace.

I'll send patches in a couple hours.  I have it mostly working.

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