def pow_bit
import bend-collections-laws-crypto@1.0.0.0/src/crypto/curve25519/field.bend as Fieldimport Base
227# one bit of a public exponent, most significant first: acc^2 (* x)
228def pow_bit(b: Bool, +x: List<&2, U32>, acc: List<&2, U32>) -> List<&2, U32>:
229 match b:
230 case True{}:
231 mul(sq(acc), x)
232 case False{}:
233 sq(acc)
Uses (5)
Used by (6)
- bend-collections-laws-crypto@1.0.0.0/src/crypto/curve25519/field:pow_bits
- bend-collections-laws-crypto@1.0.0.0/proofs/crypto/curve25519/pow:pbs_okb
- bend-collections-laws-crypto@1.0.0.0/proofs/crypto/curve25519/pow:pb_okb
- bend-collections-laws-crypto@1.0.0.0/proofs/crypto/curve25519/pow:pbs_con
- bend-collections-laws-crypto@1.0.0.0/proofs/crypto/curve25519/pow:pb_val
- …