Re: [PATCH v3 0/4] Allow customizable random offset to mmap_base address.
From: Michael Ellerman
Date: Thu Nov 26 2015 - 02:08:05 EST
On Tue, 2015-11-24 at 16:39 -0800, Andrew Morton wrote:
> On Wed, 18 Nov 2015 15:20:04 -0800 Daniel Cashman <dcashman@xxxxxxxxxxx> wrote:
> > Address Space Layout Randomization (ASLR) provides a barrier to
> > exploitation of user-space processes in the presence of security
> > vulnerabilities by making it more difficult to find desired code/data
> > which could help an attack. This is done by adding a random offset to the
> > location of regions in the process address space, with a greater range of
> > potential offset values corresponding to better protection/a larger
> > search-space for brute force, but also to greater potential for
> > fragmentation.
>
> mips, powerpc and s390 also implement arch_mmap_rnd(). Are there any
> special considerations here, or it just a matter of maintainers wiring
> it up and testing it?
I had a quick stab at powerpc. It seems to work OK, though I've only tested on
64-bit 64K pages.
I'll update this when Daniel does a version which supports a DEFAULT for both
MIN values.
cheers