lkml.org 
[lkml]   [2014]   [Oct]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [resend Patch v3 1/2] kaslr: check if kernel location is changed
On 10/13/2014 08:19 AM, Vivek Goyal wrote:
>>>
>>> This really shouldn't have happened this way on x86-64. It has to happen
>>> this way on i386, but I worry that this may be a serious misdesign in kaslr
>>> on x86-64. I'm also wondering if there is any other fallout of this?
>>
>> I agree. On x86_64, we should stick to previous design and this new
>> logic of performing relocations does not sound very clean and makes
>> things very confusing.
>>
>> I am wondering that why couldn't we simply adjust page tables in case of
>> kaslr on x86_64, instead of performing relocations.
>
> Well, IIUC, if virtual addresses are shifted w.r.t what virtual address
> kernel was compiled for, then relocation will have to be done.
>
> So question will be if physical address shift is enough for kaslr or
> virtual address shift is necessary.
>

I would assume that without a virtual address shift kaslr is pretty darn
pointless. Without the physical address shift the 1:1 map can be used,
and again, kaslr becomes pointless. However, there is absolutely no
reason why they should be coupled. They can, in fact, be independently
randomized.

-hpa




\
 
 \ /
  Last update: 2014-10-13 18:21    [W:0.107 / U:0.124 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site