# README
Hash Functions
This package implements the hash functions specified in the noise protocol framework.
Built-in Hash Functions
Four hash functions are supported, as specified in the noise specs.
Customize Hash Functions
To create your own hash function, you'll need to implement the interface specified in hash.go
. Once implemented, you need to register it using Register(Name, Hash)
.
Check examples/newhash, which implements SHA3
, once implemented, Once implemented, it can be used via the protocol name,
// register SHA3
noiseHash.Register("SHA3", newSha3)
// Now "SHA3" is a valid hash name, and it can be used in the protocol name as,
p, _ := babble.NewProtocol("Noise_NN_25519_ChaChaPoly_SHA3", "Demo", true)