From e8680e13825dc1281e8fd73f12d644b2b4a39162 Mon Sep 17 00:00:00 2001 From: Ratan Kaliani Date: Fri, 20 Dec 2024 16:23:25 -0800 Subject: [PATCH] feat: v4 --- Cargo.lock | 619 +++++++------------- Cargo.toml | 12 +- proposer/succinct/bin/server.rs | 117 +--- scripts/prove/Cargo.toml | 1 + scripts/prove/bin/agg.rs | 11 +- scripts/prove/bin/multi.rs | 54 +- scripts/prove/src/lib.rs | 4 +- scripts/prove/tests/multi.rs | 13 +- scripts/utils/bin/cost_estimator.rs | 8 +- scripts/utils/bin/fetch_and_save_proof.rs | 26 +- scripts/utils/bin/fetch_rollup_config.rs | 2 +- scripts/utils/bin/gen_sp1_test_artifacts.rs | 8 +- scripts/utils/bin/vkey.rs | 2 +- scripts/utils/src/lib.rs | 3 + 14 files changed, 305 insertions(+), 575 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index c00638e4..73523674 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -39,7 +39,7 @@ dependencies = [ "op-succinct-client-utils", "serde_cbor", "sha2", - "sp1-lib", + "sp1-lib 3.4.0 (git+https://github.com/succinctlabs/sp1.git?branch=dev)", "sp1-zkvm", ] @@ -465,7 +465,7 @@ dependencies = [ "lru", "parking_lot", "pin-project", - "reqwest 0.12.9", + "reqwest", "schnellru", "serde", "serde_json", @@ -532,7 +532,7 @@ dependencies = [ "alloy-transport-ws", "futures", "pin-project", - "reqwest 0.12.9", + "reqwest", "serde", "serde_json", "tokio", @@ -786,7 +786,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f99acddb34000d104961897dbb0240298e8b775a7efffb9fda2a1a3efedd65b3" dependencies = [ "alloy-json-rpc 0.6.4", - "base64 0.22.1", + "base64", "futures-util", "futures-utils-wasm", "serde", @@ -807,7 +807,7 @@ checksum = "5dc013132e34eeadaa0add7e74164c1503988bfba8bae885b32e0918ba85a8a6" dependencies = [ "alloy-json-rpc 0.6.4", "alloy-transport", - "reqwest 0.12.9", + "reqwest", "serde_json", "tower 0.5.2", "tracing", @@ -842,7 +842,7 @@ dependencies = [ "alloy-pubsub", "alloy-transport", "futures", - "http 1.2.0", + "http", "rustls", "serde_json", "tokio", @@ -1172,10 +1172,10 @@ dependencies = [ "axum-core", "bytes", "futures-util", - "http 1.2.0", - "http-body 1.0.1", + "http", + "http-body", "http-body-util", - "hyper 1.5.2", + "hyper", "hyper-util", "itoa", "matchit", @@ -1188,7 +1188,7 @@ dependencies = [ "serde_json", "serde_path_to_error", "serde_urlencoded", - "sync_wrapper 1.0.2", + "sync_wrapper", "tokio", "tower 0.5.2", "tower-layer", @@ -1205,13 +1205,13 @@ dependencies = [ "async-trait", "bytes", "futures-util", - "http 1.2.0", - "http-body 1.0.1", + "http", + "http-body", "http-body-util", "mime", "pin-project-lite", "rustversion", - "sync_wrapper 1.0.2", + "sync_wrapper", "tower-layer", "tower-service", "tracing", @@ -1253,12 +1253,6 @@ version = "0.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4c7f02d4ea65f2c1853089ffd8d2787bdbc63de2f0d29dedbcf8ccdfa0ccd4cf" -[[package]] -name = "base64" -version = "0.21.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9d297deb1925b89f2ccc13d7635fa0714f12c87adce1c75356b39ca9b7178567" - [[package]] name = "base64" version = "0.22.1" @@ -1292,7 +1286,7 @@ version = "0.69.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "271383c67ccabffb7381723dea0672a673f292304fcb45c01cc648c7a8d58088" dependencies = [ - "bitflags 2.6.0", + "bitflags", "cexpr", "clang-sys", "itertools 0.12.1", @@ -1312,7 +1306,7 @@ version = "0.70.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f49d8fed880d473ea71efb9bf597651e77201bdd4893efe54c9e5d65ae04ce6f" dependencies = [ - "bitflags 2.6.0", + "bitflags", "cexpr", "clang-sys", "itertools 0.13.0", @@ -1341,12 +1335,6 @@ version = "0.6.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "349f9b6a179ed607305526ca489b34ad0a41aed5f7980fa90eb03160b69598fb" -[[package]] -name = "bitflags" -version = "1.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" - [[package]] name = "bitflags" version = "2.6.0" @@ -1385,19 +1373,6 @@ dependencies = [ "constant_time_eq", ] -[[package]] -name = "blake3" -version = "1.5.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b8ee0c1824c4dea5b5f81736aff91bae041d2c07ee1192bec91054e10e3e601e" -dependencies = [ - "arrayref", - "arrayvec", - "cc", - "cfg-if", - "constant_time_eq", -] - [[package]] name = "block-buffer" version = "0.10.4" @@ -1713,7 +1688,7 @@ version = "0.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7bb11bd1378bf3731b182997b40cefe00aba6a6cc74042c8318c1b271d3badf7" dependencies = [ - "nix", + "nix 0.27.1", "thiserror 1.0.69", "tokio", ] @@ -1791,6 +1766,15 @@ dependencies = [ "libc", ] +[[package]] +name = "crossbeam-channel" +version = "0.5.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "06ba6d68e24814cb8de6bb986db8222d3a027d15872cabc0d18817bc3c0e4471" +dependencies = [ + "crossbeam-utils", +] + [[package]] name = "crossbeam-deque" version = "0.8.6" @@ -1865,6 +1849,16 @@ dependencies = [ "memchr", ] +[[package]] +name = "ctrlc" +version = "3.4.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "90eeab0aa92f3f9b4e87f258c72b139c207d251f9cbc1080a0086b86a8870dd3" +dependencies = [ + "nix 0.29.0", + "windows-sys 0.59.0", +] + [[package]] name = "darling" version = "0.20.10" @@ -2006,6 +2000,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f55bf8e7b65898637379c1b74eb1551107c8294ed26d855ceb9fd1a09cfc9bc0" dependencies = [ "const-oid", + "pem-rfc7468", "zeroize", ] @@ -2147,7 +2142,7 @@ dependencies = [ "hex-literal", "rfc6979", "signature", - "sp1-lib", + "sp1-lib 3.4.0 (registry+https://github.com/rust-lang/crates.io-index)", "spki", ] @@ -2175,6 +2170,7 @@ dependencies = [ "ff 0.13.0", "generic-array 0.14.7", "group 0.13.0", + "pem-rfc7468", "pkcs8", "rand_core", "sec1", @@ -2524,7 +2520,7 @@ version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b903b73e45dc0c6c596f2d37eccece7c1c8bb6e4407b001096387c63d0d93724" dependencies = [ - "bitflags 2.6.0", + "bitflags", "libc", "libgit2-sys", "log", @@ -2560,25 +2556,6 @@ dependencies = [ "subtle", ] -[[package]] -name = "h2" -version = "0.3.26" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "81fe527a889e1532da5c525686d96d4c2e74cdd345badf8dfef9f6b39dd5f5e8" -dependencies = [ - "bytes", - "fnv", - "futures-core", - "futures-sink", - "futures-util", - "http 0.2.12", - "indexmap 2.7.0", - "slab", - "tokio", - "tokio-util", - "tracing", -] - [[package]] name = "h2" version = "0.4.7" @@ -2590,7 +2567,7 @@ dependencies = [ "fnv", "futures-core", "futures-sink", - "http 1.2.0", + "http", "indexmap 2.7.0", "slab", "tokio", @@ -2701,17 +2678,6 @@ dependencies = [ "digest 0.10.7", ] -[[package]] -name = "http" -version = "0.2.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "601cbb57e577e2f5ef5be8e7b83f0f63994f25aa94d673e54a92d5c516d101f1" -dependencies = [ - "bytes", - "fnv", - "itoa", -] - [[package]] name = "http" version = "1.2.0" @@ -2723,17 +2689,6 @@ dependencies = [ "itoa", ] -[[package]] -name = "http-body" -version = "0.4.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7ceab25649e9960c0311ea418d17bee82c0dcec1bd053b5f9a66e265a693bed2" -dependencies = [ - "bytes", - "http 0.2.12", - "pin-project-lite", -] - [[package]] name = "http-body" version = "1.0.1" @@ -2741,7 +2696,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1efedce1fb8e6913f23e0c92de8e62cd5b772a67e7b3946df930a62566c93184" dependencies = [ "bytes", - "http 1.2.0", + "http", ] [[package]] @@ -2752,8 +2707,8 @@ checksum = "793429d76616a256bcb62c2a2ec2bed781c8307e797e2598c50010f2bee2544f" dependencies = [ "bytes", "futures-util", - "http 1.2.0", - "http-body 1.0.1", + "http", + "http-body", "pin-project-lite", ] @@ -2769,30 +2724,6 @@ version = "1.0.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "df3b46402a9d5adb4c86a0cf463f42e19994e3ee891101b1841f30a545cb49a9" -[[package]] -name = "hyper" -version = "0.14.32" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "41dfc780fdec9373c01bae43289ea34c972e40ee3c9f6b3c8801a35f35586ce7" -dependencies = [ - "bytes", - "futures-channel", - "futures-core", - "futures-util", - "h2 0.3.26", - "http 0.2.12", - "http-body 0.4.6", - "httparse", - "httpdate", - "itoa", - "pin-project-lite", - "socket2", - "tokio", - "tower-service", - "tracing", - "want", -] - [[package]] name = "hyper" version = "1.5.2" @@ -2802,9 +2733,9 @@ dependencies = [ "bytes", "futures-channel", "futures-util", - "h2 0.4.7", - "http 1.2.0", - "http-body 1.0.1", + "h2", + "http", + "http-body", "httparse", "httpdate", "itoa", @@ -2821,8 +2752,8 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "08afdbb5c31130e3034af566421053ab03787c640246a446327f550d11bcb333" dependencies = [ "futures-util", - "http 1.2.0", - "hyper 1.5.2", + "http", + "hyper", "hyper-util", "rustls", "rustls-pki-types", @@ -2838,26 +2769,13 @@ version = "0.5.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "2b90d566bffbce6a75bd8b09a05aa8c2cb1fabb6cb348f8840c9e4c90a0d83b0" dependencies = [ - "hyper 1.5.2", + "hyper", "hyper-util", "pin-project-lite", "tokio", "tower-service", ] -[[package]] -name = "hyper-tls" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d6183ddfa99b85da61a140bea0efc93fdf56ceaa041b37d553518030827f9905" -dependencies = [ - "bytes", - "hyper 0.14.32", - "native-tls", - "tokio", - "tokio-native-tls", -] - [[package]] name = "hyper-tls" version = "0.6.0" @@ -2866,7 +2784,7 @@ checksum = "70206fc6890eaca9fde8a0bf71caa2ddfc9fe045ac9e5c70df101a7dbde866e0" dependencies = [ "bytes", "http-body-util", - "hyper 1.5.2", + "hyper", "hyper-util", "native-tls", "tokio", @@ -2883,9 +2801,9 @@ dependencies = [ "bytes", "futures-channel", "futures-util", - "http 1.2.0", - "http-body 1.0.1", - "hyper 1.5.2", + "http", + "http-body", + "hyper", "pin-project-lite", "socket2", "tokio", @@ -3397,7 +3315,7 @@ dependencies = [ "op-alloy-genesis", "op-alloy-protocol", "os_pipe", - "reqwest 0.12.9", + "reqwest", "revm", "rocksdb", "serde", @@ -3527,7 +3445,7 @@ version = "0.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c0ff37bd590ca25063e35af745c343cb7a0271906fb7b37e4813e8f79f00268d" dependencies = [ - "bitflags 2.6.0", + "bitflags", "libc", ] @@ -3705,11 +3623,23 @@ version = "0.27.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "2eb04e9c688eff1c89d72b407f168cf79bb9e867a9d3323ed6c01519eb9cc053" dependencies = [ - "bitflags 2.6.0", + "bitflags", "cfg-if", "libc", ] +[[package]] +name = "nix" +version = "0.29.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "71e2746dc3a24dd78b3cfcb7be93368c6de9963d30f43a6a73998a9cf4b17b46" +dependencies = [ + "bitflags", + "cfg-if", + "cfg_aliases", + "libc", +] + [[package]] name = "nohash-hasher" version = "0.2.0" @@ -4074,7 +4004,7 @@ version = "0.1.0" dependencies = [ "cargo_metadata", "chrono", - "sp1-build 3.4.0 (registry+https://github.com/rust-lang/crates.io-index)", + "sp1-build", ] [[package]] @@ -4148,7 +4078,7 @@ dependencies = [ "op-alloy-protocol", "op-alloy-rpc-types", "op-succinct-client-utils", - "reqwest 0.12.9", + "reqwest", "rkyv 0.7.45", "serde", "serde_cbor", @@ -4166,7 +4096,7 @@ dependencies = [ "alloy-primitives", "anyhow", "axum", - "base64 0.22.1", + "base64", "bincode", "dotenv", "log", @@ -4198,7 +4128,8 @@ dependencies = [ "op-succinct-build-utils", "op-succinct-client-utils", "op-succinct-host-utils", - "reqwest 0.12.9", + "op-succinct-scripts", + "reqwest", "serde_json", "sp1-sdk", "tokio", @@ -4227,7 +4158,7 @@ dependencies = [ "op-succinct-client-utils", "op-succinct-host-utils", "rayon", - "reqwest 0.12.9", + "reqwest", "serde", "serde_json", "sp1-sdk", @@ -4250,7 +4181,7 @@ version = "0.10.68" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6174bc48f102d208783c2c84bf931bb75927a617866870de8a4ea85597f871f5" dependencies = [ - "bitflags 2.6.0", + "bitflags", "cfg-if", "foreign-types", "libc", @@ -4324,9 +4255,8 @@ dependencies = [ [[package]] name = "p3-air" -version = "0.1.4-succinct" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "066f571b2e645505ed5972dd0e1e252ba03352150830c9566769ca711c0f1e9b" +version = "0.1.0" +source = "git+https://github.com/Plonky3/Plonky3?branch=sp1-v4#bba88386261c3eaceb7f922b99bea56c1d6c6c58" dependencies = [ "p3-field", "p3-matrix", @@ -4334,9 +4264,8 @@ dependencies = [ [[package]] name = "p3-baby-bear" -version = "0.1.4-succinct" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ff00f571044d299310d9659c6e51c98422de3bf94b8577f7f30cf59cf2043e40" +version = "0.1.0" +source = "git+https://github.com/Plonky3/Plonky3?branch=sp1-v4#bba88386261c3eaceb7f922b99bea56c1d6c6c58" dependencies = [ "num-bigint 0.4.6", "p3-field", @@ -4347,21 +4276,10 @@ dependencies = [ "serde", ] -[[package]] -name = "p3-blake3" -version = "0.1.4-succinct" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cc4cb69ae54a279bbbd477566d1bdb71aa879b528fd658d0fcfc36f54b00217c" -dependencies = [ - "blake3", - "p3-symmetric", -] - [[package]] name = "p3-bn254-fr" -version = "0.1.4-succinct" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bf19917f986d45e9abb6d177e875824ced6eed096480d574fce16f2c45c721ea" +version = "0.1.0" +source = "git+https://github.com/Plonky3/Plonky3?branch=sp1-v4#bba88386261c3eaceb7f922b99bea56c1d6c6c58" dependencies = [ "ff 0.13.0", "num-bigint 0.4.6", @@ -4374,9 +4292,8 @@ dependencies = [ [[package]] name = "p3-challenger" -version = "0.1.4-succinct" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3be7e4fbce4566a93091107eadfafa0b5374bd1ffd3e0f6b850da3ff72eb183f" +version = "0.1.0" +source = "git+https://github.com/Plonky3/Plonky3?branch=sp1-v4#bba88386261c3eaceb7f922b99bea56c1d6c6c58" dependencies = [ "p3-field", "p3-maybe-rayon", @@ -4388,13 +4305,11 @@ dependencies = [ [[package]] name = "p3-commit" -version = "0.1.4-succinct" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a03eb0f99d68a712c41e658e9a7782a0705d4ffcfb6232a43bd3f1ef9591002" +version = "0.1.0" +source = "git+https://github.com/Plonky3/Plonky3?branch=sp1-v4#bba88386261c3eaceb7f922b99bea56c1d6c6c58" dependencies = [ "itertools 0.12.1", "p3-challenger", - "p3-dft", "p3-field", "p3-matrix", "p3-util", @@ -4403,9 +4318,8 @@ dependencies = [ [[package]] name = "p3-dft" -version = "0.1.4-succinct" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1556de968523fbe5d804ab50600ea306fcceea3500cfd7601e40882480524664" +version = "0.1.0" +source = "git+https://github.com/Plonky3/Plonky3?branch=sp1-v4#bba88386261c3eaceb7f922b99bea56c1d6c6c58" dependencies = [ "p3-field", "p3-matrix", @@ -4416,9 +4330,8 @@ dependencies = [ [[package]] name = "p3-field" -version = "0.1.4-succinct" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cec2af6e1ac47a2035af5165e668d64612c4b9ccabd06df37fc1fd381fdf8a71" +version = "0.1.0" +source = "git+https://github.com/Plonky3/Plonky3?branch=sp1-v4#bba88386261c3eaceb7f922b99bea56c1d6c6c58" dependencies = [ "itertools 0.12.1", "num-bigint 0.4.6", @@ -4430,9 +4343,8 @@ dependencies = [ [[package]] name = "p3-fri" -version = "0.1.4-succinct" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f351ee9f9d4256455164565cd91e3e6d2487cc2a5355515fa2b6d479269188dd" +version = "0.1.0" +source = "git+https://github.com/Plonky3/Plonky3?branch=sp1-v4#bba88386261c3eaceb7f922b99bea56c1d6c6c58" dependencies = [ "itertools 0.12.1", "p3-challenger", @@ -4449,9 +4361,8 @@ dependencies = [ [[package]] name = "p3-interpolation" -version = "0.1.4-succinct" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d24d0f2907a374ebe4545fcff3120d6376d9630cf0bef30feedcfc5908ea2c37" +version = "0.1.0" +source = "git+https://github.com/Plonky3/Plonky3?branch=sp1-v4#bba88386261c3eaceb7f922b99bea56c1d6c6c58" dependencies = [ "p3-field", "p3-matrix", @@ -4460,9 +4371,8 @@ dependencies = [ [[package]] name = "p3-keccak-air" -version = "0.1.4-succinct" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e66badd47cedf6570e91a0cabc389b80dfd53ba1a6e9a45a3923fd54b86122ff" +version = "0.1.0" +source = "git+https://github.com/Plonky3/Plonky3?branch=sp1-v4#bba88386261c3eaceb7f922b99bea56c1d6c6c58" dependencies = [ "p3-air", "p3-field", @@ -4474,9 +4384,8 @@ dependencies = [ [[package]] name = "p3-matrix" -version = "0.1.4-succinct" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fa272f3ae77ed8d73478aa7c89e712efb15bda3ff4aff10fadfe11a012cd5389" +version = "0.1.0" +source = "git+https://github.com/Plonky3/Plonky3?branch=sp1-v4#bba88386261c3eaceb7f922b99bea56c1d6c6c58" dependencies = [ "itertools 0.12.1", "p3-field", @@ -4489,18 +4398,16 @@ dependencies = [ [[package]] name = "p3-maybe-rayon" -version = "0.1.4-succinct" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3eecad6292021858f282d643d9d1284ab112a200494d589863a9c4080e578ef0" +version = "0.1.0" +source = "git+https://github.com/Plonky3/Plonky3?branch=sp1-v4#bba88386261c3eaceb7f922b99bea56c1d6c6c58" dependencies = [ "rayon", ] [[package]] name = "p3-mds" -version = "0.1.4-succinct" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "716c4dbe68a02f1541eb09149d07b8663a3a5951b1864a31cd67ff3bb0826e57" +version = "0.1.0" +source = "git+https://github.com/Plonky3/Plonky3?branch=sp1-v4#bba88386261c3eaceb7f922b99bea56c1d6c6c58" dependencies = [ "itertools 0.12.1", "p3-dft", @@ -4513,9 +4420,8 @@ dependencies = [ [[package]] name = "p3-merkle-tree" -version = "0.1.4-succinct" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ad7ebab52a03c26025988663a135aed62f5084a2e2ea262176dc8748efb593e5" +version = "0.1.0" +source = "git+https://github.com/Plonky3/Plonky3?branch=sp1-v4#bba88386261c3eaceb7f922b99bea56c1d6c6c58" dependencies = [ "itertools 0.12.1", "p3-commit", @@ -4530,9 +4436,8 @@ dependencies = [ [[package]] name = "p3-poseidon2" -version = "0.1.4-succinct" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39c042efa15beab7a8c4d0ca9b9e4cbda7582be0c08e121e830fec45f082935b" +version = "0.1.0" +source = "git+https://github.com/Plonky3/Plonky3?branch=sp1-v4#bba88386261c3eaceb7f922b99bea56c1d6c6c58" dependencies = [ "gcd", "p3-field", @@ -4544,9 +4449,8 @@ dependencies = [ [[package]] name = "p3-symmetric" -version = "0.1.4-succinct" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b9896a831f5b688adc13f6fbe1dcf66ecfaa4622a500f81aa745610e777acb72" +version = "0.1.0" +source = "git+https://github.com/Plonky3/Plonky3?branch=sp1-v4#bba88386261c3eaceb7f922b99bea56c1d6c6c58" dependencies = [ "itertools 0.12.1", "p3-field", @@ -4555,9 +4459,8 @@ dependencies = [ [[package]] name = "p3-uni-stark" -version = "0.1.4-succinct" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8437ebcd060c8a5479898030b114a93da8a86eb4c2e5f313d9eeaaf40c6e6f61" +version = "0.1.0" +source = "git+https://github.com/Plonky3/Plonky3?branch=sp1-v4#bba88386261c3eaceb7f922b99bea56c1d6c6c58" dependencies = [ "itertools 0.12.1", "p3-air", @@ -4574,9 +4477,8 @@ dependencies = [ [[package]] name = "p3-util" -version = "0.1.4-succinct" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dedb9d27ba47ac314c6fac4ca54e55c3e486c864d51ec5ba55dbe47b75121157" +version = "0.1.0" +source = "git+https://github.com/Plonky3/Plonky3?branch=sp1-v4#bba88386261c3eaceb7f922b99bea56c1d6c6c58" dependencies = [ "serde", ] @@ -4684,6 +4586,15 @@ version = "1.0.15" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "57c0d7b74b563b49d38dae00a0c37d4d6de9b432382b2892f0574ddcae73fd0a" +[[package]] +name = "pem-rfc7468" +version = "0.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "88b39c9bfcfc231068454382784bb460aae594343fb030d46e9f50a645418412" +dependencies = [ + "base64ct", +] + [[package]] name = "percent-encoding" version = "2.3.1" @@ -4868,7 +4779,7 @@ checksum = "b4c2511913b88df1637da85cc8d96ec8e43a3f8bb8ccb71ee1ac240d6f3df58d" dependencies = [ "bit-set", "bit-vec", - "bitflags 2.6.0", + "bitflags", "lazy_static", "num-traits", "rand", @@ -5133,7 +5044,7 @@ version = "0.5.8" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "03a862b389f93e68874fbf580b9de08dd02facb9a788ebadaf4a3fd33cf58834" dependencies = [ - "bitflags 2.6.0", + "bitflags", ] [[package]] @@ -5209,64 +5120,24 @@ dependencies = [ "bytecheck 0.8.0", ] -[[package]] -name = "reqwest" -version = "0.11.27" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dd67538700a17451e7cba03ac727fb961abb7607553461627b97de0b89cf4a62" -dependencies = [ - "base64 0.21.7", - "bytes", - "encoding_rs", - "futures-core", - "futures-util", - "h2 0.3.26", - "http 0.2.12", - "http-body 0.4.6", - "hyper 0.14.32", - "hyper-tls 0.5.0", - "ipnet", - "js-sys", - "log", - "mime", - "native-tls", - "once_cell", - "percent-encoding", - "pin-project-lite", - "rustls-pemfile 1.0.4", - "serde", - "serde_json", - "serde_urlencoded", - "sync_wrapper 0.1.2", - "system-configuration 0.5.1", - "tokio", - "tokio-native-tls", - "tower-service", - "url", - "wasm-bindgen", - "wasm-bindgen-futures", - "web-sys", - "winreg", -] - [[package]] name = "reqwest" version = "0.12.9" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a77c62af46e79de0a562e1a9849205ffcb7fc1238876e9bd743357570e04046f" dependencies = [ - "base64 0.22.1", + "base64", "bytes", "encoding_rs", "futures-core", "futures-util", - "h2 0.4.7", - "http 1.2.0", - "http-body 1.0.1", + "h2", + "http", + "http-body", "http-body-util", - "hyper 1.5.2", + "hyper", "hyper-rustls", - "hyper-tls 0.6.0", + "hyper-tls", "hyper-util", "ipnet", "js-sys", @@ -5278,13 +5149,13 @@ dependencies = [ "pin-project-lite", "quinn", "rustls", - "rustls-pemfile 2.2.0", + "rustls-pemfile", "rustls-pki-types", "serde", "serde_json", "serde_urlencoded", - "sync_wrapper 1.0.2", - "system-configuration 0.6.1", + "sync_wrapper", + "system-configuration", "tokio", "tokio-native-tls", "tokio-rustls", @@ -5307,8 +5178,8 @@ checksum = "562ceb5a604d3f7c885a792d42c199fd8af239d0a51b2fa6a78aafa092452b04" dependencies = [ "anyhow", "async-trait", - "http 1.2.0", - "reqwest 0.12.9", + "http", + "reqwest", "serde", "thiserror 1.0.69", "tower-service", @@ -5370,7 +5241,7 @@ dependencies = [ "alloy-eip7702 0.2.0", "alloy-primitives", "auto_impl", - "bitflags 2.6.0", + "bitflags", "bitvec", "c-kzg", "cfg-if", @@ -5584,7 +5455,7 @@ version = "0.38.42" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f93dc38ecbab2eb790ff964bb77fa94faf256fd3e73285fd7ba0903b76bedb85" dependencies = [ - "bitflags 2.6.0", + "bitflags", "errno", "libc", "linux-raw-sys", @@ -5618,15 +5489,6 @@ dependencies = [ "security-framework 3.0.1", ] -[[package]] -name = "rustls-pemfile" -version = "1.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1c74cae0a4cf6ccbbf5f359f08efdf8ee7e1dc532573bf0db71968cb56b1448c" -dependencies = [ - "base64 0.21.7", -] - [[package]] name = "rustls-pemfile" version = "2.2.0" @@ -5790,7 +5652,7 @@ version = "2.11.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "897b2245f0b511c87893af39b033e5ca9cce68824c4d7e7630b5a1d339658d02" dependencies = [ - "bitflags 2.6.0", + "bitflags", "core-foundation 0.9.4", "core-foundation-sys", "libc", @@ -5803,7 +5665,7 @@ version = "3.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e1415a607e92bec364ea2cf9264646dcce0f91e6d65281bd6f2819cca3bf39c8" dependencies = [ - "bitflags 2.6.0", + "bitflags", "core-foundation 0.10.0", "core-foundation-sys", "libc", @@ -5935,7 +5797,7 @@ version = "3.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8e28bdad6db2b8340e449f7108f020b3b092e8583a9e3fb82713e1d4e71fe817" dependencies = [ - "base64 0.22.1", + "base64", "chrono", "hex", "indexmap 1.9.3", @@ -6111,20 +5973,7 @@ dependencies = [ [[package]] name = "sp1-build" version = "3.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e58e5f49cf1481363abb74b55104e215f3b6e58dc2adb748bde7a6e4ea61b51d" -dependencies = [ - "anyhow", - "cargo_metadata", - "chrono", - "clap", - "dirs", -] - -[[package]] -name = "sp1-build" -version = "3.4.0" -source = "git+https://github.com/succinctlabs/sp1.git?rev=f0b61cf262388c1be7edfcf984c8e070064e980f#f0b61cf262388c1be7edfcf984c8e070064e980f" +source = "git+https://github.com/succinctlabs/sp1.git?branch=dev#a1e362340be2856caa138b48e4527522a8192621" dependencies = [ "anyhow", "cargo_metadata", @@ -6136,7 +5985,7 @@ dependencies = [ [[package]] name = "sp1-core-executor" version = "3.4.0" -source = "git+https://github.com/succinctlabs/sp1.git?rev=f0b61cf262388c1be7edfcf984c8e070064e980f#f0b61cf262388c1be7edfcf984c8e070064e980f" +source = "git+https://github.com/succinctlabs/sp1.git?branch=dev#a1e362340be2856caa138b48e4527522a8192621" dependencies = [ "bincode", "bytemuck", @@ -6155,7 +6004,7 @@ dependencies = [ "rrs-succinct", "serde", "sp1-curves", - "sp1-primitives 3.4.0 (git+https://github.com/succinctlabs/sp1.git?rev=f0b61cf262388c1be7edfcf984c8e070064e980f)", + "sp1-primitives", "sp1-stark", "strum", "strum_macros", @@ -6169,7 +6018,7 @@ dependencies = [ [[package]] name = "sp1-core-machine" version = "3.4.0" -source = "git+https://github.com/succinctlabs/sp1.git?rev=f0b61cf262388c1be7edfcf984c8e070064e980f#f0b61cf262388c1be7edfcf984c8e070064e980f" +source = "git+https://github.com/succinctlabs/sp1.git?branch=dev#a1e362340be2856caa138b48e4527522a8192621" dependencies = [ "bincode", "cfg-if", @@ -6182,9 +6031,9 @@ dependencies = [ "log", "num", "num_cpus", + "p256", "p3-air", "p3-baby-bear", - "p3-blake3", "p3-challenger", "p3-field", "p3-keccak-air", @@ -6199,7 +6048,7 @@ dependencies = [ "sp1-core-executor", "sp1-curves", "sp1-derive", - "sp1-primitives 3.4.0 (git+https://github.com/succinctlabs/sp1.git?rev=f0b61cf262388c1be7edfcf984c8e070064e980f)", + "sp1-primitives", "sp1-stark", "static_assertions", "strum", @@ -6213,10 +6062,26 @@ dependencies = [ "web-time", ] +[[package]] +name = "sp1-cuda" +version = "3.4.0" +source = "git+https://github.com/succinctlabs/sp1.git?branch=dev#a1e362340be2856caa138b48e4527522a8192621" +dependencies = [ + "bincode", + "ctrlc", + "prost", + "serde", + "sp1-core-machine", + "sp1-prover", + "tokio", + "tracing", + "twirp-rs", +] + [[package]] name = "sp1-curves" version = "3.4.0" -source = "git+https://github.com/succinctlabs/sp1.git?rev=f0b61cf262388c1be7edfcf984c8e070064e980f#f0b61cf262388c1be7edfcf984c8e070064e980f" +source = "git+https://github.com/succinctlabs/sp1.git?branch=dev#a1e362340be2856caa138b48e4527522a8192621" dependencies = [ "cfg-if", "dashu", @@ -6225,10 +6090,11 @@ dependencies = [ "itertools 0.13.0", "k256", "num", + "p256", "p3-field", "serde", "snowbridge-amcl", - "sp1-primitives 3.4.0 (git+https://github.com/succinctlabs/sp1.git?rev=f0b61cf262388c1be7edfcf984c8e070064e980f)", + "sp1-primitives", "sp1-stark", "typenum", ] @@ -6236,7 +6102,7 @@ dependencies = [ [[package]] name = "sp1-derive" version = "3.4.0" -source = "git+https://github.com/succinctlabs/sp1.git?rev=f0b61cf262388c1be7edfcf984c8e070064e980f#f0b61cf262388c1be7edfcf984c8e070064e980f" +source = "git+https://github.com/succinctlabs/sp1.git?branch=dev#a1e362340be2856caa138b48e4527522a8192621" dependencies = [ "quote", "syn 1.0.109", @@ -6253,27 +6119,18 @@ dependencies = [ ] [[package]] -name = "sp1-primitives" +name = "sp1-lib" version = "3.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9d10c2078a5dfc5c3a632da1bc59b57a19dadc9c03968047d8ffb06c0f83b476" +source = "git+https://github.com/succinctlabs/sp1.git?branch=dev#a1e362340be2856caa138b48e4527522a8192621" dependencies = [ "bincode", - "hex", - "lazy_static", - "num-bigint 0.4.6", - "p3-baby-bear", - "p3-field", - "p3-poseidon2", - "p3-symmetric", "serde", - "sha2", ] [[package]] name = "sp1-primitives" version = "3.4.0" -source = "git+https://github.com/succinctlabs/sp1.git?rev=f0b61cf262388c1be7edfcf984c8e070064e980f#f0b61cf262388c1be7edfcf984c8e070064e980f" +source = "git+https://github.com/succinctlabs/sp1.git?branch=dev#a1e362340be2856caa138b48e4527522a8192621" dependencies = [ "bincode", "hex", @@ -6290,7 +6147,7 @@ dependencies = [ [[package]] name = "sp1-prover" version = "3.4.0" -source = "git+https://github.com/succinctlabs/sp1.git?rev=f0b61cf262388c1be7edfcf984c8e070064e980f#f0b61cf262388c1be7edfcf984c8e070064e980f" +source = "git+https://github.com/succinctlabs/sp1.git?branch=dev#a1e362340be2856caa138b48e4527522a8192621" dependencies = [ "anyhow", "bincode", @@ -6298,7 +6155,6 @@ dependencies = [ "dirs", "eyre", "itertools 0.13.0", - "lazy_static", "lru", "num-bigint 0.4.6", "p3-baby-bear", @@ -6308,30 +6164,27 @@ dependencies = [ "p3-field", "p3-matrix", "p3-symmetric", - "rayon", - "reqwest 0.11.27", "serde", "serde_json", "serial_test", "sp1-core-executor", "sp1-core-machine", - "sp1-primitives 3.4.0 (git+https://github.com/succinctlabs/sp1.git?rev=f0b61cf262388c1be7edfcf984c8e070064e980f)", + "sp1-primitives", "sp1-recursion-circuit", "sp1-recursion-compiler", "sp1-recursion-core", "sp1-recursion-gnark-ffi", "sp1-stark", - "subtle-encoding", - "tempfile", "thiserror 1.0.69", "tracing", + "tracing-appender", "tracing-subscriber", ] [[package]] name = "sp1-recursion-circuit" version = "3.4.0" -source = "git+https://github.com/succinctlabs/sp1.git?rev=f0b61cf262388c1be7edfcf984c8e070064e980f#f0b61cf262388c1be7edfcf984c8e070064e980f" +source = "git+https://github.com/succinctlabs/sp1.git?branch=dev#a1e362340be2856caa138b48e4527522a8192621" dependencies = [ "hashbrown 0.14.5", "itertools 0.13.0", @@ -6353,7 +6206,7 @@ dependencies = [ "sp1-core-executor", "sp1-core-machine", "sp1-derive", - "sp1-primitives 3.4.0 (git+https://github.com/succinctlabs/sp1.git?rev=f0b61cf262388c1be7edfcf984c8e070064e980f)", + "sp1-primitives", "sp1-recursion-compiler", "sp1-recursion-core", "sp1-recursion-gnark-ffi", @@ -6364,7 +6217,7 @@ dependencies = [ [[package]] name = "sp1-recursion-compiler" version = "3.4.0" -source = "git+https://github.com/succinctlabs/sp1.git?rev=f0b61cf262388c1be7edfcf984c8e070064e980f#f0b61cf262388c1be7edfcf984c8e070064e980f" +source = "git+https://github.com/succinctlabs/sp1.git?branch=dev#a1e362340be2856caa138b48e4527522a8192621" dependencies = [ "backtrace", "itertools 0.13.0", @@ -6374,7 +6227,7 @@ dependencies = [ "p3-symmetric", "serde", "sp1-core-machine", - "sp1-primitives 3.4.0 (git+https://github.com/succinctlabs/sp1.git?rev=f0b61cf262388c1be7edfcf984c8e070064e980f)", + "sp1-primitives", "sp1-recursion-core", "sp1-recursion-derive", "sp1-stark", @@ -6385,7 +6238,7 @@ dependencies = [ [[package]] name = "sp1-recursion-core" version = "3.4.0" -source = "git+https://github.com/succinctlabs/sp1.git?rev=f0b61cf262388c1be7edfcf984c8e070064e980f#f0b61cf262388c1be7edfcf984c8e070064e980f" +source = "git+https://github.com/succinctlabs/sp1.git?branch=dev#a1e362340be2856caa138b48e4527522a8192621" dependencies = [ "backtrace", "ff 0.13.0", @@ -6408,7 +6261,7 @@ dependencies = [ "serde", "sp1-core-machine", "sp1-derive", - "sp1-primitives 3.4.0 (git+https://github.com/succinctlabs/sp1.git?rev=f0b61cf262388c1be7edfcf984c8e070064e980f)", + "sp1-primitives", "sp1-stark", "static_assertions", "thiserror 1.0.69", @@ -6420,7 +6273,7 @@ dependencies = [ [[package]] name = "sp1-recursion-derive" version = "3.4.0" -source = "git+https://github.com/succinctlabs/sp1.git?rev=f0b61cf262388c1be7edfcf984c8e070064e980f#f0b61cf262388c1be7edfcf984c8e070064e980f" +source = "git+https://github.com/succinctlabs/sp1.git?branch=dev#a1e362340be2856caa138b48e4527522a8192621" dependencies = [ "quote", "syn 1.0.109", @@ -6429,7 +6282,7 @@ dependencies = [ [[package]] name = "sp1-recursion-gnark-ffi" version = "3.4.0" -source = "git+https://github.com/succinctlabs/sp1.git?rev=f0b61cf262388c1be7edfcf984c8e070064e980f#f0b61cf262388c1be7edfcf984c8e070064e980f" +source = "git+https://github.com/succinctlabs/sp1.git?branch=dev#a1e362340be2856caa138b48e4527522a8192621" dependencies = [ "anyhow", "bincode", @@ -6454,7 +6307,7 @@ dependencies = [ [[package]] name = "sp1-sdk" version = "3.4.0" -source = "git+https://github.com/succinctlabs/sp1.git?rev=f0b61cf262388c1be7edfcf984c8e070064e980f#f0b61cf262388c1be7edfcf984c8e070064e980f" +source = "git+https://github.com/succinctlabs/sp1.git?branch=dev#a1e362340be2856caa138b48e4527522a8192621" dependencies = [ "alloy-primitives", "alloy-signer 0.5.4", @@ -6476,14 +6329,15 @@ dependencies = [ "p3-field", "p3-fri", "prost", - "reqwest 0.12.9", + "reqwest", "reqwest-middleware", "serde", "serde_json", - "sp1-build 3.4.0 (git+https://github.com/succinctlabs/sp1.git?rev=f0b61cf262388c1be7edfcf984c8e070064e980f)", + "sp1-build", "sp1-core-executor", "sp1-core-machine", - "sp1-primitives 3.4.0 (git+https://github.com/succinctlabs/sp1.git?rev=f0b61cf262388c1be7edfcf984c8e070064e980f)", + "sp1-cuda", + "sp1-primitives", "sp1-prover", "sp1-stark", "strum", @@ -6500,10 +6354,9 @@ dependencies = [ [[package]] name = "sp1-stark" version = "3.4.0" -source = "git+https://github.com/succinctlabs/sp1.git?rev=f0b61cf262388c1be7edfcf984c8e070064e980f#f0b61cf262388c1be7edfcf984c8e070064e980f" +source = "git+https://github.com/succinctlabs/sp1.git?branch=dev#a1e362340be2856caa138b48e4527522a8192621" dependencies = [ "arrayref", - "getrandom", "hashbrown 0.14.5", "itertools 0.13.0", "num-traits", @@ -6524,19 +6377,17 @@ dependencies = [ "rayon-scan", "serde", "sp1-derive", - "sp1-primitives 3.4.0 (git+https://github.com/succinctlabs/sp1.git?rev=f0b61cf262388c1be7edfcf984c8e070064e980f)", + "sp1-primitives", "strum", "strum_macros", "sysinfo 0.30.13", - "thiserror 1.0.69", "tracing", ] [[package]] name = "sp1-zkvm" version = "3.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ea02449a9dcaab67219f7b3442ab51b45ae40e7b04f205382295936087fe1d5" +source = "git+https://github.com/succinctlabs/sp1.git?branch=dev#a1e362340be2856caa138b48e4527522a8192621" dependencies = [ "cfg-if", "getrandom", @@ -6546,8 +6397,8 @@ dependencies = [ "p3-field", "rand", "sha2", - "sp1-lib", - "sp1-primitives 3.4.0 (registry+https://github.com/rust-lang/crates.io-index)", + "sp1-lib 3.4.0 (git+https://github.com/succinctlabs/sp1.git?branch=dev)", + "sp1-primitives", ] [[package]] @@ -6560,7 +6411,7 @@ dependencies = [ "group 0.13.0", "pairing 0.23.0", "rand_core", - "sp1-lib", + "sp1-lib 3.4.0 (registry+https://github.com/rust-lang/crates.io-index)", "subtle", ] @@ -6645,7 +6496,7 @@ dependencies = [ "num-bigint 0.4.6", "rand", "rustc-hex", - "sp1-lib", + "sp1-lib 3.4.0 (registry+https://github.com/rust-lang/crates.io-index)", ] [[package]] @@ -6654,15 +6505,6 @@ version = "2.6.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "13c2bddecc57b384dee18652358fb23172facb8a2c51ccc10d74c157bdea3292" -[[package]] -name = "subtle-encoding" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dcb1ed7b8330c5eed5441052651dd7a12c75e2ed88f2ec024ae1fa3a5e59945" -dependencies = [ - "zeroize", -] - [[package]] name = "syn" version = "1.0.109" @@ -6697,12 +6539,6 @@ dependencies = [ "syn 2.0.90", ] -[[package]] -name = "sync_wrapper" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2047c6ded9c721764247e62cd3b03c09ffc529b2ba5b10ec482ae507a4a70160" - [[package]] name = "sync_wrapper" version = "1.0.2" @@ -6752,36 +6588,15 @@ dependencies = [ "windows 0.57.0", ] -[[package]] -name = "system-configuration" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba3a3adc5c275d719af8cb4272ea1c4a6d668a777f37e115f6d11ddbc1c8e0e7" -dependencies = [ - "bitflags 1.3.2", - "core-foundation 0.9.4", - "system-configuration-sys 0.5.0", -] - [[package]] name = "system-configuration" version = "0.6.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3c879d448e9d986b661742763247d3693ed13609438cf3d006f51f5368a5ba6b" dependencies = [ - "bitflags 2.6.0", + "bitflags", "core-foundation 0.9.4", - "system-configuration-sys 0.6.0", -] - -[[package]] -name = "system-configuration-sys" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a75fb188eb626b924683e3b95e3a48e63551fcfb51949de2f06a9d91dbee93c9" -dependencies = [ - "core-foundation-sys", - "libc", + "system-configuration-sys", ] [[package]] @@ -7066,20 +6881,20 @@ dependencies = [ "async-stream", "async-trait", "axum", - "base64 0.22.1", + "base64", "bytes", - "h2 0.4.7", - "http 1.2.0", - "http-body 1.0.1", + "h2", + "http", + "http-body", "http-body-util", - "hyper 1.5.2", + "hyper", "hyper-timeout", "hyper-util", "percent-encoding", "pin-project", "prost", "rustls-native-certs", - "rustls-pemfile 2.2.0", + "rustls-pemfile", "socket2", "tokio", "tokio-rustls", @@ -7119,7 +6934,7 @@ dependencies = [ "futures-core", "futures-util", "pin-project-lite", - "sync_wrapper 1.0.2", + "sync_wrapper", "tokio", "tower-layer", "tower-service", @@ -7132,10 +6947,10 @@ version = "0.5.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1e9cd434a998747dd2c4276bc96ee2e0c7a2eadf3cae88e52be55a05fa9053f5" dependencies = [ - "bitflags 2.6.0", + "bitflags", "bytes", - "http 1.2.0", - "http-body 1.0.1", + "http", + "http-body", "http-body-util", "pin-project-lite", "tower-layer", @@ -7166,6 +6981,18 @@ dependencies = [ "tracing-core", ] +[[package]] +name = "tracing-appender" +version = "0.2.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3566e8ce28cc0a3fe42519fc80e6b4c943cc4c8cef275620eb8dac2d3d4e06cf" +dependencies = [ + "crossbeam-channel", + "thiserror 1.0.69", + "time", + "tracing-subscriber", +] + [[package]] name = "tracing-attributes" version = "0.1.28" @@ -7244,7 +7071,7 @@ dependencies = [ "byteorder", "bytes", "data-encoding", - "http 1.2.0", + "http", "httparse", "log", "rand", @@ -7264,11 +7091,11 @@ dependencies = [ "async-trait", "axum", "futures", - "http 1.2.0", + "http", "http-body-util", - "hyper 1.5.2", + "hyper", "prost", - "reqwest 0.12.9", + "reqwest", "serde", "serde_json", "thiserror 1.0.69", @@ -7861,16 +7688,6 @@ dependencies = [ "memchr", ] -[[package]] -name = "winreg" -version = "0.50.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "524e57b2c537c0f9b1e69f1965311ec12182b4122e45035b1508cd24d2adadb1" -dependencies = [ - "cfg-if", - "windows-sys 0.48.0", -] - [[package]] name = "write16" version = "1.0.0" diff --git a/Cargo.toml b/Cargo.toml index a1bf8145..29cacc82 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -88,14 +88,10 @@ op-alloy-rpc-types-engine = { version = "0.6.8", default-features = false } op-alloy-network = { version = "0.6.8", default-features = false } # sp1 -sp1-lib = { version = "3.4.0", features = ["verify"] } -# Note: This rev includes the SP1 mock groth16 bytes fix, skipping deferred verification, executor opts and network-v2 changes. -# ratan/v3.4.0-with-additions includes the network-v2 changes from `19ae3e1`. Has the latest FD's for ECDSA patch. -sp1-sdk = { git = "https://github.com/succinctlabs/sp1.git", rev = "f0b61cf262388c1be7edfcf984c8e070064e980f", features = [ - "network-v2", -] } -sp1-zkvm = { version = "3.4.0", features = ["verify"] } -sp1-build = { version = "3.4.0" } +sp1-lib = { git = "https://github.com/succinctlabs/sp1.git", branch = "dev", features = ["verify"] } +sp1-sdk = { git = "https://github.com/succinctlabs/sp1.git", branch = "dev" } +sp1-zkvm = { git = "https://github.com/succinctlabs/sp1.git", branch = "dev", features = ["verify"] } +sp1-build = { git = "https://github.com/succinctlabs/sp1.git", branch = "dev"} [profile.release-client-lto] inherits = "release" diff --git a/proposer/succinct/bin/server.rs b/proposer/succinct/bin/server.rs index 382bd73a..3e98d0e3 100644 --- a/proposer/succinct/bin/server.rs +++ b/proposer/succinct/bin/server.rs @@ -23,11 +23,11 @@ use op_succinct_proposer::{ ValidateConfigRequest, ValidateConfigResponse, }; use sp1_sdk::{ - network_v2::{ - client::NetworkClient, - proto::network::{ExecutionStatus, FulfillmentStatus, FulfillmentStrategy, ProofMode}, + network::{ + proto::network::{ExecutionStatus, FulfillmentStatus}, + FulfillmentStrategy, }, - utils, HashableKey, NetworkProverV2, ProverClient, SP1Proof, SP1ProofWithPublicValues, + utils, HashableKey, ProverClient, SP1Proof, SP1ProofWithPublicValues, }; use std::{env, str::FromStr, time::Duration}; use tower_http::limit::RequestBodyLimitLayer; @@ -41,7 +41,7 @@ async fn main() -> Result<()> { dotenv::dotenv().ok(); - let prover = ProverClient::new(); + let prover = ProverClient::from_env(); let (range_pk, range_vk) = prover.setup(RANGE_ELF); let (agg_pk, agg_vk) = prover.setup(AGG_ELF); let multi_block_vkey_u8 = u32_to_u8(range_vk.vk.hash_u32()); @@ -179,59 +179,19 @@ async fn request_span_proof( } }; - let private_key = match env::var("SP1_PRIVATE_KEY") { - Ok(private_key) => private_key, - Err(e) => { - error!("Failed to get SP1 private key: {}", e); - return Err(AppError(anyhow::anyhow!( - "Failed to get SP1 private key: {}", - e - ))); - } - }; - let rpc_url = match env::var("PROVER_NETWORK_RPC") { - Ok(rpc_url) => rpc_url, - Err(e) => { - error!("Failed to get PROVER_NETWORK_RPC: {}", e); - return Err(AppError(anyhow::anyhow!( - "Failed to get PROVER_NETWORK_RPC: {}", - e - ))); - } - }; - let mut prover = NetworkProverV2::new(&private_key, Some(rpc_url.to_string()), false); - // Use the reserved strategy to route to a specific cluster. - prover.with_strategy(FulfillmentStrategy::Reserved); - - // Set simulation to false on range proofs as they're large. - env::set_var("SKIP_SIMULATION", "true"); - let vk_hash = match prover.register_program(&state.range_vk, RANGE_ELF).await { - Ok(vk_hash) => vk_hash, - Err(e) => { - error!("Failed to register program: {}", e); - return Err(AppError(anyhow::anyhow!( - "Failed to register program: {}", - e - ))); - } - }; - let proof_id = match prover - .request_proof( - &vk_hash, - &sp1_stdin, - ProofMode::Compressed, - 1_000_000_000_000, - None, - ) + let client = ProverClient::builder().network().build(); + let proof_id = client + .prove(&state.range_pk, &sp1_stdin) + .compressed() + .strategy(FulfillmentStrategy::Reserved) + .skip_simulation(true) + .cycle_limit(1_000_000_000_000) + .request() .await - { - Ok(proof_id) => proof_id, - Err(e) => { + .map_err(|e| { error!("Failed to request proof: {}", e); - return Err(AppError(anyhow::anyhow!("Failed to request proof: {}", e))); - } - }; - env::set_var("SKIP_SIMULATION", "false"); + AppError(anyhow::anyhow!("Failed to request proof: {}", e)) + })?; Ok((StatusCode::OK, Json(ProofResponse { proof_id }))) } @@ -285,11 +245,7 @@ async fn request_agg_proof( } }; - let private_key = env::var("SP1_PRIVATE_KEY")?; - let rpc_url = env::var("PROVER_NETWORK_RPC")?; - let mut prover = NetworkProverV2::new(&private_key, Some(rpc_url.to_string()), false); - // Use the reserved strategy to route to a specific cluster. - prover.with_strategy(FulfillmentStrategy::Reserved); + let prover = ProverClient::builder().network().build(); let stdin = match get_agg_proof_stdin(proofs, boot_infos, headers, &state.range_vk, l1_head.into()) { @@ -303,24 +259,11 @@ async fn request_agg_proof( } }; - let vk_hash = match prover.register_program(&state.agg_vk, AGG_ELF).await { - Ok(vk_hash) => vk_hash, - Err(e) => { - error!("Failed to register program: {}", e); - return Err(AppError(anyhow::anyhow!( - "Failed to register program: {}", - e - ))); - } - }; let proof_id = match prover - .request_proof( - &vk_hash, - &stdin, - ProofMode::Groth16, - 1_000_000_000_000, - None, - ) + .prove(&state.agg_pk, &stdin) + .groth16() + .strategy(FulfillmentStrategy::Reserved) + .request() .await { Ok(id) => id, @@ -388,10 +331,9 @@ async fn request_mock_span_proof( } }; - let prover = ProverClient::mock(); + let prover = ProverClient::builder().mock().build(); let proof = prover - .prove(&state.range_pk, sp1_stdin) - .set_skip_deferred_proof_verification(true) + .prove(&state.range_pk, &sp1_stdin) .compressed() .run()?; @@ -462,7 +404,7 @@ async fn request_mock_agg_proof( } }; - let prover = ProverClient::mock(); + let prover = ProverClient::builder().mock().build(); let stdin = match get_agg_proof_stdin(proofs, boot_infos, headers, &state.range_vk, l1_head.into()) { @@ -475,9 +417,9 @@ async fn request_mock_agg_proof( // Simulate the mock proof. proof.bytes() returns an empty byte array for mock proofs. let proof = match prover - .prove(&state.agg_pk, stdin) - .set_skip_deferred_proof_verification(true) + .prove(&state.agg_pk, &stdin) .groth16() + .deferred_proof_verification(false) .run() { Ok(p) => p, @@ -502,18 +444,15 @@ async fn get_proof_status( Path(proof_id): Path, ) -> Result<(StatusCode, Json), AppError> { info!("Received proof status request: {:?}", proof_id); - let private_key = env::var("SP1_PRIVATE_KEY")?; - let rpc_url = env::var("PROVER_NETWORK_RPC")?; - let client = NetworkClient::new(&private_key, Some(rpc_url.to_string())); + let client = ProverClient::builder().network().build(); let proof_id_bytes = hex::decode(proof_id)?; // Time out this request if it takes too long. let timeout = Duration::from_secs(10); let (status, maybe_proof) = - match tokio::time::timeout(timeout, client.get_proof_request_status(&proof_id_bytes)).await - { + match tokio::time::timeout(timeout, client.get_proof_status(&proof_id_bytes)).await { Ok(Ok(result)) => result, Ok(Err(_)) => { return Ok(( diff --git a/scripts/prove/Cargo.toml b/scripts/prove/Cargo.toml index 5e91b543..9e6c5389 100644 --- a/scripts/prove/Cargo.toml +++ b/scripts/prove/Cargo.toml @@ -32,6 +32,7 @@ kona-host = { workspace = true } # local op-succinct-host-utils.workspace = true op-succinct-client-utils.workspace = true +op-succinct-scripts = { path = "../utils" } # op-alloy op-alloy-genesis.workspace = true diff --git a/scripts/prove/bin/agg.rs b/scripts/prove/bin/agg.rs index adef883b..ae43d52a 100644 --- a/scripts/prove/bin/agg.rs +++ b/scripts/prove/bin/agg.rs @@ -33,7 +33,6 @@ struct Args { fn load_aggregation_proof_data( proof_names: Vec, range_vkey: &SP1VerifyingKey, - prover: &ProverClient, ) -> (Vec, Vec) { let metadata = MetadataCommand::new().exec().unwrap(); let workspace_root = metadata.workspace_root; @@ -42,6 +41,8 @@ fn load_aggregation_proof_data( let mut proofs = Vec::with_capacity(proof_names.len()); let mut boot_infos = Vec::with_capacity(proof_names.len()); + let prover = ProverClient::from_env(); + for proof_name in proof_names.iter() { let proof_path = format!("{}/{}.bin", proof_directory, proof_name); if fs::metadata(&proof_path).is_err() { @@ -71,12 +72,12 @@ async fn main() -> Result<()> { dotenv::from_filename(args.env_file).ok(); - let prover = ProverClient::new(); + let prover = ProverClient::from_env(); let fetcher = OPSuccinctDataFetcher::new_with_rollup_config(RunContext::Dev).await?; let (_, vkey) = prover.setup(RANGE_ELF); - let (proofs, boot_infos) = load_aggregation_proof_data(args.proofs, &vkey, &prover); + let (proofs, boot_infos) = load_aggregation_proof_data(args.proofs, &vkey); let header = fetcher.get_latest_l1_head_in_batch(&boot_infos).await?; let headers = fetcher @@ -96,12 +97,12 @@ async fn main() -> Result<()> { if args.prove { prover - .prove(&agg_pk, stdin) + .prove(&agg_pk, &stdin) .groth16() .run() .expect("proving failed"); } else { - let (_, report) = prover.execute(AGG_ELF, stdin).run().unwrap(); + let (_, report) = prover.execute(AGG_ELF, &stdin).run().unwrap(); println!("report: {:?}", report); } diff --git a/scripts/prove/bin/multi.rs b/scripts/prove/bin/multi.rs index 4dc318a0..5553b577 100644 --- a/scripts/prove/bin/multi.rs +++ b/scripts/prove/bin/multi.rs @@ -8,41 +8,14 @@ use op_succinct_host_utils::{ ProgramType, }; use op_succinct_prove::{execute_multi, generate_witness, DEFAULT_RANGE, RANGE_ELF}; -use sp1_sdk::{utils, ProverClient}; -use std::{fs, path::PathBuf, time::Duration}; - -#[derive(Parser, Debug)] -#[command(author, version, about, long_about = None)] -struct Args { - /// Start L2 block number. - #[arg(short, long)] - start: Option, - - /// End L2 block number. - #[arg(short, long)] - end: Option, - - /// Verbosity level. - #[arg(short, long, default_value = "0")] - verbosity: u8, - - /// Skip running native execution. - #[arg(short, long)] - use_cache: bool, - - /// Generate proof. - #[arg(short, long)] - prove: bool, - - /// Env file. - #[arg(long, default_value = ".env")] - env_file: PathBuf, -} +use op_succinct_scripts::HostExecutorArgs; +use sp1_sdk::{network::FulfillmentStrategy, utils, Prover, ProverClient}; +use std::{fs, time::Duration}; /// Execute the OP Succinct program for multiple blocks. #[tokio::main] async fn main() -> Result<()> { - let args = Args::parse(); + let args = HostExecutorArgs::parse(); dotenv::from_path(&args.env_file)?; utils::setup_logger(); @@ -73,14 +46,19 @@ async fn main() -> Result<()> { // Get the stdin for the block. let sp1_stdin = get_proof_stdin(&host_cli)?; - let prover = ProverClient::new(); + let prover = ProverClient::builder().network().build(); if args.prove { // If the prove flag is set, generate a proof. let (pk, _) = prover.setup(RANGE_ELF); // Generate proofs in compressed mode for aggregation verification. - let proof = prover.prove(&pk, sp1_stdin).compressed().run().unwrap(); + let proof = prover + .prove(&pk, &sp1_stdin) + .compressed() + .strategy(FulfillmentStrategy::Reserved) + .run() + .unwrap(); // Create a proof directory for the chain ID if it doesn't exist. let proof_dir = format!( @@ -100,14 +78,8 @@ async fn main() -> Result<()> { } else { let l2_chain_id = data_fetcher.get_l2_chain_id().await?; - let (block_data, report, execution_duration) = execute_multi( - &prover, - &data_fetcher, - sp1_stdin, - l2_start_block, - l2_end_block, - ) - .await?; + let (block_data, report, execution_duration) = + execute_multi(&data_fetcher, sp1_stdin, l2_start_block, l2_end_block).await?; let stats = ExecutionStats::new( &block_data, diff --git a/scripts/prove/src/lib.rs b/scripts/prove/src/lib.rs index ad5c62b8..198c9789 100644 --- a/scripts/prove/src/lib.rs +++ b/scripts/prove/src/lib.rs @@ -33,14 +33,14 @@ pub async fn generate_witness(host_cli: &HostCli) -> Result { } pub async fn execute_multi( - prover: &ProverClient, data_fetcher: &OPSuccinctDataFetcher, sp1_stdin: SP1Stdin, l2_start_block: u64, l2_end_block: u64, ) -> Result<(Vec, ExecutionReport, Duration)> { let start_time = Instant::now(); - let (_, report) = prover.execute(RANGE_ELF, sp1_stdin.clone()).run().unwrap(); + let prover = ProverClient::from_env(); + let (_, report) = prover.execute(RANGE_ELF, &sp1_stdin).run().unwrap(); let execution_duration = start_time.elapsed(); let block_data = data_fetcher diff --git a/scripts/prove/tests/multi.rs b/scripts/prove/tests/multi.rs index 20949c7c..5bf95e15 100644 --- a/scripts/prove/tests/multi.rs +++ b/scripts/prove/tests/multi.rs @@ -8,7 +8,6 @@ use op_succinct_host_utils::{ ProgramType, }; use op_succinct_prove::{execute_multi, generate_witness, DEFAULT_RANGE, ONE_HOUR}; -use sp1_sdk::ProverClient; mod common; @@ -36,16 +35,8 @@ async fn execute_batch() -> Result<()> { // Get the stdin for the block. let sp1_stdin = get_proof_stdin(&host_cli)?; - let prover = ProverClient::new(); - - let (block_data, report, execution_duration) = execute_multi( - &prover, - &data_fetcher, - sp1_stdin, - l2_start_block, - l2_end_block, - ) - .await?; + let (block_data, report, execution_duration) = + execute_multi(&data_fetcher, sp1_stdin, l2_start_block, l2_end_block).await?; let stats = ExecutionStats::new( &block_data, diff --git a/scripts/utils/bin/cost_estimator.rs b/scripts/utils/bin/cost_estimator.rs index 71fcb57a..896bf62b 100644 --- a/scripts/utils/bin/cost_estimator.rs +++ b/scripts/utils/bin/cost_estimator.rs @@ -34,7 +34,6 @@ const TWELVE_HOURS: Duration = Duration::from_secs(60 * 60 * 12); async fn execute_blocks_and_write_stats_csv( host_clis: &[HostCli], ranges: Vec, - prover: &ProverClient, l2_chain_id: u64, start: u64, end: u64, @@ -73,6 +72,8 @@ async fn execute_blocks_and_write_stats_csv( fs::File::create(&report_path).unwrap(); let report_path = report_path.canonicalize().unwrap(); + let prover = ProverClient::from_env(); + // Run the zkVM execution process for each split range in parallel and fill in the execution stats. host_clis .par_iter() @@ -81,7 +82,7 @@ async fn execute_blocks_and_write_stats_csv( let sp1_stdin = get_proof_stdin(host_cli).unwrap(); // FIXME: Implement retries with a smaller block range if this fails. - let result = prover.execute(RANGE_ELF, sp1_stdin).run(); + let result = prover.execute(RANGE_ELF, &sp1_stdin).run(); // If the execution fails, skip this block range and log the error. if let Some(err) = result.as_ref().err() { @@ -206,8 +207,6 @@ async fn main() -> Result<()> { split_ranges ); - let prover = ProverClient::new(); - let cache_mode = if args.use_cache { CacheMode::KeepCache } else { @@ -237,7 +236,6 @@ async fn main() -> Result<()> { execute_blocks_and_write_stats_csv( &host_clis, split_ranges, - &prover, l2_chain_id, l2_start_block, l2_end_block, diff --git a/scripts/utils/bin/fetch_and_save_proof.rs b/scripts/utils/bin/fetch_and_save_proof.rs index 949291ca..5caaf6b6 100644 --- a/scripts/utils/bin/fetch_and_save_proof.rs +++ b/scripts/utils/bin/fetch_and_save_proof.rs @@ -2,8 +2,11 @@ use alloy::{hex, sol_types::SolValue}; use anyhow::Result; use clap::Parser; use op_succinct_client_utils::{boot::BootInfoStruct, AGGREGATION_OUTPUTS_SIZE}; -use sp1_sdk::{NetworkProverV2, SP1ProofWithPublicValues}; -use std::{env, fs, path::Path}; +use sp1_sdk::{ + network::proto::network::{ExecutionStatus, FulfillmentStatus, GetProofRequestStatusResponse}, + ProverClient, SP1ProofWithPublicValues, +}; +use std::{fs, path::Path}; #[derive(Parser, Debug)] #[command(author, version, about, long_about = None)] @@ -30,13 +33,24 @@ async fn main() -> Result<()> { dotenv::dotenv().ok(); let args = Args::parse(); - let private_key = env::var("SP1_PRIVATE_KEY")?; - let rpc_url = env::var("PROVER_NETWORK_RPC")?; - let prover = NetworkProverV2::new(&private_key, Some(rpc_url.to_string()), false); + let prover = ProverClient::builder().network().build(); let request_id = hex::decode(&args.request_id)?; // Fetch the proof - let mut proof: SP1ProofWithPublicValues = prover.wait_proof(&request_id, None).await?; + let (status, proof): ( + GetProofRequestStatusResponse, + Option, + ) = prover.get_proof_status(&request_id).await?; + let fulfillment_status = FulfillmentStatus::try_from(status.fulfillment_status).unwrap(); + let _ = ExecutionStatus::try_from(status.execution_status).unwrap(); + + let mut proof = match fulfillment_status { + FulfillmentStatus::Fulfilled => proof.unwrap(), + _ => { + println!("Proof is still pending"); + return Ok(()); + } + }; if args.agg_proof { let mut raw_boot_info = [0u8; AGGREGATION_OUTPUTS_SIZE]; diff --git a/scripts/utils/bin/fetch_rollup_config.rs b/scripts/utils/bin/fetch_rollup_config.rs index 9824beca..331ae1c3 100644 --- a/scripts/utils/bin/fetch_rollup_config.rs +++ b/scripts/utils/bin/fetch_rollup_config.rs @@ -121,7 +121,7 @@ async fn update_l2oo_config() -> Result<()> { let owner = get_address("OWNER"); let challenger = get_address("CHALLENGER"); - let prover = ProverClient::new(); + let prover = ProverClient::from_env(); let (_, agg_vkey) = prover.setup(AGG_ELF); let aggregation_vkey = agg_vkey.vk.bytes32(); diff --git a/scripts/utils/bin/gen_sp1_test_artifacts.rs b/scripts/utils/bin/gen_sp1_test_artifacts.rs index 4cf0a0af..e3161cb7 100644 --- a/scripts/utils/bin/gen_sp1_test_artifacts.rs +++ b/scripts/utils/bin/gen_sp1_test_artifacts.rs @@ -25,8 +25,8 @@ pub const RANGE_ELF: &[u8] = include_bytes!("../../../elf/range-elf"); async fn execute_blocks_parallel( host_clis: &[HostCli], ranges: Vec, - prover: &ProverClient, ) -> Vec<(SP1Stdin, SpanBatchRange)> { + let prover = ProverClient::from_env(); // Run the zkVM execution process for each split range in parallel and fill in the execution stats. let successful_ranges = host_clis .par_iter() @@ -34,7 +34,7 @@ async fn execute_blocks_parallel( .map(|(host_cli, range)| { let sp1_stdin = get_proof_stdin(host_cli).unwrap(); - let result = prover.execute(RANGE_ELF, sp1_stdin.clone()).run(); + let result = prover.execute(RANGE_ELF, &sp1_stdin).run(); // If the execution fails, skip this block range and log the error. if let Some(err) = result.as_ref().err() { @@ -77,8 +77,6 @@ async fn main() -> Result<()> { split_ranges ); - let prover = ProverClient::new(); - let cache_mode = if args.use_cache { CacheMode::KeepCache } else { @@ -102,7 +100,7 @@ async fn main() -> Result<()> { run_native_data_generation(&host_clis).await; } - let successful_ranges = execute_blocks_parallel(&host_clis, split_ranges, &prover).await; + let successful_ranges = execute_blocks_parallel(&host_clis, split_ranges).await; // Now, write the successful ranges to /sp1-testing-suite-artifacts/op-succinct-chain-{l2_chain_id}-{start}-{end} // The folders should each have the RANGE_ELF as program.bin, and the serialized stdin should be diff --git a/scripts/utils/bin/vkey.rs b/scripts/utils/bin/vkey.rs index 2996ebeb..1f322db0 100644 --- a/scripts/utils/bin/vkey.rs +++ b/scripts/utils/bin/vkey.rs @@ -12,7 +12,7 @@ async fn main() -> Result<()> { dotenv::dotenv().ok(); utils::setup_logger(); - let prover = ProverClient::new(); + let prover = ProverClient::from_env(); let (_, range_vk) = prover.setup(RANGE_ELF); diff --git a/scripts/utils/src/lib.rs b/scripts/utils/src/lib.rs index b88bdfa7..bce9190a 100644 --- a/scripts/utils/src/lib.rs +++ b/scripts/utils/src/lib.rs @@ -25,4 +25,7 @@ pub struct HostExecutorArgs { /// The environment file to use. #[clap(long, default_value = ".env")] pub env_file: PathBuf, + /// Whether to generate proofs. + #[clap(long)] + pub prove: bool, }