mirror of
https://github.com/serai-dex/serai.git
synced 2024-12-31 16:09:47 +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:
parent
b018fc432c
commit
25c02c1311
1 changed files with 5 additions and 0 deletions
|
@ -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 };
|
||||
|
|
Loading…
Reference in a new issue