Skip to content
This repository has been archived by the owner on Jun 21, 2020. It is now read-only.

Replacing the secp256k1 library #167

Draft
wants to merge 1 commit into
base: develop
Choose a base branch
from
Draft

Replacing the secp256k1 library #167

wants to merge 1 commit into from

Conversation

elichai
Copy link
Contributor

@elichai elichai commented May 28, 2019

This is more of a PoC for @AvishaiW or @moriaab to do in the future.
this should wait till after rust-bitcoin/rust-secp256k1#115

https://enigmaco.atlassian.net/browse/EP-612

Replacing libsecp256k1 with rust-secp256k1 makes it not compile to WASM.
we should either investigate it further, Or feature gate between them
(another possibility is to outright not use it in wasm and maybe provide other crypto in a wasm specific program or provide these as external in the runtime)

@elichai elichai requested review from AvishaiW and moriaab May 28, 2019 14:40
@elichai
Copy link
Contributor Author

elichai commented Jul 16, 2019

FYI https://github.com/rust-bitcoin/rust-secp256k1/blob/master/CHANGELOG.md#0140---2019-07-08
@AvishaiW @moriaab

P.S. maybe moving the Context to a global lazy_static! would be better. because the context is a one time slow creation that then makes everything really fast, and it's thread safe, so no need even for a Mutex.
(so either lazy_static, or something like: https://github.com/elichai/ecc-secp256k1/blob/master/src/secp256k1.rs#L480)

@moriaab
Copy link
Contributor

moriaab commented Jul 17, 2019

Thank you so much @elichai

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants