diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 09880b1..8632c46 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -1,21 +1,33 @@ -name: test +name: Build & Test -on: workflow_dispatch +on: + push: + branches: + - main + pull_request: + branches: + - main env: FOUNDRY_PROFILE: ci jobs: - check: - strategy: - fail-fast: true - - name: Foundry project + test: + name: Test runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v2 with: + token: ${{ secrets.GH_TOKEN }} submodules: recursive + - uses: actions-rs/toolchain@v1 + with: + toolchain: stable + override: true + + - uses: webfactory/ssh-agent@v0.7.0 + with: + ssh-private-key: ${{ secrets.SSH_KEY }} - name: Install Foundry uses: foundry-rs/foundry-toolchain@v1 @@ -32,3 +44,27 @@ jobs: run: | forge test -vvv id: test + + - uses: actions-rs/cargo@v1 + env: + RUSTFLAGS: "-C link-args=-Wl,--allow-multiple-definition" + with: + command: test + toolchain: stable + args: --release --locked --manifest-path ./forge/Cargo.toml -- --nocapture + + fmt: + name: Rustfmt + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - uses: actions-rs/toolchain@v1 + with: + toolchain: nightly + override: true + components: rustfmt + - uses: actions-rs/cargo@v1 + with: + command: fmt + toolchain: nightly + args: --manifest-path ./forge/Cargo.toml --all -- --check diff --git a/.gitignore b/.gitignore index 82e735e..8deaa43 100644 --- a/.gitignore +++ b/.gitignore @@ -11,4 +11,5 @@ out/ .env target/ -.cargo/ \ No newline at end of file +.cargo/ +.idea \ No newline at end of file diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..3a23e7f --- /dev/null +++ b/LICENSE @@ -0,0 +1,51 @@ +Apache License +Version 2.0, January 2004 +http://www.apache.org/licenses/ + +TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + +1. Definitions. + +"License" shall mean the terms and conditions for use, reproduction, and distribution as defined by Sections 1 through 9 of this document. + +"Licensor" shall mean the copyright owner or entity authorized by the copyright owner that is granting the License. + +"Legal Entity" shall mean the union of the acting entity and all other entities that control, are controlled by, or are under common control with that entity. For the purposes of this definition, "control" means (i) the power, direct or indirect, to cause the direction or management of such entity, whether by contract or otherwise, or (ii) ownership of fifty percent (50%) or more of the outstanding shares, or (iii) beneficial ownership of such entity. + +"You" (or "Your") shall mean an individual or Legal Entity exercising permissions granted by this License. + +"Source" form shall mean the preferred form for making modifications, including but not limited to software source code, documentation source, and configuration files. + +"Object" form shall mean any form resulting from mechanical transformation or translation of a Source form, including but not limited to compiled object code, generated documentation, and conversions to other media types. + +"Work" shall mean the work of authorship, whether in Source or Object form, made available under the License, as indicated by a copyright notice that is included in or attached to the work (an example is provided in the Appendix below). + +"Derivative Works" shall mean any work, whether in Source or Object form, that is based on (or derived from) the Work and for which the editorial revisions, annotations, elaborations, or other modifications represent, as a whole, an original work of authorship. For the purposes of this License, Derivative Works shall not include works that remain separable from, or merely link (or bind by name) to the interfaces of, the Work and Derivative Works thereof. + +"Contribution" shall mean any work of authorship, including the original version of the Work and any modifications or additions to that Work or Derivative Works thereof, that is intentionally submitted to Licensor for inclusion in the Work by the copyright owner or by an individual or Legal Entity authorized to submit on behalf of the copyright owner. For the purposes of this definition, "submitted" means any form of electronic, verbal, or written communication sent to the Licensor or its representatives, including but not limited to communication on electronic mailing lists, source code control systems, and issue tracking systems that are managed by, or on behalf of, the Licensor for the purpose of discussing and improving the Work, but excluding communication that is conspicuously marked or otherwise designated in writing by the copyright owner as "Not a Contribution." + +"Contributor" shall mean Licensor and any individual or Legal Entity on behalf of whom a Contribution has been received by Licensor and subsequently incorporated within the Work. + +2. Grant of Copyright License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable copyright license to reproduce, prepare Derivative Works of, publicly display, publicly perform, sublicense, and distribute the Work and such Derivative Works in Source or Object form. + +3. Grant of Patent License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable (except as stated in this section) patent license to make, have made, use, offer to sell, sell, import, and otherwise transfer the Work, where such license applies only to those patent claims licensable by such Contributor that are necessarily infringed by their Contribution(s) alone or by combination of their Contribution(s) with the Work to which such Contribution(s) was submitted. If You institute patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Work or a Contribution incorporated within the Work constitutes direct or contributory patent infringement, then any patent licenses granted to You under this License for that Work shall terminate as of the date such litigation is filed. + +4. Redistribution. You may reproduce and distribute copies of the Work or Derivative Works thereof in any medium, with or without modifications, and in Source or Object form, provided that You meet the following conditions: + +You must give any other recipients of the Work or Derivative Works a copy of this License; and +You must cause any modified files to carry prominent notices stating that You changed the files; and +You must retain, in the Source form of any Derivative Works that You distribute, all copyright, patent, trademark, and attribution notices from the Source form of the Work, excluding those notices that do not pertain to any part of the Derivative Works; and +If the Work includes a "NOTICE" text file as part of its distribution, then any Derivative Works that You distribute must include a readable copy of the attribution notices contained within such NOTICE file, excluding those notices that do not pertain to any part of the Derivative Works, in at least one of the following places: within a NOTICE text file distributed as part of the Derivative Works; within the Source form or documentation, if provided along with the Derivative Works; or, within a display generated by the Derivative Works, if and wherever such third-party notices normally appear. The contents of the NOTICE file are for informational purposes only and do not modify the License. You may add Your own attribution notices within Derivative Works that You distribute, alongside or as an addendum to the NOTICE text from the Work, provided that such additional attribution notices cannot be construed as modifying the License. + +You may add Your own copyright statement to Your modifications and may provide additional or different license terms and conditions for use, reproduction, or distribution of Your modifications, or for any such Derivative Works as a whole, provided Your use, reproduction, and distribution of the Work otherwise complies with the conditions stated in this License. +5. Submission of Contributions. Unless You explicitly state otherwise, any Contribution intentionally submitted for inclusion in the Work by You to the Licensor shall be under the terms and conditions of this License, without any additional terms or conditions. Notwithstanding the above, nothing herein shall supersede or modify the terms of any separate license agreement you may have executed with Licensor regarding such Contributions. + +6. Trademarks. This License does not grant permission to use the trade names, trademarks, service marks, or product names of the Licensor, except as required for reasonable and customary use in describing the origin of the Work and reproducing the content of the NOTICE file. + +7. Disclaimer of Warranty. Unless required by applicable law or agreed to in writing, Licensor provides the Work (and each Contributor provides its Contributions) on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied, including, without limitation, any warranties or conditions of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE. You are solely responsible for determining the appropriateness of using or redistributing the Work and assume any risks associated with Your exercise of permissions under this License. + +8. Limitation of Liability. In no event and under no legal theory, whether in tort (including negligence), contract, or otherwise, unless required by applicable law (such as deliberate and grossly negligent acts) or agreed to in writing, shall any Contributor be liable to You for damages, including any direct, indirect, special, incidental, or consequential damages of any character arising as a result of this License or out of the use or inability to use the Work (including but not limited to damages for loss of goodwill, work stoppage, computer failure or malfunction, or any and all other commercial damages or losses), even if such Contributor has been advised of the possibility of such damages. + +9. Accepting Warranty or Additional Liability. While redistributing the Work or Derivative Works thereof, You may choose to offer, and charge a fee for, acceptance of support, warranty, indemnity, or other liability obligations and/or rights consistent with this License. However, in accepting such obligations, You may act only on Your own behalf and on Your sole responsibility, not on behalf of any other Contributor, and only if You agree to indemnify, defend, and hold each Contributor harmless for any liability incurred by, or claims asserted against, such Contributor by reason of your accepting any such warranty or additional liability. + +END OF TERMS AND CONDITIONS \ No newline at end of file diff --git a/README.md b/README.md index a386030..5693702 100644 --- a/README.md +++ b/README.md @@ -1 +1,27 @@ -# ismp-solidity \ No newline at end of file +# ismp-solidity + +[ISMP](https://github.com/polytope-labs/ismp) implementation for both Substrate & EVM hosts. + +## Interface + + - [`IConsensusClient`](./src/interfaces/IConsensusClient.sol) + - [`BeefyV1`](./src/beefy/BeefyV1.sol) + - [`IHandler`](./src/interfaces/IHandler.sol) + - [`HandlerV1`](./src/HandlerV1.sol) + - [`IIsmpDispatcher`](./src/interfaces/IIsmpDispatcher.sol) + - [`IIsmpHost`](./src/interfaces/IIsmpHost.sol) + - [`EvmHost`](./src/EvmHost.sol) + - [`IIsmpModule`](./src/interfaces/IIsmpModule.sol) + - [`CrossChainGovernor`](./src/modules/CrossChainGovernor.sol) + +## `SubstrateDispatcher` + +This provides the interface that EVM contracts living on substrate chains can use to dispatch requests & responses over ISMP. This requires the `pallet-ismp` present in the runtime and the necessary precompiles from the `ismp-evm` module configured. + +## `EvmHost` + +The `EvmHost` contract is the core implementation of ISMP for native EVM environments. This contract will live across EVM chains allowing local contracts to interop over the ISMP network. + +## License + +This library is licensed under the Apache 2.0 License, Copyright (c) 2023 Polytope Labs. diff --git a/forge/Cargo.lock b/forge/Cargo.lock index d3f78fa..0fcaa41 100644 --- a/forge/Cargo.lock +++ b/forge/Cargo.lock @@ -27,7 +27,16 @@ version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a76fd60b23679b7d19bd066031410fb7e458ccc5e958eb5c325888ce4baedc97" dependencies = [ - "gimli 0.27.2", + "gimli 0.27.3", +] + +[[package]] +name = "addr2line" +version = "0.20.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f4fa78e18c64fce05e902adecd7a5eed15a5e0a3439f7b0e169f0252214865e3" +dependencies = [ + "gimli 0.27.3", ] [[package]] @@ -36,6 +45,15 @@ version = "1.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f26201604c87b1e01bd3d98f8d5d9a8fcbb815e8cedb41ffccbeb4bf593a35fe" +[[package]] +name = "aead" +version = "0.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0b613b8e1e3cf911a086f53f03bf286f52fd7a7258e4fa606f0ef220d39d8877" +dependencies = [ + "generic-array 0.14.7", +] + [[package]] name = "aes" version = "0.7.5" @@ -50,22 +68,36 @@ dependencies = [ [[package]] name = "aes" -version = "0.8.2" +version = "0.8.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "433cfd6710c9986c576a25ca913c39d66a6474107b406f34f91d4a8923395241" +checksum = "ac1f845298e95f983ff1944b728ae08b8cebab80d684f0a832ed0fc74dfa27e2" dependencies = [ "cfg-if", "cipher 0.4.4", "cpufeatures", ] +[[package]] +name = "aes-gcm" +version = "0.9.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "df5f85a83a7d8b0442b6aa7b504b8212c1733da07b98aae43d4bc21b2cb3cdf6" +dependencies = [ + "aead", + "aes 0.7.5", + "cipher 0.3.0", + "ctr 0.8.0", + "ghash", + "subtle", +] + [[package]] name = "ahash" version = "0.7.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fcb51a0695d8f838b1ee009b3fbf66bda078cd64590202a864a8f3e8c4315c47" dependencies = [ - "getrandom 0.2.8", + "getrandom 0.2.10", "once_cell", "version_check", ] @@ -77,20 +109,83 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "2c99f64d1e06488f620f932677e24bc6e2897582980441ae90a671415bd7ec2f" dependencies = [ "cfg-if", - "getrandom 0.2.8", + "getrandom 0.2.10", "once_cell", "version_check", ] [[package]] name = "aho-corasick" -version = "0.7.20" +version = "1.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cc936419f96fa211c1b9166887b38e5e40b19958e5b895be7c1f93adec7071ac" +checksum = "43f6cb1bf222025340178f382c426f13757b2960e89779dfcb319c32542a5a41" dependencies = [ "memchr", ] +[[package]] +name = "alloy-primitives" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "66f73f11dcfbf8bb763d88fb1d082fe7cca0a00d3227d9921bdbd52ce5e013e2" +dependencies = [ + "alloy-rlp", + "bytes", + "cfg-if", + "const-hex", + "derive_more", + "hex-literal", + "itoa", + "proptest", + "ruint", + "serde", + "tiny-keccak", +] + +[[package]] +name = "alloy-rlp" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f938f00332d63a5b0ac687bd6f46d03884638948921d9f8b50c59563d421ae25" +dependencies = [ + "arrayvec 0.7.4", + "bytes", + "smol_str", +] + +[[package]] +name = "alloy-sol-macro" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a74ceeffdacf9dd0910404d743d07273776fd17b85f9cb17b49a97e5c6055ce9" +dependencies = [ + "dunce", + "heck", + "proc-macro2", + "quote", + "syn 2.0.28", + "syn-solidity", + "tiny-keccak", +] + +[[package]] +name = "alloy-sol-types" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d5f347cb6bb307b3802ec455ef43ce00f5e590e0ceca3d2f3b070f5ee367e235" +dependencies = [ + "alloy-primitives", + "alloy-sol-macro", + "const-hex", + "serde", +] + +[[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" @@ -109,11 +204,60 @@ dependencies = [ "winapi", ] +[[package]] +name = "anstream" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0ca84f3628370c59db74ee214b3263d58f9aadd9b4fe7e711fd87dc452b7f163" +dependencies = [ + "anstyle", + "anstyle-parse", + "anstyle-query", + "anstyle-wincon", + "colorchoice", + "is-terminal", + "utf8parse", +] + +[[package]] +name = "anstyle" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3a30da5c5f2d5e72842e00bcb57657162cdabef0931f40e2deb9b4140440cecd" + +[[package]] +name = "anstyle-parse" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "938874ff5980b03a87c5524b3ae5b59cf99b1d6bc836848df7bc5ada9643c333" +dependencies = [ + "utf8parse", +] + +[[package]] +name = "anstyle-query" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5ca11d4be1bab0c8bc8734a9aa7bf4ee8316d462a08c6ac5052f888fef5b494b" +dependencies = [ + "windows-sys 0.48.0", +] + +[[package]] +name = "anstyle-wincon" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "180abfa45703aebe0093f79badacc01b8fd4ea2e35118747e5811127f926e188" +dependencies = [ + "anstyle", + "windows-sys 0.48.0", +] + [[package]] name = "anyhow" -version = "1.0.70" +version = "1.0.72" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7de8ce5e0f9f8d88245311066a578d72b7af3e7088f32783804676302df237e4" +checksum = "3b13c32d80ecc7ab747b80c3784bce54ee8a7a0cc4fbda9bf4cda2cf6fe90854" [[package]] name = "approx" @@ -132,11 +276,136 @@ checksum = "e2d098ff73c1ca148721f37baad5ea6a465a13f9573aba8641fbbbae8164a54e" [[package]] name = "ariadne" -version = "0.1.5" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "367fd0ad87307588d087544707bc5fbf4805ded96c7db922b70d368fa1cb5702" +dependencies = [ + "unicode-width", + "yansi 0.5.1", +] + +[[package]] +name = "ark-ff" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6b3235cc41ee7a12aaaf2c575a2ad7b46713a8a50bda2fc3b003a04845c05dd6" +dependencies = [ + "ark-ff-asm 0.3.0", + "ark-ff-macros 0.3.0", + "ark-serialize 0.3.0", + "ark-std 0.3.0", + "derivative", + "num-bigint", + "num-traits", + "paste", + "rustc_version 0.3.3", + "zeroize", +] + +[[package]] +name = "ark-ff" +version = "0.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ec847af850f44ad29048935519032c33da8aa03340876d351dfab5660d2966ba" +dependencies = [ + "ark-ff-asm 0.4.2", + "ark-ff-macros 0.4.2", + "ark-serialize 0.4.2", + "ark-std 0.4.0", + "derivative", + "digest 0.10.7", + "itertools", + "num-bigint", + "num-traits", + "paste", + "rustc_version 0.4.0", + "zeroize", +] + +[[package]] +name = "ark-ff-asm" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "db02d390bf6643fb404d3d22d31aee1c4bc4459600aef9113833d17e786c6e44" +dependencies = [ + "quote", + "syn 1.0.109", +] + +[[package]] +name = "ark-ff-asm" +version = "0.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3ed4aa4fe255d0bc6d79373f7e31d2ea147bcf486cba1be5ba7ea85abdb92348" +dependencies = [ + "quote", + "syn 1.0.109", +] + +[[package]] +name = "ark-ff-macros" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "db2fd794a08ccb318058009eefdf15bcaaaaf6f8161eb3345f907222bac38b20" +dependencies = [ + "num-bigint", + "num-traits", + "quote", + "syn 1.0.109", +] + +[[package]] +name = "ark-ff-macros" +version = "0.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7abe79b0e4288889c4574159ab790824d0033b9fdcb2a112a3182fac2e514565" +dependencies = [ + "num-bigint", + "num-traits", + "proc-macro2", + "quote", + "syn 1.0.109", +] + +[[package]] +name = "ark-serialize" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1d6c2b318ee6e10f8c2853e73a83adc0ccb88995aa978d8a3408d492ab2ee671" +dependencies = [ + "ark-std 0.3.0", + "digest 0.9.0", +] + +[[package]] +name = "ark-serialize" +version = "0.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "adb7b85a02b83d2f22f89bd5cac66c9c89474240cb6207cb1efc16d098e822a5" +dependencies = [ + "ark-std 0.4.0", + "digest 0.10.7", + "num-bigint", +] + +[[package]] +name = "ark-std" +version = "0.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f1cb2a2046bea8ce5e875551f5772024882de0b540c7f93dfc5d6cf1ca8b030c" +checksum = "1df2c09229cbc5a028b1d70e00fdb2acee28b1055dfb5ca73eea49c5a25c4e7c" dependencies = [ - "yansi", + "num-traits", + "rand 0.8.5", +] + +[[package]] +name = "ark-std" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "94893f1e0c6eeab764ade8dc4c0db24caf4fe7cbbaafc0eba0a9030f447b5185" +dependencies = [ + "num-traits", + "rand 0.8.5", ] [[package]] @@ -145,12 +414,30 @@ version = "4.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f52f63c5c1316a16a4b35eaac8b76a98248961a533f061684cb2a7cb0eafb6c6" +[[package]] +name = "array-init" +version = "0.0.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "23589ecb866b460d3a0f1278834750268c607e8e28a1b982c907219f3178cd72" +dependencies = [ + "nodrop", +] + [[package]] name = "arrayref" version = "0.3.7" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6b4930d2cb77ce62f89ee5d5289b4ac049559b1c45539271f5ed4fdc7db34545" +[[package]] +name = "arrayvec" +version = "0.4.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cd9fd44efafa8690358b7408d253adf110036b88f55672a933f01d616ad9b1b9" +dependencies = [ + "nodrop", +] + [[package]] name = "arrayvec" version = "0.5.2" @@ -159,9 +446,9 @@ checksum = "23b62fc65de8e4e7f52534fb52b0f3ed04746ae267519eef2a83941e8085068b" [[package]] name = "arrayvec" -version = "0.7.2" +version = "0.7.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8da52d66c7071e2e3fa2a1e5c6d088fec47b593032b254f5e980de8ea54454d6" +checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" [[package]] name = "ascii-canvas" @@ -172,6 +459,63 @@ dependencies = [ "term", ] +[[package]] +name = "async-channel" +version = "1.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "81953c529336010edd6d8e358f886d9581267795c61b19475b71314bffa46d35" +dependencies = [ + "concurrent-queue", + "event-listener", + "futures-core", +] + +[[package]] +name = "async-executor" +version = "1.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6fa3dc5f2a8564f07759c008b9109dc0d39de92a88d5588b8a5036d286383afb" +dependencies = [ + "async-lock", + "async-task", + "concurrent-queue", + "fastrand 1.9.0", + "futures-lite", + "slab", +] + +[[package]] +name = "async-fs" +version = "1.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "279cf904654eeebfa37ac9bb1598880884924aab82e290aa65c9e77a0e142e06" +dependencies = [ + "async-lock", + "autocfg", + "blocking", + "futures-lite", +] + +[[package]] +name = "async-io" +version = "1.13.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0fc5b45d93ef0529756f812ca52e44c221b35341892d3dcc34132ac02f3dd2af" +dependencies = [ + "async-lock", + "autocfg", + "cfg-if", + "concurrent-queue", + "futures-lite", + "log", + "parking", + "polling", + "rustix 0.37.23", + "slab", + "socket2", + "waker-fn", +] + [[package]] name = "async-lock" version = "2.7.0" @@ -181,15 +525,51 @@ dependencies = [ "event-listener", ] +[[package]] +name = "async-net" +version = "1.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4051e67316bc7eff608fe723df5d32ed639946adcd69e07df41fd42a7b411f1f" +dependencies = [ + "async-io", + "autocfg", + "blocking", + "futures-lite", +] + +[[package]] +name = "async-process" +version = "1.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7a9d28b1d97e08915212e2e45310d47854eafa69600756fc735fb788f75199c9" +dependencies = [ + "async-io", + "async-lock", + "autocfg", + "blocking", + "cfg-if", + "event-listener", + "futures-lite", + "rustix 0.37.23", + "signal-hook", + "windows-sys 0.48.0", +] + +[[package]] +name = "async-task" +version = "4.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ecc7ab41815b3c653ccd2978ec3255c81349336702dfdf62ee6f7069b12a3aae" + [[package]] name = "async-trait" -version = "0.1.67" +version = "0.1.72" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "86ea188f25f0255d8f92797797c97ebf5631fa88178beb1a46fdf5622c9a00e4" +checksum = "cc6dde6e4ed435a4c1ee4e73592f5ba9da2151af10076cc04858746af9352d09" dependencies = [ "proc-macro2", "quote", - "syn 2.0.5", + "syn 2.0.28", ] [[package]] @@ -200,34 +580,26 @@ checksum = "b6d7b9decdf35d8908a7e3ef02f64c5e9b1695e230154c0e8de3969142d9b94c" dependencies = [ "futures", "pharos", - "rustc_version", + "rustc_version 0.4.0", ] [[package]] name = "atomic" -version = "0.5.1" +version = "0.5.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b88d82667eca772c4aa12f0f1348b3ae643424c8876448f3f7bd5787032e234c" -dependencies = [ - "autocfg", -] +checksum = "c59bdb34bc650a32731b31bd8f0829cc15d24a708ee31559e0bb34f2bc320cba" [[package]] -name = "atty" -version = "0.2.14" +name = "atomic-waker" +version = "1.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d9b39be18770d11421cdb1b9947a45dd3f37e93092cbf377614828a319d5fee8" -dependencies = [ - "hermit-abi 0.1.19", - "libc", - "winapi", -] +checksum = "1181e1e0d1fce796a03db1ae795d67167da795f9cf4a39c37589e85ef57f26d3" [[package]] name = "auto_impl" -version = "1.0.1" +version = "1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8a8c1df849285fbacd587de7818cc7d13be6cd2cbcd47a04fb1801b0e2706e33" +checksum = "fee3da8ef1276b0bee5dd1c7258010d8fffd31801447323115a25560e1327b89" dependencies = [ "proc-macro-error", "proc-macro2", @@ -243,25 +615,19 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "backtrace" -version = "0.3.67" +version = "0.3.68" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "233d376d6d185f2a3093e58f283f60f880315b6c60075b01f36b3b85154564ca" +checksum = "4319208da049c43661739c5fade2ba182f09d1dc2299b32298d3a31692b17e12" dependencies = [ - "addr2line 0.19.0", + "addr2line 0.20.0", "cc", "cfg-if", "libc", "miniz_oxide", - "object 0.30.3", + "object 0.31.1", "rustc-demangle", ] -[[package]] -name = "base16ct" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "349a06037c7bf932dd7e7d1f653678b2038b9ad46a74102f1fc7bd7872678cce" - [[package]] name = "base16ct" version = "0.2.0" @@ -282,9 +648,9 @@ checksum = "9e1b586273c5702936fe7b7d6896644d8be71e6314cfe09d3167c95f712589e8" [[package]] name = "base64" -version = "0.21.0" +version = "0.21.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4a4ddaa51a5bc52a6948f74c06d20aaaddb71924eab79b8c97a8c556e942d6a" +checksum = "604178f6c5c21f02dc555784810edfb88d34ac2c73b2eae109655649ee73ce3d" [[package]] name = "base64ct" @@ -307,63 +673,56 @@ dependencies = [ "serde", ] -[[package]] -name = "beefy-merkle-tree" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.38#18bb7c7c841b101c19a8d1881b893ae8e37de460" -dependencies = [ - "sp-api", - "sp-beefy", - "sp-runtime 7.0.0", -] - [[package]] name = "beefy-prover" version = "0.1.0" -source = "git+https://github.com/polytope-labs/beefy?branch=seun/polkadot-v0.9.38#92478c94b5e5a6566129cb4c9754ffeb7f794695" +source = "git+ssh://git@github.com/polytope-labs/beefy.git?branch=seun/polkadot-v0.9.42#059ea001246a304cbcdc4f0baa1deb44b13d93f0" dependencies = [ "anyhow", "beefy-verifier-primitives", - "codegen", "derive_more", "frame-support", "hex", - "hex-literal", - "jsonrpsee-core", "mmr-rpc", - "once_cell", "pallet-beefy-mmr", "pallet-mmr", "parity-scale-codec", + "primitive-types", "rs_merkle", "serde_json", - "sp-beefy", - "sp-core 7.0.0", - "sp-core-hashing 5.0.0", + "sp-consensus-beefy", "sp-io 7.0.0", "sp-mmr-primitives", "sp-runtime 7.0.0", - "sp-std 5.0.0", + "sp-storage 7.0.0", "sp-trie 7.0.0", "subxt", - "tokio", ] [[package]] name = "beefy-verifier-primitives" version = "0.1.0" -source = "git+https://github.com/polytope-labs/beefy?branch=seun/polkadot-v0.9.38#92478c94b5e5a6566129cb4c9754ffeb7f794695" +source = "git+ssh://git@github.com/polytope-labs/beefy.git?branch=seun/polkadot-v0.9.42#059ea001246a304cbcdc4f0baa1deb44b13d93f0" dependencies = [ "derive_more", "parity-scale-codec", "serde", - "sp-beefy", + "sp-consensus-beefy", "sp-core 7.0.0", "sp-io 7.0.0", "sp-mmr-primitives", "sp-std 5.0.0", ] +[[package]] +name = "binary-merkle-tree" +version = "4.0.0-dev" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" +dependencies = [ + "hash-db 0.16.0", + "log", +] + [[package]] name = "bincode" version = "1.3.3" @@ -373,6 +732,15 @@ dependencies = [ "serde", ] +[[package]] +name = "bip39" +version = "2.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "93f2635620bf0b9d4576eb7bb9a38a55df78bd1205d26fa994b25911a69f212f" +dependencies = [ + "bitcoin_hashes", +] + [[package]] name = "bit-set" version = "0.5.3" @@ -388,6 +756,12 @@ version = "0.6.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "349f9b6a179ed607305526ca489b34ad0a41aed5f7980fa90eb03160b69598fb" +[[package]] +name = "bitcoin_hashes" +version = "0.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "90064b8dee6815a6470d60bad07bbbaee885c0e12d04177138fa3291a01b7bc4" + [[package]] name = "bitflags" version = "1.3.2" @@ -396,9 +770,9 @@ checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" [[package]] name = "bitflags" -version = "2.0.2" +version = "2.3.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "487f1e0fcbe47deb8b0574e646def1c903389d95241dd1bbcc6ce4a715dfc0c1" +checksum = "630be753d4e58660abd17930c71b647fe46c27ea6b63cc59e1e3851406972e42" [[package]] name = "bitvec" @@ -418,6 +792,7 @@ checksum = "1bc2832c24239b0141d5674bb9174f9d68a8b5b3f2753311927c172ca46f7e9c" dependencies = [ "funty", "radium 0.7.0", + "serde", "tap", "wyz", ] @@ -428,7 +803,28 @@ version = "0.10.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "46502ad458c9a52b69d4d4d32775c788b7a1b85e8bc9d482d92250fc0e3f8efe" dependencies = [ - "digest 0.10.6", + "digest 0.10.7", +] + +[[package]] +name = "blake2-rfc" +version = "0.2.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5d6d530bdd2d52966a6d03b7a964add7ae1a288d25214066fd4b600f0f796400" +dependencies = [ + "arrayvec 0.4.12", + "constant_time_eq 0.1.5", +] + +[[package]] +name = "blake2b_simd" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3c2f0dc9a68c6317d884f97cc36cf5a3d20ba14ce404227df55e1af708ab04bc" +dependencies = [ + "arrayref", + "arrayvec 0.7.4", + "constant_time_eq 0.2.6", ] [[package]] @@ -449,7 +845,7 @@ version = "0.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4152116fd6e9dadb291ae18fc1ec3575ed6d84c29642d97890f4b4a3417297e4" dependencies = [ - "generic-array 0.14.6", + "generic-array 0.14.7", ] [[package]] @@ -458,7 +854,7 @@ version = "0.10.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3078c7629b62d3f0439517fa394996acacc5cbc91c5a20d8c658e77abd503a71" dependencies = [ - "generic-array 0.14.6", + "generic-array 0.14.7", ] [[package]] @@ -470,11 +866,26 @@ dependencies = [ "byte-tools", ] +[[package]] +name = "blocking" +version = "1.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "77231a1c8f801696fc0123ec6150ce92cffb8e164a02afb9c8ddee0e9b65ad65" +dependencies = [ + "async-channel", + "async-lock", + "async-task", + "atomic-waker", + "fastrand 1.9.0", + "futures-lite", + "log", +] + [[package]] name = "bounded-collections" -version = "0.1.5" +version = "0.1.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a071c348a5ef6da1d3a87166b408170b46002382b1dda83992b5c2208cefb370" +checksum = "eb5b05133427c07c4776906f673ccf36c21b102c9829c641a5b56bd151d44fd6" dependencies = [ "log", "parity-scale-codec", @@ -491,11 +902,20 @@ dependencies = [ "sha2 0.9.9", ] +[[package]] +name = "bs58" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f5353f36341f7451062466f0b755b96ac3a9547e4d7f6b70d603fc721a7d7896" +dependencies = [ + "tinyvec", +] + [[package]] name = "bstr" -version = "1.4.0" +version = "1.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c3d4260bcc2e8fc9df1eac4919a720effeb63a3f0952f5bf4944adfa18897f09" +checksum = "6798148dccfbff0fae41c7574d2fa8f1ef3492fba0face179de5d8d447d67b05" dependencies = [ "memchr", "serde", @@ -509,9 +929,9 @@ checksum = "b4ae4235e6dac0694637c763029ecea1a2ec9e4e06ec2729bd21ba4d9c863eb7" [[package]] name = "bumpalo" -version = "3.12.0" +version = "3.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0d261e256854913907f67ed06efbc3338dfe6179796deefc1ff763fc1aee5535" +checksum = "a3e2c3daef883ecc1b5d58c15adae93470a91d425f3532ba1695849656af3fc1" [[package]] name = "byte-slice-cast" @@ -525,6 +945,12 @@ version = "0.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e3b5ca7a04898ad4bcd41c90c5285445ff5b791899bb1b0abdd2a2aa791211d7" +[[package]] +name = "bytemuck" +version = "1.13.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "17febce684fd15d89027105661fec94afb475cb995fbc59d2865198446ba2eea" + [[package]] name = "byteorder" version = "1.4.3" @@ -563,31 +989,31 @@ dependencies = [ [[package]] name = "camino" -version = "1.1.4" +version = "1.1.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c530edf18f37068ac2d977409ed5cd50d53d73bc653c7647b48eb78976ac9ae2" +checksum = "c59e92b5a388f549b863a7bea62612c09f24c8393560709a54558a9abdfb3b9c" dependencies = [ "serde", ] [[package]] name = "cargo-platform" -version = "0.1.2" +version = "0.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cbdb825da8a5df079a43676dbe042702f1707b1109f713a01420fbb4cc71fa27" +checksum = "2cfa25e60aea747ec7e1124f238816749faa93759c6ff5b31f1ccdda137f4479" dependencies = [ "serde", ] [[package]] name = "cargo_metadata" -version = "0.15.3" +version = "0.17.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "08a1ec454bc3eead8719cb56e15dbbfecdbc14e4b3a3ae4936cc6e31f5fc0d07" +checksum = "e7daec1a2a2129eeba1644b220b4647ec537b0b5d4bfd6876fcc5a540056b592" dependencies = [ "camino", "cargo-platform", - "semver", + "semver 1.0.18", "serde", "serde_json", "thiserror", @@ -595,11 +1021,12 @@ dependencies = [ [[package]] name = "cc" -version = "1.0.79" +version = "1.0.80" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "50d30906286121d95be3d479533b458f87493b30a4b5f79a607db8f5d11aa91f" +checksum = "51f1226cd9da55587234753d1245dd5b132343ea240f26b6a9003d68706141ba" dependencies = [ "jobserver", + "libc", ] [[package]] @@ -608,7 +1035,7 @@ version = "0.10.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0aacacf4d96c24b2ad6eb8ee6df040e4f27b0d0b39a5710c30091baa830485db" dependencies = [ - "smallvec", + "smallvec 1.11.0", ] [[package]] @@ -617,14 +1044,39 @@ version = "1.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" +[[package]] +name = "chacha20" +version = "0.8.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5c80e5460aa66fe3b91d40bcbdab953a597b60053e34d684ac6903f863b680a6" +dependencies = [ + "cfg-if", + "cipher 0.3.0", + "cpufeatures", + "zeroize", +] + +[[package]] +name = "chacha20poly1305" +version = "0.9.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a18446b09be63d457bbec447509e85f662f32952b035ce892290396bc0b0cff5" +dependencies = [ + "aead", + "chacha20", + "cipher 0.3.0", + "poly1305", + "zeroize", +] + [[package]] name = "chrono" -version = "0.4.24" +version = "0.4.26" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e3c5919066adf22df73762e50cffcde3a758f2a848b113b586d1f86728b673b" +checksum = "ec837a71355b28f6556dbd569b37b3f363091c0bd4b2e735674521b4c5fd9bc5" dependencies = [ + "android-tzdata", "iana-time-zone", - "num-integer", "num-traits", "winapi", ] @@ -635,7 +1087,7 @@ version = "0.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7ee52072ec15386f770805afd189a01c8841be8696bed250fa2f13c4c0d6dfb7" dependencies = [ - "generic-array 0.14.6", + "generic-array 0.14.7", ] [[package]] @@ -667,109 +1119,47 @@ dependencies = [ [[package]] name = "clap" -version = "3.2.23" +version = "4.3.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "71655c45cb9845d3270c9d6df84ebe72b4dad3c2ba3f7023ad47c144e4e473a5" +checksum = "5fd304a20bff958a57f04c4e96a2e7594cc4490a0e809cbd48bb6437edaa452d" dependencies = [ - "atty", - "bitflags 1.3.2", - "clap_derive 3.2.18", - "clap_lex 0.2.4", - "indexmap", + "clap_builder", + "clap_derive", "once_cell", - "strsim", - "termcolor", - "textwrap", ] [[package]] -name = "clap" -version = "4.1.11" +name = "clap_builder" +version = "4.3.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "42dfd32784433290c51d92c438bb72ea5063797fc3cc9a21a8c4346bebbb2098" +checksum = "01c6a3f08f1fe5662a35cfe393aec09c4df95f60ee93b7556505260f75eee9e1" dependencies = [ - "bitflags 2.0.2", - "clap_derive 4.1.9", - "clap_lex 0.3.3", - "is-terminal", - "once_cell", + "anstream", + "anstyle", + "clap_lex", "strsim", - "termcolor", - "terminal_size 0.2.5", + "terminal_size", "unicase", "unicode-width", ] [[package]] name = "clap_derive" -version = "3.2.18" +version = "4.3.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea0c8bce528c4be4da13ea6fead8965e95b6073585a2f05204bd8f4119f82a65" +checksum = "54a9bb5758fc5dfe728d1019941681eccaf0cf8a4189b692a0ee2f2ecf90a050" dependencies = [ "heck", - "proc-macro-error", "proc-macro2", "quote", - "syn 1.0.109", -] - -[[package]] -name = "clap_derive" -version = "4.1.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fddf67631444a3a3e3e5ac51c36a5e01335302de677bd78759eaa90ab1f46644" -dependencies = [ - "heck", - "proc-macro-error", - "proc-macro2", - "quote", - "syn 1.0.109", + "syn 2.0.28", ] [[package]] name = "clap_lex" -version = "0.2.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2850f2f5a82cbf437dd5af4d49848fbdfc27c157c3d010345776f952765261c5" -dependencies = [ - "os_str_bytes", -] - -[[package]] -name = "clap_lex" -version = "0.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "033f6b7a4acb1f358c742aaca805c939ee73b4c6209ae4318ec7aca81c42e646" -dependencies = [ - "os_str_bytes", -] - -[[package]] -name = "codegen" -version = "0.1.0" -source = "git+ssh://git@github.com/polytope-labs/subxt-codegen.git?branch=main#8545aabecaa8ed5a5ae684edb3dc1950b84e6213" -dependencies = [ - "anyhow", - "clap 3.2.23", - "frame-metadata", - "hex", - "jsonrpsee", - "parity-scale-codec", - "serde_json", - "subxt-codegen", - "syn 1.0.109", - "tokio", -] - -[[package]] -name = "codespan-reporting" -version = "0.11.1" +version = "0.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3538270d33cc669650c4b093848450d380def10c331d38c768e34cac80576e6e" -dependencies = [ - "termcolor", - "unicode-width", -] +checksum = "2da6da31387c7e4ef160ffab6d5e7f00c42626fe39aea70a7b0f1773f7dd6c1b" [[package]] name = "coins-bip32" @@ -778,35 +1168,33 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b30a84aab436fcb256a2ab3c80663d8aec686e6bae12827bb05fef3e1e439c9f" dependencies = [ "bincode", - "bs58", + "bs58 0.4.0", "coins-core", - "digest 0.10.6", - "getrandom 0.2.8", + "digest 0.10.7", + "getrandom 0.2.10", "hmac 0.12.1", - "k256 0.13.0", + "k256", "lazy_static", "serde", - "sha2 0.10.6", + "sha2 0.10.7", "thiserror", ] [[package]] name = "coins-bip39" -version = "0.8.3" +version = "0.8.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "efb68f3b6c3fee83828ecd8d463f360a397c32aaeb35bd931c01e5ddf5631c69" +checksum = "84f4d04ee18e58356accd644896aeb2094ddeafb6a713e056cef0c0a8e468c15" dependencies = [ "bitvec 0.17.4", "coins-bip32", - "getrandom 0.2.8", - "hex", + "getrandom 0.2.10", "hmac 0.12.1", "once_cell", - "pbkdf2 0.12.1", + "pbkdf2 0.12.2", "rand 0.8.5", - "sha2 0.10.6", + "sha2 0.10.7", "thiserror", - "tracing", ] [[package]] @@ -815,74 +1203,64 @@ version = "0.8.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9b949a1c63fb7eb591eb7ba438746326aedf0ae843e51ec92ba6bec5bb382c4f" dependencies = [ - "base64 0.21.0", + "base64 0.21.2", "bech32", - "bs58", - "digest 0.10.6", - "generic-array 0.14.6", + "bs58 0.4.0", + "digest 0.10.7", + "generic-array 0.14.7", "hex", "ripemd", "serde", "serde_derive", - "sha2 0.10.6", + "sha2 0.10.7", "sha3", "thiserror", ] [[package]] -name = "combine" -version = "4.6.6" +name = "colorchoice" +version = "1.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35ed6e9d84f0b51a7f52daf1c7d71dd136fd7a3f41a8462b8cdb8c78d920fad4" -dependencies = [ - "bytes", - "memchr", -] +checksum = "acbf1af155f9b9ef647e42cdc158db4b64a1b61f743629225fde6f3e0be2a7c7" [[package]] name = "comfy-table" -version = "6.1.4" +version = "6.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6e7b787b0dc42e8111badfdbe4c3059158ccb2db8780352fa1b01e8ccf45cc4d" +checksum = "7e959d788268e3bf9d35ace83e81b124190378e4c91c9067524675e33394b8ba" dependencies = [ "crossterm", - "strum", - "strum_macros", + "strum 0.24.1", + "strum_macros 0.24.3", "unicode-width", ] [[package]] -name = "console" -version = "0.14.1" +name = "concurrent-queue" +version = "2.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3993e6445baa160675931ec041a5e03ca84b9c6e32a056150d3aa2bdda0a1f45" +checksum = "62ec6771ecfa0762d24683ee5a32ad78487a3d3afdc0fb8cae19d2c5deb50b7c" dependencies = [ - "encode_unicode", - "lazy_static", - "libc", - "regex", - "terminal_size 0.1.17", - "unicode-width", - "winapi", + "crossbeam-utils", ] [[package]] -name = "console" -version = "0.15.5" +name = "const-hex" +version = "1.6.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c3d79fbe8970a77e3e34151cc13d3b3e248aa0faaecb9f6091fa07ebefe5ad60" +checksum = "268f52aae268980d03dd9544c1ea591965b2735b038d6998d6e4ab37c8c24445" dependencies = [ - "encode_unicode", - "lazy_static", - "libc", - "windows-sys 0.42.0", + "cfg-if", + "cpufeatures", + "hex", + "serde", ] [[package]] name = "const-oid" -version = "0.9.2" +version = "0.9.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "520fbf3c07483f94e3e3ca9d0cfd913d7718ef2483d2cfd91c0d9e91474ab913" +checksum = "795bc6e66a8e340f075fcf6227e417a2dc976b92b91f3cdc778bb858778b6747" [[package]] name = "constant_time_eq" @@ -891,19 +1269,16 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "245097e9a4535ee1e3e3931fcfcd55a796a44c643e8596ff6566d68f09b87bbc" [[package]] -name = "convert_case" -version = "0.4.0" +name = "constant_time_eq" +version = "0.2.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6245d59a3e82a7fc217c5828a6692dbc6dfb63a0c8c90495621f7b9d79704a0e" +checksum = "21a53c0a4d288377e7415b53dcfc3c04da5cdc2cc95c8d5ac178b58f0b861ad6" [[package]] name = "convert_case" -version = "0.6.0" +version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec182b0ca2f35d8fc196cf3404988fd8b8c739a4d270ff118a398feb0cbec1ca" -dependencies = [ - "unicode-segmentation", -] +checksum = "6245d59a3e82a7fc217c5828a6692dbc6dfb63a0c8c90495621f7b9d79704a0e" [[package]] name = "core-foundation" @@ -917,9 +1292,9 @@ dependencies = [ [[package]] name = "core-foundation-sys" -version = "0.8.3" +version = "0.8.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5827cebf4670468b8772dd191856768aedcb1b0278a04f989f7766351917b9dc" +checksum = "e496a50fda8aacccc86d7529e2c1e0892dbd0f898a6b5645b5561b89c3210efa" [[package]] name = "cpp_demangle" @@ -932,9 +1307,9 @@ dependencies = [ [[package]] name = "cpufeatures" -version = "0.2.5" +version = "0.2.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "28d997bd5e24a5928dd43e46dc529867e207907fe0b239c3477d924f7f2ca320" +checksum = "a17b76ff3a4162b0b27f354a0c87015ddad39d35f9c0c36607a3bdd175dde1f1" dependencies = [ "libc", ] @@ -950,9 +1325,27 @@ dependencies = [ [[package]] name = "cranelift-entity" -version = "0.92.1" +version = "0.92.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5a9e39cfc857e7e539aa623e03bb6bec11f54aef3dfdef41adcfa7b594af3b54" +dependencies = [ + "serde", +] + +[[package]] +name = "cranelift-entity" +version = "0.93.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f42ea692c7b450ad18b8c9889661505d51c09ec4380cf1c2d278dbb2da22cae1" +dependencies = [ + "serde", +] + +[[package]] +name = "cranelift-entity" +version = "0.95.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5a9e39cfc857e7e539aa623e03bb6bec11f54aef3dfdef41adcfa7b594af3b54" +checksum = "40099d38061b37e505e63f89bab52199037a72b931ad4868d9089ff7268660b0" dependencies = [ "serde", ] @@ -968,9 +1361,9 @@ dependencies = [ [[package]] name = "crossbeam-channel" -version = "0.5.7" +version = "0.5.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf2b3e8478797446514c91ef04bafcb59faba183e621ad488df88983cc14128c" +checksum = "a33c2bf77f2df06183c3aa30d1e96c0695a313d4f9c453cc3762a6db39f99200" dependencies = [ "cfg-if", "crossbeam-utils", @@ -989,31 +1382,41 @@ dependencies = [ [[package]] name = "crossbeam-epoch" -version = "0.9.14" +version = "0.9.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "46bd5f3f85273295a9d14aedfb86f6aadbff6d8f5295c4a9edb08e819dcf5695" +checksum = "ae211234986c545741a7dc064309f67ee1e5ad243d0e48335adc0484d960bcc7" dependencies = [ "autocfg", "cfg-if", "crossbeam-utils", - "memoffset 0.8.0", + "memoffset 0.9.0", "scopeguard", ] +[[package]] +name = "crossbeam-queue" +version = "0.3.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d1cfb3ea8a53f37c40dea2c7bedcbd88bdfae54f5e2175d6ecaff1c988353add" +dependencies = [ + "cfg-if", + "crossbeam-utils", +] + [[package]] name = "crossbeam-utils" -version = "0.8.15" +version = "0.8.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3c063cd8cc95f5c377ed0d4b49a4b21f632396ff690e8470c29b3359b346984b" +checksum = "5a22b2d63d4d1dc0b7f1b6b2747dd0088008a9be28b6ddf0b1e7d335e3037294" dependencies = [ "cfg-if", ] [[package]] name = "crossterm" -version = "0.25.0" +version = "0.26.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e64e6c0fbe2c17357405f7c758c1ef960fce08bdfb2c03d88d2a18d7e09c4b67" +checksum = "a84cda67535339806297f1b331d6dd6320470d2a0fe65381e79ee9e156dd3d13" dependencies = [ "bitflags 1.3.2", "crossterm_winapi", @@ -1027,9 +1430,9 @@ dependencies = [ [[package]] name = "crossterm_winapi" -version = "0.9.0" +version = "0.9.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2ae1b35a484aa10e07fe0638d02301c5ad24de82d310ccbd2f3693da5f09bf1c" +checksum = "acdd7c62a3665c7f6830a51635d9ac9b23ed385797f70a83bb8bafe9c572ab2b" dependencies = [ "winapi", ] @@ -1042,23 +1445,11 @@ checksum = "7a81dae078cea95a014a339291cec439d2f232ebe854a9d672b796c6afafa9b7" [[package]] name = "crypto-bigint" -version = "0.4.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ef2b4b23cddf68b89b8f8069890e8c270d54e2d5fe1b143820234805e4cb17ef" -dependencies = [ - "generic-array 0.14.6", - "rand_core 0.6.4", - "subtle", - "zeroize", -] - -[[package]] -name = "crypto-bigint" -version = "0.5.1" +version = "0.5.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7c2538c4e68e52548bacb3e83ac549f903d44f011ac9d5abb5e132e67d0808f7" +checksum = "cf4c2f4e1afd912bc40bfd6fed5d9dc1f288e0ba01bfcc835cc5bc3eb13efe15" dependencies = [ - "generic-array 0.14.6", + "generic-array 0.14.7", "rand_core 0.6.4", "subtle", "zeroize", @@ -1070,7 +1461,7 @@ version = "0.1.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1bfb12502f3fc46cca1bb51ac28df9d618d813cdc3d2f25b9fe775a34af26bb3" dependencies = [ - "generic-array 0.14.6", + "generic-array 0.14.7", "typenum", ] @@ -1080,7 +1471,7 @@ version = "0.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b584a330336237c1eecd3e94266efb216c56ed91225d634cb2991c5f3fd1aeab" dependencies = [ - "generic-array 0.14.6", + "generic-array 0.14.7", "subtle", ] @@ -1090,10 +1481,19 @@ version = "0.11.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b1d1a86f49236c215f271d40892d5fc950490551400b02ef360692c29815c714" dependencies = [ - "generic-array 0.14.6", + "generic-array 0.14.7", "subtle", ] +[[package]] +name = "ctr" +version = "0.8.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "049bb91fb4aaf0e3c7efa6cd5ef877dbbbd15b39dad06d9948de4ec8a75761ea" +dependencies = [ + "cipher 0.3.0", +] + [[package]] name = "ctr" version = "0.9.2" @@ -1130,57 +1530,50 @@ dependencies = [ ] [[package]] -name = "cxx" -version = "1.0.93" +name = "curve25519-dalek" +version = "4.0.0-rc.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a9c00419335c41018365ddf7e4d5f1c12ee3659ddcf3e01974650ba1de73d038" +checksum = "8d4ba9852b42210c7538b75484f9daa0655e9a3ac04f693747bb0f02cf3cfe16" dependencies = [ - "cc", - "cxxbridge-flags", - "cxxbridge-macro", - "link-cplusplus", + "cfg-if", + "fiat-crypto", + "packed_simd_2", + "platforms", + "subtle", + "zeroize", ] [[package]] -name = "cxx-build" -version = "1.0.93" +name = "curve25519-dalek-ng" +version = "4.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fb8307ad413a98fff033c8545ecf133e3257747b3bae935e7602aab8aa92d4ca" +checksum = "1c359b7249347e46fb28804470d071c921156ad62b3eef5d34e2ba867533dec8" dependencies = [ - "cc", - "codespan-reporting", - "once_cell", - "proc-macro2", - "quote", - "scratch", - "syn 2.0.5", + "byteorder", + "digest 0.9.0", + "rand_core 0.6.4", + "subtle-ng", + "zeroize", ] [[package]] -name = "cxxbridge-flags" -version = "1.0.93" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "edc52e2eb08915cb12596d29d55f0b5384f00d697a646dbd269b6ecb0fbd9d31" - -[[package]] -name = "cxxbridge-macro" -version = "1.0.93" +name = "darling" +version = "0.14.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "631569015d0d8d54e6c241733f944042623ab6df7bc3be7466874b05fcdb1c5f" +checksum = "7b750cb3417fd1b327431a470f388520309479ab0bf5e323505daf0290cd3850" dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.5", + "darling_core 0.14.4", + "darling_macro 0.14.4", ] [[package]] name = "darling" -version = "0.14.4" +version = "0.20.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7b750cb3417fd1b327431a470f388520309479ab0bf5e323505daf0290cd3850" +checksum = "0209d94da627ab5605dcccf08bb18afa5009cfbef48d8a8b7d7bdbc79be25c5e" dependencies = [ - "darling_core", - "darling_macro", + "darling_core 0.20.3", + "darling_macro 0.20.3", ] [[package]] @@ -1197,37 +1590,64 @@ dependencies = [ "syn 1.0.109", ] +[[package]] +name = "darling_core" +version = "0.20.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "177e3443818124b357d8e76f53be906d60937f0d3a90773a664fa63fa253e621" +dependencies = [ + "fnv", + "ident_case", + "proc-macro2", + "quote", + "strsim", + "syn 2.0.28", +] + [[package]] name = "darling_macro" version = "0.14.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a4aab4dbc9f7611d8b55048a3a16d2d010c2c8334e46304b40ac1cc14bf3b48e" dependencies = [ - "darling_core", + "darling_core 0.14.4", "quote", "syn 1.0.109", ] [[package]] -name = "der" -version = "0.6.1" +name = "darling_macro" +version = "0.20.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f1a467a65c5e759bce6e65eaf91cc29f466cdc57cb65777bd646872a8a1fd4de" +checksum = "836a9bbc7ad63342d6d6e7b815ccab164bc77a2d95d84bc3117a8c0d5c98e2d5" dependencies = [ - "const-oid", - "zeroize", + "darling_core 0.20.3", + "quote", + "syn 2.0.28", ] +[[package]] +name = "data-encoding" +version = "2.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c2e66c9d817f1720209181c316d28635c050fa304f9c79e47a520882661b7308" + [[package]] name = "der" -version = "0.7.1" +version = "0.7.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bc906908ea6458456e5eaa160a9c08543ec3d1e6f71e2235cedd660cb65f9df0" +checksum = "0c7ed52955ce76b1554f509074bb357d3fb8ac9b51288a65a3fd480d1dfba946" dependencies = [ "const-oid", "zeroize", ] +[[package]] +name = "deranged" +version = "0.3.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8810e7e2cf385b1e9b50d68264908ec367ba642c96d02edfe61c39e88e2a3c01" + [[package]] name = "derivative" version = "2.2.0" @@ -1256,25 +1676,13 @@ version = "0.99.17" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4fb810d30a7c1953f91334de7244731fc3f3c10d7fe163338a35b9f640960321" dependencies = [ - "convert_case 0.4.0", + "convert_case", "proc-macro2", "quote", - "rustc_version", + "rustc_version 0.4.0", "syn 1.0.109", ] -[[package]] -name = "dialoguer" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c9dd058f8b65922819fabb4a41e7d1964e56344042c26efbccd465202c23fa0c" -dependencies = [ - "console 0.14.1", - "lazy_static", - "tempfile", - "zeroize", -] - [[package]] name = "diff" version = "0.1.13" @@ -1296,20 +1704,30 @@ version = "0.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d3dd60d1080a57a05ab032377049e0591415d2b31afd7028356dbf3cc6dcb066" dependencies = [ - "generic-array 0.14.6", + "generic-array 0.14.7", ] [[package]] name = "digest" -version = "0.10.6" +version = "0.10.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8168378f4e5023e7218c89c891c0fd8ecdb5e5e4f18cb78f38cf245dd021e76f" +checksum = "9ed9a281f7bc9b7576e61468ba615a66a5c8cfdff42420a70aa82701a3b1e292" dependencies = [ "block-buffer 0.10.4", + "const-oid", "crypto-common", "subtle", ] +[[package]] +name = "dirs" +version = "5.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "44c45a9d03d6676652bcb5e724c7e988de1acad23a711b5217ab9cbecbec2225" +dependencies = [ + "dirs-sys", +] + [[package]] name = "dirs-next" version = "2.0.0" @@ -1320,6 +1738,18 @@ dependencies = [ "dirs-sys-next", ] +[[package]] +name = "dirs-sys" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "520f05a5cbd335fae5a99ff7a6ab8627577660ee5cfd6a94a6a929b52ff0321c" +dependencies = [ + "libc", + "option-ext", + "redox_users", + "windows-sys 0.48.0", +] + [[package]] name = "dirs-sys-next" version = "0.1.2" @@ -1339,9 +1769,9 @@ checksum = "9ea835d29036a4087793836fa931b08837ad5e957da9e23886b29586fb9b6650" [[package]] name = "dunce" -version = "1.0.3" +version = "1.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0bd4b30a6560bbd9b4620f4de34c3f14f60848e58a9b7216801afcb4c7b31c3c" +checksum = "56ce8c6da7551ec6c462cbaf3bfbc75131ebbfa1c944aeaa9dab51ca1c5f0c3b" [[package]] name = "dyn-clonable" @@ -1366,32 +1796,22 @@ dependencies = [ [[package]] name = "dyn-clone" -version = "1.0.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "68b0cf012f1230e43cd00ebb729c6bb58707ecfa8ad08b52ef3a4ccd2697fc30" - -[[package]] -name = "ecdsa" -version = "0.14.8" +version = "1.0.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "413301934810f597c1d19ca71c8710e99a3f1ba28a0d2ebc01551a2daeea3c5c" -dependencies = [ - "der 0.6.1", - "elliptic-curve 0.12.3", - "rfc6979 0.3.1", - "signature 1.6.4", -] +checksum = "304e6508efa593091e97a9abbc10f90aa7ca635b6d2784feff3c89d41dd12272" [[package]] name = "ecdsa" -version = "0.16.1" +version = "0.16.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d1b0a1222f8072619e8a6b667a854020a03d363738303203c09468b3424a420a" +checksum = "a4b1e0c257a9e9f25f90ff76d7a68360ed497ee519c8e428d1825ef0000799d4" dependencies = [ - "der 0.7.1", - "elliptic-curve 0.13.2", - "rfc6979 0.4.0", - "signature 2.0.0", + "der", + "digest 0.10.7", + "elliptic-curve", + "rfc6979", + "signature 2.1.0", + "spki", ] [[package]] @@ -1431,44 +1851,25 @@ dependencies = [ [[package]] name = "either" -version = "1.8.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7fcaabb2fef8c910e7f4c7ce9f67a1283a1715879a7c230ca9d6d1ae31f16d91" - -[[package]] -name = "elliptic-curve" -version = "0.12.3" +version = "1.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e7bb888ab5300a19b8e5bceef25ac745ad065f3c9f7efc6de1b91958110891d3" -dependencies = [ - "base16ct 0.1.1", - "crypto-bigint 0.4.9", - "der 0.6.1", - "digest 0.10.6", - "ff 0.12.1", - "generic-array 0.14.6", - "group 0.12.1", - "rand_core 0.6.4", - "sec1 0.3.0", - "subtle", - "zeroize", -] +checksum = "a26ae43d7bcc3b814de94796a5e736d4029efb0ee900c12e2d54c993ad1a1e07" [[package]] name = "elliptic-curve" -version = "0.13.2" +version = "0.13.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6ea5a92946e8614bb585254898bb7dd1ddad241ace60c52149e3765e34cc039d" +checksum = "968405c8fdc9b3bf4df0a6638858cc0b52462836ab6b1c87377785dd09cf1c0b" dependencies = [ - "base16ct 0.2.0", - "crypto-bigint 0.5.1", - "digest 0.10.6", - "ff 0.13.0", - "generic-array 0.14.6", - "group 0.13.0", - "pkcs8 0.10.1", + "base16ct", + "crypto-bigint", + "digest 0.10.7", + "ff", + "generic-array 0.14.7", + "group", + "pkcs8", "rand_core 0.6.4", - "sec1 0.7.1", + "sec1", "subtle", "zeroize", ] @@ -1482,12 +1883,6 @@ dependencies = [ "log", ] -[[package]] -name = "encode_unicode" -version = "0.3.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a357d28ed41a50f9c765dbfe56cbc04a64e53e5fc58ba79fbc34c10ef3df831f" - [[package]] name = "encoding_rs" version = "0.8.32" @@ -1499,28 +1894,58 @@ dependencies = [ [[package]] name = "enr" -version = "0.8.0" +version = "0.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eb4d5fbf6f56acecd38f5988eb2e4ae412008a2a30268c748c701ec6322f39d4" +checksum = "0be7b2ac146c1f99fe245c02d16af0696450d8e06c135db75e10eeb9e642c20d" dependencies = [ - "base64 0.13.1", + "base64 0.21.2", "bytes", "hex", - "k256 0.13.0", + "k256", "log", "rand 0.8.5", "rlp", "serde", + "serde-hex", "sha3", "zeroize", ] +[[package]] +name = "enum-as-inner" +version = "0.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c9720bba047d567ffc8a3cba48bf19126600e249ab7f128e9233e6376976a116" +dependencies = [ + "heck", + "proc-macro2", + "quote", + "syn 1.0.109", +] + +[[package]] +name = "enumn" +version = "0.1.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b893c4eb2dc092c811165f84dc7447fae16fb66521717968c34c509b39b1a5c5" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.28", +] + [[package]] name = "environmental" version = "1.1.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e48c92028aaa870e83d51c64e5d4e0b6981b360c522198c23959f219a4e1b15b" +[[package]] +name = "equivalent" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" + [[package]] name = "errno" version = "0.2.8" @@ -1532,6 +1957,17 @@ dependencies = [ "winapi", ] +[[package]] +name = "errno" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6b30f669a7961ef1631673d2766cc92f52d64f7ef354d4fe0ddfd30ed52f0f4f" +dependencies = [ + "errno-dragonfly", + "libc", + "windows-sys 0.48.0", +] + [[package]] name = "errno-dragonfly" version = "0.1.2" @@ -1548,9 +1984,9 @@ version = "0.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1fda3bf123be441da5260717e0661c25a2fd9cb2b2c1d20bf2e05580047158ab" dependencies = [ - "aes 0.8.2", - "ctr", - "digest 0.10.6", + "aes 0.8.3", + "ctr 0.9.2", + "digest 0.10.7", "hex", "hmac 0.12.1", "pbkdf2 0.11.0", @@ -1558,7 +1994,7 @@ dependencies = [ "scrypt", "serde", "serde_json", - "sha2 0.10.6", + "sha2 0.10.7", "sha3", "thiserror", "uuid", @@ -1596,6 +2032,24 @@ dependencies = [ "tiny-keccak", ] +[[package]] +name = "ethereum" +version = "0.14.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6a89fb87a9e103f71b903b80b670200b54cc67a07578f070681f1fffb7396fb7" +dependencies = [ + "bytes", + "ethereum-types", + "hash-db 0.15.2", + "hash256-std-hasher", + "parity-scale-codec", + "rlp", + "scale-info", + "serde", + "sha3", + "triehash", +] + [[package]] name = "ethereum-types" version = "0.14.1" @@ -1614,8 +2068,8 @@ dependencies = [ [[package]] name = "ethers" -version = "2.0.1" -source = "git+https://github.com/gakonst/ethers-rs?rev=80ac394#80ac3947d066bb3e3148edaecf8cd54792452bb2" +version = "2.0.8" +source = "git+https://github.com/gakonst/ethers-rs#594627dc1c3b490ba8f513f8f5e23d11448cbcf8" dependencies = [ "ethers-addressbook", "ethers-contract", @@ -1629,8 +2083,8 @@ dependencies = [ [[package]] name = "ethers-addressbook" -version = "2.0.1" -source = "git+https://github.com/gakonst/ethers-rs?rev=80ac394#80ac3947d066bb3e3148edaecf8cd54792452bb2" +version = "2.0.8" +source = "git+https://github.com/gakonst/ethers-rs#594627dc1c3b490ba8f513f8f5e23d11448cbcf8" dependencies = [ "ethers-core", "once_cell", @@ -1640,13 +2094,14 @@ dependencies = [ [[package]] name = "ethers-contract" -version = "2.0.1" -source = "git+https://github.com/gakonst/ethers-rs?rev=80ac394#80ac3947d066bb3e3148edaecf8cd54792452bb2" +version = "2.0.8" +source = "git+https://github.com/gakonst/ethers-rs#594627dc1c3b490ba8f513f8f5e23d11448cbcf8" dependencies = [ "ethers-contract-abigen", "ethers-contract-derive", "ethers-core", "ethers-providers", + "ethers-signers", "futures-util", "hex", "once_cell", @@ -1658,15 +2113,14 @@ dependencies = [ [[package]] name = "ethers-contract-abigen" -version = "2.0.1" -source = "git+https://github.com/gakonst/ethers-rs?rev=80ac394#80ac3947d066bb3e3148edaecf8cd54792452bb2" +version = "2.0.8" +source = "git+https://github.com/gakonst/ethers-rs#594627dc1c3b490ba8f513f8f5e23d11448cbcf8" dependencies = [ "Inflector", "dunce", "ethers-core", "ethers-etherscan", "eyre", - "getrandom 0.2.8", "hex", "prettyplease", "proc-macro2", @@ -1675,52 +2129,49 @@ dependencies = [ "reqwest", "serde", "serde_json", - "syn 1.0.109", - "tokio", - "toml 0.7.3", - "url", + "syn 2.0.28", + "toml", "walkdir", ] [[package]] name = "ethers-contract-derive" -version = "2.0.1" -source = "git+https://github.com/gakonst/ethers-rs?rev=80ac394#80ac3947d066bb3e3148edaecf8cd54792452bb2" +version = "2.0.8" +source = "git+https://github.com/gakonst/ethers-rs#594627dc1c3b490ba8f513f8f5e23d11448cbcf8" dependencies = [ + "Inflector", "ethers-contract-abigen", "ethers-core", "hex", "proc-macro2", "quote", - "syn 1.0.109", + "serde_json", + "syn 2.0.28", ] [[package]] name = "ethers-core" -version = "2.0.1" -source = "git+https://github.com/gakonst/ethers-rs?rev=80ac394#80ac3947d066bb3e3148edaecf8cd54792452bb2" +version = "2.0.8" +source = "git+https://github.com/gakonst/ethers-rs#594627dc1c3b490ba8f513f8f5e23d11448cbcf8" dependencies = [ - "arrayvec 0.7.2", + "arrayvec 0.7.4", "bytes", "cargo_metadata", "chrono", - "convert_case 0.6.0", - "elliptic-curve 0.13.2", + "elliptic-curve", "ethabi", - "generic-array 0.14.6", - "getrandom 0.2.8", + "generic-array 0.14.7", "hex", - "k256 0.13.0", + "k256", "num_enum", "once_cell", "open-fastrlp", - "proc-macro2", "rand 0.8.5", "rlp", "serde", "serde_json", - "strum", - "syn 1.0.109", + "strum 0.25.0", + "syn 2.0.28", "tempfile", "thiserror", "tiny-keccak", @@ -1729,14 +2180,13 @@ dependencies = [ [[package]] name = "ethers-etherscan" -version = "2.0.1" -source = "git+https://github.com/gakonst/ethers-rs?rev=80ac394#80ac3947d066bb3e3148edaecf8cd54792452bb2" +version = "2.0.8" +source = "git+https://github.com/gakonst/ethers-rs#594627dc1c3b490ba8f513f8f5e23d11448cbcf8" dependencies = [ "ethers-core", "ethers-solc", - "getrandom 0.2.8", "reqwest", - "semver", + "semver 1.0.18", "serde", "serde_json", "thiserror", @@ -1745,8 +2195,8 @@ dependencies = [ [[package]] name = "ethers-middleware" -version = "2.0.1" -source = "git+https://github.com/gakonst/ethers-rs?rev=80ac394#80ac3947d066bb3e3148edaecf8cd54792452bb2" +version = "2.0.8" +source = "git+https://github.com/gakonst/ethers-rs#594627dc1c3b490ba8f513f8f5e23d11448cbcf8" dependencies = [ "async-trait", "auto_impl", @@ -1771,20 +2221,18 @@ dependencies = [ [[package]] name = "ethers-providers" -version = "2.0.1" -source = "git+https://github.com/gakonst/ethers-rs?rev=80ac394#80ac3947d066bb3e3148edaecf8cd54792452bb2" +version = "2.0.8" +source = "git+https://github.com/gakonst/ethers-rs#594627dc1c3b490ba8f513f8f5e23d11448cbcf8" dependencies = [ "async-trait", "auto_impl", - "base64 0.21.0", + "base64 0.21.2", "bytes", "enr", "ethers-core", - "futures-channel", "futures-core", "futures-timer", "futures-util", - "getrandom 0.2.8", "hashers", "hex", "http", @@ -1808,61 +2256,128 @@ dependencies = [ [[package]] name = "ethers-signers" -version = "2.0.1" -source = "git+https://github.com/gakonst/ethers-rs?rev=80ac394#80ac3947d066bb3e3148edaecf8cd54792452bb2" +version = "2.0.8" +source = "git+https://github.com/gakonst/ethers-rs#594627dc1c3b490ba8f513f8f5e23d11448cbcf8" dependencies = [ "async-trait", "coins-bip32", "coins-bip39", - "elliptic-curve 0.13.2", + "elliptic-curve", "eth-keystore", "ethers-core", "hex", "rand 0.8.5", - "sha2 0.10.6", + "sha2 0.10.7", + "thiserror", + "tracing", +] + +[[package]] +name = "ethers-solc" +version = "2.0.8" +source = "git+https://github.com/gakonst/ethers-rs#594627dc1c3b490ba8f513f8f5e23d11448cbcf8" +dependencies = [ + "cfg-if", + "dirs", + "dunce", + "ethers-core", + "futures-util", + "glob", + "hex", + "home", + "md-5", + "num_cpus", + "once_cell", + "path-slash", + "rayon", + "regex", + "semver 1.0.18", + "serde", + "serde_json", + "sha2 0.10.7", + "solang-parser", + "svm-rs", + "svm-rs-builds", "thiserror", + "tiny-keccak", + "tokio", "tracing", + "walkdir", + "yansi 0.5.1", +] + +[[package]] +name = "event-listener" +version = "2.5.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0206175f82b8d6bf6652ff7d71a1e27fd2e4efde587fd368662814d6ec1d9ce0" + +[[package]] +name = "evm" +version = "0.39.1" +source = "git+https://github.com/rust-blockchain/evm?rev=b7b82c7e1fc57b7449d6dfa6826600de37cc1e65#b7b82c7e1fc57b7449d6dfa6826600de37cc1e65" +dependencies = [ + "auto_impl", + "environmental", + "ethereum", + "evm-core", + "evm-gasometer", + "evm-runtime", + "log", + "parity-scale-codec", + "primitive-types", + "rlp", + "scale-info", + "serde", + "sha3", +] + +[[package]] +name = "evm-core" +version = "0.39.0" +source = "git+https://github.com/rust-blockchain/evm?rev=b7b82c7e1fc57b7449d6dfa6826600de37cc1e65#b7b82c7e1fc57b7449d6dfa6826600de37cc1e65" +dependencies = [ + "parity-scale-codec", + "primitive-types", + "scale-info", + "serde", +] + +[[package]] +name = "evm-gasometer" +version = "0.39.0" +source = "git+https://github.com/rust-blockchain/evm?rev=b7b82c7e1fc57b7449d6dfa6826600de37cc1e65#b7b82c7e1fc57b7449d6dfa6826600de37cc1e65" +dependencies = [ + "environmental", + "evm-core", + "evm-runtime", + "primitive-types", ] [[package]] -name = "ethers-solc" -version = "2.0.1" -source = "git+https://github.com/gakonst/ethers-rs?rev=80ac394#80ac3947d066bb3e3148edaecf8cd54792452bb2" +name = "evm-runtime" +version = "0.39.0" +source = "git+https://github.com/rust-blockchain/evm?rev=b7b82c7e1fc57b7449d6dfa6826600de37cc1e65#b7b82c7e1fc57b7449d6dfa6826600de37cc1e65" dependencies = [ - "cfg-if", - "dunce", - "ethers-core", - "futures-util", - "getrandom 0.2.8", - "glob", - "hex", - "home", - "md-5", - "num_cpus", - "once_cell", - "path-slash", - "rayon", - "regex", - "semver", - "serde", - "serde_json", - "sha2 0.10.6", - "solang-parser", - "svm-rs", - "svm-rs-builds", - "thiserror", - "tiny-keccak", - "tokio", - "tracing", - "walkdir", - "yansi", + "auto_impl", + "environmental", + "evm-core", + "primitive-types", + "sha3", ] [[package]] -name = "event-listener" -version = "2.5.3" +name = "expander" +version = "1.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0206175f82b8d6bf6652ff7d71a1e27fd2e4efde587fd368662814d6ec1d9ce0" +checksum = "f360349150728553f92e4c997a16af8915f418d3a0f21b440d34c5632f16ed84" +dependencies = [ + "blake2", + "fs-err", + "proc-macro2", + "quote", + "syn 1.0.109", +] [[package]] name = "eyre" @@ -1896,13 +2411,20 @@ dependencies = [ ] [[package]] -name = "ff" -version = "0.12.1" +name = "fastrand" +version = "2.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d013fc25338cc558c5c2cfbad646908fb23591e2404481826742b651c9af7160" +checksum = "6999dc1837253364c2ebb0704ba97994bd874e8f195d665c50b7548f6ea92764" + +[[package]] +name = "fastrlp" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "139834ddba373bbdd213dffe02c8d110508dcf1726c2be27e8d1f7d7e1856418" dependencies = [ - "rand_core 0.6.4", - "subtle", + "arrayvec 0.7.4", + "auto_impl", + "bytes", ] [[package]] @@ -1915,16 +2437,22 @@ dependencies = [ "subtle", ] +[[package]] +name = "fiat-crypto" +version = "0.1.20" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e825f6987101665dea6ec934c09ec6d721de7bc1bf92248e1d5810c8cd636b77" + [[package]] name = "figment" -version = "0.10.8" +version = "0.10.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e56602b469b2201400dec66a66aec5a9b8761ee97cd1b8c96ab2483fcc16cc9" +checksum = "4547e226f4c9ab860571e070a9034192b3175580ecea38da34fcdb53a018c9a5" dependencies = [ "atomic", "pear", "serde", - "toml 0.5.11", + "toml", "uncased", "version_check", ] @@ -1949,9 +2477,9 @@ checksum = "0ce7134b9999ecaf8bcd65542e436736ef32ddca1b3e06094cb6ec5755203b80" [[package]] name = "flate2" -version = "1.0.25" +version = "1.0.26" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a8a2db397cb1c8772f31494cb8917e48cd1e64f0fa7efac59fbd741a0a8ce841" +checksum = "3b9429470923de8e8cbd4d2dc513535400b4b3fef0319fb5c4e1f520a7bef743" dependencies = [ "crc32fast", "miniz_oxide", @@ -1966,7 +2494,7 @@ checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1" [[package]] name = "forge" version = "0.2.0" -source = "git+https://github.com/foundry-rs/foundry?rev=6570a4cafef568922a856eef65853642b01e099d#6570a4cafef568922a856eef65853642b01e099d" +source = "git+https://github.com/foundry-rs/foundry?rev=25d3ce7ca1eed4a9f1776103185e4221e8fa0a11#25d3ce7ca1eed4a9f1776103185e4221e8fa0a11" dependencies = [ "comfy-table", "ethers", @@ -1983,45 +2511,60 @@ dependencies = [ "rayon", "regex", "rlp", - "semver", + "semver 1.0.18", "serde", "serde_json", "tokio", "tracing", - "tracing-subscriber 0.3.16", - "yansi", + "tracing-subscriber 0.3.17", + "yansi 0.5.1", ] [[package]] name = "forge-fmt" version = "0.2.0" -source = "git+https://github.com/foundry-rs/foundry?rev=6570a4cafef568922a856eef65853642b01e099d#6570a4cafef568922a856eef65853642b01e099d" +source = "git+https://github.com/foundry-rs/foundry?rev=25d3ce7ca1eed4a9f1776103185e4221e8fa0a11#25d3ce7ca1eed4a9f1776103185e4221e8fa0a11" dependencies = [ "ariadne", "ethers-core", "foundry-config", "itertools", - "semver", + "semver 1.0.18", "solang-parser", "thiserror", + "tracing", ] [[package]] name = "form_urlencoded" -version = "1.1.0" +version = "1.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a9c384f161156f5260c24a097c56119f9be8c798586aecc13afbcbe7b7e26bf8" +checksum = "a62bc1cf6f830c2ec14a513a9fb124d0a213a629668a4186f329db21fe045652" dependencies = [ "percent-encoding", ] +[[package]] +name = "foundry-abi" +version = "0.1.0" +source = "git+https://github.com/foundry-rs/foundry?rev=25d3ce7ca1eed4a9f1776103185e4221e8fa0a11#25d3ce7ca1eed4a9f1776103185e4221e8fa0a11" +dependencies = [ + "ethers-contract", + "ethers-contract-abigen", + "ethers-core", + "ethers-providers", + "eyre", + "foundry-macros", + "syn 2.0.28", +] + [[package]] name = "foundry-common" version = "0.1.0" -source = "git+https://github.com/foundry-rs/foundry?rev=6570a4cafef568922a856eef65853642b01e099d#6570a4cafef568922a856eef65853642b01e099d" +source = "git+https://github.com/foundry-rs/foundry?rev=25d3ce7ca1eed4a9f1776103185e4221e8fa0a11#25d3ce7ca1eed4a9f1776103185e4221e8fa0a11" dependencies = [ - "atty", - "clap 4.1.11", + "auto_impl", + "clap", "comfy-table", "dunce", "ethers-core", @@ -2031,23 +2574,25 @@ dependencies = [ "ethers-solc", "eyre", "foundry-config", + "foundry-macros", + "globset", "once_cell", "regex", "reqwest", - "semver", + "semver 1.0.18", "serde", "serde_json", "tempfile", "thiserror", "tracing", "walkdir", - "yansi", + "yansi 0.5.1", ] [[package]] name = "foundry-config" version = "0.2.0" -source = "git+https://github.com/foundry-rs/foundry?rev=6570a4cafef568922a856eef65853642b01e099d#6570a4cafef568922a856eef65853642b01e099d" +source = "git+https://github.com/foundry-rs/foundry?rev=25d3ce7ca1eed4a9f1776103185e4221e8fa0a11#25d3ce7ca1eed4a9f1776103185e4221e8fa0a11" dependencies = [ "Inflector", "dirs-next", @@ -2063,12 +2608,13 @@ dependencies = [ "path-slash", "regex", "reqwest", - "semver", + "semver 1.0.18", "serde", + "serde_json", "serde_regex", "thiserror", - "toml 0.5.11", - "toml_edit 0.14.4", + "toml", + "toml_edit", "tracing", "walkdir", ] @@ -2076,15 +2622,17 @@ dependencies = [ [[package]] name = "foundry-evm" version = "0.2.0" -source = "git+https://github.com/foundry-rs/foundry?rev=6570a4cafef568922a856eef65853642b01e099d#6570a4cafef568922a856eef65853642b01e099d" +source = "git+https://github.com/foundry-rs/foundry?rev=25d3ce7ca1eed4a9f1776103185e4221e8fa0a11#25d3ce7ca1eed4a9f1776103185e4221e8fa0a11" dependencies = [ "auto_impl", "bytes", "ethers", "eyre", + "foundry-abi", "foundry-common", "foundry-config", "foundry-macros", + "foundry-utils", "futures", "hashbrown 0.13.2", "hex", @@ -2095,41 +2643,44 @@ dependencies = [ "parking_lot", "proptest", "revm", - "semver", + "semver 1.0.18", "serde", "serde_json", "thiserror", "tokio", "tracing", "url", - "yansi", + "walkdir", + "yansi 0.5.1", ] [[package]] name = "foundry-macros" -version = "0.1.0" -source = "git+https://github.com/foundry-rs/foundry?rev=6570a4cafef568922a856eef65853642b01e099d#6570a4cafef568922a856eef65853642b01e099d" +version = "0.2.0" +source = "git+https://github.com/foundry-rs/foundry?rev=25d3ce7ca1eed4a9f1776103185e4221e8fa0a11#25d3ce7ca1eed4a9f1776103185e4221e8fa0a11" dependencies = [ "ethers-core", - "foundry-common", "foundry-macros-impl", + "serde", + "serde_json", ] [[package]] name = "foundry-macros-impl" version = "0.0.0" -source = "git+https://github.com/foundry-rs/foundry?rev=6570a4cafef568922a856eef65853642b01e099d#6570a4cafef568922a856eef65853642b01e099d" +source = "git+https://github.com/foundry-rs/foundry?rev=25d3ce7ca1eed4a9f1776103185e4221e8fa0a11#25d3ce7ca1eed4a9f1776103185e4221e8fa0a11" dependencies = [ "proc-macro2", "quote", - "syn 1.0.109", + "syn 2.0.28", ] [[package]] name = "foundry-utils" version = "0.2.0" -source = "git+https://github.com/foundry-rs/foundry?rev=6570a4cafef568922a856eef65853642b01e099d#6570a4cafef568922a856eef65853642b01e099d" +source = "git+https://github.com/foundry-rs/foundry?rev=25d3ce7ca1eed4a9f1776103185e4221e8fa0a11#25d3ce7ca1eed4a9f1776103185e4221e8fa0a11" dependencies = [ + "dunce", "ethers-addressbook", "ethers-contract", "ethers-core", @@ -2152,10 +2703,44 @@ dependencies = [ "tracing", ] +[[package]] +name = "fp-account" +version = "1.0.0-dev" +source = "git+https://github.com/paritytech/frontier?branch=polkadot-v0.9.42#2499d18c936edbcb7fcb711827db7abb9b4f4da4" +dependencies = [ + "hex", + "impl-serde", + "libsecp256k1", + "log", + "parity-scale-codec", + "scale-info", + "serde", + "sp-core 7.0.0", + "sp-io 7.0.0", + "sp-runtime 7.0.0", + "sp-runtime-interface 7.0.0", + "sp-std 5.0.0", +] + +[[package]] +name = "fp-evm" +version = "3.0.0-dev" +source = "git+https://github.com/paritytech/frontier?branch=polkadot-v0.9.42#2499d18c936edbcb7fcb711827db7abb9b4f4da4" +dependencies = [ + "evm", + "frame-support", + "parity-scale-codec", + "scale-info", + "serde", + "sp-core 7.0.0", + "sp-runtime 7.0.0", + "sp-std 5.0.0", +] + [[package]] name = "frame-benchmarking" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.38#18bb7c7c841b101c19a8d1881b893ae8e37de460" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" dependencies = [ "frame-support", "frame-support-procedural", @@ -2179,9 +2764,21 @@ dependencies = [ [[package]] name = "frame-metadata" -version = "15.0.0" +version = "15.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "878babb0b136e731cc77ec2fd883ff02745ff21e6fb662729953d44923df009c" +dependencies = [ + "cfg-if", + "parity-scale-codec", + "scale-info", + "serde", +] + +[[package]] +name = "frame-metadata" +version = "16.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "df6bb8542ef006ef0de09a5c4420787d79823c0ed7924225822362fd2bf2ff2d" +checksum = "87cf1549fba25a6fcac22785b61698317d958e96cac72a59102ea45b9ae64692" dependencies = [ "cfg-if", "parity-scale-codec", @@ -2192,20 +2789,21 @@ dependencies = [ [[package]] name = "frame-support" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.38#18bb7c7c841b101c19a8d1881b893ae8e37de460" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" dependencies = [ "bitflags 1.3.2", - "frame-metadata", + "environmental", + "frame-metadata 15.1.0", "frame-support-procedural", "impl-trait-for-tuples", - "k256 0.11.6", + "k256", "log", "once_cell", "parity-scale-codec", "paste", "scale-info", "serde", - "smallvec", + "smallvec 1.11.0", "sp-api", "sp-arithmetic 6.0.0", "sp-core 7.0.0", @@ -2224,44 +2822,45 @@ dependencies = [ [[package]] name = "frame-support-procedural" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.38#18bb7c7c841b101c19a8d1881b893ae8e37de460" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" dependencies = [ "Inflector", "cfg-expr", "derive-syn-parse", "frame-support-procedural-tools", "itertools", + "proc-macro-warning", "proc-macro2", "quote", - "syn 1.0.109", + "syn 2.0.28", ] [[package]] name = "frame-support-procedural-tools" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.38#18bb7c7c841b101c19a8d1881b893ae8e37de460" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" dependencies = [ "frame-support-procedural-tools-derive", "proc-macro-crate", "proc-macro2", "quote", - "syn 1.0.109", + "syn 2.0.28", ] [[package]] name = "frame-support-procedural-tools-derive" version = "3.0.0" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.38#18bb7c7c841b101c19a8d1881b893ae8e37de460" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" dependencies = [ "proc-macro2", "quote", - "syn 1.0.109", + "syn 2.0.28", ] [[package]] name = "frame-system" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.38#18bb7c7c841b101c19a8d1881b893ae8e37de460" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" dependencies = [ "frame-support", "log", @@ -2276,6 +2875,12 @@ dependencies = [ "sp-weights 4.0.0", ] +[[package]] +name = "fs-err" +version = "2.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0845fa252299212f0389d64ba26f34fa32cfe41588355f21ed507c59a0f64541" + [[package]] name = "fs2" version = "0.4.3" @@ -2294,9 +2899,9 @@ checksum = "e6d5a32815ae3f33302d95fdcb2ce17862f8c65363dcfd29360480ba1001fc9c" [[package]] name = "futures" -version = "0.3.27" +version = "0.3.28" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "531ac96c6ff5fd7c62263c5e3c67a603af4fcaee2e1a0ae5565ba3a11e69e549" +checksum = "23342abe12aba583913b2e62f22225ff9c950774065e4bfb61a19cd9770fec40" dependencies = [ "futures-channel", "futures-core", @@ -2309,9 +2914,9 @@ dependencies = [ [[package]] name = "futures-channel" -version = "0.3.27" +version = "0.3.28" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "164713a5a0dcc3e7b4b1ed7d3b433cabc18025386f9339346e8daf15963cf7ac" +checksum = "955518d47e09b25bbebc7a18df10b81f0c766eaf4c4f1cccef2fca5f2a4fb5f2" dependencies = [ "futures-core", "futures-sink", @@ -2319,15 +2924,15 @@ dependencies = [ [[package]] name = "futures-core" -version = "0.3.27" +version = "0.3.28" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "86d7a0c1aa76363dac491de0ee99faf6941128376f1cf96f07db7603b7de69dd" +checksum = "4bca583b7e26f571124fe5b7561d49cb2868d79116cfa0eefce955557c6fee8c" [[package]] name = "futures-executor" -version = "0.3.27" +version = "0.3.28" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1997dd9df74cdac935c76252744c1ed5794fac083242ea4fe77ef3ed60ba0f83" +checksum = "ccecee823288125bd88b4d7f565c9e58e41858e47ab72e8ea2d64e93624386e0" dependencies = [ "futures-core", "futures-task", @@ -2337,9 +2942,24 @@ dependencies = [ [[package]] name = "futures-io" -version = "0.3.27" +version = "0.3.28" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4fff74096e71ed47f8e023204cfd0aa1289cd54ae5430a9523be060cdb849964" + +[[package]] +name = "futures-lite" +version = "1.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "89d422fa3cbe3b40dca574ab087abb5bc98258ea57eea3fd6f1fa7162c778b91" +checksum = "49a9d51ce47660b1e808d3c990b4709f2f415d928835a17dfd16991515c46bce" +dependencies = [ + "fastrand 1.9.0", + "futures-core", + "futures-io", + "memchr", + "parking", + "pin-project-lite", + "waker-fn", +] [[package]] name = "futures-locks" @@ -2353,26 +2973,26 @@ dependencies = [ [[package]] name = "futures-macro" -version = "0.3.27" +version = "0.3.28" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3eb14ed937631bd8b8b8977f2c198443447a8355b6e3ca599f38c975e5a963b6" +checksum = "89ca545a94061b6365f2c7355b4b32bd20df3ff95f02da9329b34ccc3bd6ee72" dependencies = [ "proc-macro2", "quote", - "syn 1.0.109", + "syn 2.0.28", ] [[package]] name = "futures-sink" -version = "0.3.27" +version = "0.3.28" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec93083a4aecafb2a80a885c9de1f0ccae9dbd32c2bb54b0c3a65690e0b8d2f2" +checksum = "f43be4fe21a13b9781a69afa4985b0f6ee0e1afab2c6f454a8cf30e2b2237b6e" [[package]] name = "futures-task" -version = "0.3.27" +version = "0.3.28" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fd65540d33b37b16542a0438c12e6aeead10d4ac5d05bd3f805b8f35ab592879" +checksum = "76d3d132be6c0e6aa1534069c705a74a5997a356c0dc2f86a47765e5617c5b65" [[package]] name = "futures-timer" @@ -2386,9 +3006,9 @@ dependencies = [ [[package]] name = "futures-util" -version = "0.3.27" +version = "0.3.28" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3ef6b17e481503ec85211fed8f39d1970f128935ca1f814cd32ac4a6842e84ab" +checksum = "26b01e40b772d54cf6c6d721c1d1abd0647a0106a12ecaa1c186273392a69533" dependencies = [ "futures-channel", "futures-core", @@ -2422,9 +3042,9 @@ dependencies = [ [[package]] name = "generic-array" -version = "0.14.6" +version = "0.14.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bff49e947297f3312447abdca79f45f4738097cc82b06e72054d2223f601f1b9" +checksum = "85649ca51fd72272d7821adaf274ad91c288277713d9c18820d8499a7ff69e9a" dependencies = [ "typenum", "version_check", @@ -2444,9 +3064,9 @@ dependencies = [ [[package]] name = "getrandom" -version = "0.2.8" +version = "0.2.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c05aeb6a22b8f62540c194aac980f2115af067bfe15a0734d7277a768d396b31" +checksum = "be4136b2a15dd319360be1c07d9933517ccf0be8f16bf62a3bee4f0d618df427" dependencies = [ "cfg-if", "js-sys", @@ -2455,6 +3075,16 @@ dependencies = [ "wasm-bindgen", ] +[[package]] +name = "ghash" +version = "0.4.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1583cc1656d7839fd3732b80cf4f38850336cdb9b8ded1cd399ca62958de3c99" +dependencies = [ + "opaque-debug 0.3.0", + "polyval", +] + [[package]] name = "gimli" version = "0.26.2" @@ -2467,9 +3097,14 @@ dependencies = [ [[package]] name = "gimli" -version = "0.27.2" +version = "0.27.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ad0a93d233ebf96623465aad4046a8d3aa4da22d4f4beba5388838c8a434bbb4" +checksum = "b6c80984affa11d98d1b88b66ac8853f143217b399d3c74116778ff8fdb4ed2e" +dependencies = [ + "fallible-iterator", + "indexmap 1.9.3", + "stable_deref_trait", +] [[package]] name = "glob" @@ -2479,9 +3114,9 @@ checksum = "d2fabcfbdc87f4758337ca535fb41a6d701b65693ce38287d856d1674551ec9b" [[package]] name = "globset" -version = "0.4.10" +version = "0.4.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "029d74589adefde59de1a0c4f4732695c32805624aec7b68d91503d4dba79afc" +checksum = "aca8bbd8e0707c1887a8bbb7e6b40e228f251ff5d62c8220a4a7a53c73aff006" dependencies = [ "aho-corasick", "bstr", @@ -2502,33 +3137,22 @@ dependencies = [ "wasm-bindgen", ] -[[package]] -name = "group" -version = "0.12.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5dfbfb3a6cfbd390d5c9564ab283a0349b9b9fcd46a706c1eb10e0db70bfbac7" -dependencies = [ - "ff 0.12.1", - "rand_core 0.6.4", - "subtle", -] - [[package]] name = "group" version = "0.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f0f9ef7462f7c099f518d754361858f86d8a07af53ba9af0fe635bbccb151a63" dependencies = [ - "ff 0.13.0", + "ff", "rand_core 0.6.4", "subtle", ] [[package]] name = "h2" -version = "0.3.16" +version = "0.3.20" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5be7b54589b581f624f566bf5d8eb2bab1db736c51528720b6bd36b96b55924d" +checksum = "97ec8491ebaf99c8eaa73058b045fe58073cd6be7f596ac993ced0b0a0c01049" dependencies = [ "bytes", "fnv", @@ -2536,7 +3160,7 @@ dependencies = [ "futures-sink", "futures-util", "http", - "indexmap", + "indexmap 1.9.3", "slab", "tokio", "tokio-util", @@ -2549,6 +3173,12 @@ version = "0.15.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d23bd4e7b5eda0d0f3a307e8b381fdc8ba9000f26fbe912250c0a4cc3956364a" +[[package]] +name = "hash-db" +version = "0.16.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8e7d7786361d7425ae2fe4f9e407eb0efaa0840f5212d109cc018c40c35c6ab4" + [[package]] name = "hash256-std-hasher" version = "0.15.2" @@ -2577,6 +3207,15 @@ dependencies = [ "serde", ] +[[package]] +name = "hashbrown" +version = "0.14.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2c6201b9ff9fd90a5a3bac2e56a830d0caa509576f0e503818ee82c181b3437a" +dependencies = [ + "serde", +] + [[package]] name = "hashers" version = "1.0.1" @@ -2594,27 +3233,9 @@ checksum = "95505c38b4572b2d910cecb0281560f54b440a19336cbbcb27bf6ce6adc6f5a8" [[package]] name = "hermit-abi" -version = "0.1.19" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "62b467343b94ba476dcb2500d242dadbb39557df889310ac77c5d99100aaac33" -dependencies = [ - "libc", -] - -[[package]] -name = "hermit-abi" -version = "0.2.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ee512640fe35acbfb4bb779db6f0d80704c2cacfa2e39b601ef3e3f47d1ae4c7" -dependencies = [ - "libc", -] - -[[package]] -name = "hermit-abi" -version = "0.3.1" +version = "0.3.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fed44880c466736ef9a5c5b5facefb5ed0785676d0c02d612db14e54f0d84286" +checksum = "443144c8cdadd93ebf52ddb4056d257f5b52c04d3c804e657d19eb73fc33668b" [[package]] name = "hex" @@ -2627,9 +3248,9 @@ dependencies = [ [[package]] name = "hex-literal" -version = "0.3.4" +version = "0.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7ebdb29d2ea9ed0083cd8cece49bbd968021bd99b0849edb4a9a7ee0fdf6a4e0" +checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" [[package]] name = "hmac" @@ -2657,7 +3278,7 @@ version = "0.12.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6c49c37c09c17a53d937dfbb742eb3a961d65a994e6bcdcf37e7399d0cc8ab5e" dependencies = [ - "digest 0.10.6", + "digest 0.10.7", ] [[package]] @@ -2667,17 +3288,17 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "17ea0a1394df5b6574da6e0c1ade9e78868c9fb0a4e5ef4428e32da4676b85b1" dependencies = [ "digest 0.9.0", - "generic-array 0.14.6", + "generic-array 0.14.7", "hmac 0.8.1", ] [[package]] name = "home" -version = "0.5.4" +version = "0.5.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "747309b4b440c06d57b0b25f2aee03ee9b5e5397d288c60e21fc709bb98a7408" +checksum = "5444c27eef6923071f7ebcc33e3444508466a76f7a2b93da00ed6e19f30c1ddb" dependencies = [ - "winapi", + "windows-sys 0.48.0", ] [[package]] @@ -2716,9 +3337,9 @@ checksum = "c4a1e36c821dbe04574f602848a19f742f4fb3c98d40449f11bcad18d6b17421" [[package]] name = "hyper" -version = "0.14.25" +version = "0.14.27" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cc5e554ff619822309ffd57d8734d77cd5ce6238bc956f037ea06c58238c9899" +checksum = "ffb1cfd654a8219eaef89881fdb3bb3b1cdc5fa75ded05d6933b2b382e395468" dependencies = [ "bytes", "futures-channel", @@ -2747,18 +3368,32 @@ dependencies = [ "http", "hyper", "log", - "rustls", + "rustls 0.20.8", "rustls-native-certs", "tokio", - "tokio-rustls", - "webpki-roots", + "tokio-rustls 0.23.4", + "webpki-roots 0.22.6", +] + +[[package]] +name = "hyper-rustls" +version = "0.24.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8d78e1e73ec14cf7375674f74d7dde185c8206fd9dea6fb6295e8a98098aaa97" +dependencies = [ + "futures-util", + "http", + "hyper", + "rustls 0.21.5", + "tokio", + "tokio-rustls 0.24.1", ] [[package]] name = "iana-time-zone" -version = "0.1.54" +version = "0.1.57" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0c17cc76786e99f8d2f055c11159e7f0091c42474dcc3189fbab96072e873e6d" +checksum = "2fad5b825842d2b38bd206f3e81d6957625fd7f0a361e345c30e01a0ae2dd613" dependencies = [ "android_system_properties", "core-foundation-sys", @@ -2770,12 +3405,11 @@ dependencies = [ [[package]] name = "iana-time-zone-haiku" -version = "0.1.1" +version = "0.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0703ae284fc167426161c2e3f1da3ea71d94b21bedbcc9494e92b28e334e3dca" +checksum = "f31827a206f56af32e590ba56d5d2d085f558508192593743f16b2306495269f" dependencies = [ - "cxx", - "cxx-build", + "cc", ] [[package]] @@ -2786,9 +3420,9 @@ checksum = "b9e0384b61958566e926dc50660321d12159025e767c18e043daf26b70104c39" [[package]] name = "idna" -version = "0.3.0" +version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e14ddfc70884202db2244c223200c204c2bda1bc6e0998d11b5e024d657209e6" +checksum = "7d20d6b07bfbc108882d88ed8e37d39636dcc260e15e30c45e6ba089610b917c" dependencies = [ "unicode-bidi", "unicode-normalization", @@ -2840,9 +3474,9 @@ checksum = "ce23b50ad8242c51a442f3ff322d56b02f08852c77e4c0b4d3fd684abc89c683" [[package]] name = "indexmap" -version = "1.9.2" +version = "1.9.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1885e79c1fc4b10f0e172c475f458b7f7b93061064d98c3293e98c5ba0c8b399" +checksum = "bd070e393353796e801d209ad339e89596eb4c8d430d18ede6a1cced8fafbd99" dependencies = [ "autocfg", "hashbrown 0.12.3", @@ -2850,17 +3484,21 @@ dependencies = [ ] [[package]] -name = "indicatif" -version = "0.16.2" +name = "indexmap" +version = "2.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2d207dc617c7a380ab07ff572a6e52fa202a2a8f355860ac9c38e23f8196be1b" +checksum = "d5477fe2230a79769d8dc68e0eabf5437907c0457a5614a9e8dddb67f65eb65d" dependencies = [ - "console 0.15.5", - "lazy_static", - "number_prefix", - "regex", + "equivalent", + "hashbrown 0.14.0", ] +[[package]] +name = "indexmap-nostd" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8e04e2fd2b8188ea827b32ef11de88377086d690286ab35747ef7f9bf3ccb590" + [[package]] name = "inlinable_string" version = "0.1.15" @@ -2873,7 +3511,7 @@ version = "0.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a0c10553d664a4d0bcff9f4215d0aac67a639cc68ef660840afe309b807bc9f5" dependencies = [ - "generic-array 0.14.6", + "generic-array 0.14.7", ] [[package]] @@ -2894,6 +3532,12 @@ dependencies = [ "num-traits", ] +[[package]] +name = "intx" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f6f38a50a899dc47a6d0ed5508e7f601a2e34c3a85303514b5d137f3c10a0c75" + [[package]] name = "io-lifetimes" version = "0.7.5" @@ -2901,40 +3545,94 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "59ce5ef949d49ee85593fc4d3f3f95ad61657076395cbbce23e2121fc5542074" [[package]] -name = "io-lifetimes" -version = "1.0.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "09270fd4fa1111bc614ed2246c7ef56239a3063d5be0d1ec3b589c505d400aeb" +name = "io-lifetimes" +version = "1.0.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "eae7b9aee968036d54dce06cebaefd919e4472e753296daccd6d344e3e2df0c2" +dependencies = [ + "hermit-abi", + "libc", + "windows-sys 0.48.0", +] + +[[package]] +name = "ipnet" +version = "2.8.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "28b29a3cd74f0f4598934efe3aeba42bae0eb4680554128851ebbecb02af14e6" + +[[package]] +name = "is-terminal" +version = "0.4.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cb0889898416213fab133e1d33a0e5858a48177452750691bde3666d0fdbaf8b" +dependencies = [ + "hermit-abi", + "rustix 0.38.4", + "windows-sys 0.48.0", +] + +[[package]] +name = "ismp" +version = "0.1.0" +source = "git+https://github.com/polytope-labs/ismp-rs?branch=main#317cb2ffc16d4d5b0b50dfee282728bf70fc0641" dependencies = [ - "hermit-abi 0.3.1", - "libc", - "windows-sys 0.45.0", + "derive_more", + "parity-scale-codec", + "primitive-types", + "scale-info", + "serde", + "serde_json", ] [[package]] -name = "ipnet" -version = "2.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "30e22bd8629359895450b59ea7a776c850561b96a3b1d31321c1949d9e6c9146" +name = "ismp-evm" +version = "0.1.0" +source = "git+https://github.com/polytope-labs/ismp-substrate?branch=main#356a516c7b451490d4758bb05182233a26a4de88" +dependencies = [ + "alloy-primitives", + "alloy-sol-types", + "fp-evm", + "frame-support", + "frame-system", + "hex-literal", + "ismp", + "ismp-primitives", + "pallet-evm", + "pallet-ismp", + "parity-scale-codec", + "sp-core 7.0.0", + "sp-runtime 7.0.0", + "sp-std 5.0.0", +] [[package]] -name = "is-terminal" -version = "0.4.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8687c819457e979cc940d09cb16e42a1bf70aa6b60a549de6d3a62a0ee90c69e" +name = "ismp-primitives" +version = "0.1.0" +source = "git+https://github.com/polytope-labs/ismp-substrate?branch=main#356a516c7b451490d4758bb05182233a26a4de88" dependencies = [ - "hermit-abi 0.3.1", - "io-lifetimes 1.0.9", - "rustix 0.36.11", - "windows-sys 0.45.0", + "ckb-merkle-mountain-range 0.5.2 (registry+https://github.com/rust-lang/crates.io-index)", + "frame-support", + "frame-system", + "ismp", + "parity-scale-codec", + "primitive-types", + "scale-info", + "serde", + "sp-consensus-aura", + "sp-core 7.0.0", + "sp-runtime 7.0.0", ] [[package]] name = "ismp-solidity-test" version = "0.1.0" dependencies = [ + "anyhow", "beefy-prover", "beefy-verifier-primitives", + "bytes", + "ckb-merkle-mountain-range 0.5.2 (registry+https://github.com/rust-lang/crates.io-index)", "ckb-merkle-mountain-range 0.5.2 (git+https://github.com/polytope-labs/merkle-mountain-range?branch=seun/simplified-mmr)", "ethers", "forge", @@ -2944,20 +3642,23 @@ dependencies = [ "futures", "hex", "hex-literal", + "ismp", + "ismp-evm", + "ismp-primitives", "libfuzzer-sys", "once_cell", "parity-scale-codec", - "patricia-merkle-trie", "primitive-types", "rs_merkle", - "serde_json", - "sp-beefy", + "sp-consensus-beefy", "sp-core 17.0.0", "sp-runtime 17.0.0", "sp-trie 17.0.0", "subxt", "tokio", - "trie-db", + "tracing", + "tracing-subscriber 0.3.17", + "trie-db 0.24.0", ] [[package]] @@ -2971,9 +3672,9 @@ dependencies = [ [[package]] name = "itoa" -version = "1.0.6" +version = "1.0.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "453ad9f582a441959e5f0d088b02ce04cfe8d51a8eaf077f12ac6d3e94164ca6" +checksum = "af150ab688ff2122fcef229be89cb50dd66af9e01a4ff320cc137eecc9bacc38" [[package]] name = "jobserver" @@ -2986,9 +3687,9 @@ dependencies = [ [[package]] name = "js-sys" -version = "0.3.61" +version = "0.3.64" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "445dde2150c55e483f3d8416706b97ec8e8237c307e5b7b4b8dd15e6af2a0730" +checksum = "c5f195fe497f702db0f318b07fdd68edb16955aed830df8363d837542f8f935a" dependencies = [ "wasm-bindgen", ] @@ -3034,10 +3735,10 @@ dependencies = [ "soketto", "thiserror", "tokio", - "tokio-rustls", + "tokio-rustls 0.23.4", "tokio-util", "tracing", - "webpki-roots", + "webpki-roots 0.22.6", ] [[package]] @@ -3047,7 +3748,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a4e70b4439a751a5de7dd5ed55eacff78ebf4ffe0fc009cb1ebb11417f5b536b" dependencies = [ "anyhow", - "arrayvec 0.7.2", + "arrayvec 0.7.4", "async-lock", "async-trait", "beef", @@ -3076,7 +3777,7 @@ checksum = "cc345b0a43c6bc49b947ebeb936e886a419ee3d894421790c969cc56040542ad" dependencies = [ "async-trait", "hyper", - "hyper-rustls", + "hyper-rustls 0.23.2", "jsonrpsee-core", "jsonrpsee-types", "rustc-hash", @@ -3138,36 +3839,23 @@ dependencies = [ [[package]] name = "k256" -version = "0.11.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "72c1e0b51e7ec0a97369623508396067a486bd0cbed95a2659a4b863d28cfc8b" -dependencies = [ - "cfg-if", - "ecdsa 0.14.8", - "elliptic-curve 0.12.3", - "sha2 0.10.6", - "sha3", -] - -[[package]] -name = "k256" -version = "0.13.0" +version = "0.13.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "955890845095ccf31ef83ad41a05aabb4d8cc23dc3cac5a9f5c89cf26dd0da75" +checksum = "cadb76004ed8e97623117f3df85b17aaa6626ab0b0831e6573f104df16cd1bcc" dependencies = [ "cfg-if", - "ecdsa 0.16.1", - "elliptic-curve 0.13.2", + "ecdsa", + "elliptic-curve", "once_cell", - "sha2 0.10.6", - "signature 2.0.0", + "sha2 0.10.7", + "signature 2.1.0", ] [[package]] name = "keccak" -version = "0.1.3" +version = "0.1.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3afef3b6eff9ce9d8ff9b3601125eec7f0c8cbac7abd14f355d053fa56c98768" +checksum = "8f6d5ed8676d904364de097082f4e7d240b571b67989ced0240f08b7f966f940" dependencies = [ "cpufeatures", ] @@ -3178,26 +3866,25 @@ version = "0.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e7d770dcb02bf6835887c3a979b5107a04ff4bbde97a5f0928d27404a155add9" dependencies = [ - "smallvec", + "smallvec 1.11.0", ] [[package]] name = "lalrpop" -version = "0.19.8" +version = "0.20.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b30455341b0e18f276fa64540aff54deafb54c589de6aca68659c63dd2d5d823" +checksum = "da4081d44f4611b66c6dd725e6de3169f9f63905421e8626fcb86b6a898998b8" dependencies = [ "ascii-canvas", - "atty", "bit-set", "diff", "ena", + "is-terminal", "itertools", "lalrpop-util", "petgraph", - "pico-args", "regex", - "regex-syntax", + "regex-syntax 0.7.4", "string_cache", "term", "tiny-keccak", @@ -3206,12 +3893,9 @@ dependencies = [ [[package]] name = "lalrpop-util" -version = "0.19.8" +version = "0.20.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bcf796c978e9b4d983414f4caedc9273aa33ee214c5b887bd55fde84c85d2dc4" -dependencies = [ - "regex", -] +checksum = "3f35c735096c0293d313e8f2a641627472b83d01b937177fe76e5e2708d31e0d" [[package]] name = "lazy_static" @@ -3219,14 +3903,14 @@ version = "1.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e2abad23fbc42b3700f2f279844dc832adb2b2eb069b2df918f455c4e18cc646" dependencies = [ - "spin", + "spin 0.5.2", ] [[package]] name = "libc" -version = "0.2.140" +version = "0.2.147" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "99227334921fae1a979cf0bfdfcc6b3e5ce376ef57e16fb6fb3ea2ed6095f80c" +checksum = "b4668fb0ea861c1df094127ac5f1da3409a82116a4ba74fca2e58ef927159bb3" [[package]] name = "libfuzzer-sys" @@ -3241,9 +3925,15 @@ dependencies = [ [[package]] name = "libm" -version = "0.2.6" +version = "0.1.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7fc7aa29613bd6a620df431842069224d8bc9011086b1db4c0e0cd47fa03ec9a" + +[[package]] +name = "libm" +version = "0.2.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "348108ab3fba42ec82ff6e9564fc4ca0247bdccdc68dd8af9764bbc79c3c8ffb" +checksum = "f7012b1bbb0719e1097c47611d3898568c546d597c2e74d66f6087edd5233ff4" [[package]] name = "libsecp256k1" @@ -3293,23 +3983,13 @@ dependencies = [ "libsecp256k1-core", ] -[[package]] -name = "link-cplusplus" -version = "1.0.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ecd207c9c713c34f95a097a5b029ac2ce6010530c7b49d7fea24d977dede04f5" -dependencies = [ - "cc", -] - [[package]] name = "linregress" -version = "0.4.4" +version = "0.5.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d6c601a85f5ecd1aba625247bca0031585fb1c446461b142878a16f8245ddeb8" +checksum = "4de0b5f52a9f84544d268f5fabb71b38962d6aa3c6600b8bcd27d44ccf9c9c45" dependencies = [ "nalgebra", - "statrs", ] [[package]] @@ -3324,11 +4004,23 @@ version = "0.1.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f051f77a7c8e6957c0696eac88f26b0117e54f52d3fc682ab19397a8812846a4" +[[package]] +name = "linux-raw-sys" +version = "0.3.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ef53942eb7bf7ff43a617b3e2c1c4a5ecf5944a7c1bc12d7ee39bbb15e5c1519" + +[[package]] +name = "linux-raw-sys" +version = "0.4.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "57bcfdad1b858c2db7c38303a6d2ad4dfaf5eb53dfeb0910128b2c26d6158503" + [[package]] name = "lock_api" -version = "0.4.9" +version = "0.4.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "435011366fe56583b16cf956f9df0095b405b82d76425bc8981c0e22e60ec4df" +checksum = "c1cc9717a20b1bb222f333e6a92fd32f7d8a18ddc5a3191a11af45dcbf4dcd16" dependencies = [ "autocfg", "scopeguard", @@ -3336,12 +4028,9 @@ dependencies = [ [[package]] name = "log" -version = "0.4.17" +version = "0.4.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "abb12e687cfb44aa40f41fc3978ef76448f9b6038cad6aef4259d3c095a2382e" -dependencies = [ - "cfg-if", -] +checksum = "b06a4cde4c0f271a446782e3eff8de789548ce57dbc8eca9292c27f4a42004b4" [[package]] name = "lru" @@ -3352,6 +4041,12 @@ dependencies = [ "hashbrown 0.12.3", ] +[[package]] +name = "lru" +version = "0.10.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "718e8fae447df0c7e1ba7f5189829e63fd536945c8988d61444c19039f16b670" + [[package]] name = "mach" version = "0.3.2" @@ -3367,25 +4062,32 @@ version = "0.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f099785f7595cc4b4553a174ce30dd7589ef93391ff414dbb67f62392b9e0ce1" dependencies = [ - "regex-automata", + "regex-automata 0.1.10", ] [[package]] name = "matrixmultiply" -version = "0.3.2" +version = "0.3.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "add85d4dd35074e6fedc608f8c8f513a3548619a9024b751949ef0e8e45a4d84" +checksum = "090126dc04f95dc0d1c1c91f61bdd474b3930ca064c1edc8a849da2c6cbe1e77" dependencies = [ + "autocfg", "rawpointer", ] +[[package]] +name = "maybe-uninit" +version = "2.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "60302e4db3a61da70c0cb7991976248362f30319e88850c487b9b95bbf059e00" + [[package]] name = "md-5" version = "0.10.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6365506850d44bff6e2fbcb5176cf63650e48bd45ef2fe2665ae1570e0f4b9ca" dependencies = [ - "digest 0.10.6", + "digest 0.10.7", ] [[package]] @@ -3396,11 +4098,11 @@ checksum = "2dffe52ecf27772e601905b7522cb4ef790d2cc203488bbd0e2fe85fcb74566d" [[package]] name = "memfd" -version = "0.6.2" +version = "0.6.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b20a59d985586e4a5aef64564ac77299f8586d8be6cf9106a5a40207e8908efb" +checksum = "ffc89ccdc6e10d6907450f753537ebc5c5d3460d2e4e62ea74bd571db62c0f9e" dependencies = [ - "rustix 0.36.11", + "rustix 0.37.23", ] [[package]] @@ -3422,14 +4124,12 @@ dependencies = [ ] [[package]] -name = "memory-db" -version = "0.30.0" +name = "memoffset" +version = "0.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "34ac11bb793c28fa095b7554466f53b3a60a2cd002afdac01bcf135cbd73a269" +checksum = "5a634b1c61a95585bd15607c6ab0c4e5b226e695ff2800ba0cdccddf208c406c" dependencies = [ - "hash-db", - "hashbrown 0.12.3", - "parity-util-mem", + "autocfg", ] [[package]] @@ -3438,10 +4138,19 @@ version = "0.31.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "5e0c7cba9ce19ac7ffd2053ac9f49843bbd3f4318feedfd74e85c19d5fb0ba66" dependencies = [ - "hash-db", + "hash-db 0.15.2", "hashbrown 0.12.3", ] +[[package]] +name = "memory-db" +version = "0.32.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "808b50db46293432a45e63bc15ea51e0ab4c0a1647b8eb114e31a3e698dd6fbe" +dependencies = [ + "hash-db 0.16.0", +] + [[package]] name = "memory_units" version = "0.4.0" @@ -3460,6 +4169,18 @@ dependencies = [ "zeroize", ] +[[package]] +name = "merlin" +version = "3.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "58c38e2799fc0978b65dfff8023ec7843e2330bb462f19198840b34b6582397d" +dependencies = [ + "byteorder", + "keccak", + "rand_core 0.6.4", + "zeroize", +] + [[package]] name = "micromath" version = "2.0.0" @@ -3472,31 +4193,37 @@ version = "0.3.17" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6877bb514081ee2a7ff5ef9de3281f14a4dd4bceac4c09388074a6b5df8a139a" +[[package]] +name = "minimal-lexical" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "68354c5c6bd36d73ff3feceb05efa59b6acb7626617f4962be322a825e61f79a" + [[package]] name = "miniz_oxide" -version = "0.6.2" +version = "0.7.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b275950c28b37e794e8c55d88aeb5e139d0ce23fdbbeda68f8d7174abdf9e8fa" +checksum = "e7810e0be55b428ada41041c41f32c9f1a42817901b4ccf45fa3d4b6561e74c7" dependencies = [ "adler", ] [[package]] name = "mio" -version = "0.8.6" +version = "0.8.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b9d9a46eff5b4ff64b45a9e316a6d1e0bc719ef429cbec4dc630684212bfdf9" +checksum = "927a765cd3fc26206e66b296465fa9d3e5ab003e651c1b3c060e7956d96b19d2" dependencies = [ "libc", "log", "wasi 0.11.0+wasi-snapshot-preview1", - "windows-sys 0.45.0", + "windows-sys 0.48.0", ] [[package]] name = "mmr-rpc" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.38#18bb7c7c841b101c19a8d1881b893ae8e37de460" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" dependencies = [ "anyhow", "jsonrpsee", @@ -3511,9 +4238,9 @@ dependencies = [ [[package]] name = "nalgebra" -version = "0.27.1" +version = "0.32.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "462fffe4002f4f2e1f6a9dcf12cc1a6fc0e15989014efc02a941d3e0f5dc2120" +checksum = "307ed9b18cc2423f29e83f84fd23a8e73628727990181f18641a8b5dc2ab1caa" dependencies = [ "approx", "matrixmultiply", @@ -3521,17 +4248,15 @@ dependencies = [ "num-complex", "num-rational", "num-traits", - "rand 0.8.5", - "rand_distr", "simba", "typenum", ] [[package]] name = "nalgebra-macros" -version = "0.1.0" +version = "0.2.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "01fcc0b8149b4632adc89ac3b7b31a12fb6099a0317a4eb2ebff574ef7de7218" +checksum = "91761aed67d03ad966ef783ae962ef9bbaca728d2dd7ceb7939ec110fffad998" dependencies = [ "proc-macro2", "quote", @@ -3544,12 +4269,34 @@ version = "1.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e4a24736216ec316047a1fc4252e27dabb04218aa4a3f37c6e7ddbf1f9782b54" +[[package]] +name = "no-std-net" +version = "0.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "43794a0ace135be66a25d3ae77d41b91615fb68ae937f904090203e81f755b65" + +[[package]] +name = "nodrop" +version = "0.1.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "72ef4a56884ca558e5ddb05a1d1e7e1bfd9a68d9ed024c21704cc98872dae1bb" + [[package]] name = "nohash-hasher" version = "0.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "2bf50223579dc7cdcfb3bfcacf7069ff68243f8c363f62ffa99cf000a6b9c451" +[[package]] +name = "nom" +version = "7.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d273983c5a657a70a3e8f2a01329822f3b8c8172b73826411a55751e404a0a4a" +dependencies = [ + "memchr", + "minimal-lexical", +] + [[package]] name = "nu-ansi-term" version = "0.46.0" @@ -3562,9 +4309,9 @@ dependencies = [ [[package]] name = "num" -version = "0.4.0" +version = "0.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "43db66d1170d347f9a065114077f7dccb00c1b9478c89384490a3425279a4606" +checksum = "b05180d69e3da0e530ba2a1dae5110317e49e3b7f3d41be227dc5f92e49ee7af" dependencies = [ "num-bigint", "num-complex", @@ -3600,7 +4347,7 @@ version = "0.4.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a652d9771a63711fd3c3deb670acfbe5c30a4072e664d7a3bf5a9e1056ac72c3" dependencies = [ - "arrayvec 0.7.2", + "arrayvec 0.7.4", "itoa", ] @@ -3639,43 +4386,43 @@ dependencies = [ [[package]] name = "num-traits" -version = "0.2.15" +version = "0.2.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "578ede34cf02f8924ab9447f50c28075b4d3e5b269972345e7e0372b38c6cdcd" +checksum = "f30b0abd723be7e2ffca1272140fac1a2f084c77ec3e123c192b66af1ee9e6c2" dependencies = [ "autocfg", - "libm", + "libm 0.2.7", ] [[package]] name = "num_cpus" -version = "1.15.0" +version = "1.16.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0fac9e2da13b5eb447a6ce3d392f23a29d8694bff781bf03a16cd9ac8697593b" +checksum = "4161fcb6d602d4d2081af7c3a45852d875a03dd337a6bfdd6e06407b61342a43" dependencies = [ - "hermit-abi 0.2.6", + "hermit-abi", "libc", ] [[package]] name = "num_enum" -version = "0.5.11" +version = "0.6.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1f646caf906c20226733ed5b1374287eb97e3c2a5c227ce668c1f2ce20ae57c9" +checksum = "7a015b430d3c108a207fd776d2e2196aaf8b1cf8cf93253e3a097ff3085076a1" dependencies = [ "num_enum_derive", ] [[package]] name = "num_enum_derive" -version = "0.5.11" +version = "0.6.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dcbff9bc912032c62bf65ef1d5aea88983b420f4f839db1e9b0c281a25c9c799" +checksum = "96667db765a921f7b295ffee8b60472b686a51d4f21c2ee4ffdb94c7013b65a6" dependencies = [ "proc-macro-crate", "proc-macro2", "quote", - "syn 1.0.109", + "syn 2.0.28", ] [[package]] @@ -3692,24 +4439,36 @@ checksum = "21158b2c33aa6d4561f1c0a6ea283ca92bc54802a93b263e910746d679a7eb53" dependencies = [ "crc32fast", "hashbrown 0.12.3", - "indexmap", + "indexmap 1.9.3", + "memchr", +] + +[[package]] +name = "object" +version = "0.30.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "03b4680b86d9cfafba8fc491dc9b6df26b68cf40e9e6cd73909194759a63c385" +dependencies = [ + "crc32fast", + "hashbrown 0.13.2", + "indexmap 1.9.3", "memchr", ] [[package]] name = "object" -version = "0.30.3" +version = "0.31.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea86265d3d3dcb6a27fc51bd29a4bf387fae9d2986b823079d4986af253eb439" +checksum = "8bda667d9f2b5051b8833f59f3bf748b28ef54f850f4fcb389a252aa383866d1" dependencies = [ "memchr", ] [[package]] name = "once_cell" -version = "1.17.1" +version = "1.18.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b7e5500299e16ebb147ae15a00a942af264cf3688f47923b8fc2cd5858f23ad3" +checksum = "dd8b5dd2ae5ed71462c540258bedcb51965123ad7e7ccf4b9a8cafaa4a63576d" [[package]] name = "opaque-debug" @@ -3729,7 +4488,7 @@ version = "0.1.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "786393f80485445794f6043fd3138854dd109cc6c4bd1a6383db304c9ce9b9ce" dependencies = [ - "arrayvec 0.7.2", + "arrayvec 0.7.4", "auto_impl", "bytes", "ethereum-types", @@ -3754,50 +4513,77 @@ version = "0.1.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ff011a302c396a5197692431fc1948019154afc178baf7d8e37367442a4601cf" +[[package]] +name = "option-ext" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "04744f49eae99ab78e0d5c0b603ab218f515ea8cfe5a456d7629ad883a3b6e7d" + [[package]] name = "ordered-float" -version = "3.6.0" +version = "3.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "13a384337e997e6860ffbaa83708b2ef329fd8c54cb67a5f64d421e0f943254f" +checksum = "2fc2dbde8f8a79f2102cc474ceb0ad68e3b80b85289ea62389b60e66777e4213" dependencies = [ "num-traits", ] -[[package]] -name = "os_str_bytes" -version = "6.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ceedf44fb00f2d1984b0bc98102627ce622e083e49a5bacdb3e514fa4238e267" - [[package]] name = "overload" version = "0.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b15813163c1d831bf4a13c3610c05c0d03b39feb07f7e09fa234dac9b15aaf39" +[[package]] +name = "packed_simd_2" +version = "0.3.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a1914cd452d8fccd6f9db48147b29fd4ae05bea9dc5d9ad578509f72415de282" +dependencies = [ + "cfg-if", + "libm 0.1.4", +] + +[[package]] +name = "pallet-authorship" +version = "4.0.0-dev" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" +dependencies = [ + "frame-support", + "frame-system", + "impl-trait-for-tuples", + "parity-scale-codec", + "scale-info", + "sp-runtime 7.0.0", + "sp-std 5.0.0", +] + [[package]] name = "pallet-beefy" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.38#18bb7c7c841b101c19a8d1881b893ae8e37de460" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" dependencies = [ "frame-support", "frame-system", + "pallet-authorship", "pallet-session", "parity-scale-codec", "scale-info", "serde", - "sp-beefy", + "sp-consensus-beefy", "sp-runtime 7.0.0", + "sp-session", + "sp-staking", "sp-std 5.0.0", ] [[package]] name = "pallet-beefy-mmr" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.38#18bb7c7c841b101c19a8d1881b893ae8e37de460" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" dependencies = [ "array-bytes", - "beefy-merkle-tree", + "binary-merkle-tree", "frame-support", "frame-system", "log", @@ -3807,7 +4593,57 @@ dependencies = [ "parity-scale-codec", "scale-info", "serde", - "sp-beefy", + "sp-api", + "sp-consensus-beefy", + "sp-core 7.0.0", + "sp-io 7.0.0", + "sp-runtime 7.0.0", + "sp-std 5.0.0", +] + +[[package]] +name = "pallet-evm" +version = "6.0.0-dev" +source = "git+https://github.com/paritytech/frontier?branch=polkadot-v0.9.42#2499d18c936edbcb7fcb711827db7abb9b4f4da4" +dependencies = [ + "environmental", + "evm", + "fp-account", + "fp-evm", + "frame-benchmarking", + "frame-support", + "frame-system", + "hex", + "hex-literal", + "impl-trait-for-tuples", + "log", + "parity-scale-codec", + "rlp", + "scale-info", + "sp-core 7.0.0", + "sp-io 7.0.0", + "sp-runtime 7.0.0", + "sp-std 5.0.0", +] + +[[package]] +name = "pallet-ismp" +version = "0.1.0" +source = "git+https://github.com/polytope-labs/ismp-substrate?branch=main#356a516c7b451490d4758bb05182233a26a4de88" +dependencies = [ + "ckb-merkle-mountain-range 0.5.2 (registry+https://github.com/rust-lang/crates.io-index)", + "derive_more", + "enum-as-inner", + "frame-benchmarking", + "frame-support", + "frame-system", + "ismp", + "ismp-primitives", + "log", + "parity-scale-codec", + "scale-info", + "serde", + "sp-api", "sp-core 7.0.0", "sp-io 7.0.0", "sp-runtime 7.0.0", @@ -3817,7 +4653,7 @@ dependencies = [ [[package]] name = "pallet-mmr" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.38#18bb7c7c841b101c19a8d1881b893ae8e37de460" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" dependencies = [ "frame-benchmarking", "frame-support", @@ -3834,7 +4670,7 @@ dependencies = [ [[package]] name = "pallet-session" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.38#18bb7c7c841b101c19a8d1881b893ae8e37de460" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" dependencies = [ "frame-support", "frame-system", @@ -3855,7 +4691,7 @@ dependencies = [ [[package]] name = "pallet-timestamp" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.38#18bb7c7c841b101c19a8d1881b893ae8e37de460" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" dependencies = [ "frame-benchmarking", "frame-support", @@ -3872,53 +4708,29 @@ dependencies = [ [[package]] name = "parity-scale-codec" -version = "3.4.0" +version = "3.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "637935964ff85a605d114591d4d2c13c5d1ba2806dae97cea6bf180238a749ac" +checksum = "dd8e946cc0cc711189c0b0249fb8b599cbeeab9784d83c415719368bb8d4ac64" dependencies = [ - "arrayvec 0.7.2", + "arrayvec 0.7.4", "bitvec 1.0.1", "byte-slice-cast", - "bytes", - "impl-trait-for-tuples", - "parity-scale-codec-derive", - "serde", -] - -[[package]] -name = "parity-scale-codec-derive" -version = "3.1.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "86b26a931f824dd4eca30b3e43bb4f31cd5f0d3a403c5f5ff27106b805bfde7b" -dependencies = [ - "proc-macro-crate", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "parity-util-mem" -version = "0.12.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0d32c34f4f5ca7f9196001c0aba5a1f9a5a12382c8944b8b0f90233282d1e8f8" -dependencies = [ - "cfg-if", - "hashbrown 0.12.3", + "bytes", "impl-trait-for-tuples", - "parity-util-mem-derive", - "winapi", + "parity-scale-codec-derive", + "serde", ] [[package]] -name = "parity-util-mem-derive" -version = "0.1.0" +name = "parity-scale-codec-derive" +version = "3.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f557c32c6d268a07c921471619c0295f5efad3a0e76d4f97a05c091a51d110b2" +checksum = "2a296c3079b5fefbc499e1de58dc26c09b1b9a5952d26694ee89f04a43ebbb3e" dependencies = [ + "proc-macro-crate", "proc-macro2", + "quote", "syn 1.0.109", - "synstructure", ] [[package]] @@ -3927,6 +4739,12 @@ version = "0.45.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e1ad0aff30c1da14b1254fcb2af73e1fa9a28670e584a626f53a369d0e157304" +[[package]] +name = "parking" +version = "2.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "14f2252c834a40ed9bb5422029649578e63aa341ac401f74e719dd1afda8394e" + [[package]] name = "parking_lot" version = "0.12.1" @@ -3939,15 +4757,15 @@ dependencies = [ [[package]] name = "parking_lot_core" -version = "0.9.7" +version = "0.9.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9069cbb9f99e3a5083476ccb29ceb1de18b9118cafa53e90c9551235de2b9521" +checksum = "93f00c865fe7cabf650081affecd3871070f26767e7b2070a3ffae14c654b447" dependencies = [ "cfg-if", "libc", - "redox_syscall", - "smallvec", - "windows-sys 0.45.0", + "redox_syscall 0.3.5", + "smallvec 1.11.0", + "windows-targets 0.48.1", ] [[package]] @@ -3963,9 +4781,9 @@ dependencies = [ [[package]] name = "paste" -version = "1.0.12" +version = "1.0.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9f746c4065a8fa3fe23974dd82f15431cc8d40779821001404d10d2e79ca7d79" +checksum = "de3145af08024dea9fa9914f381a17b8fc6034dfb00f3a84013f7ff43f29ed4c" [[package]] name = "path-slash" @@ -3973,21 +4791,6 @@ version = "0.2.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1e91099d4268b0e11973f036e885d652fb0b21fedcf69738c627f94db6a44f42" -[[package]] -name = "patricia-merkle-trie" -version = "0.1.0" -source = "git+https://github.com/polytope-labs/patricia-merkle-trie?branch=main#bc624c1595aff64d577217873ba58ec50040a107" -dependencies = [ - "hash-db", - "hash256-std-hasher", - "memory-db 0.30.0", - "parity-scale-codec", - "primitive-types", - "rlp", - "tiny-keccak", - "trie-db", -] - [[package]] name = "pbkdf2" version = "0.8.0" @@ -4003,50 +4806,60 @@ version = "0.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "83a0692ec44e4cf1ef28ca317f14f8f07da2d95ec3fa01f86e4467b725e60917" dependencies = [ - "digest 0.10.6", + "digest 0.10.7", "hmac 0.12.1", "password-hash", - "sha2 0.10.6", + "sha2 0.10.7", ] [[package]] name = "pbkdf2" -version = "0.12.1" +version = "0.12.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f0ca0b5a68607598bf3bad68f32227a8164f6254833f84eafaac409cd6746c31" +checksum = "f8ed6a7761f76e3b9f92dfb0a60a6a6477c61024b775147ff0973a02653abaf2" dependencies = [ - "digest 0.10.6", + "digest 0.10.7", "hmac 0.12.1", ] [[package]] name = "pear" -version = "0.2.3" +version = "0.2.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "15e44241c5e4c868e3eaa78b7c1848cadd6344ed4f54d029832d32b415a58702" +checksum = "61a386cd715229d399604b50d1361683fe687066f42d56f54be995bc6868f71c" dependencies = [ "inlinable_string", "pear_codegen", - "yansi", + "yansi 1.0.0-rc", ] [[package]] name = "pear_codegen" -version = "0.2.3" +version = "0.2.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "82a5ca643c2303ecb740d506539deba189e16f2754040a42901cd8105d0282d0" +checksum = "da9f0f13dac8069c139e8300a6510e3f4143ecf5259c60b116a9b271b4ca0d54" dependencies = [ "proc-macro2", "proc-macro2-diagnostics", "quote", - "syn 1.0.109", + "syn 2.0.28", ] [[package]] name = "percent-encoding" -version = "2.2.0" +version = "2.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9b2a4787296e9989611394c33f193f676704af1686e70b8f8033ab5ba9a35a94" + +[[package]] +name = "pest" +version = "2.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "478c572c3d73181ff3c2539045f6eb99e5491218eae919370993b890cdbdd98e" +checksum = "1acb4a4365a13f749a93f1a094a7805e5cfa0955373a9de860d962eaa3a5fe5a" +dependencies = [ + "thiserror", + "ucd-trie", +] [[package]] name = "petgraph" @@ -4055,7 +4868,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4dd7d28ee937e54fe3080c91faa1c3a46c06de6252988a7f4592ba2310ef22a4" dependencies = [ "fixedbitset", - "indexmap", + "indexmap 1.9.3", ] [[package]] @@ -4065,40 +4878,40 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e9567389417feee6ce15dd6527a8a1ecac205ef62c2932bcf3d9f6fc5b78b414" dependencies = [ "futures", - "rustc_version", + "rustc_version 0.4.0", ] [[package]] name = "phf" -version = "0.11.1" +version = "0.11.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "928c6535de93548188ef63bb7c4036bd415cd8f36ad25af44b9789b2ee72a48c" +checksum = "ade2d8b8f33c7333b51bcf0428d37e217e9f32192ae4772156f65063b8ce03dc" dependencies = [ "phf_macros", - "phf_shared 0.11.1", + "phf_shared 0.11.2", ] [[package]] name = "phf_generator" -version = "0.11.1" +version = "0.11.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b1181c94580fa345f50f19d738aaa39c0ed30a600d95cb2d3e23f94266f14fbf" +checksum = "48e4cc64c2ad9ebe670cb8fd69dd50ae301650392e81c05f9bfcb2d5bdbc24b0" dependencies = [ - "phf_shared 0.11.1", + "phf_shared 0.11.2", "rand 0.8.5", ] [[package]] name = "phf_macros" -version = "0.11.1" +version = "0.11.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "92aacdc5f16768709a569e913f7451034034178b05bdc8acda226659a3dccc66" +checksum = "3444646e286606587e49f3bcf1679b8cef1dc2c5ecc29ddacaffc305180d464b" dependencies = [ "phf_generator", - "phf_shared 0.11.1", + "phf_shared 0.11.2", "proc-macro2", "quote", - "syn 1.0.109", + "syn 2.0.28", ] [[package]] @@ -4112,44 +4925,38 @@ dependencies = [ [[package]] name = "phf_shared" -version = "0.11.1" +version = "0.11.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e1fb5f6f826b772a8d4c0394209441e7d37cbbb967ae9c7e0e8134365c9ee676" +checksum = "90fcb95eef784c2ac79119d1dd819e162b5da872ce6f3c3abe1e8ca1c082f72b" dependencies = [ "siphasher", ] -[[package]] -name = "pico-args" -version = "0.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "db8bcd96cb740d03149cbad5518db9fd87126a10ab519c011893b1754134c468" - [[package]] name = "pin-project" -version = "1.0.12" +version = "1.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ad29a609b6bcd67fee905812e544992d216af9d755757c05ed2d0e15a74c6ecc" +checksum = "030ad2bc4db10a8944cb0d837f158bdfec4d4a4873ab701a95046770d11f8842" dependencies = [ "pin-project-internal", ] [[package]] name = "pin-project-internal" -version = "1.0.12" +version = "1.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "069bdb1e05adc7a8990dce9cc75370895fbe4e3d58b9b73bf1aee56359344a55" +checksum = "ec2e072ecce94ec471b13398d5402c188e76ac03cf74dd1a975161b23a3f6d9c" dependencies = [ "proc-macro2", "quote", - "syn 1.0.109", + "syn 2.0.28", ] [[package]] name = "pin-project-lite" -version = "0.2.9" +version = "0.2.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e0a7ae3ac2f1173085d398531c705756c94a4c56843785df85a60c1a0afac116" +checksum = "4c40d25201921e5ff0c862a505c6557ea88568a4e3ace775ab55e93f2f4f9d57" [[package]] name = "pin-utils" @@ -4159,29 +4966,64 @@ checksum = "8b870d8c151b6f2fb93e84a13146138f05d02ed11c7e7c54f8826aaaf7c9f184" [[package]] name = "pkcs8" -version = "0.9.0" +version = "0.10.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9eca2c590a5f85da82668fa685c09ce2888b9430e83299debf1f34b65fd4a4ba" +checksum = "f950b2377845cebe5cf8b5165cb3cc1a5e0fa5cfa3e1f7f55707d8fd82e0a7b7" dependencies = [ - "der 0.6.1", - "spki 0.6.0", + "der", + "spki", ] [[package]] -name = "pkcs8" -version = "0.10.1" +name = "pkg-config" +version = "0.3.27" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "26072860ba924cbfa98ea39c8c19b4dd6a4a25423dbdf219c1eca91aa0cf6964" + +[[package]] +name = "platforms" +version = "3.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e3d7ddaed09e0eb771a79ab0fd64609ba0afb0a8366421957936ad14cbd13630" + +[[package]] +name = "polling" +version = "2.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3d2820d87d2b008616e5c27212dd9e0e694fb4c6b522de06094106813328cb49" +checksum = "4b2d323e8ca7996b3e23126511a523f7e62924d93ecd5ae73b333815b0eb3dce" dependencies = [ - "der 0.7.1", - "spki 0.7.0", + "autocfg", + "bitflags 1.3.2", + "cfg-if", + "concurrent-queue", + "libc", + "log", + "pin-project-lite", + "windows-sys 0.48.0", ] [[package]] -name = "pkg-config" -version = "0.3.26" +name = "poly1305" +version = "0.7.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "048aeb476be11a4b6ca432ca569e375810de9294ae78f4774e78ea98a9246ede" +dependencies = [ + "cpufeatures", + "opaque-debug 0.3.0", + "universal-hash", +] + +[[package]] +name = "polyval" +version = "0.5.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6ac9a59f73473f1b8d852421e59e64809f025994837ef743615c6d0c5b305160" +checksum = "8419d2b623c7c0896ff2d5d96e2cb4ede590fed28fcc34934f4c33c036e620a1" +dependencies = [ + "cfg-if", + "cpufeatures", + "opaque-debug 0.3.0", + "universal-hash", +] [[package]] name = "ppv-lite86" @@ -4197,12 +5039,12 @@ checksum = "925383efa346730478fb4838dbe9137d2a47675ad789c546d150a6e1dd4ab31c" [[package]] name = "prettyplease" -version = "0.1.25" +version = "0.2.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c8646e95016a7a6c4adea95bafa8a16baab64b583356217f2c85db4a39d9a86" +checksum = "6c64d9ba0963cdcea2e1b2230fbae2bab30eb25a174be395c41e764bfb65dd62" dependencies = [ "proc-macro2", - "syn 1.0.109", + "syn 2.0.28", ] [[package]] @@ -4226,7 +5068,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7f4c021e1093a56626774e81216a4ce732a735e5bad4868a03f3ed65ca0c3919" dependencies = [ "once_cell", - "toml_edit 0.19.7", + "toml_edit", ] [[package]] @@ -4253,44 +5095,54 @@ dependencies = [ "version_check", ] +[[package]] +name = "proc-macro-warning" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0e99670bafb56b9a106419397343bdbc8b8742c3cc449fec6345f86173f47cd4" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.28", +] + [[package]] name = "proc-macro2" -version = "1.0.53" +version = "1.0.66" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba466839c78239c09faf015484e5cc04860f88242cff4d03eb038f04b4699b73" +checksum = "18fb31db3f9bddb2ea821cde30a9f70117e3f119938b5ee630b7403aa6e2ead9" dependencies = [ "unicode-ident", ] [[package]] name = "proc-macro2-diagnostics" -version = "0.9.1" +version = "0.10.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4bf29726d67464d49fa6224a1d07936a8c08bb3fba727c7493f6cf1616fdaada" +checksum = "af066a9c399a26e020ada66a034357a868728e72cd426f3adcd35f80d88d88c8" dependencies = [ "proc-macro2", "quote", - "syn 1.0.109", + "syn 2.0.28", "version_check", - "yansi", + "yansi 1.0.0-rc", ] [[package]] name = "proptest" -version = "1.1.0" +version = "1.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "29f1b898011ce9595050a68e60f90bad083ff2987a695a42357134c8381fba70" +checksum = "4e35c06b98bf36aba164cc17cb25f7e232f5c4aeea73baa14b8a9f0d92dbfa65" dependencies = [ "bit-set", "bitflags 1.3.2", "byteorder", "lazy_static", "num-traits", - "quick-error 2.0.1", "rand 0.8.5", "rand_chacha 0.3.1", "rand_xorshift", - "regex-syntax", + "regex-syntax 0.6.29", "rusty-fork", "tempfile", "unarray", @@ -4311,17 +5163,11 @@ version = "1.2.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a1d01941d82fa2ab50be1e79e6714289dd7cde78eba4c074bc5a4374f650dfe0" -[[package]] -name = "quick-error" -version = "2.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a993555f31e5a609f617c12db6250dedcac1b0a85076912c436e6fc9b2c8e6a3" - [[package]] name = "quote" -version = "1.0.26" +version = "1.0.32" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4424af4bf778aae2051a77b60283332f386554255d722233d09fbfc7e30da2fc" +checksum = "50f3b39ccfb720540debaa0164757101c08ecb8d326b15358ce76a62c7e85965" dependencies = [ "proc-macro2", ] @@ -4397,17 +5243,7 @@ version = "0.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c" dependencies = [ - "getrandom 0.2.8", -] - -[[package]] -name = "rand_distr" -version = "0.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "32cb0b9bc82b0a0876c2dd994a7e7a2683d3e7390ca40e6886785ef0c7e3ee31" -dependencies = [ - "num-traits", - "rand 0.8.5", + "getrandom 0.2.10", ] [[package]] @@ -4465,46 +5301,56 @@ dependencies = [ "bitflags 1.3.2", ] +[[package]] +name = "redox_syscall" +version = "0.3.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "567664f262709473930a4bf9e51bf2ebf3348f2e748ccc50dea20646858f8f29" +dependencies = [ + "bitflags 1.3.2", +] + [[package]] name = "redox_users" version = "0.4.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b033d837a7cf162d7993aded9304e30a83213c648b6e389db233191f891e5c2b" dependencies = [ - "getrandom 0.2.8", - "redox_syscall", + "getrandom 0.2.10", + "redox_syscall 0.2.16", "thiserror", ] [[package]] name = "ref-cast" -version = "1.0.16" +version = "1.0.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f43faa91b1c8b36841ee70e97188a869d37ae21759da6846d4be66de5bf7b12c" +checksum = "61ef7e18e8841942ddb1cf845054f8008410030a3997875d9e49b7a363063df1" dependencies = [ "ref-cast-impl", ] [[package]] name = "ref-cast-impl" -version = "1.0.16" +version = "1.0.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8d2275aab483050ab2a7364c1a46604865ee7d6906684e08db0f090acf74f9e7" +checksum = "2dfaf0c85b766276c797f3791f5bc6d5bd116b41d53049af2789666b0c0bc9fa" dependencies = [ "proc-macro2", "quote", - "syn 2.0.5", + "syn 2.0.28", ] [[package]] name = "regex" -version = "1.7.2" +version = "1.9.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cce168fea28d3e05f158bda4576cf0c844d5045bc2cc3620fa0292ed5bb5814c" +checksum = "b2eae68fc220f7cf2532e4494aded17545fce192d59cd996e0fe7887f4ceb575" dependencies = [ "aho-corasick", "memchr", - "regex-syntax", + "regex-automata 0.3.4", + "regex-syntax 0.7.4", ] [[package]] @@ -4513,7 +5359,18 @@ version = "0.1.10" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6c230d73fb8d8c1b9c0b3135c5142a8acee3a0558fb8db5cf1cb65f8d7862132" dependencies = [ - "regex-syntax", + "regex-syntax 0.6.29", +] + +[[package]] +name = "regex-automata" +version = "0.3.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b7b6d6190b7594385f61bd3911cd1be99dfddcfc365a4160cc2ab5bff4aed294" +dependencies = [ + "aho-corasick", + "memchr", + "regex-syntax 0.7.4", ] [[package]] @@ -4522,13 +5379,19 @@ version = "0.6.29" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f162c6dd7b008981e4d40210aca20b4bd0f9b60ca9271061b07f78537722f2e1" +[[package]] +name = "regex-syntax" +version = "0.7.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e5ea92a5b6195c6ef2a0295ea818b312502c6fc94dde986c5553242e18fd4ce2" + [[package]] name = "reqwest" -version = "0.11.15" +version = "0.11.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0ba30cc2c0cd02af1222ed216ba659cdb2f879dfe3181852fe7c50b1d0005949" +checksum = "cde824a14b7c14f85caff81225f411faacc04a2013f41670f41443742b1c1c55" dependencies = [ - "base64 0.21.0", + "base64 0.21.2", "bytes", "encoding_rs", "futures-core", @@ -4537,7 +5400,7 @@ dependencies = [ "http", "http-body", "hyper", - "hyper-rustls", + "hyper-rustls 0.24.1", "ipnet", "js-sys", "log", @@ -4545,68 +5408,84 @@ dependencies = [ "once_cell", "percent-encoding", "pin-project-lite", - "rustls", + "rustls 0.21.5", "rustls-pemfile", "serde", "serde_json", "serde_urlencoded", "tokio", - "tokio-rustls", + "tokio-rustls 0.24.1", "tower-service", "url", "wasm-bindgen", "wasm-bindgen-futures", "web-sys", - "webpki-roots", + "webpki-roots 0.22.6", "winreg", ] [[package]] name = "revm" -version = "2.3.1" +version = "3.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "73d84c8f9836efb0f5f5f8de4700a953c4e1f3119e5cfcb0aad8e5be73daf991" +checksum = "f293f351c4c203d321744e54ed7eed3d2b6eef4c140228910dde3ac9a5ea8031" dependencies = [ - "arrayref", "auto_impl", - "bytes", - "hashbrown 0.13.2", - "hex", - "num_enum", - "primitive-types", - "revm_precompiles", - "rlp", + "revm-interpreter", + "revm-precompile", "serde", - "sha3", + "serde_json", ] [[package]] -name = "revm_precompiles" +name = "revm-interpreter" version = "1.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0353d456ef3e989dc9190f42c6020f09bc2025930c37895826029304413204b5" +checksum = "a53980a26f9b5a66d13511c35074d4b53631e157850a1d7cf1af4efc2c2b72c9" dependencies = [ - "bytes", - "hashbrown 0.13.2", - "k256 0.11.6", + "derive_more", + "enumn", + "revm-primitives", + "serde", + "sha3", +] + +[[package]] +name = "revm-precompile" +version = "2.0.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "41320af3bd6a65153d38eb1d3638ba89104cc9513c7feedb2d8510e8307dab29" +dependencies = [ + "k256", "num", "once_cell", - "primitive-types", + "revm-primitives", "ripemd", - "sha2 0.10.6", + "sha2 0.10.7", "sha3", "substrate-bn", ] [[package]] -name = "rfc6979" -version = "0.3.1" +name = "revm-primitives" +version = "1.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7743f17af12fa0b03b803ba12cd6a8d9483a587e89c69445e3909655c0b9fabb" +checksum = "304d998f466ffef72d76c7f20b05bf08a96801736a6fb1fdef47d49a292618df" dependencies = [ - "crypto-bigint 0.4.9", - "hmac 0.12.1", - "zeroize", + "auto_impl", + "bitvec 1.0.1", + "bytes", + "derive_more", + "enumn", + "fixed-hash", + "hashbrown 0.13.2", + "hex", + "hex-literal", + "primitive-types", + "rlp", + "ruint", + "serde", + "sha3", ] [[package]] @@ -4628,7 +5507,7 @@ dependencies = [ "cc", "libc", "once_cell", - "spin", + "spin 0.5.2", "untrusted", "web-sys", "winapi", @@ -4640,7 +5519,7 @@ version = "0.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "bd124222d17ad93a644ed9d011a40f4fb64aa54275c08cc216524a9ea82fb09f" dependencies = [ - "digest 0.10.6", + "digest 0.10.7", ] [[package]] @@ -4671,14 +5550,43 @@ version = "1.2.0" source = "git+https://github.com/polytope-labs/rs-merkle?branch=seun/2d-merkle-proofs#02750ca0b3a93dc9b53c826b58692b3c1cf7e2a7" dependencies = [ "micromath", - "sha2 0.10.6", + "sha2 0.10.7", +] + +[[package]] +name = "ruint" +version = "1.10.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "95294d6e3a6192f3aabf91c38f56505a625aa495533442744185a36d75a790c4" +dependencies = [ + "alloy-rlp", + "ark-ff 0.3.0", + "ark-ff 0.4.2", + "bytes", + "fastrlp", + "num-bigint", + "parity-scale-codec", + "primitive-types", + "proptest", + "rand 0.8.5", + "rlp", + "ruint-macro", + "serde", + "valuable", + "zeroize", ] +[[package]] +name = "ruint-macro" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e666a5496a0b2186dbcd0ff6106e29e093c15591bde62c20d3842007c6978a09" + [[package]] name = "rustc-demangle" -version = "0.1.21" +version = "0.1.23" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7ef03e0a2b150c7a90d01faf6254c9c48a41e95fb2a8c2ac1c6f0d2b9aefc342" +checksum = "d626bb9dae77e28219937af045c257c28bfd3f69333c512553507f5f9798cb76" [[package]] name = "rustc-hash" @@ -4692,23 +5600,32 @@ version = "2.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3e75f6a532d0fd9f7f13144f392b6ad56a32696bfcd9c78f797f16bbb6f072d6" +[[package]] +name = "rustc_version" +version = "0.3.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f0dfe2087c51c460008730de8b57e6a320782fbfb312e1f4d520e6c6fae155ee" +dependencies = [ + "semver 0.11.0", +] + [[package]] name = "rustc_version" version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "bfa0f585226d2e68097d4f95d113b15b83a82e819ab25717ec0590d9584ef366" dependencies = [ - "semver", + "semver 1.0.18", ] [[package]] name = "rustix" -version = "0.35.13" +version = "0.35.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "727a1a6d65f786ec22df8a81ca3121107f235970dc1705ed681d3e6e8b9cd5f9" +checksum = "6380889b07a03b5ecf1d44dc9ede6fd2145d84b502a2a9ca0b03c48e0cc3220f" dependencies = [ "bitflags 1.3.2", - "errno", + "errno 0.2.8", "io-lifetimes 0.7.5", "libc", "linux-raw-sys 0.0.46", @@ -4717,18 +5634,45 @@ dependencies = [ [[package]] name = "rustix" -version = "0.36.11" +version = "0.36.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "db4165c9963ab29e422d6c26fbc1d37f15bace6b2810221f9d925023480fcf0e" +checksum = "c37f1bd5ef1b5422177b7646cba67430579cfe2ace80f284fee876bca52ad941" dependencies = [ "bitflags 1.3.2", - "errno", - "io-lifetimes 1.0.9", + "errno 0.3.2", + "io-lifetimes 1.0.11", "libc", "linux-raw-sys 0.1.4", "windows-sys 0.45.0", ] +[[package]] +name = "rustix" +version = "0.37.23" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4d69718bf81c6127a49dc64e44a742e8bb9213c0ff8869a22c308f84c1d4ab06" +dependencies = [ + "bitflags 1.3.2", + "errno 0.3.2", + "io-lifetimes 1.0.11", + "libc", + "linux-raw-sys 0.3.8", + "windows-sys 0.48.0", +] + +[[package]] +name = "rustix" +version = "0.38.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0a962918ea88d644592894bc6dc55acc6c0956488adcebbfb6e273506b7fd6e5" +dependencies = [ + "bitflags 2.3.3", + "errno 0.3.2", + "libc", + "linux-raw-sys 0.4.5", + "windows-sys 0.48.0", +] + [[package]] name = "rustls" version = "0.20.8" @@ -4741,11 +5685,23 @@ dependencies = [ "webpki", ] +[[package]] +name = "rustls" +version = "0.21.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "79ea77c539259495ce8ca47f53e66ae0330a8819f67e23ac96ca02f50e7b7d36" +dependencies = [ + "log", + "ring", + "rustls-webpki 0.101.2", + "sct", +] + [[package]] name = "rustls-native-certs" -version = "0.6.2" +version = "0.6.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0167bac7a9f490495f3c33013e7722b53cb087ecbe082fb0c6387c96f634ea50" +checksum = "a9aace74cb666635c918e9c12bc0d348266037aa8eb599b5cba565709a8dff00" dependencies = [ "openssl-probe", "rustls-pemfile", @@ -4755,18 +5711,38 @@ dependencies = [ [[package]] name = "rustls-pemfile" -version = "1.0.2" +version = "1.0.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2d3987094b1d07b653b7dfdc3f70ce9a1da9c51ac18c1b06b662e4f9a0e9f4b2" +dependencies = [ + "base64 0.21.2", +] + +[[package]] +name = "rustls-webpki" +version = "0.100.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d6207cd5ed3d8dca7816f8f3725513a34609c0c765bf652b8c3cb4cfd87db46b" +dependencies = [ + "ring", + "untrusted", +] + +[[package]] +name = "rustls-webpki" +version = "0.101.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d194b56d58803a43635bdc398cd17e383d6f71f9182b9a192c127ca42494a59b" +checksum = "513722fd73ad80a71f72b61009ea1b584bcfa1483ca93949c8f290298837fa59" dependencies = [ - "base64 0.21.0", + "ring", + "untrusted", ] [[package]] name = "rustversion" -version = "1.0.12" +version = "1.0.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4f3208ce4d8448b3f3e7d168a73f5e0c43a61e32930de3bceeccedb388b6bf06" +checksum = "7ffc183a10b4478d04cbbbfc96d0873219d962dd5accaff2ffbd4ceb7df837f4" [[package]] name = "rusty-fork" @@ -4775,16 +5751,36 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "cb3dcc6e454c328bb824492db107ab7c0ae8fcffe4ad210136ef014458c1bc4f" dependencies = [ "fnv", - "quick-error 1.2.3", + "quick-error", "tempfile", "wait-timeout", ] +[[package]] +name = "ruzstd" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ac3ffab8f9715a0d455df4bbb9d21e91135aab3cd3ca187af0cd0c3c3f868fdc" +dependencies = [ + "byteorder", + "thiserror-core", + "twox-hash", +] + [[package]] name = "ryu" -version = "1.0.13" +version = "1.0.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1ad4cc8da4ef723ed60bced201181d83791ad433213d8c24efffda1eec85d741" + +[[package]] +name = "safe_arch" +version = "0.7.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f91339c0467de62360649f8d3e185ca8de4224ff281f66000de5eb2a77a79041" +checksum = "f398075ce1e6a179b46f51bd88d0598b92b00d3551f1a2d4ac49e771b56ac354" +dependencies = [ + "bytemuck", +] [[package]] name = "salsa20" @@ -4817,21 +5813,65 @@ dependencies = [ [[package]] name = "scale-decode" -version = "0.4.0" +version = "0.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f0459d00b0dbd2e765009924a78ef36b2ff7ba116292d732f00eb0ed8e465d15" +dependencies = [ + "parity-scale-codec", + "primitive-types", + "scale-bits", + "scale-decode-derive", + "scale-info", + "smallvec 1.11.0", + "thiserror", +] + +[[package]] +name = "scale-decode-derive" +version = "0.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4391f0dfbb6690f035f6d2a15d6a12f88cc5395c36bcc056db07ffa2a90870ec" +dependencies = [ + "darling 0.14.4", + "proc-macro-crate", + "proc-macro2", + "quote", + "syn 1.0.109", +] + +[[package]] +name = "scale-encode" +version = "0.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d823d4be477fc33321f93d08fb6c2698273d044f01362dc27573a750deb7c233" +checksum = "b0401b7cdae8b8aa33725f3611a051358d5b32887ecaa0fda5953a775b2d4d76" dependencies = [ "parity-scale-codec", + "primitive-types", "scale-bits", + "scale-encode-derive", "scale-info", + "smallvec 1.11.0", "thiserror", ] +[[package]] +name = "scale-encode-derive" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "316e0fb10ec0fee266822bd641bab5e332a4ab80ef8c5b5ff35e5401a394f5a6" +dependencies = [ + "darling 0.14.4", + "proc-macro-crate", + "proc-macro2", + "quote", + "syn 1.0.109", +] + [[package]] name = "scale-info" -version = "2.3.1" +version = "2.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "001cf62ece89779fd16105b5f515ad0e5cedcd5440d3dd806bb067978e7c3608" +checksum = "35c0a159d0c45c12b20c5a844feb1fe4bea86e28f17b92a5f0c42193634d3782" dependencies = [ "bitvec 1.0.1", "cfg-if", @@ -4843,9 +5883,9 @@ dependencies = [ [[package]] name = "scale-info-derive" -version = "2.3.1" +version = "2.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "303959cf613a6f6efd19ed4b4ad5bf79966a13352716299ad532cfb115f4205c" +checksum = "912e55f6d20e0e80d63733872b40e1227c0bce1e1ab81ba67d696339bfd7fd29" dependencies = [ "proc-macro-crate", "proc-macro2", @@ -4855,15 +5895,18 @@ dependencies = [ [[package]] name = "scale-value" -version = "0.6.0" +version = "0.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "16a5e7810815bd295da73e4216d1dfbced3c7c7c7054d70fa5f6e4c58123fff4" +checksum = "f2096d36e94ce9bf87d8addb752423b6b19730dc88edd7cc452bb2b90573f7a7" dependencies = [ + "base58", + "blake2", "either", - "frame-metadata", + "frame-metadata 15.1.0", "parity-scale-codec", "scale-bits", "scale-decode", + "scale-encode", "scale-info", "serde", "thiserror", @@ -4872,11 +5915,11 @@ dependencies = [ [[package]] name = "schannel" -version = "0.1.21" +version = "0.1.22" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "713cfb06c7059f3588fb8044c0fad1d09e3c01d225e25b9220dbfdcf16dbb1b3" +checksum = "0c3733bf4cf7ea0880754e19cb5a462007c4a8c1914bff372ccc95b464f1df88" dependencies = [ - "windows-sys 0.42.0", + "windows-sys 0.48.0", ] [[package]] @@ -4900,7 +5943,7 @@ dependencies = [ "arrayvec 0.5.2", "curve25519-dalek 2.1.3", "getrandom 0.1.16", - "merlin", + "merlin 2.0.1", "rand 0.7.3", "rand_core 0.5.1", "sha2 0.8.2", @@ -4909,16 +5952,26 @@ dependencies = [ ] [[package]] -name = "scopeguard" -version = "1.1.0" +name = "schnorrkel" +version = "0.10.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d29ab0c6d3fc0ee92fe66e2d99f700eab17a8d57d1c1d3b748380fb20baa78cd" +checksum = "844b7645371e6ecdf61ff246ba1958c29e802881a749ae3fb1993675d210d28d" +dependencies = [ + "arrayref", + "arrayvec 0.7.4", + "curve25519-dalek-ng", + "merlin 3.0.0", + "rand_core 0.6.4", + "sha2 0.9.9", + "subtle-ng", + "zeroize", +] [[package]] -name = "scratch" -version = "1.0.5" +name = "scopeguard" +version = "1.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1792db035ce95be60c3f8853017b3999209281c24e2ba5bc8e59bf97a0c590c1" +checksum = "94143f37725109f92c262ed2cf5e59bce7498c01bcc1502d7b9afe439a4e9f49" [[package]] name = "scrypt" @@ -4929,7 +5982,7 @@ dependencies = [ "hmac 0.12.1", "pbkdf2 0.11.0", "salsa20", - "sha2 0.10.6", + "sha2 0.10.7", ] [[package]] @@ -4944,28 +5997,14 @@ dependencies = [ [[package]] name = "sec1" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3be24c1842290c45df0a7bf069e0c268a747ad05a192f2fd7dcfdbc1cba40928" -dependencies = [ - "base16ct 0.1.1", - "der 0.6.1", - "generic-array 0.14.6", - "pkcs8 0.9.0", - "subtle", - "zeroize", -] - -[[package]] -name = "sec1" -version = "0.7.1" +version = "0.7.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "48518a2b5775ba8ca5b46596aae011caa431e6ce7e4a67ead66d92f08884220e" +checksum = "d3e97a565f76233a6003f9f5c54be1d9c5bdfa3eccfb189469f11ec4901c47dc" dependencies = [ - "base16ct 0.2.0", - "der 0.7.1", - "generic-array 0.14.6", - "pkcs8 0.10.1", + "base16ct", + "der", + "generic-array 0.14.7", + "pkcs8", "subtle", "zeroize", ] @@ -4999,9 +6038,9 @@ dependencies = [ [[package]] name = "security-framework" -version = "2.8.2" +version = "2.9.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a332be01508d814fed64bf28f798a146d73792121129962fdf335bb3c49a4254" +checksum = "05b64fb303737d99b81884b2c63433e9ae28abebe5eb5045dcdd175dc2ecf4de" dependencies = [ "bitflags 1.3.2", "core-foundation", @@ -5012,9 +6051,9 @@ dependencies = [ [[package]] name = "security-framework-sys" -version = "2.8.0" +version = "2.9.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "31c9bb296072e961fcbd8853511dd39c2d8be2deb1e17c6860b1d30732b323b4" +checksum = "e932934257d3b408ed8f30db49d85ea163bfe74961f017f405b025af298f0c7a" dependencies = [ "core-foundation-sys", "libc", @@ -5022,13 +6061,31 @@ dependencies = [ [[package]] name = "semver" -version = "1.0.17" +version = "0.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f301af10236f6df4160f7c3f04eec6dbc70ace82d23326abad5edee88801c6b6" +dependencies = [ + "semver-parser", +] + +[[package]] +name = "semver" +version = "1.0.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bebd363326d05ec3e2f532ab7660680f3b02130d780c299bca73469d521bc0ed" +checksum = "b0293b4b29daaf487284529cc2f5675b8e57c61f70167ba415a463651fd6a918" dependencies = [ "serde", ] +[[package]] +name = "semver-parser" +version = "0.10.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "00b0bef5b7f9e0df16536d3961cfb6e84331c065b4066afb39768d0e319411f7" +dependencies = [ + "pest", +] + [[package]] name = "send_wrapper" version = "0.4.0" @@ -5043,31 +6100,42 @@ checksum = "cd0b0ec5f1c1ca621c432a25813d8d60c88abe6d3e08a3eb9cf37d97a0fe3d73" [[package]] name = "serde" -version = "1.0.158" +version = "1.0.180" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "771d4d9c4163ee138805e12c710dd365e4f44be8be0503cb1bb9eb989425d9c9" +checksum = "0ea67f183f058fe88a4e3ec6e2788e003840893b91bac4559cabedd00863b3ed" dependencies = [ "serde_derive", ] +[[package]] +name = "serde-hex" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ca37e3e4d1b39afd7ff11ee4e947efae85adfddf4841787bfa47c470e96dc26d" +dependencies = [ + "array-init", + "serde", + "smallvec 0.6.14", +] + [[package]] name = "serde_derive" -version = "1.0.158" +version = "1.0.180" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e801c1712f48475582b7696ac71e0ca34ebb30e09338425384269d9717c62cad" +checksum = "24e744d7782b686ab3b73267ef05697159cc0e5abbed3f47f9933165e5219036" dependencies = [ "proc-macro2", "quote", - "syn 2.0.5", + "syn 2.0.28", ] [[package]] name = "serde_json" -version = "1.0.94" +version = "1.0.104" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1c533a59c9d8a93a09c6ab31f0fd5e5f4dd1b8fc9434804029839884765d04ea" +checksum = "076066c5f1078eac5b722a31827a8832fe108bed65dfa75e233c89f8206e976c" dependencies = [ - "indexmap", + "indexmap 2.0.0", "itoa", "ryu", "serde", @@ -5085,9 +6153,9 @@ dependencies = [ [[package]] name = "serde_spanned" -version = "0.6.1" +version = "0.6.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0efd8caf556a6cebd3b285caf480045fcc1ac04f6bd786b09a6f11af30c4fcf4" +checksum = "96426c9936fd7a0124915f9185ea1d20aa9445cc9821142f0a73bc9207a2e186" dependencies = [ "serde", ] @@ -5125,7 +6193,7 @@ checksum = "f04293dc80c3993519f2d7f6f511707ee7094fe0c6d3406feb330cdb3540eba3" dependencies = [ "cfg-if", "cpufeatures", - "digest 0.10.6", + "digest 0.10.7", ] [[package]] @@ -5155,22 +6223,22 @@ dependencies = [ [[package]] name = "sha2" -version = "0.10.6" +version = "0.10.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "82e6b795fe2e3b1e845bafcb27aa35405c4d47cdfc92af5fc8d3002f76cebdc0" +checksum = "479fb9d862239e610720565ca91403019f2f00410f1864c5aa7479b950a76ed8" dependencies = [ "cfg-if", "cpufeatures", - "digest 0.10.6", + "digest 0.10.7", ] [[package]] name = "sha3" -version = "0.10.6" +version = "0.10.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bdf0c33fae925bdc080598b84bc15c55e7b9a4a43b3c704da051f977469691c9" +checksum = "75872d278a8f37ef87fa0ddbda7802605cb18344497949862c0d4dcb291eba60" dependencies = [ - "digest 0.10.6", + "digest 0.10.7", "keccak", ] @@ -5185,9 +6253,9 @@ dependencies = [ [[package]] name = "signal-hook" -version = "0.3.15" +version = "0.3.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "732768f1176d21d09e076c23a93123d40bba92d50c4058da34d45c8de8e682b9" +checksum = "8621587d4798caf8eb44879d42e56b9a93ea5dcd315a6487c357130095b62801" dependencies = [ "libc", "signal-hook-registry", @@ -5218,31 +6286,28 @@ name = "signature" version = "1.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "74233d3b3b2f6d4b006dc19dee745e73e2a6bfb6f93607cd3b02bd5b00797d7c" -dependencies = [ - "digest 0.10.6", - "rand_core 0.6.4", -] [[package]] name = "signature" -version = "2.0.0" +version = "2.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8fe458c98333f9c8152221191a77e2a44e8325d0193484af2e9421a53019e57d" +checksum = "5e1788eed21689f9cf370582dfc467ef36ed9c707f073528ddafa8d83e3b8500" dependencies = [ - "digest 0.10.6", + "digest 0.10.7", "rand_core 0.6.4", ] [[package]] name = "simba" -version = "0.5.1" +version = "0.8.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8e82063457853d00243beda9952e910b82593e4b07ae9f721b9278a99a0d3d5c" +checksum = "061507c94fc6ab4ba1c9a0305018408e312e17c041eb63bef8aa726fa33aceae" dependencies = [ "approx", "num-complex", "num-traits", "paste", + "wide", ] [[package]] @@ -5262,9 +6327,141 @@ dependencies = [ [[package]] name = "smallvec" -version = "1.10.0" +version = "0.6.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b97fcaeba89edba30f044a10c6a3cc39df9c3f17d7cd829dd1446cab35f890e0" +dependencies = [ + "maybe-uninit", +] + +[[package]] +name = "smallvec" +version = "1.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "62bb4feee49fdd9f707ef802e22365a35de4b7b299de4763d44bfea899442ff9" + +[[package]] +name = "smol" +version = "1.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "13f2b548cd8447f8de0fdf1c592929f70f4fc7039a05e47404b0d096ec6987a1" +dependencies = [ + "async-channel", + "async-executor", + "async-fs", + "async-io", + "async-lock", + "async-net", + "async-process", + "blocking", + "futures-lite", +] + +[[package]] +name = "smol_str" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "74212e6bbe9a4352329b2f68ba3130c15a3f26fe88ff22dbdc6cdd58fa85e99c" +dependencies = [ + "serde", +] + +[[package]] +name = "smoldot" +version = "0.8.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1cce5e2881b30bad7ef89f383a816ad0b22c45915911f28499026de4a76d20ee" +dependencies = [ + "arrayvec 0.7.4", + "async-lock", + "atomic", + "base64 0.21.2", + "bip39", + "blake2-rfc", + "bs58 0.5.0", + "crossbeam-queue", + "derive_more", + "ed25519-zebra", + "either", + "event-listener", + "fnv", + "futures-channel", + "futures-util", + "hashbrown 0.14.0", + "hex", + "hmac 0.12.1", + "itertools", + "libsecp256k1", + "merlin 3.0.0", + "no-std-net", + "nom", + "num-bigint", + "num-rational", + "num-traits", + "pbkdf2 0.12.2", + "pin-project", + "rand 0.8.5", + "rand_chacha 0.3.1", + "ruzstd", + "schnorrkel 0.10.2", + "serde", + "serde_json", + "sha2 0.10.7", + "siphasher", + "slab", + "smallvec 1.11.0", + "smol", + "snow", + "soketto", + "tiny-keccak", + "twox-hash", + "wasmi 0.30.0", +] + +[[package]] +name = "smoldot-light" +version = "0.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4b2f7b4687b83ff244ef6137735ed5716ad37dcdf3ee16c4eb1a32fb9808fa47" +dependencies = [ + "async-lock", + "blake2-rfc", + "derive_more", + "either", + "event-listener", + "fnv", + "futures-channel", + "futures-util", + "hashbrown 0.14.0", + "hex", + "itertools", + "log", + "lru 0.10.1", + "parking_lot", + "rand 0.8.5", + "serde", + "serde_json", + "siphasher", + "slab", + "smol", + "smoldot", +] + +[[package]] +name = "snow" +version = "0.9.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a507befe795404456341dfab10cef66ead4c041f62b8b11bbb92bffe5d0953e0" +checksum = "5ccba027ba85743e09d15c03296797cad56395089b832b48b5a5217880f57733" +dependencies = [ + "aes-gcm", + "blake2", + "chacha20poly1305", + "curve25519-dalek 4.0.0-rc.1", + "rand_core 0.6.4", + "rustc_version 0.4.0", + "sha2 0.10.7", + "subtle", +] [[package]] name = "socket2" @@ -5294,27 +6491,30 @@ dependencies = [ [[package]] name = "solang-parser" -version = "0.2.3" +version = "0.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ff87dae6cdccacdbf3b19e99b271083556e808de0f59c74a01482f64fdbc61fc" +checksum = "9c792fe9fae2a2f716846f214ca10d5a1e21133e0bf36cef34bcc4a852467b21" dependencies = [ "itertools", "lalrpop", "lalrpop-util", "phf", + "thiserror", "unicode-xid", ] [[package]] name = "sp-api" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.38#18bb7c7c841b101c19a8d1881b893ae8e37de460" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" dependencies = [ - "hash-db", + "hash-db 0.16.0", "log", "parity-scale-codec", + "scale-info", "sp-api-proc-macro", "sp-core 7.0.0", + "sp-metadata-ir", "sp-runtime 7.0.0", "sp-state-machine 0.13.0", "sp-std 5.0.0", @@ -5326,19 +6526,21 @@ dependencies = [ [[package]] name = "sp-api-proc-macro" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.38#18bb7c7c841b101c19a8d1881b893ae8e37de460" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" dependencies = [ + "Inflector", "blake2", + "expander", "proc-macro-crate", "proc-macro2", "quote", - "syn 1.0.109", + "syn 2.0.28", ] [[package]] name = "sp-application-crypto" version = "7.0.0" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.38#18bb7c7c841b101c19a8d1881b893ae8e37de460" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" dependencies = [ "parity-scale-codec", "scale-info", @@ -5350,36 +6552,36 @@ dependencies = [ [[package]] name = "sp-application-crypto" -version = "12.0.0" +version = "16.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a72575f160b1b134ee277a2ab46af4361c072a3fe661c48e474255406cb01c97" +checksum = "bb3e48446bc776e1578811706c4ad22f263e9fcff92127ecd55375eedc31d560" dependencies = [ "parity-scale-codec", "scale-info", "serde", - "sp-core 11.0.0", - "sp-io 12.0.0", + "sp-core 15.0.0", + "sp-io 16.0.0", "sp-std 6.0.0", ] [[package]] name = "sp-application-crypto" -version = "16.0.0" +version = "23.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bb3e48446bc776e1578811706c4ad22f263e9fcff92127ecd55375eedc31d560" +checksum = "899492ea547816d5dfe9a5a2ecc32f65a7110805af6da3380aa4902371b31dc2" dependencies = [ "parity-scale-codec", "scale-info", "serde", - "sp-core 15.0.0", - "sp-io 16.0.0", - "sp-std 6.0.0", + "sp-core 21.0.0", + "sp-io 23.0.0", + "sp-std 8.0.0", ] [[package]] name = "sp-arithmetic" version = "6.0.0" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.38#18bb7c7c841b101c19a8d1881b893ae8e37de460" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" dependencies = [ "integer-sqrt", "num-traits", @@ -5392,9 +6594,9 @@ dependencies = [ [[package]] name = "sp-arithmetic" -version = "9.0.0" +version = "12.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2038010f7514d50775dcbd3edb569e17fa9bda63128580a9e172abb1795f2c1d" +checksum = "7796939f2e3b68a3b9410ea17a2063b78038cd366f57fa772dd3be0798bd3412" dependencies = [ "integer-sqrt", "num-traits", @@ -5407,98 +6609,129 @@ dependencies = [ [[package]] name = "sp-arithmetic" -version = "12.0.0" +version = "16.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7796939f2e3b68a3b9410ea17a2063b78038cd366f57fa772dd3be0798bd3412" +checksum = "bb6020576e544c6824a51d651bc8df8e6ab67cd59f1c9ac09868bb81a5199ded" dependencies = [ "integer-sqrt", "num-traits", "parity-scale-codec", "scale-info", "serde", - "sp-std 6.0.0", + "sp-std 8.0.0", "static_assertions", ] [[package]] -name = "sp-beefy" +name = "sp-blockchain" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.38#18bb7c7c841b101c19a8d1881b893ae8e37de460" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" +dependencies = [ + "futures", + "log", + "lru 0.8.1", + "parity-scale-codec", + "parking_lot", + "sp-api", + "sp-consensus", + "sp-database", + "sp-runtime 7.0.0", + "sp-state-machine 0.13.0", + "thiserror", +] + +[[package]] +name = "sp-consensus" +version = "0.10.0-dev" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" dependencies = [ + "async-trait", + "futures", + "log", + "sp-core 7.0.0", + "sp-inherents", + "sp-runtime 7.0.0", + "sp-state-machine 0.13.0", + "thiserror", +] + +[[package]] +name = "sp-consensus-aura" +version = "0.10.0-dev" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" +dependencies = [ + "async-trait", "parity-scale-codec", "scale-info", - "serde", "sp-api", "sp-application-crypto 7.0.0", - "sp-core 7.0.0", - "sp-io 7.0.0", - "sp-mmr-primitives", + "sp-consensus", + "sp-consensus-slots", + "sp-inherents", "sp-runtime 7.0.0", "sp-std 5.0.0", + "sp-timestamp", ] [[package]] -name = "sp-blockchain" +name = "sp-consensus-beefy" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.38#18bb7c7c841b101c19a8d1881b893ae8e37de460" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" dependencies = [ - "futures", - "log", - "lru", + "lazy_static", "parity-scale-codec", - "parking_lot", + "scale-info", + "serde", "sp-api", - "sp-consensus", - "sp-database", + "sp-application-crypto 7.0.0", + "sp-core 7.0.0", + "sp-io 7.0.0", + "sp-mmr-primitives", "sp-runtime 7.0.0", - "sp-state-machine 0.13.0", - "thiserror", + "sp-std 5.0.0", + "strum 0.24.1", ] [[package]] -name = "sp-consensus" +name = "sp-consensus-slots" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.38#18bb7c7c841b101c19a8d1881b893ae8e37de460" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" dependencies = [ - "async-trait", - "futures", - "log", "parity-scale-codec", - "sp-core 7.0.0", - "sp-inherents", - "sp-runtime 7.0.0", - "sp-state-machine 0.13.0", + "scale-info", + "serde", "sp-std 5.0.0", - "sp-version", - "thiserror", + "sp-timestamp", ] [[package]] name = "sp-core" version = "7.0.0" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.38#18bb7c7c841b101c19a8d1881b893ae8e37de460" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" dependencies = [ "array-bytes", - "base58", "bitflags 1.3.2", "blake2", + "bounded-collections", + "bs58 0.4.0", "dyn-clonable", "ed25519-zebra", "futures", - "hash-db", + "hash-db 0.16.0", "hash256-std-hasher", "impl-serde", "lazy_static", "libsecp256k1", "log", - "merlin", + "merlin 2.0.1", "parity-scale-codec", "parking_lot", + "paste", "primitive-types", "rand 0.8.5", "regex", "scale-info", - "schnorrkel", + "schnorrkel 0.9.1", "secp256k1", "secrecy", "serde", @@ -5517,40 +6750,41 @@ dependencies = [ [[package]] name = "sp-core" -version = "11.0.0" +version = "15.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d99984f57c9eb858d29fbe0e4cf44092eec484b2ff72176d5afa4ab7bf1dc8b1" +checksum = "9b13a58a87e1ffbbf03a15425c001a036ad4d933e070807a60f73fa98a3bfdc8" dependencies = [ "array-bytes", "base58", "bitflags 1.3.2", "blake2", + "bounded-collections", "dyn-clonable", "ed25519-zebra", "futures", - "hash-db", + "hash-db 0.15.2", "hash256-std-hasher", "impl-serde", "lazy_static", "libsecp256k1", "log", - "merlin", + "merlin 2.0.1", "parity-scale-codec", "parking_lot", "primitive-types", "rand 0.8.5", "regex", "scale-info", - "schnorrkel", + "schnorrkel 0.9.1", "secp256k1", "secrecy", "serde", "sp-core-hashing 6.0.0", "sp-debug-derive 6.0.0", - "sp-externalities 0.15.0", - "sp-runtime-interface 10.0.0", + "sp-externalities 0.17.0", + "sp-runtime-interface 12.0.0", "sp-std 6.0.0", - "sp-storage 9.0.0", + "sp-storage 11.0.0", "ss58-registry", "substrate-bip39", "thiserror", @@ -5560,9 +6794,9 @@ dependencies = [ [[package]] name = "sp-core" -version = "15.0.0" +version = "17.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9b13a58a87e1ffbbf03a15425c001a036ad4d933e070807a60f73fa98a3bfdc8" +checksum = "9f02a8ea5a2a18f4a1d493f0dbb0d83668a73e2431701de65cd19b60e85b0723" dependencies = [ "array-bytes", "base58", @@ -5572,27 +6806,27 @@ dependencies = [ "dyn-clonable", "ed25519-zebra", "futures", - "hash-db", + "hash-db 0.15.2", "hash256-std-hasher", "impl-serde", "lazy_static", "libsecp256k1", "log", - "merlin", + "merlin 2.0.1", "parity-scale-codec", "parking_lot", "primitive-types", "rand 0.8.5", "regex", "scale-info", - "schnorrkel", + "schnorrkel 0.9.1", "secp256k1", "secrecy", "serde", "sp-core-hashing 6.0.0", "sp-debug-derive 6.0.0", "sp-externalities 0.17.0", - "sp-runtime-interface 12.0.0", + "sp-runtime-interface 14.0.0", "sp-std 6.0.0", "sp-storage 11.0.0", "ss58-registry", @@ -5604,41 +6838,42 @@ dependencies = [ [[package]] name = "sp-core" -version = "17.0.0" +version = "21.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9f02a8ea5a2a18f4a1d493f0dbb0d83668a73e2431701de65cd19b60e85b0723" +checksum = "f18d9e2f67d8661f9729f35347069ac29d92758b59135176799db966947a7336" dependencies = [ "array-bytes", - "base58", "bitflags 1.3.2", "blake2", "bounded-collections", + "bs58 0.4.0", "dyn-clonable", "ed25519-zebra", "futures", - "hash-db", + "hash-db 0.16.0", "hash256-std-hasher", "impl-serde", "lazy_static", "libsecp256k1", "log", - "merlin", + "merlin 2.0.1", "parity-scale-codec", "parking_lot", + "paste", "primitive-types", "rand 0.8.5", "regex", "scale-info", - "schnorrkel", + "schnorrkel 0.9.1", "secp256k1", "secrecy", "serde", - "sp-core-hashing 6.0.0", - "sp-debug-derive 6.0.0", - "sp-externalities 0.17.0", - "sp-runtime-interface 14.0.0", - "sp-std 6.0.0", - "sp-storage 11.0.0", + "sp-core-hashing 9.0.0", + "sp-debug-derive 8.0.0", + "sp-externalities 0.19.0", + "sp-runtime-interface 17.0.0", + "sp-std 8.0.0", + "sp-storage 13.0.0", "ss58-registry", "substrate-bip39", "thiserror", @@ -5649,12 +6884,12 @@ dependencies = [ [[package]] name = "sp-core-hashing" version = "5.0.0" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.38#18bb7c7c841b101c19a8d1881b893ae8e37de460" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" dependencies = [ - "blake2", + "blake2b_simd", "byteorder", - "digest 0.10.6", - "sha2 0.10.6", + "digest 0.10.7", + "sha2 0.10.7", "sha3", "sp-std 5.0.0", "twox-hash", @@ -5668,28 +6903,43 @@ checksum = "cbc2d1947252b7a4e403b0a260f596920443742791765ec111daa2bbf98eff25" dependencies = [ "blake2", "byteorder", - "digest 0.10.6", - "sha2 0.10.6", + "digest 0.10.7", + "sha2 0.10.7", "sha3", "sp-std 6.0.0", "twox-hash", ] +[[package]] +name = "sp-core-hashing" +version = "9.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2ee599a8399448e65197f9a6cee338ad192e9023e35e31f22382964c3c174c68" +dependencies = [ + "blake2b_simd", + "byteorder", + "digest 0.10.7", + "sha2 0.10.7", + "sha3", + "sp-std 8.0.0", + "twox-hash", +] + [[package]] name = "sp-core-hashing-proc-macro" version = "5.0.0" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.38#18bb7c7c841b101c19a8d1881b893ae8e37de460" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" dependencies = [ "proc-macro2", "quote", "sp-core-hashing 5.0.0", - "syn 1.0.109", + "syn 2.0.28", ] [[package]] name = "sp-database" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.38#18bb7c7c841b101c19a8d1881b893ae8e37de460" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" dependencies = [ "kvdb", "parking_lot", @@ -5698,11 +6948,11 @@ dependencies = [ [[package]] name = "sp-debug-derive" version = "5.0.0" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.38#18bb7c7c841b101c19a8d1881b893ae8e37de460" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" dependencies = [ "proc-macro2", "quote", - "syn 1.0.109", + "syn 2.0.28", ] [[package]] @@ -5716,10 +6966,21 @@ dependencies = [ "syn 1.0.109", ] +[[package]] +name = "sp-debug-derive" +version = "8.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c7f531814d2f16995144c74428830ccf7d94ff4a7749632b83ad8199b181140c" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.28", +] + [[package]] name = "sp-externalities" version = "0.13.0" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.38#18bb7c7c841b101c19a8d1881b893ae8e37de460" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" dependencies = [ "environmental", "parity-scale-codec", @@ -5729,36 +6990,37 @@ dependencies = [ [[package]] name = "sp-externalities" -version = "0.15.0" +version = "0.17.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dc754e1cec66b93df0b48a8986d019c1a2a90431c42cf2614cc35a291597c329" +checksum = "57052935c9c9b070ea6b339ef0da3bf241b7e065fc37f9c551669ee83ecfc3c1" dependencies = [ "environmental", "parity-scale-codec", "sp-std 6.0.0", - "sp-storage 9.0.0", + "sp-storage 11.0.0", ] [[package]] name = "sp-externalities" -version = "0.17.0" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "57052935c9c9b070ea6b339ef0da3bf241b7e065fc37f9c551669ee83ecfc3c1" +checksum = "a0f71c671e01a8ca60da925d43a1b351b69626e268b8837f8371e320cf1dd100" dependencies = [ "environmental", "parity-scale-codec", - "sp-std 6.0.0", - "sp-storage 11.0.0", + "sp-std 8.0.0", + "sp-storage 13.0.0", ] [[package]] name = "sp-inherents" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.38#18bb7c7c841b101c19a8d1881b893ae8e37de460" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" dependencies = [ "async-trait", "impl-trait-for-tuples", "parity-scale-codec", + "scale-info", "sp-core 7.0.0", "sp-runtime 7.0.0", "sp-std 5.0.0", @@ -5768,7 +7030,7 @@ dependencies = [ [[package]] name = "sp-io" version = "7.0.0" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.38#18bb7c7c841b101c19a8d1881b893ae8e37de460" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" dependencies = [ "bytes", "ed25519", @@ -5777,6 +7039,7 @@ dependencies = [ "libsecp256k1", "log", "parity-scale-codec", + "rustversion", "secp256k1", "sp-core 7.0.0", "sp-externalities 0.13.0", @@ -5792,9 +7055,9 @@ dependencies = [ [[package]] name = "sp-io" -version = "12.0.0" +version = "16.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ac917b37c7733e3778e7ffc3958f1181a151ac3b14116d65fb10fe7b08db10e" +checksum = "8b89f9726b6473b096e52fd995f2886f9c579ebda51392d3cbe2068ec11bd28e" dependencies = [ "bytes", "ed25519", @@ -5804,23 +7067,23 @@ dependencies = [ "log", "parity-scale-codec", "secp256k1", - "sp-core 11.0.0", - "sp-externalities 0.15.0", - "sp-keystore 0.17.0", - "sp-runtime-interface 10.0.0", - "sp-state-machine 0.17.0", + "sp-core 15.0.0", + "sp-externalities 0.17.0", + "sp-keystore 0.21.0", + "sp-runtime-interface 12.0.0", + "sp-state-machine 0.21.0", "sp-std 6.0.0", - "sp-tracing 7.0.0", - "sp-trie 11.0.0", + "sp-tracing 8.0.0", + "sp-trie 15.0.0", "tracing", "tracing-core", ] [[package]] name = "sp-io" -version = "16.0.0" +version = "23.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8b89f9726b6473b096e52fd995f2886f9c579ebda51392d3cbe2068ec11bd28e" +checksum = "9d597e35a9628fe7454b08965b2442e3ec0f264b0a90d41328e87422cec02e99" dependencies = [ "bytes", "ed25519", @@ -5829,15 +7092,16 @@ dependencies = [ "libsecp256k1", "log", "parity-scale-codec", + "rustversion", "secp256k1", - "sp-core 15.0.0", - "sp-externalities 0.17.0", - "sp-keystore 0.21.0", - "sp-runtime-interface 12.0.0", - "sp-state-machine 0.21.0", - "sp-std 6.0.0", - "sp-tracing 8.0.0", - "sp-trie 15.0.0", + "sp-core 21.0.0", + "sp-externalities 0.19.0", + "sp-keystore 0.27.0", + "sp-runtime-interface 17.0.0", + "sp-state-machine 0.28.0", + "sp-std 8.0.0", + "sp-tracing 10.0.0", + "sp-trie 22.0.0", "tracing", "tracing-core", ] @@ -5845,14 +7109,11 @@ dependencies = [ [[package]] name = "sp-keystore" version = "0.13.0" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.38#18bb7c7c841b101c19a8d1881b893ae8e37de460" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" dependencies = [ - "async-trait", "futures", - "merlin", "parity-scale-codec", "parking_lot", - "schnorrkel", "sp-core 7.0.0", "sp-externalities 0.13.0", "thiserror", @@ -5860,42 +7121,50 @@ dependencies = [ [[package]] name = "sp-keystore" -version = "0.17.0" +version = "0.21.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6ada8b7a72404bda58b3353830bc42f027ec764e13a28b4cd4386cf34fb1ae7c" +checksum = "85a4c5a3eb775dbe189e7bbb5f2990a2b19a989663281087f597e1fc1c6ecc50" dependencies = [ "async-trait", "futures", - "merlin", + "merlin 2.0.1", "parity-scale-codec", "parking_lot", - "schnorrkel", - "sp-core 11.0.0", - "sp-externalities 0.15.0", + "schnorrkel 0.9.1", + "sp-core 15.0.0", + "sp-externalities 0.17.0", "thiserror", ] [[package]] name = "sp-keystore" -version = "0.21.0" +version = "0.27.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "85a4c5a3eb775dbe189e7bbb5f2990a2b19a989663281087f597e1fc1c6ecc50" +checksum = "9be3cdd67cc1d9c1db17c5cbc4ec4924054a8437009d167f21f6590797e4aa45" dependencies = [ - "async-trait", "futures", - "merlin", "parity-scale-codec", "parking_lot", - "schnorrkel", - "sp-core 15.0.0", - "sp-externalities 0.17.0", + "sp-core 21.0.0", + "sp-externalities 0.19.0", "thiserror", ] +[[package]] +name = "sp-metadata-ir" +version = "0.1.0" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" +dependencies = [ + "frame-metadata 15.1.0", + "parity-scale-codec", + "scale-info", + "sp-std 5.0.0", +] + [[package]] name = "sp-mmr-primitives" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.38#18bb7c7c841b101c19a8d1881b893ae8e37de460" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" dependencies = [ "ckb-merkle-mountain-range 0.5.2 (registry+https://github.com/rust-lang/crates.io-index)", "log", @@ -5913,7 +7182,7 @@ dependencies = [ [[package]] name = "sp-panic-handler" version = "5.0.0" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.38#18bb7c7c841b101c19a8d1881b893ae8e37de460" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" dependencies = [ "backtrace", "lazy_static", @@ -5931,10 +7200,21 @@ dependencies = [ "regex", ] +[[package]] +name = "sp-panic-handler" +version = "8.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ebd2de46003fa8212426838ca71cd42ee36a26480ba9ffea983506ce03131033" +dependencies = [ + "backtrace", + "lazy_static", + "regex", +] + [[package]] name = "sp-runtime" version = "7.0.0" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.38#18bb7c7c841b101c19a8d1881b893ae8e37de460" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" dependencies = [ "either", "hash256-std-hasher", @@ -5955,9 +7235,9 @@ dependencies = [ [[package]] name = "sp-runtime" -version = "12.0.0" +version = "17.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c86578c67b060a6ecab52af64f1cf18b3892fca7fba5ffc5c49934b2e76b1929" +checksum = "ccb45605ded381a581ab89d4d38db4f4c93ab29a627ca1ad124a6739acb5e762" dependencies = [ "either", "hash256-std-hasher", @@ -5968,19 +7248,19 @@ dependencies = [ "rand 0.8.5", "scale-info", "serde", - "sp-application-crypto 12.0.0", - "sp-arithmetic 9.0.0", - "sp-core 11.0.0", - "sp-io 12.0.0", + "sp-application-crypto 16.0.0", + "sp-arithmetic 12.0.0", + "sp-core 15.0.0", + "sp-io 16.0.0", "sp-std 6.0.0", - "sp-weights 8.0.0", + "sp-weights 13.0.0", ] [[package]] name = "sp-runtime" -version = "17.0.0" +version = "24.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ccb45605ded381a581ab89d4d38db4f4c93ab29a627ca1ad124a6739acb5e762" +checksum = "21c5bfc764a1a8259d7e8f7cfd22c84006275a512c958d3ff966c92151e134d5" dependencies = [ "either", "hash256-std-hasher", @@ -5991,18 +7271,18 @@ dependencies = [ "rand 0.8.5", "scale-info", "serde", - "sp-application-crypto 16.0.0", - "sp-arithmetic 12.0.0", - "sp-core 15.0.0", - "sp-io 16.0.0", - "sp-std 6.0.0", - "sp-weights 13.0.0", + "sp-application-crypto 23.0.0", + "sp-arithmetic 16.0.0", + "sp-core 21.0.0", + "sp-io 23.0.0", + "sp-std 8.0.0", + "sp-weights 20.0.0", ] [[package]] name = "sp-runtime-interface" version = "7.0.0" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.38#18bb7c7c841b101c19a8d1881b893ae8e37de460" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" dependencies = [ "bytes", "impl-trait-for-tuples", @@ -6017,25 +7297,6 @@ dependencies = [ "static_assertions", ] -[[package]] -name = "sp-runtime-interface" -version = "10.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f3858935567385728ea45f6d159f9970b0b278eb22a8e77625bbf4a63e43a85a" -dependencies = [ - "bytes", - "impl-trait-for-tuples", - "parity-scale-codec", - "primitive-types", - "sp-externalities 0.15.0", - "sp-runtime-interface-proc-macro 7.0.0", - "sp-std 6.0.0", - "sp-storage 9.0.0", - "sp-tracing 7.0.0", - "sp-wasm-interface 8.0.0", - "static_assertions", -] - [[package]] name = "sp-runtime-interface" version = "12.0.0" @@ -6074,23 +7335,42 @@ dependencies = [ "static_assertions", ] +[[package]] +name = "sp-runtime-interface" +version = "17.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6e676128182f90015e916f806cba635c8141e341e7abbc45d25525472e1bbce8" +dependencies = [ + "bytes", + "impl-trait-for-tuples", + "parity-scale-codec", + "primitive-types", + "sp-externalities 0.19.0", + "sp-runtime-interface-proc-macro 11.0.0", + "sp-std 8.0.0", + "sp-storage 13.0.0", + "sp-tracing 10.0.0", + "sp-wasm-interface 14.0.0", + "static_assertions", +] + [[package]] name = "sp-runtime-interface-proc-macro" version = "6.0.0" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.38#18bb7c7c841b101c19a8d1881b893ae8e37de460" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" dependencies = [ "Inflector", "proc-macro-crate", "proc-macro2", "quote", - "syn 1.0.109", + "syn 2.0.28", ] [[package]] name = "sp-runtime-interface-proc-macro" -version = "7.0.0" +version = "8.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "00083a77e938c4f35d0bde7ca0b6e5f616158ebe11af6063795aa664d92a238b" +checksum = "a6f3d42d7ea6b34fc110dae7ca8aaecbe976ac86942bbcbd7caf2ef8bfad808e" dependencies = [ "Inflector", "proc-macro-crate", @@ -6101,9 +7381,9 @@ dependencies = [ [[package]] name = "sp-runtime-interface-proc-macro" -version = "8.0.0" +version = "9.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a6f3d42d7ea6b34fc110dae7ca8aaecbe976ac86942bbcbd7caf2ef8bfad808e" +checksum = "2773c90e5765847c5e8b4a24b553d38a9ca52ded47c142cfcfb7948f42827af9" dependencies = [ "Inflector", "proc-macro-crate", @@ -6114,21 +7394,21 @@ dependencies = [ [[package]] name = "sp-runtime-interface-proc-macro" -version = "9.0.0" +version = "11.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2773c90e5765847c5e8b4a24b553d38a9ca52ded47c142cfcfb7948f42827af9" +checksum = "a5d5bd5566fe5633ec48dfa35ab152fd29f8a577c21971e1c6db9f28afb9bbb9" dependencies = [ "Inflector", "proc-macro-crate", "proc-macro2", "quote", - "syn 1.0.109", + "syn 2.0.28", ] [[package]] name = "sp-session" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.38#18bb7c7c841b101c19a8d1881b893ae8e37de460" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" dependencies = [ "parity-scale-codec", "scale-info", @@ -6142,10 +7422,11 @@ dependencies = [ [[package]] name = "sp-staking" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.38#18bb7c7c841b101c19a8d1881b893ae8e37de460" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" dependencies = [ "parity-scale-codec", "scale-info", + "serde", "sp-core 7.0.0", "sp-runtime 7.0.0", "sp-std 5.0.0", @@ -6154,14 +7435,14 @@ dependencies = [ [[package]] name = "sp-state-machine" version = "0.13.0" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.38#18bb7c7c841b101c19a8d1881b893ae8e37de460" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" dependencies = [ - "hash-db", + "hash-db 0.16.0", "log", "parity-scale-codec", "parking_lot", "rand 0.8.5", - "smallvec", + "smallvec 1.11.0", "sp-core 7.0.0", "sp-externalities 0.13.0", "sp-panic-handler 5.0.0", @@ -6173,42 +7454,42 @@ dependencies = [ [[package]] name = "sp-state-machine" -version = "0.17.0" +version = "0.21.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f1fd4c600df0b5abf26c19b6c61d928b64e0c2b8a709a3dbef872be0507cd1ca" +checksum = "5b5a9ed0ba877ea0d3b2b7d720b225444151cc9060f098cb6d4dcc3a68bd3d2a" dependencies = [ - "hash-db", + "hash-db 0.15.2", "log", "parity-scale-codec", "parking_lot", "rand 0.8.5", - "smallvec", - "sp-core 11.0.0", - "sp-externalities 0.15.0", + "smallvec 1.11.0", + "sp-core 15.0.0", + "sp-externalities 0.17.0", "sp-panic-handler 6.0.0", "sp-std 6.0.0", - "sp-trie 11.0.0", + "sp-trie 15.0.0", "thiserror", "tracing", ] [[package]] name = "sp-state-machine" -version = "0.21.0" +version = "0.28.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b5a9ed0ba877ea0d3b2b7d720b225444151cc9060f098cb6d4dcc3a68bd3d2a" +checksum = "9ef45d31f9e7ac648f8899a0cd038a3608f8499028bff55b6c799702592325b6" dependencies = [ - "hash-db", + "hash-db 0.16.0", "log", "parity-scale-codec", "parking_lot", "rand 0.8.5", - "smallvec", - "sp-core 15.0.0", - "sp-externalities 0.17.0", - "sp-panic-handler 6.0.0", - "sp-std 6.0.0", - "sp-trie 15.0.0", + "smallvec 1.11.0", + "sp-core 21.0.0", + "sp-externalities 0.19.0", + "sp-panic-handler 8.0.0", + "sp-std 8.0.0", + "sp-trie 22.0.0", "thiserror", "tracing", ] @@ -6216,7 +7497,7 @@ dependencies = [ [[package]] name = "sp-std" version = "5.0.0" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.38#18bb7c7c841b101c19a8d1881b893ae8e37de460" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" [[package]] name = "sp-std" @@ -6224,10 +7505,16 @@ version = "6.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "af0ee286f98455272f64ac5bb1384ff21ac029fbb669afbaf48477faff12760e" +[[package]] +name = "sp-std" +version = "8.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "53458e3c57df53698b3401ec0934bea8e8cfce034816873c0b0abbd83d7bac0d" + [[package]] name = "sp-storage" version = "7.0.0" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.38#18bb7c7c841b101c19a8d1881b893ae8e37de460" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" dependencies = [ "impl-serde", "parity-scale-codec", @@ -6239,9 +7526,9 @@ dependencies = [ [[package]] name = "sp-storage" -version = "9.0.0" +version = "11.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9acb4059eb0ae4fa8cf9ca9119b0178ad312a592d4c6054bd17b411034f233e9" +checksum = "3c20cb0c562d1a159ecb2c7ca786828c81e432c535474967d2df3a484977cea4" dependencies = [ "impl-serde", "parity-scale-codec", @@ -6253,22 +7540,22 @@ dependencies = [ [[package]] name = "sp-storage" -version = "11.0.0" +version = "13.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3c20cb0c562d1a159ecb2c7ca786828c81e432c535474967d2df3a484977cea4" +checksum = "94294be83f11d4958cfea89ed5798f0b6605f5defc3a996948848458abbcc18e" dependencies = [ "impl-serde", "parity-scale-codec", "ref-cast", "serde", - "sp-debug-derive 6.0.0", - "sp-std 6.0.0", + "sp-debug-derive 8.0.0", + "sp-std 8.0.0", ] [[package]] name = "sp-timestamp" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.38#18bb7c7c841b101c19a8d1881b893ae8e37de460" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" dependencies = [ "async-trait", "futures-timer", @@ -6283,7 +7570,7 @@ dependencies = [ [[package]] name = "sp-tracing" version = "6.0.0" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.38#18bb7c7c841b101c19a8d1881b893ae8e37de460" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" dependencies = [ "parity-scale-codec", "sp-std 5.0.0", @@ -6294,9 +7581,9 @@ dependencies = [ [[package]] name = "sp-tracing" -version = "7.0.0" +version = "8.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b22d28a0bc2365dfb86644d14f2682a79da35891d4656d4896fb09fb05ff1e6c" +checksum = "e46bd547da89a9cda69b4ce4c91a5b7e1f86915190d83cd407b715d0c6bac042" dependencies = [ "parity-scale-codec", "sp-std 6.0.0", @@ -6307,12 +7594,12 @@ dependencies = [ [[package]] name = "sp-tracing" -version = "8.0.0" +version = "10.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e46bd547da89a9cda69b4ce4c91a5b7e1f86915190d83cd407b715d0c6bac042" +checksum = "357f7591980dd58305956d32f8f6646d0a8ea9ea0e7e868e46f53b68ddf00cec" dependencies = [ "parity-scale-codec", - "sp-std 6.0.0", + "sp-std 8.0.0", "tracing", "tracing-core", "tracing-subscriber 0.2.25", @@ -6321,13 +7608,13 @@ dependencies = [ [[package]] name = "sp-trie" version = "7.0.0" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.38#18bb7c7c841b101c19a8d1881b893ae8e37de460" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" dependencies = [ "ahash 0.8.3", - "hash-db", - "hashbrown 0.12.3", + "hash-db 0.16.0", + "hashbrown 0.13.2", "lazy_static", - "memory-db 0.31.0", + "memory-db 0.32.0", "nohash-hasher", "parity-scale-codec", "parking_lot", @@ -6337,42 +7624,42 @@ dependencies = [ "sp-std 5.0.0", "thiserror", "tracing", - "trie-db", - "trie-root", + "trie-db 0.27.1", + "trie-root 0.18.0", ] [[package]] name = "sp-trie" -version = "11.0.0" +version = "15.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "db085f134cb444e52ca569a442d12c84bd17667532613d78dd6f568942632da4" +checksum = "a003ea58d0e1d2944032a45625eedcc12f67612a3939152dc7e80252486b6751" dependencies = [ - "ahash 0.7.6", - "hash-db", + "ahash 0.8.3", + "hash-db 0.15.2", "hashbrown 0.12.3", "lazy_static", - "lru", "memory-db 0.31.0", "nohash-hasher", "parity-scale-codec", "parking_lot", "scale-info", - "sp-core 11.0.0", + "schnellru", + "sp-core 15.0.0", "sp-std 6.0.0", "thiserror", "tracing", - "trie-db", - "trie-root", + "trie-db 0.24.0", + "trie-root 0.17.0", ] [[package]] name = "sp-trie" -version = "15.0.0" +version = "17.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a003ea58d0e1d2944032a45625eedcc12f67612a3939152dc7e80252486b6751" +checksum = "cba198d0450e16b2d3cd10f5d31560d3ebbd5c7b903184c18e337bb407d02175" dependencies = [ "ahash 0.8.3", - "hash-db", + "hash-db 0.15.2", "hashbrown 0.12.3", "lazy_static", "memory-db 0.31.0", @@ -6381,42 +7668,42 @@ dependencies = [ "parking_lot", "scale-info", "schnellru", - "sp-core 15.0.0", + "sp-core 17.0.0", "sp-std 6.0.0", "thiserror", "tracing", - "trie-db", - "trie-root", + "trie-db 0.24.0", + "trie-root 0.17.0", ] [[package]] name = "sp-trie" -version = "17.0.0" +version = "22.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cba198d0450e16b2d3cd10f5d31560d3ebbd5c7b903184c18e337bb407d02175" +checksum = "48e4eeb7ef23f79eba8609db79ef9cef242f994f1f87a3c0387b4b5f177fda74" dependencies = [ "ahash 0.8.3", - "hash-db", - "hashbrown 0.12.3", + "hash-db 0.16.0", + "hashbrown 0.13.2", "lazy_static", - "memory-db 0.31.0", + "memory-db 0.32.0", "nohash-hasher", "parity-scale-codec", "parking_lot", "scale-info", "schnellru", - "sp-core 17.0.0", - "sp-std 6.0.0", + "sp-core 21.0.0", + "sp-std 8.0.0", "thiserror", "tracing", - "trie-db", - "trie-root", + "trie-db 0.27.1", + "trie-root 0.18.0", ] [[package]] name = "sp-version" version = "5.0.0" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.38#18bb7c7c841b101c19a8d1881b893ae8e37de460" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" dependencies = [ "impl-serde", "parity-scale-codec", @@ -6433,79 +7720,80 @@ dependencies = [ [[package]] name = "sp-version-proc-macro" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.38#18bb7c7c841b101c19a8d1881b893ae8e37de460" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" dependencies = [ "parity-scale-codec", "proc-macro2", "quote", - "syn 1.0.109", + "syn 2.0.28", ] [[package]] name = "sp-wasm-interface" version = "7.0.0" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.38#18bb7c7c841b101c19a8d1881b893ae8e37de460" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" dependencies = [ + "anyhow", "impl-trait-for-tuples", "log", "parity-scale-codec", "sp-std 5.0.0", - "wasmi", - "wasmtime 1.0.2", + "wasmi 0.13.2", + "wasmtime 6.0.2", ] [[package]] name = "sp-wasm-interface" -version = "8.0.0" +version = "9.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3ebc377987d42f8fc20e3f4ec4fd1147dd098fe90bcb4269e1eddb04e920f889" +checksum = "92e37c12659709ca8eb380d44c784368ca78dca58f2cd8e17c33371a2702b10e" dependencies = [ "impl-trait-for-tuples", "log", "parity-scale-codec", "sp-std 6.0.0", - "wasmi", + "wasmi 0.13.2", "wasmtime 1.0.2", ] [[package]] name = "sp-wasm-interface" -version = "9.0.0" +version = "11.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "92e37c12659709ca8eb380d44c784368ca78dca58f2cd8e17c33371a2702b10e" +checksum = "f64b40073473be37185cd8f85852fa79c98908b44cc5a3137483a8be4d47acfd" dependencies = [ + "anyhow", "impl-trait-for-tuples", "log", "parity-scale-codec", "sp-std 6.0.0", - "wasmi", - "wasmtime 1.0.2", + "wasmi 0.13.2", + "wasmtime 5.0.1", ] [[package]] name = "sp-wasm-interface" -version = "11.0.0" +version = "14.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f64b40073473be37185cd8f85852fa79c98908b44cc5a3137483a8be4d47acfd" +checksum = "a19c122609ca5d8246be6386888596320d03c7bc880959eaa2c36bcd5acd6846" dependencies = [ "anyhow", "impl-trait-for-tuples", "log", "parity-scale-codec", - "sp-std 6.0.0", - "wasmi", - "wasmtime 5.0.1", + "sp-std 8.0.0", + "wasmtime 8.0.1", ] [[package]] name = "sp-weights" version = "4.0.0" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.38#18bb7c7c841b101c19a8d1881b893ae8e37de460" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.42#ff24c60ac7d9f87727ecdd0ded9a80c56e4f4b65" dependencies = [ "parity-scale-codec", "scale-info", "serde", - "smallvec", + "smallvec 1.11.0", "sp-arithmetic 6.0.0", "sp-core 7.0.0", "sp-debug-derive 5.0.0", @@ -6514,34 +7802,34 @@ dependencies = [ [[package]] name = "sp-weights" -version = "8.0.0" +version = "13.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90eca2a19f48978e9cd605e23905d0602419f7880a9360ac717b03412e9c7916" +checksum = "09e47b360be9c14f3f9f4c546ae4c39e89e1d33022798b46c8d84ea883a9dd87" dependencies = [ "parity-scale-codec", "scale-info", "serde", - "smallvec", - "sp-arithmetic 9.0.0", - "sp-core 11.0.0", + "smallvec 1.11.0", + "sp-arithmetic 12.0.0", + "sp-core 15.0.0", "sp-debug-derive 6.0.0", "sp-std 6.0.0", ] [[package]] name = "sp-weights" -version = "13.0.0" +version = "20.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "09e47b360be9c14f3f9f4c546ae4c39e89e1d33022798b46c8d84ea883a9dd87" +checksum = "45d084c735544f70625b821c3acdbc7a2fc1893ca98b85f1942631284692c75b" dependencies = [ "parity-scale-codec", "scale-info", "serde", - "smallvec", - "sp-arithmetic 12.0.0", - "sp-core 15.0.0", - "sp-debug-derive 6.0.0", - "sp-std 6.0.0", + "smallvec 1.11.0", + "sp-arithmetic 16.0.0", + "sp-core 21.0.0", + "sp-debug-derive 8.0.0", + "sp-std 8.0.0", ] [[package]] @@ -6551,30 +7839,26 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6e63cff320ae2c57904679ba7cb63280a3dc4613885beafb148ee7bf9aa9042d" [[package]] -name = "spki" -version = "0.6.0" +name = "spin" +version = "0.9.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "67cf02bbac7a337dc36e4f5a693db6c21e7863f45070f7064577eb4367a3212b" -dependencies = [ - "base64ct", - "der 0.6.1", -] +checksum = "6980e8d7511241f8acf4aebddbb1ff938df5eebe98691418c4468d0b72a96a67" [[package]] name = "spki" -version = "0.7.0" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c0445c905640145c7ea8c1993555957f65e7c46d0535b91ba501bc9bfc85522f" +checksum = "9d1e996ef02c474957d681f1b05213dfb0abab947b446a62d37770b23500184a" dependencies = [ "base64ct", - "der 0.7.1", + "der", ] [[package]] name = "ss58-registry" -version = "1.39.0" +version = "1.41.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ecf0bd63593ef78eca595a7fc25e9a443ca46fe69fd472f8f09f5245cdcd769d" +checksum = "bfc443bad666016e012538782d9e3006213a7db43e9fb1dda91657dc06a6fa08" dependencies = [ "Inflector", "num-format", @@ -6597,19 +7881,6 @@ version = "1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a2eb9349b6444b326872e140eb1cf5e7c522154d69e7a0ffb0fb81c06b37543f" -[[package]] -name = "statrs" -version = "0.15.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "05bdbb8e4e78216a85785a85d3ec3183144f98d0097b9281802c019bb07a6f05" -dependencies = [ - "approx", - "lazy_static", - "nalgebra", - "num-traits", - "rand 0.8.5", -] - [[package]] name = "string_cache" version = "0.8.7" @@ -6635,7 +7906,16 @@ version = "0.24.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "063e6045c0e62079840579a7e47a355ae92f60eb74daaf156fb1e84ba164e63f" dependencies = [ - "strum_macros", + "strum_macros 0.24.3", +] + +[[package]] +name = "strum" +version = "0.25.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "290d54ea6f91c969195bdbcd7442c8c2a2ba87da8bf60a7ee86a235d4bc1e125" +dependencies = [ + "strum_macros 0.25.1", ] [[package]] @@ -6651,6 +7931,19 @@ dependencies = [ "syn 1.0.109", ] +[[package]] +name = "strum_macros" +version = "0.25.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6069ca09d878a33f883cc06aaa9718ede171841d3832450354410b718b097232" +dependencies = [ + "heck", + "proc-macro2", + "quote", + "rustversion", + "syn 2.0.28", +] + [[package]] name = "substrate-bip39" version = "0.4.4" @@ -6659,7 +7952,7 @@ checksum = "49eee6965196b32f882dd2ee85a92b1dbead41b04e53907f269de3b0dc04733c" dependencies = [ "hmac 0.11.0", "pbkdf2 0.8.0", - "schnorrkel", + "schnorrkel 0.9.1", "sha2 0.9.9", "zeroize", ] @@ -6683,32 +7976,40 @@ version = "2.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6bdef32e8150c2a081110b42772ffe7d7c9032b606bc226c8260fd97e0976601" +[[package]] +name = "subtle-ng" +version = "2.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "734676eb262c623cec13c3155096e08d1f8f29adce39ba17948b18dad1e54142" + [[package]] name = "subxt" -version = "0.26.0" -source = "git+https://github.com/paritytech/subxt?rev=d92352ad739836a4100e1ef1db607acc82ed8c5a#d92352ad739836a4100e1ef1db607acc82ed8c5a" +version = "0.30.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0ba02ada83ba2640c46e200a1758cc83ce876a16326d2c52ca5db41b7d6645ce" dependencies = [ "base58", "blake2", "derivative", - "frame-metadata", + "either", + "frame-metadata 16.0.0", "futures", - "getrandom 0.2.8", "hex", "impl-serde", "jsonrpsee", "parity-scale-codec", - "parking_lot", "primitive-types", "scale-bits", "scale-decode", + "scale-encode", "scale-info", "scale-value", "serde", "serde_json", - "sp-core 11.0.0", - "sp-core-hashing 6.0.0", - "sp-runtime 12.0.0", + "sp-core 21.0.0", + "sp-core-hashing 9.0.0", + "sp-runtime 24.0.0", + "subxt-lightclient", "subxt-macro", "subxt-metadata", "thiserror", @@ -6717,86 +8018,95 @@ dependencies = [ [[package]] name = "subxt-codegen" -version = "0.26.0" -source = "git+https://github.com/paritytech/subxt?rev=d92352ad739836a4100e1ef1db607acc82ed8c5a#d92352ad739836a4100e1ef1db607acc82ed8c5a" +version = "0.30.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3213eb04567e710aa253b94de74337c7b663eea52114805b8723129763282779" dependencies = [ - "darling", - "frame-metadata", + "frame-metadata 16.0.0", "heck", "hex", "jsonrpsee", "parity-scale-codec", - "proc-macro-error", "proc-macro2", "quote", "scale-info", "subxt-metadata", - "syn 1.0.109", + "syn 2.0.28", + "thiserror", + "tokio", +] + +[[package]] +name = "subxt-lightclient" +version = "0.30.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "439a235bedd0e460c110e5341d919ec3a27f9be3dd4c1c944daad8a9b54d396d" +dependencies = [ + "futures", + "futures-util", + "serde", + "serde_json", + "smoldot-light", + "thiserror", "tokio", + "tokio-stream", + "tracing", ] [[package]] name = "subxt-macro" -version = "0.26.0" -source = "git+https://github.com/paritytech/subxt?rev=d92352ad739836a4100e1ef1db607acc82ed8c5a#d92352ad739836a4100e1ef1db607acc82ed8c5a" +version = "0.30.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cfda460cc5f701785973382c589e9bb12c23bb8d825bfc3ac547b7c672aba1c0" dependencies = [ - "darling", + "darling 0.20.3", "proc-macro-error", "subxt-codegen", - "syn 1.0.109", + "syn 2.0.28", ] [[package]] name = "subxt-metadata" -version = "0.26.0" -source = "git+https://github.com/paritytech/subxt?rev=d92352ad739836a4100e1ef1db607acc82ed8c5a#d92352ad739836a4100e1ef1db607acc82ed8c5a" +version = "0.30.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0283bd02163913fbd0a5153d0b179533e48b239b953fa4e43baa27c73f18861c" dependencies = [ - "frame-metadata", + "frame-metadata 16.0.0", "parity-scale-codec", "scale-info", - "sp-core-hashing 6.0.0", + "sp-core-hashing 9.0.0", + "thiserror", ] [[package]] name = "svm-rs" -version = "0.2.22" +version = "0.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "01afefe60c02f4a2271fb15d1965c37856712cebb338330b06649d12afec42df" +checksum = "597e3a746727984cb7ea2487b6a40726cad0dbe86628e7d429aa6b8c4c153db4" dependencies = [ - "anyhow", - "cfg-if", - "clap 3.2.23", - "console 0.14.1", - "dialoguer", + "dirs", "fs2", "hex", - "home", - "indicatif", - "itertools", "once_cell", - "rand 0.8.5", "reqwest", - "semver", + "semver 1.0.18", "serde", "serde_json", - "sha2 0.9.9", - "tempfile", + "sha2 0.10.7", "thiserror", - "tokio", - "tracing", "url", "zip", ] [[package]] name = "svm-rs-builds" -version = "0.1.14" +version = "0.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2e69c19996b709c881de264a6ce64609ff305ef0bf59fc45243ac5a67291afd1" +checksum = "2271abd7d01895a3e5bfa4b578e32f09155002ce1ec239532e297f82aafad06b" dependencies = [ "build_const", "hex", - "semver", + "semver 1.0.18", "serde_json", "svm-rs", ] @@ -6814,9 +8124,9 @@ dependencies = [ [[package]] name = "syn" -version = "2.0.5" +version = "2.0.28" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "89c2d1c76a26822187a1fbb5964e3fff108bc208f02e820ab9dac1234f6b388a" +checksum = "04361975b3f5e348b2189d8dc55bc942f278b2d482a6a0365de5bdd62d351567" dependencies = [ "proc-macro2", "quote", @@ -6824,15 +8134,14 @@ dependencies = [ ] [[package]] -name = "synstructure" -version = "0.12.6" +name = "syn-solidity" +version = "0.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f36bdaa60a83aca3921b5259d5400cbf5e90fc51931376a9bd4a0eb79aa7210f" +checksum = "e5f995d2140b0f751dbe94365be2591edbf3d1b75dcfaeac14183abbd2ff07bd" dependencies = [ "proc-macro2", "quote", - "syn 1.0.109", - "unicode-xid", + "syn 2.0.28", ] [[package]] @@ -6843,21 +8152,21 @@ checksum = "55937e1799185b12863d447f42597ed69d9928686b8d88a1df17376a097d8369" [[package]] name = "target-lexicon" -version = "0.12.6" +version = "0.12.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ae9980cab1db3fceee2f6c6f643d5d8de2997c58ee8d25fb0cc8a9e9e7348e5" +checksum = "9d0e916b1148c8e263850e1ebcbd046f333e0683c724876bb0da63ea4373dc8a" [[package]] name = "tempfile" -version = "3.4.0" +version = "3.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "af18f7ae1acd354b992402e9ec5864359d693cd8a79dcbef59f76891701c1e95" +checksum = "5486094ee78b2e5038a6382ed7645bc084dc2ec433426ca4c3cb61e2007b8998" dependencies = [ "cfg-if", - "fastrand", - "redox_syscall", - "rustix 0.36.11", - "windows-sys 0.42.0", + "fastrand 2.0.0", + "redox_syscall 0.3.5", + "rustix 0.38.4", + "windows-sys 0.48.0", ] [[package]] @@ -6872,58 +8181,53 @@ dependencies = [ ] [[package]] -name = "termcolor" -version = "1.2.0" +name = "terminal_size" +version = "0.2.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "be55cf8942feac5c765c2c993422806843c9a9a45d4d5c407ad6dd2ea95eb9b6" +checksum = "8e6bf6f19e9f8ed8d4048dc22981458ebcf406d67e94cd422e5ecd73d63b3237" dependencies = [ - "winapi-util", + "rustix 0.37.23", + "windows-sys 0.48.0", ] [[package]] -name = "terminal_size" -version = "0.1.17" +name = "thiserror" +version = "1.0.44" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "633c1a546cee861a1a6d0dc69ebeca693bf4296661ba7852b9d21d159e0506df" +checksum = "611040a08a0439f8248d1990b111c95baa9c704c805fa1f62104b39655fd7f90" dependencies = [ - "libc", - "winapi", + "thiserror-impl", ] [[package]] -name = "terminal_size" -version = "0.2.5" +name = "thiserror-core" +version = "1.0.38" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4c9afddd2cec1c0909f06b00ef33f94ab2cc0578c4a610aa208ddfec8aa2b43a" +checksum = "0d97345f6437bb2004cd58819d8a9ef8e36cdd7661c2abc4bbde0a7c40d9f497" dependencies = [ - "rustix 0.36.11", - "windows-sys 0.45.0", + "thiserror-core-impl", ] [[package]] -name = "textwrap" -version = "0.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "222a222a5bfe1bba4a77b45ec488a741b3cb8872e5e499451fd7d0129c9c7c3d" - -[[package]] -name = "thiserror" -version = "1.0.40" +name = "thiserror-core-impl" +version = "1.0.38" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "978c9a314bd8dc99be594bc3c175faaa9794be04a5a5e153caba6915336cebac" +checksum = "10ac1c5050e43014d16b2f94d0d2ce79e65ffdd8b38d8048f9c8f6a8a6da62ac" dependencies = [ - "thiserror-impl", + "proc-macro2", + "quote", + "syn 1.0.109", ] [[package]] name = "thiserror-impl" -version = "1.0.40" +version = "1.0.44" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f9456a42c5b0d803c8cd86e73dd7cc9edd429499f37a3550d286d5e86720569f" +checksum = "090198534930841fab3a5d1bb637cde49e339654e606195f8d9c76eeb081dc96" dependencies = [ "proc-macro2", "quote", - "syn 2.0.5", + "syn 2.0.28", ] [[package]] @@ -6938,19 +8242,20 @@ dependencies = [ [[package]] name = "time" -version = "0.3.20" +version = "0.3.24" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cd0cbfecb4d19b5ea75bb31ad904eb5b9fa13f21079c3b92017ebdf4999a5890" +checksum = "b79eabcd964882a646b3584543ccabeae7869e9ac32a46f6f22b7a5bd405308b" dependencies = [ + "deranged", "serde", "time-core", ] [[package]] name = "time-core" -version = "0.1.0" +version = "0.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2e153e1f1acaef8acc537e68b44906d2db6436e2b35ac2c6b42640fff91f00fd" +checksum = "7300fbefb4dadc1af235a9cef3737cea692a9d97e1b9cbcd4ebdae6f8868e6fb" [[package]] name = "tiny-bip39" @@ -6964,7 +8269,7 @@ dependencies = [ "pbkdf2 0.11.0", "rand 0.8.5", "rustc-hash", - "sha2 0.10.6", + "sha2 0.10.7", "thiserror", "unicode-normalization", "wasm-bindgen", @@ -6997,33 +8302,32 @@ checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" [[package]] name = "tokio" -version = "1.26.0" +version = "1.29.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "03201d01c3c27a29c8a5cee5b55a93ddae1ccf6f08f65365c2c918f8c1b76f64" +checksum = "532826ff75199d5833b9d2c5fe410f29235e25704ee5f0ef599fb51c21f4a4da" dependencies = [ "autocfg", + "backtrace", "bytes", "libc", - "memchr", "mio", "num_cpus", - "parking_lot", "pin-project-lite", "signal-hook-registry", "socket2", "tokio-macros", - "windows-sys 0.45.0", + "windows-sys 0.48.0", ] [[package]] name = "tokio-macros" -version = "1.8.2" +version = "2.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d266c00fde287f55d3f1c3e96c500c362a2b8c695076ec180f27918820bc6df8" +checksum = "630bdcf245f78637c13ec01ffae6187cca34625e8c63150d424b59e55af2675e" dependencies = [ "proc-macro2", "quote", - "syn 1.0.109", + "syn 2.0.28", ] [[package]] @@ -7032,16 +8336,26 @@ version = "0.23.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c43ee83903113e03984cb9e5cebe6c04a5116269e900e3ddba8f068a62adda59" dependencies = [ - "rustls", + "rustls 0.20.8", "tokio", "webpki", ] +[[package]] +name = "tokio-rustls" +version = "0.24.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c28327cf380ac148141087fbfb9de9d7bd4e84ab5d2c28fbc911d753de8a7081" +dependencies = [ + "rustls 0.21.5", + "tokio", +] + [[package]] name = "tokio-stream" -version = "0.1.12" +version = "0.1.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8fb52b74f05dbf495a8fba459fdc331812b96aa086d9eb78101fa0d4569c3313" +checksum = "397c988d37662c7dda6d2208364a706264bf3d6138b11d436cbac0ad38832842" dependencies = [ "futures-core", "pin-project-lite", @@ -7050,25 +8364,24 @@ dependencies = [ [[package]] name = "tokio-tungstenite" -version = "0.18.0" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "54319c93411147bced34cb5609a80e0a8e44c5999c93903a81cd866630ec0bfd" +checksum = "ec509ac96e9a0c43427c74f003127d953a265737636129424288d27cb5c4b12c" dependencies = [ "futures-util", "log", - "rustls", + "rustls 0.21.5", "tokio", - "tokio-rustls", + "tokio-rustls 0.24.1", "tungstenite", - "webpki", - "webpki-roots", + "webpki-roots 0.23.1", ] [[package]] name = "tokio-util" -version = "0.7.7" +version = "0.7.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5427d89453009325de0d8f342c9490009f76e999cb7672d77e46267448f7e6b2" +checksum = "806fe8c2c87eccc8b3267cbae29ed3ab2d0bd37fca70ab622e46aaa9375ddb7d" dependencies = [ "bytes", "futures-core", @@ -7081,53 +8394,33 @@ dependencies = [ [[package]] name = "toml" -version = "0.5.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f4f7f0dd8d50a853a531c426359045b1998f04219d88799810762cd4ad314234" -dependencies = [ - "indexmap", - "serde", -] - -[[package]] -name = "toml" -version = "0.7.3" +version = "0.7.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b403acf6f2bb0859c93c7f0d967cb4a75a7ac552100f9322faf64dc047669b21" +checksum = "c17e963a819c331dcacd7ab957d80bc2b9a9c1e71c804826d2f283dd65306542" dependencies = [ + "indexmap 2.0.0", "serde", "serde_spanned", "toml_datetime", - "toml_edit 0.19.7", + "toml_edit", ] [[package]] name = "toml_datetime" -version = "0.6.1" +version = "0.6.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3ab8ed2edee10b50132aed5f331333428b011c99402b5a534154ed15746f9622" +checksum = "7cda73e2f1397b1262d6dfdcef8aafae14d1de7748d66822d3bfeeb6d03e5e4b" dependencies = [ "serde", ] [[package]] name = "toml_edit" -version = "0.14.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5376256e44f2443f8896ac012507c19a012df0fe8758b55246ae51a2279db51f" -dependencies = [ - "combine", - "indexmap", - "itertools", -] - -[[package]] -name = "toml_edit" -version = "0.19.7" +version = "0.19.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dc18466501acd8ac6a3f615dd29a3438f8ca6bb3b19537138b3106e575621274" +checksum = "f8123f27e969974a3dfba720fdb560be359f57b44302d280ba72e76a74480e8a" dependencies = [ - "indexmap", + "indexmap 2.0.0", "serde", "serde_spanned", "toml_datetime", @@ -7172,20 +8465,20 @@ dependencies = [ [[package]] name = "tracing-attributes" -version = "0.1.23" +version = "0.1.26" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4017f8f45139870ca7e672686113917c71c7a6e02d4924eda67186083c03081a" +checksum = "5f4f31f56159e98206da9efd823404b79b6ef3143b4a7ab76e67b1751b25a4ab" dependencies = [ "proc-macro2", "quote", - "syn 1.0.109", + "syn 2.0.28", ] [[package]] name = "tracing-core" -version = "0.1.30" +version = "0.1.31" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24eb03ba0eab1fd845050058ce5e616558e8f8d8fca633e6b163fe25c797213a" +checksum = "0955b8137a1df6f1a2e9a37d8a6656291ff0297c1a97c24e0d8425fe2312f79a" dependencies = [ "once_cell", "valuable", @@ -7236,7 +8529,7 @@ dependencies = [ "serde", "serde_json", "sharded-slab", - "smallvec", + "smallvec 1.11.0", "thread_local", "tracing", "tracing-core", @@ -7246,13 +8539,13 @@ dependencies = [ [[package]] name = "tracing-subscriber" -version = "0.3.16" +version = "0.3.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a6176eae26dd70d0c919749377897b54a9276bd7061339665dd68777926b5a70" +checksum = "30a651bc37f915e81f087d86e62a18eec5f79550c7faff886f7090b4ea757c77" dependencies = [ "nu-ansi-term", "sharded-slab", - "smallvec", + "smallvec 1.11.0", "thread_local", "tracing-core", "tracing-log", @@ -7264,11 +8557,24 @@ version = "0.24.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "004e1e8f92535694b4cb1444dc5a8073ecf0815e3357f729638b9f8fc4062908" dependencies = [ - "hash-db", + "hash-db 0.15.2", "hashbrown 0.12.3", "log", "rustc-hex", - "smallvec", + "smallvec 1.11.0", +] + +[[package]] +name = "trie-db" +version = "0.27.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "767abe6ffed88a1889671a102c2861ae742726f52e0a5a425b92c9fbfa7e9c85" +dependencies = [ + "hash-db 0.16.0", + "hashbrown 0.13.2", + "log", + "rustc-hex", + "smallvec 1.11.0", ] [[package]] @@ -7277,7 +8583,26 @@ version = "0.17.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9a36c5ca3911ed3c9a5416ee6c679042064b93fc637ded67e25f92e68d783891" dependencies = [ - "hash-db", + "hash-db 0.15.2", +] + +[[package]] +name = "trie-root" +version = "0.18.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d4ed310ef5ab98f5fa467900ed906cb9232dd5376597e00fd4cba2a449d06c0b" +dependencies = [ + "hash-db 0.16.0", +] + +[[package]] +name = "triehash" +version = "0.8.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a1631b201eb031b563d2e85ca18ec8092508e262a3196ce9bd10a67ec87b9f5c" +dependencies = [ + "hash-db 0.15.2", + "rlp", ] [[package]] @@ -7294,18 +8619,18 @@ checksum = "f4f195fd851901624eee5a58c4bb2b4f06399148fcd0ed336e6f1cb60a9881df" [[package]] name = "tungstenite" -version = "0.18.0" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "30ee6ab729cd4cf0fd55218530c4522ed30b7b6081752839b68fcec8d0960788" +checksum = "15fba1a6d6bb030745759a9a2a588bfe8490fc8b4751a277db3a0be1c9ebbf67" dependencies = [ - "base64 0.13.1", "byteorder", "bytes", + "data-encoding", "http", "httparse", "log", "rand 0.8.5", - "rustls", + "rustls 0.21.5", "sha1", "thiserror", "url", @@ -7320,7 +8645,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "97fee6b57c6a41524a810daee9286c02d7752c4253064d0b05472833a438f675" dependencies = [ "cfg-if", - "digest 0.10.6", + "digest 0.10.7", "rand 0.8.5", "static_assertions", ] @@ -7331,6 +8656,12 @@ version = "1.16.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "497961ef93d974e23eb6f433eb5fe1b7930b659f06d12dec6fc44a8f554c0bba" +[[package]] +name = "ucd-trie" +version = "0.1.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ed646292ffc8188ef8ea4d1e0e0150fb15a5c2e12ad9b8fc191ae7a8a7f3c4b9" + [[package]] name = "uint" version = "0.9.5" @@ -7351,9 +8682,9 @@ checksum = "eaea85b334db583fe3274d12b4cd1880032beab409c0d774be044d4480ab9a94" [[package]] name = "uncased" -version = "0.9.7" +version = "0.9.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "09b01702b0fd0b3fadcf98e098780badda8742d4f4a7676615cad90e8ac73622" +checksum = "9b9bc53168a4be7402ab86c3aad243a84dd7381d09be0eddc81280c1da95ca68" dependencies = [ "version_check", ] @@ -7375,9 +8706,9 @@ checksum = "92888ba5573ff080736b3648696b70cafad7d250551175acbaa4e0385b3e1460" [[package]] name = "unicode-ident" -version = "1.0.8" +version = "1.0.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e5464a87b239f13a63a501f2701565754bae92d243d4bb7eb12f6d57d2269bf4" +checksum = "301abaae475aa91687eb82514b328ab47a211a533026cb25fc3e519b86adfc3c" [[package]] name = "unicode-normalization" @@ -7388,12 +8719,6 @@ dependencies = [ "tinyvec", ] -[[package]] -name = "unicode-segmentation" -version = "1.10.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1dd624098567895118886609431a7c3b8f516e41d30e0643f03d94592a147e36" - [[package]] name = "unicode-width" version = "0.1.10" @@ -7406,6 +8731,16 @@ version = "0.2.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f962df74c8c05a667b5ee8bcf162993134c104e96440b663c8daa176dc772d8c" +[[package]] +name = "universal-hash" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9f214e8f697e925001e66ec2c6e37a4ef93f0f78c2eed7814394e10c62025b05" +dependencies = [ + "generic-array 0.14.7", + "subtle", +] + [[package]] name = "untrusted" version = "0.7.1" @@ -7414,9 +8749,9 @@ checksum = "a156c684c91ea7d62626509bce3cb4e1d9ed5c4d978f7b4352658f96a4c26b4a" [[package]] name = "url" -version = "2.3.1" +version = "2.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0d68c799ae75762b8c3fe375feb6600ef5602c883c5d21eb51c09f22b83c4643" +checksum = "50bff7831e19200a85b17131d085c25d7811bc4e186efdaf54bbd132994a88cb" dependencies = [ "form_urlencoded", "idna", @@ -7429,13 +8764,19 @@ version = "0.7.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "09cc8ee72d2a9becf2f2febe0205bbed8fc6615b7cb429ad062dc7b7ddd036a9" +[[package]] +name = "utf8parse" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "711b9620af191e0cdc7468a8d14e709c3dcdb115b36f838e601583af800a370a" + [[package]] name = "uuid" version = "0.8.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "bc5cf98d8186244414c848017f0e2676b3fcb46807f6668a97dfe67359a3c4b7" dependencies = [ - "getrandom 0.2.8", + "getrandom 0.2.10", "serde", ] @@ -7460,6 +8801,12 @@ dependencies = [ "libc", ] +[[package]] +name = "waker-fn" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9d5b2c62b4012a3e1eca5a7e077d13b3bf498c4073e33ccd58626607748ceeca" + [[package]] name = "walkdir" version = "2.3.3" @@ -7472,11 +8819,10 @@ dependencies = [ [[package]] name = "want" -version = "0.3.0" +version = "0.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1ce8a968cb1cd110d136ff8b819a556d6fb6d919363c61534f6860c7eb172ba0" +checksum = "bfa7760aed19e106de2c7c0b581b509f2f25d3dacaf737cb82ac61bc6d760b0e" dependencies = [ - "log", "try-lock", ] @@ -7494,9 +8840,9 @@ checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" [[package]] name = "wasm-bindgen" -version = "0.2.84" +version = "0.2.87" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "31f8dcbc21f30d9b8f2ea926ecb58f6b91192c17e9d33594b3df58b2007ca53b" +checksum = "7706a72ab36d8cb1f80ffbf0e071533974a60d0a308d01a5d0375bf60499a342" dependencies = [ "cfg-if", "wasm-bindgen-macro", @@ -7504,24 +8850,24 @@ dependencies = [ [[package]] name = "wasm-bindgen-backend" -version = "0.2.84" +version = "0.2.87" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95ce90fd5bcc06af55a641a86428ee4229e44e07033963a2290a8e241607ccb9" +checksum = "5ef2b6d3c510e9625e5fe6f509ab07d66a760f0885d858736483c32ed7809abd" dependencies = [ "bumpalo", "log", "once_cell", "proc-macro2", "quote", - "syn 1.0.109", + "syn 2.0.28", "wasm-bindgen-shared", ] [[package]] name = "wasm-bindgen-futures" -version = "0.4.34" +version = "0.4.37" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f219e0d211ba40266969f6dbdd90636da12f75bee4fc9d6c23d1260dadb51454" +checksum = "c02dbc21516f9f1f04f187958890d7e6026df8d16540b7ad9492bc34a67cea03" dependencies = [ "cfg-if", "js-sys", @@ -7531,9 +8877,9 @@ dependencies = [ [[package]] name = "wasm-bindgen-macro" -version = "0.2.84" +version = "0.2.87" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4c21f77c0bedc37fd5dc21f897894a5ca01e7bb159884559461862ae90c0b4c5" +checksum = "dee495e55982a3bd48105a7b947fd2a9b4a8ae3010041b9e0faab3f9cd028f1d" dependencies = [ "quote", "wasm-bindgen-macro-support", @@ -7541,22 +8887,22 @@ dependencies = [ [[package]] name = "wasm-bindgen-macro-support" -version = "0.2.84" +version = "0.2.87" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2aff81306fcac3c7515ad4e177f521b5c9a15f2b08f4e32d823066102f35a5f6" +checksum = "54681b18a46765f095758388f2d0cf16eb8d4169b639ab575a8f5693af210c7b" dependencies = [ "proc-macro2", "quote", - "syn 1.0.109", + "syn 2.0.28", "wasm-bindgen-backend", "wasm-bindgen-shared", ] [[package]] name = "wasm-bindgen-shared" -version = "0.2.84" +version = "0.2.87" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0046fef7e28c3804e5e38bfa31ea2a0f73905319b677e57ebe37e49358989b5d" +checksum = "ca6ad05a4870b2bf5fe995117d3728437bd27d7cd5f06f13c17443ef369775a1" [[package]] name = "wasmi" @@ -7566,7 +8912,21 @@ checksum = "06c326c93fbf86419608361a2c925a31754cf109da1b8b55737070b4d6669422" dependencies = [ "parity-wasm", "wasmi-validation", - "wasmi_core", + "wasmi_core 0.2.1", +] + +[[package]] +name = "wasmi" +version = "0.30.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e51fb5c61993e71158abf5bb863df2674ca3ec39ed6471c64f07aeaf751d67b4" +dependencies = [ + "intx", + "smallvec 1.11.0", + "spin 0.9.8", + "wasmi_arena", + "wasmi_core 0.12.0", + "wasmparser-nostd", ] [[package]] @@ -7578,6 +8938,12 @@ dependencies = [ "parity-wasm", ] +[[package]] +name = "wasmi_arena" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "401c1f35e413fac1846d4843745589d9ec678977ab35a384db8ae7830525d468" + [[package]] name = "wasmi_core" version = "0.2.1" @@ -7585,29 +8951,70 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "57d20cb3c59b788653d99541c646c561c9dd26506f25c0cebfe810659c54c6d7" dependencies = [ "downcast-rs", - "libm", + "libm 0.2.7", "memory_units", "num-rational", "num-traits", ] +[[package]] +name = "wasmi_core" +version = "0.12.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "624e6333e861ef49095d2d678b76ebf30b06bf37effca845be7e5b87c90071b7" +dependencies = [ + "downcast-rs", + "libm 0.2.7", + "num-traits", + "paste", +] + [[package]] name = "wasmparser" version = "0.89.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ab5d3e08b13876f96dd55608d03cd4883a0545884932d5adf11925876c96daef" dependencies = [ - "indexmap", + "indexmap 1.9.3", ] [[package]] name = "wasmparser" version = "0.96.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "adde01ade41ab9a5d10ec8ed0bb954238cf8625b5cd5a13093d6de2ad9c2be1a" +checksum = "adde01ade41ab9a5d10ec8ed0bb954238cf8625b5cd5a13093d6de2ad9c2be1a" +dependencies = [ + "indexmap 1.9.3", + "url", +] + +[[package]] +name = "wasmparser" +version = "0.100.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "64b20236ab624147dfbb62cf12a19aaf66af0e41b8398838b66e997d07d269d4" +dependencies = [ + "indexmap 1.9.3", + "url", +] + +[[package]] +name = "wasmparser" +version = "0.102.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "48134de3d7598219ab9eaf6b91b15d8e50d31da76b8519fe4ecfcec2cf35104b" +dependencies = [ + "indexmap 1.9.3", + "url", +] + +[[package]] +name = "wasmparser-nostd" +version = "0.100.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9157cab83003221bfd385833ab587a039f5d6fa7304854042ba358a3b09e0724" dependencies = [ - "indexmap", - "url", + "indexmap-nostd", ] [[package]] @@ -7619,7 +9026,7 @@ dependencies = [ "anyhow", "bincode", "cfg-if", - "indexmap", + "indexmap 1.9.3", "libc", "log", "object 0.29.0", @@ -7644,7 +9051,7 @@ dependencies = [ "anyhow", "bincode", "cfg-if", - "indexmap", + "indexmap 1.9.3", "libc", "log", "object 0.29.0", @@ -7660,6 +9067,56 @@ dependencies = [ "windows-sys 0.42.0", ] +[[package]] +name = "wasmtime" +version = "6.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "76a222f5fa1e14b2cefc286f1b68494d7a965f4bf57ec04c59bb62673d639af6" +dependencies = [ + "anyhow", + "bincode", + "cfg-if", + "indexmap 1.9.3", + "libc", + "log", + "object 0.29.0", + "once_cell", + "paste", + "psm", + "serde", + "target-lexicon", + "wasmparser 0.100.0", + "wasmtime-environ 6.0.2", + "wasmtime-jit 6.0.2", + "wasmtime-runtime 6.0.2", + "windows-sys 0.42.0", +] + +[[package]] +name = "wasmtime" +version = "8.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f907fdead3153cb9bfb7a93bbd5b62629472dc06dee83605358c64c52ed3dda9" +dependencies = [ + "anyhow", + "bincode", + "cfg-if", + "indexmap 1.9.3", + "libc", + "log", + "object 0.30.4", + "once_cell", + "paste", + "psm", + "serde", + "target-lexicon", + "wasmparser 0.102.0", + "wasmtime-environ 8.0.1", + "wasmtime-jit 8.0.1", + "wasmtime-runtime 8.0.1", + "windows-sys 0.45.0", +] + [[package]] name = "wasmtime-asm-macros" version = "1.0.2" @@ -7678,6 +9135,24 @@ dependencies = [ "cfg-if", ] +[[package]] +name = "wasmtime-asm-macros" +version = "6.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4407a7246e7d2f3d8fb1cf0c72fda8dbafdb6dd34d555ae8bea0e5ae031089cc" +dependencies = [ + "cfg-if", +] + +[[package]] +name = "wasmtime-asm-macros" +version = "8.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d3b9daa7c14cd4fa3edbf69de994408d5f4b7b0959ac13fa69d465f6597f810d" +dependencies = [ + "cfg-if", +] + [[package]] name = "wasmtime-environ" version = "1.0.2" @@ -7687,7 +9162,7 @@ dependencies = [ "anyhow", "cranelift-entity 0.88.2", "gimli 0.26.2", - "indexmap", + "indexmap 1.9.3", "log", "object 0.29.0", "serde", @@ -7706,7 +9181,7 @@ dependencies = [ "anyhow", "cranelift-entity 0.92.1", "gimli 0.26.2", - "indexmap", + "indexmap 1.9.3", "log", "object 0.29.0", "serde", @@ -7716,6 +9191,44 @@ dependencies = [ "wasmtime-types 5.0.1", ] +[[package]] +name = "wasmtime-environ" +version = "6.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "47b8b50962eae38ee319f7b24900b7cf371f03eebdc17400c1dc8575fc10c9a7" +dependencies = [ + "anyhow", + "cranelift-entity 0.93.2", + "gimli 0.26.2", + "indexmap 1.9.3", + "log", + "object 0.29.0", + "serde", + "target-lexicon", + "thiserror", + "wasmparser 0.100.0", + "wasmtime-types 6.0.2", +] + +[[package]] +name = "wasmtime-environ" +version = "8.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a990198cee4197423045235bf89d3359e69bd2ea031005f4c2d901125955c949" +dependencies = [ + "anyhow", + "cranelift-entity 0.95.1", + "gimli 0.27.3", + "indexmap 1.9.3", + "log", + "object 0.30.4", + "serde", + "target-lexicon", + "thiserror", + "wasmparser 0.102.0", + "wasmtime-types 8.0.1", +] + [[package]] name = "wasmtime-jit" version = "1.0.2" @@ -7731,7 +9244,7 @@ dependencies = [ "log", "object 0.29.0", "rustc-demangle", - "rustix 0.35.13", + "rustix 0.35.14", "serde", "target-lexicon", "thiserror", @@ -7758,11 +9271,57 @@ dependencies = [ "serde", "target-lexicon", "wasmtime-environ 5.0.1", - "wasmtime-jit-icache-coherence", + "wasmtime-jit-icache-coherence 5.0.1", "wasmtime-runtime 5.0.1", "windows-sys 0.42.0", ] +[[package]] +name = "wasmtime-jit" +version = "6.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ffaed4f9a234ba5225d8e64eac7b4a5d13b994aeb37353cde2cbeb3febda9eaa" +dependencies = [ + "addr2line 0.17.0", + "anyhow", + "bincode", + "cfg-if", + "cpp_demangle", + "gimli 0.26.2", + "log", + "object 0.29.0", + "rustc-demangle", + "serde", + "target-lexicon", + "wasmtime-environ 6.0.2", + "wasmtime-jit-icache-coherence 6.0.2", + "wasmtime-runtime 6.0.2", + "windows-sys 0.42.0", +] + +[[package]] +name = "wasmtime-jit" +version = "8.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0de48df552cfca1c9b750002d3e07b45772dd033b0b206d5c0968496abf31244" +dependencies = [ + "addr2line 0.19.0", + "anyhow", + "bincode", + "cfg-if", + "cpp_demangle", + "gimli 0.27.3", + "log", + "object 0.30.4", + "rustc-demangle", + "serde", + "target-lexicon", + "wasmtime-environ 8.0.1", + "wasmtime-jit-icache-coherence 8.0.1", + "wasmtime-runtime 8.0.1", + "windows-sys 0.45.0", +] + [[package]] name = "wasmtime-jit-debug" version = "1.0.2" @@ -7781,6 +9340,24 @@ dependencies = [ "once_cell", ] +[[package]] +name = "wasmtime-jit-debug" +version = "6.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "eed41cbcbf74ce3ff6f1d07d1b707888166dc408d1a880f651268f4f7c9194b2" +dependencies = [ + "once_cell", +] + +[[package]] +name = "wasmtime-jit-debug" +version = "8.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6e0554b84c15a27d76281d06838aed94e13a77d7bf604bbbaf548aa20eb93846" +dependencies = [ + "once_cell", +] + [[package]] name = "wasmtime-jit-icache-coherence" version = "5.0.1" @@ -7792,6 +9369,28 @@ dependencies = [ "windows-sys 0.42.0", ] +[[package]] +name = "wasmtime-jit-icache-coherence" +version = "6.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "43a28ae1e648461bfdbb79db3efdaee1bca5b940872e4175390f465593a2e54c" +dependencies = [ + "cfg-if", + "libc", + "windows-sys 0.42.0", +] + +[[package]] +name = "wasmtime-jit-icache-coherence" +version = "8.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "aecae978b13f7f67efb23bd827373ace4578f2137ec110bbf6a4a7cde4121bbd" +dependencies = [ + "cfg-if", + "libc", + "windows-sys 0.45.0", +] + [[package]] name = "wasmtime-runtime" version = "1.0.2" @@ -7801,14 +9400,14 @@ dependencies = [ "anyhow", "cc", "cfg-if", - "indexmap", + "indexmap 1.9.3", "libc", "log", "mach", "memoffset 0.6.5", "paste", "rand 0.8.5", - "rustix 0.35.13", + "rustix 0.35.14", "thiserror", "wasmtime-asm-macros 1.0.2", "wasmtime-environ 1.0.2", @@ -7825,7 +9424,7 @@ dependencies = [ "anyhow", "cc", "cfg-if", - "indexmap", + "indexmap 1.9.3", "libc", "log", "mach", @@ -7833,13 +9432,61 @@ dependencies = [ "memoffset 0.6.5", "paste", "rand 0.8.5", - "rustix 0.36.11", + "rustix 0.36.15", "wasmtime-asm-macros 5.0.1", "wasmtime-environ 5.0.1", "wasmtime-jit-debug 5.0.1", "windows-sys 0.42.0", ] +[[package]] +name = "wasmtime-runtime" +version = "6.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e704b126e4252788ccfc3526d4d4511d4b23c521bf123e447ac726c14545217b" +dependencies = [ + "anyhow", + "cc", + "cfg-if", + "indexmap 1.9.3", + "libc", + "log", + "mach", + "memfd", + "memoffset 0.6.5", + "paste", + "rand 0.8.5", + "rustix 0.36.15", + "wasmtime-asm-macros 6.0.2", + "wasmtime-environ 6.0.2", + "wasmtime-jit-debug 6.0.2", + "windows-sys 0.42.0", +] + +[[package]] +name = "wasmtime-runtime" +version = "8.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "658cf6f325232b6760e202e5255d823da5e348fdea827eff0a2a22319000b441" +dependencies = [ + "anyhow", + "cc", + "cfg-if", + "indexmap 1.9.3", + "libc", + "log", + "mach", + "memfd", + "memoffset 0.8.0", + "paste", + "rand 0.8.5", + "rustix 0.36.15", + "wasmtime-asm-macros 8.0.1", + "wasmtime-environ 8.0.1", + "wasmtime-jit-debug 8.0.1", + "windows-sys 0.45.0", +] + [[package]] name = "wasmtime-types" version = "1.0.2" @@ -7864,11 +9511,35 @@ dependencies = [ "wasmparser 0.96.0", ] +[[package]] +name = "wasmtime-types" +version = "6.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "83e5572c5727c1ee7e8f28717aaa8400e4d22dcbd714ea5457d85b5005206568" +dependencies = [ + "cranelift-entity 0.93.2", + "serde", + "thiserror", + "wasmparser 0.100.0", +] + +[[package]] +name = "wasmtime-types" +version = "8.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a4f6fffd2a1011887d57f07654dd112791e872e3ff4a2e626aee8059ee17f06f" +dependencies = [ + "cranelift-entity 0.95.1", + "serde", + "thiserror", + "wasmparser 0.102.0", +] + [[package]] name = "web-sys" -version = "0.3.61" +version = "0.3.64" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e33b99f4b23ba3eec1a53ac264e35a755f00e966e0065077d6027c0f575b0b97" +checksum = "9b85cbef8c220a6abc02aefd892dfc0fc23afb1c6a426316ec33253a3877249b" dependencies = [ "js-sys", "wasm-bindgen", @@ -7893,6 +9564,25 @@ dependencies = [ "webpki", ] +[[package]] +name = "webpki-roots" +version = "0.23.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b03058f88386e5ff5310d9111d53f48b17d732b401aeb83a8d5190f2ac459338" +dependencies = [ + "rustls-webpki 0.100.1", +] + +[[package]] +name = "wide" +version = "0.7.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "aa469ffa65ef7e0ba0f164183697b89b854253fd31aeb92358b7b6155177d62f" +dependencies = [ + "bytemuck", + "safe_arch", +] + [[package]] name = "winapi" version = "0.3.9" @@ -7926,11 +9616,11 @@ checksum = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f" [[package]] name = "windows" -version = "0.46.0" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cdacb41e6a96a052c6cb63a144f24900236121c6f63f4f8219fef5977ecb0c25" +checksum = "e686886bc078bc1b0b600cac0147aadb815089b6e4da64016cbd754b6342700f" dependencies = [ - "windows-targets", + "windows-targets 0.48.1", ] [[package]] @@ -7952,12 +9642,12 @@ version = "0.42.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "5a3e1820f08b8513f676f7ab6c1f99ff312fb97b553d30ff4dd86f9f15728aa7" dependencies = [ - "windows_aarch64_gnullvm", + "windows_aarch64_gnullvm 0.42.2", "windows_aarch64_msvc 0.42.2", "windows_i686_gnu 0.42.2", "windows_i686_msvc 0.42.2", "windows_x86_64_gnu 0.42.2", - "windows_x86_64_gnullvm", + "windows_x86_64_gnullvm 0.42.2", "windows_x86_64_msvc 0.42.2", ] @@ -7967,7 +9657,16 @@ version = "0.45.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "75283be5efb2831d37ea142365f009c02ec203cd29a3ebecbc093d52315b66d0" dependencies = [ - "windows-targets", + "windows-targets 0.42.2", +] + +[[package]] +name = "windows-sys" +version = "0.48.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "677d2418bec65e3338edb076e806bc1ec15693c5d0104683f2efe857f61056a9" +dependencies = [ + "windows-targets 0.48.1", ] [[package]] @@ -7976,21 +9675,42 @@ version = "0.42.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8e5180c00cd44c9b1c88adb3693291f1cd93605ded80c250a75d472756b4d071" dependencies = [ - "windows_aarch64_gnullvm", + "windows_aarch64_gnullvm 0.42.2", "windows_aarch64_msvc 0.42.2", "windows_i686_gnu 0.42.2", "windows_i686_msvc 0.42.2", "windows_x86_64_gnu 0.42.2", - "windows_x86_64_gnullvm", + "windows_x86_64_gnullvm 0.42.2", "windows_x86_64_msvc 0.42.2", ] +[[package]] +name = "windows-targets" +version = "0.48.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "05d4b17490f70499f20b9e791dcf6a299785ce8af4d709018206dc5b4953e95f" +dependencies = [ + "windows_aarch64_gnullvm 0.48.0", + "windows_aarch64_msvc 0.48.0", + "windows_i686_gnu 0.48.0", + "windows_i686_msvc 0.48.0", + "windows_x86_64_gnu 0.48.0", + "windows_x86_64_gnullvm 0.48.0", + "windows_x86_64_msvc 0.48.0", +] + [[package]] name = "windows_aarch64_gnullvm" version = "0.42.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "597a5118570b68bc08d8d59125332c54f1ba9d9adeedeef5b99b02ba2b0698f8" +[[package]] +name = "windows_aarch64_gnullvm" +version = "0.48.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "91ae572e1b79dba883e0d315474df7305d12f569b400fcf90581b06062f7e1bc" + [[package]] name = "windows_aarch64_msvc" version = "0.36.1" @@ -8003,6 +9723,12 @@ version = "0.42.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e08e8864a60f06ef0d0ff4ba04124db8b0fb3be5776a5cd47641e942e58c4d43" +[[package]] +name = "windows_aarch64_msvc" +version = "0.48.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b2ef27e0d7bdfcfc7b868b317c1d32c641a6fe4629c171b8928c7b08d98d7cf3" + [[package]] name = "windows_i686_gnu" version = "0.36.1" @@ -8015,6 +9741,12 @@ version = "0.42.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c61d927d8da41da96a81f029489353e68739737d3beca43145c8afec9a31a84f" +[[package]] +name = "windows_i686_gnu" +version = "0.48.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "622a1962a7db830d6fd0a69683c80a18fda201879f0f447f065a3b7467daa241" + [[package]] name = "windows_i686_msvc" version = "0.36.1" @@ -8027,6 +9759,12 @@ version = "0.42.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "44d840b6ec649f480a41c8d80f9c65108b92d89345dd94027bfe06ac444d1060" +[[package]] +name = "windows_i686_msvc" +version = "0.48.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4542c6e364ce21bf45d69fdd2a8e455fa38d316158cfd43b3ac1c5b1b19f8e00" + [[package]] name = "windows_x86_64_gnu" version = "0.36.1" @@ -8039,12 +9777,24 @@ version = "0.42.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8de912b8b8feb55c064867cf047dda097f92d51efad5b491dfb98f6bbb70cb36" +[[package]] +name = "windows_x86_64_gnu" +version = "0.48.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ca2b8a661f7628cbd23440e50b05d705db3686f894fc9580820623656af974b1" + [[package]] name = "windows_x86_64_gnullvm" version = "0.42.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "26d41b46a36d453748aedef1486d5c7a85db22e56aff34643984ea85514e94a3" +[[package]] +name = "windows_x86_64_gnullvm" +version = "0.48.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7896dbc1f41e08872e9d5e8f8baa8fdd2677f29468c4e156210174edc7f7b953" + [[package]] name = "windows_x86_64_msvc" version = "0.36.1" @@ -8057,11 +9807,17 @@ version = "0.42.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9aec5da331524158c6d1a4ac0ab1541149c0b9505fde06423b02f5ef0106b9f0" +[[package]] +name = "windows_x86_64_msvc" +version = "0.48.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1a515f5799fe4961cb532f983ce2b23082366b898e52ffbce459c86f67c8378a" + [[package]] name = "winnow" -version = "0.3.6" +version = "0.5.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23d020b441f92996c80d94ae9166e8501e59c7bb56121189dc9eab3bd8216966" +checksum = "f46aab759304e4d7b2075a9aecba26228bb073ee8c50db796b2c72c676b5d807" dependencies = [ "memchr", ] @@ -8086,7 +9842,7 @@ dependencies = [ "js-sys", "log", "pharos", - "rustc_version", + "rustc_version 0.4.0", "send_wrapper 0.6.0", "thiserror", "wasm-bindgen", @@ -8109,43 +9865,48 @@ version = "0.5.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "09041cd90cf85f7f8b2df60c646f853b7f535ce68f85244eb6731cf89fa498ec" +[[package]] +name = "yansi" +version = "1.0.0-rc" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9ee746ad3851dd3bc40e4a028ab3b00b99278d929e48957bcb2d111874a7e43e" + [[package]] name = "yap" -version = "0.7.2" +version = "0.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5fc77f52dc9e9b10d55d3f4462c3b7fc393c4f17975d641542833ab2d3bc26ef" +checksum = "e2a7eb6d82a11e4d0b8e6bda8347169aff4ccd8235d039bba7c47482d977dcf7" [[package]] name = "zeroize" -version = "1.5.7" +version = "1.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c394b5bd0c6f669e7275d9c20aa90ae064cb22e75a1cad54e1b34088034b149f" +checksum = "2a0956f1ba7c7909bfb66c2e9e4124ab6f6482560f6628b5aaeba39207c9aad9" dependencies = [ "zeroize_derive", ] [[package]] name = "zeroize_derive" -version = "1.3.3" +version = "1.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "44bf07cb3e50ea2003396695d58bf46bc9887a1f362260446fad6bc4e79bd36c" +checksum = "ce36e65b0d2999d2aafac989fb249189a141aee1f53c612c1f37d72631959f69" dependencies = [ "proc-macro2", "quote", - "syn 1.0.109", - "synstructure", + "syn 2.0.28", ] [[package]] name = "zip" -version = "0.6.4" +version = "0.6.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0445d0fbc924bb93539b4316c11afb121ea39296f99a3c4c9edad09e3658cdef" +checksum = "760394e246e4c28189f19d488c058bf16f564016aefac5d32bb1f3b51d5e9261" dependencies = [ - "aes 0.7.5", + "aes 0.8.3", "byteorder", "bzip2", - "constant_time_eq", + "constant_time_eq 0.1.5", "crc32fast", "crossbeam-utils", "flate2", @@ -8177,9 +9938,9 @@ dependencies = [ [[package]] name = "zstd-sys" -version = "2.0.7+zstd.1.5.4" +version = "2.0.8+zstd.1.5.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "94509c3ba2fe55294d752b79842c530ccfab760192521df74a081a78d2b3c7f5" +checksum = "5556e6ee25d32df2586c098bbfa278803692a20d0ab9565e049480d52707ec8c" dependencies = [ "cc", "libc", diff --git a/forge/Cargo.toml b/forge/Cargo.toml index 7fff01d..64600df 100644 --- a/forge/Cargo.toml +++ b/forge/Cargo.toml @@ -5,33 +5,43 @@ edition = "2021" resolver = "2" authors = ["Polytope Labs"] - -[build-dependencies] -ethers = { git = "https://github.com/gakonst/ethers-rs", features = ["solc-full", "solc-tests"], rev = "80ac394" } -json = { version = "1.0.94", package = "serde_json" } - [dependencies] -forge = { git = "https://github.com/foundry-rs/foundry", rev = "6570a4cafef568922a856eef65853642b01e099d" } -foundry-common = { git = "https://github.com/foundry-rs/foundry", rev = "6570a4cafef568922a856eef65853642b01e099d" } -foundry-config = { git = "https://github.com/foundry-rs/foundry", rev = "6570a4cafef568922a856eef65853642b01e099d" } -foundry-evm = { git = "https://github.com/foundry-rs/foundry", rev = "6570a4cafef568922a856eef65853642b01e099d" } -ethers = { git = "https://github.com/gakonst/ethers-rs", features = ["solc-full", "solc-tests"], rev = "80ac394" } +# crates.io once_cell = "1.17.0" -hex-literal = "0.3.4" -rs_merkle = { git = "https://github.com/polytope-labs/rs-merkle", branch = "seun/2d-merkle-proofs" } +hex-literal = "0.4.1" hex = "0.4.3" -merkle-mountain-range = { package = "ckb-merkle-mountain-range", git = "https://github.com/polytope-labs/merkle-mountain-range", branch = "seun/simplified-mmr" } trie-db = "0.24.0" -patricia-merkle-trie = { git = "https://github.com/polytope-labs/patricia-merkle-trie", branch = "main" } primitive-types = "0.12.1" codec = { package = "parity-scale-codec", version = "3.2.2" } sp-core = "17.0.0" +anyhow = "1.0.72" sp-runtime = "17.0.0" sp-trie = "17.0.0" libfuzzer-sys = "0.4.6" futures = "0.3.27" -subxt = { git = "https://github.com/paritytech/subxt", rev = "d92352ad739836a4100e1ef1db607acc82ed8c5a", features = ["substrate-compat"] } -tokio = { version = "1.17.0", features = ["full"] } -beefy-prover = { git = "https://github.com/polytope-labs/beefy", branch = "seun/polkadot-v0.9.38" } -beefy-verifier-primitives = { git = "https://github.com/polytope-labs/beefy", branch = "seun/polkadot-v0.9.38" } -beefy-primitives = { package = "sp-beefy", git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.38" } +bytes = "1.4.0" +subxt = { version = "0.30.1", features = ["substrate-compat"] } +tokio = { version = "1.17.0", features = ["macros"] } +tracing = "0.1.34" +tracing-subscriber = "0.3.11" + +# rust-evm tools +forge = { git = "https://github.com/foundry-rs/foundry", rev = "25d3ce7ca1eed4a9f1776103185e4221e8fa0a11" } +foundry-common = { git = "https://github.com/foundry-rs/foundry", rev = "25d3ce7ca1eed4a9f1776103185e4221e8fa0a11" } +foundry-config = { git = "https://github.com/foundry-rs/foundry", rev = "25d3ce7ca1eed4a9f1776103185e4221e8fa0a11" } +foundry-evm = { git = "https://github.com/foundry-rs/foundry", rev = "25d3ce7ca1eed4a9f1776103185e4221e8fa0a11" } +ethers = { git = "https://github.com/gakonst/ethers-rs", features = ["ethers-solc"] } + +# polytope-labs +merkle-mountain-range-labs = { package = "ckb-merkle-mountain-range", git = "https://github.com/polytope-labs/merkle-mountain-range", branch = "seun/simplified-mmr" } +merkle-mountain-range = { package = "ckb-merkle-mountain-range", version = "0.5.2" } +rs_merkle = { git = "https://github.com/polytope-labs/rs-merkle", branch = "seun/2d-merkle-proofs" } +ismp-evm = { git = "https://github.com/polytope-labs/ismp-substrate", branch = "main" } +ismp-primitives = { git = "https://github.com/polytope-labs/ismp-substrate", branch = "main" } +ismp = { git = "https://github.com/polytope-labs/ismp-rs", branch = "main" } +beefy-prover = { git = "ssh://git@github.com/polytope-labs/beefy.git", branch = "seun/polkadot-v0.9.42" } +beefy-verifier-primitives = { git = "ssh://git@github.com/polytope-labs/beefy.git", branch = "seun/polkadot-v0.9.42" } + +## substrate +beefy-primitives = { package = "sp-consensus-beefy", git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.42" } + diff --git a/forge/src/abi.rs b/forge/src/abi.rs index 1de1bb3..eae0fb5 100644 --- a/forge/src/abi.rs +++ b/forge/src/abi.rs @@ -1,9 +1,11 @@ use beefy_primitives::mmr::BeefyNextAuthoritySet; use beefy_verifier_primitives::{ConsensusMessage, ConsensusState, MmrProof}; -use merkle_mountain_range::{leaf_index_to_mmr_size, leaf_index_to_pos, mmr_position_to_k_index}; +use merkle_mountain_range::{leaf_index_to_mmr_size, leaf_index_to_pos}; +use merkle_mountain_range_labs::mmr_position_to_k_index; use primitive_types::H256; -ethers::contract::abigen!(BeefyV1, "../out/abi/BeefyV1.abi",); +ethers::contract::abigen!(BeefyV1, "../out/BeefyV1.sol/BeefyV1.json",); +ethers::contract::abigen!(HandlerV1, "../out/HandlerV1.sol/HandlerV1.json",); impl From for BeefyConsensusProof { fn from(message: ConsensusMessage) -> Self { @@ -62,11 +64,11 @@ impl From for RelayChainProof { block_number: value.signed_commitment.commitment.block_number.into(), validator_set_id: value.signed_commitment.commitment.validator_set_id.into(), }, - signatures: value + votes: value .signed_commitment .signatures .into_iter() - .map(|a| Signature { + .map(|a| Vote { signature: a.signature.to_vec().into(), authority_index: a.index.into(), }) @@ -109,9 +111,6 @@ impl From for BeefyConsensusState { fn from(value: ConsensusState) -> Self { BeefyConsensusState { latest_height: value.latest_beefy_height.into(), - latest_timestamp: Default::default(), - frozen_height: Default::default(), - latest_heads_root: Default::default(), beefy_activation_block: Default::default(), current_authority_set: value.current_authorities.into(), next_authority_set: value.next_authorities.into(), @@ -142,8 +141,8 @@ impl From for local::IntermediateState { fn from(value: IntermediateState) -> Self { local::IntermediateState { height: local::StateMachineHeight { - state_machine_id: value.height.state_machine_id.as_u32(), - height: value.height.height.as_u32(), + state_machine_id: value.state_machine_id.as_u32(), + height: value.height.as_u32(), }, commitment: local::StateCommitment { timestamp: value.commitment.timestamp.as_u64(), diff --git a/forge/src/forge.rs b/forge/src/forge.rs index da3b90e..4bd4e09 100644 --- a/forge/src/forge.rs +++ b/forge/src/forge.rs @@ -1,7 +1,7 @@ use ethers::{ abi::{Detokenize, Tokenize}, solc::{remappings::Remapping, Project, ProjectCompileOutput, ProjectPathsConfig}, - types::U256, + types::{Log, U256}, }; use forge::{ executor::{ @@ -12,7 +12,11 @@ use forge::{ ContractRunner, MultiContractRunner, MultiContractRunnerBuilder, }; use foundry_config::{fs_permissions::PathPermission, Config, FsPermissions}; -use foundry_evm::executor::{Backend, EvmError, ExecutorBuilder}; +use foundry_evm::{ + decode::decode_console_logs, + executor::{Backend, EvmError, ExecutorBuilder}, + Address, +}; use once_cell::sync::Lazy; use std::{ fmt::Debug, @@ -21,12 +25,13 @@ use std::{ static PROJECT: Lazy = Lazy::new(|| { let mut root = PathBuf::from(env!("CARGO_MANIFEST_DIR")); - root = PathBuf::from(root.parent().unwrap().clone()); + root = PathBuf::from(root.parent().unwrap()); let mut paths = ProjectPathsConfig::builder().root(root.clone()).build().unwrap(); { // manually insert openzeppelin to remmapings. forge isn't autodetecting. root.push("lib/openzeppelin-contracts/contracts"); paths.remappings.push(Remapping { + context: None, name: "openzeppelin/".to_string(), path: root.to_str().unwrap().to_string(), }); @@ -41,6 +46,7 @@ static EVM_OPTS: Lazy = Lazy::new(|| EvmOpts { tx_origin: Config::DEFAULT_SENDER, block_number: 1, block_timestamp: 1, + code_size_limit: Some(usize::MAX), ..Default::default() }, sender: Config::DEFAULT_SENDER, @@ -50,6 +56,14 @@ static EVM_OPTS: Lazy = Lazy::new(|| EvmOpts { ..Default::default() }); +static LOL: Lazy<()> = Lazy::new(|| { + use tracing::Level; + use tracing_subscriber::FmtSubscriber; + + let subscriber = FmtSubscriber::builder().with_max_level(Level::TRACE).finish(); + tracing::subscriber::set_global_default(subscriber).expect("setting default subscriber failed"); +}); + static COMPILED: Lazy = Lazy::new(|| { let out = (*PROJECT).compile().unwrap(); if out.has_compiler_errors() { @@ -76,17 +90,15 @@ fn manifest_root() -> PathBuf { /// Builds a non-tracing runner fn runner_with_config(mut config: Config) -> MultiContractRunner { + use foundry_evm::executor::SpecId; + config.allow_paths.push(manifest_root()); base_runner() .with_cheats_config(CheatsConfig::new(&config, &EVM_OPTS)) + .evm_spec(SpecId::MERGE) .sender(config.sender) - .build( - &PROJECT.paths.root, - (*COMPILED).clone(), - EVM_OPTS.evm_env_blocking().unwrap(), - EVM_OPTS.clone(), - ) + .build(&PROJECT.paths.root, (*COMPILED).clone(), EVM_OPTS.local_evm_env(), EVM_OPTS.clone()) .unwrap() } @@ -97,7 +109,7 @@ pub fn runner() -> MultiContractRunner { runner_with_config(config) } -pub fn execute( +pub async fn execute( runner: &mut MultiContractRunner, contract_name: &'static str, fn_name: &'static str, @@ -107,17 +119,14 @@ where T: Tokenize, R: Detokenize + Debug, { - let db = Backend::spawn(runner.fork.take()); - - let names = runner.contracts.iter().map(|(id, _)| id.name.clone()).collect::>(); - - println!("names: {:?}", names); + let db = Backend::spawn(runner.fork.take()).await; - let (_, (abi, deploy_code, libs)) = runner + let (id, (abi, deploy_code, libs)) = runner .contracts .iter() .find(|(id, (abi, _, _))| id.name == contract_name && abi.functions.contains_key(fn_name)) .unwrap(); + let identifier = id.identifier(); let function = abi.functions.get(fn_name).unwrap().first().unwrap().clone(); @@ -126,11 +135,12 @@ where .with_config(runner.env.clone()) .with_spec(runner.evm_spec) .with_gas_limit(runner.evm_opts.gas_limit()) - .set_tracing(runner.evm_opts.verbosity >= 3) + .set_tracing(true) .set_coverage(runner.coverage) .build(db.clone()); let mut single_runner = ContractRunner::new( + &identifier, executor, abi, deploy_code.clone(), @@ -140,7 +150,7 @@ where libs, ); - let setup = single_runner.setup(false).unwrap(); + let setup = single_runner.setup(true); let TestSetup { address, .. } = setup; let result = single_runner.executor.execute_test::( @@ -157,3 +167,86 @@ where Ok(result.result) } + +pub async fn single_runner<'a>( + runner: &'a mut MultiContractRunner, + contract_name: &'static str, +) -> (ContractRunner<'a>, Address) { + let db = Backend::spawn(runner.fork.take()).await; + + let (id, (abi, deploy_code, libs)) = runner + .contracts + .iter() + .find(|(id, (_, _, _))| id.name == contract_name) + .unwrap(); + + dbg!(deploy_code.len()); + dbg!(2 * 0x6000); // max init codesize + + let executor = ExecutorBuilder::default() + .with_cheatcodes(runner.cheats_config.clone()) + .with_config(runner.env.clone()) + .with_spec(runner.evm_spec) + .with_gas_limit(runner.evm_opts.gas_limit()) + .set_tracing(true) + .set_coverage(runner.coverage) + .build(db.clone()); + + let mut single_runner = ContractRunner::new( + &id.name, + executor, + abi, + deploy_code.clone(), + runner.evm_opts.initial_balance, + runner.sender, + runner.errors.as_ref(), + libs, + ); + + let setup = single_runner.setup(true); + let TestSetup { address, reason, .. } = setup; + dbg!(reason); + + (single_runner, address) +} + +/// Execute using the single [`ContractRunner`] +pub fn execute_single( + contract: &mut ContractRunner, + address: Address, + func: &str, + args: T, +) -> Result +where + T: Tokenize, + R: Detokenize + Debug, +{ + let function = contract.contract.functions.get(func).unwrap().first().unwrap().clone(); + + let result = contract.executor.execute_test::( + contract.sender, + address, + function, + args, + 0.into(), + contract.errors, + ); + + match &result { + Ok(call) => print_logs(func, call.gas_used, &call.logs), + Err(EvmError::Execution(execution)) => + print_logs(func, execution.gas_used, &execution.logs), + _ => {}, + }; + + Ok(result?.result) +} + +fn print_logs(func: &str, gas_used: u64, logs: &Vec) { + println!("Gas used {func}: {:#?}", gas_used); + println!("=========== Start Logs {func} ==========="); + for log in decode_console_logs(logs) { + println!("{}", log); + } + println!("=========== End Logs {func} ==========="); +} diff --git a/forge/src/lib.rs b/forge/src/lib.rs index 1171618..a1ba194 100644 --- a/forge/src/lib.rs +++ b/forge/src/lib.rs @@ -1,16 +1,17 @@ #![allow(unused_parens)] pub mod abi; -mod beefy; mod forge; +mod tests; pub use crate::forge::{execute, runner}; pub use ethers::{abi::Token, types::U256, utils::keccak256}; -use merkle_mountain_range::{Error, Merge}; +use ismp_primitives::mmr::{DataOrHash, MmrHasher}; +use merkle_mountain_range::{util::MemMMR, Error, Merge}; use rs_merkle::Hasher; #[derive(Clone)] -struct Keccak256; +pub struct Keccak256; impl Hasher for Keccak256 { type Hash = [u8; 32]; @@ -20,6 +21,15 @@ impl Hasher for Keccak256 { } } +impl ismp::util::Keccak256 for Keccak256 { + fn keccak256(bytes: &[u8]) -> H256 + where + Self: Sized, + { + keccak256(bytes).into() + } +} + struct MergeKeccak; impl Merge for MergeKeccak { @@ -42,3 +52,14 @@ impl From for NumberHash { NumberHash(hash.to_vec()) } } + +pub fn unwrap_hash(item: &DataOrHash) -> [u8; 32] { + match item { + DataOrHash::Hash(h) => (*h).into(), + _ => panic!("not a hash"), + } +} + +use primitive_types::H256; + +pub type Mmr = MemMMR>; diff --git a/forge/src/tests.rs b/forge/src/tests.rs new file mode 100644 index 0000000..b5654df --- /dev/null +++ b/forge/src/tests.rs @@ -0,0 +1,7 @@ +#[cfg(feature = "beefy")] +mod beefy_v1; +mod get_response; +mod get_timeout; +mod post_request; +mod post_response; +mod post_timeout; diff --git a/forge/src/beefy.rs b/forge/src/tests/beefy_v1.rs similarity index 84% rename from forge/src/beefy.rs rename to forge/src/tests/beefy_v1.rs index c08a153..d90a0b6 100644 --- a/forge/src/beefy.rs +++ b/forge/src/tests/beefy_v1.rs @@ -1,9 +1,11 @@ -use crate::{abi, execute, runner}; +#![cfg(test)] + +use crate::{abi, abi::local, execute, runner}; use beefy_primitives::{crypto::Signature, mmr::MmrLeaf, Commitment, VersionedFinalityProof}; use beefy_prover::Prover; use beefy_verifier_primitives::ConsensusState; use codec::{Decode, Encode}; -use ethers::abi::{Token, Tokenizable, Uint}; +use ethers::abi::{AbiDecode, AbiEncode, Token, Uint}; use futures::stream::StreamExt; use hex_literal::hex; use primitive_types::H256; @@ -20,9 +22,9 @@ use subxt::{ utils::{AccountId32, MultiAddress, MultiSignature}, PolkadotConfig, }; -use crate::abi::local; -type Hyperbridge = WithExtrinsicParams>; +type Hyperbridge = + WithExtrinsicParams>; pub struct HyperbridgeConfig {} @@ -37,21 +39,19 @@ impl Hasher for Keccak256 { } impl subxt::Config for HyperbridgeConfig { - type Index = u32; - type BlockNumber = u32; type Hash = H256; type AccountId = AccountId32; type Address = MultiAddress; type Signature = MultiSignature; type Hasher = Keccak256; - type Header = SubstrateHeader; + type Header = SubstrateHeader; type ExtrinsicParams = SubstrateExtrinsicParams; } -#[tokio::test] +#[tokio::test(flavor = "multi_thread")] +#[ignore] async fn beefy_consensus_client_test() { let mut runner = runner(); - let relay_ws_url = format!( "ws://{}:9944", std::env::var("RELAY_HOST").unwrap_or_else(|_| "127.0.0.1".to_string()) @@ -73,7 +73,7 @@ async fn beefy_consensus_client_test() { .skip_while(|result| { futures::future::ready({ match result { - Ok(block) => block.number() < 125, + Ok(block) => block.number() < 10, Err(_) => false, } }) @@ -87,7 +87,6 @@ async fn beefy_consensus_client_test() { let para = subxt::client::OnlineClient::::from_url(para_ws_url).await.unwrap(); let prover = Prover { relay, para, para_ids: vec![2000] }; let initial_state = prover.get_initial_consensus_state().await.unwrap(); - dbg!(&initial_state); let mut consensus_state: abi::BeefyConsensusState = initial_state.into(); let subscription: Subscription = prover .relay @@ -123,30 +122,40 @@ async fn beefy_consensus_client_test() { let consensus_proof: abi::BeefyConsensusProof = prover.consensus_proof(signed_commitment).await.unwrap().into(); - let update = - execute::<_, (abi::BeefyConsensusState, Vec)>( - &mut runner, - "BeefyConsensusClientTest", - "VerifyV1", - (consensus_state.clone().into_token(), consensus_proof.into_token()), - ) - .unwrap(); + if consensus_proof.relay.signed_commitment.commitment.block_number == + consensus_state.latest_height + { + continue + } - consensus_state = update.0.clone(); + dbg!(&consensus_proof.relay.signed_commitment.commitment); + + let (new_state, intermediates) = execute::<_, (bytes::Bytes, Vec)>( + &mut runner, + "BeefyConsensusClientTest", + "VerifyV1", + ( + Token::Bytes(consensus_state.clone().encode()), + Token::Bytes(consensus_proof.encode()), + ), + ) + .await + .unwrap(); + + consensus_state = abi::BeefyConsensusState::decode(new_state).unwrap(); { - let debug_consensus_state: ConsensusState = update.0.into(); + let debug_consensus_state: ConsensusState = consensus_state.clone().into(); dbg!(&debug_consensus_state); let intermediate: Vec = - update.1.into_iter().map(Into::into).collect(); + intermediates.into_iter().map(Into::into).collect(); dbg!(&intermediate); } - } } -#[test] -fn test_decode_encode() { +#[tokio::test(flavor = "multi_thread")] +async fn test_decode_encode() { let mmr_leaf = hex!("003f1e0000ccaf442e2648d278e87dbca890e532ef9cb7cf2058d023903b49567e2943996f550000000000000006000000a9d36172252f275bc8b7851062dff4a29e018355d8626c941f2ad57dfbabecd008ca13222c83d2a481d7b63c356d95bf9366b2a70e907ca3e38fa52e35731537").to_vec(); let header = hex!("9a28ac82dd089df2f5215ec55ae8b4933f9d58c8c76bf0c0ca1884f3778af2b7a53ba87a649f925c5093914299f42c78ad997b5f69a2ca5dc9ad3357cd0aeb6fd409566fe009ee37e1bbdc43af58c0be65d195bc3f0a5c98568bb12b709ef0d4f3be0806617572612038b856080000000005617572610101ecb27e1850a572d08ff0f4e94a1a557b0ddd7b12158627e442789802aada1553e65d72ecc3a6c0efb9794fb6c2ebf5878da36d6e5b8295cc0f42810beb64c68a").to_vec(); let commitment = hex!("046d688088bc15df49c90d1823ac81aa90236815062561ccc4352983576013413e17c25a401e00005400000000000000").to_vec(); @@ -166,6 +175,7 @@ fn test_decode_encode() { "DecodeHeader", (Token::Bytes(header.encode())), ) + .await .unwrap(); assert_eq!(&parent_hash, header.parent_hash.as_fixed_bytes()); @@ -190,6 +200,7 @@ fn test_decode_encode() { "EncodeCommitment", (abi,), ) + .await .unwrap(); assert_eq!(encoded, commitment.encode()); @@ -211,6 +222,7 @@ fn test_decode_encode() { let encoded = execute::<_, Vec>(&mut runner, "BeefyConsensusClientTest", "EncodeLeaf", (abi,)) + .await .unwrap(); assert_eq!(encoded, mmr_leaf.encode()); diff --git a/forge/src/tests/get_response.rs b/forge/src/tests/get_response.rs new file mode 100644 index 0000000..1ca2827 --- /dev/null +++ b/forge/src/tests/get_response.rs @@ -0,0 +1,165 @@ +#![cfg(test)] + +use crate::{ + abi, + forge::{execute_single, single_runner}, + runner, Keccak256, +}; +use ethers::{ + abi::{AbiEncode, Token, Tokenizable}, + core::types::U256, +}; +use foundry_evm::Address; +use ismp::{ + host::{Ethereum, StateMachine}, + router::{Get, Request}, + util::hash_request, +}; +use primitive_types::H256; +use sp_core::KeccakHasher; +use sp_trie::{LayoutV0, MemoryDB}; +use std::collections::HashSet; +use trie_db::{Recorder, Trie, TrieDBBuilder, TrieDBMutBuilder, TrieMut}; + +fn generate_proof(request: H256, key: Vec) -> (H256, Vec>) { + let storage_prefix = b":child_storage:default:".to_vec(); + + // Populate DB with full trie from entries. + let (child_db, child_root) = { + let mut db = >::default(); + let mut root = Default::default(); + let mut trie = TrieDBMutBuilder::>::new(&mut db, &mut root).build(); + trie.insert(&key, H256::random().as_bytes()).unwrap(); + drop(trie); + + (db, root) + }; + + let child_proof = { + let mut recorder = Recorder::>::new(); + let trie_db = TrieDBBuilder::>::new(&child_db, &child_root) + .with_recorder(&mut recorder) + .build(); + + // try to get the keys we need from the trie + let _ = trie_db.get(key.as_ref()).unwrap(); + + let proof = recorder.drain().into_iter().map(|f| f.data).collect::>(); + + proof.into_iter().collect::>() + }; + + let key = [storage_prefix.clone(), request.as_bytes().to_vec()].concat(); + + let entries = (0..10) + .into_iter() + .map(|_| { + let key = [storage_prefix.clone(), H256::random().as_bytes().to_vec()].concat(); + + (key, H256::random().as_bytes().to_vec()) + }) + .collect::>(); + + // Populate DB with full trie from entries. + let (db, root) = { + let mut db = >::default(); + let mut root = Default::default(); + { + let mut trie = + TrieDBMutBuilder::>::new(&mut db, &mut root).build(); + for (key, value) in &entries { + trie.insert(key, &value).unwrap(); + } + trie.insert(key.as_ref(), child_root.as_ref()).unwrap(); + } + + (db, root) + }; + + // Generate proof for the given keys.. + let proof = { + let mut recorder = Recorder::>::new(); + let trie_db = TrieDBBuilder::>::new(&db, &root) + .with_recorder(&mut recorder) + .build(); + + // try to get the keys we need from the trie + let _ = trie_db.get(key.as_ref()).unwrap(); + + let proof = recorder.drain().into_iter().map(|f| f.data).collect::>(); + + proof.into_iter().collect::>() + }; + + let proof = [child_proof, proof].concat(); + + (root, proof) +} + +#[tokio::test(flavor = "multi_thread")] +async fn test_post_request_proof() { + let mut runner = runner(); + let (mut contract, address) = single_runner(&mut runner, "GetResponseTest").await; + let destination = + execute_single::(&mut contract, address.clone(), "module", ()).unwrap(); + + let key = H256::random().as_bytes().to_vec(); + + // create post request object + let get = Get { + dest: StateMachine::Polkadot(2000), + source: StateMachine::Ethereum(Ethereum::ExecutionLayer), + nonce: 0, + from: destination.as_bytes().to_vec(), + keys: vec![key.clone()], + timeout_timestamp: 50, + gas_limit: 0, + height: 0, + }; + + let request = Request::Get(get.clone()); + let request_commitment = hash_request::(&request); + let (root, proof) = generate_proof(request_commitment, key.clone()); + + // create intermediate state + let height = + abi::StateMachineHeight { state_machine_id: U256::from(2000), height: U256::from(1) }; + let consensus_proof = abi::IntermediateState { + state_machine_id: height.state_machine_id, + height: height.height, + commitment: abi::StateCommitment { + timestamp: U256::from(20000), + overlay_root: [0u8; 32], + state_root: root.0, + }, + } + .encode(); + + let mut sol_get = abi::GetRequest { + source: get.source.to_string().as_bytes().to_vec().into(), + dest: get.dest.to_string().as_bytes().to_vec().into(), + nonce: get.nonce, + keys: get.keys.into_iter().map(Into::into).collect(), + from: get.from.into(), + timeout_timestamp: get.timeout_timestamp, + gaslimit: get.gas_limit, + height: get.height, + }; + + let message = abi::GetResponseMessage { + proof: proof.into_iter().map(Into::into).collect(), + height, + requests: vec![sol_get.clone()], + }; + + sol_get.timeout_timestamp -= 1; + + // execute the test + execute_single::<(), _>( + &mut contract, + address.clone(), + "GetResponseNoChallengeNoTimeout", + (Token::Bytes(consensus_proof), sol_get.into_token(), message.into_token()), + ) + .unwrap(); +} diff --git a/forge/src/tests/get_timeout.rs b/forge/src/tests/get_timeout.rs new file mode 100644 index 0000000..67005ab --- /dev/null +++ b/forge/src/tests/get_timeout.rs @@ -0,0 +1 @@ +#![cfg(test)] diff --git a/forge/src/tests/post_request.rs b/forge/src/tests/post_request.rs new file mode 100644 index 0000000..8bfd788 --- /dev/null +++ b/forge/src/tests/post_request.rs @@ -0,0 +1,102 @@ +#![cfg(test)] + +use crate::{ + abi, + forge::{execute_single, single_runner}, + runner, unwrap_hash, Mmr, +}; +use ethers::{ + abi::{AbiEncode, Token, Tokenizable}, + core::types::U256, +}; +use foundry_evm::Address; +use ismp::{ + host::{Ethereum, StateMachine}, + router::{Post, Request}, +}; +use ismp_primitives::mmr::{DataOrHash, Leaf}; +use merkle_mountain_range_labs::mmr_position_to_k_index; +use primitive_types::H256; + +#[tokio::test(flavor = "multi_thread")] +async fn test_post_request_proof() { + let mut runner = runner(); + let (mut contract, address) = single_runner(&mut runner, "PostRequestTest").await; + let destination = + execute_single::(&mut contract, address.clone(), "module", ()).unwrap(); + + // create post request object + let post = Post { + source: StateMachine::Polkadot(2000), + dest: StateMachine::Ethereum(Ethereum::ExecutionLayer), + nonce: 0, + from: contract.sender.as_bytes().to_vec(), + to: destination.as_bytes().to_vec(), + timeout_timestamp: 50, + data: vec![], + gas_limit: 0, + }; + let request = DataOrHash::Data(Leaf::Request(Request::Post(post.clone()))); + + // create the mmr tree and insert it + let mut mmr = Mmr::default(); + + for _ in 0..30 { + let hash = H256::random(); + mmr.push(DataOrHash::Hash(hash)).unwrap(); + } + + let pos = mmr.push(request.clone()).unwrap(); + + for _ in 0..30 { + let hash = H256::random(); + mmr.push(DataOrHash::Hash(hash)).unwrap(); + } + + let k_index = mmr_position_to_k_index(vec![pos], mmr.mmr_size())[0].1; + + let proof = mmr.gen_proof(vec![pos]).unwrap(); + let overlay_root = unwrap_hash(&mmr.get_root().unwrap()); + let multiproof = proof.proof_items().iter().map(unwrap_hash).collect(); + + // create intermediate state + let height = + abi::StateMachineHeight { state_machine_id: U256::from(2000), height: U256::from(1) }; + let consensus_proof = abi::IntermediateState { + state_machine_id: height.state_machine_id, + height: height.height, + commitment: abi::StateCommitment { + timestamp: U256::from(20000), + overlay_root, + state_root: [0u8; 32], + }, + } + .encode(); + + let message = abi::PostRequestMessage { + proof: abi::Proof { height, multiproof, mmr_size: proof.mmr_size().into() }, + requests: vec![abi::PostRequestLeaf { + request: abi::PostRequest { + source: post.source.to_string().as_bytes().to_vec().into(), + dest: post.dest.to_string().as_bytes().to_vec().into(), + nonce: post.nonce, + from: post.from.into(), + to: post.to.into(), + timeout_timestamp: post.timeout_timestamp, + body: post.data.into(), + gaslimit: post.gas_limit, + }, + mmr_index: pos.into(), + k_index: k_index.into(), + }], + }; + + // execute the test + execute_single::<(), _>( + &mut contract, + address.clone(), + "PostRequestNoChallengeNoTimeout", + (Token::Bytes(consensus_proof), message.into_token()), + ) + .unwrap(); +} diff --git a/forge/src/tests/post_response.rs b/forge/src/tests/post_response.rs new file mode 100644 index 0000000..a0ccc4e --- /dev/null +++ b/forge/src/tests/post_response.rs @@ -0,0 +1,106 @@ +#![cfg(test)] + +use crate::{ + abi, + forge::{execute_single, single_runner}, + runner, unwrap_hash, Mmr, +}; +use ethers::{ + abi::{AbiEncode, Token, Tokenizable}, + core::types::U256, +}; +use foundry_evm::Address; +use ismp::{ + host::{Ethereum, StateMachine}, + router::{Post, PostResponse, Response}, +}; +use ismp_primitives::mmr::{DataOrHash, Leaf}; +use merkle_mountain_range_labs::mmr_position_to_k_index; +use primitive_types::H256; + +#[tokio::test(flavor = "multi_thread")] +async fn test_post_response_proof() { + let mut runner = runner(); + let (mut contract, address) = single_runner(&mut runner, "PostResponseTest").await; + let module = + execute_single::(&mut contract, address.clone(), "module", ()).unwrap(); + + // create post request object + let post = Post { + source: StateMachine::Ethereum(Ethereum::ExecutionLayer), + dest: StateMachine::Polkadot(2000), + nonce: 0, + from: module.as_bytes().to_vec(), + to: module.as_bytes().to_vec(), + timeout_timestamp: 50, + data: vec![2u8; 32], + gas_limit: 100, + }; + + let post_response = PostResponse { post: post.clone(), response: vec![1u8; 64] }; + + let response = DataOrHash::Data(Leaf::Response(Response::Post(post_response.clone()))); + + // create the mmr tree and insert it + let mut mmr = Mmr::default(); + + for _ in 0..30 { + let hash = H256::random(); + mmr.push(DataOrHash::Hash(hash)).unwrap(); + } + + let pos = mmr.push(response).unwrap(); + let k_index = mmr_position_to_k_index(vec![pos], mmr.mmr_size())[0].1; + + let proof = mmr.gen_proof(vec![pos]).unwrap(); + let overlay_root = unwrap_hash(&mmr.get_root().unwrap()); + let multiproof = proof.proof_items().iter().map(unwrap_hash).collect(); + + // create intermediate state + let height = + abi::StateMachineHeight { state_machine_id: U256::from(2000), height: U256::from(1) }; + let consensus_proof = abi::IntermediateState { + state_machine_id: height.state_machine_id, + height: height.height, + commitment: abi::StateCommitment { + timestamp: U256::from(20000), + overlay_root, + state_root: [0u8; 32], + }, + } + .encode(); + + let mut sol_post = abi::PostRequest { + source: post.source.to_string().as_bytes().to_vec().into(), + dest: post.dest.to_string().as_bytes().to_vec().into(), + nonce: post.nonce, + from: post.from.into(), + to: post.to.into(), + timeout_timestamp: post.timeout_timestamp, + body: post.data.into(), + gaslimit: post.gas_limit, + }; + + let message = abi::PostResponseMessage { + proof: abi::Proof { height, multiproof, mmr_size: proof.mmr_size().into() }, + responses: vec![abi::PostResponseLeaf { + response: abi::PostResponse { + request: sol_post.clone(), + response: post_response.response.into(), + }, + mmr_index: pos.into(), + k_index: k_index.into(), + }], + }; + + sol_post.timeout_timestamp -= 1; + + // execute the test + execute_single::<(), _>( + &mut contract, + address.clone(), + "PostResponseNoChallengeNoTimeout", + (Token::Bytes(consensus_proof), sol_post.into_token(), message.into_token()), + ) + .unwrap(); +} diff --git a/forge/src/tests/post_timeout.rs b/forge/src/tests/post_timeout.rs new file mode 100644 index 0000000..77af031 --- /dev/null +++ b/forge/src/tests/post_timeout.rs @@ -0,0 +1,167 @@ +#![cfg(test)] + +use crate::{ + abi, + forge::{execute_single, single_runner}, + runner, Keccak256, +}; +use ethers::{ + abi::{AbiEncode, Token, Tokenizable}, + core::types::U256, +}; +use foundry_evm::Address; +use hex_literal::hex; +use ismp::{ + host::{Ethereum, StateMachine}, + router::{Post, Request}, + util::hash_request, +}; +use primitive_types::H256; +use sp_core::KeccakHasher; +use sp_trie::{HashDBT, LayoutV0, MemoryDB, StorageProof, TrieDBBuilder, EMPTY_PREFIX}; +use std::collections::{BTreeMap, HashSet}; +use trie_db::{Recorder, Trie, TrieDBMutBuilder, TrieMut}; + +#[tokio::test(flavor = "multi_thread")] +async fn test_post_timeout_proof() { + let mut runner = runner(); + let (mut contract, address) = single_runner(&mut runner, "PostTimeoutTest").await; + let module = + execute_single::(&mut contract, address.clone(), "module", ()).unwrap(); + + let storage_prefix = + hex!("103895530afb23bb607661426d55eb8b0484aecefe882c3ce64e6f82507f715a").to_vec(); + + // create post request object + let post = Post { + source: StateMachine::Ethereum(Ethereum::ExecutionLayer), + dest: StateMachine::Polkadot(2000), + nonce: 0, + from: module.as_bytes().to_vec(), + to: module.as_bytes().to_vec(), + timeout_timestamp: 10000, + data: vec![], + gas_limit: 0, + }; + let mut key = storage_prefix.clone(); + key.extend_from_slice(hash_request::(&Request::Post(post.clone())).as_ref()); + + let entries = (1..50) + .into_iter() + .map(|_| { + let mut key = storage_prefix.clone(); + key.extend_from_slice(&H256::random().0.to_vec()); + (key, H256::random().0.to_vec()) + }) + .collect::>(); + + let (root, proof) = generate_proof(entries.clone(), vec![key.clone()]); + + let storage_proof = StorageProof::new(proof.clone().into_iter()); + let result = read_proof_check(&root, storage_proof, vec![key.as_slice()]).unwrap(); + + // The value should be None since it's a None membership proof + assert!(result.get(&key).unwrap().is_none()); + + // create intermediate state + let height = + abi::StateMachineHeight { state_machine_id: U256::from(2000), height: U256::from(1) }; + let consensus_proof = abi::IntermediateState { + state_machine_id: height.state_machine_id, + height: height.height, + commitment: abi::StateCommitment { + timestamp: U256::from(20000), + overlay_root: [0u8; 32], + state_root: root.0, + }, + } + .encode(); + + let mut sol_post = abi::PostRequest { + source: post.source.to_string().as_bytes().to_vec().into(), + dest: post.dest.to_string().as_bytes().to_vec().into(), + nonce: post.nonce, + from: post.from.into(), + to: post.to.into(), + timeout_timestamp: post.timeout_timestamp, + body: post.data.into(), + gaslimit: post.gas_limit, + }; + + let message = abi::PostTimeoutMessage { + proof: proof.into_iter().map(|node| node.into()).collect(), + timeouts: vec![sol_post.clone()], + height, + }; + sol_post.timeout_timestamp -= 1; + + // execute the test + execute_single::<(), _>( + &mut contract, + address.clone(), + "PostTimeoutNoChallenge", + (Token::Bytes(consensus_proof), sol_post.into_token(), message.into_token()), + ) + .unwrap(); +} + +fn generate_proof(entries: Vec<(Vec, Vec)>, keys: Vec>) -> (H256, Vec>) { + // Populate DB with full trie from entries. + let (db, root) = { + let mut db = >::default(); + let mut root = Default::default(); + { + let mut trie = + TrieDBMutBuilder::>::new(&mut db, &mut root).build(); + for (key, value) in &entries { + trie.insert(key, &value).unwrap(); + } + } + (db, root) + }; + + // Generate proof for the given keys.. + let proof = { + let mut recorder = Recorder::>::new(); + let trie_db = TrieDBBuilder::>::new(&db, &root) + .with_recorder(&mut recorder) + .build(); + + // try to get the keys we need from the trie + for key in &keys { + let _ = trie_db.get(key).unwrap(); + } + + let proof = recorder.drain().into_iter().map(|f| f.data).collect::>(); + + proof.into_iter().collect::>() + }; + + (root, proof) +} + +pub fn read_proof_check( + root: &H256, + proof: StorageProof, + keys: I, +) -> Result, Option>>, ()> +where + I: IntoIterator, + I::Item: AsRef<[u8]>, +{ + let db = proof.into_memory_db::(); + + if !db.contains(root, EMPTY_PREFIX) { + Err(())? + } + + let trie = TrieDBBuilder::>::new(&db, root).build(); + let mut result = BTreeMap::new(); + + for key in keys.into_iter() { + let value = trie.get(key.as_ref()).map_err(|_| ())?; + result.insert(key.as_ref().to_vec(), value); + } + + Ok(result) +} diff --git a/lib/solidity-merkle-trees b/lib/solidity-merkle-trees index a58b187..9b39e30 160000 --- a/lib/solidity-merkle-trees +++ b/lib/solidity-merkle-trees @@ -1 +1 @@ -Subproject commit a58b187792efc10d3640f0473a115ff454e4bc24 +Subproject commit 9b39e304bc56e732468121bc6641ce193e685431 diff --git a/src/ISMP.sol b/src/EvmHost.sol similarity index 63% rename from src/ISMP.sol rename to src/EvmHost.sol index a1938fd..77d5612 100644 --- a/src/ISMP.sol +++ b/src/EvmHost.sol @@ -1,29 +1,48 @@ // SPDX-License-Identifier: UNLICENSED -pragma solidity ^0.8.17; +pragma solidity 0.8.17; import "solidity-merkle-trees/MerkleMountainRange.sol"; import "openzeppelin/utils/introspection/IERC165.sol"; import "openzeppelin/utils/Context.sol"; import "openzeppelin/utils/math/Math.sol"; -import "./consensus/Schema.sol"; -import "./consensus/Beefy.sol"; -import "./interfaces/IISMPModule.sol"; +import "./interfaces/IIsmpModule.sol"; import "./interfaces/IIsmpHost.sol"; import "./interfaces/IHandler.sol"; -/// ISMP core protocol -abstract contract IsmpHost is IIsmpHost, Context { +struct HostParams { + // default timeout in seconds for requests. + uint256 defaultTimeout; + // timestamp for when the consensus was most recently updated + uint256 lastUpdated; + // unstaking period + uint256 unStakingPeriod; + // minimum challenge period in seconds; + uint256 challengePeriod; + // consensus client contract + address consensusClient; + // admin account, this only has the rights to freeze, or unfreeze the bridge + address admin; + // Ismp request/response handler + address handler; + // the authorized cross-chain governor contract + address crosschainGovernor; + // current verified state of the consensus client; + bytes consensusState; +} + +/// Ismp implementation for Evm hosts +abstract contract EvmHost is IIsmpHost, Context { // commitment of all outgoing requests mapping(bytes32 => bool) private _requestCommitments; + // commitment of all outgoing responses + mapping(bytes32 => bool) private _responseCommitments; + // commitment of all incoming requests mapping(bytes32 => bool) private _requestReceipts; // commitment of all incoming responses - mapping(bytes32 => bool) private _responseCommitments; - - // commitment of all outgoing responses mapping(bytes32 => bool) private _responseReceipts; // (stateMachineId => (blockHeight => StateCommitment)) @@ -32,33 +51,15 @@ abstract contract IsmpHost is IIsmpHost, Context { // (stateMachineId => (blockHeight => timestamp)) mapping(uint256 => mapping(uint256 => uint256)) private _stateCommitmentsUpdateTime; - // minimum challenge period in seconds; - uint256 private _CHALLENGE_PERIOD = 12000; - - // todo: Default timeout in seconds for requests. - uint256 private _DEFAULT_TIMEOUT = 12000; - - // consensus client address and metadata, - Consensus private _consensus; + // Parameters for the host + HostParams private _hostParams; // monotonically increasing nonce for outgoing requests uint256 private _nonce; - // admin account, this only has the rights to freeze, or unfreeze the bridge - address private _admin; - - // emergency shutdown button + // emergency shutdown button, only the admin can do this bool private _frozen; - // unstaking period - uint256 private _unStakingPeriod; - - // host handler - IHandler private _handler; - - // governance contracts - address public governance; - event PostResponseEvent( bytes source, bytes dest, @@ -77,28 +78,30 @@ abstract contract IsmpHost is IIsmpHost, Context { event GetRequestEvent(bytes source, bytes dest, bytes from, uint256 indexed nonce, uint256 timeoutTimestamp); + modifier onlyAdmin() { + require(_msgSender() == _hostParams.admin, "EvmHost: Only admin"); + _; + } + modifier onlyHandler() { - require(_msgSender() == address(_handler), "ISMP_HOST: Only handler can call"); + require(_msgSender() == address(_hostParams.handler), "EvmHost: Only handler"); _; } modifier onlyGovernance() { - require(_msgSender() == governance, "ISMP_HOST: Only governance contract can call"); + require(_msgSender() == _hostParams.crosschainGovernor, "EvmHost: Only governor contract"); _; } - constructor(address adminAccount, IHandler handler, Consensus memory initial, address _governance) { - _admin = adminAccount; - _consensus = initial; - _handler = handler; - governance = _governance; + constructor(HostParams memory params) { + _hostParams = params; } /** * @return the host admin */ - function admin() external returns (address) { - return _admin; + function admin() external view returns (address) { + return _hostParams.admin; } /** @@ -109,7 +112,7 @@ abstract contract IsmpHost is IIsmpHost, Context { /** * @return the host timestamp */ - function hostTimestamp() public view returns (uint256) { + function timestamp() public view returns (uint256) { return block.timestamp; } @@ -124,7 +127,7 @@ abstract contract IsmpHost is IIsmpHost, Context { * @param height - state machine height * @return the state commitment at `height` */ - function stateMachineCommitment(StateMachineHeight memory height) external returns (StateCommitment memory) { + function stateMachineCommitment(StateMachineHeight memory height) external view returns (StateCommitment memory) { return _stateCommitments[height.stateMachineId][height.height]; } @@ -132,7 +135,7 @@ abstract contract IsmpHost is IIsmpHost, Context { * @param height - state machine height * @return the state machine update time at `height` */ - function stateMachineUpdateTime(StateMachineHeight memory height) external returns (uint256) { + function stateMachineCommitmentUpdateTime(StateMachineHeight memory height) external view returns (uint256) { return _stateCommitmentsUpdateTime[height.stateMachineId][height.height]; } @@ -140,29 +143,29 @@ abstract contract IsmpHost is IIsmpHost, Context { * @dev Should return a handle to the consensus client based on the id * @return the consensus client contract */ - function consensusClient() external returns (address) { - return _consensus.client; + function consensusClient() external view returns (address) { + return _hostParams.consensusClient; } /** * @return the last updated time of the consensus client */ - function consensusUpdateTime() external returns (uint256) { - return _consensus.lastUpdated; + function consensusUpdateTime() external view returns (uint256) { + return _hostParams.lastUpdated; } /** * @return the state of the consensus client */ - function consensusState() external returns (bytes memory) { - return _consensus.state; + function consensusState() external view returns (bytes memory) { + return _hostParams.consensusState; } /** * @param commitment - commitment to the request * @return existence status of an incoming request commitment */ - function requestReceipts(bytes32 commitment) external returns (bool) { + function requestReceipts(bytes32 commitment) external view returns (bool) { return _requestReceipts[commitment]; } @@ -170,7 +173,7 @@ abstract contract IsmpHost is IIsmpHost, Context { * @param commitment - commitment to the response * @return existence status of an incoming response commitment */ - function responseReceipts(bytes32 commitment) external returns (bool) { + function responseReceipts(bytes32 commitment) external view returns (bool) { return _responseReceipts[commitment]; } @@ -178,7 +181,7 @@ abstract contract IsmpHost is IIsmpHost, Context { * @param commitment - commitment to the request * @return existence status of an outgoing request commitment */ - function requestCommitments(bytes32 commitment) external returns (bool) { + function requestCommitments(bytes32 commitment) external view returns (bool) { return _requestCommitments[commitment]; } @@ -186,15 +189,15 @@ abstract contract IsmpHost is IIsmpHost, Context { * @param commitment - commitment to the response * @return existence status of an outgoing response commitment */ - function responseCommitments(bytes32 commitment) external returns (bool) { + function responseCommitments(bytes32 commitment) external view returns (bool) { return _responseCommitments[commitment]; } /** * @return the challenge period */ - function challengePeriod() external returns (uint256) { - return _CHALLENGE_PERIOD; + function challengePeriod() external view returns (uint256) { + return _hostParams.challengePeriod; } /** @@ -202,26 +205,27 @@ abstract contract IsmpHost is IIsmpHost, Context { * @param params new bridge params */ function setBridgeParams(BridgeParams memory params) external onlyGovernance { - _admin = params.admin; - _CHALLENGE_PERIOD = params.challengePeriod; - _consensus.client = params.consensus; - _DEFAULT_TIMEOUT = params.defaultTimeout; - _unStakingPeriod = params.unstakingPeriod; - _handler = IHandler(params.handler); + _hostParams.challengePeriod = params.challengePeriod; + _hostParams.consensusClient = params.consensus; + _hostParams.unStakingPeriod = params.unstakingPeriod; + + _hostParams.admin = params.admin; + _hostParams.defaultTimeout = params.defaultTimeout; + _hostParams.handler = params.handler; } /** * @dev Store an encoded consensus state */ function storeConsensusState(bytes memory state) external onlyHandler { - _consensus.state = state; + _hostParams.consensusState = state; } /** * @dev Store the timestamp when the consensus client was updated */ - function storeConsensusUpdateTime(uint256 timestamp) external onlyHandler { - _consensus.lastUpdated = timestamp; + function storeConsensusUpdateTime(uint256 time) external onlyHandler { + _hostParams.lastUpdated = time; } /** @@ -237,11 +241,11 @@ abstract contract IsmpHost is IIsmpHost, Context { /** * @dev Store the timestamp when the state machine was updated */ - function storeStateMachineCommitmentUpdateTime(StateMachineHeight memory height, uint256 timestamp) + function storeStateMachineCommitmentUpdateTime(StateMachineHeight memory height, uint256 time) external onlyHandler { - _stateCommitmentsUpdateTime[height.stateMachineId][height.height] = timestamp; + _stateCommitmentsUpdateTime[height.stateMachineId][height.height] = time; } /** @@ -255,8 +259,8 @@ abstract contract IsmpHost is IIsmpHost, Context { /** * @return the unstaking period */ - function unStakingPeriod() public returns (uint256) { - return _unStakingPeriod; + function unStakingPeriod() public view returns (uint256) { + return _hostParams.unStakingPeriod; } /** @@ -265,7 +269,6 @@ abstract contract IsmpHost is IIsmpHost, Context { */ function dispatchIncoming(PostRequest memory request) external onlyHandler { address destination = _bytesToAddress(request.to); - require(IERC165(destination).supportsInterface(type(IIsmpModule).interfaceId), "ISMP_HOST: Invalid module"); IIsmpModule(destination).onAccept(request); bytes32 commitment = Message.hash(request); @@ -278,7 +281,6 @@ abstract contract IsmpHost is IIsmpHost, Context { */ function dispatchIncoming(PostResponse memory response) external onlyHandler { address origin = _bytesToAddress(response.request.from); - require(IERC165(origin).supportsInterface(type(IIsmpModule).interfaceId), "ISMP_HOST: Invalid module"); IIsmpModule(origin).onPostResponse(response); bytes32 commitment = Message.hash(response); @@ -291,23 +293,23 @@ abstract contract IsmpHost is IIsmpHost, Context { */ function dispatchIncoming(GetResponse memory response) external onlyHandler { address origin = _bytesToAddress(response.request.from); - require(IERC165(origin).supportsInterface(type(IIsmpModule).interfaceId), "ISMP_HOST: Invalid module"); IIsmpModule(origin).onGetResponse(response); - // todo: store response commitment + + bytes32 commitment = Message.hash(response); + _responseReceipts[commitment] = true; } /** * @dev Dispatch an incoming get timeout to source module - * @param timeout - get timeout + * @param request - get request */ function dispatchIncoming(GetRequest memory request) external onlyHandler { address origin = _bytesToAddress(request.from); - require(IERC165(origin).supportsInterface(type(IIsmpModule).interfaceId), "ISMP_HOST: Invalid module"); IIsmpModule(origin).onGetTimeout(request); // Delete Commitment bytes32 commitment = Message.hash(request); - delete _responseReceipts[commitment]; + delete _requestCommitments[commitment]; } /** @@ -315,14 +317,13 @@ abstract contract IsmpHost is IIsmpHost, Context { * @param timeout - post timeout */ function dispatchIncoming(PostTimeout memory timeout) external onlyHandler { - PostRequest request = timeout.request; + PostRequest memory request = timeout.request; address origin = _bytesToAddress(request.from); - require(IERC165(origin).supportsInterface(type(IIsmpModule).interfaceId), "ISMP_HOST: Invalid module"); IIsmpModule(origin).onPostTimeout(request); // Delete Commitment bytes32 commitment = Message.hash(request); - delete _responseReceipts[commitment]; + delete _requestCommitments[commitment]; } /** @@ -330,24 +331,31 @@ abstract contract IsmpHost is IIsmpHost, Context { * @param request - post dispatch request */ function dispatch(DispatchPost memory request) external { - require(IERC165(_msgSender()).supportsInterface(type(IIsmpModule).interfaceId), "Cannot dispatch request"); - uint256 timeout = Math.max(_DEFAULT_TIMEOUT, request.timeoutTimestamp); - PostRequest memory request = PostRequest( - host(), request.dest, _nextNonce(), request.from, request.to, timeout, request.body, request.gaslimit - ); + uint64 timeout = uint64(this.timestamp()) + uint64(Math.max(_hostParams.defaultTimeout, request.timeout)); + PostRequest memory _request = PostRequest({ + source: host(), + dest: request.dest, + nonce: uint64(_nextNonce()), + from: abi.encodePacked(_msgSender()), + to: request.to, + timeoutTimestamp: timeout, + body: request.body, + gaslimit: request.gaslimit + }); + // make the commitment - bytes32 commitment = Message.hash(request); + bytes32 commitment = Message.hash(_request); _requestCommitments[commitment] = true; emit PostRequestEvent( - request.source, - request.dest, - request.from, - abi.encodePacked(request.to), - request.nonce, - request.timeoutTimestamp, - request.body - ); + _request.source, + _request.dest, + _request.from, + abi.encodePacked(_request.to), + _request.nonce, + _request.timeoutTimestamp, + _request.body + ); } /** @@ -355,17 +363,23 @@ abstract contract IsmpHost is IIsmpHost, Context { * @param request - get dispatch request */ function dispatch(DispatchGet memory request) external { - require(IERC165(_msgSender()).supportsInterface(type(IIsmpModule).interfaceId), "Cannot dispatch request"); - uint256 timeout = Math.max(_DEFAULT_TIMEOUT, request.timeoutTimestamp); - GetRequest memory request = GetRequest( - host(), request.dest, _nextNonce(), request.from, timeout, request.keys, request.height, request.gaslimit - ); + uint64 timeout = uint64(this.timestamp()) + uint64(Math.max(_hostParams.defaultTimeout, request.timeout)); + GetRequest memory _request = GetRequest({ + source: host(), + dest: request.dest, + nonce: uint64(_nextNonce()), + from: abi.encodePacked(_msgSender()), + timeoutTimestamp: timeout, + keys: request.keys, + height: request.height, + gaslimit: request.gaslimit + }); // make the commitment - bytes32 commitment = Message.hash(request); + bytes32 commitment = Message.hash(_request); _requestCommitments[commitment] = true; - emit GetRequestEvent(request.source, request.dest, request.from, request.nonce, request.timeoutTimestamp); + emit GetRequestEvent(_request.source, _request.dest, _request.from, _request.nonce, _request.timeoutTimestamp); } /** @@ -373,9 +387,8 @@ abstract contract IsmpHost is IIsmpHost, Context { * @param response - post response */ function dispatch(PostResponse memory response) external { - require(IERC165(_msgSender()).supportsInterface(type(IIsmpModule).interfaceId), "ISMP_HOST: invalid module"); bytes32 receipt = Message.hash(response.request); - require(_requestReceipts[receipt], "ISMP_HOST: unknown request"); + require(_requestReceipts[receipt], "EvmHost: unknown request"); bytes32 commitment = Message.hash(response); _responseCommitments[commitment] = true; @@ -389,26 +402,28 @@ abstract contract IsmpHost is IIsmpHost, Context { response.request.timeoutTimestamp, response.request.body, response.response - ); + ); } /** * @dev Get next available nonce for outgoing requests. */ function _nextNonce() private returns (uint256) { + uint256 _nonce_copy = _nonce; + unchecked { ++_nonce; } - return _nonce; + return _nonce_copy; } /** * @dev Converts bytes to address. * @param _bytes bytes value to be converted - * @return returns the address + * @return addr returns the address */ - function _bytesToAddress(bytes memory _bytes) private returns (address addr) { + function _bytesToAddress(bytes memory _bytes) private pure returns (address addr) { require(_bytes.length >= 20, "Invalid address length"); assembly { addr := mload(add(_bytes, 20)) diff --git a/src/Handler.sol b/src/HandlerV1.sol similarity index 57% rename from src/Handler.sol rename to src/HandlerV1.sol index 9ee6a9e..87ea6b6 100644 --- a/src/Handler.sol +++ b/src/HandlerV1.sol @@ -1,5 +1,5 @@ // SPDX-License-Identifier: UNLICENSED -pragma solidity ^0.8.17; +pragma solidity 0.8.17; import "solidity-merkle-trees/MerkleMountainRange.sol"; import "solidity-merkle-trees/MerklePatricia.sol"; @@ -8,16 +8,19 @@ import "openzeppelin/utils/Context.sol"; import "./interfaces/IConsensusClient.sol"; import "./interfaces/IHandler.sol"; import "./interfaces/IIsmpHost.sol"; -import "./interfaces/IIsmpDispatcher.sol"; -abstract contract Handler is IHandler, Context { +contract HandlerV1 is IHandler, Context { using Bytes for bytes; modifier notFrozen(IIsmpHost host) { - require(!host.frozen(), "ISMP_Handler: frozen"); + require(!host.frozen(), "IHandler: frozen"); _; } + // Storage prefix for request receipts in pallet-ismp + bytes private constant REQUEST_COMMITMENT_STORAGE_PREFIX = + hex"103895530afb23bb607661426d55eb8b0484aecefe882c3ce64e6f82507f715a"; + /** * @dev Handle incoming consensus messages * @param host - Ismp host @@ -25,20 +28,20 @@ abstract contract Handler is IHandler, Context { */ function handleConsensus(IIsmpHost host, bytes memory proof) external notFrozen(host) { require( - (host.hostTimestamp() - host.consensusUpdateTime()) > host.challengePeriod(), - "ISMP_Handler: still in challenge period" + (host.timestamp() - host.consensusUpdateTime()) > host.challengePeriod(), + "IHandler: still in challenge period" ); // not today, time traveling validators require( - (host.hostTimestamp() - host.consensusUpdateTime()) < host.unStakingPeriod() || _msgSender() == host.admin(), - "ISMP_Handler: still in challenge period" + (host.timestamp() - host.consensusUpdateTime()) < host.unStakingPeriod() || _msgSender() == host.admin(), + "IHandler: still in challenge period" ); (bytes memory verifiedState, IntermediateState[] memory intermediates) = IConsensusClient(host.consensusClient()).verifyConsensus(host.consensusState(), proof); host.storeConsensusState(verifiedState); - host.storeConsensusUpdateTime(host.hostTimestamp()); + host.storeConsensusUpdateTime(host.timestamp()); uint256 commitmentsLen = intermediates.length; for (uint256 i = 0; i < commitmentsLen; i++) { @@ -46,7 +49,7 @@ abstract contract Handler is IHandler, Context { StateMachineHeight memory stateMachineHeight = StateMachineHeight({stateMachineId: intermediate.stateMachineId, height: intermediate.height}); host.storeStateMachineCommitment(stateMachineHeight, intermediate.commitment); - host.storeStateMachineCommitmentUpdateTime(stateMachineHeight, host.hostTimestamp()); + host.storeStateMachineCommitmentUpdateTime(stateMachineHeight, host.timestamp()); } } @@ -56,8 +59,8 @@ abstract contract Handler is IHandler, Context { * @param request - batch post requests */ function handlePostRequests(IIsmpHost host, PostRequestMessage memory request) external notFrozen(host) { - uint256 delay = host.hostTimestamp() - host.stateMachineCommitmentUpdateTime(request.proof.height); - require(delay > host.challengePeriod(), "ISMP_Handler: still in challenge period"); + uint256 delay = host.timestamp() - host.stateMachineCommitmentUpdateTime(request.proof.height); + require(delay > host.challengePeriod(), "IHandler: still in challenge period"); uint256 requestsLen = request.requests.length; MmrLeaf[] memory leaves = new MmrLeaf[](requestsLen); @@ -65,24 +68,21 @@ abstract contract Handler is IHandler, Context { for (uint256 i = 0; i < requestsLen; i++) { PostRequestLeaf memory leaf = request.requests[i]; - require(!leaf.request.dest.equals(host.host()), "ISMP_Handler: Invalid request destination"); - - require(leaf.request.timeoutTimestamp < host.hostTimestamp(), "ISMP_Handler: Request timed out"); + require(leaf.request.dest.equals(host.host()), "IHandler: Invalid request destination"); + require(leaf.request.timeoutTimestamp < host.timestamp(), "IHandler: Request timed out"); bytes32 commitment = Message.hash(leaf.request); - require(!host.requestReceipts(commitment), "ISMP_Handler: Duplicate request"); + require(!host.requestReceipts(commitment), "IHandler: Duplicate request"); - uint256 mmrPos = MerkleMountainRange.leafIndexToPos(uint64(leaf.mmrIndex)); - leaves[i] = MmrLeaf(leaf.kIndex, mmrPos, commitment); + leaves[i] = MmrLeaf(leaf.kIndex, leaf.mmrIndex, commitment); } bytes32 root = host.stateMachineCommitment(request.proof.height).overlayRoot; - require(root != bytes32(0), "ISMP_Handler: Proof height not found!"); - bytes32[] memory proof = abi.decode(request.proof.multiproof, (bytes32[])); + require(root != bytes32(0), "IHandler: Proof height not found!"); require( - MerkleMountainRange.VerifyProof(root, proof, leaves, request.proof.mmrSize), - "ISMP_Handler: Invalid request proofs" + MerkleMountainRange.VerifyProof(root, request.proof.multiproof, leaves, request.proof.mmrSize), + "IHandler: Invalid request proofs" ); for (uint256 i = 0; i < requestsLen; i++) { @@ -97,32 +97,31 @@ abstract contract Handler is IHandler, Context { * @param response - batch post responses */ function handlePostResponses(IIsmpHost host, PostResponseMessage memory response) external notFrozen(host) { - uint256 delay = host.hostTimestamp() - host.stateMachineCommitmentUpdateTime(response.proof.height); - require(delay > host.challengePeriod(), "ISMP_Handler: still in challenge period"); + uint256 delay = host.timestamp() - host.stateMachineCommitmentUpdateTime(response.proof.height); + require(delay > host.challengePeriod(), "IHandler: still in challenge period"); uint256 responsesLength = response.responses.length; MmrLeaf[] memory leaves = new MmrLeaf[](responsesLength); for (uint256 i = 0; i < responsesLength; i++) { PostResponseLeaf memory leaf = response.responses[i]; - require(leaf.response.request.source.equals(host.host()), "ISMP_Handler: Invalid response destination"); + require(leaf.response.request.source.equals(host.host()), "IHandler: Invalid response destination"); bytes32 requestCommitment = Message.hash(leaf.response.request); - require(host.requestCommitments(requestCommitment), "ISMP_Handler: Unknown request"); + require(host.requestCommitments(requestCommitment), "IHandler: Unknown request"); bytes32 responseCommitment = Message.hash(leaf.response); - require(!host.responseCommitments(responseCommitment), "ISMP_Handler: Duplicate response"); + require(!host.responseCommitments(responseCommitment), "IHandler: Duplicate Post response"); - uint256 mmrPos = MerkleMountainRange.leafIndexToPos(uint64(leaf.mmrIndex)); - leaves[i] = MmrLeaf(leaf.kIndex, mmrPos, responseCommitment); + leaves[i] = MmrLeaf(leaf.kIndex, leaf.mmrIndex, responseCommitment); } bytes32 root = host.stateMachineCommitment(response.proof.height).overlayRoot; - require(root != bytes32(0), "ISMP_Handler: Proof height not found!"); + require(root != bytes32(0), "IHandler: Proof height not found!"); require( MerkleMountainRange.VerifyProof(root, response.proof.multiproof, leaves, response.proof.mmrSize), - "ISMP_Handler: Invalid response proofs" + "IHandler: Invalid response proofs" ); for (uint256 i = 0; i < responsesLength; i++) { @@ -132,62 +131,61 @@ abstract contract Handler is IHandler, Context { } /** - * @dev check response proofs, message delay and timeouts, then dispatch get responses to modules + * @dev check timeout proofs then dispatch to modules * @param host - Ismp host - * @param message - batch get responses + * @param message - batch post request timeouts */ - function handleGetResponses(IIsmpHost host, GetResponseMessage memory message) external { - uint256 delay = host.hostTimestamp() - host.stateMachineCommitmentUpdateTime(message.height); - require(delay > host.challengePeriod(), "ISMP_Handler: still in challenge period"); - - StateCommitment memory stateCommitment = host.stateMachineCommitment(message.height); - bytes32 root = stateCommitment.stateRoot; - require(root != bytes32(0), "ISMP_Handler: Proof height not found!"); - - uint256 responsesLength = message.requests.length; - bytes[] memory proof = message.proof; - - for (uint256 i = 0; i < responsesLength; i++) { - GetRequest memory request = message.requests[i]; + function handlePostTimeouts(IIsmpHost host, PostTimeoutMessage memory message) external notFrozen(host) { + // fetch the state commitment + StateCommitment memory state = host.stateMachineCommitment(message.height); + uint256 timeoutsLength = message.timeouts.length; - require(request.source.equals(host.host()), "ISMP_Handler: Invalid response destination"); + for (uint256 i = 0; i < timeoutsLength; i++) { + PostRequest memory request = message.timeouts[i]; + require(state.timestamp > request.timeoutTimestamp, "Request not timed out"); bytes32 requestCommitment = Message.hash(request); - require(host.requestCommitments(requestCommitment), "ISMP_Handler: Unknown request"); + require(host.requestCommitments(requestCommitment), "IHandler: Unknown request"); - require(request.timeoutTimestamp < host.hostTimestamp(), "ISMP_Handler: Request timed out"); - // todo: check duplicate response + bytes[] memory keys = new bytes[](1); + keys[i] = bytes.concat(REQUEST_COMMITMENT_STORAGE_PREFIX, bytes.concat(requestCommitment)); - // todo: use child trie. - StorageValue[] memory values = MerklePatricia.VerifySubstrateProof(root, proof, request.keys); - GetResponse memory response = GetResponse({request: request, values: values}); - host.dispatchIncoming(response); + StorageValue memory entry = MerklePatricia.VerifySubstrateProof(state.stateRoot, message.proof, keys)[0]; + require(entry.value.equals(new bytes(0)), "IHandler: Invalid non-membership proof"); + + host.dispatchIncoming(PostTimeout(request)); } } /** - * @dev check timeout proofs then dispatch to modules + * @dev check response proofs, message delay and timeouts, then dispatch get responses to modules * @param host - Ismp host - * @param message - batch post request timeouts + * @param message - batch get responses */ - function handlePostTimeouts(IIsmpHost host, PostTimeoutMessage memory message) external { - // fetch the state commitment - StateCommitment memory commitment = host.stateMachineCommitment(message.height); - uint256 timeoutsLength = message.timeouts.length; + function handleGetResponses(IIsmpHost host, GetResponseMessage memory message) external notFrozen(host) { + uint256 delay = host.timestamp() - host.stateMachineCommitmentUpdateTime(message.height); + require(delay > host.challengePeriod(), "IHandler: still in challenge period"); - for (uint256 i = 0; i < timeoutsLength; i++) { - PostRequest memory request = message.timeouts[i]; + StateCommitment memory stateCommitment = host.stateMachineCommitment(message.height); + bytes32 root = stateCommitment.stateRoot; + require(root != bytes32(0), "IHandler: Proof height not found!"); - require(request.timeoutTimestamp > commitment.timestamp); + uint256 responsesLength = message.requests.length; + bytes[] memory proof = message.proof; - // Todo: temporary placeholder for post request - bytes[] memory keys; + for (uint256 i = 0; i < responsesLength; i++) { + GetRequest memory request = message.requests[i]; + require(request.source.equals(host.host()), "IHandler: Invalid GET response destination"); - StorageValue memory entry = - MerklePatricia.VerifySubstrateProof(commitment.stateRoot, keys, message.proof)[0]; - require(entry.value.equals(new bytes(0)), "ISMP_Handler: Invalid non-membership proof"); + bytes32 requestCommitment = Message.hash(request); + require(host.requestCommitments(requestCommitment), "IHandler: Unknown GET request"); + require(request.timeoutTimestamp < host.timestamp(), "IHandler: GET request timed out"); - host.dispatchIncoming(PostTimeout(request)); + StorageValue[] memory values = + MerklePatricia.ReadChildProofCheck(root, proof, request.keys, bytes.concat(requestCommitment)); + GetResponse memory response = GetResponse({request: request, values: values}); + require(!host.responseCommitments(Message.hash(response)), "IHandler: Duplicate GET response"); + host.dispatchIncoming(response); } } @@ -196,12 +194,16 @@ abstract contract Handler is IHandler, Context { * @param host - Ismp host * @param message - batch get request timeouts */ - function handleGetTimeouts(IIsmpHost host, GetTimeoutMessage memory message) external { + function handleGetTimeouts(IIsmpHost host, GetTimeoutMessage memory message) external notFrozen(host) { uint256 timeoutsLength = message.timeouts.length; for (uint256 i = 0; i < timeoutsLength; i++) { - GetRequest memory timeout = message.timeouts[i]; - host.dispatchIncoming(timeout); + GetRequest memory request = message.timeouts[i]; + bytes32 requestCommitment = Message.hash(request); + require(host.requestCommitments(requestCommitment), "IHandler: Unknown request"); + + require(host.timestamp() > request.timeoutTimestamp, "IHandler: GET request not timed out"); + host.dispatchIncoming(request); } } } diff --git a/src/SubstrateHost.sol b/src/SubstrateDispatcher.sol similarity index 82% rename from src/SubstrateHost.sol rename to src/SubstrateDispatcher.sol index b6defd2..c35bf18 100644 --- a/src/SubstrateHost.sol +++ b/src/SubstrateDispatcher.sol @@ -1,10 +1,10 @@ // SPDX-License-Identifier: UNLICENSED -pragma solidity ^0.8.17; +pragma solidity 0.8.17; import "./interfaces/IIsmpDispatcher.sol"; import "./interfaces/IIsmpModule.sol"; -library SubstrateHost { +library SubstrateDispatcher { // addresses of the precompiles address public constant POST_REQUEST_DISPATCHER = 0x222A98a2832ae77E72a768bF5be1F82D8959f4Ec; address public constant POST_RESPONSE_DISPATCHER = 0xEB928e2de75Cb5ab60aBE75f539C5312aeb46f38; @@ -15,8 +15,7 @@ library SubstrateHost { * @param request - post request */ function dispatch(DispatchPost memory request) internal view { - bytes memory input = - abi.encode(request.dest, request.to, request.body, request.timeoutTimestamp, request.gaslimit); + bytes memory input = abi.encode(request.dest, request.to, request.body, request.timeout, request.gaslimit); (bool ok, bytes memory out) = address(POST_REQUEST_DISPATCHER).staticcall(input); @@ -30,8 +29,7 @@ library SubstrateHost { * @param request - get request */ function dispatch(DispatchGet memory request) internal view { - bytes memory input = - abi.encode(request.dest, request.height, request.keys, request.timeoutTimestamp, request.gaslimit); + bytes memory input = abi.encode(request.dest, request.height, request.keys, request.timeout, request.gaslimit); (bool ok, bytes memory out) = address(GET_REQUEST_DISPATCHER).staticcall(input); diff --git a/src/consensus/Beefy.sol b/src/beefy/BeefyV1.sol similarity index 68% rename from src/consensus/Beefy.sol rename to src/beefy/BeefyV1.sol index 727191e..dea85f1 100644 --- a/src/consensus/Beefy.sol +++ b/src/beefy/BeefyV1.sol @@ -1,9 +1,9 @@ // SPDX-License-Identifier: UNLICENSED -pragma solidity ^0.8.13; +pragma solidity 0.8.17; -//import "../ISMP.sol"; import "./Codec.sol"; -import "./Schema.sol"; +import "../interfaces/StateMachine.sol"; +import "../interfaces/IConsensusClient.sol"; import "solidity-merkle-trees/MerkleMultiProof.sol"; import "solidity-merkle-trees/MerkleMountainRange.sol"; @@ -11,15 +11,100 @@ import "solidity-merkle-trees/MerklePatricia.sol"; import "solidity-merkle-trees/trie/substrate/ScaleCodec.sol"; import "solidity-merkle-trees/trie/Bytes.sol"; import "openzeppelin/utils/cryptography/ECDSA.sol"; -import "openzeppelin/utils/cryptography/MerkleProof.sol"; -import "openzeppelin/utils/Strings.sol"; -import "../interfaces/IConsensusClient.sol"; + +struct BeefyConsensusState { + /// block number for the latest mmr_root_hash + uint256 latestHeight; + /// Block number that the beefy protocol was activated on the relay chain. + /// This should be the first block in the merkle-mountain-range tree. + uint256 beefyActivationBlock; + /// authorities for the current round + AuthoritySetCommitment currentAuthoritySet; + /// authorities for the next round + AuthoritySetCommitment nextAuthoritySet; +} + +struct AuthoritySetCommitment { + /// Id of the set. + uint256 id; + /// Number of validators in the set. + uint256 len; + /// Merkle Root Hash built from BEEFY AuthorityIds. + bytes32 root; +} + +struct Payload { + bytes2 id; + bytes data; +} + +struct Commitment { + Payload[] payload; + uint256 blockNumber; + uint256 validatorSetId; +} + +struct Vote { + bytes signature; + uint256 authorityIndex; +} + +struct SignedCommitment { + Commitment commitment; + Vote[] votes; +} + +struct BeefyMmrLeaf { + uint256 version; + uint256 parentNumber; + bytes32 parentHash; + AuthoritySetCommitment nextAuthoritySet; + bytes32 extra; + uint256 kIndex; +} + +struct PartialBeefyMmrLeaf { + uint256 version; + uint256 parentNumber; + bytes32 parentHash; + AuthoritySetCommitment nextAuthoritySet; +} + +struct RelayChainProof { + /// Signed commitment + SignedCommitment signedCommitment; + /// Latest leaf added to mmr + BeefyMmrLeaf latestMmrLeaf; + /// Proof for the latest mmr leaf + bytes32[] mmrProof; + /// Proof for authorities in current/next session + Node[][] proof; +} + +struct Parachain { + /// k-index for latestHeadsRoot + uint256 index; + /// Parachain Id + uint256 id; + /// SCALE encoded header + bytes header; +} + +struct ParachainProof { + Parachain[] parachains; + Node[][] proof; +} + +struct BeefyConsensusProof { + RelayChainProof relay; + ParachainProof parachain; +} struct ConsensusMessage { BeefyConsensusProof proof; } -library BeefyConsensusClient { +contract BeefyV1 is IConsensusClient { /// Slot duration in milliseconds uint256 public constant SLOT_DURATION = 12000; /// The PayloadId for the mmr root. @@ -29,22 +114,34 @@ library BeefyConsensusClient { /// ConsensusID for aura bytes4 public constant AURA_CONSENSUS_ID = bytes4("aura"); + function verifyConsensus(bytes memory encodedState, bytes memory encodedProof) + external + returns (bytes memory, IntermediateState[] memory) + { + BeefyConsensusState memory consensusState = abi.decode(encodedState, (BeefyConsensusState)); + (RelayChainProof memory relay, ParachainProof memory parachain) = + abi.decode(encodedProof, (RelayChainProof, ParachainProof)); + + (BeefyConsensusState memory newState, IntermediateState[] memory intermediates) = + this.verifyConsensus(consensusState, BeefyConsensusProof(relay, parachain)); + + return (abi.encode(newState), intermediates); + } + /// Verify the consensus proof and return the new trusted consensus state and any intermediate states finalized /// by this consensus proof. function verifyConsensus(BeefyConsensusState memory trustedState, BeefyConsensusProof memory proof) - internal + external pure returns (BeefyConsensusState memory, IntermediateState[] memory) { - require(trustedState.frozenHeight == 0, "Consensus client is frozen"); - // verify mmr root proofs - trustedState = verifyMmrUpdateProof(trustedState, proof.relay); + (BeefyConsensusState memory state, bytes32 headsRoot) = verifyMmrUpdateProof(trustedState, proof.relay); // verify intermediate state commitment proofs - IntermediateState[] memory intermediate = verifyParachainHeaderProof(trustedState, proof.parachain); + IntermediateState[] memory intermediate = verifyParachainHeaderProof(headsRoot, proof.parachain); - return (trustedState, intermediate); + return (state, intermediate); } /// Verifies a new Mmmr root update, the relay chain accumulates its blocks into a merkle mountain range tree @@ -52,9 +149,9 @@ library BeefyConsensusClient { /// the relay chain authority set and we can verify the membership of the authorities who signed this new root /// using a merkle multi proof and a merkle commitment to the total authorities. function verifyMmrUpdateProof(BeefyConsensusState memory trustedState, RelayChainProof memory relayProof) - internal + private pure - returns (BeefyConsensusState memory) + returns (BeefyConsensusState memory, bytes32) { uint256 signatures_length = relayProof.signedCommitment.votes.length; uint256 latestHeight = relayProof.signedCommitment.commitment.blockNumber; @@ -127,30 +224,29 @@ library BeefyConsensusClient { } trustedState.latestHeight = latestHeight; - trustedState.latestHeadsRoot = relayProof.latestMmrLeaf.extra; - return trustedState; + return (trustedState, relayProof.latestMmrLeaf.extra); } /// Stack too deep, sigh solidity function verifyMmrLeaf(BeefyConsensusState memory trustedState, RelayChainProof memory relay, bytes32 mmrRoot) - internal + private pure { - bytes32 leafHash = keccak256(Codec.Encode(relay.latestMmrLeaf)); - uint256 leafIndex = leafIndex(trustedState.beefyActivationBlock, relay.latestMmrLeaf.parentNumber); - uint256 mmrSize = MerkleMountainRange.leafIndexToMmrSize(uint64(leafIndex)); - uint256 leafPos = MerkleMountainRange.leafIndexToPos(uint64(leafIndex)); + bytes32 hash = keccak256(Codec.Encode(relay.latestMmrLeaf)); + uint256 index = leafIndex(trustedState.beefyActivationBlock, relay.latestMmrLeaf.parentNumber); + uint256 mmrSize = MerkleMountainRange.leafIndexToMmrSize(uint64(index)); + uint256 pos = MerkleMountainRange.leafIndexToPos(uint64(index)); MmrLeaf[] memory leaves = new MmrLeaf[](1); - leaves[0] = MmrLeaf(relay.latestMmrLeaf.kIndex, leafPos, leafHash); + leaves[0] = MmrLeaf(relay.latestMmrLeaf.kIndex, pos, hash); require(MerkleMountainRange.VerifyProof(mmrRoot, relay.mmrProof, leaves, mmrSize), "Invalid Mmr Proof"); } /// Verifies that some parachain header has been finalized, given the current trusted consensus state. - function verifyParachainHeaderProof(BeefyConsensusState memory trustedState, ParachainProof memory proof) - internal + function verifyParachainHeaderProof(bytes32 headsRoot, ParachainProof memory proof) + private pure returns (IntermediateState[] memory) { @@ -187,16 +283,13 @@ library BeefyConsensusClient { IntermediateState(para.id, header.number, StateCommitment(timestamp, commitment, header.stateRoot)); } - require( - MerkleMultiProof.VerifyProofSorted(trustedState.latestHeadsRoot, proof.proof, leaves), - "Invalid parachains heads proof" - ); + require(MerkleMultiProof.VerifyProofSorted(headsRoot, proof.proof, leaves), "Invalid parachains heads proof"); return intermediates; } /// Calculates the mmr leaf index for a block whose parent number is given. - function leafIndex(uint256 activationBlock, uint256 parentNumber) internal pure returns (uint256) { + function leafIndex(uint256 activationBlock, uint256 parentNumber) private pure returns (uint256) { if (activationBlock == 0) { return parentNumber; } else { @@ -205,7 +298,7 @@ library BeefyConsensusClient { } /// Check for supermajority participation. - function checkParticipationThreshold(uint256 len, uint256 total) internal pure returns (bool) { + function checkParticipationThreshold(uint256 len, uint256 total) private pure returns (bool) { return len >= ((2 * total) / 3) + 1; } } diff --git a/src/consensus/Codec.sol b/src/beefy/Codec.sol similarity index 98% rename from src/consensus/Codec.sol rename to src/beefy/Codec.sol index b19ccfe..f808bbe 100644 --- a/src/consensus/Codec.sol +++ b/src/beefy/Codec.sol @@ -1,10 +1,11 @@ // SPDX-License-Identifier: UNLICENSED -pragma solidity ^0.8.0; +pragma solidity 0.8.17; import "solidity-merkle-trees/MerkleMultiProof.sol"; import "solidity-merkle-trees/trie/substrate/ScaleCodec.sol"; import "solidity-merkle-trees/trie/Bytes.sol"; -import "./Schema.sol"; +import "./Header.sol"; +import "./BeefyV1.sol"; /// type encoding stuff library Codec { diff --git a/src/beefy/Header.sol b/src/beefy/Header.sol new file mode 100644 index 0000000..7f11df7 --- /dev/null +++ b/src/beefy/Header.sol @@ -0,0 +1,27 @@ +// SPDX-License-Identifier: UNLICENSED +pragma solidity 0.8.17; + +struct DigestItem { + bytes4 consensusId; + bytes data; +} + +struct Digest { + bool isPreRuntime; + DigestItem preruntime; + bool isConsensus; + DigestItem consensus; + bool isSeal; + DigestItem seal; + bool isOther; + bytes other; + bool isRuntimeEnvironmentUpdated; +} + +struct Header { + bytes32 parentHash; + uint256 number; + bytes32 stateRoot; + bytes32 extrinsicRoot; + Digest[] digests; +} diff --git a/src/consensus/Schema.sol b/src/consensus/Schema.sol deleted file mode 100644 index 03dc043..0000000 --- a/src/consensus/Schema.sol +++ /dev/null @@ -1,124 +0,0 @@ -// SPDX-License-Identifier: UNLICENSED -pragma solidity ^0.8.0; - -import "./Schema.sol"; -import "solidity-merkle-trees/MerkleMultiProof.sol"; - -struct BeefyConsensusState { - /// block number for the latest mmr_root_hash - uint256 latestHeight; - /// timestamp for the latest height - uint256 latestTimestamp; - /// Block height when the client was frozen due to a byzantine attack - uint256 frozenHeight; - /// Parachain heads root. - bytes32 latestHeadsRoot; - /// Block number that the beefy protocol was activated on the relay chain. - /// This should be the first block in the merkle-mountain-range tree. - uint256 beefyActivationBlock; - /// authorities for the current round - AuthoritySetCommitment currentAuthoritySet; - /// authorities for the next round - AuthoritySetCommitment nextAuthoritySet; -} - -struct AuthoritySetCommitment { - /// Id of the set. - uint256 id; - /// Number of validators in the set. - uint256 len; - /// Merkle Root Hash built from BEEFY AuthorityIds. - bytes32 root; -} - -struct Payload { - bytes2 id; - bytes data; -} - -struct Commitment { - Payload[] payload; - uint256 blockNumber; - uint256 validatorSetId; -} - -struct Vote { - bytes signature; - uint256 authorityIndex; -} - -struct SignedCommitment { - Commitment commitment; - Vote[] votes; -} - -struct BeefyMmrLeaf { - uint256 version; - uint256 parentNumber; - bytes32 parentHash; - AuthoritySetCommitment nextAuthoritySet; - bytes32 extra; - uint256 kIndex; -} - -struct PartialBeefyMmrLeaf { - uint256 version; - uint256 parentNumber; - bytes32 parentHash; - AuthoritySetCommitment nextAuthoritySet; -} - -struct RelayChainProof { - /// Signed commitment - SignedCommitment signedCommitment; - /// Latest leaf added to mmr - BeefyMmrLeaf latestMmrLeaf; - /// Proof for the latest mmr leaf - bytes32[] mmrProof; - /// Proof for authorities in current/next session - Node[][] proof; -} - -struct Parachain { - /// k-index for latestHeadsRoot - uint256 index; - /// Parachain Id - uint256 id; - /// SCALE encoded header - bytes header; -} - -struct ParachainProof { - Parachain[] parachains; - Node[][] proof; -} - -struct BeefyConsensusProof { - RelayChainProof relay; - ParachainProof parachain; -} - -struct DigestItem { - bytes4 consensusId; - bytes data; -} - -struct Digest { - bool isPreRuntime; - DigestItem preruntime; - bool isConsensus; - DigestItem consensus; - bool isSeal; - DigestItem seal; - bool isOther; - bytes other; - bool isRuntimeEnvironmentUpdated; -} - -struct Header { - bytes32 parentHash; - uint256 number; - bytes32 stateRoot; - bytes32 extrinsicRoot; - Digest[] digests; -} diff --git a/src/interfaces/IConsensusClient.sol b/src/interfaces/IConsensusClient.sol index 15aa6cd..301654d 100644 --- a/src/interfaces/IConsensusClient.sol +++ b/src/interfaces/IConsensusClient.sol @@ -1,5 +1,5 @@ // SPDX-License-Identifier: UNLICENSED -pragma solidity ^0.8.17; +pragma solidity 0.8.17; import "solidity-merkle-trees/MerklePatricia.sol"; @@ -18,7 +18,7 @@ struct StateCommitment { // as some consensus clients may track multiple, concurrent state machines. struct StateMachineHeight { // the state machine identifier - uint256 stateMachineId; // TODO: Subject to change/review + uint256 stateMachineId; // height of this state machine uint256 height; } @@ -32,25 +32,10 @@ struct IntermediateState { StateCommitment commitment; } -struct Consensus { - // consensus client contract - address client; - // current verified state of the consensus client; - bytes state; - // timestamp for when the consensus was most recently updated - uint256 lastUpdated; -} - interface IConsensusClient { /// Verify the consensus proof and return the new trusted consensus state and any intermediate states finalized /// by this consensus proof. function verifyConsensus(bytes memory trustedState, bytes memory proof) external - pure returns (bytes memory, IntermediateState[] memory); - - function verifyStateProof(bytes32 root, bytes[] memory keys, bytes[] memory proof) - external - pure - returns (StorageValue[] memory); } diff --git a/src/interfaces/IHandler.sol b/src/interfaces/IHandler.sol index cac1e5c..1d5ec06 100644 --- a/src/interfaces/IHandler.sol +++ b/src/interfaces/IHandler.sol @@ -1,5 +1,5 @@ // SPDX-License-Identifier: UNLICENSED -pragma solidity ^0.8.17; +pragma solidity 0.8.17; import "./IIsmpHost.sol"; import "./IIsmpDispatcher.sol"; diff --git a/src/interfaces/IIsmpDispatcher.sol b/src/interfaces/IIsmpDispatcher.sol index ae12bab..759fb0f 100644 --- a/src/interfaces/IIsmpDispatcher.sol +++ b/src/interfaces/IIsmpDispatcher.sol @@ -1,5 +1,5 @@ // SPDX-License-Identifier: UNLICENSED -pragma solidity ^0.8.17; +pragma solidity 0.8.17; import "solidity-merkle-trees/MerklePatricia.sol"; @@ -139,8 +139,8 @@ struct DispatchPost { bytes to; // the request body bytes body; - // the timestamp at which this request should timeout - uint64 timeoutTimestamp; + // timeout for this request in seconds + uint64 timeout; // gas limit for executing this request on destination & its response (if any) on the source. uint64 gaslimit; } @@ -153,8 +153,8 @@ struct DispatchGet { uint64 height; // Storage keys to read bytes[] keys; - // the timestamp at which this request should timeout - uint64 timeoutTimestamp; + // timeout for this request in seconds + uint64 timeout; // gas limit for executing this request on destination & its response (if any) on the source. uint64 gaslimit; } @@ -204,11 +204,37 @@ library Message { } function hash(GetRequest memory req) internal pure returns (bytes32) { - bytes memory keysEncoding = abi.encode(req.keys); + bytes memory keysEncoding = bytes(""); + uint256 len = req.keys.length; + for (uint256 i = 0; i < len; i++) { + keysEncoding = bytes.concat(keysEncoding, req.keys[i]); + } + return keccak256( abi.encodePacked( req.source, req.dest, req.nonce, req.height, req.timeoutTimestamp, req.from, keysEncoding, req.gaslimit ) ); } + + function hash(GetResponse memory res) internal pure returns (bytes32) { + bytes memory keysEncoding = abi.encode(res.request.keys); + bytes memory preimage = abi.encodePacked( + res.request.source, + res.request.dest, + res.request.nonce, + res.request.height, + res.request.timeoutTimestamp, + res.request.from, + keysEncoding, + res.request.gaslimit + ); + uint256 len = res.values.length; + for (uint256 i = 0; i < len; i++) { + StorageValue memory entry = res.values[i]; + preimage = bytes.concat(preimage, abi.encodePacked(entry.key, entry.value)); + } + + return keccak256(preimage); + } } diff --git a/src/interfaces/IIsmpHost.sol b/src/interfaces/IIsmpHost.sol index 03ec307..5174b7f 100644 --- a/src/interfaces/IIsmpHost.sol +++ b/src/interfaces/IIsmpHost.sol @@ -1,8 +1,8 @@ // SPDX-License-Identifier: UNLICENSED -pragma solidity ^0.8.17; +pragma solidity 0.8.17; -import {StateCommitment, StateMachineHeight, Consensus} from "./IConsensusClient.sol"; -import {IIsmpDispatcher, PostRequest, PostResponse, GetResponse, PostTimeout} from "./IIsmpDispatcher.sol"; +import {StateCommitment, StateMachineHeight} from "./IConsensusClient.sol"; +import {IIsmpDispatcher, PostRequest, PostResponse, GetResponse, PostTimeout, GetRequest} from "./IIsmpDispatcher.sol"; struct BridgeParams { address admin; @@ -27,7 +27,7 @@ interface IIsmpHost is IIsmpDispatcher { /** * @return the host timestamp */ - function hostTimestamp() external returns (uint256); + function timestamp() external returns (uint256); /** * @return the `frozen` status diff --git a/src/interfaces/IIsmpModule.sol b/src/interfaces/IIsmpModule.sol index 4ef0f33..526ea5b 100644 --- a/src/interfaces/IIsmpModule.sol +++ b/src/interfaces/IIsmpModule.sol @@ -1,5 +1,5 @@ // SPDX-License-Identifier: UNLICENSED -pragma solidity ^0.8.17; +pragma solidity 0.8.17; import "./IIsmpDispatcher.sol"; diff --git a/src/StateMachine.sol b/src/interfaces/StateMachine.sol similarity index 65% rename from src/StateMachine.sol rename to src/interfaces/StateMachine.sol index 29a5f2d..50c10c7 100644 --- a/src/StateMachine.sol +++ b/src/interfaces/StateMachine.sol @@ -1,5 +1,5 @@ // SPDX-License-Identifier: UNLICENSED -pragma solidity ^0.8.17; +pragma solidity 0.8.17; import "openzeppelin/utils/Strings.sol"; @@ -8,32 +8,32 @@ library StateMachine { uint256 public constant RELAY_CHAIN = 0; // Address a state machine on the polkadot relay chain - function polkadot(uint256 id) public returns (bytes memory) { + function polkadot(uint256 id) public pure returns (bytes memory) { return bytes(string.concat("POLKADOT-", Strings.toString(id))); } // Address a state machine on the kusama relay chain - function kusama(uint256 id) public returns (bytes memory) { + function kusama(uint256 id) public pure returns (bytes memory) { return bytes(string.concat("KUSAMA-", Strings.toString(id))); } // Address the ethereum "execution layer" - function ethereum() public returns (bytes memory) { + function ethereum() public pure returns (bytes memory) { return bytes("ETH"); } // Address the Arbitrum state machine - function arbitrum() public returns (bytes memory) { + function arbitrum() public pure returns (bytes memory) { return bytes("ARB"); } // Address the Optimism state machine - function optimism() public returns (bytes memory) { + function optimism() public pure returns (bytes memory) { return bytes("OP"); } // Address the Base state machine - function base() public returns (bytes memory) { + function base() public pure returns (bytes memory) { return bytes("BASE"); } } diff --git a/src/modules/CrossChainGovernor.sol b/src/modules/CrossChainGovernor.sol index 62f069f..ac5ad79 100644 --- a/src/modules/CrossChainGovernor.sol +++ b/src/modules/CrossChainGovernor.sol @@ -1,22 +1,30 @@ // SPDX-License-Identifier: UNLICENSED -pragma solidity ^0.8.17; +pragma solidity 0.8.17; import "solidity-merkle-trees/trie/Bytes.sol"; import "../interfaces/IIsmpModule.sol"; import "../interfaces/IIsmpHost.sol"; -import "../StateMachine.sol"; +import "../interfaces/StateMachine.sol"; contract CrossChainGovernor is IIsmpModule { - address private host; - uint256 private paraId; + using Bytes for bytes; + + address private _host; + uint256 private _paraId; modifier onlyIsmpHost() { - require(msg.sender == host, "CrossChainGovernance: Invalid caller"); + require(msg.sender == _host, "CrossChainGovernance: Invalid caller"); + _; + } + + constructor(address host, uint256 paraId) { + _host = host; + _paraId = paraId; } function onAccept(PostRequest memory request) external onlyIsmpHost { - require(request.source.equals(StateMachine.polkadot(paraId)), "Unauthorized request"); + require(request.source.equals(StateMachine.polkadot(_paraId)), "Unauthorized request"); ( address admin, address consensus, @@ -29,22 +37,22 @@ contract CrossChainGovernor is IIsmpModule { BridgeParams memory params = BridgeParams(admin, consensus, handler, challengePeriod, unstakingPeriod, defaultTimeout); - IIsmpHost(host).setBridgeParams(params); + IIsmpHost(_host).setBridgeParams(params); } - function onPostResponse(PostResponse memory response) external { + function onPostResponse(PostResponse memory response) external pure { revert("Module doesn't emit requests"); } - function onGetResponse(GetResponse memory response) external { + function onGetResponse(GetResponse memory response) external pure { revert("Module doesn't emit requests"); } - function onPostTimeout(PostRequest memory request) external { + function onPostTimeout(PostRequest memory request) external pure { revert("Module doesn't emit requests"); } - function onGetTimeout(GetRequest memory request) external { + function onGetTimeout(GetRequest memory request) external pure { revert("Module doesn't emit requests"); } } diff --git a/src/modules/TokenGateway.sol b/src/modules/TokenGateway.sol index fc4b7d3..a498958 100644 --- a/src/modules/TokenGateway.sol +++ b/src/modules/TokenGateway.sol @@ -1,133 +1,158 @@ // SPDX-License-Identifier: UNLICENSED -pragma solidity ^0.8.17; - -// import "../IISMPRouter.sol"; -import "../interfaces/IISMPModule.sol"; -import "openzeppelin/utils/introspection/IERC165.sol"; -import "multichain-token/interfaces/IERC6160Ext20.sol"; -import {IERC_ACL_CORE} from "multichain-token/interfaces/IERCAclCore.sol"; -import "../interfaces/IIsmpDispatcher.sol"; - -// -// Add supports interface for custom bride token -// -error LengthMismatch(); -error ZeroAddress(); -error TokenNotMultiChainNative(); -error BurnerRoleMissing(); -error MinterRoleMissing(); -error AuthFailed(); -error NotDispatcher(); - -contract TokenGateway is IIsmpModule { - address admin; - address host; - bytes4 constant IERC6160Ext20ID = 0xbbb8b47e; - - bytes32 constant MINTER_ROLE = keccak256("MINTER ROLE"); - bytes32 constant BURNER_ROLE = keccak256("BURNER ROLE"); - - mapping(uint256 => address) public chains; - mapping(uint256 => address) public tokenIds; - - // auth modifier - modifier auth() { - if (msg.sender != admin) { - revert AuthFailed(); - } - _; - } - - // restricts call to `dispatcher` - modifier onlyDispatcher() { - if (msg.sender != host) { - revert NotDispatcher(); - } - _; - } - - constructor( - address _host, - uint256[] memory _SMids, - address[] memory _SMaddresses, - uint256[] memory _Tids, - address[] memory _Taddresses - ) { - admin = msg.sender; - host = _host; - setStateMachineIds(_SMids, _SMaddresses); - setTokenIds(_Tids, _Taddresses); - } - - // sets the addresses for a given StateMachineId - function setStateMachineIds(uint256[] memory _ids, address[] memory _addresses) public auth { - if (_ids.length != _addresses.length) revert LengthMismatch(); - for (uint256 i = 0; i < _ids.length;) { - address _address = _addresses[i]; - if (_address == address(0)) continue; - chains[_ids[i]] = _addresses[i]; - unchecked { - ++i; - } - } - } - - // sets the Id for a bridge compatible token - function setTokenIds(uint256[] memory _tokenIds, address[] memory _addresses) public auth { - if (_tokenIds.length != _addresses.length) revert LengthMismatch(); - for (uint256 i = 0; i < _tokenIds.length;) { - address _tokenAddress = _addresses[i]; - if (_tokenAddress == address(0)) revert ZeroAddress(); - if (!IERC_ACL_CORE(_tokenAddress).hasRole(BURNER_ROLE, address(this))) revert BurnerRoleMissing(); - if (!IERC_ACL_CORE(_tokenAddress).hasRole(MINTER_ROLE, address(this))) revert MinterRoleMissing(); - if (!IERC165(_tokenAddress).supportsInterface(IERC6160Ext20ID)) revert TokenNotMultiChainNative(); - tokenIds[_tokenIds[i]] = _tokenAddress; - unchecked { - ++i; - } - } - } - - // // // The Gateway contract has to have the roles `MINTER` and `BURNER`. - // function send(bytes memory stateMachine, uint256 tokenId, uint256 amount, address to, bytes memory module) public { - // // USDC -> HyperUSDC(ERC6160) - // address tokenAddress = tokenIds[tokenId]; - - // // check permision at set token. - // IERC6160Ext20(tokenAddress).burn(msg.sender, amount, ""); - // bytes memory data = abi.encodePacked(to, amount, tokenId); - // IIsmpDispatcher(host).dispatch(DispatchRequest(stateMachine, module, data)); - // } - - function onAccept(PostRequest memory request) public onlyDispatcher { - (address to, uint256 amount, uint256 tokenId) = _decodePackedData(request.body); - address tokenAddress = tokenIds[tokenId]; - - IERC6160Ext20(tokenAddress).mint(to, amount, ""); - } - - function onResponse(PostResponse memory response) public onlyDispatcher { - revert("Token gateway doesn't emit responses"); - } - - function onTimeout(PostRequest memory request) public onlyDispatcher { - (address to, uint256 amount, uint256 tokenId) = _decodePackedData(request.body); - address tokenAddress = tokenIds[tokenId]; - - if (tokenAddress == address(0)) revert ZeroAddress(); - - IERC6160Ext20(tokenAddress).mint(to, amount, ""); - } - - function _decodePackedData(bytes memory data) - internal - pure - returns (address to_, uint256 amount_, uint256 tokenId_) - { - assembly { - to_ := div(mload(add(data, 32)), 0x1000000000000000000000000) // hex slicing to get first 20-bytes. - amount_ := mload(add(data, 52)) - tokenId_ := mload(add(data, 84)) - } - } -} +pragma solidity 0.8.17; +// +//// import "../IISMPRouter.sol"; +//import "../interfaces/IISMPModule.sol"; +//import "openzeppelin/utils/introspection/IERC165.sol"; +//import "multichain-token/interfaces/IERC6160Ext20.sol"; +//import {IERC_ACL_CORE} from "multichain-token/interfaces/IERCAclCore.sol"; +//import "../interfaces/IIsmpDispatcher.sol"; +//import "../interfaces/IIsmpHost.sol"; +// +//// +//// Add supports interface for custom bride token +//// +//error LengthMismatch(); +//error ZeroAddress(); +//error TokenNotMultiChainNative(); +//error BurnerRoleMissing(); +//error MinterRoleMissing(); +//error AuthFailed(); +//error NotDispatcher(); +// +//contract TokenGateway is IIsmpModule { +// address admin; +// address host; +// bytes4 constant IERC6160Ext20ID = 0xbbb8b47e; +// +// bytes32 constant MINTER_ROLE = keccak256("MINTER ROLE"); +// bytes32 constant BURNER_ROLE = keccak256("BURNER ROLE"); +// +// mapping(uint256 => address) public chains; +// mapping(uint256 => address) public tokenIds; +// +// // auth modifier +// modifier auth() { +// if (msg.sender != admin) { +// revert AuthFailed(); +// } +// _; +// } +// +// // restricts call to `dispatcher` +// modifier onlyDispatcher() { +// if (msg.sender != host) { +// revert NotDispatcher(); +// } +// _; +// } +// +// constructor( +// address _host, +// uint256[] memory _SMids, +// address[] memory _SMaddresses, +// uint256[] memory _Tids, +// address[] memory _Taddresses +// ) { +// admin = msg.sender; +// host = _host; +// setStateMachineIds(_SMids, _SMaddresses); +// setTokenIds(_Tids, _Taddresses); +// } +// +// // sets the addresses for a given StateMachineId +// function setStateMachineIds(uint256[] memory _ids, address[] memory _addresses) public auth { +// if (_ids.length != _addresses.length) revert LengthMismatch(); +// for (uint256 i = 0; i < _ids.length;) { +// address _address = _addresses[i]; +// if (_address == address(0)) continue; +// chains[_ids[i]] = _addresses[i]; +// unchecked { +// ++i; +// } +// } +// } +// +// // sets the Id for a bridge compatible token +// function setTokenIds(uint256[] memory _tokenIds, address[] memory _addresses) public auth { +// if (_tokenIds.length != _addresses.length) revert LengthMismatch(); +// for (uint256 i = 0; i < _tokenIds.length;) { +// address _tokenAddress = _addresses[i]; +// if (_tokenAddress == address(0)) revert ZeroAddress(); +// if (!IERC_ACL_CORE(_tokenAddress).hasRole(BURNER_ROLE, address(this))) revert BurnerRoleMissing(); +// if (!IERC_ACL_CORE(_tokenAddress).hasRole(MINTER_ROLE, address(this))) revert MinterRoleMissing(); +// if (!IERC165(_tokenAddress).supportsInterface(IERC6160Ext20ID)) revert TokenNotMultiChainNative(); +// tokenIds[_tokenIds[i]] = _tokenAddress; +// unchecked { +// ++i; +// } +// } +// } +// +// // The Gateway contract has to have the roles `MINTER` and `BURNER`. +// function send( +// bytes memory stateMachine, +// uint256 tokenId, +// uint256 amount, +// address to, +// bytes memory module, +// uint64 timestamp, +// uint64 gasLimit +// ) public { +// // USDC -> HyperUSDC(ERC6160) +// address tokenAddress = tokenIds[tokenId]; +// // check permision at set token. +// IERC6160Ext20(tokenAddress).burn(msg.sender, amount, ""); +// bytes memory data = abi.encodePacked(to, amount, tokenId); +// bytes memory source = IIsmpHost(host).host(); +// DispatchPost memory postRequest = DispatchPost({ +// destChain: stateMachine, +// from: source, +// to: module, +// body: data, +// timeoutTimestamp: timestamp, +// gaslimit: gasLimit +// }); +// IIsmpDispatcher(host).dispatch(postRequest); +// } +// +// function onAccept(PostRequest memory request) public onlyDispatcher { +// (address to, uint256 amount, uint256 tokenId) = _decodePackedData(request.body); +// address tokenAddress = tokenIds[tokenId]; +// +// IERC6160Ext20(tokenAddress).mint(to, amount, ""); +// } +// +// function onPostResponse(PostResponse memory response) public view onlyDispatcher { +// revert("Token gateway doesn't emit responses"); +// } +// +// function onPostTimeout(PostRequest memory request) public onlyDispatcher { +// (address to, uint256 amount, uint256 tokenId) = _decodePackedData(request.body); +// address tokenAddress = tokenIds[tokenId]; +// +// if (tokenAddress == address(0)) revert ZeroAddress(); +// +// IERC6160Ext20(tokenAddress).mint(to, amount, ""); +// } +// +// function onGetResponse(GetResponse memory response) public view onlyDispatcher { +// revert("Not implemented"); +// } +// +// function onGetTimeout(GetRequest memory request) public view onlyDispatcher { +// revert("Not implemented"); +// } +// +// function _decodePackedData(bytes memory data) +// internal +// pure +// returns (address to_, uint256 amount_, uint256 tokenId_) +// { +// assembly { +// to_ := div(mload(add(data, 32)), 0x1000000000000000000000000) // hex slicing to get first 20-bytes. +// amount_ := mload(add(data, 52)) +// tokenId_ := mload(add(data, 84)) +// } +// } +//} diff --git a/test/Beefy.sol b/test/Beefy.sol index e52da89..2f861bc 100644 --- a/test/Beefy.sol +++ b/test/Beefy.sol @@ -1,19 +1,24 @@ // SPDX-License-Identifier: UNLICENSED -pragma solidity ^0.8.13; +pragma solidity 0.8.17; import "forge-std/Test.sol"; - -import "../src/consensus/Beefy.sol"; +import "../src/beefy/BeefyV1.sol"; contract BeefyConsensusClientTest is Test { // needs a test method so that forge can detect it function testConsensusClient() public {} - function VerifyV1(BeefyConsensusState memory trustedConsensusState, BeefyConsensusProof memory proof) + BeefyV1 internal beefy; + + function setUp() public virtual { + beefy = new BeefyV1(); + } + + function VerifyV1(bytes memory trustedConsensusState, bytes memory proof) public - returns (BeefyConsensusState memory, IntermediateState[] memory) + returns (bytes memory, IntermediateState[] memory) { - return BeefyConsensusClient.verifyConsensus(trustedConsensusState, proof); + return beefy.verifyConsensus(trustedConsensusState, proof); } function DecodeHeader(bytes memory encoded) public pure returns (Header memory) { diff --git a/test/GetResponse.sol b/test/GetResponse.sol new file mode 100644 index 0000000..0218c6d --- /dev/null +++ b/test/GetResponse.sol @@ -0,0 +1,58 @@ +// SPDX-License-Identifier: UNLICENSED +pragma solidity 0.8.17; + +import "forge-std/Test.sol"; + +import "../src/beefy/BeefyV1.sol"; +import "./TestConsensusClient.sol"; +import "../src/EvmHost.sol"; +import "./TestHost.sol"; +import {MockModule} from "./MockModule.sol"; +import "../src/HandlerV1.sol"; + +contract GetResponseTest is Test { + // needs a test method so that forge can detect it + function testPostResponse() public {} + + IConsensusClient internal consensusClient; + EvmHost internal host; + HandlerV1 internal handler; + address internal testModule; + + function setUp() public virtual { + consensusClient = new TestConsensusClient(); + handler = new HandlerV1(); + + HostParams memory params = HostParams({ + admin: address(0), + crosschainGovernor: address(0), + handler: address(handler), + defaultTimeout: 0, + unStakingPeriod: 5000, + // for this test + challengePeriod: 0, + consensusClient: address(consensusClient), + lastUpdated: 0, + consensusState: new bytes(0) + }); + host = new TestHost(params); + + MockModule test = new MockModule(address(host)); + testModule = address(test); + } + + function module() public view returns (address) { + return testModule; + } + + function GetResponseNoChallengeNoTimeout( + bytes memory consensusProof, + GetRequest memory request, + GetResponseMessage memory message + ) public { + MockModule(testModule).dispatch(request); + handler.handleConsensus(host, consensusProof); + vm.warp(5000); + handler.handleGetResponses(host, message); + } +} diff --git a/test/MockModule.sol b/test/MockModule.sol new file mode 100644 index 0000000..5623914 --- /dev/null +++ b/test/MockModule.sol @@ -0,0 +1,81 @@ +// SPDX-License-Identifier: UNLICENSED +// A Sample ISMP solidity contract for unit tests + +pragma solidity 0.8.17; + +import "../src/interfaces/IIsmpModule.sol"; + +contract MockModule is IIsmpModule { + event PostResponseReceived(); + event GetResponseReceived(); + event PostTimeoutReceived(); + event GetTimeoutReceived(); + event PostReceived(); + + error NotIsmpHost(); + error ExecutionFailed(); + + // restricts call to `IIsmpHost` + modifier onlyIsmpHost() { + if (msg.sender != _host) { + revert NotIsmpHost(); + } + _; + } + + address internal _host; + + constructor(address host) { + _host = host; + } + + function dispatch(PostRequest memory request) public returns (bytes32) { + bytes32 commitment = Message.hash(request); + DispatchPost memory post = DispatchPost({ + body: request.body, + dest: request.dest, + timeout: request.timeoutTimestamp, + to: request.to, + gaslimit: request.gaslimit + }); + IIsmpDispatcher(_host).dispatch(post); + return commitment; + } + + function dispatch(GetRequest memory request) public returns (bytes32) { + bytes32 commitment = Message.hash(request); + DispatchGet memory get = DispatchGet({ + dest: request.dest, + height: request.height, + keys: request.keys, + timeout: request.timeoutTimestamp, + gaslimit: request.gaslimit + }); + IIsmpDispatcher(_host).dispatch(get); + return commitment; + } + + function onAccept(PostRequest memory request) public onlyIsmpHost { + emit PostReceived(); + } + + function onPostResponse(PostResponse memory response) public onlyIsmpHost { + emit PostResponseReceived(); + } + + function onGetResponse(GetResponse memory response) public onlyIsmpHost { + // console.log("key: "); + // console.logBytes(response.values[0].key); + // console.log("value: "); + // console.logBytes(response.values[0].value); + emit GetResponseReceived(); + } + + function onGetTimeout(GetRequest memory request) public onlyIsmpHost { + emit GetTimeoutReceived(); + } + + function onPostTimeout(PostRequest memory request) public onlyIsmpHost { + emit PostTimeoutReceived(); + } +} diff --git a/test/PostRequest.sol b/test/PostRequest.sol new file mode 100644 index 0000000..49edddc --- /dev/null +++ b/test/PostRequest.sol @@ -0,0 +1,53 @@ +// SPDX-License-Identifier: UNLICENSED +pragma solidity 0.8.17; + +import "forge-std/Test.sol"; + +import "../src/beefy/BeefyV1.sol"; +import "./TestConsensusClient.sol"; +import "../src/EvmHost.sol"; +import "./TestHost.sol"; +import {MockModule} from "./MockModule.sol"; +import "../src/HandlerV1.sol"; + +contract PostRequestTest is Test { + // needs a test method so that forge can detect it + function testPostRequest() public {} + + IConsensusClient internal consensusClient; + EvmHost internal host; + HandlerV1 internal handler; + address internal testModule; + + function setUp() public virtual { + consensusClient = new TestConsensusClient(); + handler = new HandlerV1(); + + HostParams memory params = HostParams({ + admin: address(0), + crosschainGovernor: address(0), + handler: address(handler), + defaultTimeout: 5000, + unStakingPeriod: 5000, + // for this test + challengePeriod: 0, + consensusClient: address(consensusClient), + lastUpdated: 0, + consensusState: new bytes(0) + }); + host = new TestHost(params); + + MockModule test = new MockModule(address(host)); + testModule = address(test); + } + + function module() public view returns (address) { + return testModule; + } + + function PostRequestNoChallengeNoTimeout(bytes memory consensusProof, PostRequestMessage memory message) public { + handler.handleConsensus(host, consensusProof); + vm.warp(5000); + handler.handlePostRequests(host, message); + } +} diff --git a/test/PostResponse.sol b/test/PostResponse.sol new file mode 100644 index 0000000..bd286b4 --- /dev/null +++ b/test/PostResponse.sol @@ -0,0 +1,58 @@ +// SPDX-License-Identifier: UNLICENSED +pragma solidity 0.8.17; + +import "forge-std/Test.sol"; + +import "../src/beefy/BeefyV1.sol"; +import "./TestConsensusClient.sol"; +import "../src/EvmHost.sol"; +import "./TestHost.sol"; +import {MockModule} from "./MockModule.sol"; +import "../src/HandlerV1.sol"; + +contract PostResponseTest is Test { + // needs a test method so that forge can detect it + function testPostResponse() public {} + + IConsensusClient internal consensusClient; + EvmHost internal host; + HandlerV1 internal handler; + address internal testModule; + + function setUp() public virtual { + consensusClient = new TestConsensusClient(); + handler = new HandlerV1(); + + HostParams memory params = HostParams({ + admin: address(0), + crosschainGovernor: address(0), + handler: address(handler), + defaultTimeout: 0, + unStakingPeriod: 5000, + // for this test + challengePeriod: 0, + consensusClient: address(consensusClient), + lastUpdated: 0, + consensusState: new bytes(0) + }); + host = new TestHost(params); + + MockModule test = new MockModule(address(host)); + testModule = address(test); + } + + function module() public view returns (address) { + return testModule; + } + + function PostResponseNoChallengeNoTimeout( + bytes memory consensusProof, + PostRequest memory request, + PostResponseMessage memory message + ) public { + MockModule(testModule).dispatch(request); + handler.handleConsensus(host, consensusProof); + vm.warp(5000); + handler.handlePostResponses(host, message); + } +} diff --git a/test/PostTimeout.sol b/test/PostTimeout.sol new file mode 100644 index 0000000..f32935c --- /dev/null +++ b/test/PostTimeout.sol @@ -0,0 +1,58 @@ +// SPDX-License-Identifier: UNLICENSED +pragma solidity 0.8.17; + +import "forge-std/Test.sol"; + +import "../src/beefy/BeefyV1.sol"; +import "./TestConsensusClient.sol"; +import "../src/EvmHost.sol"; +import "./TestHost.sol"; +import {MockModule} from "./MockModule.sol"; +import "../src/HandlerV1.sol"; + +contract PostTimeoutTest is Test { + // needs a test method so that forge can detect it + function testPostTimeout() public {} + + IConsensusClient internal consensusClient; + EvmHost internal host; + HandlerV1 internal handler; + address internal testModule; + + function setUp() public virtual { + consensusClient = new TestConsensusClient(); + handler = new HandlerV1(); + + HostParams memory params = HostParams({ + admin: address(0), + crosschainGovernor: address(0), + handler: address(handler), + defaultTimeout: 0, + unStakingPeriod: 5000, + // for this test + challengePeriod: 0, + consensusClient: address(consensusClient), + lastUpdated: 0, + consensusState: new bytes(0) + }); + host = new TestHost(params); + + MockModule test = new MockModule(address(host)); + testModule = address(test); + } + + function module() public view returns (address) { + return testModule; + } + + function PostTimeoutNoChallenge( + bytes memory consensusProof, + PostRequest memory request, + PostTimeoutMessage memory message + ) public { + MockModule(testModule).dispatch(request); + handler.handleConsensus(host, consensusProof); + vm.warp(5000); + handler.handlePostTimeouts(host, message); + } +} diff --git a/test/TestConsensusClient.sol b/test/TestConsensusClient.sol new file mode 100644 index 0000000..f3e2269 --- /dev/null +++ b/test/TestConsensusClient.sol @@ -0,0 +1,18 @@ +// SPDX-License-Identifier: UNLICENSED +pragma solidity 0.8.17; + +import "../src/interfaces/IConsensusClient.sol"; + +/// Test consensus client, performs no verification +contract TestConsensusClient is IConsensusClient { + function verifyConsensus(bytes memory consensusState, bytes memory proof) + external + returns (bytes memory, IntermediateState[] memory) + { + IntermediateState memory intermediate = abi.decode(proof, (IntermediateState)); + IntermediateState[] memory intermediates = new IntermediateState[](1); + intermediates[0] = intermediate; + + return (consensusState, intermediates); + } +} diff --git a/test/TestHost.sol b/test/TestHost.sol new file mode 100644 index 0000000..ba314eb --- /dev/null +++ b/test/TestHost.sol @@ -0,0 +1,13 @@ +// SPDX-License-Identifier: UNLICENSED +pragma solidity 0.8.17; + +import "../src/EvmHost.sol"; +import "../src/interfaces/StateMachine.sol"; + +contract TestHost is EvmHost { + constructor(HostParams memory params) EvmHost(params) {} + + function host() public override returns (bytes memory) { + return StateMachine.ethereum(); + } +}