def open128
import bend-collections-laws-crypto@1.0.0.0/proofs/crypto/aes/api.bend as Apiimport Base
import bend-collections-laws-crypto@1.0.0.0/src/crypto/aesgcm.bend as GCM
23# Decrypt what an encryption returned (None stays None).
24def open128(+key: List<&2, U32>, +nonce: List<&2, U32>, +aad: List<&2, U32>, m: Maybe<&2, List<&2, U32>>) -> Maybe<&2, List<&2, U32>>:
25 match m:
26 case None{}:
27 None{}
28 case Some{ct}:
29 GCM.aes128_gcm_decrypt(key, nonce, aad, ct)
Uses (4)
Used by (6)
- bend-collections-laws-crypto@1.0.0.0/proofs/crypto/aes/api:aes128_roundtrip
- bend-collections-laws-crypto@1.0.0.0/proofs/crypto/aead/proof:open_seal
- bend-collections-laws-crypto@1.0.0.0/proofs/crypto/aead/proof:os128
- bend-collections-laws-crypto@1.0.0.0/proofs/crypto/aes/api:aes128_roundtrip_l
- bend-collections-laws-crypto@1.0.0.0/proofs/crypto/aes/proof:open128_same
- …