parity-version: bump beta to 1.11.3 (#8806)
* parity-version: bump beta to 1.11.3
* Disallow unsigned transactions in case EIP-86 is disabled (#8802)
* Disallow unsigned transactions in case EIP-86 is disabled
* Add tests for verification
* Add disallow unsigned transactions test in machine
* Fix ancient blocks queue deadlock (#8751)
* Revert "Fix not downloading old blocks (#8642)"
This reverts commit d1934363e7.
* Make sure only one thread actually imports old blocks.
* Add some trace timers.
* Bring back pending hashes set.
* Separate locks so that queue can happen while we are importing.
* Address grumbles.
This commit is contained in:
@@ -574,7 +574,17 @@ mod tests {
|
||||
nonce: U256::from(2)
|
||||
}.sign(keypair.secret(), None);
|
||||
|
||||
let tr3 = Transaction {
|
||||
action: Action::Call(0x0.into()),
|
||||
value: U256::from(0),
|
||||
data: Bytes::new(),
|
||||
gas: U256::from(30_000),
|
||||
gas_price: U256::from(0),
|
||||
nonce: U256::zero(),
|
||||
}.null_sign(0);
|
||||
|
||||
let good_transactions = [ tr1.clone(), tr2.clone() ];
|
||||
let eip86_transactions = [ tr3.clone() ];
|
||||
|
||||
let diff_inc = U256::from(0x40);
|
||||
|
||||
@@ -610,6 +620,7 @@ mod tests {
|
||||
uncles_rlp.append_list(&good_uncles);
|
||||
let good_uncles_hash = keccak(uncles_rlp.as_raw());
|
||||
let good_transactions_root = ordered_trie_root(good_transactions.iter().map(|t| ::rlp::encode::<UnverifiedTransaction>(t)));
|
||||
let eip86_transactions_root = ordered_trie_root(eip86_transactions.iter().map(|t| ::rlp::encode::<UnverifiedTransaction>(t)));
|
||||
|
||||
let mut parent = good.clone();
|
||||
parent.set_number(9);
|
||||
@@ -630,6 +641,14 @@ mod tests {
|
||||
|
||||
check_ok(basic_test(&create_test_block(&good), engine));
|
||||
|
||||
let mut bad_header = good.clone();
|
||||
bad_header.set_transactions_root(eip86_transactions_root.clone());
|
||||
bad_header.set_uncles_hash(good_uncles_hash.clone());
|
||||
match basic_test(&create_test_block_with_data(&bad_header, &eip86_transactions, &good_uncles), engine) {
|
||||
Err(Error(ErrorKind::Transaction(ref e), _)) if e == &::ethkey::Error::InvalidSignature.into() => (),
|
||||
e => panic!("Block verification failed.\nExpected: Transaction Error (Invalid Signature)\nGot: {:?}", e),
|
||||
}
|
||||
|
||||
let mut header = good.clone();
|
||||
header.set_transactions_root(good_transactions_root.clone());
|
||||
header.set_uncles_hash(good_uncles_hash.clone());
|
||||
|
||||
Reference in New Issue
Block a user