Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[github patch] Switch to the (more collision-resilient?) SipHash function #6366

Closed
vicuna opened this issue Apr 12, 2014 · 1 comment
Closed

Comments

@vicuna
Copy link

vicuna commented Apr 12, 2014

Original bug ID: 6366
Reporter: @gasche
Status: closed (set by @alainfrisch on 2016-12-07T17:43:47Z)
Resolution: suspended
Priority: normal
Severity: feature
Version: 4.02.0+dev
Category: standard library
Tags: github, patch

Bug description

#24

The patchset changes the C API exposed in hash.h to make it digest-agnostic
(so as to make future changes simpler) and switches the hash function to
SipHash-2-4.

SipHash is a familly of cryptographically-strong hash functions which are
competitive (performance-wise) with MurmurHash, the hash function currently used. SipHash-2-4 ( https://131002.net/siphash/ ) is the recommended version of SipHash.

Preliminary benchmarks look good. However, they were done using the functorized
version of Hashtbl, and this specific proposal hasn't been benchmarked yet.

Caveats:

  • The testsuite hasn't been fixed yet (expected values changed for hashes)
    Commits expected to change the behaviour of the hash function are nbraud@28bde97 ( https://github.com/nbraud/ocaml/commit/28bde97b8 ) and nbraud@7dde207 ( https://github.com/nbraud/ocaml/commit/7dde207fe )

  • This patchset doesn't change the bit-width of the key and output (32 bits).
    This weakens the hash function, compared to SipHash-2-4 as specified by its authors, but isn't fixable without breaking the API.

@vicuna
Copy link
Author

vicuna commented Dec 7, 2016

Comment author: @alainfrisch

We no longer mirror Github PR on Mantis, so closing this ticket.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant