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
| ||
|
Date: Tue, 7 Aug 2018 13:28:23 -0700 From: Andy Lutomirski <luto@...nel.org> To: Thomas Gleixner <tglx@...utronix.de> Cc: Andy Lutomirski <luto@...nel.org>, Dave Hansen <dave.hansen@...el.com>, Joerg Roedel <joro@...tes.org>, Ingo Molnar <mingo@...nel.org>, "H . Peter Anvin" <hpa@...or.com>, X86 ML <x86@...nel.org>, LKML <linux-kernel@...r.kernel.org>, Linux-MM <linux-mm@...ck.org>, Linus Torvalds <torvalds@...ux-foundation.org>, Josh Poimboeuf <jpoimboe@...hat.com>, Juergen Gross <jgross@...e.com>, Peter Zijlstra <peterz@...radead.org>, Borislav Petkov <bp@...en8.de>, Jiri Kosina <jkosina@...e.cz>, Boris Ostrovsky <boris.ostrovsky@...cle.com>, Brian Gerst <brgerst@...il.com>, David Laight <David.Laight@...lab.com>, Denys Vlasenko <dvlasenk@...hat.com>, Eduardo Valentin <eduval@...zon.com>, Greg KH <gregkh@...uxfoundation.org>, Will Deacon <will.deacon@....com>, "Liguori, Anthony" <aliguori@...zon.com>, Daniel Gruss <daniel.gruss@...k.tugraz.at>, Hugh Dickins <hughd@...gle.com>, Kees Cook <keescook@...gle.com>, Andrea Arcangeli <aarcange@...hat.com>, Waiman Long <llong@...hat.com>, Pavel Machek <pavel@....cz>, "David H . Gutteridge" <dhgutteridge@...patico.ca>, Joerg Roedel <jroedel@...e.de> Subject: Re: [PATCH 2/3] x86/mm/pti: Don't clear permissions in pti_clone_pmd() On Tue, Aug 7, 2018 at 1:21 PM, Thomas Gleixner <tglx@...utronix.de> wrote: > On Tue, 7 Aug 2018, Andy Lutomirski wrote: > >> On Tue, Aug 7, 2018 at 11:34 AM, Dave Hansen <dave.hansen@...el.com> wrote: >> > On 08/07/2018 03:24 AM, Joerg Roedel wrote: >> >> The function sets the global-bit on cloned PMD entries, >> >> which only makes sense when the permissions are identical >> >> between the user and the kernel page-table. >> >> >> >> Further, only write-permissions are cleared for entry-text >> >> and kernel-text sections, which are not writeable anyway. >> > >> > I think this patch is correct, but I'd be curious if Andy remembers why >> > we chose to clear _PAGE_RW on these things. It might have been that we >> > were trying to say that the *entry* code shouldn't write to this stuff, >> > regardless of whether the normal kernel can. >> > >> > But, either way, I agree with the logic here that Global pages must >> > share permissions between both mappings, so feel free to add my Ack. I >> > just want to make sure Andy doesn't remember some detail I'm forgetting. >> >> I suspect it's because we used to (and maybe still do) initialize the >> user tables before mark_read_only(). > > We still do that because we need the entry stuff working for interrupts > early on. We now repeat the clone after mark_ro so the mask RW is not > longer required. Agreed.
Powered by blists - more mailing lists