siphash

package
v0.6.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 21, 2024 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Overview

Package siphash implements SipHash-2-4, a fast short-input PRF created by Jean-Philippe Aumasson and Daniel J. Bernstein.

Index

Constants

View Source
const (
	// BlockSize is the block size of hash algorithm in bytes.
	BlockSize = 8

	// Size64 is the size of hash output in bytes.
	Size64 = 8

	// Size128 is the size of 128-bit hash output in bytes.
	Size128 = 16
)

Variables

This section is empty.

Functions

func New128

func New128(key []byte) hash.Hash

New128 returns a new hash.Hash computing SipHash-2-4 with 16-byte key and 16-byte output.

Note that 16-byte output is considered experimental by SipHash authors at this time.

func New64

func New64(key []byte) hash.Hash

New64 returns a new hash.Hash computing SipHash-2-4 with 16-byte key and 8-byte output.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL