From 26b109bb82ec3d80cb5a9b33d29d69b1264e8315 Mon Sep 17 00:00:00 2001 From: Muharem Ismailov Date: Thu, 23 Feb 2023 03:24:01 +0100 Subject: [PATCH] Collectives chain xcm filter (#2222) --- .../collectives/collectives-polkadot/src/xcm_config.rs | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/xcm_config.rs b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/xcm_config.rs index a97c767757..4eb123d680 100644 --- a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/xcm_config.rs +++ b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/xcm_config.rs @@ -155,6 +155,9 @@ impl Contains for SafeCallFilter { RuntimeCall::DmpQueue(..) | RuntimeCall::Utility(pallet_utility::Call::as_derivative { .. }) | RuntimeCall::Alliance( + // `init_members` accepts unbounded vecs as arguments, + // but the call can be initiated only by root origin. + pallet_alliance::Call::init_members { .. } | pallet_alliance::Call::vote { .. } | pallet_alliance::Call::close_old_weight { .. } | pallet_alliance::Call::disband { .. } | @@ -175,7 +178,8 @@ impl Contains for SafeCallFilter { pallet_collective::Call::close_old_weight { .. } | pallet_collective::Call::disapprove_proposal { .. } | pallet_collective::Call::close { .. }, - ) => true, + ) | + RuntimeCall::PolkadotXcm(pallet_xcm::Call::force_xcm_version { .. }) => true, _ => false, } }