From 62623aab31b26fde31471dc4eacccfc26535df0e Mon Sep 17 00:00:00 2001 From: Adam Tucker Date: Fri, 10 Apr 2026 11:33:42 -0600 Subject: [PATCH 1/4] chore: add crates.io metadata to imt-tree Add description, license (MIT OR Apache-2.0), and repository fields required for crates.io publication. --- imt-tree/Cargo.toml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/imt-tree/Cargo.toml b/imt-tree/Cargo.toml index 7b8d5e7..8a005e5 100644 --- a/imt-tree/Cargo.toml +++ b/imt-tree/Cargo.toml @@ -2,6 +2,9 @@ name = "imt-tree" version = "0.1.0" edition = "2021" +description = "Indexed Merkle Tree for nullifier non-membership proofs" +license = "MIT OR Apache-2.0" +repository = "https://github.com/valargroup/vote-nullifier-pir" [dependencies] anyhow = "1.0" From 2fe0623dc59a3707beb4707420d33fc1f8e55be0 Mon Sep 17 00:00:00 2001 From: Adam Tucker Date: Fri, 10 Apr 2026 11:53:20 -0600 Subject: [PATCH 2/4] fix: use package = "valar-ypir"/"valar-spiral-rs" for renamed fork deps The valargroup forks renamed their packages (ypir -> valar-ypir, spiral-rs -> valar-spiral-rs). Add `package` keys so cargo finds the renamed packages while code continues using the original import names. Keeps using the audited valargroup forks, not upstream. --- pir/client/Cargo.toml | 2 +- pir/server/Cargo.toml | 4 ++-- pir/test/Cargo.toml | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/pir/client/Cargo.toml b/pir/client/Cargo.toml index c6d860b..d6b534c 100644 --- a/pir/client/Cargo.toml +++ b/pir/client/Cargo.toml @@ -11,7 +11,7 @@ wiremock = "0.6" [dependencies] pir-types = { path = "../types", features = ["reader"] } imt-tree = { path = "../../imt-tree" } -ypir = { git = "https://github.com/valargroup/ypir.git", branch = "valar/artifact", default-features = false } +ypir = { git = "https://github.com/valargroup/ypir.git", branch = "valar/artifact", package = "valar-ypir", default-features = false } hex = "0.4" anyhow = "1.0" ff = "0.13" diff --git a/pir/server/Cargo.toml b/pir/server/Cargo.toml index 5ea7f05..bda9960 100644 --- a/pir/server/Cargo.toml +++ b/pir/server/Cargo.toml @@ -9,8 +9,8 @@ avx512 = ["ypir/explicit_avx512"] [dependencies] pir-types = { path = "../types" } -ypir = { git = "https://github.com/valargroup/ypir.git", branch = "valar/artifact", default-features = false, features = ["server"] } -spiral-rs = { git = "https://github.com/valargroup/spiral-rs.git", branch = "valar/avoid-avx512" } +ypir = { git = "https://github.com/valargroup/ypir.git", branch = "valar/artifact", package = "valar-ypir", default-features = false, features = ["server"] } +spiral-rs = { git = "https://github.com/valargroup/spiral-rs.git", branch = "valar/avoid-avx512", package = "valar-spiral-rs" } axum = "0.7" tokio = { version = "1", features = ["rt-multi-thread", "macros"] } anyhow = "1.0" diff --git a/pir/test/Cargo.toml b/pir/test/Cargo.toml index 25e40cb..3da79ca 100644 --- a/pir/test/Cargo.toml +++ b/pir/test/Cargo.toml @@ -9,7 +9,7 @@ pir-client = { path = "../client" } pir-server = { path = "../server" } pir-types = { path = "../types" } nf-ingest = { path = "../../nf-ingest" } -ypir = { git = "https://github.com/valargroup/ypir.git", branch = "valar/artifact", default-features = false, features = ["server"] } +ypir = { git = "https://github.com/valargroup/ypir.git", branch = "valar/artifact", package = "valar-ypir", default-features = false, features = ["server"] } anyhow = "1.0" clap = { version = "4", features = ["derive"] } ff = "0.13" From b06d0932066887f393b95ec39fc4464bb793dff9 Mon Sep 17 00:00:00 2001 From: Adam Tucker Date: Fri, 10 Apr 2026 13:30:04 -0600 Subject: [PATCH 3/4] chore: switch imt-tree deps to published crates.io version MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Now that imt-tree v0.1.0 is on crates.io, workspace members depend on the published version instead of path deps. A workspace-level [patch.crates-io] redirects to the local source for development. When downstream consumers (librustvoting) pull pir-client as a git dep, cargo sees `imt-tree = "0.1"` and resolves from crates.io — no more duplicate imt-tree from mismatched git vs crates.io sources. --- Cargo.toml | 3 +++ nf-ingest/Cargo.toml | 2 +- nf-server/Cargo.toml | 2 +- pir/client/Cargo.toml | 2 +- pir/export/Cargo.toml | 2 +- pir/types/Cargo.toml | 2 +- 6 files changed, 8 insertions(+), 5 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index 7cdc3cc..53709e7 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -11,6 +11,9 @@ members = [ "nf-ingest", ] +[patch.crates-io] +imt-tree = { path = "imt-tree" } + [profile.release] lto = "fat" codegen-units = 1 diff --git a/nf-ingest/Cargo.toml b/nf-ingest/Cargo.toml index 56098c9..d5c69d2 100644 --- a/nf-ingest/Cargo.toml +++ b/nf-ingest/Cargo.toml @@ -4,7 +4,7 @@ version = "0.1.0" edition = "2021" [dependencies] -imt-tree = { path = "../imt-tree" } +imt-tree = "0.1" anyhow = "1.0" hex = "0.4" ff = "0.13" diff --git a/nf-server/Cargo.toml b/nf-server/Cargo.toml index 3d4ae8f..fd1123d 100644 --- a/nf-server/Cargo.toml +++ b/nf-server/Cargo.toml @@ -20,7 +20,7 @@ reqwest = { version = "0.12", default-features = false, features = [" # Always needed pir-export = { path = "../pir/export" } nf-ingest = { path = "../nf-ingest" } -imt-tree = { path = "../imt-tree" } +imt-tree = "0.1" tokio = { version = "1", features = ["rt-multi-thread", "macros"] } clap = { version = "4", features = ["derive", "env"] } anyhow = "1.0" diff --git a/pir/client/Cargo.toml b/pir/client/Cargo.toml index d6b534c..ea58653 100644 --- a/pir/client/Cargo.toml +++ b/pir/client/Cargo.toml @@ -10,7 +10,7 @@ wiremock = "0.6" [dependencies] pir-types = { path = "../types", features = ["reader"] } -imt-tree = { path = "../../imt-tree" } +imt-tree = "0.1" ypir = { git = "https://github.com/valargroup/ypir.git", branch = "valar/artifact", package = "valar-ypir", default-features = false } hex = "0.4" anyhow = "1.0" diff --git a/pir/export/Cargo.toml b/pir/export/Cargo.toml index 9cf3791..1c03de1 100644 --- a/pir/export/Cargo.toml +++ b/pir/export/Cargo.toml @@ -12,7 +12,7 @@ cli = ["dep:nf-ingest"] [dependencies] pir-types = { path = "../types", features = ["reader"] } -imt-tree = { path = "../../imt-tree" } +imt-tree = "0.1" nf-ingest = { path = "../../nf-ingest", optional = true } anyhow = "1.0" hex = "0.4" diff --git a/pir/types/Cargo.toml b/pir/types/Cargo.toml index 7d08534..c8be1c3 100644 --- a/pir/types/Cargo.toml +++ b/pir/types/Cargo.toml @@ -12,4 +12,4 @@ serde = { version = "1", features = ["derive"] } pasta_curves = { version = "0.5", optional = true } ff = { version = "0.13", optional = true } anyhow = { version = "1.0", optional = true } -imt-tree = { path = "../../imt-tree", optional = true } +imt-tree = { version = "0.1", optional = true } From d976e13e5a69e5f03f0cede235af18c1257a6895 Mon Sep 17 00:00:00 2001 From: Adam Tucker Date: Fri, 10 Apr 2026 14:56:17 -0600 Subject: [PATCH 4/4] chore: regenerate Cargo.lock after imt-tree and ypir/spiral-rs changes Lockfile now reflects: - imt-tree resolved via [patch.crates-io] to local path - valar-ypir from valargroup/ypir (was ypir) - valar-spiral-rs from crates.io (was spiral-rs from git) --- Cargo.lock | 107 ++++++++++++++++++++++++++++++----------------------- 1 file changed, 61 insertions(+), 46 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index f5f450b..f0d8708 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -53,7 +53,7 @@ version = "1.1.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "40c48f72fd53cd289104fc64099abca73db4166ad86ea0b4341abe65af83dadc" dependencies = [ - "windows-sys 0.61.2", + "windows-sys 0.60.2", ] [[package]] @@ -64,7 +64,7 @@ checksum = "291e6a250ff86cd4a820112fb8898808a366d8f9f58ce16d1f538353ad55747d" dependencies = [ "anstyle", "once_cell_polyfill", - "windows-sys 0.61.2", + "windows-sys 0.60.2", ] [[package]] @@ -629,7 +629,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "39cab71617ae0d63f51a36d69f866391735b51691dbda63cf6f96d042b63efeb" dependencies = [ "libc", - "windows-sys 0.61.2", + "windows-sys 0.52.0", ] [[package]] @@ -1340,7 +1340,7 @@ checksum = "3640c1c38b8e4e43584d8df18be5fc6b0aa314ce6ebf51b53313d4306cca8e46" dependencies = [ "hermit-abi", "libc", - "windows-sys 0.61.2", + "windows-sys 0.52.0", ] [[package]] @@ -1563,7 +1563,7 @@ version = "0.50.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7957b9740744892f114936ab4a57b3f487491bbeafaf8083688b16841a4240e5" dependencies = [ - "windows-sys 0.61.2", + "windows-sys 0.60.2", ] [[package]] @@ -1723,8 +1723,8 @@ dependencies = [ "reqwest", "serde_json", "tokio", + "valar-ypir", "wiremock", - "ypir", ] [[package]] @@ -1756,11 +1756,11 @@ dependencies = [ "pir-types", "serde", "serde_json", - "spiral-rs", "tokio", "tracing", "tracing-subscriber", - "ypir", + "valar-spiral-rs 0.5.0 (git+https://github.com/valargroup/spiral-rs.git?branch=valar%2Favoid-avx512)", + "valar-ypir", ] [[package]] @@ -1779,7 +1779,7 @@ dependencies = [ "pir-types", "rand 0.8.5", "tokio", - "ypir", + "valar-ypir", ] [[package]] @@ -2181,7 +2181,7 @@ dependencies = [ "errno", "libc", "linux-raw-sys", - "windows-sys 0.61.2", + "windows-sys 0.52.0", ] [[package]] @@ -2477,7 +2477,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3a766e1110788c36f4fa1c2b71b387a7815aa65f88ce0229841826633d93723e" dependencies = [ "libc", - "windows-sys 0.61.2", + "windows-sys 0.60.2", ] [[package]] @@ -2492,20 +2492,6 @@ version = "0.9.8" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6980e8d7511241f8acf4aebddbb1ff938df5eebe98691418c4468d0b72a96a67" -[[package]] -name = "spiral-rs" -version = "0.4.0" -source = "git+https://github.com/valargroup/spiral-rs.git?branch=valar%2Favoid-avx512#e06c730f958ddd0717fda43ae43eb7c628290bd4" -dependencies = [ - "fastrand", - "getrandom 0.2.17", - "rand 0.8.5", - "rand_chacha 0.3.1", - "serde_json", - "sha2", - "subtle", -] - [[package]] name = "stable_deref_trait" version = "1.2.1" @@ -2615,7 +2601,7 @@ dependencies = [ "getrandom 0.4.2", "once_cell", "rustix", - "windows-sys 0.61.2", + "windows-sys 0.52.0", ] [[package]] @@ -3075,6 +3061,54 @@ version = "0.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "06abde3611657adf66d383f00b093d7faecc7fa57071cce2578660c9f1010821" +[[package]] +name = "valar-spiral-rs" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ce897de77f8b80c06e3457da2db3585333d2882f9e9f420ac8a79ab6e6a43f09" +dependencies = [ + "fastrand", + "getrandom 0.2.17", + "rand 0.8.5", + "rand_chacha 0.3.1", + "serde_json", + "sha2", + "subtle", +] + +[[package]] +name = "valar-spiral-rs" +version = "0.5.0" +source = "git+https://github.com/valargroup/spiral-rs.git?branch=valar%2Favoid-avx512#2a6386a6f2c194bb721d24e8bed0ef9adf6046a0" +dependencies = [ + "fastrand", + "getrandom 0.2.17", + "rand 0.8.5", + "rand_chacha 0.3.1", + "serde_json", + "sha2", + "subtle", +] + +[[package]] +name = "valar-ypir" +version = "0.1.0" +source = "git+https://github.com/valargroup/ypir.git?branch=valar%2Fartifact#970156c297df90bb1871b39e04f0d03b8036f4f9" +dependencies = [ + "cc", + "clap", + "env_logger", + "fastrand", + "log", + "rand 0.8.5", + "rand_chacha 0.3.1", + "serde", + "serde_json", + "sha1", + "test-log", + "valar-spiral-rs 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)", +] + [[package]] name = "valuable" version = "0.1.1" @@ -3286,7 +3320,7 @@ version = "0.1.11" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c2a7b1c03c876122aa43f3020e6c3c3ee5c05081c9a00739faf7503aeba10d22" dependencies = [ - "windows-sys 0.61.2", + "windows-sys 0.52.0", ] [[package]] @@ -3635,25 +3669,6 @@ dependencies = [ "synstructure", ] -[[package]] -name = "ypir" -version = "0.1.0" -source = "git+https://github.com/valargroup/ypir.git?branch=valar%2Fartifact#bb4d68bf0022b1b6cefc1fda8bf25ea8bce36fef" -dependencies = [ - "cc", - "clap", - "env_logger", - "fastrand", - "log", - "rand 0.8.5", - "rand_chacha 0.3.1", - "serde", - "serde_json", - "sha1", - "spiral-rs", - "test-log", -] - [[package]] name = "zerocopy" version = "0.8.48"