Re: [go-nuts] A Measure of Hash Function Collisions

2019-02-19 Thread Serhat Sevki Dincer
Hi, Chris kindly searched collisions on his 6 TiB ram server and we could not find any for more than 5 x 2^37 inputs (for both + and ^ versions) ! Final version of the hash is available at https://github.com/jfcg/sixb Let me know if you find one ;) On Tue, Feb 19, 2019 at 10:44 AM Chris Burkert

Re: [go-nuts] A Measure of Hash Function Collisions

2019-02-13 Thread Serhat Sevki Dincer
14 Şub 2019 Per 01:58 tarihinde Michael Jones şunu yazdı: > Serhat, > > Some more ideas for you to consider: the expected number of collisions for > an ideal random hash, the option of "folding in" the high bits of the hash > rather than truncating, and finer control of operation. > >

Re: [go-nuts] A Measure of Hash Function Collisions

2019-02-13 Thread Michael Jones
Serhat, Some more ideas for you to consider: the expected number of collisions for an ideal random hash, the option of "folding in" the high bits of the hash rather than truncating, and finer control of operation. https://play.golang.org/p/92ERC4PJKAL On Wed, Feb 13, 2019 at 12:20 PM Serhat

Re: [go-nuts] A Measure of Hash Function Collisions

2019-02-13 Thread Serhat Şevki Dinçer
On Tuesday, February 12, 2019 at 9:51:17 PM UTC+3, Michael Jones wrote: > > Serhat, some ideas for you... > https://play.golang.org/p/7QPy5wa-9eO > Interestingly I found out input iteration order does matter :) 15,33 shift version yields an amazing number of collisions (7_910_886_368 collisions

Re: [go-nuts] A Measure of Hash Function Collisions

2019-02-12 Thread Michael Jones
Serhat, some ideas for you... https://play.golang.org/p/7QPy5wa-9eO On Tue, Feb 12, 2019 at 9:23 AM Damian Gryski wrote: > For more information on hash function goodness tests, check out > https://github.com/demerphq/smhasher > > Damian > > On Tuesday, February 12, 2019 at 5:23:39 AM UTC-8,

Re: [go-nuts] A Measure of Hash Function Collisions

2019-02-12 Thread Damian Gryski
For more information on hash function goodness tests, check out https://github.com/demerphq/smhasher Damian On Tuesday, February 12, 2019 at 5:23:39 AM UTC-8, Serhat Şevki Dinçer wrote: > > On Saturday, February 9, 2019 at 5:23:14 PM UTC+3, Serhat Şevki Dinçer > wrote: >> >> On Fri, Feb 8,

Re: [go-nuts] A Measure of Hash Function Collisions

2019-02-12 Thread Serhat Şevki Dinçer
On Saturday, February 9, 2019 at 5:23:14 PM UTC+3, Serhat Şevki Dinçer wrote: > > On Fri, Feb 8, 2019 at 7:42 PM Michael Jones wrote: > > clustering: > > https://www.cs.cornell.edu/courses/cs3110/2014fa/lectures/13/lec13.html > > > > careful hash functions often treat short inputs specially.

Re: [go-nuts] A Measure of Hash Function Collisions

2019-02-09 Thread Serhat Sevki Dincer
On Fri, Feb 8, 2019 at 7:42 PM Michael Jones wrote: > clustering: > https://www.cs.cornell.edu/courses/cs3110/2014fa/lectures/13/lec13.html > > careful hash functions often treat short inputs specially. > > iterated shift-xor alone is weak in expanding the "changed bits(s)" signal, > at least by

Re: [go-nuts] A Measure of Hash Function Collisions

2019-02-08 Thread Michael Jones
clustering: https://www.cs.cornell.edu/courses/cs3110/2014fa/lectures/13/lec13.html careful hash functions often treat short inputs specially. iterated shift-xor alone is weak in expanding the "changed bits(s)" signal, at least by comparison to a) large prime multiply, b) good s-boxes, c)

Re: [go-nuts] A Measure of Hash Function Collisions

2019-02-08 Thread Serhat Sevki Dincer
8 Şub 2019 Cum 11:57 tarihinde Michael Jones şunu yazdı: > ...says that in one particular test condition (8 character strings, 1M > random strings, all possible shift values) > and under one particular metric of virtue... > > x = x<<15 ^ x>>33 > > ...gives the closest overall approximation to a

Re: [go-nuts] A Measure of Hash Function Collisions

2019-02-08 Thread Michael Jones
one quick result: celeste:spin10 mtj$ spin10 -a 0,63 -b 0,63 -bins 32 -rotate ab -set 0,0,0,0 -samples 10 -trials 10 [0] best 5.683527373827505613e+01 8 0 0 0 [1] best 5.508690460484671547e+01 8 1 0 0 [2] best 5.434519430630660253e+01 8 2 0 0 [4]

Re: [go-nuts] A Measure of Hash Function Collisions

2019-02-07 Thread Serhat Şevki Dinçer
On Tuesday, February 5, 2019 at 12:29:32 AM UTC+3, Michael Jones wrote: > I recently did just this in an effort (successful!) to make a well-known > simple hash function be its best with minor single CPU cycle changes. > yes I am told 15 is not the best shift amount, how about this? x = x<<27

Re: [go-nuts] A Measure of Hash Function Collisions

2019-02-04 Thread Michael Jones
There are many measures. One realm of them focus on the mixing properties of the design as would be a consideration in cypher systems. The other “experimentalist” realm considers how the hash performs compared to an ideal hash function. The latter approach is suitable for a broader range of

[go-nuts] A Measure of Hash Function Collisions

2019-02-04 Thread Serhat Şevki Dinçer
Hi, What is the minimum sum of input lengths len(s1)+len(s2) such that: - s1, s2 are distinct utf8 strings - Txt2int(s1) = Txt2int(s2) for the below simple hash function ? func Txt2int(s string) uint64 { x := uint64(len(s)) for i := len(s) - 1; i >= 0; i-- { x =