def chacha20

bend-collections@1.0.0.0 · src/crypto/chacha/chacha20.bend:150

import bend-collections@1.0.0.0/src/crypto/chacha/chacha20.bend as Chacha20
import Base

150# chacha20_encrypt(key, counter, nonce, plaintext) (encryption and decryption
151# are the same operation).
152def chacha20(+key_bytes: List<&2, U32>, counter: U32, +nonce_bytes: List<&2, U32>, +plaintext: List<&2, U32>) -> Maybe<&2, List<&2, U32>>:
153  when(valid(key_bytes, nonce_bytes, 12n), encrypt_rounds(10n, key_bytes, counter, nonce_bytes, plaintext))

Uses (6)

Used by (0)

No other definition uses this definition.