penumbra-zone / decaf377

decaf377 is a prime-order group designed for use in SNARKs over BLS12-377
https://protocol.penumbra.zone/main/crypto/decaf377.html
12 stars 12 forks source link

Implement FromStr for all the fields #79

Closed cronokirby closed 5 months ago

cronokirby commented 5 months ago

This is needed upstream as well, and having an unimplemented macro is a bit of a footgun.

I chose not to implement a more efficient method using u64 because after spending a bit of time on it it didn't pass the test I wrote—for some reason—and I was too lazy to tinker with it more; the efficiency of this method doesn't really matter anyways.