Follow @Openwall on Twitter for new release announcements and other news
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Wed, 11 Oct 2017 22:09:20 +0200
From: "Jason A. Donenfeld" <Jason@...c4.com>
To: "Tobin C. Harding" <me@...in.cc>
Cc: kernel-hardening@...ts.openwall.com, kvm@...r.kernel.org, 
	LKML <linux-kernel@...r.kernel.org>, 
	Linus Torvalds <torvalds@...ux-foundation.org>, Kees Cook <keescook@...omium.org>, 
	Paolo Bonzini <pbonzini@...hat.com>, Tycho Andersen <tycho@...ker.com>, 
	"Roberts, William C" <william.c.roberts@...el.com>, Tejun Heo <tj@...nel.org>, 
	Jordan Glover <Golden_Miller83@...tonmail.ch>, Greg KH <gregkh@...uxfoundation.org>, 
	Petr Mladek <pmladek@...e.com>, Joe Perches <joe@...ches.com>, Ian Campbell <ijc@...lion.org.uk>, 
	Sergey Senozhatsky <sergey.senozhatsky@...il.com>, Catalin Marinas <catalin.marinas@....com>, 
	Will Deacon <will.deacon@....com>, Steven Rostedt <rostedt@...dmis.org>, 
	Chris Fries <cfries@...gle.com>, Dave Weinstein <olorin@...gle.com>, 
	Daniel Micay <danielmicay@...il.com>, Djalal Harouni <tixxdz@...il.com>
Subject: Re: [PATCH 0/3] add %pX specifier

Hi Tobin,

On Wed, Oct 11, 2017 at 1:09 AM, Tobin C. Harding <me@...in.cc> wrote:
>
>   +        hashval = hash_three_words(
>   +                (unsigned long)ptr,
>   +                (unsigned long)ptr >> 16 >> 16,
>   +                boot_time_random_int);

This is most likely not what you want to be using. Take a look at the
siphash_* set of functions. If you're just hashing 1 64-bit pointer
with some secret, use siphash_1u64, for example. That's the right
interface for this purpose.

Regards,
Jason

Powered by blists - more mailing lists

Confused about mailing lists and their use? Read about mailing lists on Wikipedia and check out these guidelines on proper formatting of your messages.