Giter Site home page Giter Site logo

pombredanne / siphash-2 Goto Github PK

View Code? Open in Web Editor NEW

This project forked from veorq/siphash

0.0 1.0 0.0 44 KB

High-speed pseudorandom function (reference code)

Home Page: https://131002.net/siphash

License: Creative Commons Zero v1.0 Universal

C 40.17% Makefile 1.63% Objective-C 58.20%

siphash-2's Introduction

SipHash

Reference implementation of SipHash, a family of pseudorandom functions optimized for speed on short messages.

SipHash was designed as a mitigation to hash-flooding DoS attacks. It is now used in the hash tables implementation of Python, Ruby, Perl 5, etc.

SipHash was designed by Jean-Philippe Aumasson and Daniel J. Bernstein.

Usage

Running

  make

will build tests for

  • SipHash-2-4, the default version of SipHash returning 64-bit tags
  • SipHash-2-4 with doubled tag size, i.e. 128-bit tags
  • HalfSipHash-2-4, a version of SipHash working with 32-bit words and returning 32-bit tags by default
  • HalfSipHash-2-4 with doubled tag size, i.e. 64-bit tags
  ./test

verifies 64 test vectors, and

  ./debug

does the same and prints intermediate values.

The code can be adapted to implement SipHash-c-d, the version of SipHash with c compression rounds and d finalization rounds, by tweaking the lines

#define cROUNDS 2
#define dROUNDS 4

Obviously, if the number of rounds is modified then the test vectors won't verify.

Intellectual property

The SipHash reference code is released under CC0 license, a public domain-like licence.

We aren't aware of any patents or patent applications relevant to SipHash, and we aren't planning to apply for any.

References

The SipHash page includes

  • a list of third-party implementations and modules
  • a list of projects using SipHash
  • references to cryptanalysis results

siphash-2's People

Contributors

dchest avatar veorq avatar zx2c4 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.