rodentrabies / bp

Bitcoin Protocol components in Common Lisp
MIT License
37 stars 8 forks source link

crypto: expose secp256k1 `combine-pubkeys` #12

Closed Titan-C closed 1 year ago

Titan-C commented 1 year ago

This will require some feedback rounds as I'm not to familiar with cffi.

I want to expose the combine function to add public keys. The function supports and array of public keys, yet I could only figure out how to do it pair-wise. The function I expose does support multiple keys, yet that happens over pairwise reduction at the lisp level.

I include a test, that compares the secret key multiplication to the repeated addition of the public key.

Titan-C commented 1 year ago

My apologies for the late reply. I addressed the comments.

rodentrabies commented 1 year ago

My apologies for the late reply. I addressed the comments.

No problem. Thanks a lot for your contribution! Merged.