Make signature batching use specialized methods (#6616)

It was a mistake to use the `*_verify` methods for signature batching.
This pr move the signature batching into their own functions. This is
required, because otherwise transaction signature verification infers
with other signature verifications.

This pr also temporarily disables signature batching. The functionality
stays, but we need to make sure that all nodes have the new runtime
interface, before we can bring back signature batching.
This commit is contained in:
Bastian Köcher
2020-07-12 15:43:47 +02:00
committed by GitHub
parent c03f1743c8
commit 8ab23fafdc
3 changed files with 109 additions and 130 deletions
+4 -2
View File
@@ -293,11 +293,13 @@ where
// any initial checks
Self::initial_checks(&block);
let batching_safeguard = sp_runtime::SignatureBatching::start();
let signature_batching = sp_runtime::SignatureBatching::start();
// execute extrinsics
let (header, extrinsics) = block.deconstruct();
Self::execute_extrinsics_with_book_keeping(extrinsics, *header.number());
if !sp_runtime::SignatureBatching::verify(batching_safeguard) {
if !signature_batching.verify() {
panic!("Signature verification failed.");
}