mimblewimble / secp256k1-zkp

Fork of secp256k1-zkp for the Grin/MimbleWimble project
MIT License
32 stars 42 forks source link

Functions to inverse and negate private key, commit with 2 blinding factors #39

Closed jaspervdm closed 5 years ago

jaspervdm commented 5 years ago

This PR adds 3 new convenience functions (and corresponding tests):

garyyu commented 5 years ago

And you also add secp256k1_pedersen_blind_commit function in this PR. What's it for?

jaspervdm commented 5 years ago

Yeah haven't updated the PR description yet, will do soon. It is to calculate commitment x*G + v*H where v is a secret key instead of a 64 bit integer

jaspervdm commented 5 years ago

I added some tests for the secp256k1_pedersen_blind_commit function, the PR is ready for final review!

ignopeverell commented 5 years ago

Could you provide some general direction as to what those could be used for?

antiochp commented 5 years ago

@jaspervdm doing some secret dev work by the looks of it.

jaspervdm commented 5 years ago

These 3 methods are useful in a secret sharing scheme. In particular, the inverse and negate functions are used in calculations for Lagrange basis polynomials.