From 4dbb1a984043f1c9c99e8557b190299b32446ac4 Mon Sep 17 00:00:00 2001 From: jonesmarvin8 <83104039+jonesmarvin8@users.noreply.github.com> Date: Wed, 9 Jul 2025 19:49:09 -0400 Subject: [PATCH] precompiles precompiles for ped_curve25519 and secp256k1. --- risc0/ped_bls12_381_test/methods/guest/src/main.rs | 2 +- risc0/ped_curve25519_test/methods/guest/Cargo.toml | 3 ++- risc0/ped_secp256k1_test/methods/guest/Cargo.toml | 7 +++++-- 3 files changed, 8 insertions(+), 4 deletions(-) diff --git a/risc0/ped_bls12_381_test/methods/guest/src/main.rs b/risc0/ped_bls12_381_test/methods/guest/src/main.rs index 42fea58..5fdf768 100644 --- a/risc0/ped_bls12_381_test/methods/guest/src/main.rs +++ b/risc0/ped_bls12_381_test/methods/guest/src/main.rs @@ -8,7 +8,7 @@ fn main() { // TODO: do something with the input let g1 = bls12_381::G1Affine::generator(); - let g1_proj = bls12_381::G1Projective::from(g1); + let g1_proj = bls12_381::G1Projective::from(g1); let g2 = g1_proj + g1; let g3 = g1 + g2; let g4 = g1 + g3; diff --git a/risc0/ped_curve25519_test/methods/guest/Cargo.toml b/risc0/ped_curve25519_test/methods/guest/Cargo.toml index 05af76c..831fb17 100644 --- a/risc0/ped_curve25519_test/methods/guest/Cargo.toml +++ b/risc0/ped_curve25519_test/methods/guest/Cargo.toml @@ -7,4 +7,5 @@ edition = "2021" [dependencies] risc0-zkvm = { version = "^2.1.0", default-features = false, features = ['std'] } -curve25519-dalek = "4" +curve25519-dalek = "4.1.2" + diff --git a/risc0/ped_secp256k1_test/methods/guest/Cargo.toml b/risc0/ped_secp256k1_test/methods/guest/Cargo.toml index d066c3c..a1039c7 100644 --- a/risc0/ped_secp256k1_test/methods/guest/Cargo.toml +++ b/risc0/ped_secp256k1_test/methods/guest/Cargo.toml @@ -6,5 +6,8 @@ edition = "2021" [workspace] [dependencies] -risc0-zkvm = { version = "^2.1.0", default-features = false, features = ['std'] } -k256 = "0.13.4" +risc0-zkvm = { version = "^2.1.0", default-features = false, features = ['std', 'unstable'] } +k256 = "0.13.3" + +[patch.crates-io] +k256 = { git = "https://github.com/risc0/RustCrypto-elliptic-curves", tag = "k256/v0.13.3-risczero.1" }