mirror of
https://github.com/serai-dex/serai.git
synced 2025-12-08 04:09:23 +00:00
Ban Serai from setting keys
They were already banned form publishing `Batch`s, yet the ability to set keys enabled changing how certain functionality in the coordinator operated. Removing this malleability ensures operation as expected.
This commit is contained in:
@@ -741,6 +741,11 @@ pub mod pallet {
|
||||
Call::__Ignore(_, _) => unreachable!(),
|
||||
};
|
||||
|
||||
// Don't allow the Serai set to set_keys, as they have no reason to do so
|
||||
if network == &NetworkId::Serai {
|
||||
Err(InvalidTransaction::Custom(0))?;
|
||||
}
|
||||
|
||||
let session = Session(pallet_session::Pallet::<T>::current_index());
|
||||
|
||||
let set = ValidatorSet { session, network: *network };
|
||||
|
||||
Reference in New Issue
Block a user