def keystream

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

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

60# The 64 keystream bytes of block `counter`, with r double rounds.
61def keystream(+r: Nat, k: Key, counter: U32, n: Nonce) -> List<&2, U32>:
62  C.bytes(C.block(r, state(k, counter, n)))

Uses (8)

Used by (6)