diff --git a/.cargo/audit.toml b/.cargo/audit.toml index 0a9b444..7cd2574 100644 --- a/.cargo/audit.toml +++ b/.cargo/audit.toml @@ -3,7 +3,6 @@ ignore = [ # Coming from outdated libp2p and litep2p dependencies from which # some Polkadot libraries are dependent on. They will be updated # once we update Polkadot packages to latest version - "RUSTSEC-2024-0336", "RUSTSEC-2024-0421", "RUSTSEC-2025-0009", "RUSTSEC-2024-0363", # Maybe we should fix the sqlx dependency in our frontier branch @@ -34,6 +33,32 @@ ignore = [ # and in protocols/identify/src/behaviour.rs we can see that there isn't any mutable iterator used for # `lru::LruCache`. # We can conclude that the unsound code is never exercised. + "RUSTSEC-2026-0020", # wasmtime v8.0.1 via sc-executor-wasmtime (polkadot-sdk, cannot upgrade independently). + # https://rustsec.org/advisories/RUSTSEC-2026-0020 -> + # https://github.com/bytecodealliance/wasmtime/security/advisories/GHSA-852m-cvvp-9p4w + # "Wasmtime's implementations of WASIp1 and WASIp2 are affected by this vulnerability." + # We use wasmtime exclusively as a Wasm executor for Substrate PVF/runtime blobs via + # sc-executor-wasmtime. Neither wasmtime-wasi nor any WASI context is present in our + # dependency tree, so we are unaffected. + "RUSTSEC-2026-0021", # wasmtime v8.0.1 via sc-executor-wasmtime (polkadot-sdk, cannot upgrade independently). + # https://rustsec.org/advisories/RUSTSEC-2026-0021 -> + # https://github.com/bytecodealliance/wasmtime/security/advisories/GHSA-243v-98vx-264h + # "Specific to implementations using the wasi:http/types.fields resource in wasmtime-wasi-http." + # We do not use wasmtime-wasi-http (not present in Cargo.lock) — wasmtime is used only for + # Substrate PVF/runtime Wasm execution, so we are unaffected. + "RUSTSEC-2026-0049", # rustls-webpki v0.101.7 and v0.102.8 — transitive via libp2p-websocket/jsonrpsee (polkadot-sdk). + # https://rustsec.org/advisories/RUSTSEC-2026-0049 -> + # https://github.com/advisories/GHSA-pwjx-qhcg-rvj4 + # Faulty CRL distribution point matching causes revocation checks to miss non-first + # distribution points. Only affects code that configures CRL revocation checking. + # We never configure CRL checking (no CRL/revocation usage anywhere in the codebase), + # so revocation status is never queried and the bug cannot be triggered. + # Fix requires rustls-webpki >=0.103.10; we are on 0.101.x/0.102.x pinned by polkadot-sdk. + "RUSTSEC-2026-0037", # quinn-proto v0.10.6 — stale lockfile entry (libp2p-quic -> quinn -> quinn-proto 0.10). + # https://rustsec.org/advisories/RUSTSEC-2026-0037 + # Nothing in the workspace actually depends on this chain (`cargo tree` confirms it). + # It remains in Cargo.lock because Cargo resolves optional dependencies in the lockfile + # (libp2p's optional `quic` feature pulls it in). Cannot be updated: no patched 0.10.x exists. ] informational_warnings = ["unmaintained", "yanked"] diff --git a/Cargo.lock b/Cargo.lock index 051cb08..591d17d 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -2617,9 +2617,9 @@ checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b" [[package]] name = "bytes" -version = "1.10.1" +version = "1.11.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d71b6127be86fdcfddb610f7182ac57211d4b18a3e9c82eb2d17662f2227ad6a" +checksum = "1e748733b7cbc798e1434b6ac524f0c1ff2ab456fe201501e6497c8417a4fc33" dependencies = [ "serde", ] @@ -4340,7 +4340,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8d162beedaa69905488a8da94f5ac3edb4dd4788b732fadb7bd120b2625c1976" dependencies = [ "data-encoding", - "syn 2.0.106", + "syn 1.0.109", ] [[package]] @@ -4901,7 +4901,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "778e2ac28f6c47af28e4907f13ffd1e1ddbd400980a9abd7c8df189bf578a5ad" dependencies = [ "libc", - "windows-sys 0.52.0", + "windows-sys 0.60.2", ] [[package]] @@ -7919,9 +7919,9 @@ dependencies = [ [[package]] name = "keccak" -version = "0.1.5" +version = "0.1.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ecc2af9a1119c51f12a14607e783cb977bde58bc069ff0c3da1095e635d70654" +checksum = "cb26cec98cce3a3d96cbb7bced3c4b16e3d13f27ec56dbd62cbc8f39cfb9d653" dependencies = [ "cpufeatures", ] @@ -8034,7 +8034,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "07033963ba89ebaf1584d767badaa2e8fcec21aedea6b8c0346d487d49c28667" dependencies = [ "cfg-if", - "windows-targets 0.48.5", + "windows-targets 0.53.3", ] [[package]] @@ -9738,9 +9738,9 @@ dependencies = [ [[package]] name = "num-conv" -version = "0.1.0" +version = "0.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "51d515d32fb182ee37cda2ccdcb92950d6a3c2893aa280e540671c2cd0f3b1d9" +checksum = "cf97ec579c3c42f953ef76dbf8d55ac91fb219dde70e49aa4a6b7d74e9919050" [[package]] name = "num-derive" @@ -15249,7 +15249,7 @@ dependencies = [ "once_cell", "socket2 0.6.0", "tracing", - "windows-sys 0.52.0", + "windows-sys 0.60.2", ] [[package]] @@ -16276,7 +16276,7 @@ dependencies = [ "errno", "libc", "linux-raw-sys 0.9.4", - "windows-sys 0.52.0", + "windows-sys 0.60.2", ] [[package]] @@ -16315,7 +16315,7 @@ dependencies = [ "once_cell", "ring 0.17.14", "rustls-pki-types", - "rustls-webpki 0.103.4", + "rustls-webpki 0.103.10", "subtle 2.6.1", "zeroize", ] @@ -16420,7 +16420,7 @@ dependencies = [ "rustls 0.23.31", "rustls-native-certs 0.8.1", "rustls-platform-verifier-android", - "rustls-webpki 0.103.4", + "rustls-webpki 0.103.10", "security-framework 3.3.0", "security-framework-sys", "webpki-root-certs 0.26.11", @@ -16456,9 +16456,9 @@ dependencies = [ [[package]] name = "rustls-webpki" -version = "0.103.4" +version = "0.103.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0a17884ae0c1b773f1ccd2bd4a8c72f16da897310a98b0e84bf349ad5ead92fc" +checksum = "df33b2b81ac578cabaf06b89b0631153a3f416b0a886e8a7a1707fb51abbd1ef" dependencies = [ "ring 0.17.14", "rustls-pki-types", @@ -21033,7 +21033,7 @@ dependencies = [ "getrandom 0.3.3", "once_cell", "rustix 1.0.8", - "windows-sys 0.52.0", + "windows-sys 0.60.2", ] [[package]] @@ -21184,29 +21184,30 @@ dependencies = [ [[package]] name = "time" -version = "0.3.43" +version = "0.3.47" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "83bde6f1ec10e72d583d91623c939f623002284ef622b87de38cfd546cbf2031" +checksum = "743bd48c283afc0388f9b8827b976905fb217ad9e647fae3a379a9283c4def2c" dependencies = [ "deranged", + "itoa", "num-conv", "powerfmt", - "serde", + "serde_core", "time-core", "time-macros", ] [[package]] name = "time-core" -version = "0.1.6" +version = "0.1.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "40868e7c1d2f0b8d73e4a8c7f0ff63af4f6d19be117e90bd73eb1d62cf831c6b" +checksum = "7694e1cfe791f8d31026952abf09c69ca6f6fa4e1a1229e18988f06a04a12dca" [[package]] name = "time-macros" -version = "0.2.24" +version = "0.2.27" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "30cfb0125f12d9c277f35663a0a33f8c30190f4e4574868a330595412d34ebf3" +checksum = "2e70e4c5a0e0a8a4823ad65dfe1a6930e4f4d756dcd9dd7939022b5e8c501215" dependencies = [ "num-conv", "time-core", @@ -22055,6 +22056,7 @@ dependencies = [ "fp-rpc", "fp-self-contained", "frame-benchmarking", + "frame-executive", "frame-support", "frame-system", "frame-system-benchmarking", @@ -22081,7 +22083,6 @@ dependencies = [ "pallet-evm-precompile-simple", "pallet-message-queue", "pallet-multisig", - "pallet-proxy", "pallet-session", "pallet-sudo", "pallet-timestamp", @@ -22903,7 +22904,7 @@ version = "0.1.10" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0978bf7171b3d90bac376700cb56d606feb40f251a475a5d6634613564460b22" dependencies = [ - "windows-sys 0.48.0", + "windows-sys 0.60.2", ] [[package]] diff --git a/runtime/vflow/Cargo.toml b/runtime/vflow/Cargo.toml index 6a4da94..d9eea96 100644 --- a/runtime/vflow/Cargo.toml +++ b/runtime/vflow/Cargo.toml @@ -25,6 +25,7 @@ cfg-if = { workspace = true } # Substrate frame-benchmarking = {workspace = true, optional = true} +frame-executive = {workspace = true} frame-support = {workspace = true} frame-system = {workspace = true} frame-system-benchmarking = {workspace = true, optional = true} @@ -36,7 +37,6 @@ pallet-balances = {workspace = true, features = ["insecure_zero_ed"]} pallet-deployment-permissions = {workspace = true} pallet-message-queue = {workspace = true} pallet-multisig = {workspace = true} -pallet-proxy = {workspace = true} pallet-session = {workspace = true} pallet-collator-selection = {workspace = true} pallet-sudo = {workspace = true} @@ -129,6 +129,7 @@ std = [ "fp-rpc/std", "fp-self-contained/std", "frame-benchmarking?/std", + "frame-executive/std", "frame-support/std", "frame-system-benchmarking?/std", "frame-system-rpc-runtime-api/std", @@ -153,7 +154,6 @@ std = [ "pallet-evm/std", "pallet-message-queue/std", "pallet-multisig/std", - "pallet-proxy/std", "pallet-session/std", "pallet-sudo/std", "pallet-timestamp/std", @@ -209,7 +209,6 @@ runtime-benchmarks = [ "pallet-evm/runtime-benchmarks", "pallet-message-queue/runtime-benchmarks", "pallet-multisig/runtime-benchmarks", - "pallet-proxy/runtime-benchmarks", "pallet-sudo/runtime-benchmarks", "pallet-timestamp/runtime-benchmarks", "pallet-transaction-payment/runtime-benchmarks", @@ -232,6 +231,7 @@ try-runtime = [ "cumulus-pallet-xcm/try-runtime", "cumulus-pallet-xcmp-queue/try-runtime", "fp-self-contained/try-runtime", + "frame-executive/try-runtime", "frame-support/try-runtime", "frame-system/try-runtime", "frame-try-runtime/try-runtime", @@ -246,7 +246,6 @@ try-runtime = [ "pallet-evm/try-runtime", "pallet-message-queue/try-runtime", "pallet-multisig/try-runtime", - "pallet-proxy/try-runtime", "pallet-session/try-runtime", "pallet-sudo/try-runtime", "pallet-timestamp/try-runtime", diff --git a/runtime/vflow/src/benchmark.rs b/runtime/vflow/src/benchmark.rs index c726ee5..8d426f3 100644 --- a/runtime/vflow/src/benchmark.rs +++ b/runtime/vflow/src/benchmark.rs @@ -18,7 +18,6 @@ frame_benchmarking::define_benchmarks!( [frame_system_extensions, SystemExtensionsBench::] [cumulus_pallet_parachain_system, ParachainSystem] [pallet_timestamp, Timestamp] - [pallet_proxy, Proxy] [pallet_utility, Utility] [pallet_multisig, Multisig] [pallet_transaction_payment, TransactionPayment] diff --git a/runtime/vflow/src/configs/ethereum_xcm.rs b/runtime/vflow/src/configs/ethereum_xcm.rs index d9ec881..824b1e6 100644 --- a/runtime/vflow/src/configs/ethereum_xcm.rs +++ b/runtime/vflow/src/configs/ethereum_xcm.rs @@ -15,28 +15,13 @@ //! In this module, we provide the configurations for the ethereum-xcm pallet. -use crate::{ - configs::system::{ProxyType, ReservedXcmpWeight}, - AccountId, BlockNumber, Runtime, RuntimeEvent, -}; -use frame_support::ensure; +use crate::{configs::system::ReservedXcmpWeight, AccountId, Runtime, RuntimeEvent}; use frame_system::EnsureRoot; -use sp_runtime::traits::Zero; pub struct EthereumXcmEnsureProxy; impl xcm_primitives::EnsureProxy for EthereumXcmEnsureProxy { - fn ensure_ok(delegator: AccountId, delegatee: AccountId) -> Result<(), &'static str> { - // The EVM implicitly contains an Any proxy, so we only allow for "Any" proxies - let def: pallet_proxy::ProxyDefinition = - pallet_proxy::Pallet::::find_proxy( - &delegator, - &delegatee, - Some(ProxyType::Any), - ) - .map_err(|_| "proxy error: expected `ProxyType::Any`")?; - // We only allow to use it for delay zero proxies, as the call will immediatly be executed - ensure!(def.delay.is_zero(), "proxy delay is Non-zero`"); - Ok(()) + fn ensure_ok(_delegator: AccountId, _delegatee: AccountId) -> Result<(), &'static str> { + Err("proxy pallet removed") } } diff --git a/runtime/vflow/src/configs/system.rs b/runtime/vflow/src/configs/system.rs index 936c425..742989c 100644 --- a/runtime/vflow/src/configs/system.rs +++ b/runtime/vflow/src/configs/system.rs @@ -28,7 +28,6 @@ use crate::{ AccountId, Aura, Balance, Balances, Block, Hash, MessageQueue, Nonce, OriginCaller, PalletInfo, Runtime, RuntimeCall, RuntimeEvent, RuntimeOrigin, RuntimeTask, XcmpQueue, }; -use core::fmt::Debug; use cumulus_pallet_parachain_system::{ DefaultCoreSelector, ParachainSetCode, RelayNumberMonotonicallyIncreases, }; @@ -36,13 +35,13 @@ use cumulus_primitives_core::AggregateMessageOrigin; use frame_support::{ derive_impl, dispatch::DispatchClass, - pallet_prelude::{ConstU32, Decode, Encode, MaxEncodedLen, TypeInfo}, + pallet_prelude::ConstU32, parameter_types, - traits::{ConstU64, Contains, InstanceFilter}, + traits::{ConstU64, Everything}, }; use frame_system::limits::{BlockLength, BlockWeights}; use polkadot_runtime_common::BlockHashCount; -use sp_runtime::traits::{BlakeTwo256, IdentityLookup}; +use sp_runtime::traits::IdentityLookup; use sp_version::RuntimeVersion; use sp_weights::Weight; @@ -79,23 +78,6 @@ parameter_types! { pub const SS58Prefix: u16 = 0; } -pub struct NormalFilter; -impl Contains for NormalFilter { - fn contains(c: &RuntimeCall) -> bool { - match c { - // We filter anonymous proxy as they make "reserve" inconsistent - // See: https://github.com/paritytech/polkadot-sdk/blob/v1.9.0-rc2/substrate/frame/proxy/src/lib.rs#L260 - RuntimeCall::Proxy(method) => !matches!( - method, - pallet_proxy::Call::create_pure { .. } - | pallet_proxy::Call::kill_pure { .. } - | pallet_proxy::Call::remove_proxies { .. } - ), - _ => true, - } - } -} - /// The default types are being injected by [`derive_impl`](`frame_support::derive_impl`) from /// [`ParaChainDefaultConfig`](`struct@frame_system::config_preludes::ParaChainDefaultConfig`), /// but overridden as needed. @@ -106,7 +88,7 @@ impl frame_system::Config for Runtime { /// The identifier used to distinguish between accounts. type AccountId = AccountId; /// The basic call filter to use in dispatchable. - type BaseCallFilter = NormalFilter; + type BaseCallFilter = Everything; /// The block type. type Block = Block; /// Maximum number of block number to block hash mappings to keep (oldest pruned first). @@ -200,67 +182,3 @@ impl pallet_timestamp::Config for Runtime { type MinimumPeriod = ConstU64<{ SLOT_DURATION / 2 }>; type WeightInfo = weights::pallet_timestamp::ZKVEvmWeight; } - -parameter_types! { - pub const MaxProxies: u32 = 32; - pub const MaxPending: u32 = 32; - pub const ProxyDepositBase: Balance = deposit(1, 40); - pub const AnnouncementDepositBase: Balance = deposit(1, 48); - pub const ProxyDepositFactor: Balance = deposit(0, 33); - pub const AnnouncementDepositFactor: Balance = deposit(0, 66); -} - -/// The type used to represent the kinds of proxying allowed. -/// If you are adding new pallets, consider adding new ProxyType variant -#[derive( - Copy, - Clone, - Decode, - Debug, - Default, - Encode, - Eq, - MaxEncodedLen, - Ord, - PartialEq, - PartialOrd, - TypeInfo, -)] -pub enum ProxyType { - /// Allows to proxy all calls - #[default] - Any, - /// Allows all non-transfer calls - NonTransfer, - /// Allows to finish the proxy - CancelProxy, -} - -impl InstanceFilter for ProxyType { - fn filter(&self, c: &RuntimeCall) -> bool { - match self { - ProxyType::Any => true, - ProxyType::NonTransfer => !matches!(c, RuntimeCall::Balances { .. }), - ProxyType::CancelProxy => matches!( - c, - RuntimeCall::Proxy(pallet_proxy::Call::reject_announcement { .. }) - | RuntimeCall::Multisig { .. } - ), - } - } -} - -impl pallet_proxy::Config for Runtime { - type RuntimeEvent = RuntimeEvent; - type RuntimeCall = RuntimeCall; - type Currency = Balances; - type ProxyType = ProxyType; - type ProxyDepositBase = ProxyDepositBase; - type ProxyDepositFactor = ProxyDepositFactor; - type MaxProxies = MaxProxies; - type WeightInfo = weights::pallet_proxy::ZKVEvmWeight; - type MaxPending = MaxPending; - type CallHasher = BlakeTwo256; - type AnnouncementDepositBase = AnnouncementDepositBase; - type AnnouncementDepositFactor = AnnouncementDepositFactor; -} diff --git a/runtime/vflow/src/lib.rs b/runtime/vflow/src/lib.rs index 2663649..8de75e4 100644 --- a/runtime/vflow/src/lib.rs +++ b/runtime/vflow/src/lib.rs @@ -24,6 +24,7 @@ include!(concat!(env!("OUT_DIR"), "/wasm_binary.rs")); pub mod configs; mod genesis_config_presets; +mod migrations; mod precompiles; pub use precompiles::Precompiles; @@ -203,7 +204,6 @@ construct_runtime!( ParachainSystem: cumulus_pallet_parachain_system = 1, Timestamp: pallet_timestamp = 2, ParachainInfo: parachain_info = 3, // No weight - Proxy: pallet_proxy = 4, Utility: pallet_utility = 5, Multisig: pallet_multisig = 6, diff --git a/runtime/vflow/src/migrations.rs b/runtime/vflow/src/migrations.rs new file mode 100644 index 0000000..0ba5207 --- /dev/null +++ b/runtime/vflow/src/migrations.rs @@ -0,0 +1,25 @@ +// Copyright 2025, Horizen Labs, Inc. + +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. + +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . + +use frame_support::{migrations::RemovePallet, parameter_types}; + +parameter_types! { + pub const ProxyPalletName: &'static str = "Proxy"; +} + +pub type RemoveProxyPallet = + RemovePallet::DbWeight>; + +pub type Migrations = (RemoveProxyPallet,); diff --git a/runtime/vflow/src/tests/constants_test.rs b/runtime/vflow/src/tests/constants_test.rs index c1d6119..fa5246e 100644 --- a/runtime/vflow/src/tests/constants_test.rs +++ b/runtime/vflow/src/tests/constants_test.rs @@ -87,22 +87,6 @@ mod runtime_tests { ); } - #[test] - fn proxy_constants() { - use configs::system::*; - assert_eq!(MaxProxies::get(), 32); - - assert_eq!(MaxPending::get(), 32); - - assert_eq!(ProxyDepositBase::get(), deposit(1, 40)); - - assert_eq!(AnnouncementDepositBase::get(), deposit(1, 48)); - - assert_eq!(ProxyDepositFactor::get(), deposit(0, 33)); - - assert_eq!(AnnouncementDepositFactor::get(), deposit(0, 66)); - } - #[test] fn balances_constants() { use configs::monetary::*; diff --git a/runtime/vflow/src/tests/storage.rs b/runtime/vflow/src/tests/storage.rs index 7de9d34..5d59d28 100644 --- a/runtime/vflow/src/tests/storage.rs +++ b/runtime/vflow/src/tests/storage.rs @@ -30,7 +30,6 @@ fn verify_pallet_prefixes() { assert_pallet_prefix::("ParachainSystem"); assert_pallet_prefix::("Timestamp"); assert_pallet_prefix::("ParachainInfo"); - assert_pallet_prefix::("Proxy"); assert_pallet_prefix::("Balances"); assert_pallet_prefix::("TransactionPayment"); assert_pallet_prefix::("Sudo"); diff --git a/runtime/vflow/src/tests/use_correct_weights.rs b/runtime/vflow/src/tests/use_correct_weights.rs index e56515b..d3a999a 100644 --- a/runtime/vflow/src/tests/use_correct_weights.rs +++ b/runtime/vflow/src/tests/use_correct_weights.rs @@ -65,16 +65,6 @@ fn pallet_timestamp() { ); } -#[test] -fn pallet_proxy() { - use pallet_proxy::WeightInfo; - - assert_eq!( - ::WeightInfo::create_pure(1), - weights::pallet_proxy::ZKVEvmWeight::::create_pure(1) - ); -} - #[test] fn pallet_utility() { use pallet_utility::WeightInfo; diff --git a/runtime/vflow/src/types.rs b/runtime/vflow/src/types.rs index 2f39ee2..3bc7e94 100644 --- a/runtime/vflow/src/types.rs +++ b/runtime/vflow/src/types.rs @@ -34,7 +34,14 @@ pub type SignedPayload = generic::SignedPayload; pub type SignedExtra = ct::SignedExtra; /// Executive: handles dispatch to the various modules. -pub type Executive = ct::Executive; +pub type Executive = frame_executive::Executive< + Runtime, + Block, + frame_system::ChainContext, + Runtime, + AllPalletsWithSystem, + crate::migrations::Migrations, +>; /// Configures the number of blocks that can be created without submission of validity proof to the relay chain pub type ConsensusHook = ct::ConsensusHook; diff --git a/runtime/vflow/src/weights.rs b/runtime/vflow/src/weights.rs index 4d6dc2e..5a9aef4 100644 --- a/runtime/vflow/src/weights.rs +++ b/runtime/vflow/src/weights.rs @@ -29,7 +29,6 @@ pub mod pallet_deployment_permissions; pub mod pallet_evm; pub mod pallet_message_queue; pub mod pallet_multisig; -pub mod pallet_proxy; pub mod pallet_session; pub mod pallet_sudo; pub mod pallet_timestamp; diff --git a/runtime/vflow/src/weights/pallet_proxy.rs b/runtime/vflow/src/weights/pallet_proxy.rs deleted file mode 100644 index e2462b2..0000000 --- a/runtime/vflow/src/weights/pallet_proxy.rs +++ /dev/null @@ -1,216 +0,0 @@ -// Copyright 2024, Horizen Labs, Inc. -// SPDX-License-Identifier: Apache-2.0 - -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -//! Autogenerated weights for `pallet_proxy` -//! -//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 46.2.0 -//! DATE: 2025-06-03, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` -//! WORST CASE MAP SIZE: `1000000` -//! HOSTNAME: `a07377df7860`, CPU: `11th Gen Intel(R) Core(TM) i7-11850H @ 2.50GHz` -//! WASM-EXECUTION: `Compiled`, CHAIN: `None`, DB CACHE: `1024` - -// Executed Command: -// /usr/local/bin/zkv-para-evm-node -// benchmark -// pallet -// --genesis-builder=spec -// --pallet -// pallet-proxy -// --extrinsic -// * -// --steps -// 50 -// --repeat -// 20 -// --heap-pages=4096 -// --header -// /data/benchmark/HEADER-APACHE2 -// --output -// /data/benchmark/runtime/src/weights/pallet_proxy.rs -// --template -// /data/benchmark/scripts/templates/deploy-weight-template.hbs - -#![cfg_attr(rustfmt, rustfmt_skip)] -#![allow(unused_parens)] -#![allow(unused_imports)] -#![allow(missing_docs)] - -use frame_support::{traits::Get, weights::{Weight, constants::RocksDbWeight}}; -use core::marker::PhantomData; - -/// Weights for `pallet_proxy` using the zkVerify node and recommended hardware. -pub struct ZKVEvmWeight(PhantomData); - -impl pallet_proxy::WeightInfo for ZKVEvmWeight { - /// Storage: `Proxy::Proxies` (r:1 w:0) - /// Proof: `Proxy::Proxies` (`max_values`: None, `max_size`: Some(845), added: 3320, mode: `MaxEncodedLen`) - /// The range of component `p` is `[1, 31]`. - fn proxy(_p: u32, ) -> Weight { - // Proof Size summary in bytes: - // Measured: `182 + p * (25 ±0)` - // Estimated: `4310` - // Minimum execution time: 11_631_000 picoseconds. - Weight::from_parts(12_770_462, 4310) - .saturating_add(T::DbWeight::get().reads(1_u64)) - } - /// Storage: `Proxy::Proxies` (r:1 w:0) - /// Proof: `Proxy::Proxies` (`max_values`: None, `max_size`: Some(845), added: 3320, mode: `MaxEncodedLen`) - /// Storage: `Proxy::Announcements` (r:1 w:1) - /// Proof: `Proxy::Announcements` (`max_values`: None, `max_size`: Some(1837), added: 4312, mode: `MaxEncodedLen`) - /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(116), added: 2591, mode: `MaxEncodedLen`) - /// The range of component `a` is `[0, 31]`. - /// The range of component `p` is `[1, 31]`. - fn proxy_announced(a: u32, p: u32, ) -> Weight { - // Proof Size summary in bytes: - // Measured: `434 + a * (56 ±0) + p * (25 ±0)` - // Estimated: `5302` - // Minimum execution time: 32_834_000 picoseconds. - Weight::from_parts(33_256_105, 5302) - // Standard Error: 2_377 - .saturating_add(Weight::from_parts(119_644, 0).saturating_mul(a.into())) - // Standard Error: 2_456 - .saturating_add(Weight::from_parts(26_648, 0).saturating_mul(p.into())) - .saturating_add(T::DbWeight::get().reads(3_u64)) - .saturating_add(T::DbWeight::get().writes(2_u64)) - } - /// Storage: `Proxy::Announcements` (r:1 w:1) - /// Proof: `Proxy::Announcements` (`max_values`: None, `max_size`: Some(1837), added: 4312, mode: `MaxEncodedLen`) - /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(116), added: 2591, mode: `MaxEncodedLen`) - /// The range of component `a` is `[0, 31]`. - /// The range of component `p` is `[1, 31]`. - fn remove_announcement(a: u32, p: u32, ) -> Weight { - // Proof Size summary in bytes: - // Measured: `362 + a * (56 ±0)` - // Estimated: `5302` - // Minimum execution time: 23_636_000 picoseconds. - Weight::from_parts(23_030_983, 5302) - // Standard Error: 3_335 - .saturating_add(Weight::from_parts(160_059, 0).saturating_mul(a.into())) - // Standard Error: 3_446 - .saturating_add(Weight::from_parts(54_307, 0).saturating_mul(p.into())) - .saturating_add(T::DbWeight::get().reads(2_u64)) - .saturating_add(T::DbWeight::get().writes(2_u64)) - } - /// Storage: `Proxy::Announcements` (r:1 w:1) - /// Proof: `Proxy::Announcements` (`max_values`: None, `max_size`: Some(1837), added: 4312, mode: `MaxEncodedLen`) - /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(116), added: 2591, mode: `MaxEncodedLen`) - /// The range of component `a` is `[0, 31]`. - /// The range of component `p` is `[1, 31]`. - fn reject_announcement(a: u32, _p: u32, ) -> Weight { - // Proof Size summary in bytes: - // Measured: `362 + a * (56 ±0)` - // Estimated: `5302` - // Minimum execution time: 23_585_000 picoseconds. - Weight::from_parts(24_611_530, 5302) - // Standard Error: 1_429 - .saturating_add(Weight::from_parts(120_376, 0).saturating_mul(a.into())) - .saturating_add(T::DbWeight::get().reads(2_u64)) - .saturating_add(T::DbWeight::get().writes(2_u64)) - } - /// Storage: `Proxy::Proxies` (r:1 w:0) - /// Proof: `Proxy::Proxies` (`max_values`: None, `max_size`: Some(845), added: 3320, mode: `MaxEncodedLen`) - /// Storage: `Proxy::Announcements` (r:1 w:1) - /// Proof: `Proxy::Announcements` (`max_values`: None, `max_size`: Some(1837), added: 4312, mode: `MaxEncodedLen`) - /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(116), added: 2591, mode: `MaxEncodedLen`) - /// The range of component `a` is `[0, 31]`. - /// The range of component `p` is `[1, 31]`. - fn announce(a: u32, p: u32, ) -> Weight { - // Proof Size summary in bytes: - // Measured: `378 + a * (56 ±0) + p * (25 ±0)` - // Estimated: `5302` - // Minimum execution time: 29_900_000 picoseconds. - Weight::from_parts(30_542_812, 5302) - // Standard Error: 1_780 - .saturating_add(Weight::from_parts(124_929, 0).saturating_mul(a.into())) - // Standard Error: 1_839 - .saturating_add(Weight::from_parts(15_597, 0).saturating_mul(p.into())) - .saturating_add(T::DbWeight::get().reads(3_u64)) - .saturating_add(T::DbWeight::get().writes(2_u64)) - } - /// Storage: `Proxy::Proxies` (r:1 w:1) - /// Proof: `Proxy::Proxies` (`max_values`: None, `max_size`: Some(845), added: 3320, mode: `MaxEncodedLen`) - /// The range of component `p` is `[1, 31]`. - fn add_proxy(p: u32, ) -> Weight { - // Proof Size summary in bytes: - // Measured: `182 + p * (25 ±0)` - // Estimated: `4310` - // Minimum execution time: 20_002_000 picoseconds. - Weight::from_parts(20_729_802, 4310) - // Standard Error: 1_339 - .saturating_add(Weight::from_parts(41_361, 0).saturating_mul(p.into())) - .saturating_add(T::DbWeight::get().reads(1_u64)) - .saturating_add(T::DbWeight::get().writes(1_u64)) - } - /// Storage: `Proxy::Proxies` (r:1 w:1) - /// Proof: `Proxy::Proxies` (`max_values`: None, `max_size`: Some(845), added: 3320, mode: `MaxEncodedLen`) - /// The range of component `p` is `[1, 31]`. - fn remove_proxy(p: u32, ) -> Weight { - // Proof Size summary in bytes: - // Measured: `182 + p * (25 ±0)` - // Estimated: `4310` - // Minimum execution time: 20_264_000 picoseconds. - Weight::from_parts(21_231_396, 4310) - // Standard Error: 1_158 - .saturating_add(Weight::from_parts(21_173, 0).saturating_mul(p.into())) - .saturating_add(T::DbWeight::get().reads(1_u64)) - .saturating_add(T::DbWeight::get().writes(1_u64)) - } - /// Storage: `Proxy::Proxies` (r:1 w:1) - /// Proof: `Proxy::Proxies` (`max_values`: None, `max_size`: Some(845), added: 3320, mode: `MaxEncodedLen`) - /// The range of component `p` is `[1, 31]`. - fn remove_proxies(p: u32, ) -> Weight { - // Proof Size summary in bytes: - // Measured: `182 + p * (25 ±0)` - // Estimated: `4310` - // Minimum execution time: 18_246_000 picoseconds. - Weight::from_parts(19_005_033, 4310) - // Standard Error: 886 - .saturating_add(Weight::from_parts(19_667, 0).saturating_mul(p.into())) - .saturating_add(T::DbWeight::get().reads(1_u64)) - .saturating_add(T::DbWeight::get().writes(1_u64)) - } - /// Storage: `Proxy::Proxies` (r:1 w:1) - /// Proof: `Proxy::Proxies` (`max_values`: None, `max_size`: Some(845), added: 3320, mode: `MaxEncodedLen`) - /// The range of component `p` is `[1, 31]`. - fn create_pure(p: u32, ) -> Weight { - // Proof Size summary in bytes: - // Measured: `194` - // Estimated: `4310` - // Minimum execution time: 21_145_000 picoseconds. - Weight::from_parts(22_014_085, 4310) - // Standard Error: 1_293 - .saturating_add(Weight::from_parts(27_143, 0).saturating_mul(p.into())) - .saturating_add(T::DbWeight::get().reads(1_u64)) - .saturating_add(T::DbWeight::get().writes(1_u64)) - } - /// Storage: `Proxy::Proxies` (r:1 w:1) - /// Proof: `Proxy::Proxies` (`max_values`: None, `max_size`: Some(845), added: 3320, mode: `MaxEncodedLen`) - /// The range of component `p` is `[0, 30]`. - fn kill_pure(p: u32, ) -> Weight { - // Proof Size summary in bytes: - // Measured: `207 + p * (25 ±0)` - // Estimated: `4310` - // Minimum execution time: 19_003_000 picoseconds. - Weight::from_parts(19_743_253, 4310) - // Standard Error: 1_149 - .saturating_add(Weight::from_parts(19_935, 0).saturating_mul(p.into())) - .saturating_add(T::DbWeight::get().reads(1_u64)) - .saturating_add(T::DbWeight::get().writes(1_u64)) - } -}