Chacha20.xencrypt_unchecked: def of bend-collections@1.0.0.0 Import: import bend-collections@1.0.0.0/src/crypto/chacha/chacha20.bend as Chacha20 Lines 126-130 of bend-collections@1.0.0.0/src/crypto/chacha/chacha20.bend: https://jend.leeeet.dev/read.txt?path=bend-collections@1.0.0.0/src/crypto/chacha/chacha20.bend&start_line=126&end_line=130 import Base # XChaCha20: ChaCha20 under the HChaCha20 subkey of nonce[0..16], with the # nonce 0x00000000 || nonce[16..24]. def xencrypt_unchecked(key_bytes: List<&2, U32>, counter: U32, +nonce_bytes: List<&2, U32>, +plaintext: List<&2, U32>) -> List<&2, U32>: +sub = hchacha20_unchecked(key_bytes, take(16n, nonce_bytes)) encrypt_rounds(10n, sub, counter, 0 <> 0 <> 0 <> 0 <> skip(16n, nonce_bytes), plaintext) Uses (6): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=List https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32 https://jend.leeeet.dev/definition.txt?path=bend-collections@1.0.0.0/src/crypto/chacha/chacha20.bend&name=encrypt_rounds https://jend.leeeet.dev/definition.txt?path=bend-collections@1.0.0.0/src/crypto/chacha/chacha20.bend&name=hchacha20_unchecked https://jend.leeeet.dev/definition.txt?path=bend-collections@1.0.0.0/src/crypto/chacha/chacha20.bend&name=skip https://jend.leeeet.dev/definition.txt?path=bend-collections@1.0.0.0/src/crypto/chacha/chacha20.bend&name=take