def cipher

bend-collections-laws-crypto@1.0.0.0 · src/crypto/aes/aes.bend:65

import bend-collections-laws-crypto@1.0.0.0/src/crypto/aes/aes.bend as Aes
import Base
import bend-collections-laws-crypto@1.0.0.0/src/crypto/aes/types.bend as T

65def cipher(+nr: Nat, s: T.State, ks: List<&2, T.State>) -> T.State:
66  match ks:
67    case k <> rest:
68      rounds(Nat.sub(nr, 1n), add_round_key(s, k), rest)
69    case Nil{}:
70      s

Uses (6)

Used by (4)