PROOF.sm4_unstep_step: def of bend-osdev-legacy-ciphers@0.1.0.0 Import: import bend-osdev-legacy-ciphers@0.1.0.0/PROOF.bend as PROOF Lines 239-243 of bend-osdev-legacy-ciphers@0.1.0.0/PROOF.bend: https://jend.leeeet.dev/read.txt?path=bend-osdev-legacy-ciphers@0.1.0.0/PROOF.bend&start_line=239&end_line=243 import Base import bend-osdev-cipher-modes@0.1.0.0/cipher_modes.bend as M import bend-osdev-legacy-ciphers@0.1.0.0/legacy_ciphers.bend as L import bend-osdev-legacy-ciphers@0.1.0.0/sm4.bend as S def sm4_unstep_step(+tab: L.LcTab, +rk: U32, s: M.CmBlock) -> {s == S.sm4.unstep(tab, rk, S.sm4.step(tab, rk, s)) : M.CmBlock}: match s: case M.CmBlock{x0, +x1, +x2, +x3}: %u32_xx(x0, S.sm4.t(tab, U32.xor(U32.xor(U32.xor(x1, x2), x3), rk))) : {M.CmBlock{x0, x1, x2, x3} == M.CmBlock{_, x1, x2, x3} : M.CmBlock} {==} Uses (8): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32 https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32.xor https://jend.leeeet.dev/definition.txt?path=bend-osdev-cipher-modes@0.1.0.0/cipher_modes.bend&name=CmBlock https://jend.leeeet.dev/definition.txt?path=bend-osdev-legacy-ciphers@0.1.0.0/PROOF.bend&name=u32_xx https://jend.leeeet.dev/definition.txt?path=bend-osdev-legacy-ciphers@0.1.0.0/legacy_ciphers.bend&name=LcTab https://jend.leeeet.dev/definition.txt?path=bend-osdev-legacy-ciphers@0.1.0.0/sm4.bend&name=sm4.step https://jend.leeeet.dev/definition.txt?path=bend-osdev-legacy-ciphers@0.1.0.0/sm4.bend&name=sm4.t https://jend.leeeet.dev/definition.txt?path=bend-osdev-legacy-ciphers@0.1.0.0/sm4.bend&name=sm4.unstep