law xchacha20.valid
import bend-collections-laws-crypto@1.0.0.0/proofs/crypto/chacha/laws.bend as Lawsimport Base
import bend-collections-laws-crypto@1.0.0.0/src/crypto/chacha/chacha20.bend as I
import bend-collections-laws-crypto@1.0.0.0/spec/crypto/chacha.bend as R
98law xchacha20.valid:
99 for +key: List<&2, U32>
100 for +counter: U32
101 for +nonce: List<&2, U32>
102 for +plaintext: List<&2, U32>
103 for +hk: {List.length(&2, U32, key) == 32n : Nat}
104 for +hn: {List.length(&2, U32, nonce) == 24n : Nat}
105 {I.xchacha20(key, counter, nonce, plaintext) == Some{R.xencrypt(key, counter, nonce, plaintext)} : Maybe<&2, List<&2, U32>>}
Uses (14)
Used by (0)
No other definition uses this definition.