FrankC01 / pysui

SUI Python Client SDK
Apache License 2.0
138 stars 38 forks source link

[change] Signing with secp256k1 and secp256r1 #67

Closed FrankC01 closed 1 year ago

FrankC01 commented 1 year ago

As per https://github.com/MystenLabs/sui/pull/7423 Changes to secp256/k/r1 signing includes dropping the recovery byte v

FrankC01 commented 1 year ago

A regression in pysui with SUI 0.26.0. Using sui client new-address to generate an secp256r1 key works with all signing in pysui however; the pysui creation of same key type fails on signing.

FrankC01 commented 1 year ago

secp256r1 still failing intermittently on signing complaining that the s value must be small.

pysui is using a crypto library (ecdsa) that is conformant, however in debugging I see the s value is sometimes much larger than the acceptable range defined by MystenLabs.

Having conversations with MystenLabs on this issue.

FrankC01 commented 1 year ago

Finally have this fixed in the next release of pysui (0.15.0) which will be posted along with sui 0.28.1 release... soon!