// NewShakeCipher256 creates a Cipher implementing the SHAKE256 algorithm, // which provides 256-bit security against all known attacks. func NewShakeCipher256(key []byte, options ...interface{}) abstract.Cipher { return cipher.FromSponge(newKeccak512(), key, append(shakeOpts, options...)...) }
// NewCipher512 creates a Cipher implementing the SHA3-512 algorithm, // which provides 512-bit security against preimage attacks // and 256-bit security against collisions. func NewCipher512(key []byte, options ...interface{}) abstract.Cipher { return cipher.FromSponge(newKeccak1024(), key, append(sha3opts, options...)...) }
func (s *shake) Reset() { s.cipher = cipher.FromSponge(s.sponge(), abstract.NoKey, cipher.Padding(0x1f)) s.squeezing = false }
// NewCipher creates a Cipher implementing the 64-4-1 mode of NORX. func NewCipher(key []byte, options ...interface{}) abstract.Cipher { return cipher.FromSponge(newSponge(), key, options...) }