Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use global context for secp256k1 #408

Merged
merged 3 commits into from
Jan 13, 2025
Merged

Conversation

ozankaymak
Copy link
Contributor

Description

This PR introduces the global context provided by secp256k1 crate to reduce unnecessary operations for curve operations.

Linked Issues

core/src/utils.rs Outdated Show resolved Hide resolved
@ceyhunsen ceyhunsen marked this pull request as ready for review January 12, 2025 20:32
@ozankaymak ozankaymak merged commit c3ed546 into dev Jan 13, 2025
9 checks passed
@ozankaymak ozankaymak deleted the ozan/use-global-context-secp branch January 13, 2025 12:15
@ekrembal ekrembal linked an issue Jan 13, 2025 that may be closed by this pull request
ceyhunsen pushed a commit that referenced this pull request Jan 16, 2025
* Use global context for secp256k1

* Lint

* Delete comment
ekrembal added a commit that referenced this pull request Jan 17, 2025
* cargo: Add secp256k1 patch for musig.

* cargo: Revert secp to 0.29 and apply chainway patch.

* cargo: Remove musig2.

* musig2: Update functions with new secp types.

* errors: Remove old musig errors and add new ones.

* secp_musig: Switch to the new types wherever possible.

* database: Add MusigPubNonceDB type.

* database: Add new wrapper for MusigAggNonceDB and fix rest.

* verifier-musig2: Fix copying error for nonces in deposit_sign.

Co-authored-by: Ekrem BAL <[email protected]>

* musig2: Fix compilation errors caused by the switch.

* database: Add Message wrapper.

* core: Fix rest of the compilation errors caused by the switch.

* tests-musig: Fix compilation errors.

* clippy: Apply suggestions.

* musig: Convert from_digest_slices to from_digest.

* secp: Convert secp types into bitcoin::secp.

* musig2: Convert secp types into bitcoin::secp types.

* musig2: Remove tweak_flag from from_musig2_pks.

* cargo: Delete config generator.

* Revert "musig2: Remove tweak_flag from from_musig2_pks."

This reverts commit d0ccc06.

* musig2: Add initial tweak support.

* musig: Add create_key_agg_cache and MusigTweak.

* musig: Fix wrong params for MusigTweak and add KeyAndScriptSpend.

* Add signature verification to aggregate_partial_signatures (#417)

* database: Fix wrong encoding for pub and agg nonces.

* musig: Remove none from Musig2Mode and make them optional.

* feat(musig2): add musig2 tweaking

* musig2: add musig2 tweaking test and update README

* errors: Add Secp256k1ScalarOutOfRange and return BridgeError in musog2.

* musig2: Fix merge conflicts for key_agg_cache_tweak_checks test.

* tests: Fix musig2 test by changing musig2 tweak modes.

* musig2: Remove xonly field from Musig2Mode.

* watchtower pk's for watchtower challenge page tx (#404)

* Add watchtower xonly_pk to get_params and save to db

* fix clippy error

* add db helper to get single xonly_pk, remove unwrap

* Adjust sighash.rs and transaction.rs to remove nofn sigs from challenge page tx

* Incorporate Ceyhun's feedback

* Ozan/change anchor (#407)

* Update risc0-to-bitvm2, change anchor output

* Renaming fix from circuits to header-chain

* Use global context for secp256k1 (#408)

* Use global context for secp256k1

* Lint

* Delete comment

* Implement kickoff timeout tx (#413)

* Implement kickoff_timeoout_tx

* Clippy

* Add kickoff_timeout_tx to sighash_stream

* Change num_required_sigs

* Remove time_tx from the inputs of operator_challenge_nack_tx (#414)

* merge: Fix compilation errors caused by the merge.

* database: Remove redundant borsch usage for MessageDB.

* musig2: Add comments for Musig2Mode and update key_agg_cache tests.

---------

Co-authored-by: Ekrem BAL <[email protected]>
Co-authored-by: Ozan Kaymak <[email protected]>
Co-authored-by: Mehmet Efe Akça <[email protected]>
Co-authored-by: atacann <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Use global SECP256K1 instead of lazy static
3 participants