diff --git a/Cargo.lock b/Cargo.lock index afe4c047..1c15322f 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -57,9 +57,9 @@ checksum = "683d7910e743518b0e34f1186f92494becacb047c7b6bf616c96772180fef923" [[package]] name = "alloy" -version = "1.0.24" +version = "1.0.32" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "48dff4dd98e17de00203f851800bbc8b76eb29a4d4e3e44074614338b7a3308d" +checksum = "36f63701831729cb154cf0b6945256af46c426074646c98b9d123148ba1d8bde" dependencies = [ "alloy-consensus", "alloy-core", @@ -74,9 +74,9 @@ dependencies = [ [[package]] name = "alloy-chains" -version = "0.2.6" +version = "0.2.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4195a29a4b87137b2bb02105e746102873bc03561805cf45c0e510c961f160e6" +checksum = "ef8ff73a143281cb77c32006b04af9c047a6b8fe5860e85a88ad325328965355" dependencies = [ "alloy-primitives", "alloy-rlp", @@ -87,9 +87,9 @@ dependencies = [ [[package]] name = "alloy-consensus" -version = "1.0.24" +version = "1.0.32" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eda689f7287f15bd3582daba6be8d1545bad3740fd1fb778f629a1fe866bb43b" +checksum = "64a3bd0305a44fb457cae77de1e82856eadd42ea3cdf0dae29df32eb3b592979" dependencies = [ "alloy-eips", "alloy-primitives", @@ -112,9 +112,9 @@ dependencies = [ [[package]] name = "alloy-consensus-any" -version = "1.0.24" +version = "1.0.32" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2b5659581e41e8fe350ecc3593cb5c9dcffddfd550896390f2b78a07af67b0fa" +checksum = "7a842b4023f571835e62ac39fb8d523d19fcdbacfa70bf796ff96e7e19586f50" dependencies = [ "alloy-consensus", "alloy-eips", @@ -126,9 +126,9 @@ dependencies = [ [[package]] name = "alloy-core" -version = "1.3.0" +version = "1.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d47400608fc869727ad81dba058d55f97b29ad8b5c5256d9598523df8f356ab6" +checksum = "bfe6c56d58fbfa9f0f6299376e8ce33091fc6494239466814c3f54b55743cb09" dependencies = [ "alloy-primitives", ] @@ -173,9 +173,9 @@ dependencies = [ [[package]] name = "alloy-eips" -version = "1.0.24" +version = "1.0.32" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6f35887da30b5fc50267109a3c61cd63e6ca1f45967983641053a40ee83468c1" +checksum = "5cd749c57f38f8cbf433e651179fc5a676255e6b95044f467d49255d2b81725a" dependencies = [ "alloy-eip2124", "alloy-eip2930", @@ -188,14 +188,16 @@ dependencies = [ "derive_more", "either", "serde", + "serde_with", "sha2 0.10.9", + "thiserror", ] [[package]] name = "alloy-evm" -version = "0.17.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2211ccd0f05e2fea4f767242957f5e8cfb08b127ea2e6a3c0d9e5b10e6bf67d9" +checksum = "0dbe7c66c859b658d879b22e8aaa19546dab726b0639f4649a424ada3d99349e" dependencies = [ "alloy-consensus", "alloy-eips", @@ -213,9 +215,9 @@ dependencies = [ [[package]] name = "alloy-genesis" -version = "1.0.24" +version = "1.0.32" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "11d4009efea6f403b3a80531f9c6f70fc242399498ff71196a1688cc1c901f44" +checksum = "7d32cbf6c26d7d87e8a4e5925bbce41456e0bbeed95601add3443af277cd604e" dependencies = [ "alloy-eips", "alloy-primitives", @@ -227,9 +229,9 @@ dependencies = [ [[package]] name = "alloy-hardforks" -version = "0.2.13" +version = "0.3.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3165210652f71dfc094b051602bafd691f506c54050a174b1cba18fb5ef706a3" +checksum = "8d66cfdf265bf52c0c4a952960c854c3683c71ff2fc02c9b8c317c691fd3bc28" dependencies = [ "alloy-chains", "alloy-eip2124", @@ -241,9 +243,9 @@ dependencies = [ [[package]] name = "alloy-json-abi" -version = "1.3.0" +version = "1.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "459f98c6843f208856f338bfb25e65325467f7aff35dfeb0484d0a76e059134b" +checksum = "125a1c373261b252e53e04d6e92c37d881833afc1315fceab53fd46045695640" dependencies = [ "alloy-primitives", "alloy-sol-type-parser", @@ -253,9 +255,9 @@ dependencies = [ [[package]] name = "alloy-json-rpc" -version = "1.0.24" +version = "1.0.32" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "883dee3b4020fcb5667ee627b4f401e899dad82bf37b246620339dd980720ed9" +checksum = "f614019a029c8fec14ae661aa7d4302e6e66bdbfb869dab40e78dcfba935fc97" dependencies = [ "alloy-primitives", "alloy-sol-types", @@ -268,9 +270,9 @@ dependencies = [ [[package]] name = "alloy-network" -version = "1.0.24" +version = "1.0.32" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cd6e5b8ac1654a05c224390008e43634a2bdc74e181e02cf8ed591d8b3d4ad08" +checksum = "be8b6d58e98803017bbfea01dde96c4d270a29e7aed3beb65c8d28b5ab464e0e" dependencies = [ "alloy-consensus", "alloy-consensus-any", @@ -294,9 +296,9 @@ dependencies = [ [[package]] name = "alloy-network-primitives" -version = "1.0.24" +version = "1.0.32" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "80d7980333dd9391719756ac28bc2afa9baa705fc70ffd11dc86ab078dd64477" +checksum = "db489617bffe14847bf89f175b1c183e5dd7563ef84713936e2c34255cfbd845" dependencies = [ "alloy-consensus", "alloy-eips", @@ -307,17 +309,17 @@ dependencies = [ [[package]] name = "alloy-primitives" -version = "1.3.0" -source = "git+https://github.com/scroll-tech/alloy-core?branch=feat/rkyv#65e074f03f4491168e4ec7853d2b1cebb8a35be2" +version = "1.3.1" +source = "git+https://github.com/scroll-tech/alloy-core?branch=feat/rkyv#0ae81396e9455a5d1aad24e5713c91b3d13c4a25" dependencies = [ "alloy-rlp", "bytes", "cfg-if", "const-hex", "derive_more", - "foldhash", - "hashbrown 0.15.5", - "indexmap 2.10.0", + "foldhash 0.2.0", + "hashbrown 0.16.0", + "indexmap 2.11.3", "itoa", "k256 0.13.4 (registry+https://github.com/rust-lang/crates.io-index)", "keccak-asm", @@ -334,9 +336,9 @@ dependencies = [ [[package]] name = "alloy-provider" -version = "1.0.24" +version = "1.0.32" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "478a42fe167057b7b919cd8b0c2844f0247f667473340dad100eaf969de5754e" +checksum = "ed90278374435e076a04dbddbb6d714bdd518eb274a64dbd70f65701429dd747" dependencies = [ "alloy-chains", "alloy-consensus", @@ -395,9 +397,9 @@ dependencies = [ [[package]] name = "alloy-rpc-client" -version = "1.0.24" +version = "1.0.32" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8a0c6d723fbdf4a87454e2e3a275e161be27edcfbf46e2e3255dd66c138634b6" +checksum = "33732242ca63f107f5f8284190244038905fb233280f4b7c41f641d4f584d40d" dependencies = [ "alloy-json-rpc", "alloy-primitives", @@ -418,9 +420,9 @@ dependencies = [ [[package]] name = "alloy-rpc-types-any" -version = "1.0.24" +version = "1.0.32" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f7eb22670a972ad6c222a6c6dac3eef905579acffe9d63ab42be24c7d158535" +checksum = "18f27c0c41a16cd0af4f5dbf791f7be2a60502ca8b0e840e0ad29803fac2d587" dependencies = [ "alloy-consensus-any", "alloy-rpc-types-eth", @@ -429,20 +431,21 @@ dependencies = [ [[package]] name = "alloy-rpc-types-debug" -version = "1.0.24" +version = "1.0.32" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a9b6f0482c82310366ec3dcf4e5212242f256a69fcf1a26e5017e6704091ee95" +checksum = "d46cb226f1c8071875f4d0d8a0eb3ac571fcc49cd3bcdc20a5818de7b6ef0634" dependencies = [ "alloy-primitives", "derive_more", "serde", + "serde_with", ] [[package]] name = "alloy-rpc-types-engine" -version = "1.0.24" +version = "1.0.32" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e24c171377c0684e3860385f6d93fbfcc8ecc74f6cce8304c822bf1a50bacce0" +checksum = "dec35a39206f0e04e8544d763c9fe324cc01f74de8821ef4b61e25ac329682f9" dependencies = [ "alloy-consensus", "alloy-eips", @@ -454,9 +457,9 @@ dependencies = [ [[package]] name = "alloy-rpc-types-eth" -version = "1.0.24" +version = "1.0.32" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b777b98526bbe5b7892ca22a7fd5f18ed624ff664a79f40d0f9f2bf94ba79a84" +checksum = "7f5812f81c3131abc2cd8953dc03c41999e180cff7252abbccaba68676e15027" dependencies = [ "alloy-consensus", "alloy-consensus-any", @@ -475,9 +478,9 @@ dependencies = [ [[package]] name = "alloy-serde" -version = "1.0.24" +version = "1.0.32" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ee8d2c52adebf3e6494976c8542fbdf12f10123b26e11ad56f77274c16a2a039" +checksum = "04dfe41a47805a34b848c83448946ca96f3d36842e8c074bcf8fa0870e337d12" dependencies = [ "alloy-primitives", "serde", @@ -486,9 +489,9 @@ dependencies = [ [[package]] name = "alloy-signer" -version = "1.0.24" +version = "1.0.32" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7c0494d1e0f802716480aabbe25549c7f6bc2a25ff33b08fd332bbb4b7d06894" +checksum = "f79237b4c1b0934d5869deea4a54e6f0a7425a8cd943a739d6293afdf893d847" dependencies = [ "alloy-primitives", "async-trait", @@ -522,7 +525,7 @@ dependencies = [ "alloy-sol-macro-input", "const-hex", "heck", - "indexmap 2.10.0", + "indexmap 2.11.3", "proc-macro-error2", "proc-macro2", "quote", @@ -559,9 +562,9 @@ dependencies = [ [[package]] name = "alloy-sol-types" -version = "1.3.0" +version = "1.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a285b46e3e0c177887028278f04cc8262b76fd3b8e0e20e93cea0a58c35f5ac5" +checksum = "f5383d34ea00079e6dd89c652bcbdb764db160cef84e6250926961a0b2295d04" dependencies = [ "alloy-json-abi", "alloy-primitives", @@ -571,9 +574,9 @@ dependencies = [ [[package]] name = "alloy-transport" -version = "1.0.24" +version = "1.0.32" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3c0107675e10c7f248bf7273c1e7fdb02409a717269cc744012e6f3c39959bfb" +checksum = "cb43750e137fe3a69a325cd89a8f8e2bbf4f83e70c0f60fbe49f22511ca075e8" dependencies = [ "alloy-json-rpc", "alloy-primitives", @@ -596,9 +599,9 @@ dependencies = [ [[package]] name = "alloy-transport-http" -version = "1.0.24" +version = "1.0.32" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "78e3736701b5433afd06eecff08f0688a71a10e0e1352e0bbf0bed72f0dd4e35" +checksum = "f9b42c7d8b666eed975739201f407afc3320d3cd2e4d807639c2918fc736ea67" dependencies = [ "alloy-json-rpc", "alloy-transport", @@ -611,9 +614,9 @@ dependencies = [ [[package]] name = "alloy-trie" -version = "0.9.0" +version = "0.9.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bada1fc392a33665de0dc50d401a3701b62583c655e3522a323490a5da016962" +checksum = "e3412d52bb97c6c6cc27ccc28d4e6e8cf605469101193b50b0bd5813b1f990b5" dependencies = [ "alloy-primitives", "alloy-rlp", @@ -627,23 +630,17 @@ dependencies = [ [[package]] name = "alloy-tx-macros" -version = "1.0.24" +version = "1.0.32" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6acb36318dfa50817154064fea7932adf2eec3f51c86680e2b37d7e8906c66bb" +checksum = "e434e0917dce890f755ea774f59d6f12557bc8c7dd9fa06456af80cfe0f0181e" dependencies = [ "alloy-primitives", - "darling", + "darling 0.21.3", "proc-macro2", "quote", "syn 2.0.106", ] -[[package]] -name = "android-tzdata" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e999941b234f3131b00bc13c22d06e8c5ff726d1b6318ac7eb276997bbb4fef0" - [[package]] name = "android_system_properties" version = "0.1.5" @@ -1155,9 +1152,9 @@ dependencies = [ [[package]] name = "bitflags" -version = "2.9.2" +version = "2.9.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6a65b545ab31d687cff52899d4890855fec459eb6afe0da6417b8a18da87aa29" +checksum = "2261d10cca569e4643e526d8dc2e62e433cc8aba21ab764233731f8d369bf394" dependencies = [ "serde", ] @@ -1315,10 +1312,11 @@ dependencies = [ [[package]] name = "cc" -version = "1.2.33" +version = "1.2.37" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3ee0f8803222ba5a7e2777dd72ca451868909b1ac410621b676adf07280e9b5f" +checksum = "65193589c6404eb80b450d618eaf9a2cafaaafd57ecce47370519ef674a7bd44" dependencies = [ + "find-msvc-tools", "jobserver", "libc", "shlex", @@ -1326,9 +1324,9 @@ dependencies = [ [[package]] name = "cfg-if" -version = "1.0.1" +version = "1.0.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9555578bc9e57714c812a1f84e4fc5b4d21fcb063490c624de019f7464c91268" +checksum = "2fd1289c04a9ea8cb22300a459a72a385d7c73d3259e2ed7dcb2af674838cfa9" [[package]] name = "cfg_aliases" @@ -1338,22 +1336,21 @@ checksum = "613afe47fcd5fac7ccf1db93babcb082c5994d996f20b8b159f2ad1658eb5724" [[package]] name = "chrono" -version = "0.4.41" +version = "0.4.42" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c469d952047f47f91b68d1cba3f10d63c11d73e4636f24f08daf0278abf01c4d" +checksum = "145052bdd345b87320e369255277e3fb5152762ad123a901ef5c262dd38fe8d2" dependencies = [ - "android-tzdata", "iana-time-zone", "num-traits", "serde", - "windows-link", + "windows-link 0.2.0", ] [[package]] name = "clap" -version = "4.5.45" +version = "4.5.47" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1fc0e74a703892159f5ae7d3aac52c8e6c392f5ae5f359c70b5881d60aaac318" +checksum = "7eac00902d9d136acd712710d71823fb8ac8004ca445a89e73a41d45aa712931" dependencies = [ "clap_builder", "clap_derive", @@ -1361,9 +1358,9 @@ dependencies = [ [[package]] name = "clap_builder" -version = "4.5.44" +version = "4.5.47" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b3e7f4214277f3c7aa526a59dd3fbe306a370daee1f8b7b8c987069cd8e888a8" +checksum = "2ad9bbf750e73b5884fb8a211a9424a1906c1e156724260fdae972f31d70e1d6" dependencies = [ "anstream", "anstyle", @@ -1373,9 +1370,9 @@ dependencies = [ [[package]] name = "clap_derive" -version = "4.5.45" +version = "4.5.47" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "14cb31bb0a7d536caef2639baa7fad459e15c3144efefa6dbd1c84562c4739f6" +checksum = "bbfd7eae0b0f1a6e63d4b13c9c478de77c2eb546fba158ad50b4203dc24b9f9c" dependencies = [ "heck", "proc-macro2", @@ -1397,28 +1394,27 @@ checksum = "b05b61dc5112cbb17e4b6cd61790d9845d13888356391624cbe7e41efeac1e75" [[package]] name = "console" -version = "0.16.0" +version = "0.16.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2e09ced7ebbccb63b4c65413d821f2e00ce54c5ca4514ddc6b3c892fdbcbc69d" +checksum = "b430743a6eb14e9764d4260d4c0d8123087d504eeb9c48f2b2a5e810dd369df4" dependencies = [ "encode_unicode", "libc", "once_cell", "unicode-width", - "windows-sys 0.60.2", + "windows-sys 0.61.0", ] [[package]] name = "const-hex" -version = "1.15.0" +version = "1.16.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dccd746bf9b1038c0507b7cec21eb2b11222db96a2902c96e8c185d6d20fb9c4" +checksum = "b6407bff74dea37e0fa3dc1c1c974e5d46405f0c987bf9997a0762adce71eda6" dependencies = [ "cfg-if", "cpufeatures", - "hex", "proptest", - "serde", + "serde_core", ] [[package]] @@ -1462,16 +1458,6 @@ dependencies = [ "unicode-segmentation", ] -[[package]] -name = "core-foundation" -version = "0.9.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "91e195e091a93c46f7102ec7818a2aa394e1e1771c3ab4825963fa03e45afb8f" -dependencies = [ - "core-foundation-sys", - "libc", -] - [[package]] name = "core-foundation-sys" version = "0.8.7" @@ -1604,8 +1590,18 @@ version = "0.20.11" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fc7f46116c46ff9ab3eb1597a45688b6715c6e628b5c133e288e709a29bcb4ee" dependencies = [ - "darling_core", - "darling_macro", + "darling_core 0.20.11", + "darling_macro 0.20.11", +] + +[[package]] +name = "darling" +version = "0.21.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9cdf337090841a411e2a7f3deb9187445851f91b309c0c0a29e05f74a00a48c0" +dependencies = [ + "darling_core 0.21.3", + "darling_macro 0.21.3", ] [[package]] @@ -1622,13 +1618,39 @@ dependencies = [ "syn 2.0.106", ] +[[package]] +name = "darling_core" +version = "0.21.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1247195ecd7e3c85f83c8d2a366e4210d588e802133e1e355180a9870b517ea4" +dependencies = [ + "fnv", + "ident_case", + "proc-macro2", + "quote", + "serde", + "strsim", + "syn 2.0.106", +] + [[package]] name = "darling_macro" version = "0.20.11" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fc34b93ccb385b40dc71c6fceac4b2ad23662c7eeb248cf10d529b7e055b6ead" dependencies = [ - "darling_core", + "darling_core 0.20.11", + "quote", + "syn 2.0.106", +] + +[[package]] +name = "darling_macro" +version = "0.21.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d38308df82d1080de0afee5d069fa14b0326a88c14f15c5ccda35b4a6c414c81" +dependencies = [ + "darling_core 0.21.3", "quote", "syn 2.0.106", ] @@ -1659,9 +1681,9 @@ dependencies = [ [[package]] name = "deranged" -version = "0.4.0" +version = "0.5.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c9e6a11ca8224451684bc0d7d5a7adbf8f2fd6887261a1cfc3c0432f9d4068e" +checksum = "d630bccd429a5bb5a64b5e94f693bfc48c9f8566418fda4c494cc94f911f87cc" dependencies = [ "powerfmt", "serde", @@ -1879,12 +1901,12 @@ checksum = "877a4ace8713b0bcf2a4e7eec82529c029f1d0619886d18145fea96c3ffe5c0f" [[package]] name = "errno" -version = "0.3.13" +version = "0.3.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "778e2ac28f6c47af28e4907f13ffd1e1ddbd400980a9abd7c8df189bf578a5ad" +checksum = "39cab71617ae0d63f51a36d69f866391735b51691dbda63cf6f96d042b63efeb" dependencies = [ "libc", - "windows-sys 0.60.2", + "windows-sys 0.61.0", ] [[package]] @@ -1953,6 +1975,12 @@ dependencies = [ "syn 1.0.109", ] +[[package]] +name = "find-msvc-tools" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7fd99930f64d146689264c637b5af2f0233a933bef0d8570e2526bf9e083192d" + [[package]] name = "fixed-hash" version = "0.8.0" @@ -1978,25 +2006,16 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d9c4f5dac5e15c24eb999c26181a6ca40b39fe946cbe4c263c7209467bc83af2" [[package]] -name = "foreign-types" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6f339eb8adc052cd2ca78910fda869aefa38d22d5cb648e6485e4d3fc06f3b1" -dependencies = [ - "foreign-types-shared", -] - -[[package]] -name = "foreign-types-shared" -version = "0.1.1" +name = "foldhash" +version = "0.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "00b0228411908ca8685dba7fc2cdd70ec9990a6e753e89b6ac91a84c40fbaf4b" +checksum = "77ce24cb58228fbb8aa041425bb1050850ac19177686ea6e0f41a70416f56fdb" [[package]] name = "form_urlencoded" -version = "1.2.1" +version = "1.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e13624c2627564efccf4934284bdd98cbaa14e79b0b5a141218e507b3a823456" +checksum = "cb4cb245038516f5f85277875cdaa4f7d2c9a0fa0468de06ed190163b1581fcf" dependencies = [ "percent-encoding", ] @@ -2148,7 +2167,7 @@ dependencies = [ "js-sys", "libc", "r-efi", - "wasi 0.14.2+wasi-0.2.4", + "wasi 0.14.7+wasi-0.2.4", "wasm-bindgen", ] @@ -2166,12 +2185,12 @@ checksum = "0cc23270f6e1808e30a928bdc84dea0b9b4136a8bc82338574f23baf47bbd280" [[package]] name = "gmp-mpfr-sys" -version = "1.6.5" +version = "1.6.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c66d61197a68f6323b9afa616cf83d55d69191e1bf364d4eb7d35ae18defe776" +checksum = "60f8970a75c006bb2f8ae79c6768a116dd215fa8346a87aed99bf9d82ca43394" dependencies = [ "libc", - "windows-sys 0.59.0", + "windows-sys 0.60.2", ] [[package]] @@ -2254,8 +2273,16 @@ checksum = "9229cfe53dfd69f0609a49f65461bd93001ea1ef889cd5529dd176593f5338a1" dependencies = [ "allocator-api2", "equivalent", - "foldhash", - "rayon", + "foldhash 0.1.5", +] + +[[package]] +name = "hashbrown" +version = "0.16.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5419bdc4f6a9207fbeba6d11b604d481addf78ecd10c11ad51e76c2f6482748d" +dependencies = [ + "foldhash 0.2.0", "serde", ] @@ -2388,27 +2415,11 @@ dependencies = [ "webpki-roots", ] -[[package]] -name = "hyper-tls" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "70206fc6890eaca9fde8a0bf71caa2ddfc9fe045ac9e5c70df101a7dbde866e0" -dependencies = [ - "bytes", - "http-body-util", - "hyper", - "hyper-util", - "native-tls", - "tokio", - "tokio-native-tls", - "tower-service", -] - [[package]] name = "hyper-util" -version = "0.1.16" +version = "0.1.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8d9b05277c7e8da2c93a568989bb6207bef0112e8d17df7a6eda4a3cf143bc5e" +checksum = "3c6995591a8f1380fcb4ba966a252a4b29188d51d2b89e3a252f5305be65aea8" dependencies = [ "base64", "bytes", @@ -2422,7 +2433,7 @@ dependencies = [ "libc", "percent-encoding", "pin-project-lite", - "socket2 0.6.0", + "socket2", "tokio", "tower-service", "tracing", @@ -2430,9 +2441,9 @@ dependencies = [ [[package]] name = "iana-time-zone" -version = "0.1.63" +version = "0.1.64" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b0c919e5debc312ad217002b8048a17b7d83f80703865bbfcfebb0458b0b27d8" +checksum = "33e57f83510bb73707521ebaffa789ec8caf86f9657cad665b092b581d40e9fb" dependencies = [ "android_system_properties", "core-foundation-sys", @@ -2546,9 +2557,9 @@ checksum = "b9e0384b61958566e926dc50660321d12159025e767c18e043daf26b70104c39" [[package]] name = "idna" -version = "1.0.3" +version = "1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "686f825264d630750a544639377bae737628043f20d38bbc029e8f29ea968a7e" +checksum = "3b0875f23caa03898994f6ddc501886a45c7d3d62d04d2d90788d47be1b1e4de" dependencies = [ "idna_adapter", "smallvec", @@ -2604,13 +2615,14 @@ dependencies = [ [[package]] name = "indexmap" -version = "2.10.0" +version = "2.11.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fe4cd85333e22411419a0bcae1297d25e58c9443848b11dc6a86fefe8c78a661" +checksum = "92119844f513ffa41556430369ab02c295a3578af21cf945caa3e9e0c2481ac3" dependencies = [ "equivalent", "hashbrown 0.15.5", "serde", + "serde_core", ] [[package]] @@ -2628,9 +2640,9 @@ dependencies = [ [[package]] name = "io-uring" -version = "0.7.9" +version = "0.7.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d93587f37623a1a17d94ef2bc9ada592f5465fe7732084ab7beefabe5c77c0c4" +checksum = "046fa2d4d00aea763528b4950358d0ead425372445dc8ff86312b3c69ff7727b" dependencies = [ "bitflags", "cfg-if", @@ -2703,9 +2715,9 @@ checksum = "4a5f13b858c8d314ee3e8f639011f7ccefe71f97f96e50151fb991f267928e2c" [[package]] name = "jobserver" -version = "0.1.33" +version = "0.1.34" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "38f262f097c174adebe41eb73d66ae9c06b2844fb0da69969647bbddd9b0538a" +checksum = "9afb3de4395d6b3e67a780b6de64b51c978ecf11cb9a462c66be7d4ca9039d33" dependencies = [ "getrandom 0.3.3", "libc", @@ -2713,9 +2725,9 @@ dependencies = [ [[package]] name = "js-sys" -version = "0.3.77" +version = "0.3.79" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1cfaf33c695fc6e08064efbc1f72ec937429614f25eef83af942d0e227c3a28f" +checksum = "6247da8b8658ad4e73a186e747fcc5fc2a29f979d6fe6269127fdb5fd08298d0" dependencies = [ "once_cell", "wasm-bindgen", @@ -2855,9 +2867,9 @@ dependencies = [ [[package]] name = "linux-raw-sys" -version = "0.9.4" +version = "0.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cd945864f07fe9f5371a27ad7b52a172b4b499999f1d97574c9fa68373937e12" +checksum = "df1d3c3b53da64cf5760482273a98e575c651a67eec7f77df96b5b642de8f039" [[package]] name = "litemap" @@ -2877,9 +2889,9 @@ dependencies = [ [[package]] name = "log" -version = "0.4.27" +version = "0.4.28" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "13dc2df351e3202783a1fe0d44375f7295ffb4049267b0f3018346dc122a1d94" +checksum = "34080505efa8e45a4b816c349525ebe327ceaa8559756f0356cba97ef3bf7432" [[package]] name = "lru" @@ -2918,11 +2930,11 @@ dependencies = [ [[package]] name = "matchers" -version = "0.1.0" +version = "0.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8263075bb86c5a1b1427b5ae862e8889656f126e9f77c484496e8b47cf5c5558" +checksum = "d1525a2a28c7f4fa0fc98bb91ae755d1e2d1505079e05539e35bc876b5d65ae9" dependencies = [ - "regex-automata 0.1.10", + "regex-automata", ] [[package]] @@ -2992,23 +3004,6 @@ dependencies = [ "syn 2.0.106", ] -[[package]] -name = "native-tls" -version = "0.2.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "87de3442987e9dbec73158d5c715e7ad9072fda936bb03d19d7fa10e00520f0e" -dependencies = [ - "libc", - "log", - "openssl", - "openssl-probe", - "openssl-sys", - "schannel", - "security-framework", - "security-framework-sys", - "tempfile", -] - [[package]] name = "no-std-compat" version = "0.4.1" @@ -3023,12 +3018,11 @@ checksum = "38bf9645c8b145698bb0b18a4637dcacbc421ea49bef2317e4fd8065a387cf21" [[package]] name = "nu-ansi-term" -version = "0.46.0" +version = "0.50.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "77a8165726e8236064dbb45459242600304b42a5ea24ee2948e18e023bf7ba84" +checksum = "d4a28e057d01f97e61255210fcff094d74ed0466038633e95017f5beb68e4399" dependencies = [ - "overload", - "winapi", + "windows-sys 0.52.0", ] [[package]] @@ -3196,9 +3190,9 @@ dependencies = [ [[package]] name = "nybbles" -version = "0.4.3" +version = "0.4.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "63cb50036b1ad148038105af40aaa70ff24d8a14fbc44ae5c914e1348533d12e" +checksum = "f0418987d1aaed324d95b4beffc93635e19be965ed5d63ec07a35980fe3b71a4" dependencies = [ "alloy-rlp", "cfg-if", @@ -3235,9 +3229,9 @@ checksum = "a4895175b425cb1f87721b59f0f286c2092bd4af812243672510e1ac53e2e0ad" [[package]] name = "op-alloy-consensus" -version = "0.18.14" +version = "0.19.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0c88d2940558fd69f8f07b3cbd7bb3c02fc7d31159c1a7ba9deede50e7881024" +checksum = "d9ade20c592484ba1ea538006e0454284174447a3adf9bb59fa99ed512f95493" dependencies = [ "alloy-consensus", "alloy-eips", @@ -3252,12 +3246,11 @@ dependencies = [ [[package]] name = "op-revm" -version = "8.1.0" +version = "10.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5ce1dc7533f4e5716c55cd3d62488c6200cb4dfda96e0c75a7e484652464343b" +checksum = "5ba21d705bbbfc947a423cba466d75e4af0c7d43ee89ba0a0f1cfa04963cede9" dependencies = [ "auto_impl", - "once_cell", "revm", "serde", ] @@ -3268,50 +3261,6 @@ version = "0.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c08d65885ee38876c4f86fa503fb49d7b507c2b62552df7c70b2fce627e06381" -[[package]] -name = "openssl" -version = "0.10.73" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8505734d46c8ab1e19a1dce3aef597ad87dcb4c37e7188231769bd6bd51cebf8" -dependencies = [ - "bitflags", - "cfg-if", - "foreign-types", - "libc", - "once_cell", - "openssl-macros", - "openssl-sys", -] - -[[package]] -name = "openssl-macros" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a948666b637a0f465e8564c73e89d4dde00d72d4d473cc972f390fc3dcee7d9c" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.106", -] - -[[package]] -name = "openssl-probe" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d05e27ee213611ffe7d6348b942e8f942b37114c00cc03cec254295a4a17852e" - -[[package]] -name = "openssl-sys" -version = "0.9.109" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90096e2e47630d78b7d1c20952dc621f957103f8bc2c8359ec81290d75238571" -dependencies = [ - "cc", - "libc", - "pkg-config", - "vcpkg", -] - [[package]] name = "openvm" version = "1.4.0" @@ -3402,23 +3351,6 @@ dependencies = [ "syn 2.0.106", ] -[[package]] -name = "openvm-keccak256" -version = "1.4.0" -source = "git+https://github.com/openvm-org/openvm.git?tag=v1.4.0#39ee587f0f73646e3753cb2aa5f34885d4efffe0" -dependencies = [ - "openvm-keccak256-guest", - "tiny-keccak", -] - -[[package]] -name = "openvm-keccak256-guest" -version = "1.4.0" -source = "git+https://github.com/openvm-org/openvm.git?tag=v1.4.0#39ee587f0f73646e3753cb2aa5f34885d4efffe0" -dependencies = [ - "openvm-platform", -] - [[package]] name = "openvm-kzg" version = "0.2.0-alpha" @@ -3524,12 +3456,6 @@ dependencies = [ "openvm-platform", ] -[[package]] -name = "overload" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b15813163c1d831bf4a13c3610c05c0d03b39feb07f7e09fa234dac9b15aaf39" - [[package]] name = "p256" version = "0.13.2" @@ -3767,15 +3693,15 @@ checksum = "57c0d7b74b563b49d38dae00a0c37d4d6de9b432382b2892f0574ddcae73fd0a" [[package]] name = "percent-encoding" -version = "2.3.1" +version = "2.3.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e3148f5046208a5d56bcfc03053e3ca6334e51da8dfb19b6cdc8b306fae3283e" +checksum = "9b4f627cb1b25917193a259e49bdad08f671f8d9708acfd5fe0a8c1455d87220" [[package]] name = "pest" -version = "2.8.1" +version = "2.8.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1db05f56d34358a8b1066f67cbb203ee3e7ed2ba674a6263a1d5ec6db2204323" +checksum = "21e0a3a33733faeaf8651dfee72dd0f388f0c8e5ad496a3478fa5a922f49cfa8" dependencies = [ "memchr", "thiserror", @@ -3881,9 +3807,9 @@ checksum = "f84267b20a16ea918e43c6a88433c2d54fa145c92a811b5b047ccbe153674483" [[package]] name = "potential_utf" -version = "0.1.2" +version = "0.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e5a7c30837279ca13e7c867e9e40053bc68740f988cb07f7ca6df43cc734b585" +checksum = "84df19adbe5b5a0782edcab45899906947ab039ccf4573713735ee7de1e6b08a" dependencies = [ "zerovec", ] @@ -3925,9 +3851,9 @@ dependencies = [ [[package]] name = "proc-macro-crate" -version = "3.3.0" +version = "3.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "edce586971a4dfaa28950c6f18ed55e0406c1ab88bbce2c6f6293a7aaba73d35" +checksum = "219cb19e96be00ab2e37d6e299658a0cfa83e52429179969b0f0121b4ac46983" dependencies = [ "toml_edit", ] @@ -3977,7 +3903,7 @@ dependencies = [ "rand 0.9.2", "rand_chacha 0.9.0", "rand_xorshift", - "regex-syntax 0.8.5", + "regex-syntax", "rusty-fork", "tempfile", "unarray", @@ -4026,9 +3952,9 @@ checksum = "a1d01941d82fa2ab50be1e79e6714289dd7cde78eba4c074bc5a4374f650dfe0" [[package]] name = "quinn" -version = "0.11.8" +version = "0.11.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "626214629cda6781b6dc1d316ba307189c85ba657213ce642d9c77670f8202c8" +checksum = "b9e20a958963c291dc322d98411f541009df2ced7b5a4f2bd52337638cfccf20" dependencies = [ "bytes", "cfg_aliases", @@ -4037,7 +3963,7 @@ dependencies = [ "quinn-udp", "rustc-hash", "rustls", - "socket2 0.5.10", + "socket2", "thiserror", "tokio", "tracing", @@ -4046,9 +3972,9 @@ dependencies = [ [[package]] name = "quinn-proto" -version = "0.11.12" +version = "0.11.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49df843a9161c85bb8aae55f101bc0bac8bcafd637a620d9122fd7e0b2f7422e" +checksum = "f1906b49b0c3bc04b5fe5d86a77925ae6524a19b816ae38ce1e426255f1d8a31" dependencies = [ "bytes", "getrandom 0.3.3", @@ -4067,16 +3993,16 @@ dependencies = [ [[package]] name = "quinn-udp" -version = "0.5.13" +version = "0.5.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fcebb1209ee276352ef14ff8732e24cc2b02bbac986cd74a4c81bcb2f9881970" +checksum = "addec6a0dcad8a8d96a771f815f0eaf55f9d1805756410b39f5fa81332574cbd" dependencies = [ "cfg_aliases", "libc", "once_cell", - "socket2 0.5.10", + "socket2", "tracing", - "windows-sys 0.59.0", + "windows-sys 0.60.2", ] [[package]] @@ -4182,9 +4108,9 @@ dependencies = [ [[package]] name = "raw-cpuid" -version = "11.5.0" +version = "11.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c6df7ab838ed27997ba19a4664507e6f82b41fe6e20be42929332156e5e85146" +checksum = "498cd0dc59d73224351ee52a95fee0f1a617a2eae0e7d9d720cc622c73a54186" dependencies = [ "bitflags", ] @@ -4240,47 +4166,32 @@ dependencies = [ [[package]] name = "regex" -version = "1.11.1" +version = "1.11.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b544ef1b4eac5dc2db33ea63606ae9ffcfac26c1416a2806ae0bf5f56b201191" +checksum = "23d7fd106d8c02486a8d64e778353d1cffe08ce79ac2e82f540c86d0facf6912" dependencies = [ "aho-corasick", "memchr", - "regex-automata 0.4.9", - "regex-syntax 0.8.5", + "regex-automata", + "regex-syntax", ] [[package]] name = "regex-automata" -version = "0.1.10" +version = "0.4.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c230d73fb8d8c1b9c0b3135c5142a8acee3a0558fb8db5cf1cb65f8d7862132" -dependencies = [ - "regex-syntax 0.6.29", -] - -[[package]] -name = "regex-automata" -version = "0.4.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "809e8dc61f6de73b46c85f4c96486310fe304c434cfa43669d7b40f711150908" +checksum = "6b9458fa0bfeeac22b5ca447c63aaf45f28439a709ccd244698632f9aa6394d6" dependencies = [ "aho-corasick", "memchr", - "regex-syntax 0.8.5", + "regex-syntax", ] [[package]] name = "regex-syntax" -version = "0.6.29" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f162c6dd7b008981e4d40210aca20b4bd0f9b60ca9271061b07f78537722f2e1" - -[[package]] -name = "regex-syntax" -version = "0.8.5" +version = "0.8.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2b15c43186be67a4fd63bee50d0303afffcef381492ebe2c5d87f324e1b8815c" +checksum = "caf4aa5b0f434c91fe5c7f1ecb6a5ece2130b02ad2a590589dda5146df959001" [[package]] name = "relative-path" @@ -4311,11 +4222,9 @@ dependencies = [ "http-body-util", "hyper", "hyper-rustls", - "hyper-tls", "hyper-util", "js-sys", "log", - "native-tls", "percent-encoding", "pin-project-lite", "quinn", @@ -4326,7 +4235,6 @@ dependencies = [ "serde_urlencoded", "sync_wrapper", "tokio", - "tokio-native-tls", "tokio-rustls", "tower", "tower-http", @@ -4340,8 +4248,8 @@ dependencies = [ [[package]] name = "reth-chainspec" -version = "1.6.0" -source = "git+https://github.com/scroll-tech/reth?branch=scroll#d485f4718a0c93f3fc1ec453b8ddde6ce1ebe397" +version = "1.7.0" +source = "git+https://github.com/scroll-tech/reth?branch=scroll#501e5c609bdd13af047f90d764331ba5ad39c34b" dependencies = [ "alloy-chains", "alloy-consensus", @@ -4360,8 +4268,8 @@ dependencies = [ [[package]] name = "reth-codecs" -version = "1.6.0" -source = "git+https://github.com/scroll-tech/reth?branch=scroll#d485f4718a0c93f3fc1ec453b8ddde6ce1ebe397" +version = "1.7.0" +source = "git+https://github.com/scroll-tech/reth?branch=scroll#501e5c609bdd13af047f90d764331ba5ad39c34b" dependencies = [ "alloy-consensus", "alloy-eips", @@ -4378,8 +4286,8 @@ dependencies = [ [[package]] name = "reth-codecs-derive" -version = "1.6.0" -source = "git+https://github.com/scroll-tech/reth?branch=scroll#d485f4718a0c93f3fc1ec453b8ddde6ce1ebe397" +version = "1.7.0" +source = "git+https://github.com/scroll-tech/reth?branch=scroll#501e5c609bdd13af047f90d764331ba5ad39c34b" dependencies = [ "convert_case", "proc-macro2", @@ -4389,8 +4297,8 @@ dependencies = [ [[package]] name = "reth-db-models" -version = "1.6.0" -source = "git+https://github.com/scroll-tech/reth?branch=scroll#d485f4718a0c93f3fc1ec453b8ddde6ce1ebe397" +version = "1.7.0" +source = "git+https://github.com/scroll-tech/reth?branch=scroll#501e5c609bdd13af047f90d764331ba5ad39c34b" dependencies = [ "alloy-eips", "alloy-primitives", @@ -4399,8 +4307,8 @@ dependencies = [ [[package]] name = "reth-ethereum-forks" -version = "1.6.0" -source = "git+https://github.com/scroll-tech/reth?branch=scroll#d485f4718a0c93f3fc1ec453b8ddde6ce1ebe397" +version = "1.7.0" +source = "git+https://github.com/scroll-tech/reth?branch=scroll#501e5c609bdd13af047f90d764331ba5ad39c34b" dependencies = [ "alloy-eip2124", "alloy-hardforks", @@ -4411,8 +4319,8 @@ dependencies = [ [[package]] name = "reth-ethereum-primitives" -version = "1.6.0" -source = "git+https://github.com/scroll-tech/reth?branch=scroll#d485f4718a0c93f3fc1ec453b8ddde6ce1ebe397" +version = "1.7.0" +source = "git+https://github.com/scroll-tech/reth?branch=scroll#501e5c609bdd13af047f90d764331ba5ad39c34b" dependencies = [ "alloy-consensus", "alloy-eips", @@ -4426,8 +4334,8 @@ dependencies = [ [[package]] name = "reth-evm" -version = "1.6.0" -source = "git+https://github.com/scroll-tech/reth?branch=scroll#d485f4718a0c93f3fc1ec453b8ddde6ce1ebe397" +version = "1.7.0" +source = "git+https://github.com/scroll-tech/reth?branch=scroll#501e5c609bdd13af047f90d764331ba5ad39c34b" dependencies = [ "alloy-consensus", "alloy-eips", @@ -4448,8 +4356,8 @@ dependencies = [ [[package]] name = "reth-evm-ethereum" -version = "1.6.0" -source = "git+https://github.com/scroll-tech/reth?branch=scroll#d485f4718a0c93f3fc1ec453b8ddde6ce1ebe397" +version = "1.7.0" +source = "git+https://github.com/scroll-tech/reth?branch=scroll#501e5c609bdd13af047f90d764331ba5ad39c34b" dependencies = [ "alloy-consensus", "alloy-eips", @@ -4468,8 +4376,8 @@ dependencies = [ [[package]] name = "reth-execution-errors" -version = "1.6.0" -source = "git+https://github.com/scroll-tech/reth?branch=scroll#d485f4718a0c93f3fc1ec453b8ddde6ce1ebe397" +version = "1.7.0" +source = "git+https://github.com/scroll-tech/reth?branch=scroll#501e5c609bdd13af047f90d764331ba5ad39c34b" dependencies = [ "alloy-evm", "alloy-primitives", @@ -4481,8 +4389,8 @@ dependencies = [ [[package]] name = "reth-execution-types" -version = "1.6.0" -source = "git+https://github.com/scroll-tech/reth?branch=scroll#d485f4718a0c93f3fc1ec453b8ddde6ce1ebe397" +version = "1.7.0" +source = "git+https://github.com/scroll-tech/reth?branch=scroll#501e5c609bdd13af047f90d764331ba5ad39c34b" dependencies = [ "alloy-consensus", "alloy-eips", @@ -4497,8 +4405,8 @@ dependencies = [ [[package]] name = "reth-network-peers" -version = "1.6.0" -source = "git+https://github.com/scroll-tech/reth?branch=scroll#d485f4718a0c93f3fc1ec453b8ddde6ce1ebe397" +version = "1.7.0" +source = "git+https://github.com/scroll-tech/reth?branch=scroll#501e5c609bdd13af047f90d764331ba5ad39c34b" dependencies = [ "alloy-primitives", "alloy-rlp", @@ -4509,8 +4417,8 @@ dependencies = [ [[package]] name = "reth-primitives" -version = "1.6.0" -source = "git+https://github.com/scroll-tech/reth?branch=scroll#d485f4718a0c93f3fc1ec453b8ddde6ce1ebe397" +version = "1.7.0" +source = "git+https://github.com/scroll-tech/reth?branch=scroll#501e5c609bdd13af047f90d764331ba5ad39c34b" dependencies = [ "alloy-consensus", "once_cell", @@ -4522,8 +4430,8 @@ dependencies = [ [[package]] name = "reth-primitives-traits" -version = "1.6.0" -source = "git+https://github.com/scroll-tech/reth?branch=scroll#d485f4718a0c93f3fc1ec453b8ddde6ce1ebe397" +version = "1.7.0" +source = "git+https://github.com/scroll-tech/reth?branch=scroll#501e5c609bdd13af047f90d764331ba5ad39c34b" dependencies = [ "alloy-consensus", "alloy-eips", @@ -4550,8 +4458,8 @@ dependencies = [ [[package]] name = "reth-prune-types" -version = "1.6.0" -source = "git+https://github.com/scroll-tech/reth?branch=scroll#d485f4718a0c93f3fc1ec453b8ddde6ce1ebe397" +version = "1.7.0" +source = "git+https://github.com/scroll-tech/reth?branch=scroll#501e5c609bdd13af047f90d764331ba5ad39c34b" dependencies = [ "alloy-primitives", "derive_more", @@ -4560,8 +4468,8 @@ dependencies = [ [[package]] name = "reth-scroll-chainspec" -version = "1.6.0" -source = "git+https://github.com/scroll-tech/reth?branch=scroll#d485f4718a0c93f3fc1ec453b8ddde6ce1ebe397" +version = "1.7.0" +source = "git+https://github.com/scroll-tech/reth?branch=scroll#501e5c609bdd13af047f90d764331ba5ad39c34b" dependencies = [ "alloy-chains", "alloy-consensus", @@ -4585,8 +4493,8 @@ dependencies = [ [[package]] name = "reth-scroll-evm" -version = "1.6.0" -source = "git+https://github.com/scroll-tech/reth?branch=scroll#d485f4718a0c93f3fc1ec453b8ddde6ce1ebe397" +version = "1.7.0" +source = "git+https://github.com/scroll-tech/reth?branch=scroll#501e5c609bdd13af047f90d764331ba5ad39c34b" dependencies = [ "alloy-consensus", "alloy-eips", @@ -4615,8 +4523,8 @@ dependencies = [ [[package]] name = "reth-scroll-forks" -version = "1.6.0" -source = "git+https://github.com/scroll-tech/reth?branch=scroll#d485f4718a0c93f3fc1ec453b8ddde6ce1ebe397" +version = "1.7.0" +source = "git+https://github.com/scroll-tech/reth?branch=scroll#501e5c609bdd13af047f90d764331ba5ad39c34b" dependencies = [ "alloy-chains", "alloy-primitives", @@ -4629,8 +4537,8 @@ dependencies = [ [[package]] name = "reth-scroll-primitives" -version = "1.6.0" -source = "git+https://github.com/scroll-tech/reth?branch=scroll#d485f4718a0c93f3fc1ec453b8ddde6ce1ebe397" +version = "1.7.0" +source = "git+https://github.com/scroll-tech/reth?branch=scroll#501e5c609bdd13af047f90d764331ba5ad39c34b" dependencies = [ "alloy-consensus", "alloy-eips", @@ -4646,8 +4554,8 @@ dependencies = [ [[package]] name = "reth-stages-types" -version = "1.6.0" -source = "git+https://github.com/scroll-tech/reth?branch=scroll#d485f4718a0c93f3fc1ec453b8ddde6ce1ebe397" +version = "1.7.0" +source = "git+https://github.com/scroll-tech/reth?branch=scroll#501e5c609bdd13af047f90d764331ba5ad39c34b" dependencies = [ "alloy-primitives", "reth-trie-common", @@ -4655,8 +4563,8 @@ dependencies = [ [[package]] name = "reth-static-file-types" -version = "1.6.0" -source = "git+https://github.com/scroll-tech/reth?branch=scroll#d485f4718a0c93f3fc1ec453b8ddde6ce1ebe397" +version = "1.7.0" +source = "git+https://github.com/scroll-tech/reth?branch=scroll#501e5c609bdd13af047f90d764331ba5ad39c34b" dependencies = [ "alloy-primitives", "derive_more", @@ -4666,8 +4574,8 @@ dependencies = [ [[package]] name = "reth-storage-api" -version = "1.6.0" -source = "git+https://github.com/scroll-tech/reth?branch=scroll#d485f4718a0c93f3fc1ec453b8ddde6ce1ebe397" +version = "1.7.0" +source = "git+https://github.com/scroll-tech/reth?branch=scroll#501e5c609bdd13af047f90d764331ba5ad39c34b" dependencies = [ "alloy-consensus", "alloy-eips", @@ -4688,8 +4596,8 @@ dependencies = [ [[package]] name = "reth-storage-errors" -version = "1.6.0" -source = "git+https://github.com/scroll-tech/reth?branch=scroll#d485f4718a0c93f3fc1ec453b8ddde6ce1ebe397" +version = "1.7.0" +source = "git+https://github.com/scroll-tech/reth?branch=scroll#501e5c609bdd13af047f90d764331ba5ad39c34b" dependencies = [ "alloy-eips", "alloy-primitives", @@ -4704,8 +4612,8 @@ dependencies = [ [[package]] name = "reth-trie" -version = "1.6.0" -source = "git+https://github.com/scroll-tech/reth?branch=scroll#d485f4718a0c93f3fc1ec453b8ddde6ce1ebe397" +version = "1.7.0" +source = "git+https://github.com/scroll-tech/reth?branch=scroll#501e5c609bdd13af047f90d764331ba5ad39c34b" dependencies = [ "alloy-consensus", "alloy-eips", @@ -4726,8 +4634,8 @@ dependencies = [ [[package]] name = "reth-trie-common" -version = "1.6.0" -source = "git+https://github.com/scroll-tech/reth?branch=scroll#d485f4718a0c93f3fc1ec453b8ddde6ce1ebe397" +version = "1.7.0" +source = "git+https://github.com/scroll-tech/reth?branch=scroll#501e5c609bdd13af047f90d764331ba5ad39c34b" dependencies = [ "alloy-consensus", "alloy-primitives", @@ -4742,8 +4650,8 @@ dependencies = [ [[package]] name = "reth-trie-sparse" -version = "1.6.0" -source = "git+https://github.com/scroll-tech/reth?branch=scroll#d485f4718a0c93f3fc1ec453b8ddde6ce1ebe397" +version = "1.7.0" +source = "git+https://github.com/scroll-tech/reth?branch=scroll#501e5c609bdd13af047f90d764331ba5ad39c34b" dependencies = [ "alloy-primitives", "alloy-rlp", @@ -4758,16 +4666,16 @@ dependencies = [ [[package]] name = "reth-zstd-compressors" -version = "1.6.0" -source = "git+https://github.com/scroll-tech/reth?branch=scroll#d485f4718a0c93f3fc1ec453b8ddde6ce1ebe397" +version = "1.7.0" +source = "git+https://github.com/scroll-tech/reth?branch=scroll#501e5c609bdd13af047f90d764331ba5ad39c34b" dependencies = [ "zstd", ] [[package]] name = "revm" -version = "27.1.0" -source = "git+https://github.com/scroll-tech/revm#9cd9896c06a5bf6d4212906260d8789579873ba4" +version = "29.0.0" +source = "git+https://github.com/scroll-tech/revm#cc793301c260ce292d8deb59f61bc2a59bd0b991" dependencies = [ "revm-bytecode", "revm-context", @@ -4784,11 +4692,10 @@ dependencies = [ [[package]] name = "revm-bytecode" -version = "6.1.0" -source = "git+https://github.com/scroll-tech/revm#9cd9896c06a5bf6d4212906260d8789579873ba4" +version = "6.2.2" +source = "git+https://github.com/scroll-tech/revm#cc793301c260ce292d8deb59f61bc2a59bd0b991" dependencies = [ "bitvec", - "once_cell", "phf", "revm-primitives", "serde", @@ -4796,9 +4703,10 @@ dependencies = [ [[package]] name = "revm-context" -version = "8.0.4" -source = "git+https://github.com/scroll-tech/revm#9cd9896c06a5bf6d4212906260d8789579873ba4" +version = "9.0.2" +source = "git+https://github.com/scroll-tech/revm#cc793301c260ce292d8deb59f61bc2a59bd0b991" dependencies = [ + "bitvec", "cfg-if", "derive-where", "revm-bytecode", @@ -4811,8 +4719,8 @@ dependencies = [ [[package]] name = "revm-context-interface" -version = "9.0.0" -source = "git+https://github.com/scroll-tech/revm#9cd9896c06a5bf6d4212906260d8789579873ba4" +version = "10.1.0" +source = "git+https://github.com/scroll-tech/revm#cc793301c260ce292d8deb59f61bc2a59bd0b991" dependencies = [ "alloy-eip2930", "alloy-eip7702", @@ -4826,8 +4734,8 @@ dependencies = [ [[package]] name = "revm-database" -version = "7.0.2" -source = "git+https://github.com/scroll-tech/revm#9cd9896c06a5bf6d4212906260d8789579873ba4" +version = "7.0.5" +source = "git+https://github.com/scroll-tech/revm#cc793301c260ce292d8deb59f61bc2a59bd0b991" dependencies = [ "alloy-eips", "revm-bytecode", @@ -4839,8 +4747,8 @@ dependencies = [ [[package]] name = "revm-database-interface" -version = "7.0.2" -source = "git+https://github.com/scroll-tech/revm#9cd9896c06a5bf6d4212906260d8789579873ba4" +version = "7.0.5" +source = "git+https://github.com/scroll-tech/revm#cc793301c260ce292d8deb59f61bc2a59bd0b991" dependencies = [ "auto_impl", "either", @@ -4851,8 +4759,8 @@ dependencies = [ [[package]] name = "revm-handler" -version = "8.1.0" -source = "git+https://github.com/scroll-tech/revm#9cd9896c06a5bf6d4212906260d8789579873ba4" +version = "10.0.0" +source = "git+https://github.com/scroll-tech/revm#cc793301c260ce292d8deb59f61bc2a59bd0b991" dependencies = [ "auto_impl", "derive-where", @@ -4869,8 +4777,8 @@ dependencies = [ [[package]] name = "revm-inspector" -version = "8.1.0" -source = "git+https://github.com/scroll-tech/revm#9cd9896c06a5bf6d4212906260d8789579873ba4" +version = "10.0.0" +source = "git+https://github.com/scroll-tech/revm#cc793301c260ce292d8deb59f61bc2a59bd0b991" dependencies = [ "auto_impl", "either", @@ -4886,8 +4794,8 @@ dependencies = [ [[package]] name = "revm-interpreter" -version = "24.0.0" -source = "git+https://github.com/scroll-tech/revm#9cd9896c06a5bf6d4212906260d8789579873ba4" +version = "25.0.2" +source = "git+https://github.com/scroll-tech/revm#cc793301c260ce292d8deb59f61bc2a59bd0b991" dependencies = [ "revm-bytecode", "revm-context-interface", @@ -4897,8 +4805,8 @@ dependencies = [ [[package]] name = "revm-precompile" -version = "25.0.0" -source = "git+https://github.com/scroll-tech/revm#9cd9896c06a5bf6d4212906260d8789579873ba4" +version = "27.0.0" +source = "git+https://github.com/scroll-tech/revm#cc793301c260ce292d8deb59f61bc2a59bd0b991" dependencies = [ "ark-bls12-381", "ark-bn254", @@ -4912,7 +4820,6 @@ dependencies = [ "k256 0.13.4 (registry+https://github.com/rust-lang/crates.io-index)", "kzg-rs", "libsecp256k1", - "once_cell", "p256", "revm-primitives", "ripemd", @@ -4923,18 +4830,19 @@ dependencies = [ [[package]] name = "revm-primitives" -version = "20.1.0" -source = "git+https://github.com/scroll-tech/revm#9cd9896c06a5bf6d4212906260d8789579873ba4" +version = "20.2.1" +source = "git+https://github.com/scroll-tech/revm#cc793301c260ce292d8deb59f61bc2a59bd0b991" dependencies = [ "alloy-primitives", "num_enum", + "once_cell", "serde", ] [[package]] name = "revm-scroll" version = "0.1.0" -source = "git+https://github.com/scroll-tech/scroll-revm#59d400f1a0b616d7b97a24da1cb5b8dcb8006f4b" +source = "git+https://github.com/scroll-tech/scroll-revm#727c40fe86ac165f53505a6efe01bad9b1c502f7" dependencies = [ "auto_impl", "enumn", @@ -4947,8 +4855,8 @@ dependencies = [ [[package]] name = "revm-state" -version = "7.0.2" -source = "git+https://github.com/scroll-tech/revm#9cd9896c06a5bf6d4212906260d8789579873ba4" +version = "7.0.5" +source = "git+https://github.com/scroll-tech/revm#cc793301c260ce292d8deb59f61bc2a59bd0b991" dependencies = [ "bitflags", "revm-bytecode", @@ -4998,7 +4906,7 @@ dependencies = [ "bytecheck", "bytes", "hashbrown 0.15.5", - "indexmap 2.10.0", + "indexmap 2.11.3", "munge", "ptr_meta", "rancor", @@ -5060,9 +4968,9 @@ dependencies = [ [[package]] name = "rug" -version = "1.27.0" +version = "1.28.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4207e8d668e5b8eb574bda8322088ccd0d7782d3d03c7e8d562e82ed82bdcbc3" +checksum = "58ad2e973fe3c3214251a840a621812a4f40468da814b1a3d6947d433c2af11f" dependencies = [ "az", "gmp-mpfr-sys", @@ -5137,20 +5045,20 @@ version = "0.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "cfcb3a22ef46e85b45de6ee7e79d063319ebb6594faafcf1c225ea92ab6e9b92" dependencies = [ - "semver 1.0.26", + "semver 1.0.27", ] [[package]] name = "rustix" -version = "1.0.8" +version = "1.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "11181fbabf243db407ef8df94a6ce0b2f9a733bd8be4ad02b4eda9602296cac8" +checksum = "cd15f8a2c5551a84d56efdc1cd049089e409ac19a3072d5037a17fd70719ff3e" dependencies = [ "bitflags", "errno", "libc", "linux-raw-sys", - "windows-sys 0.60.2", + "windows-sys 0.61.0", ] [[package]] @@ -5179,9 +5087,9 @@ dependencies = [ [[package]] name = "rustls-webpki" -version = "0.103.4" +version = "0.103.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0a17884ae0c1b773f1ccd2bd4a8c72f16da897310a98b0e84bf349ad5ead92fc" +checksum = "8572f3c2cb9934231157b45499fc41e1f58c589fdfb81a844ba873265e80f8eb" dependencies = [ "ring", "rustls-pki-types", @@ -5241,7 +5149,7 @@ dependencies = [ "serde_path_to_error", "tokio", "tracing", - "tracing-subscriber 0.3.19", + "tracing-subscriber 0.3.20", "url", ] @@ -5266,7 +5174,7 @@ dependencies = [ "serde_with", "thiserror", "tracing", - "tracing-subscriber 0.3.19", + "tracing-subscriber 0.3.20", ] [[package]] @@ -5280,8 +5188,8 @@ dependencies = [ name = "sbv-kv" version = "2.0.0" dependencies = [ + "alloy-primitives", "auto_impl", - "hashbrown 0.15.5", "rustc-hash", ] @@ -5291,7 +5199,6 @@ version = "2.0.0" dependencies = [ "k256 0.13.4 (git+https://github.com/openvm-org/openvm.git?tag=v1.4.0)", "openvm-ecc-guest", - "openvm-keccak256", "openvm-kzg", "openvm-pairing", "openvm-sha2", @@ -5369,15 +5276,6 @@ dependencies = [ "thiserror", ] -[[package]] -name = "schannel" -version = "0.1.27" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1f29ebaa345f945cec9fbbc532eb307f0fdad8161f281b6369539c8d84876b3d" -dependencies = [ - "windows-sys 0.59.0", -] - [[package]] name = "schemars" version = "0.9.0" @@ -5410,8 +5308,8 @@ checksum = "94143f37725109f92c262ed2cf5e59bce7498c01bcc1502d7b9afe439a4e9f49" [[package]] name = "scroll-alloy-consensus" -version = "1.6.0" -source = "git+https://github.com/scroll-tech/reth?branch=scroll#d485f4718a0c93f3fc1ec453b8ddde6ce1ebe397" +version = "1.7.0" +source = "git+https://github.com/scroll-tech/reth?branch=scroll#501e5c609bdd13af047f90d764331ba5ad39c34b" dependencies = [ "alloy-consensus", "alloy-eips", @@ -5426,8 +5324,8 @@ dependencies = [ [[package]] name = "scroll-alloy-evm" -version = "1.6.0" -source = "git+https://github.com/scroll-tech/reth?branch=scroll#d485f4718a0c93f3fc1ec453b8ddde6ce1ebe397" +version = "1.7.0" +source = "git+https://github.com/scroll-tech/reth?branch=scroll#501e5c609bdd13af047f90d764331ba5ad39c34b" dependencies = [ "alloy-consensus", "alloy-eips", @@ -5444,8 +5342,8 @@ dependencies = [ [[package]] name = "scroll-alloy-hardforks" -version = "1.6.0" -source = "git+https://github.com/scroll-tech/reth?branch=scroll#d485f4718a0c93f3fc1ec453b8ddde6ce1ebe397" +version = "1.7.0" +source = "git+https://github.com/scroll-tech/reth?branch=scroll#501e5c609bdd13af047f90d764331ba5ad39c34b" dependencies = [ "alloy-hardforks", "auto_impl", @@ -5454,8 +5352,8 @@ dependencies = [ [[package]] name = "scroll-alloy-network" -version = "1.6.0" -source = "git+https://github.com/scroll-tech/reth?branch=scroll#d485f4718a0c93f3fc1ec453b8ddde6ce1ebe397" +version = "1.7.0" +source = "git+https://github.com/scroll-tech/reth?branch=scroll#501e5c609bdd13af047f90d764331ba5ad39c34b" dependencies = [ "alloy-consensus", "alloy-network", @@ -5469,8 +5367,8 @@ dependencies = [ [[package]] name = "scroll-alloy-rpc-types" -version = "1.6.0" -source = "git+https://github.com/scroll-tech/reth?branch=scroll#d485f4718a0c93f3fc1ec453b8ddde6ce1ebe397" +version = "1.7.0" +source = "git+https://github.com/scroll-tech/reth?branch=scroll#501e5c609bdd13af047f90d764331ba5ad39c34b" dependencies = [ "alloy-consensus", "alloy-eips", @@ -5540,29 +5438,6 @@ dependencies = [ "cc", ] -[[package]] -name = "security-framework" -version = "2.11.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "897b2245f0b511c87893af39b033e5ca9cce68824c4d7e7630b5a1d339658d02" -dependencies = [ - "bitflags", - "core-foundation", - "core-foundation-sys", - "libc", - "security-framework-sys", -] - -[[package]] -name = "security-framework-sys" -version = "2.14.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49db231d56a190491cb4aeda9527f1ad45345af50b0851622a7adb8c03b01c32" -dependencies = [ - "core-foundation-sys", - "libc", -] - [[package]] name = "semver" version = "0.11.0" @@ -5574,9 +5449,9 @@ dependencies = [ [[package]] name = "semver" -version = "1.0.26" +version = "1.0.27" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "56e6fa9c48d24d85fb3de5ad847117517440f6beceb7798af16b4a87d616b8d0" +checksum = "d767eb0aabc880b29956c35734170f26ed551a859dbd361d140cdbeca61ab1e2" [[package]] name = "semver-parser" @@ -5589,10 +5464,11 @@ dependencies = [ [[package]] name = "serde" -version = "1.0.219" +version = "1.0.225" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5f0e2c6ed6606019b4e29e69dbaba95b11854410e5347d525002456dbbb786b6" +checksum = "fd6c24dee235d0da097043389623fb913daddf92c76e9f5a1db88607a0bcbd1d" dependencies = [ + "serde_core", "serde_derive", ] @@ -5623,11 +5499,20 @@ dependencies = [ "serde", ] +[[package]] +name = "serde_core" +version = "1.0.225" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "659356f9a0cb1e529b24c01e43ad2bdf520ec4ceaf83047b83ddcc2251f96383" +dependencies = [ + "serde_derive", +] + [[package]] name = "serde_derive" -version = "1.0.219" +version = "1.0.225" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b0276cf7f2c73365f7157c8123c21cd9a50fbbd844757af28ca1f5925fc2a00" +checksum = "0ea936adf78b1f766949a4977b91d2f5595825bd6ec079aa9543ad2685fc4516" dependencies = [ "proc-macro2", "quote", @@ -5636,25 +5521,27 @@ dependencies = [ [[package]] name = "serde_json" -version = "1.0.143" +version = "1.0.145" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d401abef1d108fbd9cbaebc3e46611f4b1021f714a0597a71f41ee463f5f4a5a" +checksum = "402a6f66d8c709116cf22f558eab210f5a50187f702eb4d7e5ef38d9a7f1c79c" dependencies = [ - "indexmap 2.10.0", + "indexmap 2.11.3", "itoa", "memchr", "ryu", "serde", + "serde_core", ] [[package]] name = "serde_path_to_error" -version = "0.1.17" +version = "0.1.20" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "59fab13f937fa393d08645bf3a84bdfe86e296747b506ada67bb15f10f218b2a" +checksum = "10a9ff822e371bb5403e391ecd83e182e0e77ba7f6fe0160b795797109d1b457" dependencies = [ "itoa", "serde", + "serde_core", ] [[package]] @@ -5679,7 +5566,7 @@ dependencies = [ "chrono", "hex", "indexmap 1.9.3", - "indexmap 2.10.0", + "indexmap 2.11.3", "schemars 0.9.0", "schemars 1.0.4", "serde", @@ -5695,7 +5582,7 @@ version = "3.14.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "de90945e6565ce0d9a25098082ed4ee4002e047cb59892c318d66821e14bb30f" dependencies = [ - "darling", + "darling 0.20.11", "proc-macro2", "quote", "syn 2.0.106", @@ -5807,16 +5694,6 @@ dependencies = [ "serde", ] -[[package]] -name = "socket2" -version = "0.5.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e22376abed350d73dd1cd119b57ffccad95b4e585a7cda43e286245ce23c0678" -dependencies = [ - "libc", - "windows-sys 0.52.0", -] - [[package]] name = "socket2" version = "0.6.0" @@ -6024,31 +5901,31 @@ checksum = "55937e1799185b12863d447f42597ed69d9928686b8d88a1df17376a097d8369" [[package]] name = "tempfile" -version = "3.20.0" +version = "3.22.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e8a64e3985349f2441a1a9ef0b853f869006c3855f2cda6862a94d26ebb9d6a1" +checksum = "84fa4d11fadde498443cca10fd3ac23c951f0dc59e080e9f4b93d4df4e4eea53" dependencies = [ "fastrand", "getrandom 0.3.3", "once_cell", "rustix", - "windows-sys 0.59.0", + "windows-sys 0.61.0", ] [[package]] name = "thiserror" -version = "2.0.15" +version = "2.0.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "80d76d3f064b981389ecb4b6b7f45a0bf9fdac1d5b9204c7bd6714fecc302850" +checksum = "3467d614147380f2e4e374161426ff399c91084acd2363eaf549172b3d5e60c0" dependencies = [ "thiserror-impl", ] [[package]] name = "thiserror-impl" -version = "2.0.15" +version = "2.0.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "44d29feb33e986b6ea906bd9c3559a856983f92371b3eaa5e83782a351623de0" +checksum = "6c5e1be1c48b9172ee610da68fd9cd2770e7a4056cb3fc98710ee6906f0c7960" dependencies = [ "proc-macro2", "quote", @@ -6075,12 +5952,11 @@ dependencies = [ [[package]] name = "time" -version = "0.3.41" +version = "0.3.43" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8a7619e19bc266e0f9c5e6686659d394bc57973859340060a69221e57dbc0c40" +checksum = "83bde6f1ec10e72d583d91623c939f623002284ef622b87de38cfd546cbf2031" dependencies = [ "deranged", - "itoa", "num-conv", "powerfmt", "serde", @@ -6090,15 +5966,15 @@ dependencies = [ [[package]] name = "time-core" -version = "0.1.4" +version = "0.1.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c9e9a38711f559d9e3ce1cdb06dd7c5b8ea546bc90052da6d06bb76da74bb07c" +checksum = "40868e7c1d2f0b8d73e4a8c7f0ff63af4f6d19be117e90bd73eb1d62cf831c6b" [[package]] name = "time-macros" -version = "0.2.22" +version = "0.2.24" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3526739392ec93fd8b359c8e98514cb3e8e021beb4e5f597b00a0221f8ed8a49" +checksum = "30cfb0125f12d9c277f35663a0a33f8c30190f4e4574868a330595412d34ebf3" dependencies = [ "num-conv", "time-core", @@ -6151,7 +6027,7 @@ dependencies = [ "mio", "pin-project-lite", "slab", - "socket2 0.6.0", + "socket2", "tokio-macros", "windows-sys 0.59.0", ] @@ -6167,16 +6043,6 @@ dependencies = [ "syn 2.0.106", ] -[[package]] -name = "tokio-native-tls" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bbae76ab933c85776efabc971569dd6119c580d8f5d448769dec1764bf796ef2" -dependencies = [ - "native-tls", - "tokio", -] - [[package]] name = "tokio-rustls" version = "0.26.2" @@ -6214,18 +6080,31 @@ dependencies = [ [[package]] name = "toml_datetime" -version = "0.6.11" +version = "0.7.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "22cddaf88f4fbc13c51aebbf5f8eceb5c7c5a9da2ac40a13519eb5b0a0e8f11c" +checksum = "a197c0ec7d131bfc6f7e82c8442ba1595aeab35da7adbf05b6b73cd06a16b6be" +dependencies = [ + "serde_core", +] [[package]] name = "toml_edit" -version = "0.22.27" +version = "0.23.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "41fe8c660ae4257887cf66394862d21dbca4a6ddd26f04a3560410406a2f819a" +checksum = "c2ad0b7ae9cfeef5605163839cb9221f453399f15cfb5c10be9885fcf56611f9" dependencies = [ - "indexmap 2.10.0", + "indexmap 2.11.3", "toml_datetime", + "toml_parser", + "winnow", +] + +[[package]] +name = "toml_parser" +version = "1.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b551886f449aa90d4fe2bdaa9f4a2577ad2dde302c61ecf262d80b116db95c10" +dependencies = [ "winnow", ] @@ -6328,14 +6207,14 @@ dependencies = [ [[package]] name = "tracing-subscriber" -version = "0.3.19" +version = "0.3.20" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e8189decb5ac0fa7bc8b96b7cb9b2701d60d48805aca84a238004d665fcc4008" +checksum = "2054a14f5307d601f88daf0553e1cbf472acc4f2c51afab632431cdcd72124d5" dependencies = [ "matchers", "nu-ansi-term", "once_cell", - "regex", + "regex-automata", "sharded-slab", "smallvec", "thread_local", @@ -6382,9 +6261,9 @@ checksum = "eaea85b334db583fe3274d12b4cd1880032beab409c0d774be044d4480ab9a94" [[package]] name = "unicode-ident" -version = "1.0.18" +version = "1.0.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5a5f39404a5da50712a4c1eecf25e90dd62b613502b7e925fd4e4d19b5c96512" +checksum = "f63a545481291138910575129486daeaf8ac54aee4387fe7906919f7830c7d9d" [[package]] name = "unicode-segmentation" @@ -6428,13 +6307,14 @@ checksum = "8ecb6da28b8a351d773b68d5825ac39017e680750f980f3a1a85cd8dd28a47c1" [[package]] name = "url" -version = "2.5.4" +version = "2.5.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "32f8b686cadd1473f4bd0117a5d28d36b1ade384ea9b5069a1c40aefed7fda60" +checksum = "08bc136a29a3d1758e07a9cca267be308aeebf5cfd5a10f3f67ab2097683ef5b" dependencies = [ "form_urlencoded", "idna", "percent-encoding", + "serde", ] [[package]] @@ -6451,9 +6331,9 @@ checksum = "06abde3611657adf66d383f00b093d7faecc7fa57071cce2578660c9f1010821" [[package]] name = "uuid" -version = "1.18.0" +version = "1.18.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f33196643e165781c20a5ead5582283a7dacbb87855d867fbc2df3f81eddc1be" +checksum = "2f87b8aa10b915a06587d0dec516c282ff295b475d94abf425d62b57710070a2" dependencies = [ "js-sys", "wasm-bindgen", @@ -6465,12 +6345,6 @@ version = "0.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ba73ea9cf16a25df0c8caa16c51acb937d5712a8429db78a3ee29d5dcacd3a65" -[[package]] -name = "vcpkg" -version = "0.2.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "accd4ea62f7bb7a82fe23066fb0957d48ef677f6eeb8215f372f52e48bb32426" - [[package]] name = "version_check" version = "0.9.5" @@ -6503,30 +6377,40 @@ checksum = "ccf3ec651a847eb01de73ccad15eb7d99f80485de043efb2f370cd654f4ea44b" [[package]] name = "wasi" -version = "0.14.2+wasi-0.2.4" +version = "0.14.7+wasi-0.2.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "883478de20367e224c0090af9cf5f9fa85bed63a95c1abf3afc5c083ebc06e8c" +dependencies = [ + "wasip2", +] + +[[package]] +name = "wasip2" +version = "1.0.1+wasi-0.2.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9683f9a5a998d873c0d21fcbe3c083009670149a8fab228644b8bd36b2c48cb3" +checksum = "0562428422c63773dad2c345a1882263bbf4d65cf3f42e90921f787ef5ad58e7" dependencies = [ - "wit-bindgen-rt", + "wit-bindgen", ] [[package]] name = "wasm-bindgen" -version = "0.2.100" +version = "0.2.102" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1edc8929d7499fc4e8f0be2262a241556cfc54a0bea223790e71446f2aab1ef5" +checksum = "4ad224d2776649cfb4f4471124f8176e54c1cca67a88108e30a0cd98b90e7ad3" dependencies = [ "cfg-if", "once_cell", "rustversion", "wasm-bindgen-macro", + "wasm-bindgen-shared", ] [[package]] name = "wasm-bindgen-backend" -version = "0.2.100" +version = "0.2.102" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2f0a0651a5c2bc21487bde11ee802ccaf4c51935d0d3d42a6101f98161700bc6" +checksum = "3a1364104bdcd3c03f22b16a3b1c9620891469f5e9f09bc38b2db121e593e732" dependencies = [ "bumpalo", "log", @@ -6538,9 +6422,9 @@ dependencies = [ [[package]] name = "wasm-bindgen-futures" -version = "0.4.50" +version = "0.4.52" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "555d470ec0bc3bb57890405e5d4322cc9ea83cebb085523ced7be4144dac1e61" +checksum = "9c0a08ecf5d99d5604a6666a70b3cde6ab7cc6142f5e641a8ef48fc744ce8854" dependencies = [ "cfg-if", "js-sys", @@ -6551,9 +6435,9 @@ dependencies = [ [[package]] name = "wasm-bindgen-macro" -version = "0.2.100" +version = "0.2.102" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7fe63fc6d09ed3792bd0897b314f53de8e16568c2b3f7982f468c0bf9bd0b407" +checksum = "0d7ab4ca3e367bb1ed84ddbd83cc6e41e115f8337ed047239578210214e36c76" dependencies = [ "quote", "wasm-bindgen-macro-support", @@ -6561,9 +6445,9 @@ dependencies = [ [[package]] name = "wasm-bindgen-macro-support" -version = "0.2.100" +version = "0.2.102" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ae87ea40c9f689fc23f209965b6fb8a99ad69aeeb0231408be24920604395de" +checksum = "4a518014843a19e2dbbd0ed5dfb6b99b23fb886b14e6192a00803a3e14c552b0" dependencies = [ "proc-macro2", "quote", @@ -6574,18 +6458,18 @@ dependencies = [ [[package]] name = "wasm-bindgen-shared" -version = "0.2.100" +version = "0.2.102" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1a05d73b933a847d6cccdda8f838a22ff101ad9bf93e33684f39c1f5f0eece3d" +checksum = "255eb0aa4cc2eea3662a00c2bbd66e93911b7361d5e0fcd62385acfd7e15dcee" dependencies = [ "unicode-ident", ] [[package]] name = "wasmtimer" -version = "0.4.2" +version = "0.4.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d8d49b5d6c64e8558d9b1b065014426f35c18de636895d24893dbbd329743446" +checksum = "1c598d6b99ea013e35844697fc4670d08339d5cda15588f193c6beedd12f644b" dependencies = [ "futures", "js-sys", @@ -6597,9 +6481,9 @@ dependencies = [ [[package]] name = "web-sys" -version = "0.3.77" +version = "0.3.79" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "33b6dd2ef9186f1f2072e409e99cd22a975331a6b3591b12c764e0e55c60d5d2" +checksum = "50462a022f46851b81d5441d1a6f5bac0b21a1d72d64bd4906fbdd4bf7230ec7" dependencies = [ "js-sys", "wasm-bindgen", @@ -6648,13 +6532,13 @@ checksum = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f" [[package]] name = "windows-core" -version = "0.61.2" +version = "0.62.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c0fdd3ddb90610c7638aa2b3a3ab2904fb9e5cdbecc643ddb3647212781c4ae3" +checksum = "57fe7168f7de578d2d8a05b07fd61870d2e73b4020e9f49aa00da8471723497c" dependencies = [ "windows-implement", "windows-interface", - "windows-link", + "windows-link 0.2.0", "windows-result", "windows-strings", ] @@ -6687,22 +6571,28 @@ version = "0.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "5e6ad25900d524eaabdbbb96d20b4311e1e7ae1699af4fb28c17ae66c80d798a" +[[package]] +name = "windows-link" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "45e46c0661abb7180e7b9c281db115305d49ca1709ab8242adf09666d2173c65" + [[package]] name = "windows-result" -version = "0.3.4" +version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "56f42bd332cc6c8eac5af113fc0c1fd6a8fd2aa08a0119358686e5160d0586c6" +checksum = "7084dcc306f89883455a206237404d3eaf961e5bd7e0f312f7c91f57eb44167f" dependencies = [ - "windows-link", + "windows-link 0.2.0", ] [[package]] name = "windows-strings" -version = "0.4.2" +version = "0.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "56e6c93f3a0c3b36176cb1327a4958a0353d5d166c2a35cb268ace15e91d3b57" +checksum = "7218c655a553b0bed4426cf54b20d7ba363ef543b52d515b3e48d7fd55318dda" dependencies = [ - "windows-link", + "windows-link 0.2.0", ] [[package]] @@ -6732,6 +6622,15 @@ dependencies = [ "windows-targets 0.53.3", ] +[[package]] +name = "windows-sys" +version = "0.61.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e201184e40b2ede64bc2ea34968b28e33622acdbbf37104f0e4a33f7abe657aa" +dependencies = [ + "windows-link 0.2.0", +] + [[package]] name = "windows-targets" version = "0.52.6" @@ -6754,7 +6653,7 @@ version = "0.53.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d5fe6031c4041849d7c496a8ded650796e7b6ecc19df1a431c1a363342e5dc91" dependencies = [ - "windows-link", + "windows-link 0.1.3", "windows_aarch64_gnullvm 0.53.0", "windows_aarch64_msvc 0.53.0", "windows_i686_gnu 0.53.0", @@ -6863,21 +6762,18 @@ checksum = "271414315aff87387382ec3d271b52d7ae78726f5d44ac98b4f4030c91880486" [[package]] name = "winnow" -version = "0.7.12" +version = "0.7.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f3edebf492c8125044983378ecb5766203ad3b4c2f7a922bd7dd207f6d443e95" +checksum = "21a0236b59786fed61e2a80582dd500fe61f18b5dca67a4a067d0bc9039339cf" dependencies = [ "memchr", ] [[package]] -name = "wit-bindgen-rt" -version = "0.39.0" +name = "wit-bindgen" +version = "0.46.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6f42320e61fe2cfd34354ecb597f86f413484a798ba44a8ca1165c58d42da6c1" -dependencies = [ - "bitflags", -] +checksum = "f17a85883d4e6d00e8a97c586de764dabcc06133f7f1d55dce5cdc070ad7fe59" [[package]] name = "writeable" @@ -6920,18 +6816,18 @@ dependencies = [ [[package]] name = "zerocopy" -version = "0.8.26" +version = "0.8.27" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1039dd0d3c310cf05de012d8a39ff557cb0d23087fd44cad61df08fc31907a2f" +checksum = "0894878a5fa3edfd6da3f88c4805f4c8558e2b996227a3d864f47fe11e38282c" dependencies = [ "zerocopy-derive", ] [[package]] name = "zerocopy-derive" -version = "0.8.26" +version = "0.8.27" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9ecf5b4cc5364572d7f4c329661bcc82724222973f2cab6f050a4e5c22f75181" +checksum = "88d2b8d9c68ad2b9e4340d7832716a4d21a22a1154777ad56ea55c51a9cf3831" dependencies = [ "proc-macro2", "quote", @@ -7032,9 +6928,9 @@ dependencies = [ [[package]] name = "zstd-sys" -version = "2.0.15+zstd.1.5.7" +version = "2.0.16+zstd.1.5.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eb81183ddd97d0c74cedf1d50d85c8d08c1b8b68ee863bdee9e706eedba1a237" +checksum = "91e19ebc2adc8f83e43039e79776e3fda8ca919132d68a1fed6a5faca2683748" dependencies = [ "cc", "pkg-config", diff --git a/Cargo.toml b/Cargo.toml index 9626168d..d425a48b 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -23,24 +23,24 @@ repository = "https://github.com/scroll-tech/stateless-block-verifier" [workspace.dependencies] # https://github.com/alloy-rs/alloy -alloy = { version = "1.0", default-features = false } -alloy-consensus = { version = "1.0", default-features = false } -alloy-eips = { version = "1.0", default-features = false } -alloy-network = { version = "1.0", default-features = false } -alloy-provider = { version = "1.0", default-features = false } -alloy-rpc-client = { version = "1.0", default-features = false } -alloy-rpc-types-eth = { version = "1.0", default-features = false } -alloy-rpc-types-debug = { version = "1.0", default-features = false } -alloy-serde = { version = "1.0", default-features = false } -alloy-transport = { version = "1.0", default-features = false } +alloy = { version = "1.0.30", default-features = false } +alloy-consensus = { version = "1.0.30", default-features = false } +alloy-eips = { version = "1.0.30", default-features = false } +alloy-network = { version = "1.0.30", default-features = false } +alloy-provider = { version = "1.0.30", default-features = false } +alloy-rpc-client = { version = "1.0.30", default-features = false } +alloy-rpc-types-eth = { version = "1.0.30", default-features = false } +alloy-rpc-types-debug = { version = "1.0.30", default-features = false } +alloy-serde = { version = "1.0.30", default-features = false } +alloy-transport = { version = "1.0.30", default-features = false } # https://github.com/alloy-rs/rlp -alloy-rlp = { version = "0.3", default-features = false } +alloy-rlp = { version = "0.3.10", default-features = false } # https://github.com/alloy-rs/trie -alloy-trie = { version = "0.9", default-features = false } +alloy-trie = { version = "0.9.1", default-features = false } # https://github.com/alloy-rs/core -alloy-primitives = { version = "1.3", default-features = false, features = ["map-hashbrown", "map-fxhash"] } +alloy-primitives = { version = "1.3.1", default-features = false, features = ["map-hashbrown", "map-fxhash"] } # https://github.com/alloy-rs/evm -alloy-evm = { version = "0.17", default-features = false } +alloy-evm = { version = "0.20.1", default-features = false } revm-scroll = { git = "https://github.com/scroll-tech/scroll-revm", default-features = false } @@ -83,7 +83,6 @@ scroll-alloy-network = { git = "https://github.com/scroll-tech/reth", branch = " #scroll-alloy-network = { path = "../reth/crates/scroll/alloy/network", default-features = false } openvm-ecc-guest = { git = "https://github.com/openvm-org/openvm.git", tag = "v1.4.0" } -openvm-keccak256 = { git = "https://github.com/openvm-org/openvm.git", tag = "v1.4.0" } openvm-sha2 = { git = "https://github.com/openvm-org/openvm.git", tag = "v1.4.0" } openvm-pairing = { git = "https://github.com/openvm-org/openvm.git", tag = "v1.4.0" } openvm-k256 = { package = "k256", git = "https://github.com/openvm-org/openvm.git", tag = "v1.4.0" } @@ -94,13 +93,11 @@ async-trait = "0.1" auto_impl = "1.2" console = "0.16" futures = "0.3" -hashbrown = { version = "0.15", default-features = false } indicatif = "0.18" itertools = "0.14" rkyv = "0.8" rustc-hash = "2.1" thiserror = "2.0" -tiny-keccak = "2.0" url = ">=2.5.3" rstest = "0.26" cfg-if = "1.0" diff --git a/crates/core/src/executor/ethereum.rs b/crates/core/src/executor/ethereum.rs index 53cb9c4a..0315e53a 100644 --- a/crates/core/src/executor/ethereum.rs +++ b/crates/core/src/executor/ethereum.rs @@ -1,36 +1,19 @@ use crate::{EvmDatabase, VerificationError}; use sbv_kv::KeyValueStoreGet; -use sbv_precompile::PrecompileProvider; use sbv_primitives::{ B256, Bytes, chainspec::ChainSpec, types::{ - evm::precompiles::PrecompilesMap, reth::{ - evm::{ - ConfigureEvm, Database, EthEvm, EthEvmConfig, EvmEnv, EvmFactory, - eth::EthEvmContext, - execute::Executor, - revm::{ - Context, Inspector, MainBuilder, MainContext, - context::{ - BlockEnv, CfgEnv, TxEnv, - result::{EVMError, HaltReason}, - }, - inspector::NoOpInspector, - }, - }, + evm::{ConfigureEvm, EthEvmConfig, execute::Executor}, execution_types::BlockExecutionOutput, primitives::{Block, Receipt, RecoveredBlock}, }, - revm::{SpecId, database::CacheDB, precompile::PrecompileSpecId}, + revm::database::CacheDB, }, }; use std::sync::Arc; -/// Ethereum-related EVM configuration with [`SbvEthEvmFactory`] as the factory. -pub type EvmConfig = EthEvmConfig; - /// EVM executor that handles the block. #[derive(Debug)] pub struct EvmExecutor<'a, CodeDb, BlockHashProvider> { @@ -59,7 +42,7 @@ impl, BlockHashProvider: KeyValueStoreGet< { /// Handle the block with the given witness pub fn execute(self) -> Result, VerificationError> { - let provider = EvmConfig::new_with_evm_factory(self.chain_spec.clone(), SbvEthEvmFactory); + let provider = EthEvmConfig::new(self.chain_spec.clone()); let output = cycle_track!( provider.executor(CacheDB::new(self.db)).execute(self.block), @@ -69,53 +52,3 @@ impl, BlockHashProvider: KeyValueStoreGet< Ok(output) } } - -/// Factory producing [`EthEvm`]. -#[derive(Debug, Default, Clone, Copy)] -#[non_exhaustive] -pub struct SbvEthEvmFactory; - -impl EvmFactory for SbvEthEvmFactory { - type Evm>> = EthEvm; - type Context = Context; - type Tx = TxEnv; - type Error = EVMError; - type HaltReason = HaltReason; - type Spec = SpecId; - type Precompiles = PrecompilesMap; - - fn create_evm(&self, db: DB, input: EvmEnv) -> Self::Evm { - let spec_id = input.cfg_env.spec; - EthEvm::new( - Context::mainnet() - .with_block(input.block_env) - .with_cfg(input.cfg_env) - .with_db(db) - .build_mainnet_with_inspector(NoOpInspector {}) - .with_precompiles(PrecompileProvider::with_spec( - PrecompileSpecId::from_spec_id(spec_id), - )), - false, - ) - } - - fn create_evm_with_inspector>>( - &self, - db: DB, - input: EvmEnv, - inspector: I, - ) -> Self::Evm { - let spec_id = input.cfg_env.spec; - EthEvm::new( - Context::mainnet() - .with_block(input.block_env) - .with_cfg(input.cfg_env) - .with_db(db) - .build_mainnet_with_inspector(inspector) - .with_precompiles(PrecompileProvider::with_spec( - PrecompileSpecId::from_spec_id(spec_id), - )), - true, - ) - } -} diff --git a/crates/core/src/executor/mod.rs b/crates/core/src/executor/mod.rs index a9284f88..ea8f88a5 100644 --- a/crates/core/src/executor/mod.rs +++ b/crates/core/src/executor/mod.rs @@ -1,9 +1,9 @@ #[cfg(not(feature = "scroll"))] mod ethereum; #[cfg(not(feature = "scroll"))] -pub use ethereum::{EvmConfig, EvmExecutor, SbvEthEvmFactory}; +pub use ethereum::EvmExecutor; #[cfg(feature = "scroll")] mod scroll; #[cfg(feature = "scroll")] -pub use scroll::{EvmConfig, EvmExecutor}; +pub use scroll::EvmExecutor; diff --git a/crates/core/src/executor/scroll.rs b/crates/core/src/executor/scroll.rs index 3800fc47..69aa4b2c 100644 --- a/crates/core/src/executor/scroll.rs +++ b/crates/core/src/executor/scroll.rs @@ -5,19 +5,15 @@ use sbv_primitives::{ chainspec::ChainSpec, types::{ reth::{ - evm::{ConfigureEvm, EthEvmConfig, RethReceiptBuilder}, + evm::{ConfigureEvm, EthEvmConfig}, execution_types::BlockExecutionOutput, - primitives::{Block, EthPrimitives, Receipt, RecoveredBlock}, + primitives::{Block, Receipt, RecoveredBlock}, }, revm::database::CacheDB, }, }; use std::sync::Arc; -/// Ethereum-related EVM configuration. -pub type EvmConfig = - EthEvmConfig; - /// EVM executor that handles the block. #[derive(Debug)] pub struct EvmExecutor<'a, CodeDb, BlockHashProvider, CompressionRatios> { @@ -60,7 +56,7 @@ impl< revm::database::{State, states::bundle_state::BundleRetention}, }; - let provider = EvmConfig::new(self.chain_spec.clone(), Default::default()); + let provider = EthEvmConfig::scroll(self.chain_spec.clone()); let factory = provider.block_executor_factory(); let mut db = State::builder() diff --git a/crates/core/src/lib.rs b/crates/core/src/lib.rs index a3f38692..88c1c367 100644 --- a/crates/core/src/lib.rs +++ b/crates/core/src/lib.rs @@ -14,9 +14,7 @@ mod error; pub use error::VerificationError; mod executor; -#[cfg(not(feature = "scroll"))] -pub use executor::SbvEthEvmFactory; -pub use executor::{EvmConfig, EvmExecutor}; +pub use executor::EvmExecutor; pub mod verifier; diff --git a/crates/core/src/witness.rs b/crates/core/src/witness.rs index a64ac726..33c6b5f2 100644 --- a/crates/core/src/witness.rs +++ b/crates/core/src/witness.rs @@ -237,55 +237,3 @@ impl BlockWitnessChunkExt for [BlockWitness] { .all(|(a, b)| a.header.state_root == b.prev_state_root) } } - -#[cfg(test)] -#[cfg(feature = "scroll")] -mod tests { - use super::*; - use std::{collections::BTreeSet, ffi::OsStr, path::PathBuf}; - - #[rstest::rstest] - fn serde_scroll_blocks_roundtrip( - #[files("../../testdata/scroll_witness/**/*.json")] - #[mode = path] - path: PathBuf, - ) { - let file_content = std::fs::read_to_string(path).unwrap(); - let witness: BlockWitness = serde_json::from_str(&file_content).unwrap(); - let serialized = serde_json::to_string(&witness).unwrap(); - let deserialized: BlockWitness = serde_json::from_str(&serialized).unwrap(); - assert_eq!(witness, deserialized); - } - - #[rstest::rstest] - fn serde_scroll_blocks_legacy_compatibility( - #[files("../../testdata/scroll_witness/**/*.json")] - #[mode = path] - path: PathBuf, - ) { - let file_content = std::fs::read_to_string(&path).unwrap(); - let witness: BlockWitness = serde_json::from_str(&file_content).unwrap(); - - let base_dir = path - .ancestors() - .find(|p| p.file_name().unwrap() == OsStr::new("testdata")) - .unwrap(); - let filename = path.file_name().unwrap(); - let harfork = path.parent().unwrap().file_name().unwrap(); - let legacy_path = base_dir - .join("legacy") - .join("scroll_witness") - .join(harfork) - .join(filename); - let legacy_content = std::fs::read_to_string(legacy_path).unwrap(); - let mut legacy_witness: sbv_primitives::legacy_types::BlockWitness = - serde_json::from_str(&legacy_content).unwrap(); - legacy_witness.states = Vec::from_iter(BTreeSet::from_iter(legacy_witness.states)); - legacy_witness.codes = Vec::from_iter(BTreeSet::from_iter(legacy_witness.codes)); - - let mut legacy_converted = witness.into_legacy(); - legacy_converted.states = Vec::from_iter(BTreeSet::from_iter(legacy_converted.states)); - legacy_converted.codes = Vec::from_iter(BTreeSet::from_iter(legacy_converted.codes)); - assert_eq!(legacy_converted, legacy_witness); - } -} diff --git a/crates/kv/Cargo.toml b/crates/kv/Cargo.toml index b49956b5..d65b1702 100644 --- a/crates/kv/Cargo.toml +++ b/crates/kv/Cargo.toml @@ -13,7 +13,5 @@ workspace = true [dependencies] auto_impl.workspace = true -hashbrown = { workspace = true, features = [ - "rayon", -] } # reth use rayon::IntoParallelIterator +alloy-primitives.workspace = true rustc-hash.workspace = true diff --git a/crates/kv/src/lib.rs b/crates/kv/src/lib.rs index 94d5a2b4..c0018404 100644 --- a/crates/kv/src/lib.rs +++ b/crates/kv/src/lib.rs @@ -4,13 +4,12 @@ use auto_impl::auto_impl; use std::{borrow::Borrow, hash::Hash}; mod imps; -pub use hashbrown; pub use imps::{nohash, null}; /// HashMap -pub type HashMap = hashbrown::HashMap; +pub type HashMap = alloy_primitives::map::HashMap; /// HashSet -pub type HashSet = hashbrown::HashSet; +pub type HashSet = alloy_primitives::map::HashSet; /// Key-Value store insert trait #[auto_impl(&mut, Box)] diff --git a/crates/precompile/Cargo.toml b/crates/precompile/Cargo.toml index 47872a9c..defea779 100644 --- a/crates/precompile/Cargo.toml +++ b/crates/precompile/Cargo.toml @@ -12,7 +12,6 @@ repository.workspace = true sbv-primitives = { workspace = true, features = ["evm-types", "revm-types"] } openvm-ecc-guest = { workspace = true, optional = true } -openvm-keccak256 = { workspace = true, optional = true } openvm-k256 = { workspace = true, optional = true } openvm-sha2 = { workspace = true, optional = true } openvm-pairing = { workspace = true, optional = true } @@ -31,41 +30,32 @@ scroll = [ ] scroll-openvm = [ "scroll", - "openvm-bn128", + "openvm-bn254", "openvm-sha256" ] ethereum-openvm = [ - "openvm-bn128", + "openvm-bn254", "openvm-kzg", "openvm-secp256k1", "openvm-sha256", ] -bn128 = [] # marker, won't be used in dependencies -openvm-bn128 = [ - "bn128", +openvm-bn254 = [ "dep:openvm-ecc-guest", "dep:openvm-pairing", "openvm-pairing/bn254", ] -kzg = [] # marker, won't be used in dependencies openvm-kzg = [ - "kzg", "dep:openvm-kzg", ] -secp256k1 = [] # marker, won't be used in dependencies openvm-secp256k1 = [ - "secp256k1", "dep:openvm-ecc-guest", - "dep:openvm-keccak256", "dep:openvm-k256", ] -sha256 = [] openvm-sha256 = [ - "sha256", "dep:openvm-sha2" ] diff --git a/crates/precompile/src/imps/bn128/openvm.rs b/crates/precompile/src/bn254.rs similarity index 80% rename from crates/precompile/src/imps/bn128/openvm.rs rename to crates/precompile/src/bn254.rs index 41ea36ce..90d948b8 100644 --- a/crates/precompile/src/imps/bn128/openvm.rs +++ b/crates/precompile/src/bn254.rs @@ -37,9 +37,9 @@ const G1_LEN: usize = 2 * FQ_LEN; #[inline] fn read_fq(input: &[u8]) -> Result { if input.len() < FQ_LEN { - Err(PrecompileError::Bn128FieldPointNotAMember) + Err(PrecompileError::Bn254FieldPointNotAMember) } else { - Fp::from_be_bytes(&input[..32]).ok_or(PrecompileError::Bn128FieldPointNotAMember) + Fp::from_be_bytes(&input[..32]).ok_or(PrecompileError::Bn254FieldPointNotAMember) } } @@ -62,7 +62,7 @@ fn read_fq2(input: &[u8]) -> Result { #[inline] fn new_g1_affine_point(px: Fp, py: Fp) -> Result { - G1Affine::from_xy(px, py).ok_or(PrecompileError::Bn128AffineGFailedToCreate) + G1Affine::from_xy(px, py).ok_or(PrecompileError::Bn254AffineGFailedToCreate) } /// Reads a G1 point from the input slice. @@ -114,7 +114,7 @@ pub(super) fn read_g2_point(input: &[u8]) -> Result { let ba = read_fq2(&input[0..FQ2_LEN])?; let bb = read_fq2(&input[FQ2_LEN..2 * FQ2_LEN])?; - G2Affine::from_xy(ba, bb).ok_or(PrecompileError::Bn128AffineGFailedToCreate) + G2Affine::from_xy(ba, bb).ok_or(PrecompileError::Bn254AffineGFailedToCreate) } /// Reads a scalar from the input slice @@ -153,22 +153,31 @@ pub(super) fn g1_point_mul(p: G1Affine, fr: Scalar) -> G1Affine { /// Note: If the input is empty, this function returns true. /// This is different to EIP2537 which disallows the empty input. #[inline] -pub(super) fn pairing_check(pairs: &[(G1Affine, G2Affine)]) -> bool { - if pairs.is_empty() { - return true; +pub(super) fn pairing_check(pairs: &[(&[u8], &[u8])]) -> Result { + let mut g1_points = Vec::with_capacity(pairs.len()); + let mut g2_points = Vec::with_capacity(pairs.len()); + + for (g1_bytes, g2_bytes) in pairs { + let g1_is_zero = g1_bytes.iter().all(|i| *i == 0); + let g2_is_zero = g2_bytes.iter().all(|i| *i == 0); + + let g1 = read_g1_point(g1_bytes)?; + let g2 = read_g2_point(g2_bytes)?; + + let (g1x, g1y) = g1.into_coords(); + let (g2x, g2y) = g2.into_coords(); + + // Skip pairs where either point is at infinity + if !g1_is_zero && !g2_is_zero { + let g1 = AffinePoint::new(g1x, g1y); + let g2 = AffinePoint::new(g2x, g2y); + g1_points.push(g1); + g2_points.push(g2); + } } - let (g1_points, g2_points): (Vec<_>, Vec<_>) = pairs - .iter() - .cloned() - .map(|(g1, g2)| { - let (g1_x, g1_y) = g1.into_coords(); - let g1 = AffinePoint::new(g1_x, g1_y); - - let (g2_x, g2_y) = g2.into_coords(); - let g2 = AffinePoint::new(g2_x, g2_y); - (g1, g2) - }) - .unzip(); - - Bn254::pairing_check(&g1_points, &g2_points).is_ok() + if g1_points.is_empty() { + return Ok(true); + } + + Ok(Bn254::pairing_check(&g1_points, &g2_points).is_ok()) } diff --git a/crates/precompile/src/ethereum.rs b/crates/precompile/src/ethereum.rs deleted file mode 100644 index 355f5333..00000000 --- a/crates/precompile/src/ethereum.rs +++ /dev/null @@ -1,38 +0,0 @@ -use super::PrecompileProvider; -use sbv_primitives::types::{ - evm::precompiles::PrecompilesMap, - revm::precompile::{PrecompileSpecId, Precompiles}, -}; - -#[cfg(not(feature = "ethereum-openvm"))] -impl PrecompileProvider { - /// Returns the precompiles map for the given spec. - #[inline] - pub fn with_spec(spec: PrecompileSpecId) -> PrecompilesMap { - PrecompilesMap::from_static(Precompiles::new(spec)) - } -} - -#[cfg(feature = "ethereum-openvm")] -impl PrecompileProvider { - /// Returns the precompiles map for the given spec. - pub fn with_spec(spec: PrecompileSpecId) -> PrecompilesMap { - use crate::imps::{bn128, kzg_point_evaluation, secp256k1, sha256}; - - let mut precompiles = Precompiles::new(spec).to_owned(); - - precompiles.extend([secp256k1::ECRECOVER, sha256::HOMESTEAD]); - - if spec >= PrecompileSpecId::ISTANBUL { - precompiles.extend([bn128::add::ISTANBUL, bn128::mul::ISTANBUL]); - } else if spec >= PrecompileSpecId::BYZANTIUM { - precompiles.extend([bn128::add::BYZANTIUM, bn128::mul::BYZANTIUM]); - } - - if spec >= PrecompileSpecId::CANCUN { - precompiles.extend([kzg_point_evaluation::POINT_EVALUATION]); - } - - PrecompilesMap::new(std::borrow::Cow::Owned(precompiles)) - } -} diff --git a/crates/precompile/src/imps/bn128/mod.rs b/crates/precompile/src/imps/bn128/mod.rs deleted file mode 100644 index 1b74020d..00000000 --- a/crates/precompile/src/imps/bn128/mod.rs +++ /dev/null @@ -1,255 +0,0 @@ -//! BN128 precompiles added in [`EIP-1962`](https://eips.ethereum.org/EIPS/eip-1962) -use sbv_primitives::types::revm::precompile::{PrecompileWithAddress, bn128}; - -#[cfg(not(feature = "openvm-bn128"))] -pub use bn128::{run_add, run_mul, run_pair}; -#[cfg(feature = "openvm-bn128")] -pub use imps::{run_add, run_mul, run_pair}; - -#[cfg(feature = "openvm-bn128")] -mod openvm; - -/// Bn128 add precompile -pub mod add { - use super::*; - - pub use bn128::add::{ADDRESS, BYZANTIUM_ADD_GAS_COST, ISTANBUL_ADD_GAS_COST}; - - /// Bn128 add precompile with ISTANBUL gas rules - pub const ISTANBUL: PrecompileWithAddress = - PrecompileWithAddress(ADDRESS, |input, gas_limit| { - run_add(input, ISTANBUL_ADD_GAS_COST, gas_limit) - }); - - /// Bn128 add precompile with BYZANTIUM gas rules - pub const BYZANTIUM: PrecompileWithAddress = - PrecompileWithAddress(ADDRESS, |input, gas_limit| { - run_add(input, BYZANTIUM_ADD_GAS_COST, gas_limit) - }); -} - -/// Bn128 mul precompile -pub mod mul { - use super::*; - - pub use bn128::mul::{ADDRESS, BYZANTIUM_MUL_GAS_COST, ISTANBUL_MUL_GAS_COST}; - - /// Bn128 mul precompile with ISTANBUL gas rules - pub const ISTANBUL: PrecompileWithAddress = - PrecompileWithAddress(ADDRESS, |input, gas_limit| { - run_mul(input, ISTANBUL_MUL_GAS_COST, gas_limit) - }); - - /// Bn128 mul precompile with BYZANTIUM gas rules - pub const BYZANTIUM: PrecompileWithAddress = - PrecompileWithAddress(ADDRESS, |input, gas_limit| { - run_mul(input, BYZANTIUM_MUL_GAS_COST, gas_limit) - }); -} - -/// Bn128 pair precompile -pub mod pair { - use super::*; - - pub use bn128::pair::{ - ADDRESS, BYZANTIUM_PAIR_BASE, BYZANTIUM_PAIR_PER_POINT, ISTANBUL_PAIR_BASE, - ISTANBUL_PAIR_PER_POINT, - }; - - /// Bn128 pair precompile with ISTANBUL gas rules - pub const ISTANBUL: PrecompileWithAddress = - PrecompileWithAddress(ADDRESS, |input, gas_limit| { - run_pair( - input, - ISTANBUL_PAIR_PER_POINT, - ISTANBUL_PAIR_BASE, - gas_limit, - ) - }); - - /// Bn128 pair precompile with BYZANTIUM gas rules - pub const BYZANTIUM: PrecompileWithAddress = - PrecompileWithAddress(ADDRESS, |input, gas_limit| { - run_pair( - input, - BYZANTIUM_PAIR_PER_POINT, - BYZANTIUM_PAIR_BASE, - gas_limit, - ) - }); - - #[cfg(feature = "scroll")] - #[cfg_attr(docsrs, doc(cfg(feature = "scroll")))] - pub use scroll::*; - #[cfg(feature = "scroll")] - mod scroll { - use super::*; - use bn128::PAIR_ELEMENT_LEN; - use sbv_primitives::types::revm::precompile::{PrecompileError, PrecompileResult}; - - /// The number of pairing inputs per pairing operation. If the inputs provided to the precompile - /// call are < 4, we append (G1::infinity, G2::generator) until we have the required no. of - /// inputs. - const BERNOULLI_LEN_LIMIT: usize = 4; - - /// The Bn128 pair precompile with BERNOULLI input rules. - pub const BERNOULLI: PrecompileWithAddress = PrecompileWithAddress(ADDRESS, bernoulli_run); - - /// The bernoulli Bn128 pair precompile implementation. - /// - /// # Errors - /// - `PrecompileError::Other("BN128PairingInputOverflow: input overflow".into())` if the input - /// length is greater than 768 bytes. - fn bernoulli_run(input: &[u8], gas_limit: u64) -> PrecompileResult { - if input.len() > BERNOULLI_LEN_LIMIT * PAIR_ELEMENT_LEN { - return Err(PrecompileError::Other( - "BN128PairingInputOverflow: input overflow".into(), - )); - } - run_pair( - input, - ISTANBUL_PAIR_PER_POINT, - ISTANBUL_PAIR_BASE, - gas_limit, - ) - } - - /// The Bn128 pair precompile in FEYNMAN hardfork. - pub const FEYNMAN: PrecompileWithAddress = ISTANBUL; - } -} - -#[cfg(feature = "openvm-bn128")] -mod imps { - use super::*; - use openvm::{ - encode_g1_point, g1_point_add, g1_point_mul, pairing_check, read_g1_point, read_g2_point, - read_scalar, - }; - use sbv_primitives::types::revm::precompile::{ - PrecompileError, PrecompileOutput, PrecompileResult, - bn128::{ADD_INPUT_LEN, MUL_INPUT_LEN, PAIR_ELEMENT_LEN}, - utilities::{bool_to_bytes32, right_pad}, - }; - - // Copied from https://github.com/bluealloy/revm/blob/v75/crates/precompile/src/bn128.rs Under MIT License - - /// FQ_LEN specifies the number of bytes needed to represent an - /// Fq element. This is an element in the base field of BN254. - /// - /// Note: The base field is used to define G1 and G2 elements. - const FQ_LEN: usize = 32; - - /// SCALAR_LEN specifies the number of bytes needed to represent an Fr element. - /// This is an element in the scalar field of BN254. - const SCALAR_LEN: usize = 32; - - /// FQ2_LEN specifies the number of bytes needed to represent an - /// Fq^2 element. - /// - /// Note: This is the quadratic extension of Fq, and by definition - /// means we need 2 Fq elements. - const FQ2_LEN: usize = 2 * FQ_LEN; - - /// G1_LEN specifies the number of bytes needed to represent a G1 element. - /// - /// Note: A G1 element contains 2 Fq elements. - const G1_LEN: usize = 2 * FQ_LEN; - /// G2_LEN specifies the number of bytes needed to represent a G2 element. - /// - /// Note: A G2 element contains 2 Fq^2 elements. - const G2_LEN: usize = 2 * FQ2_LEN; - - /// Run the Bn128 add precompile - pub fn run_add(input: &[u8], gas_cost: u64, gas_limit: u64) -> PrecompileResult { - if gas_cost > gas_limit { - return Err(PrecompileError::OutOfGas); - } - - let input = right_pad::(input); - - let p1 = read_g1_point(&input[..G1_LEN])?; - let p2 = read_g1_point(&input[G1_LEN..])?; - let result = g1_point_add(p1, p2); - - let output = encode_g1_point(result); - - Ok(PrecompileOutput::new(gas_cost, output.into())) - } - - /// Run the Bn128 mul precompile - pub fn run_mul(input: &[u8], gas_cost: u64, gas_limit: u64) -> PrecompileResult { - if gas_cost > gas_limit { - return Err(PrecompileError::OutOfGas); - } - - let input = right_pad::(input); - - let p = read_g1_point(&input[..G1_LEN])?; - - let scalar = read_scalar(&input[G1_LEN..G1_LEN + SCALAR_LEN]); - let result = g1_point_mul(p, scalar); - - let output = encode_g1_point(result); - - Ok(PrecompileOutput::new(gas_cost, output.into())) - } - - /// Run the Bn128 pair precompile - pub fn run_pair( - input: &[u8], - pair_per_point_cost: u64, - pair_base_cost: u64, - gas_limit: u64, - ) -> PrecompileResult { - let gas_used = - (input.len() / PAIR_ELEMENT_LEN) as u64 * pair_per_point_cost + pair_base_cost; - if gas_used > gas_limit { - return Err(PrecompileError::OutOfGas); - } - - if input.len() % PAIR_ELEMENT_LEN != 0 { - return Err(PrecompileError::Bn128PairLength); - } - - let elements = input.len() / PAIR_ELEMENT_LEN; - - let mut points = Vec::with_capacity(elements); - - for idx in 0..elements { - // Offset to the start of the pairing element at index `idx` in the byte slice - let start = idx * PAIR_ELEMENT_LEN; - let g1_start = start; - // Offset to the start of the G2 element in the pairing element - // This is where G1 ends. - let g2_start = start + G1_LEN; - - let encoded_g1_element = &input[g1_start..g2_start]; - let encoded_g2_element = &input[g2_start..g2_start + G2_LEN]; - - // If either the G1 or G2 element is the encoded representation - // of the point at infinity, then these two points are no-ops - // in the pairing computation. - // - // Note: we do not skip the validation of these two elements even if - // one of them is the point at infinity because we could have G1 be - // the point at infinity and G2 be an invalid element or vice versa. - // In that case, the precompile should error because one of the elements - // was invalid. - let g1_is_zero = encoded_g1_element.iter().all(|i| *i == 0); - let g2_is_zero = encoded_g2_element.iter().all(|i| *i == 0); - - // Get G1 and G2 points from the input - let a = read_g1_point(encoded_g1_element)?; - let b = read_g2_point(encoded_g2_element)?; - - if !g1_is_zero && !g2_is_zero { - points.push((a, b)); - } - } - - let success = pairing_check(&points); - - Ok(PrecompileOutput::new(gas_used, bool_to_bytes32(success))) - } -} diff --git a/crates/precompile/src/imps/kzg_point_evaluation/mod.rs b/crates/precompile/src/imps/kzg_point_evaluation/mod.rs deleted file mode 100644 index f62e1351..00000000 --- a/crates/precompile/src/imps/kzg_point_evaluation/mod.rs +++ /dev/null @@ -1,23 +0,0 @@ -//! KZG point evaluation precompile added in [`EIP-4844`](https://eips.ethereum.org/EIPS/eip-4844) - -#[cfg(not(any(feature = "c-kzg", feature = "kzg-rs")))] -compile_error!( - "KZG point evaluation precompile requires either the `c-kzg` or `kzg-rs` feature to be enabled." -); - -use sbv_primitives::types::revm::precompile::{PrecompileWithAddress, kzg_point_evaluation}; - -pub use kzg_point_evaluation::{ - ADDRESS, GAS_COST, RETURN_VALUE, VERSIONED_HASH_VERSION_KZG, kzg_to_versioned_hash, -}; - -#[cfg(not(feature = "openvm-kzg"))] -pub use kzg_point_evaluation::{run, verify_kzg_proof}; - -#[cfg(feature = "openvm-kzg")] -mod openvm; -#[cfg(feature = "openvm-kzg")] -pub use openvm::{run, verify_kzg_proof}; - -/// KZG point evaluation precompile, containing address and function to run. -pub const POINT_EVALUATION: PrecompileWithAddress = PrecompileWithAddress(ADDRESS, run); diff --git a/crates/precompile/src/imps/kzg_point_evaluation/openvm.rs b/crates/precompile/src/imps/kzg_point_evaluation/openvm.rs deleted file mode 100644 index 88cd3b2e..00000000 --- a/crates/precompile/src/imps/kzg_point_evaluation/openvm.rs +++ /dev/null @@ -1,72 +0,0 @@ -use sbv_primitives::types::revm::precompile::{ - PrecompileError, PrecompileOutput, PrecompileResult, kzg_point_evaluation, -}; - -/// Verify KZG proof with openvm precompile. -#[inline] -pub fn verify_kzg_proof( - commitment: &openvm_kzg::Bytes48, - z: &openvm_kzg::Bytes32, - y: &openvm_kzg::Bytes32, - proof: &openvm_kzg::Bytes48, -) -> bool { - let env = openvm_kzg::EnvKzgSettings::default(); - let kzg_settings = env.get(); - openvm_kzg::KzgProof::verify_kzg_proof(commitment, z, y, proof, kzg_settings).unwrap_or(false) -} - -/// Run kzg point evaluation precompile. -pub fn run(input: &[u8], gas_limit: u64) -> PrecompileResult { - use kzg_point_evaluation::{GAS_COST, RETURN_VALUE, kzg_to_versioned_hash}; - - if gas_limit < GAS_COST { - return Err(PrecompileError::OutOfGas); - } - - // Verify input length. - if input.len() != 192 { - return Err(PrecompileError::BlobInvalidInputLength); - } - - // Verify commitment matches versioned_hash - let versioned_hash = &input[..32]; - let commitment = &input[96..144]; - if kzg_to_versioned_hash(commitment) != versioned_hash { - return Err(PrecompileError::BlobMismatchedVersion); - } - - // Verify KZG proof with z and y in big endian format - let commitment = as_bytes48(commitment); - let z = as_bytes32(&input[32..64]); - let y = as_bytes32(&input[64..96]); - let proof = as_bytes48(&input[144..192]); - if !verify_kzg_proof(commitment, z, y, proof) { - return Err(PrecompileError::BlobVerifyKzgProofFailed); - } - - // Return FIELD_ELEMENTS_PER_BLOB and BLS_MODULUS as padded 32 byte big endian values - Ok(PrecompileOutput::new(GAS_COST, RETURN_VALUE.into())) -} - -/// Convert a slice to an array of a specific size. -#[inline] -#[track_caller] -fn as_array(bytes: &[u8]) -> &[u8; N] { - bytes.try_into().expect("slice with incorrect length") -} - -/// Convert a slice to a 32 byte big endian array. -#[inline] -#[track_caller] -fn as_bytes32(bytes: &[u8]) -> &openvm_kzg::Bytes32 { - // SAFETY: `#[repr(C)] Bytes32([u8; 32])` - unsafe { &*as_array::<32>(bytes).as_ptr().cast() } -} - -/// Convert a slice to a 48 byte big endian array. -#[inline] -#[track_caller] -fn as_bytes48(bytes: &[u8]) -> &openvm_kzg::Bytes48 { - // SAFETY: `#[repr(C)] Bytes48([u8; 48])` - unsafe { &*as_array::<48>(bytes).as_ptr().cast() } -} diff --git a/crates/precompile/src/imps/mod.rs b/crates/precompile/src/imps/mod.rs deleted file mode 100644 index c284e4fd..00000000 --- a/crates/precompile/src/imps/mod.rs +++ /dev/null @@ -1,15 +0,0 @@ -#[cfg(feature = "bn128")] -#[cfg_attr(docsrs, doc(cfg(feature = "bn128")))] -pub mod bn128; - -#[cfg(feature = "kzg")] -#[cfg_attr(docsrs, doc(cfg(feature = "kzg")))] -pub mod kzg_point_evaluation; - -#[cfg(feature = "secp256k1")] -#[cfg_attr(docsrs, doc(cfg(feature = "secp256k1")))] -pub mod secp256k1; - -#[cfg(feature = "sha256")] -#[cfg_attr(docsrs, doc(cfg(feature = "sha256")))] -pub mod sha256; diff --git a/crates/precompile/src/imps/secp256k1/mod.rs b/crates/precompile/src/imps/secp256k1/mod.rs deleted file mode 100644 index fca120f9..00000000 --- a/crates/precompile/src/imps/secp256k1/mod.rs +++ /dev/null @@ -1,48 +0,0 @@ -//! `ecrecover` precompile. -use sbv_primitives::types::revm::precompile::{self, PrecompileWithAddress, secp256k1}; - -#[cfg(feature = "openvm-secp256k1")] -mod openvm; - -#[cfg(feature = "openvm-secp256k1")] -pub use openvm::ecrecover; -#[cfg(not(feature = "openvm-secp256k1"))] -pub use secp256k1::{ec_recover_run, ecrecover}; - -/// `ecrecover` precompile, containing address and function to run. -pub const ECRECOVER: PrecompileWithAddress = - PrecompileWithAddress(secp256k1::ECRECOVER.0, ec_recover_run); - -// Copied from https://github.com/bluealloy/revm/blob/v75/crates/precompile/src/secp256k1.rs Under MIT License - -/// `ecrecover` precompile function with openvm precompiles. -#[cfg(feature = "openvm-secp256k1")] -pub fn ec_recover_run(input: &[u8], gas_limit: u64) -> precompile::PrecompileResult { - use sbv_primitives::{ - B256, Bytes, - alloy_primitives::B512, - types::revm::precompile::{PrecompileError, PrecompileOutput, utilities::right_pad}, - }; - - const ECRECOVER_BASE: u64 = 3_000; - - if ECRECOVER_BASE > gas_limit { - return Err(PrecompileError::OutOfGas); - } - - let input = right_pad::<128>(input); - - // `v` must be a 32-byte big-endian integer equal to 27 or 28. - if !(input[32..63].iter().all(|&b| b == 0) && matches!(input[63], 27 | 28)) { - return Ok(PrecompileOutput::new(ECRECOVER_BASE, Bytes::new())); - } - - let msg = <&B256>::try_from(&input[0..32]).unwrap(); - let recid = input[63] - 27; - let sig = <&B512>::try_from(&input[64..128]).unwrap(); - - let res = ecrecover(sig, recid, msg); - - let out = res.map(|o| o.to_vec().into()).unwrap_or_default(); - Ok(PrecompileOutput::new(ECRECOVER_BASE, out)) -} diff --git a/crates/precompile/src/imps/sha256.rs b/crates/precompile/src/imps/sha256.rs deleted file mode 100644 index e3064323..00000000 --- a/crates/precompile/src/imps/sha256.rs +++ /dev/null @@ -1,30 +0,0 @@ -//! Hash precompiles, it contains SHA-256 hash precompile -//! More details in [`sha256_run`] -use sbv_primitives::types::revm::precompile::{self, PrecompileWithAddress, hash}; - -#[cfg(not(feature = "openvm-sha256"))] -pub use hash::sha256_run; - -/// The homestead SHA256 precompile implementation with address. -pub const HOMESTEAD: PrecompileWithAddress = PrecompileWithAddress(hash::SHA256.0, sha256_run); - -/// The bernoulli SHA256 precompile implementation with address. -#[cfg(feature = "scroll")] -#[cfg_attr(docsrs, doc(cfg(feature = "scroll")))] -pub const BERNOULLI: PrecompileWithAddress = PrecompileWithAddress(hash::SHA256.0, sha256_run); - -/// Computes the SHA-256 hash of the input data with openvm-sha2 precompile -/// -/// See [`hash::sha256_run`] for more details. -#[cfg(feature = "openvm-sha256")] -pub fn sha256_run(input: &[u8], gas_limit: u64) -> precompile::PrecompileResult { - use precompile::{PrecompileError, PrecompileOutput, calc_linear_cost_u32}; - - let cost = calc_linear_cost_u32(input.len(), 60, 12); - if cost > gas_limit { - Err(PrecompileError::OutOfGas) - } else { - let output = openvm_sha2::sha256(input); - Ok(PrecompileOutput::new(cost, output.to_vec().into())) - } -} diff --git a/crates/precompile/src/kzg_point_evaluation.rs b/crates/precompile/src/kzg_point_evaluation.rs new file mode 100644 index 00000000..b60a9797 --- /dev/null +++ b/crates/precompile/src/kzg_point_evaluation.rs @@ -0,0 +1,40 @@ +/// Verify KZG proof with openvm precompile. +#[inline] +pub fn verify_kzg_proof( + commitment: &[u8; 48], + z: &[u8; 32], + y: &[u8; 32], + proof: &[u8; 48], +) -> bool { + let commitment = as_bytes48(commitment); + let z = as_bytes32(z); + let y = as_bytes32(y); + let proof = as_bytes48(proof); + + let env = openvm_kzg::EnvKzgSettings::default(); + let kzg_settings = env.get(); + openvm_kzg::KzgProof::verify_kzg_proof(commitment, z, y, proof, kzg_settings).unwrap_or(false) +} + +/// Convert a slice to an array of a specific size. +#[inline] +#[track_caller] +fn as_array(bytes: &[u8]) -> &[u8; N] { + bytes.try_into().expect("slice with incorrect length") +} + +/// Convert a slice to a 32 byte big endian array. +#[inline] +#[track_caller] +fn as_bytes32(bytes: &[u8]) -> &openvm_kzg::Bytes32 { + // SAFETY: `#[repr(C)] Bytes32([u8; 32])` + unsafe { &*as_array::<32>(bytes).as_ptr().cast() } +} + +/// Convert a slice to a 48 byte big endian array. +#[inline] +#[track_caller] +fn as_bytes48(bytes: &[u8]) -> &openvm_kzg::Bytes48 { + // SAFETY: `#[repr(C)] Bytes48([u8; 48])` + unsafe { &*as_array::<48>(bytes).as_ptr().cast() } +} diff --git a/crates/precompile/src/lib.rs b/crates/precompile/src/lib.rs index 1b5430c0..c1f167d9 100644 --- a/crates/precompile/src/lib.rs +++ b/crates/precompile/src/lib.rs @@ -1,15 +1,91 @@ //! sbv precompiles provider #![cfg_attr(docsrs, feature(doc_cfg))] -#[cfg(not(feature = "scroll"))] -mod ethereum; -mod imps; -#[cfg(feature = "scroll")] -#[cfg_attr(docsrs, doc(cfg(feature = "scroll")))] -mod scroll; - -#[allow(unused_imports)] -pub use imps::*; - -/// A precompile provider that patches the precompiles when runs on zkVM with OpenVM enabled. -#[derive(Debug, Default, Copy, Clone)] -pub struct PrecompileProvider; +#[cfg(any( + feature = "openvm-bn254", + feature = "openvm-kzg", + feature = "openvm-secp256k1", +))] +use sbv_primitives::types::revm::precompile::PrecompileError; +use sbv_primitives::types::revm::precompile::{Crypto as CryptoInterface, install_crypto}; + +#[cfg(feature = "openvm-bn254")] +mod bn254; +#[cfg(feature = "openvm-kzg")] +mod kzg_point_evaluation; +#[cfg(feature = "openvm-secp256k1")] +mod secp256k1; + +/// revm precompile crypto operations provider +#[derive(Debug)] +pub struct Crypto; + +impl Crypto { + /// Install this as the global crypto provider. + /// + /// # Panics + /// + /// Panics if a crypto provider has already been installed. + pub fn install() { + assert!(install_crypto(Self)); + } +} + +impl CryptoInterface for Crypto { + #[cfg(feature = "openvm-sha256")] + #[inline] + fn sha256(&self, input: &[u8]) -> [u8; 32] { + openvm_sha2::sha256(input) + } + + #[cfg(feature = "openvm-bn254")] + #[inline] + fn bn254_g1_add(&self, p1: &[u8], p2: &[u8]) -> Result<[u8; 64], PrecompileError> { + let p1 = bn254::read_g1_point(p1)?; + let p2 = bn254::read_g1_point(p2)?; + let result = bn254::g1_point_add(p1, p2); + Ok(bn254::encode_g1_point(result)) + } + + #[cfg(feature = "openvm-bn254")] + #[inline] + fn bn254_g1_mul(&self, point: &[u8], scalar: &[u8]) -> Result<[u8; 64], PrecompileError> { + let p = bn254::read_g1_point(point)?; + let fr = bn254::read_scalar(scalar); + let result = bn254::g1_point_mul(p, fr); + Ok(bn254::encode_g1_point(result)) + } + + #[cfg(feature = "openvm-bn254")] + #[inline] + fn bn254_pairing_check(&self, pairs: &[(&[u8], &[u8])]) -> Result { + bn254::pairing_check(pairs) + } + + #[cfg(feature = "openvm-secp256k1")] + #[inline] + fn secp256k1_ecrecover( + &self, + sig: &[u8; 64], + recid: u8, + msg: &[u8; 32], + ) -> Result<[u8; 32], PrecompileError> { + secp256k1::ecrecover(sig, recid, msg) + .ok() + .ok_or_else(|| PrecompileError::other("ecrecover failed")) + } + + #[cfg(feature = "openvm-kzg")] + #[inline] + fn verify_kzg_proof( + &self, + z: &[u8; 32], + y: &[u8; 32], + commitment: &[u8; 48], + proof: &[u8; 48], + ) -> Result<(), PrecompileError> { + if !kzg_point_evaluation::verify_kzg_proof(commitment, z, y, proof) { + return Err(PrecompileError::BlobVerifyKzgProofFailed); + } + Ok(()) + } +} diff --git a/crates/precompile/src/scroll.rs b/crates/precompile/src/scroll.rs deleted file mode 100644 index 595d0b64..00000000 --- a/crates/precompile/src/scroll.rs +++ /dev/null @@ -1,46 +0,0 @@ -use super::PrecompileProvider; -use sbv_primitives::types::{ - evm::{ScrollPrecompilesFactory, precompiles::PrecompilesMap}, - revm::{ScrollPrecompileProvider, SpecId}, -}; - -#[cfg(not(feature = "scroll-openvm"))] -impl ScrollPrecompilesFactory for PrecompileProvider { - fn with_spec(spec: SpecId) -> PrecompilesMap { - PrecompilesMap::from_static(ScrollPrecompileProvider::new_with_spec(spec).precompiles()) - } -} - -#[cfg(feature = "scroll-openvm")] -impl ScrollPrecompilesFactory for PrecompileProvider { - fn with_spec(spec: SpecId) -> PrecompilesMap { - let mut precompiles = ScrollPrecompileProvider::new_with_spec(spec) - .precompiles() - .to_owned(); - - #[cfg(feature = "openvm-sha256")] - { - if spec.is_enabled_in(SpecId::BERNOULLI) { - precompiles.extend([crate::imps::sha256::BERNOULLI]); - } - } - - #[cfg(feature = "openvm-secp256k1")] - precompiles.extend([crate::imps::secp256k1::ECRECOVER]); - - #[cfg(feature = "openvm-bn128")] - { - use crate::imps::bn128; - - precompiles.extend([bn128::add::ISTANBUL, bn128::mul::ISTANBUL]); - if spec.is_enabled_in(SpecId::BERNOULLI) { - precompiles.extend([bn128::pair::BERNOULLI]); - } - if spec.is_enabled_in(SpecId::FEYNMAN) { - precompiles.extend([bn128::pair::FEYNMAN]); - } - } - - PrecompilesMap::new(std::borrow::Cow::Owned(precompiles)) - } -} diff --git a/crates/precompile/src/imps/secp256k1/openvm.rs b/crates/precompile/src/secp256k1.rs similarity index 80% rename from crates/precompile/src/imps/secp256k1/openvm.rs rename to crates/precompile/src/secp256k1.rs index f43543a4..fba61b5a 100644 --- a/crates/precompile/src/imps/secp256k1/openvm.rs +++ b/crates/precompile/src/secp256k1.rs @@ -3,15 +3,14 @@ //! OpenVM implementation of `ecrecover`. More about it in [`crate::secp256k1`]. use openvm_ecc_guest::{algebra::IntMod, weierstrass::WeierstrassPoint}; use openvm_k256::ecdsa::{Error, RecoveryId, Signature, VerifyingKey}; -use openvm_keccak256::keccak256; -use sbv_primitives::{B256, alloy_primitives::B512}; +use sbv_primitives::{B256, alloy_primitives::B512, keccak256}; /// Recover the public key from a signature and a message. /// /// This function is using the OpenVM patch of the `k256` crate. -pub fn ecrecover(sig: &B512, mut recid: u8, msg: &B256) -> Result { - let _sig = sig; - let _recid = recid; +pub fn ecrecover(sig: &[u8; 64], mut recid: u8, msg: &[u8; 32]) -> Result<[u8; 32], Error> { + let sig = B512::from_slice(sig); + let msg = B256::from_slice(msg); // parse signature let mut sig = Signature::from_slice(sig.as_slice())?; if let Some(sig_normalized) = sig.normalize_s() { @@ -28,8 +27,8 @@ pub fn ecrecover(sig: &B512, mut recid: u8, msg: &B256) -> Result { encoded[..32].copy_from_slice(&WeierstrassPoint::x(public_key).to_be_bytes()); encoded[32..].copy_from_slice(&WeierstrassPoint::y(public_key).to_be_bytes()); // hash it - let mut hash = keccak256(&encoded); + let mut hash = keccak256(encoded); // truncate to 20 bytes hash[..12].fill(0); - Ok(B256::from(hash)) + Ok(B256::from(hash).into()) } diff --git a/crates/trie/src/lib.rs b/crates/trie/src/lib.rs index c6313bde..4002ec33 100644 --- a/crates/trie/src/lib.rs +++ b/crates/trie/src/lib.rs @@ -33,7 +33,7 @@ impl PartialStateTrie { pub fn new<'a, I>( prev_state_root: B256, states: I, - ) -> Result + ) -> Result where I: IntoIterator, { @@ -74,7 +74,6 @@ impl PartialStateTrie { } // Storage slot value is not present in the trie, validate that the witness is complete. - println!("[TRIGGERED] EMPTY NODE PROOF"); let account = self.state_trie.get_rlp::(&*hashed_address)?; match account { Some(account) => {