diff --git a/Cargo.lock b/Cargo.lock index c4a6db2..dadebf2 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -110,7 +110,7 @@ dependencies = [ "k256", "keccak-asm", "proptest", - "rand 0.8.5", + "rand", "ruint", "serde", "tiny-keccak", @@ -306,7 +306,6 @@ dependencies = [ "hashbrown 0.13.2", "itertools 0.10.5", "num-traits", - "rayon", "zeroize", ] @@ -343,7 +342,6 @@ dependencies = [ "num-bigint 0.4.6", "num-traits", "paste", - "rayon", "rustc_version 0.4.0", "zeroize", ] @@ -493,7 +491,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1df2c09229cbc5a028b1d70e00fdb2acee28b1055dfb5ca73eea49c5a25c4e7c" dependencies = [ "num-traits", - "rand 0.8.5", + "rand", ] [[package]] @@ -503,8 +501,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "94893f1e0c6eeab764ade8dc4c0db24caf4fe7cbbaafc0eba0a9030f447b5185" dependencies = [ "num-traits", - "rand 0.8.5", - "rayon", + "rand", ] [[package]] @@ -639,7 +636,7 @@ dependencies = [ "cfg-if", "libc", "miniz_oxide", - "object 0.36.1", + "object", "rustc-demangle", "serde", ] @@ -712,35 +709,6 @@ dependencies = [ "which", ] -[[package]] -name = "binius_field" -version = "0.1.0" -source = "git+https://gitlab.com/UlvetannaOSS/binius#45e676b5333ff6bb2a3a2540e3c839c7cbe741ef" -dependencies = [ - "binius_utils", - "bytemuck", - "cfg-if", - "derive_more", - "p3-util 0.1.0 (git+https://github.com/Plonky3/Plonky3?rev=3f5fb24)", - "rand 0.8.5", - "rayon", - "seq-macro", - "subtle", - "thiserror", - "transpose", -] - -[[package]] -name = "binius_utils" -version = "0.1.0" -source = "git+https://gitlab.com/UlvetannaOSS/binius#45e676b5333ff6bb2a3a2540e3c839c7cbe741ef" -dependencies = [ - "rayon", - "tracing", - "tracing-profile", - "tracing-subscriber 0.3.18", -] - [[package]] name = "bit-set" version = "0.5.3" @@ -832,7 +800,7 @@ dependencies = [ "ff 0.12.1", "group 0.12.1", "pairing", - "rand_core 0.6.4", + "rand_core", "subtle", ] @@ -1059,12 +1027,6 @@ version = "0.7.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4b82cf0babdbd58558212896d1a4272303a57bdb245c2bf1147185fb45640e70" -[[package]] -name = "cobs" -version = "0.2.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "67ba02a97a2bd10f4b59b25c7973101c79642302776489e030cd13cdab09ed15" - [[package]] name = "coins-bip32" version = "0.8.7" @@ -1092,7 +1054,7 @@ dependencies = [ "hmac", "once_cell", "pbkdf2 0.12.2", - "rand 0.8.5", + "rand", "sha2", "thiserror", ] @@ -1123,27 +1085,6 @@ version = "1.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0b6a852b24ab71dffc585bcb46eaf7959d175cb865a7152e35b348d1b2960422" -[[package]] -name = "colored" -version = "2.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cbf2150cce219b664a8a70df7a1f933836724b503f8a413af9365b4dcc4d90b8" -dependencies = [ - "lazy_static", - "windows-sys 0.48.0", -] - -[[package]] -name = "common" -version = "0.2.0" -source = "git+https://github.com/a16z/jolt#5d1b57cb1dac6b675e90e5a1db1271c44366a6b4" -dependencies = [ - "ark-serialize 0.4.2", - "serde", - "serde_json", - "strum_macros 0.25.3", -] - [[package]] name = "console" version = "0.15.8" @@ -1266,7 +1207,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0dc92fb57ca44df6db8059111ab3af99a63d5d0f8375d9972e319a379c6bab76" dependencies = [ "generic-array 0.14.7", - "rand_core 0.6.4", + "rand_core", "subtle", "zeroize", ] @@ -1483,16 +1424,6 @@ version = "1.2.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "75b325c5dbd37f80359721ad39aca5a29fb04c89279657cffdda8736d0c0b9d2" -[[package]] -name = "drawille" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e64e461c3f1e69d99372620640b3fd5f0309eeda2e26e4af69f6760c0e1df845" -dependencies = [ - "colored", - "fnv", -] - [[package]] name = "dunce" version = "1.0.4" @@ -1548,18 +1479,12 @@ dependencies = [ "generic-array 0.14.7", "group 0.13.0", "pkcs8", - "rand_core 0.6.4", + "rand_core", "sec1", "subtle", "zeroize", ] -[[package]] -name = "embedded-io" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ef1a6892d9eef45c8fa6b9e0086428a2cca8491aca8f787c534a3d6d0bcb3ced" - [[package]] name = "ena" version = "0.14.3" @@ -1595,25 +1520,13 @@ dependencies = [ "hex", "k256", "log", - "rand 0.8.5", + "rand", "rlp", "serde", "sha3", "zeroize", ] -[[package]] -name = "enum_dispatch" -version = "0.3.13" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "aa18ce2bc66555b3218614519ac839ddb759a7d6720732f979ef8d13be147ecd" -dependencies = [ - "once_cell", - "proc-macro2", - "quote", - "syn 2.0.68", -] - [[package]] name = "equivalent" version = "1.0.1" @@ -1642,7 +1555,7 @@ dependencies = [ "hex", "hmac", "pbkdf2 0.11.0", - "rand 0.8.5", + "rand", "scrypt", "serde", "serde_json", @@ -1883,11 +1796,11 @@ dependencies = [ "num_enum 0.7.2", "once_cell", "open-fastrlp", - "rand 0.8.5", + "rand", "rlp", "serde", "serde_json", - "strum 0.26.3", + "strum", "syn 2.0.68", "tempfile", "thiserror", @@ -1912,11 +1825,11 @@ dependencies = [ "num_enum 0.7.2", "once_cell", "open-fastrlp", - "rand 0.8.5", + "rand", "rlp", "serde", "serde_json", - "strum 0.26.3", + "strum", "syn 2.0.68", "tempfile", "thiserror", @@ -2077,7 +1990,7 @@ dependencies = [ "elliptic-curve", "eth-keystore", "ethers-core 2.0.14 (registry+https://github.com/rust-lang/crates.io-index)", - "rand 0.8.5", + "rand", "sha2", "thiserror", "tracing", @@ -2095,7 +2008,7 @@ dependencies = [ "elliptic-curve", "eth-keystore", "ethers-core 2.0.14 (git+https://github.com/yetanotherco/ethers-rs.git?tag=v2.0.15-fix-reconnections)", - "rand 0.8.5", + "rand", "sha2", "thiserror", "tracing", @@ -2166,7 +2079,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d013fc25338cc558c5c2cfbad646908fb23591e2404481826742b651c9af7160" dependencies = [ "bitvec", - "rand_core 0.6.4", + "rand_core", "subtle", ] @@ -2179,7 +2092,7 @@ dependencies = [ "bitvec", "byteorder", "ff_derive", - "rand_core 0.6.4", + "rand_core", "subtle", ] @@ -2212,7 +2125,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "835c052cb0c08c1acf6ffd71c022172e18723949c8282f2b9f27efbc51e64534" dependencies = [ "byteorder", - "rand 0.8.5", + "rand", "rustc-hex", "static_assertions", ] @@ -2223,12 +2136,6 @@ version = "0.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0ce7134b9999ecaf8bcd65542e436736ef32ddca1b3e06094cb6ec5755203b80" -[[package]] -name = "fixedbitset" -version = "0.5.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1d674e81391d1e1ab681a28d99df07927c6d4aa5b027d7da16ba32d1d21ecd99" - [[package]] name = "flate2" version = "1.0.30" @@ -2430,17 +2337,6 @@ dependencies = [ "typenum", ] -[[package]] -name = "getrandom" -version = "0.1.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8fc3cb4d91f53b50155bdcfd23f6a4c39ae1969c2ae85982b135750cccaf5fce" -dependencies = [ - "cfg-if", - "libc", - "wasi 0.9.0+wasi-snapshot-preview1", -] - [[package]] name = "getrandom" version = "0.2.15" @@ -2449,7 +2345,7 @@ checksum = "c4567c8db10ae91089c99af84c68c38da3ec2f087c3f82960bcdbf3656b6f4d7" dependencies = [ "cfg-if", "libc", - "wasi 0.11.0+wasi-snapshot-preview1", + "wasi", ] [[package]] @@ -2497,7 +2393,7 @@ checksum = "5dfbfb3a6cfbd390d5c9564ab283a0349b9b9fcd46a706c1eb10e0db70bfbac7" dependencies = [ "ff 0.12.1", "memuse", - "rand_core 0.6.4", + "rand_core", "subtle", ] @@ -2508,7 +2404,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f0f9ef7462f7c099f518d754361858f86d8a07af53ba9af0fe635bbccb151a63" dependencies = [ "ff 0.13.0", - "rand_core 0.6.4", + "rand_core", "subtle", ] @@ -2569,7 +2465,7 @@ dependencies = [ "ff 0.12.1", "group 0.12.1", "pasta_curves 0.4.1", - "rand_core 0.6.4", + "rand_core", "rayon", ] @@ -3035,84 +2931,6 @@ dependencies = [ "libc", ] -[[package]] -name = "jolt-core" -version = "0.1.0" -source = "git+https://github.com/a16z/jolt#5d1b57cb1dac6b675e90e5a1db1271c44366a6b4" -dependencies = [ - "ark-bn254", - "ark-ec", - "ark-ff 0.4.2", - "ark-serialize 0.4.2", - "ark-std 0.4.0", - "bincode", - "binius_field", - "bytemuck", - "clap", - "common", - "dirs", - "enum_dispatch", - "eyre", - "fixedbitset 0.5.7", - "indicatif", - "itertools 0.10.5", - "lazy_static", - "memory-stats", - "merlin", - "num-integer", - "postcard", - "rand 0.7.3", - "rand_chacha 0.3.1", - "rand_core 0.6.4", - "rayon", - "reqwest 0.12.5", - "rgb", - "serde", - "sha3", - "smallvec", - "strum 0.25.0", - "strum_macros 0.25.3", - "target-lexicon", - "textplots", - "thiserror", - "tokio", - "tracer", - "tracing", - "tracing-chrome", - "tracing-flame", - "tracing-subscriber 0.3.18", - "tracing-texray", -] - -[[package]] -name = "jolt-sdk" -version = "0.1.0" -source = "git+https://github.com/a16z/jolt#5d1b57cb1dac6b675e90e5a1db1271c44366a6b4" -dependencies = [ - "ark-bn254", - "ark-ec", - "ark-ff 0.4.2", - "ark-serialize 0.4.2", - "common", - "eyre", - "jolt-core", - "jolt-sdk-macros", - "postcard", - "serde", - "tracer", -] - -[[package]] -name = "jolt-sdk-macros" -version = "0.1.0" -source = "git+https://github.com/a16z/jolt#5d1b57cb1dac6b675e90e5a1db1271c44366a6b4" -dependencies = [ - "common", - "proc-macro2", - "quote", - "syn 1.0.109", -] - [[package]] name = "js-sys" version = "0.3.69" @@ -3146,7 +2964,7 @@ dependencies = [ "bls12_381", "ff 0.12.1", "group 0.12.1", - "rand_core 0.6.4", + "rand_core", "subtle", ] @@ -3370,34 +3188,12 @@ version = "2.7.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "78ca9ab1a0babb1e7d5695e3530886289c18cf2f87ec19a575a0abdce112e3a3" -[[package]] -name = "memory-stats" -version = "1.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c73f5c649995a115e1a0220b35e4df0a1294500477f97a91d0660fb5abeb574a" -dependencies = [ - "libc", - "windows-sys 0.52.0", -] - [[package]] name = "memuse" version = "0.2.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "2145869435ace5ea6ea3d35f59be559317ec9a0d04e1812d5f185a87b6d36f1a" -[[package]] -name = "merlin" -version = "3.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "58c38e2799fc0978b65dfff8023ec7843e2330bb462f19198840b34b6582397d" -dependencies = [ - "byteorder", - "keccak", - "rand_core 0.6.4", - "zeroize", -] - [[package]] name = "mime" version = "0.3.17" @@ -3426,7 +3222,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a4a650543ca06a924e8b371db273b2756685faae30f8487da1b56505a8f78b0c" dependencies = [ "libc", - "wasi 0.11.0+wasi-snapshot-preview1", + "wasi", "windows-sys 0.48.0", ] @@ -3637,17 +3433,6 @@ version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "830b246a0e5f20af87141b25c173cd1b609bd7779a4617d6ec582abaf90870f3" -[[package]] -name = "object" -version = "0.32.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a6a622008b6e321afc04970976f62ee297fdbaa6f95318ca343e3eebb9648441" -dependencies = [ - "flate2", - "memchr", - "ruzstd", -] - [[package]] name = "object" version = "0.36.1" @@ -3763,7 +3548,7 @@ dependencies = [ "p3-mds", "p3-poseidon2", "p3-symmetric", - "rand 0.8.5", + "rand", "serde", ] @@ -3786,7 +3571,7 @@ dependencies = [ "p3-field", "p3-poseidon2", "p3-symmetric", - "rand 0.8.5", + "rand", "serde", ] @@ -3798,7 +3583,7 @@ dependencies = [ "p3-field", "p3-maybe-rayon", "p3-symmetric", - "p3-util 0.1.0 (git+https://github.com/Plonky3/Plonky3.git?rev=88ea2b866e41329817e4761429b4a5a2a9751c07)", + "p3-util", "tracing", ] @@ -3811,7 +3596,7 @@ dependencies = [ "p3-challenger", "p3-field", "p3-matrix", - "p3-util 0.1.0 (git+https://github.com/Plonky3/Plonky3.git?rev=88ea2b866e41329817e4761429b4a5a2a9751c07)", + "p3-util", "serde", ] @@ -3823,7 +3608,7 @@ dependencies = [ "p3-field", "p3-matrix", "p3-maybe-rayon", - "p3-util 0.1.0 (git+https://github.com/Plonky3/Plonky3.git?rev=88ea2b866e41329817e4761429b4a5a2a9751c07)", + "p3-util", "tracing", ] @@ -3835,8 +3620,8 @@ dependencies = [ "itertools 0.12.1", "num-bigint 0.4.6", "num-traits", - "p3-util 0.1.0 (git+https://github.com/Plonky3/Plonky3.git?rev=88ea2b866e41329817e4761429b4a5a2a9751c07)", - "rand 0.8.5", + "p3-util", + "rand", "serde", ] @@ -3853,7 +3638,7 @@ dependencies = [ "p3-interpolation", "p3-matrix", "p3-maybe-rayon", - "p3-util 0.1.0 (git+https://github.com/Plonky3/Plonky3.git?rev=88ea2b866e41329817e4761429b4a5a2a9751c07)", + "p3-util", "serde", "tracing", ] @@ -3865,7 +3650,7 @@ source = "git+https://github.com/Plonky3/Plonky3.git?rev=88ea2b866e41329817e4761 dependencies = [ "p3-field", "p3-matrix", - "p3-util 0.1.0 (git+https://github.com/Plonky3/Plonky3.git?rev=88ea2b866e41329817e4761429b4a5a2a9751c07)", + "p3-util", ] [[package]] @@ -3886,7 +3671,7 @@ dependencies = [ "p3-field", "p3-matrix", "p3-maybe-rayon", - "p3-util 0.1.0 (git+https://github.com/Plonky3/Plonky3.git?rev=88ea2b866e41329817e4761429b4a5a2a9751c07)", + "p3-util", "tracing", ] @@ -3898,8 +3683,8 @@ dependencies = [ "itertools 0.12.1", "p3-field", "p3-maybe-rayon", - "p3-util 0.1.0 (git+https://github.com/Plonky3/Plonky3.git?rev=88ea2b866e41329817e4761429b4a5a2a9751c07)", - "rand 0.8.5", + "p3-util", + "rand", "serde", "tracing", ] @@ -3922,8 +3707,8 @@ dependencies = [ "p3-field", "p3-matrix", "p3-symmetric", - "p3-util 0.1.0 (git+https://github.com/Plonky3/Plonky3.git?rev=88ea2b866e41329817e4761429b4a5a2a9751c07)", - "rand 0.8.5", + "p3-util", + "rand", ] [[package]] @@ -3937,7 +3722,7 @@ dependencies = [ "p3-matrix", "p3-maybe-rayon", "p3-symmetric", - "p3-util 0.1.0 (git+https://github.com/Plonky3/Plonky3.git?rev=88ea2b866e41329817e4761429b4a5a2a9751c07)", + "p3-util", "serde", "tracing", ] @@ -3951,7 +3736,7 @@ dependencies = [ "p3-field", "p3-mds", "p3-symmetric", - "rand 0.8.5", + "rand", ] [[package]] @@ -3977,19 +3762,11 @@ dependencies = [ "p3-field", "p3-matrix", "p3-maybe-rayon", - "p3-util 0.1.0 (git+https://github.com/Plonky3/Plonky3.git?rev=88ea2b866e41329817e4761429b4a5a2a9751c07)", + "p3-util", "serde", "tracing", ] -[[package]] -name = "p3-util" -version = "0.1.0" -source = "git+https://github.com/Plonky3/Plonky3?rev=3f5fb24#3f5fb24f6561a5e333c23da69b9db64205c9c55c" -dependencies = [ - "serde", -] - [[package]] name = "p3-util" version = "0.1.0" @@ -4063,7 +3840,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7676374caaee8a325c9e7a2ae557f216c5563a171d6997b0ef8a65af35147700" dependencies = [ "base64ct", - "rand_core 0.6.4", + "rand_core", "subtle", ] @@ -4077,7 +3854,7 @@ dependencies = [ "ff 0.12.1", "group 0.12.1", "lazy_static", - "rand 0.8.5", + "rand", "static_assertions", "subtle", ] @@ -4092,7 +3869,7 @@ dependencies = [ "ff 0.13.0", "group 0.13.0", "lazy_static", - "rand 0.8.5", + "rand", "static_assertions", "subtle", ] @@ -4163,7 +3940,7 @@ version = "0.6.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b4c5cc86750666a3ed20bdaf5ca2a0344f9c67674cae0515bec2da16fbaa47db" dependencies = [ - "fixedbitset 0.4.2", + "fixedbitset", "indexmap 2.2.6", ] @@ -4194,7 +3971,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "48e4cc64c2ad9ebe670cb8fd69dd50ae301650392e81c05f9bfcb2d5bdbc24b0" dependencies = [ "phf_shared 0.11.2", - "rand 0.8.5", + "rand", ] [[package]] @@ -4282,17 +4059,6 @@ version = "1.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7170ef9988bc169ba16dd36a7fa041e5c4cbeb6a35b76d4c03daded371eae7c0" -[[package]] -name = "postcard" -version = "1.0.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a55c51ee6c0db07e68448e336cf8ea4131a620edefebf9893e759b2d793420f8" -dependencies = [ - "cobs", - "embedded-io", - "serde", -] - [[package]] name = "powerfmt" version = "0.2.0" @@ -4398,8 +4164,8 @@ dependencies = [ "bitflags 2.6.0", "lazy_static", "num-traits", - "rand 0.8.5", - "rand_chacha 0.3.1", + "rand", + "rand_chacha", "rand_xorshift", "regex-syntax 0.8.4", "rusty-fork", @@ -4460,7 +4226,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ddf517c03a109db8100448a4be38d498df8a210a99fe0e1b9eaf39e78c640efe" dependencies = [ "bytes", - "rand 0.8.5", + "rand", "ring 0.17.8", "rustc-hash", "rustls 0.23.10", @@ -4498,19 +4264,6 @@ version = "0.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "dc33ff2d4973d518d823d61aa239014831e521c75da58e3df4840d3f47749d09" -[[package]] -name = "rand" -version = "0.7.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6a6b1679d49b24bbfe0c803429aa1874472f50d9b363131f0e89fc356b544d03" -dependencies = [ - "getrandom 0.1.16", - "libc", - "rand_chacha 0.2.2", - "rand_core 0.5.1", - "rand_hc", -] - [[package]] name = "rand" version = "0.8.5" @@ -4518,18 +4271,8 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "34af8d1a0e25924bc5b7c43c079c942339d8f0a8b57c39049bef581b46327404" dependencies = [ "libc", - "rand_chacha 0.3.1", - "rand_core 0.6.4", -] - -[[package]] -name = "rand_chacha" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f4c8ed856279c9737206bf725bf36935d8666ead7aa69b52be55af369d193402" -dependencies = [ - "ppv-lite86", - "rand_core 0.5.1", + "rand_chacha", + "rand_core", ] [[package]] @@ -4539,16 +4282,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e6c10a63a0fa32252be49d21e7709d4d4baf8d231c2dbce1eaa8141b9b127d88" dependencies = [ "ppv-lite86", - "rand_core 0.6.4", -] - -[[package]] -name = "rand_core" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90bde5296fc891b0cef12a6d03ddccc162ce7b2aff54160af9338f8d40df6d19" -dependencies = [ - "getrandom 0.1.16", + "rand_core", ] [[package]] @@ -4557,16 +4291,7 @@ version = "0.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c" dependencies = [ - "getrandom 0.2.15", -] - -[[package]] -name = "rand_hc" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca3129af7b92a17112d59ad498c6f81eaf463253766b90396d39ea7a39d6613c" -dependencies = [ - "rand_core 0.5.1", + "getrandom", ] [[package]] @@ -4575,7 +4300,7 @@ version = "0.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d25bf25ec5ae4a3f1b92f929810509a2f53d7dca2f50b794ff57e3face536c8f" dependencies = [ - "rand_core 0.6.4", + "rand_core", ] [[package]] @@ -4622,7 +4347,7 @@ version = "0.4.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "bd283d9651eeda4b2a83a43c1c91b266c40fd76ecd39a50a8c630ae69dc72891" dependencies = [ - "getrandom 0.2.15", + "getrandom", "libredox", "thiserror", ] @@ -4788,15 +4513,6 @@ dependencies = [ "subtle", ] -[[package]] -name = "rgb" -version = "0.8.40" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a7439be6844e40133eda024efd85bf07f59d0dd2f59b10c00dd6cfb92cc5c741" -dependencies = [ - "bytemuck", -] - [[package]] name = "ring" version = "0.16.20" @@ -4820,7 +4536,7 @@ checksum = "c17fa4cb658e3583423e915b9f3acc01cceaee1860e33d59ebae66adc3a2dc0d" dependencies = [ "cc", "cfg-if", - "getrandom 0.2.15", + "getrandom", "libc", "spin 0.9.8", "untrusted 0.9.0", @@ -4882,7 +4598,7 @@ version = "1.1.0-alpha.1" source = "git+https://github.com/risc0/risc0.git#0767e982ddf3cbbf4342b0096d81c659d376f4c4" dependencies = [ "bytemuck", - "rand_core 0.6.4", + "rand_core", ] [[package]] @@ -4917,7 +4633,7 @@ dependencies = [ "hex", "hex-literal", "paste", - "rand_core 0.6.4", + "rand_core", "risc0-core", "risc0-zkvm-platform", "serde", @@ -4936,7 +4652,7 @@ dependencies = [ "bytemuck", "bytes", "cfg-if", - "getrandom 0.2.15", + "getrandom", "hex", "prost", "risc0-binfmt", @@ -4960,7 +4676,7 @@ version = "1.1.0-alpha.1" source = "git+https://github.com/risc0/risc0.git#0767e982ddf3cbbf4342b0096d81c659d376f4c4" dependencies = [ "bytemuck", - "getrandom 0.2.15", + "getrandom", "libm", ] @@ -5043,7 +4759,7 @@ dependencies = [ "parity-scale-codec", "primitive-types", "proptest", - "rand 0.8.5", + "rand", "rlp", "ruint-macro", "serde", @@ -5196,17 +4912,6 @@ dependencies = [ "wait-timeout", ] -[[package]] -name = "ruzstd" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "58c4eb8a81997cf040a091d1f7e1938aeab6749d3a0dfa73af43cdc32393483d" -dependencies = [ - "byteorder", - "derive_more", - "twox-hash", -] - [[package]] name = "ryu" version = "1.0.18" @@ -5383,12 +5088,6 @@ version = "0.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "cd0b0ec5f1c1ca621c432a25813d8d60c88abe6d3e08a3eb9cf37d97a0fe3d73" -[[package]] -name = "seq-macro" -version = "0.3.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a3f0bf26fd526d2a95683cd0f87bf103b8539e2ca1ef48ce002d67aad59aa0b4" - [[package]] name = "serde" version = "1.0.203" @@ -5585,7 +5284,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "77549399552de45a898a580c1b41d445bf730df867cc44e6c0233bbc4b8329de" dependencies = [ "digest 0.10.7", - "rand_core 0.6.4", + "rand_core", ] [[package]] @@ -5700,8 +5399,8 @@ dependencies = [ "p3-poseidon2", "p3-symmetric", "p3-uni-stark", - "p3-util 0.1.0 (git+https://github.com/Plonky3/Plonky3.git?rev=88ea2b866e41329817e4761429b4a5a2a9751c07)", - "rand 0.8.5", + "p3-util", + "rand", "rayon-scan", "rrs-lib 0.1.0 (git+https://github.com/GregAC/rrs.git)", "serde", @@ -5710,8 +5409,8 @@ dependencies = [ "snowbridge-amcl", "sp1-derive", "sp1-primitives", - "strum 0.26.3", - "strum_macros 0.26.4", + "strum", + "strum_macros", "tempfile", "thiserror", "tracing", @@ -5765,8 +5464,8 @@ dependencies = [ "p3-challenger", "p3-commit", "p3-field", - "p3-util 0.1.0 (git+https://github.com/Plonky3/Plonky3.git?rev=88ea2b866e41329817e4761429b4a5a2a9751c07)", - "rand 0.8.5", + "p3-util", + "rand", "rayon", "reqwest 0.12.5", "serde", @@ -5803,7 +5502,7 @@ dependencies = [ "p3-field", "p3-fri", "p3-matrix", - "p3-util 0.1.0 (git+https://github.com/Plonky3/Plonky3.git?rev=88ea2b866e41329817e4761429b4a5a2a9751c07)", + "p3-util", "serde", "sp1-core", "sp1-recursion-compiler", @@ -5828,7 +5527,7 @@ dependencies = [ "p3-matrix", "p3-poseidon2", "p3-symmetric", - "p3-util 0.1.0 (git+https://github.com/Plonky3/Plonky3.git?rev=88ea2b866e41329817e4761429b4a5a2a9751c07)", + "p3-util", "serde", "sp1-core", "sp1-recursion-core", @@ -5859,7 +5558,7 @@ dependencies = [ "p3-merkle-tree", "p3-poseidon2", "p3-symmetric", - "p3-util 0.1.0 (git+https://github.com/Plonky3/Plonky3.git?rev=88ea2b866e41329817e4761429b4a5a2a9751c07)", + "p3-util", "serde", "serde_with", "sp1-core", @@ -5896,7 +5595,7 @@ dependencies = [ "p3-baby-bear", "p3-field", "p3-symmetric", - "rand 0.8.5", + "rand", "serde", "serde_json", "sha2", @@ -5923,8 +5622,8 @@ dependencies = [ "p3-merkle-tree", "p3-poseidon2", "p3-symmetric", - "p3-util 0.1.0 (git+https://github.com/Plonky3/Plonky3.git?rev=88ea2b866e41329817e4761429b4a5a2a9751c07)", - "rand 0.8.5", + "p3-util", + "rand", "serde", "sp1-core", "sp1-recursion-compiler", @@ -5961,8 +5660,8 @@ dependencies = [ "sha2", "sp1-core", "sp1-prover", - "strum 0.26.3", - "strum_macros 0.26.4", + "strum", + "strum_macros", "tempfile", "thiserror", "tokio", @@ -5999,12 +5698,6 @@ version = "1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a2eb9349b6444b326872e140eb1cf5e7c522154d69e7a0ffb0fb81c06b37543f" -[[package]] -name = "strength_reduce" -version = "0.2.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fe895eb47f22e2ddd4dabc02bce419d2e643c8e3b585c78158b349195bc24d82" - [[package]] name = "string_cache" version = "0.8.7" @@ -6024,32 +5717,13 @@ version = "0.11.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7da8b5736845d9f2fcb837ea5d9e2628564b3b043a70948a3f0b778838c5fb4f" -[[package]] -name = "strum" -version = "0.25.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "290d54ea6f91c969195bdbcd7442c8c2a2ba87da8bf60a7ee86a235d4bc1e125" - [[package]] name = "strum" version = "0.26.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8fec0f0aef304996cf250b31b5a10dee7980c85da9d759361292b8bca5a18f06" dependencies = [ - "strum_macros 0.26.4", -] - -[[package]] -name = "strum_macros" -version = "0.25.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23dc1fa9ac9c169a78ba62f0b841814b7abae11bdd047b9c58f893439e309ea0" -dependencies = [ - "heck 0.4.1", - "proc-macro2", - "quote", - "rustversion", - "syn 2.0.68", + "strum_macros", ] [[package]] @@ -6173,12 +5847,6 @@ version = "1.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "55937e1799185b12863d447f42597ed69d9928686b8d88a1df17376a097d8369" -[[package]] -name = "target-lexicon" -version = "0.12.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e1fc403891a21bcfb7c37834ba66a547a8f402146eba7265b5a6d88059c9ff2f" - [[package]] name = "tempfile" version = "3.10.1" @@ -6202,26 +5870,6 @@ dependencies = [ "winapi", ] -[[package]] -name = "term_size" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1e4129646ca0ed8f45d09b929036bafad5377103edd06e50bf574b353d2b08d9" -dependencies = [ - "libc", - "winapi", -] - -[[package]] -name = "textplots" -version = "0.8.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f59b64803118dbff62f92842b3154a2c802dfd8e18660132bbcbfb141c637ae3" -dependencies = [ - "drawille", - "rgb", -] - [[package]] name = "thiserror" version = "1.0.61" @@ -6496,17 +6144,6 @@ version = "0.3.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b6bc1c9ce2b5135ac7f93c72918fc37feb872bdc6a5533a8b85eb4b86bfdae52" -[[package]] -name = "tracer" -version = "0.2.0" -source = "git+https://github.com/a16z/jolt#5d1b57cb1dac6b675e90e5a1db1271c44366a6b4" -dependencies = [ - "common", - "fnv", - "object 0.32.2", - "tracing", -] - [[package]] name = "tracing" version = "0.1.40" @@ -6530,17 +6167,6 @@ dependencies = [ "syn 2.0.68", ] -[[package]] -name = "tracing-chrome" -version = "0.7.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bf0a738ed5d6450a9fb96e86a23ad808de2b727fd1394585da5cdd6788ffe724" -dependencies = [ - "serde_json", - "tracing-core", - "tracing-subscriber 0.3.18", -] - [[package]] name = "tracing-core" version = "0.1.32" @@ -6551,17 +6177,6 @@ dependencies = [ "valuable", ] -[[package]] -name = "tracing-flame" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0bae117ee14789185e129aaee5d93750abe67fdc5a9a62650452bfe4e122a3a9" -dependencies = [ - "lazy_static", - "tracing", - "tracing-subscriber 0.3.18", -] - [[package]] name = "tracing-forest" version = "0.1.6" @@ -6596,16 +6211,6 @@ dependencies = [ "tracing-core", ] -[[package]] -name = "tracing-profile" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8cedeb2155cbf8f535de375829ed567735a35ed194342c57e7b54c6e6ef61eb1" -dependencies = [ - "tracing", - "tracing-subscriber 0.3.18", -] - [[package]] name = "tracing-subscriber" version = "0.2.25" @@ -6633,29 +6238,6 @@ dependencies = [ "tracing-log", ] -[[package]] -name = "tracing-texray" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "07b7943a21ef76920e7250b59946b0068221c323bf1077baab36164477d63efc" -dependencies = [ - "lazy_static", - "parking_lot", - "term_size", - "tracing", - "tracing-subscriber 0.3.18", -] - -[[package]] -name = "transpose" -version = "0.2.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1ad61aed86bc3faea4300c7aee358b4c6d0c8d6ccc36524c96e4c92ccf26e77e" -dependencies = [ - "num-integer", - "strength_reduce", -] - [[package]] name = "try-lock" version = "0.2.5" @@ -6674,7 +6256,7 @@ dependencies = [ "http 0.2.12", "httparse", "log", - "rand 0.8.5", + "rand", "rustls 0.21.12", "sha1", "thiserror", @@ -6695,7 +6277,7 @@ dependencies = [ "httparse", "log", "native-tls", - "rand 0.8.5", + "rand", "sha1", "thiserror", "utf-8", @@ -6723,16 +6305,6 @@ dependencies = [ "url", ] -[[package]] -name = "twox-hash" -version = "1.6.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "97fee6b57c6a41524a810daee9286c02d7752c4253064d0b05472833a438f675" -dependencies = [ - "cfg-if", - "static_assertions", -] - [[package]] name = "typenum" version = "1.17.0" @@ -6837,7 +6409,7 @@ version = "0.8.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "bc5cf98d8186244414c848017f0e2676b3fcb46807f6668a97dfe67359a3c4b7" dependencies = [ - "getrandom 0.2.15", + "getrandom", "serde", ] @@ -6900,12 +6472,6 @@ dependencies = [ "try-lock", ] -[[package]] -name = "wasi" -version = "0.9.0+wasi-snapshot-preview1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cccddf32554fecc6acb585f82a32a72e28b48f8c4c1883ddfeeeaa96f7d8e519" - [[package]] name = "wasi" version = "0.11.0+wasi-snapshot-preview1" @@ -7360,7 +6926,6 @@ dependencies = [ "dialoguer", "ethers 2.0.14 (git+https://github.com/yetanotherco/ethers-rs.git?tag=v2.0.15-fix-reconnections)", "hex", - "jolt-sdk", "regex", "risc0-zkvm", "rpassword", @@ -7387,7 +6952,7 @@ dependencies = [ "jubjub", "lazy_static", "pasta_curves 0.5.1", - "rand 0.8.5", + "rand", "serde", "sha2", "sha3", diff --git a/src/main.rs b/src/main.rs index 47edab7..3c56580 100644 --- a/src/main.rs +++ b/src/main.rs @@ -22,6 +22,7 @@ enum Commands { /// Adds files to myapp ProveSp1(ProofArgs), ProveRisc0(ProofArgs), + ProveJolt(ProofArgs) } #[derive(Args, Debug)] @@ -60,6 +61,18 @@ fn add_text_after_substring(original_string: &str, substring: &str, text_to_add: } } +fn add_before_substring(original_string: &str, substring: &str, text_to_add: &str) -> String { + if let Some(index) = original_string.find(substring) { + let mut modified_string = String::with_capacity(original_string.len() + text_to_add.len()); + modified_string.push_str(&original_string[..index]); + modified_string.push_str(text_to_add); + modified_string.push_str(&original_string[index..]); + modified_string + } else { + original_string.to_string() + } +} + fn prepend_to_file(file_path: &str, text_to_prepend: &str) -> io::Result<()> { // Open the file in read mode to read its existing content let mut file = OpenOptions::new().read(true).write(true).open(file_path)?; @@ -153,6 +166,26 @@ const SP1_PROOF_PATH: &str = "./sp1.proof"; const SP1_PROGRAM_HEADER: &str = "#![no_main]\nsp1_zkvm::entrypoint!(main);\n"; +// Jolt File Paths and Additions +const JOLT_PROOF_PATH: &str = "./jolt.proof"; + +const JOLT_ELF_PATH: &str = "./jolt.elf"; + +const JOLT_DIR: &str = "./.jolt/"; + +const JOLT_GUEST_DIR: &str = "./.jolt/guest/src"; + +const JOLT_GUEST_MAIN: &str = "./.jolt/guest/src/lib.rs"; + +const JOLT_GUEST_CARGO_TOML: &str = "./.jolt/guest/Cargo.toml"; + +const JOLT_GUEST_PROGRAM_HEADER_STD: &str = "#![no_main]\n"; + +const JOLT_GUEST_PROC_MACRO: &str = "\n#[jolt::provable]\n"; + +const JOLT_GUEST_DEPS: &str = + "\njolt = { package = \"jolt-sdk\", git = \"https://github.com/a16z/jolt\", features = [\"guest-std\"] }"; + // Risc0 File Paths and Additions const RISC0_PROOF_PATH: &str = "./risc_zero.proof"; @@ -214,6 +247,68 @@ fn main() { keystore_path, SP1_PROOF_PATH, SP1_ELF_PATH, + //TODO: Change when Jolt PR is upstreamed + ProvingSystemId::SP1, + ) + .unwrap(); + println!("Proof submitted and verified on aligned"); + } + } + Commands::ProveJolt(args) => { + println!("'Proving with Jolt program in: {}", args.guest_path); + // Clear contents of src directory + fs::remove_dir_all(JOLT_GUEST_DIR).unwrap(); + fs::create_dir(JOLT_GUEST_DIR).unwrap(); + + // Copy the source main to the destination directory + let guest_path = format!("{}/src/", args.guest_path); + copy_dir_all(guest_path, JOLT_GUEST_DIR).unwrap(); + fs::rename("./.jolt/guest/src/main.rs", JOLT_GUEST_MAIN).unwrap(); + + // Copy dependencies to from guest toml to risc0 project template + let toml_path = format!("{}/Cargo.toml", args.guest_path); + copy_dependencies(&toml_path, JOLT_GUEST_CARGO_TOML); + + /* + #![no_main] + */ + prepend_to_file(JOLT_GUEST_MAIN, JOLT_GUEST_PROGRAM_HEADER_STD).unwrap(); + + // Find and replace function name + let content = fs::read_to_string(JOLT_GUEST_MAIN).unwrap(); + + let modified_content = content.replace("main()", "method()"); + + /* + #[jolt::provable] + */ + let modified_content = + add_before_substring(&modified_content, "fn method()", JOLT_GUEST_PROC_MACRO); + + let mut file = fs::File::create(JOLT_GUEST_MAIN).unwrap(); + file.write_all(modified_content.as_bytes()).unwrap(); + + let guest_path = fs::canonicalize(JOLT_DIR).unwrap(); + //TODO: propogate errors from this command to stdout/stderr + Command::new("cargo") + .arg("run") + .arg("--release") + .current_dir(guest_path) + .status() + .expect("Prove build failed"); + println!("Proof and Proof Image generated!"); + + // Clear toml of dependencies + remove_dependencies(JOLT_GUEST_CARGO_TOML, JOLT_GUEST_DEPS); + println!("Proof Generated"); + + // Submit to aligned + if let Some(keystore_path) = args.submit_to_aligned_with_keystore.clone() { + submit_proof_to_aligned( + keystore_path, + JOLT_PROOF_PATH, + JOLT_ELF_PATH, + //TODO: Change when Jolt PR is upstreamed ProvingSystemId::SP1, ) .unwrap(); @@ -252,7 +347,6 @@ fn main() { // Clear toml of dependencies remove_dependencies(RISC0_GUEST_CARGO_TOML, RISC0_GUEST_DEPS); - // Submit to aligned if let Some(keystore_path) = args.submit_to_aligned_with_keystore.clone() { submit_proof_to_aligned(