Skip to content

Commit

Permalink
chore(crypto): CRP-2574 Use k256 instead of schnorr_fun (#2066)
Browse files Browse the repository at this point in the history
In a few areas of the code relating to BIP340 we were previously forced
to use the crate schnorr_fun instead of our usual k256, because k256
before 0.13.4 did not support BIP340 signatures over messages that were
not exactly 32 bytes.

Now that k256 0.13.4 is available we can use k256 universally and remove
schnorr_fun as a dependency within the monorepo.

---------

Co-authored-by: IDX GitHub Automation <[email protected]>
  • Loading branch information
randombit and IDX GitHub Automation authored Oct 16, 2024
1 parent db693c8 commit 38b6d6e
Show file tree
Hide file tree
Showing 17 changed files with 58 additions and 1,243 deletions.
466 changes: 1 addition & 465 deletions Cargo.Bazel.Fuzzing.json.lock

Large diffs are not rendered by default.

87 changes: 4 additions & 83 deletions Cargo.Bazel.Fuzzing.toml.lock
Original file line number Diff line number Diff line change
Expand Up @@ -1096,25 +1096,6 @@ dependencies = [
"serde",
]

[[package]]
name = "bincode"
version = "2.0.0-rc.3"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "f11ea1a0346b94ef188834a65c068a03aec181c94896d481d7a0a40d85b0ce95"
dependencies = [
"bincode_derive",
"serde",
]

[[package]]
name = "bincode_derive"
version = "2.0.0-rc.3"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "7e30759b3b99a1b802a7a3aa21c85c3ded5c28e1c83170d82d70f08bbf7f3e4c"
dependencies = [
"virtue",
]

[[package]]
name = "bindgen"
version = "0.65.1"
Expand Down Expand Up @@ -1540,7 +1521,7 @@ source = "git+https://github.com/dfinity-lab/build-info?rev=701a696844fba5c87df1
dependencies = [
"anyhow",
"base64 0.13.1",
"bincode 1.3.3",
"bincode",
"build-info-common",
"cargo_metadata",
"glob",
Expand Down Expand Up @@ -1568,7 +1549,7 @@ source = "git+https://github.com/dfinity-lab/build-info?rev=701a696844fba5c87df1
dependencies = [
"anyhow",
"base64 0.13.1",
"bincode 1.3.3",
"bincode",
"build-info-common",
"num-bigint 0.4.6",
"num-traits",
Expand Down Expand Up @@ -3060,7 +3041,7 @@ dependencies = [
"base32",
"base64 0.13.1",
"bech32 0.9.1",
"bincode 1.3.3",
"bincode",
"bindgen 0.65.1",
"bip32",
"bit-vec",
Expand Down Expand Up @@ -3282,7 +3263,6 @@ dependencies = [
"rustversion",
"rusty-fork",
"schemars",
"schnorr_fun",
"scoped_threadpool",
"scopeguard",
"scraper",
Expand Down Expand Up @@ -9748,15 +9728,6 @@ dependencies = [
"syn 1.0.109",
]

[[package]]
name = "schnorr_fun"
version = "0.10.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "56f8fbe78e3698a49208f5dd1a1d602908493ec800dd49147b1570b4eae84a1e"
dependencies = [
"secp256kfun",
]

[[package]]
name = "scoped-tls"
version = "1.0.1"
Expand Down Expand Up @@ -9845,15 +9816,6 @@ dependencies = [
"serde",
]

[[package]]
name = "secp256k1"
version = "0.28.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "d24b59d129cdadea20aea4fb2352fa053712e5d713eee47d700cd4b2bc002f10"
dependencies = [
"secp256k1-sys 0.9.2",
]

[[package]]
name = "secp256k1"
version = "0.29.0"
Expand Down Expand Up @@ -9882,15 +9844,6 @@ dependencies = [
"cc",
]

[[package]]
name = "secp256k1-sys"
version = "0.9.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "e5d1746aae42c19d583c3c1a8c646bfad910498e2051c551a7f2e3c0c9fbb7eb"
dependencies = [
"cc",
]

[[package]]
name = "secp256k1-sys"
version = "0.10.0"
Expand All @@ -9900,32 +9853,6 @@ dependencies = [
"cc",
]

[[package]]
name = "secp256kfun"
version = "0.10.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "9ecc2adce3ef929c5dc7dacdd612d65ab98002ee18119215ce25d8054ed53c1a"
dependencies = [
"bincode 2.0.0-rc.3",
"digest 0.10.7",
"rand_core 0.6.4",
"secp256k1 0.27.0",
"secp256k1 0.28.2",
"secp256kfun_arithmetic_macros",
"serde",
"subtle-ng",
]

[[package]]
name = "secp256kfun_arithmetic_macros"
version = "0.1.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "91b7c385a72530ebfe6010ff476ad9e235743fb33408a360052bb706f1481e1e"
dependencies = [
"proc-macro2",
"quote",
]

[[package]]
name = "secrecy"
version = "0.8.0"
Expand Down Expand Up @@ -11306,7 +11233,7 @@ version = "0.8.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "911a61637386b789af998ee23f50aa30d5fd7edcec8d6d3dedae5e5815205466"
dependencies = [
"bincode 1.3.3",
"bincode",
"bytes",
"educe",
"futures-core",
Expand Down Expand Up @@ -12046,12 +11973,6 @@ version = "0.9.4"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "49874b5167b65d7193b8aba1567f5c7d93d001cafc34600cee003eda787e483f"

[[package]]
name = "virtue"
version = "0.0.13"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "9dcc60c0624df774c82a0ef104151231d37da4962957d691c011c852b2473314"

[[package]]
name = "vsock"
version = "0.4.0"
Expand Down
Loading

0 comments on commit 38b6d6e

Please sign in to comment.