def encrypt_rounds
import bend-collections-laws-crypto@1.0.0.0/spec/crypto/chacha.bend as Chachaimport Base
166# chacha20_encrypt(key, counter, nonce, plaintext) with n double rounds.
167def encrypt_rounds(+n: Nat, +key: List<&2, U32>, counter: U32, +nonce: List<&2, U32>, +plaintext: List<&2, U32>) -> List<&2, U32>:
168 encrypt_blocks(blocks(List.length(&2, U32, plaintext), plaintext), n, key, counter, nonce)
Uses (6)
Used by (9)
- bend-collections-laws-crypto@1.0.0.0/spec/crypto/chacha:encrypt
- bend-collections-laws-crypto@1.0.0.0/proofs/crypto/chacha/stream:encrypt_correct
- bend-collections-laws-crypto@1.0.0.0/proofs/crypto/chacha/involution:involution
- bend-collections-laws-crypto@1.0.0.0/proofs/crypto/chacha/involution:encrypt_length
- bend-collections-laws-crypto@1.0.0.0/proofs/crypto/chacha/involution:encrypt_xor
- …