Re: [PATCH 3/6] x86: kaslr: return location from decompress_kernel
From: H. Peter Anvin
Date: Fri Apr 26 2013 - 17:48:14 EST
On 04/26/2013 12:03 PM, Kees Cook wrote:
> This allows decompress_kernel to return a new location for the kernel to
> be relocated to. With CONFIG_RANDOMIZE_BASE, the choose_kernel_location
> routine will select a new location to decompress the kernel, and is
> presently a no-op. The logic for bypassing this routine with "noaslr"
> on the kernel command line is handled.
>
> Signed-off-by: Kees Cook <keescook@xxxxxxxxxxxx>
> ---
> Documentation/kernel-parameters.txt | 4 ++++
> arch/x86/boot/compressed/Makefile | 2 +-
> arch/x86/boot/compressed/aslr.c | 21 +++++++++++++++++++++
> arch/x86/boot/compressed/cmdline.c | 2 +-
> arch/x86/boot/compressed/head_32.S | 2 +-
> arch/x86/boot/compressed/head_64.S | 2 +-
> arch/x86/boot/compressed/misc.c | 7 +++++--
> arch/x86/boot/compressed/misc.h | 22 ++++++++++++++++------
> 8 files changed, 50 insertions(+), 12 deletions(-)
> create mode 100644 arch/x86/boot/compressed/aslr.c
>
> diff --git a/Documentation/kernel-parameters.txt b/Documentation/kernel-parameters.txt
> index 8ccbf27..eb1c62c 100644
> --- a/Documentation/kernel-parameters.txt
> +++ b/Documentation/kernel-parameters.txt
> @@ -1862,6 +1862,10 @@ bytes respectively. Such letter suffixes can also be entirely omitted.
> noapic [SMP,APIC] Tells the kernel to not make use of any
> IOAPICs that may be present in the system.
>
> + noaslr [X86]
> + Disable kernel base offset ASLR (Address Space
> + Layout Randomization) if built into the kernel.
> +
> noautogroup Disable scheduler automatic task group creation.
>
> nobats [PPC] Do not use BATs for mapping kernel lowmem
Calling it "nokaslr" might be useful to note that it is specifically
about the kernel.
-hpa
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/