def sign_ok

bend-collections-laws-crypto@1.0.0.0 · spec/crypto/secp256k1/schnorr.bend:159

import bend-collections-laws-crypto@1.0.0.0/spec/crypto/secp256k1/schnorr.bend as Schnorr
import Base
import bend-collections-laws-crypto@1.0.0.0/spec/crypto/secp256k1/curve.bend as CV

159def sign_ok(+one: Nat, +sk: List<&2, U32>, +m: List<&2, U32>, +aux: List<&2, U32>, ok: Bool) -> Maybe<&2, List<&2, U32>>:
160  match ok:
161    case True{}:
162      +d0 = CV.os2ip(sk)
163      sign_p(one, d0, m, aux, CV.to_affine(p(one), CV.pmul(p(one), d0, CV.g(one))))
164    case False{}: None{}

Uses (11)

Used by (5)