Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Go package blake256 implements BLAKE-256 and BLAKE-224 hash functions (SHA-3 finalist).
Go
branch: master

Make pad global variable.

Core 2 Duo MacBook benchmarks:

Before:

BenchmarkHash1K  200000     10514 ns/op  97.39 MB/s
BenchmarkHash8K   200000     84057 ns/op  97.46 MB/s
BenchmarkFull64 1000000      1962 ns/op  32.62 MB/s

After:

BenchmarkHash1K  200000     10515 ns/op  97.38 MB/s
BenchmarkHash8K   200000     84027 ns/op  97.49 MB/s
BenchmarkFull64 1000000      1934 ns/op  33.08 MB/s
latest commit 8f6fa0f80d
@dchest authored

README.markdown

Package blake256

import "github.com/dchest/blake256"

Package blake256 implements BLAKE-256 and BLAKE-224 hash functions (SHA-3 candidate).

Public domain.

Constants

const BlockSize = 64

The block size of the hash algorithm in bytes.

const Size = 32

The size of BLAKE-256 hash in bytes.

const Size224 = 28

The size of BLAKE-224 hash in bytes.

Functions

func New

func New() hash.Hash

New returns a new hash.Hash computing the BLAKE-256 checksum.

func New224

func New224() hash.Hash

New224 returns a new hash.Hash computing the BLAKE-224 checksum.

func New224Salt

func New224Salt(salt []byte) hash.Hash

New224Salt is like New224 but initializes salt with the given 16-byte slice.

func NewSalt

func NewSalt(salt []byte) hash.Hash

NewSalt is like New but initializes salt with the given 16-byte slice.

Something went wrong with that request. Please try again.