From ffe1b60a11b9475634bab7f319d861c2a9dc755c Mon Sep 17 00:00:00 2001 From: Luke Parker Date: Thu, 28 Aug 2025 23:55:05 -0400 Subject: [PATCH] Move the contents of the `evrf/` folder to the `crypto/` folder It was justified when it had several libraries, which it no longer does thanks to the upstreaming with monero-oxide. --- Cargo.toml | 4 ++-- crypto/dkg/evrf/Cargo.toml | 6 +++--- crypto/{evrf => }/embedwards25519/Cargo.toml | 14 +++++++------- crypto/{evrf => }/embedwards25519/LICENSE | 0 crypto/{evrf => }/embedwards25519/README.md | 0 crypto/{evrf => }/embedwards25519/src/lib.rs | 0 crypto/{evrf => }/secq256k1/Cargo.toml | 12 ++++++------ crypto/{evrf => }/secq256k1/LICENSE | 0 crypto/{evrf => }/secq256k1/README.md | 0 crypto/{evrf => }/secq256k1/src/lib.rs | 0 orchestration/Cargo.toml | 4 ++-- substrate/node/Cargo.toml | 4 ++-- tests/coordinator/Cargo.toml | 4 ++-- tests/no-std/Cargo.toml | 4 ++-- 14 files changed, 26 insertions(+), 26 deletions(-) rename crypto/{evrf => }/embedwards25519/Cargo.toml (73%) rename crypto/{evrf => }/embedwards25519/LICENSE (100%) rename crypto/{evrf => }/embedwards25519/README.md (100%) rename crypto/{evrf => }/embedwards25519/src/lib.rs (100%) rename crypto/{evrf => }/secq256k1/Cargo.toml (75%) rename crypto/{evrf => }/secq256k1/LICENSE (100%) rename crypto/{evrf => }/secq256k1/README.md (100%) rename crypto/{evrf => }/secq256k1/src/lib.rs (100%) diff --git a/Cargo.toml b/Cargo.toml index 285c9b10..c90cd7b9 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -41,8 +41,8 @@ members = [ "crypto/prime-field", "crypto/short-weierstrass", - "crypto/evrf/secq256k1", - "crypto/evrf/embedwards25519", + "crypto/secq256k1", + "crypto/embedwards25519", "crypto/dkg", "crypto/dkg/recovery", diff --git a/crypto/dkg/evrf/Cargo.toml b/crypto/dkg/evrf/Cargo.toml index 4c69f349..1108261d 100644 --- a/crypto/dkg/evrf/Cargo.toml +++ b/crypto/dkg/evrf/Cargo.toml @@ -42,15 +42,15 @@ generalized-bulletproofs-ec-gadgets = { git = "https://github.com/monero-oxide/m dkg = { path = ".." } ciphersuite-kp256 = { path = "../../ciphersuite/kp256", default-features = false, optional = true } -secq256k1 = { path = "../../evrf/secq256k1", optional = true } +secq256k1 = { path = "../../secq256k1", optional = true } dalek-ff-group = { path = "../../dalek-ff-group", default-features = false, optional = true } -embedwards25519 = { path = "../../evrf/embedwards25519", default-features = false, features = ["alloc"], optional = true } +embedwards25519 = { path = "../../embedwards25519", default-features = false, features = ["alloc"], optional = true } [dev-dependencies] rand_core = { version = "0.6", default-features = false, features = ["getrandom"] } rand = { version = "0.8", default-features = false, features = ["std"] } ciphersuite = { path = "../../ciphersuite", default-features = false, features = ["std"] } -embedwards25519 = { path = "../../evrf/embedwards25519", default-features = false, features = ["std"] } +embedwards25519 = { path = "../../embedwards25519", default-features = false, features = ["std"] } dalek-ff-group = { path = "../../dalek-ff-group", default-features = false, features = ["std"] } generalized-bulletproofs = { git = "https://github.com/monero-oxide/monero-oxide", rev = "a6f8797007e768488568b821435cf5006517a962", features = ["tests"] } dkg-recovery = { path = "../recovery" } diff --git a/crypto/evrf/embedwards25519/Cargo.toml b/crypto/embedwards25519/Cargo.toml similarity index 73% rename from crypto/evrf/embedwards25519/Cargo.toml rename to crypto/embedwards25519/Cargo.toml index baac48af..2863b25a 100644 --- a/crypto/evrf/embedwards25519/Cargo.toml +++ b/crypto/embedwards25519/Cargo.toml @@ -3,7 +3,7 @@ name = "embedwards25519" version = "0.1.0" description = "A curve defined over the Ed25519 scalar field" license = "MIT" -repository = "https://github.com/serai-dex/serai/tree/develop/crypto/evrf/embedwards25519" +repository = "https://github.com/serai-dex/serai/tree/develop/crypto/embedwards25519" authors = ["Luke Parker "] keywords = ["curve25519", "ed25519", "ristretto255", "group"] edition = "2021" @@ -16,19 +16,19 @@ rustdoc-args = ["--cfg", "docsrs"] [dependencies] hex-literal = { version = "0.4", default-features = false } -std-shims = { version = "0.1", path = "../../../common/std-shims", default-features = false, optional = true } +std-shims = { version = "0.1", path = "../../common/std-shims", default-features = false, optional = true } zeroize = { version = "^1.5", default-features = false, features = ["zeroize_derive"] } generic-array = { version = "1", default-features = false } -prime-field = { path = "../../prime-field", default-features = false } -short-weierstrass = { path = "../../short-weierstrass", default-features = false } +prime-field = { path = "../prime-field", default-features = false } +short-weierstrass = { path = "../short-weierstrass", default-features = false } curve25519-dalek = { version = "4", default-features = false, features = ["legacy_compatibility"] } -dalek-ff-group = { path = "../../dalek-ff-group", version = "0.4", default-features = false } +dalek-ff-group = { path = "../dalek-ff-group", version = "0.4", default-features = false } blake2 = { version = "0.10", default-features = false } -ciphersuite = { path = "../../ciphersuite", version = "0.4", default-features = false } +ciphersuite = { path = "../ciphersuite", version = "0.4", default-features = false } generalized-bulletproofs-ec-gadgets = { git = "https://github.com/monero-oxide/monero-oxide", rev = "a6f8797007e768488568b821435cf5006517a962", default-features = false, optional = true } @@ -37,7 +37,7 @@ hex = "0.4" rand_core = { version = "0.6", features = ["std"] } -ff-group-tests = { path = "../../ff-group-tests" } +ff-group-tests = { path = "../ff-group-tests" } [features] alloc = ["std-shims", "zeroize/alloc", "prime-field/alloc", "short-weierstrass/alloc", "curve25519-dalek/alloc", "ciphersuite/alloc", "generalized-bulletproofs-ec-gadgets"] diff --git a/crypto/evrf/embedwards25519/LICENSE b/crypto/embedwards25519/LICENSE similarity index 100% rename from crypto/evrf/embedwards25519/LICENSE rename to crypto/embedwards25519/LICENSE diff --git a/crypto/evrf/embedwards25519/README.md b/crypto/embedwards25519/README.md similarity index 100% rename from crypto/evrf/embedwards25519/README.md rename to crypto/embedwards25519/README.md diff --git a/crypto/evrf/embedwards25519/src/lib.rs b/crypto/embedwards25519/src/lib.rs similarity index 100% rename from crypto/evrf/embedwards25519/src/lib.rs rename to crypto/embedwards25519/src/lib.rs diff --git a/crypto/evrf/secq256k1/Cargo.toml b/crypto/secq256k1/Cargo.toml similarity index 75% rename from crypto/evrf/secq256k1/Cargo.toml rename to crypto/secq256k1/Cargo.toml index 43ad777c..1c32cbbb 100644 --- a/crypto/evrf/secq256k1/Cargo.toml +++ b/crypto/secq256k1/Cargo.toml @@ -3,7 +3,7 @@ name = "secq256k1" version = "0.1.0" description = "An implementation of the curve secp256k1 cycles with" license = "MIT" -repository = "https://github.com/serai-dex/serai/tree/develop/crypto/evrf/secq256k1" +repository = "https://github.com/serai-dex/serai/tree/develop/crypto/secq256k1" authors = ["Luke Parker "] keywords = ["secp256k1", "secq256k1", "group"] edition = "2021" @@ -16,15 +16,15 @@ rustdoc-args = ["--cfg", "docsrs"] [dependencies] hex-literal = { version = "0.4", default-features = false } -std-shims = { version = "0.1", path = "../../../common/std-shims", default-features = false, optional = true } +std-shims = { version = "0.1", path = "../../common/std-shims", default-features = false, optional = true } generic-array = { version = "1", default-features = false } k256 = { version = "0.13", default-features = false, features = ["arithmetic"] } -prime-field = { path = "../../prime-field", default-features = false } -short-weierstrass = { path = "../../short-weierstrass", default-features = false } +prime-field = { path = "../prime-field", default-features = false } +short-weierstrass = { path = "../short-weierstrass", default-features = false } blake2 = { version = "0.10", default-features = false } -ciphersuite = { path = "../../ciphersuite", version = "0.4", default-features = false } +ciphersuite = { path = "../ciphersuite", version = "0.4", default-features = false } generalized-bulletproofs-ec-gadgets = { git = "https://github.com/monero-oxide/monero-oxide", rev = "a6f8797007e768488568b821435cf5006517a962", default-features = false, optional = true } [dev-dependencies] @@ -32,7 +32,7 @@ hex = "0.4" rand_core = { version = "0.6", features = ["std"] } -ff-group-tests = { path = "../../ff-group-tests" } +ff-group-tests = { path = "../ff-group-tests" } [features] alloc = ["std-shims", "generic-array/alloc", "k256/alloc", "prime-field/alloc", "short-weierstrass/alloc", "ciphersuite/alloc", "generalized-bulletproofs-ec-gadgets"] diff --git a/crypto/evrf/secq256k1/LICENSE b/crypto/secq256k1/LICENSE similarity index 100% rename from crypto/evrf/secq256k1/LICENSE rename to crypto/secq256k1/LICENSE diff --git a/crypto/evrf/secq256k1/README.md b/crypto/secq256k1/README.md similarity index 100% rename from crypto/evrf/secq256k1/README.md rename to crypto/secq256k1/README.md diff --git a/crypto/evrf/secq256k1/src/lib.rs b/crypto/secq256k1/src/lib.rs similarity index 100% rename from crypto/evrf/secq256k1/src/lib.rs rename to crypto/secq256k1/src/lib.rs diff --git a/orchestration/Cargo.toml b/orchestration/Cargo.toml index ad1fd4e8..252f25c3 100644 --- a/orchestration/Cargo.toml +++ b/orchestration/Cargo.toml @@ -25,8 +25,8 @@ rand_chacha = { version = "0.3", default-features = false, features = ["std"] } transcript = { package = "flexible-transcript", path = "../crypto/transcript", default-features = false, features = ["std", "recommended"] } ciphersuite = { path = "../crypto/ciphersuite", default-features = false, features = ["std"] } dalek-ff-group = { path = "../crypto/dalek-ff-group", default-features = false, features = ["std"] } -embedwards25519 = { path = "../crypto/evrf/embedwards25519" } -secq256k1 = { path = "../crypto/evrf/secq256k1" } +embedwards25519 = { path = "../crypto/embedwards25519" } +secq256k1 = { path = "../crypto/secq256k1" } zalloc = { path = "../common/zalloc" } diff --git a/substrate/node/Cargo.toml b/substrate/node/Cargo.toml index 7ddd2df2..59d6d14e 100644 --- a/substrate/node/Cargo.toml +++ b/substrate/node/Cargo.toml @@ -29,8 +29,8 @@ schnorrkel = "0.11" ciphersuite = { path = "../../crypto/ciphersuite" } ciphersuite-kp256 = { path = "../../crypto/ciphersuite/kp256" } dalek-ff-group = { path = "../../crypto/dalek-ff-group" } -embedwards25519 = { path = "../../crypto/evrf/embedwards25519" } -secq256k1 = { path = "../../crypto/evrf/secq256k1" } +embedwards25519 = { path = "../../crypto/embedwards25519" } +secq256k1 = { path = "../../crypto/secq256k1" } libp2p = "0.52" diff --git a/tests/coordinator/Cargo.toml b/tests/coordinator/Cargo.toml index cdd6d4f2..ac7a7b6f 100644 --- a/tests/coordinator/Cargo.toml +++ b/tests/coordinator/Cargo.toml @@ -27,8 +27,8 @@ blake2 = "0.10" ciphersuite = { path = "../../crypto/ciphersuite", default-features = false, features = ["std"] } ciphersuite-kp256 = { path = "../../crypto/ciphersuite/kp256", default-features = false, features = ["std"] } dalek-ff-group = { path = "../../crypto/dalek-ff-group", default-features = false, features = ["std"] } -embedwards25519 = { path = "../../crypto/evrf/embedwards25519" } -secq256k1 = { path = "../../crypto/evrf/secq256k1" } +embedwards25519 = { path = "../../crypto/embedwards25519" } +secq256k1 = { path = "../../crypto/secq256k1" } schnorrkel = "0.11" dkg = { path = "../../crypto/dkg", default-features = false, features = ["tests"] } diff --git a/tests/no-std/Cargo.toml b/tests/no-std/Cargo.toml index 03a51b90..00fe08d8 100644 --- a/tests/no-std/Cargo.toml +++ b/tests/no-std/Cargo.toml @@ -30,8 +30,8 @@ schnorr-signatures = { path = "../../crypto/schnorr", default-features = false } prime-field = { path = "../../crypto/prime-field", default-features = false, features = ["alloc"] } short-weierstrass = { path = "../../crypto/short-weierstrass", default-features = false, features = ["alloc"] } -secq256k1 = { path = "../../crypto/evrf/secq256k1", default-features = false } -embedwards25519 = { path = "../../crypto/evrf/embedwards25519", default-features = false } +secq256k1 = { path = "../../crypto/secq256k1", default-features = false } +embedwards25519 = { path = "../../crypto/embedwards25519", default-features = false } dkg = { path = "../../crypto/dkg", default-features = false } dkg-evrf = { path = "../../crypto/dkg/evrf", default-features = false }