def rc4_xs_append
bend-osdev-legacy-ciphers@0.1.0.0 · PROOF.bend:8483
import bend-osdev-legacy-ciphers@0.1.0.0/PROOF.bend as PROOF
import Base
import bend-osdev-bytes@0.1.0.0/bytes.bend as B
import bend-osdev-legacy-ciphers@0.1.0.0/rc4.bend as R
8483def rc4_xs_append(xs: List<&2, U32>, +ys: List<&2, U32>, +st: R.LcRc4State) -> {R.rc4.xs(B.append(xs, ys), st) == B.append(R.rc4.xs(xs, st), R.rc4.xs(ys, R.rc4.after(xs, st))) : List<&2, U32>}:
8484 match xs:
8485 case Nil{}:
8486 {==}
8487 case Con{+x, +t}:
8488 %rc4_xs_append(t, ys, R.rc4.step.st(R.rc4.next(st))) : {Con{B.byte(U32.xor(x, R.rc4.step.k(R.rc4.next(st)))), R.rc4.xs(B.append(t, ys), R.rc4.step.st(R.rc4.next(st)))} == Con{B.byte(U32.xor(x, R.rc4.step.k(R.rc4.next(st)))), _} : List<&2, U32>}
8489 {==}