PROOF.pk.at: def of bend-osdev-pkcs7@0.1.0.0 Import: import bend-osdev-pkcs7@0.1.0.0/PROOF.bend as PROOF Lines 1322-1330 of bend-osdev-pkcs7@0.1.0.0/PROOF.bend: https://jend.leeeet.dev/read.txt?path=bend-osdev-pkcs7@0.1.0.0/PROOF.bend&start_line=1322&end_line=1330 import Base import bend-osdev-bytes@0.1.1.0/bytes.bend as B import bend-osdev-bytes@0.1.1.0/LAWS.bend as BL import bend-osdev-pkcs7@0.1.0.0/pkcs7.bend as P # its last byte, at L + p1 of m and it def pk.at(+m: B.Octets, +p1: Nat) -> {B.Octets.at(B.Octets.append(m, pk.pad(p1)), Nat.add(B.Octets.len(m), p1)) == Some{B.byte(U32.from_nat(1n+p1))} : Maybe<&2, U32>}: %Equal.sym(Maybe<&2, U32>, B.Octets.at(B.Octets.append(m, pk.pad(p1)), Nat.add(B.Octets.len(m), p1)), B.Octets.at(pk.pad(p1), p1), BL.octets_at_append_add(m, pk.pad(p1), p1)) : {_ == Some{B.byte(U32.from_nat(1n+p1))} : Maybe<&2, U32>} %Equal.sym(Maybe<&2, U32>, B.Octets.at(pk.pad(p1), p1), B.at(B.Octets.to_list(pk.pad(p1)), p1), BL.octets_at_list(pk.pad(p1), p1)) : {_ == Some{B.byte(U32.from_nat(1n+p1))} : Maybe<&2, U32>} %Equal.sym(List<&2, U32>, B.Octets.to_list(pk.pad(p1)), B.mask(P.pkcs7.fill(1n+p1, U32.from_nat(1n+p1))), BL.octets_to_of(P.pkcs7.fill(1n+p1, U32.from_nat(1n+p1)))) : {B.at(_, p1) == Some{B.byte(U32.from_nat(1n+p1))} : Maybe<&2, U32>} %Equal.sym(List<&2, U32>, B.mask(P.pkcs7.fill(1n+p1, U32.from_nat(1n+p1))), P.pkcs7.fill(1n+p1, B.byte(U32.from_nat(1n+p1))), pk.mask_fill(1n+p1, U32.from_nat(1n+p1))) : {B.at(_, p1) == Some{B.byte(U32.from_nat(1n+p1))} : Maybe<&2, U32>} %Equal.sym(List<&2, U32>, B.drop(p1, P.pkcs7.fill(1n+p1, B.byte(U32.from_nat(1n+p1)))), Con{B.byte(U32.from_nat(1n+p1)), Nil{}}, pk.drop_fill(p1, B.byte(U32.from_nat(1n+p1)))) : {B.at.head(_) == Some{B.byte(U32.from_nat(1n+p1))} : Maybe<&2, U32>} %pk.bb(U32.from_nat(1n+p1)) : {Some{B.byte(B.byte(U32.from_nat(1n+p1)))} == Some{_} : Maybe<&2, U32>} {==} Uses (25): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Equal.sym https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=List https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Maybe https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Nat https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Nat.add https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32 https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32.from_nat https://jend.leeeet.dev/definition.txt?path=bend-osdev-bytes@0.1.1.0/LAWS.bend&name=octets_at_append_add https://jend.leeeet.dev/definition.txt?path=bend-osdev-bytes@0.1.1.0/LAWS.bend&name=octets_at_list https://jend.leeeet.dev/definition.txt?path=bend-osdev-bytes@0.1.1.0/LAWS.bend&name=octets_to_of https://jend.leeeet.dev/definition.txt?path=bend-osdev-bytes@0.1.1.0/bytes.bend&name=Octets https://jend.leeeet.dev/definition.txt?path=bend-osdev-bytes@0.1.1.0/bytes.bend&name=Octets.append https://jend.leeeet.dev/definition.txt?path=bend-osdev-bytes@0.1.1.0/bytes.bend&name=Octets.at https://jend.leeeet.dev/definition.txt?path=bend-osdev-bytes@0.1.1.0/bytes.bend&name=Octets.len https://jend.leeeet.dev/definition.txt?path=bend-osdev-bytes@0.1.1.0/bytes.bend&name=Octets.to_list https://jend.leeeet.dev/definition.txt?path=bend-osdev-bytes@0.1.1.0/bytes.bend&name=at https://jend.leeeet.dev/definition.txt?path=bend-osdev-bytes@0.1.1.0/bytes.bend&name=at.head https://jend.leeeet.dev/definition.txt?path=bend-osdev-bytes@0.1.1.0/bytes.bend&name=byte https://jend.leeeet.dev/definition.txt?path=bend-osdev-bytes@0.1.1.0/bytes.bend&name=drop https://jend.leeeet.dev/definition.txt?path=bend-osdev-bytes@0.1.1.0/bytes.bend&name=mask https://jend.leeeet.dev/definition.txt?path=bend-osdev-pkcs7@0.1.0.0/PROOF.bend&name=pk.bb https://jend.leeeet.dev/definition.txt?path=bend-osdev-pkcs7@0.1.0.0/PROOF.bend&name=pk.drop_fill https://jend.leeeet.dev/definition.txt?path=bend-osdev-pkcs7@0.1.0.0/PROOF.bend&name=pk.mask_fill https://jend.leeeet.dev/definition.txt?path=bend-osdev-pkcs7@0.1.0.0/PROOF.bend&name=pk.pad https://jend.leeeet.dev/definition.txt?path=bend-osdev-pkcs7@0.1.0.0/pkcs7.bend&name=pkcs7.fill