Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757514Ab3DZSxa (ORCPT ); Fri, 26 Apr 2013 14:53:30 -0400 Received: from mail-oa0-f49.google.com ([209.85.219.49]:54027 "EHLO mail-oa0-f49.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1757169Ab3DZSx2 (ORCPT ); Fri, 26 Apr 2013 14:53:28 -0400 MIME-Version: 1.0 In-Reply-To: <5179A7CE.2050605@zytor.com> References: <1366926860-26776-1-git-send-email-keescook@chromium.org> <5179A7CE.2050605@zytor.com> Date: Fri, 26 Apr 2013 11:53:28 -0700 X-Google-Sender-Auth: ujKAUzfq58Zf7gepY_7oWsjUHAg Message-ID: Subject: Re: [PATCH v3 0/6] kernel ASLR From: Kees Cook To: "H. Peter Anvin" Cc: LKML , "kernel-hardening@lists.openwall.com" , Thomas Gleixner , Ingo Molnar , "x86@kernel.org" , Jarkko Sakkinen , Matthew Garrett , Matt Fleming , Eric Northup , Dan Rosenberg , Julien Tinnes , Will Drewry Content-Type: text/plain; charset=ISO-8859-1 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1543 Lines: 37 On Thu, Apr 25, 2013 at 3:01 PM, H. Peter Anvin wrote: > On 04/25/2013 02:54 PM, Kees Cook wrote: >> This continues to build on the tip/kaslr patches for KASLR. This series >> converts the logic to C, and moves both relocation and address selection >> into the decompress_kernel path. Several areas were refactored to allow >> for some code reuse (e.g. CPU flags, kernel command line). >> >> This does not yet attempt to rework the page tables to handle an arbitrary >> physical memory location on x86_64. I would love some suggestions on >> how to do this. :) >> > > We *should* already support arbitrary physical memory locations at least > in the kernel proper (the decompressor might need some work.) > > We may want to do in the decompressor what we already do in the kernel, > and set up a #PF handler which creates page tables on demand. That way > you can simply treat the entire memory space as a single linear space. I'll need to compare the logic used for that against what's in head_64.S for setting up the initial tables. And mapping the kernel chunk as not 1-to-1, etc. In the meantime, I'll send a v4 series with the other identified changes since everything else (up to the 64-bit phy/virt detachment) seems to be working. -Kees -- Kees Cook Chrome OS Security -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/