lkml.org 
[lkml]   [2017]   [Dec]   [10]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Date
SubjectRe: [PATCH tip/core/rcu 02/20] torture: Prepare scripting for shift from %p to %pK
On Sun, Dec 10, 2017 at 4:52 AM, Andy Shevchenko
<andy.shevchenko@gmail.com> wrote:
>>
>>> Perhaps it should have printed a fixed, non-zero value for non-zero
>>> pointers.
>>
>> I must leave this to the people who have a dog in that contest. ;-)
>
> Since there is an ongoing discussion with security people near to %pK
> and alike, I added Kees and Linus to Cc list.
>
> The proposed change can be done easily, though I have no knowledge
> about possible implications.

I'd rather make %pK act more like %p than have gratuitous differences.

I also think %pK is kind of pointless in general. It has not been a
big success, and the whole "root or not" is kind of nasty anyway. Root
in a container? Things like that.

So I think that if people worry about leaking pointers, they should
primarily go for:

- just use %p and now get the hashed value

- if the hashed value is pointless, ask yourself whether the pointer
itself is important. Maybe it should be removed?

- as a last option, if you really think the true pointer value is
important, why is root so special, and maybe you should use %px and
make sure you have proper sensible permissions.

..and %pK just isn't really the answer in any of those cases.

Linus

\
 
 \ /
  Last update: 2017-12-10 21:39    [W:0.112 / U:3.540 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site