From 81e715a358bce6ac103938e791337900e8a8ed1f Mon Sep 17 00:00:00 2001 From: Miha Stopar Date: Fri, 2 Feb 2024 17:36:00 +0100 Subject: [PATCH] MPT StorageDoesNotExist (#1699) ### Description A couple of `StorageDoesNotExist` issues to be addressed: 1. Witness generation fails for `getProof` proofs of length 0. 2. For `StorageDoesNotExist`, when the trie is empty, the key occupies `33 (33 = 161 - 128)` bytes, as in the example below: ``` [227 161 32 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0] ``` Currently, the length for the RLP items is set `valueLen = 34`, so we don't have space for all 33 bytes. 3. It seems that some constraints of the `StorageDoesNotExist` proof were lost on the way - currently there are only constraints for the `wrong` leaf, but the constraints for the case when the node in branch is `nil` are missing. ### Type of change - [x] Bug fix (non-breaking change which fixes an issue) ### How Has This Been Tested? `TestStorageDoesNotExistOnlySProof` in `mpt-witness-generator/witness/gen_witness_from_infura_blockchain_test.go`. --- mpt-witness-generator/witness/branch.go | 34 +- ...gen_witness_from_infura_blockchain_test.go | 31 + mpt-witness-generator/witness/leaf.go | 12 +- .../witness/modified_extension_node.go | 2 +- .../witness/prepare_witness.go | 50 +- .../src/mpt_circuit/account_leaf.rs | 160 +++- .../src/mpt_circuit/extension_branch.rs | 4 + zkevm-circuits/src/mpt_circuit/helpers.rs | 4 +- .../src/mpt_circuit/storage_leaf.rs | 127 ++- .../tests/StorageDoesNotExistOnlySProof.json | 884 ++++++++++++++++++ zkevm-circuits/src/mpt_circuit/witness_row.rs | 74 +- 11 files changed, 1204 insertions(+), 178 deletions(-) create mode 100644 zkevm-circuits/src/mpt_circuit/tests/StorageDoesNotExistOnlySProof.json diff --git a/mpt-witness-generator/witness/branch.go b/mpt-witness-generator/witness/branch.go index d6deda4abd..9cbe21ea5d 100644 --- a/mpt-witness-generator/witness/branch.go +++ b/mpt-witness-generator/witness/branch.go @@ -65,8 +65,8 @@ func prepareBranchWitness(rows [][]byte, branch []byte, branchStart int, branchR } } -func prepareBranchNode(branch1, branch2, extNode1, extNode2, extListRlpBytes []byte, extValues [][]byte, key, driftedInd, - branchC16, branchC1 byte, isBranchSPlaceholder, isBranchCPlaceholder, isExtension bool) Node { +func prepareBranchNode(branch1, branch2, extNode1, extNode2, extListRlpBytes []byte, extValues [][]byte, key, driftedInd byte, + isBranchSPlaceholder, isBranchCPlaceholder, isExtension bool) Node { extensionNode := ExtensionNode{ ListRlpBytes: extListRlpBytes, } @@ -197,7 +197,7 @@ func addBranchAndPlaceholder(proof1, proof2, leafRow0, key, neighbourNode []byte, keyIndex, extensionNodeInd int, additionalBranch, isAccountProof, nonExistingAccountProof, - isShorterProofLastLeaf bool, branchC16, branchC1 byte, toBeHashed *[][]byte) (bool, bool, int, byte, Node) { + isShorterProofLastLeaf bool, toBeHashed *[][]byte) (bool, bool, int, Node) { len1 := len(proof1) len2 := len(proof2) @@ -211,15 +211,7 @@ func addBranchAndPlaceholder(proof1, proof2, } isExtension := (len1 == len2+2) || (len2 == len1+2) - if !isExtension { - if branchC16 == 1 { - branchC16 = 0 - branchC1 = 1 - } else { - branchC16 = 1 - branchC1 = 0 - } - } else { + if isExtension { var numNibbles byte if len1 > len2 { numNibbles, extListRlpBytes, extValues = prepareExtensions(extNibblesS, extensionNodeInd, proof1[len1-3], proof1[len1-3]) @@ -227,16 +219,6 @@ func addBranchAndPlaceholder(proof1, proof2, numNibbles, extListRlpBytes, extValues = prepareExtensions(extNibblesC, extensionNodeInd, proof2[len2-3], proof2[len2-3]) } numberOfNibbles = int(numNibbles) - - if numberOfNibbles%2 == 0 { - if branchC16 == 1 { - branchC16 = 0 - branchC1 = 1 - } else { - branchC16 = 1 - branchC1 = 0 - } - } } /* @@ -290,8 +272,7 @@ func addBranchAndPlaceholder(proof1, proof2, driftedInd := getDriftedPosition(leafRow0, numberOfNibbles) node = prepareBranchNode(proof1[len1-2], proof1[len1-2], extNode, extNode, extListRlpBytes, extValues, - key[keyIndex+numberOfNibbles], driftedInd, - branchC16, branchC1, false, true, isExtension) + key[keyIndex+numberOfNibbles], driftedInd, false, true, isExtension) // We now get the first nibble of the leaf that was turned into branch. // This first nibble presents the position of the leaf once it moved @@ -303,9 +284,8 @@ func addBranchAndPlaceholder(proof1, proof2, driftedInd := getDriftedPosition(leafRow0, numberOfNibbles) node = prepareBranchNode(proof2[len2-2], proof2[len2-2], extNode, extNode, extListRlpBytes, extValues, - key[keyIndex+numberOfNibbles], driftedInd, - branchC16, branchC1, true, false, isExtension) + key[keyIndex+numberOfNibbles], driftedInd, true, false, isExtension) } - return isModifiedExtNode, isExtension, numberOfNibbles, branchC16, node + return isModifiedExtNode, isExtension, numberOfNibbles, node } diff --git a/mpt-witness-generator/witness/gen_witness_from_infura_blockchain_test.go b/mpt-witness-generator/witness/gen_witness_from_infura_blockchain_test.go index e5ef24741b..d185c77cc0 100644 --- a/mpt-witness-generator/witness/gen_witness_from_infura_blockchain_test.go +++ b/mpt-witness-generator/witness/gen_witness_from_infura_blockchain_test.go @@ -2302,3 +2302,34 @@ func TestWrongAccount(t *testing.T) { prepareWitness("WrongAccount", trieModifications, statedb) } + +func TestStorageDoesNotExistOnlySProof(t *testing.T) { + blockNum := 2000003 + blockNumberParent := big.NewInt(int64(blockNum)) + blockHeaderParent := oracle.PrefetchBlock(blockNumberParent, true, nil) + database := state.NewDatabase(blockHeaderParent) + statedb, _ := state.New(blockHeaderParent.Root, database, nil) + addr := common.HexToAddress("0xcaac46d9bd68bffb533320545a90cd92c6e98e58") + + // Implicitly create account: + trieMod1 := TrieModification{ + Type: BalanceChanged, + Balance: big.NewInt(98), + Address: addr, + } + + key1 := common.HexToHash("0x0000000000000000000000000000000000000000000000000000000000000000") + // leave the same + val1 := common.Hash{} + + trieMod2 := TrieModification{ + Type: StorageDoesNotExist, + Key: key1, + Value: val1, + Address: addr, + } + + trieModifications := []TrieModification{trieMod1, trieMod2} + + prepareWitness("StorageDoesNotExistOnlySProof", trieModifications, statedb) +} diff --git a/mpt-witness-generator/witness/leaf.go b/mpt-witness-generator/witness/leaf.go index 62d69db9ce..95581e4ec8 100644 --- a/mpt-witness-generator/witness/leaf.go +++ b/mpt-witness-generator/witness/leaf.go @@ -14,7 +14,7 @@ func prepareEmptyNonExistingStorageRow() []byte { return nonExistingStorageRow } -func prepareNonExistingStorageRow(leafC, keyNibbles []byte, noLeaf bool) ([]byte, []byte) { +func prepareNonExistingStorageRow(leafC, keyNibbles []byte) ([]byte, []byte) { // nonExistingStorageRow is used only for proof that nothing is stored at a particular storage key nonExistingStorageRow := prepareEmptyNonExistingStorageRow() @@ -307,7 +307,7 @@ func prepareAccountLeafNode(addr common.Address, addrh []byte, leafS, leafC, nei // prepareLeafAndPlaceholderNode prepares a leaf node and its placeholder counterpart // (used when one of the proofs does not have a leaf). -func prepareLeafAndPlaceholderNode(addr common.Address, addrh []byte, proof1, proof2 [][]byte, storage_key common.Hash, key []byte, nonExistingAccountProof, isAccountProof, isSModExtension, isCModExtension bool) Node { +func prepareLeafAndPlaceholderNode(addr common.Address, addrh []byte, proof1, proof2 [][]byte, storage_key common.Hash, key []byte, isAccountProof, isSModExtension, isCModExtension bool) Node { len1 := len(proof1) len2 := len(proof2) @@ -407,7 +407,10 @@ func prepareAccountLeafPlaceholderNode(addr common.Address, addrh, key []byte, k } func prepareStorageLeafPlaceholderNode(storage_key common.Hash, key []byte, keyIndex int) Node { - leaf := make([]byte, valueLen) + // valueLen + 1 because the placeholder leaf in the empty trie occupies 35 bytes: + // [227 161 32 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0] + // 33 (33 = 161 - 128) bytes for path, as in the example above + leaf := make([]byte, valueLen+1) setStorageLeafKeyRLP(&leaf, key, keyIndex) keyLen := getLeafKeyLen(keyIndex) leaf[0] = 192 + 1 + byte(keyLen) + 1 @@ -529,8 +532,7 @@ func prepareStorageLeafNode(leafS, leafC, neighbourNode []byte, storage_key comm var nonExistingStorageRow []byte var wrongRlpBytes []byte if nonExistingStorageProof { - noLeaf := false - wrongRlpBytes, nonExistingStorageRow = prepareNonExistingStorageRow(leafC, key, noLeaf) + wrongRlpBytes, nonExistingStorageRow = prepareNonExistingStorageRow(leafC, key) } else { nonExistingStorageRow = prepareEmptyNonExistingStorageRow() } diff --git a/mpt-witness-generator/witness/modified_extension_node.go b/mpt-witness-generator/witness/modified_extension_node.go index c768b8339e..ae547ceaf5 100644 --- a/mpt-witness-generator/witness/modified_extension_node.go +++ b/mpt-witness-generator/witness/modified_extension_node.go @@ -15,7 +15,7 @@ func equipLeafWithModExtensionNode(statedb *state.StateDB, leafNode Node, addr c key, neighbourNode []byte, keyIndex, extensionNodeInd, numberOfNibbles int, additionalBranch, isAccountProof, nonExistingAccountProof, - isShorterProofLastLeaf bool, branchC16, branchC1 byte, toBeHashed *[][]byte) Node { + isShorterProofLastLeaf bool, toBeHashed *[][]byte) Node { len1 := len(proof1) len2 := len(proof2) diff --git a/mpt-witness-generator/witness/prepare_witness.go b/mpt-witness-generator/witness/prepare_witness.go index d3da7e4cf5..e5df706238 100644 --- a/mpt-witness-generator/witness/prepare_witness.go +++ b/mpt-witness-generator/witness/prepare_witness.go @@ -369,11 +369,18 @@ func convertProofToWitness(statedb *state.StateDB, addr common.Address, addrh [] var nodes []Node - branchC16 := byte(0) - branchC1 := byte(1) for i := 0; i < upTo; i++ { if !isBranch(proof1[i]) { - if i != len1-1 { // extension node + isNonExistingProof := (isAccountProof && nonExistingAccountProof) || (!isAccountProof && nonExistingStorageProof) + areThereNibbles := len(extNibblesS) != 0 || len(extNibblesC) != 0 + // If i < upTo-1, it means it's not a leaf, so it's an extension node. + // There is no any special relation between isNonExistingProof and isExtension, + // except that in the non-existing proof the extension node can appear in `i == upTo-1`. + // For non-existing proof, the last node in the proof could be an extension node (we have + // nil in the underlying branch). For the non-existing proof with the wrong leaf + // (non-existing proofs can be with a nil leaf or with a wrong leaf), + // we don't need to worry because it appears in i = upTo-1). + if (i != upTo-1) || (areThereNibbles && isNonExistingProof) { // extension node var numberOfNibbles byte isExtension = true numberOfNibbles, extListRlpBytes, extValues = prepareExtensions(extNibblesS, extensionNodeInd, proof1[i], proof2[i]) @@ -393,27 +400,6 @@ func convertProofToWitness(statedb *state.StateDB, addr common.Address, addrh [] nodes = append(nodes, node) } else { - switchC16 := true // If not extension node, switchC16 = true. - if isExtension { - keyLen := getExtensionNodeKeyLen(proof1[i-1]) - if keyLen == 1 { - switchC16 = false - } else { - if proof1[i-1][2] != 0 { // If even, switch16 = true. - switchC16 = false - } - } - } - if switchC16 { - if branchC16 == 1 { - branchC16 = 0 - branchC1 = 1 - } else { - branchC16 = 1 - branchC1 = 0 - } - } - var extNode1 []byte = nil var extNode2 []byte = nil if isExtension { @@ -422,7 +408,7 @@ func convertProofToWitness(statedb *state.StateDB, addr common.Address, addrh [] } bNode := prepareBranchNode(proof1[i], proof2[i], extNode1, extNode2, extListRlpBytes, extValues, - key[keyIndex], key[keyIndex], branchC16, branchC1, false, false, isExtension) + key[keyIndex], key[keyIndex], false, false, isExtension) nodes = append(nodes, bNode) keyIndex += 1 @@ -438,10 +424,10 @@ func convertProofToWitness(statedb *state.StateDB, addr common.Address, addrh [] leafRow0 = proof2[len2-1] } - isModifiedExtNode, _, numberOfNibbles, branchC16, bNode := addBranchAndPlaceholder(proof1, proof2, extNibblesS, extNibblesC, + isModifiedExtNode, _, numberOfNibbles, bNode := addBranchAndPlaceholder(proof1, proof2, extNibblesS, extNibblesC, leafRow0, key, neighbourNode, keyIndex, extensionNodeInd, additionalBranch, - isAccountProof, nonExistingAccountProof, isShorterProofLastLeaf, branchC16, branchC1, &toBeHashed) + isAccountProof, nonExistingAccountProof, isShorterProofLastLeaf, &toBeHashed) nodes = append(nodes, bNode) @@ -458,7 +444,7 @@ func convertProofToWitness(statedb *state.StateDB, addr common.Address, addrh [] } else { isCModExtension = true } - leafNode = prepareLeafAndPlaceholderNode(addr, addrh, proof1, proof2, storage_key, key, nonExistingAccountProof, isAccountProof, isSModExtension, isCModExtension) + leafNode = prepareLeafAndPlaceholderNode(addr, addrh, proof1, proof2, storage_key, key, isAccountProof, isSModExtension, isCModExtension) } } else { // Add storage leaf after branch placeholder @@ -472,7 +458,7 @@ func convertProofToWitness(statedb *state.StateDB, addr common.Address, addrh [] } else { isCModExtension = true } - leafNode = prepareLeafAndPlaceholderNode(addr, addrh, proof1, proof2, storage_key, key, nonExistingAccountProof, isAccountProof, isSModExtension, isCModExtension) + leafNode = prepareLeafAndPlaceholderNode(addr, addrh, proof1, proof2, storage_key, key, isAccountProof, isSModExtension, isCModExtension) } } @@ -482,14 +468,14 @@ func convertProofToWitness(statedb *state.StateDB, addr common.Address, addrh [] if isModifiedExtNode { leafNode = equipLeafWithModExtensionNode(statedb, leafNode, addr, proof1, proof2, extNibblesS, extNibblesC, key, neighbourNode, keyIndex, extensionNodeInd, numberOfNibbles, additionalBranch, - isAccountProof, nonExistingAccountProof, isShorterProofLastLeaf, branchC16, branchC1, &toBeHashed) + isAccountProof, nonExistingAccountProof, isShorterProofLastLeaf, &toBeHashed) } nodes = append(nodes, leafNode) } else { - node := prepareLeafAndPlaceholderNode(addr, addrh, proof1, proof2, storage_key, key, nonExistingAccountProof, isAccountProof, false, false) + node := prepareLeafAndPlaceholderNode(addr, addrh, proof1, proof2, storage_key, key, isAccountProof, false, false) nodes = append(nodes, node) } - } else if isBranch(proof2[len(proof2)-1]) { + } else if (len1 == 0 && len2 == 0) || isBranch(proof2[len(proof2)-1]) { // Account proof has drifted leaf as the last row, storage proof has non-existing-storage row // as the last row. // When non existing proof and only the branches are returned, we add a placeholder leaf. diff --git a/zkevm-circuits/src/mpt_circuit/account_leaf.rs b/zkevm-circuits/src/mpt_circuit/account_leaf.rs index 9969f97f29..2b16ff34c7 100644 --- a/zkevm-circuits/src/mpt_circuit/account_leaf.rs +++ b/zkevm-circuits/src/mpt_circuit/account_leaf.rs @@ -1,4 +1,4 @@ -use eth_types::Field; +use eth_types::{Field, U256}; use gadgets::util::{pow, Scalar}; use halo2_proofs::{ circuit::Value, @@ -26,7 +26,7 @@ use crate::{ IsPlaceholderLeafGadget, KeyData, MPTConstraintBuilder, ParentData, WrongGadget, KECCAK, }, - param::{KEY_LEN_IN_NIBBLES, RLP_LIST_LONG, RLP_LONG}, + param::{EMPTY_TRIE_HASH, KEY_LEN_IN_NIBBLES, RLP_LIST_LONG, RLP_LONG}, MPTConfig, MPTContext, MptMemory, RlpItemType, }, table::MPTProofType, @@ -142,9 +142,10 @@ impl AccountLeafConfig { config.is_mod_extension[is_s.idx()] = cb.query_bool(); } + // Constraint 1 config.main_data = MainData::load(cb, &mut ctx.memory[main_memory()], 0.expr()); - // Don't allow an account node to follow an account node + // Constraint 2: Don't allow an account node to follow another account node require!(config.main_data.is_below_account => false); let mut key_rlc = vec![0.expr(); 2]; @@ -157,13 +158,51 @@ impl AccountLeafConfig { let mut value_list_num_bytes = vec![0.expr(); 2]; let parent_data = &mut config.parent_data; + + // Constraint 3: parent_data[0] = ParentData::load(cb, &mut ctx.memory[parent_memory(true)], 0.expr()); + // Constraint 4: parent_data[1] = ParentData::load(cb, &mut ctx.memory[parent_memory(false)], 0.expr()); let key_data = &mut config.key_data; + // Constraint 5: key_data[0] = KeyData::load(cb, &mut ctx.memory[key_memory(true)], 0.expr()); + // Constraint 6: key_data[1] = KeyData::load(cb, &mut ctx.memory[key_memory(false)], 0.expr()); + // Constraint 7: IsEqualGadget using IsZeroGadget to determine the proof type + // Proof types + config.is_non_existing_account_proof = IsEqualGadget::construct( + &mut cb.base, + config.main_data.proof_type.expr(), + MPTProofType::AccountDoesNotExist.expr(), + ); + config.is_account_delete_mod = IsEqualGadget::construct( + &mut cb.base, + config.main_data.proof_type.expr(), + MPTProofType::AccountDestructed.expr(), + ); + config.is_nonce_mod = IsEqualGadget::construct( + &mut cb.base, + config.main_data.proof_type.expr(), + MPTProofType::NonceChanged.expr(), + ); + config.is_balance_mod = IsEqualGadget::construct( + &mut cb.base, + config.main_data.proof_type.expr(), + MPTProofType::BalanceChanged.expr(), + ); + config.is_storage_mod = IsEqualGadget::construct( + &mut cb.base, + config.main_data.proof_type.expr(), + MPTProofType::StorageChanged.expr(), + ); + config.is_codehash_mod = IsEqualGadget::construct( + &mut cb.base, + config.main_data.proof_type.expr(), + MPTProofType::CodeHashChanged.expr(), + ); + for is_s in [true, false] { ifx! {not!(config.is_mod_extension[is_s.idx()].expr()) => { // Placeholder leaf checks @@ -233,11 +272,39 @@ impl AccountLeafConfig { num_nibbles::expr(rlp_key.key_value.len(), key_data[is_s.idx()].is_odd.expr()); require!(key_data[is_s.idx()].num_nibbles.expr() + num_nibbles.expr() => KEY_LEN_IN_NIBBLES); - // Check if the account is in its parent. - // Check is skipped for placeholder leaves which are dummy leaves - ifx! {not!(and::expr(&[not!(parent_data[is_s.idx()].is_placeholder), config.is_placeholder_leaf[is_s.idx()].expr()])) => { + // Check if the leaf is in its parent. + // Check is skipped for placeholder leaves which are dummy leaves. + // Contrary to the storage leaf, the account leaf is always hashed since its length + // is always greater than 32. + // Note that the constraint works for the case when there is the placeholder branch above + // the leaf too - in this case `parent_data.hash` contains the hash of the node above the placeholder + // branch. + ifx! {not!(config.is_placeholder_leaf[is_s.idx()]) => { let hash = parent_data[is_s.idx()].hash.expr(); require!((1.expr(), leaf_rlc, rlp_key.rlp_list.num_bytes(), hash.lo(), hash.hi()) =>> @KECCAK); + } elsex { + // For NonExistingAccountProof prove there is no leaf. + + // When there is only one leaf in the trie, `getProof` will always return this leaf - so we will have + // either the required leaf or the wrong leaf, so for NonExistingAccountProof we don't handle this + // case here (handled by WrongLeaf gadget). + ifx! {config.is_non_existing_account_proof.expr() => { + ifx! {parent_data[is_s.idx()].is_root.expr() => { + // If leaf is placeholder and the parent is root (no branch above leaf) and the proof is NonExistingStorageProof, + // the trie needs to be empty. + let empty_hash = Word::::from(U256::from_big_endian(&EMPTY_TRIE_HASH)); + let hash = parent_data[is_s.idx()].hash.expr(); + require!(hash.lo() => Expression::Constant(empty_hash.lo())); + require!(hash.hi() => Expression::Constant(empty_hash.hi())); + } elsex { + // For NonExistingAccountProof we need to prove that there is nil in the parent branch + // at the `modified_pos` position. + // Note that this does not hold when there is NonExistingAccountProof wrong leaf scenario, + // in this case there is a non-nil leaf. However, in this case the leaf is not a placeholder, + // so the check below is not triggered. + require!(parent_data[is_s.idx()].rlc.expr() => 128.expr()); + }} + }} }} // Check the RLP encoding consistency. @@ -282,38 +349,6 @@ impl AccountLeafConfig { ); }}; - // Proof types - config.is_non_existing_account_proof = IsEqualGadget::construct( - &mut cb.base, - config.main_data.proof_type.expr(), - MPTProofType::AccountDoesNotExist.expr(), - ); - config.is_account_delete_mod = IsEqualGadget::construct( - &mut cb.base, - config.main_data.proof_type.expr(), - MPTProofType::AccountDestructed.expr(), - ); - config.is_nonce_mod = IsEqualGadget::construct( - &mut cb.base, - config.main_data.proof_type.expr(), - MPTProofType::NonceChanged.expr(), - ); - config.is_balance_mod = IsEqualGadget::construct( - &mut cb.base, - config.main_data.proof_type.expr(), - MPTProofType::BalanceChanged.expr(), - ); - config.is_storage_mod = IsEqualGadget::construct( - &mut cb.base, - config.main_data.proof_type.expr(), - MPTProofType::StorageChanged.expr(), - ); - config.is_codehash_mod = IsEqualGadget::construct( - &mut cb.base, - config.main_data.proof_type.expr(), - MPTProofType::CodeHashChanged.expr(), - ); - // Drifted leaf handling config.drifted = DriftedGadget::construct( cb, @@ -426,18 +461,39 @@ impl AccountLeafConfig { let address = address_item.word().compress(); ifx! {not!(config.parent_data[false.idx()].is_placeholder) => { - ctx.mpt_table.constrain( - meta, - &mut cb.base, - address.clone(), - proof_type.clone(), - Word::zero(), - config.main_data.new_root.expr(), - config.main_data.old_root.expr(), - Word::>::new([new_value_lo, new_value_hi]), - Word::>::new([old_value_lo.clone(), old_value_hi.clone()]), - ); + ifx! {not!(config.is_non_existing_account_proof) => { + ctx.mpt_table.constrain( + meta, + &mut cb.base, + address.clone(), + proof_type.clone(), + Word::zero(), + config.main_data.new_root.expr(), + config.main_data.old_root.expr(), + Word::>::new([new_value_lo, new_value_hi]), + Word::>::new([old_value_lo.clone(), old_value_hi.clone()]), + ); + } elsex { + // Non-existing proof doesn't have the value set to 0 in the case of a wrong leaf - we set it to 0 + // below to enable lookups with the value set to 0 (as in the case of a non-wrong non-existing proof). + ctx.mpt_table.constrain( + meta, + &mut cb.base, + address.clone(), + proof_type.clone(), + Word::zero(), + config.main_data.new_root.expr(), + config.main_data.old_root.expr(), + Word::zero(), + Word::zero(), + ); + }}; } elsex { + // When the value is set to 0, the leaf is deleted, and if there were only two leaves in the branch, + // the neighbour leaf moves one level up and replaces the branch. When the lookup is executed with + // the new value set to 0, the lookup fails (without the code below), because the leaf that is returned + // is the neighbour node that moved up (because the branch and the old leaf doesn’t exist anymore), + // but this leaf doesn’t have the zero value. ctx.mpt_table.constrain( meta, &mut cb.base, @@ -688,8 +744,12 @@ impl AccountLeafConfig { } let mut new_value = value[false.idx()]; + let mut old_value = value[true.idx()]; if parent_data[false.idx()].is_placeholder { new_value = word::Word::zero_f(); + } else if is_non_existing_proof { + new_value = word::Word::zero_f(); + old_value = word::Word::zero_f(); } mpt_config.mpt_table.assign_cached( region, @@ -703,7 +763,7 @@ impl AccountLeafConfig { new_root: main_data.new_root.into_value(), old_root: main_data.old_root.into_value(), new_value: new_value.into_value(), - old_value: value[true.idx()].into_value(), + old_value: old_value.into_value(), }, )?; diff --git a/zkevm-circuits/src/mpt_circuit/extension_branch.rs b/zkevm-circuits/src/mpt_circuit/extension_branch.rs index fa69a12f2a..50301fd4f8 100644 --- a/zkevm-circuits/src/mpt_circuit/extension_branch.rs +++ b/zkevm-circuits/src/mpt_circuit/extension_branch.rs @@ -161,6 +161,10 @@ impl ExtensionBranchConfig { Word::zero(), ); } elsex { + // For the placeholder branch / extension node the values did not change, we reuse + // the previous values. These values are used in the leaf after the placeholder branch + // - this way we can use `KeyData` and `ParentData` in the leaf as in the cases of + // the leaf after the non-placeholder branch. KeyData::store( cb, &mut ctx.memory[key_memory(is_s)], diff --git a/zkevm-circuits/src/mpt_circuit/helpers.rs b/zkevm-circuits/src/mpt_circuit/helpers.rs index 44ab29c394..ffdd697504 100644 --- a/zkevm-circuits/src/mpt_circuit/helpers.rs +++ b/zkevm-circuits/src/mpt_circuit/helpers.rs @@ -1222,14 +1222,14 @@ impl WrongGadget { key_value: &RLPItemView, key_rlc: &Expression, expected_item: &RLPItemView, - is_in_empty_tree: Expression, + is_placeholder: Expression, key_data: KeyData, r: &Expression, ) -> Self { let mut config = WrongGadget::default(); circuit!([meta, cb.base], { // Get the previous key data - ifx! {(is_non_existing, not!(is_in_empty_tree)) => { + ifx! {(is_non_existing, not!(is_placeholder)) => { // Calculate the key config.wrong_rlp_key = ListKeyGadget::construct(cb, expected_item); let key_rlc_wrong = key_data.rlc.expr() + config.wrong_rlp_key.key.expr( diff --git a/zkevm-circuits/src/mpt_circuit/storage_leaf.rs b/zkevm-circuits/src/mpt_circuit/storage_leaf.rs index e7edc5393a..83ada89e27 100644 --- a/zkevm-circuits/src/mpt_circuit/storage_leaf.rs +++ b/zkevm-circuits/src/mpt_circuit/storage_leaf.rs @@ -1,4 +1,4 @@ -use eth_types::Field; +use eth_types::{Field, U256}; use gadgets::util::Scalar; use halo2_proofs::{ circuit::Value, @@ -20,7 +20,7 @@ use crate::{ IsPlaceholderLeafGadget, KeyData, MPTConstraintBuilder, MainData, ParentData, ParentDataWitness, KECCAK, }, - param::KEY_LEN_IN_NIBBLES, + param::{EMPTY_TRIE_HASH, KEY_LEN_IN_NIBBLES}, MPTConfig, MPTContext, MptMemory, RlpItemType, }, table::MPTProofType, @@ -116,6 +116,18 @@ impl StorageLeafConfig { key_data[0] = KeyData::load(cb, &mut ctx.memory[key_memory(true)], 0.expr()); key_data[1] = KeyData::load(cb, &mut ctx.memory[key_memory(false)], 0.expr()); + // Proof types + config.is_storage_mod_proof = IsEqualGadget::construct( + &mut cb.base, + config.main_data.proof_type.expr(), + MPTProofType::StorageChanged.expr(), + ); + config.is_non_existing_storage_proof = IsEqualGadget::construct( + &mut cb.base, + config.main_data.proof_type.expr(), + MPTProofType::StorageDoesNotExist.expr(), + ); + for is_s in [true, false] { ifx! {not!(config.is_mod_extension[is_s.idx()].expr()) => { // Placeholder leaf checks @@ -186,18 +198,45 @@ impl StorageLeafConfig { // storage = [key, "value"] require!(rlp_key.rlp_list.len() => key_items[is_s.idx()].num_bytes() + config.rlp_value[is_s.idx()].num_bytes()); - // Check if the account is in its parent. - // Check is skipped for placeholder leaves which are dummy leaves + // Check if the leaf is in its parent. + // Check is skipped for placeholder leaves which are dummy leaves. + // Note that the constraint works for the case when there is the placeholder branch above + // the leaf too - in this case `parent_data.hash` contains the hash of the node above the placeholder + // branch. ifx! {not!(is_placeholder_leaf) => { config.is_not_hashed[is_s.idx()] = LtGadget::construct(&mut cb.base, rlp_key.rlp_list.num_bytes(), 32.expr()); ifx!{or::expr(&[parent_data[is_s.idx()].is_root.expr(), not!(config.is_not_hashed[is_s.idx()])]) => { - // Hashed branch hash in parent branch + // Hashed leaf in parent branch let hash = parent_data[is_s.idx()].hash.expr(); require!((1.expr(), leaf_rlc.expr(), rlp_key.rlp_list.num_bytes(), hash.lo(), hash.hi()) =>> @KECCAK); } elsex { - // Non-hashed branch hash in parent branch + // Non-hashed leaf in parent branch require!(leaf_rlc => parent_data[is_s.idx()].rlc.expr()); }} + } elsex { + // For NonExistingStorageProof prove there is no leaf. + + // When there is only one leaf in the trie, `getProof` will always return this leaf - so we will have + // either the required leaf or the wrong leaf, so for NonExistingStorageProof we don't handle this + // case here (handled by WrongLeaf gadget). + ifx! {config.is_non_existing_storage_proof.expr() => { + ifx! {parent_data[is_s.idx()].is_root.expr() => { + // If leaf is placeholder and the parent is root (no branch above leaf) and the proof is NonExistingStorageProof, + // the trie needs to be empty. + let empty_hash = Word::::from(U256::from_big_endian(&EMPTY_TRIE_HASH)); + let hash = parent_data[is_s.idx()].hash.expr(); + require!(hash.lo() => Expression::Constant(empty_hash.lo())); + require!(hash.hi() => Expression::Constant(empty_hash.hi())); + } elsex { + // For NonExistingStorageProof we need to prove that there is nil in the parent branch + // at the `modified_pos` position. + // Note that this does not hold when there is NonExistingStorageProof wrong leaf scenario, + // in this case there is a non-nil leaf. However, in this case the leaf is not a placeholder, + // so the check below is not triggered. + require!(parent_data[is_s.idx()].rlc.expr() => 128.expr()); + }} + + }} }} }}; @@ -225,18 +264,6 @@ impl StorageLeafConfig { ); }}; - // Proof types - config.is_storage_mod_proof = IsEqualGadget::construct( - &mut cb.base, - config.main_data.proof_type.expr(), - MPTProofType::StorageChanged.expr(), - ); - config.is_non_existing_storage_proof = IsEqualGadget::construct( - &mut cb.base, - config.main_data.proof_type.expr(), - MPTProofType::StorageDoesNotExist.expr(), - ); - // Drifted leaf handling config.drifted = DriftedGadget::construct( cb, @@ -311,19 +338,55 @@ impl StorageLeafConfig { } }}; + ifx! {not!(config.is_non_existing_storage_proof) => { + let key_rlc = ifx!{not!(config.parent_data[true.idx()].is_placeholder) => { + key_rlc[true.idx()].expr() + } elsex { + key_rlc[false.idx()].expr() + }}; + // Check that the key item contains the correct key for the path that was taken + require!(key_item.hash_rlc() => key_rlc); + // Check if the key is correct for the given address + if ctx.params.is_preimage_check_enabled() { + let key = key_item.word(); + require!((1.expr(), address_item.bytes_le()[1..33].rlc(&cb.keccak_r), 32.expr(), key.lo(), key.hi()) =>> @KECCAK); + } + }}; + ifx! {not!(config.parent_data[false.idx()].is_placeholder) => { - ctx.mpt_table.constrain( - meta, - &mut cb.base, - config.main_data.address.expr(), - proof_type.clone(), - address_item.word(), - config.main_data.new_root.expr(), - config.main_data.old_root.expr(), - value_word[false.idx()].clone(), - value_word[true.idx()].clone(), - ); + ifx! {not!(config.is_non_existing_storage_proof) => { + ctx.mpt_table.constrain( + meta, + &mut cb.base, + config.main_data.address.expr(), + proof_type.clone(), + address_item.word(), + config.main_data.new_root.expr(), + config.main_data.old_root.expr(), + value_word[false.idx()].clone(), + value_word[true.idx()].clone(), + ); + } elsex { + // Non-existing proof doesn't have the value set to 0 in the case of a wrong leaf - we set it to 0 + // below to enable lookups with the value set to 0 (as in the case of a non-wrong non-existing proof). + ctx.mpt_table.constrain( + meta, + &mut cb.base, + config.main_data.address.expr(), + proof_type.clone(), + address_item.word(), + config.main_data.new_root.expr(), + config.main_data.old_root.expr(), + Word::>::new([0.expr(), 0.expr()]), + Word::>::new([0.expr(), 0.expr()]), + ); + }}; } elsex { + // When the value is set to 0, the leaf is deleted, and if there were only two leaves in the branch, + // the neighbour leaf moves one level up and replaces the branch. When the lookup is executed with + // the new value set to 0, the lookup fails (without the code below), because the leaf that is returned + // is the neighbour node that moved up (because the branch and the old leaf doesn’t exist anymore), + // but this leaf doesn’t have the zero value. ctx.mpt_table.constrain( meta, &mut cb.base, @@ -531,8 +594,12 @@ impl StorageLeafConfig { } let mut new_value = value_word[false.idx()]; + let mut old_value = value_word[true.idx()]; if parent_data[false.idx()].is_placeholder { new_value = word::Word::zero_f(); + } else if is_non_existing_proof { + new_value = word::Word::zero_f(); + old_value = word::Word::zero_f(); } mpt_config.mpt_table.assign_cached( region, @@ -544,7 +611,7 @@ impl StorageLeafConfig { new_root: main_data.new_root.into_value(), old_root: main_data.old_root.into_value(), new_value: new_value.into_value(), - old_value: value_word[true.idx()].into_value(), + old_value: old_value.into_value(), }, )?; diff --git a/zkevm-circuits/src/mpt_circuit/tests/StorageDoesNotExistOnlySProof.json b/zkevm-circuits/src/mpt_circuit/tests/StorageDoesNotExistOnlySProof.json new file mode 100644 index 0000000000..ad5a9c33e7 --- /dev/null +++ b/zkevm-circuits/src/mpt_circuit/tests/StorageDoesNotExistOnlySProof.json @@ -0,0 +1,884 @@ +[ + { + "start": { + "disable_preimage_check": false, + "proof_type": "BalanceChanged" + }, + "extension_branch": null, + "account": null, + "storage": null, + "mod_extension": null, + "values": [ + "a02523e4607a05d992ffa4a5d5df7490a5531aa30892c5eac6adf86bad2856bb6d00", + "a0caf6653ccaaaa78601ce2fb67faa13084dfc7c2391ef77ead89284a09c02b3ec00" + ], + "keccak_data": [] + }, + { + "start": null, + "extension_branch": { + "is_extension": false, + "is_mod_extension": [ + false, + false + ], + "is_placeholder": [ + false, + false + ], + "extension": { + "list_rlp_bytes": "00000000000000000000000000000000000000000000000000000000000000000000" + }, + "branch": { + "modified_index": 12, + "drifted_index": 12, + "list_rlp_bytes": [ + "f90211", + "f90211" + ] + } + }, + "account": null, + "storage": null, + "mod_extension": null, + "values": [ + "a01d7faae436001d10cf96100d8fb1e13cd4a031d605a96f53c21a64dff0f4629700", + "a072c16366d0bbb992f6d5515a9ff895ee5c6eecfc3cbf34c1e264a8dd934e5a6500", + "a049565dab20afe6ae478427b0356f569865d9f42eda630659c2939d62721e0a7f00", + "a028146412dbe3e474ec9348a726feab497f273a27511776e9d6ff0f8f05a126ac00", + "a0a51cfec42ea9d7a4c3deac3daf2a1b364b01e2f71bdc40af02f738742f5d01ff00", + "a04c023f80d2d18f1a3e4cdc5242bf9e9ae4fe3850e324fa31f6cf0d66eac38af700", + "a052d345bf981d5e996b4bc2906d72a7fd2b30f36fd93146485beb70b46c9c6db800", + "a080a18f6ee76e65d2dde38a13d774f43c7b4205d247f46f9eb1327964dac357b400", + "a0406dc489f30576ba4475cc4d1aedeef4d531e56a52ded0bb6c0d38f601ca9b4a00", + "a0e82e0c5066e06cd1346b0475d2485723f50d5d2f3ea9d085bb0ba6264f286b5000", + "a021ae734f2f6928c9fc4910eb901c4878c87345d6f4fc1288e2f5aa72888db07400", + "a05f2d744390aa2bd1ab7e6244552162a1ebad0f975f551965776742c506ce8bd200", + "a050c4d55e661be3f28a0d41c1e2bfbd6ecc0c7551f606c341de9e6310e9e2c67100", + "a0873b1a534422dbfa2bfafc66b7c0c1f5a283be7d22be10f58b4a3b226e038cd700", + "a07fac0edb04f86c1660a9fbcf361686c59608f142482f7b0c1b60ebf433c698f400", + "a0d3841ee2a7ff3cedbe4ef083217f87d3cc285261adebd3304029ecc09f080d3800", + "a0765f7869c81a6518af91dfa6feccaff661551eae3c7e6eec1d1e376c9c46ec0d00", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000" + ], + "keccak_data": [ + "f90211a072c16366d0bbb992f6d5515a9ff895ee5c6eecfc3cbf34c1e264a8dd934e5a65a049565dab20afe6ae478427b0356f569865d9f42eda630659c2939d62721e0a7fa028146412dbe3e474ec9348a726feab497f273a27511776e9d6ff0f8f05a126aca0a51cfec42ea9d7a4c3deac3daf2a1b364b01e2f71bdc40af02f738742f5d01ffa04c023f80d2d18f1a3e4cdc5242bf9e9ae4fe3850e324fa31f6cf0d66eac38af7a052d345bf981d5e996b4bc2906d72a7fd2b30f36fd93146485beb70b46c9c6db8a080a18f6ee76e65d2dde38a13d774f43c7b4205d247f46f9eb1327964dac357b4a0406dc489f30576ba4475cc4d1aedeef4d531e56a52ded0bb6c0d38f601ca9b4aa0e82e0c5066e06cd1346b0475d2485723f50d5d2f3ea9d085bb0ba6264f286b50a021ae734f2f6928c9fc4910eb901c4878c87345d6f4fc1288e2f5aa72888db074a05f2d744390aa2bd1ab7e6244552162a1ebad0f975f551965776742c506ce8bd2a050c4d55e661be3f28a0d41c1e2bfbd6ecc0c7551f606c341de9e6310e9e2c671a0873b1a534422dbfa2bfafc66b7c0c1f5a283be7d22be10f58b4a3b226e038cd7a07fac0edb04f86c1660a9fbcf361686c59608f142482f7b0c1b60ebf433c698f4a0d3841ee2a7ff3cedbe4ef083217f87d3cc285261adebd3304029ecc09f080d38a0765f7869c81a6518af91dfa6feccaff661551eae3c7e6eec1d1e376c9c46ec0d80", + "f90211a072c16366d0bbb992f6d5515a9ff895ee5c6eecfc3cbf34c1e264a8dd934e5a65a049565dab20afe6ae478427b0356f569865d9f42eda630659c2939d62721e0a7fa028146412dbe3e474ec9348a726feab497f273a27511776e9d6ff0f8f05a126aca0a51cfec42ea9d7a4c3deac3daf2a1b364b01e2f71bdc40af02f738742f5d01ffa04c023f80d2d18f1a3e4cdc5242bf9e9ae4fe3850e324fa31f6cf0d66eac38af7a052d345bf981d5e996b4bc2906d72a7fd2b30f36fd93146485beb70b46c9c6db8a080a18f6ee76e65d2dde38a13d774f43c7b4205d247f46f9eb1327964dac357b4a0406dc489f30576ba4475cc4d1aedeef4d531e56a52ded0bb6c0d38f601ca9b4aa0e82e0c5066e06cd1346b0475d2485723f50d5d2f3ea9d085bb0ba6264f286b50a021ae734f2f6928c9fc4910eb901c4878c87345d6f4fc1288e2f5aa72888db074a05f2d744390aa2bd1ab7e6244552162a1ebad0f975f551965776742c506ce8bd2a050c4d55e661be3f28a0d41c1e2bfbd6ecc0c7551f606c341de9e6310e9e2c671a01d7faae436001d10cf96100d8fb1e13cd4a031d605a96f53c21a64dff0f46297a07fac0edb04f86c1660a9fbcf361686c59608f142482f7b0c1b60ebf433c698f4a0d3841ee2a7ff3cedbe4ef083217f87d3cc285261adebd3304029ecc09f080d38a0765f7869c81a6518af91dfa6feccaff661551eae3c7e6eec1d1e376c9c46ec0d80" + ] + }, + { + "start": null, + "extension_branch": { + "is_extension": false, + "is_mod_extension": [ + false, + false + ], + "is_placeholder": [ + false, + false + ], + "extension": { + "list_rlp_bytes": "00000000000000000000000000000000000000000000000000000000000000000000" + }, + "branch": { + "modified_index": 8, + "drifted_index": 8, + "list_rlp_bytes": [ + "f90211", + "f90211" + ] + } + }, + "account": null, + "storage": null, + "mod_extension": null, + "values": [ + "a0ae8a9a65f35ae639ed37965d8a252d2b4da7bf9d631c02e32ce88247964e636900", + "a0f3cdaf60d79fb61e893b369b710937ac23e0c2847bcbccff7009922d4db5bd0100", + "a0fce77948227c2a286b84ef12e23e853388bb8b12f72fd9bf0a84e92f63164e5300", + "a039e92b76a5aec3250c46b68db0534c0b7730026a91299f4144ae2124536000cf00", + "a0f987345194d91423f8dfcda5412ef4a12464835103a26c2822f848d194cb4bfa00", + "a04bea5e4005db61e7bef013096cd5e23a29b0595f2f9daa8ac9bc76f9e4c3adb100", + "a0695a7fbb5ad5107fb1de0c1530caa5fa73628c4100052c13e4f21859f110f31100", + "a03d98d4f7fbdaf32ef9aa992a70209a1cf7a85e746704dc3248f8c1ebbdaa08bb00", + "a06388fe7b966ff5e278f29526c5c2e4ed1e2c11016d6ec1e437a37d3223ff90ec00", + "a084b502688ae04d0b474585c2ad50dbcfa0df26b7ceb09732e3d242fb854c5ab700", + "a08d42490450e1385bdfef861f41d597d2693f4c2b5c4e1a8751b2096185f1d36400", + "a0ed9ee1e21920ec422f026b70439d6cfa0e7b3992b482e7591909eec6ddf751b400", + "a01bd96f3d6fc795e66d82116ddef3d38865bafa04e426c1b51e446d38b79dc3a100", + "a0910782b346b7dcd82c6709ec62ef1f13aa487576ddd5cb8019f0201fe15ef00900", + "a0491b867e5a84cf4046b39a78315504d529feda45cab7f99e1f6f3101bdf00c8900", + "a034f545d3a349cfb6c8098c638f87d7b2a14706400544d743187afcb337b9b9d000", + "a057994926d9422d5d969fffc0b2677cdb6e289b86625219fede0bc84421e4db0600", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000" + ], + "keccak_data": [ + "f90211a0f3cdaf60d79fb61e893b369b710937ac23e0c2847bcbccff7009922d4db5bd01a0fce77948227c2a286b84ef12e23e853388bb8b12f72fd9bf0a84e92f63164e53a039e92b76a5aec3250c46b68db0534c0b7730026a91299f4144ae2124536000cfa0f987345194d91423f8dfcda5412ef4a12464835103a26c2822f848d194cb4bfaa04bea5e4005db61e7bef013096cd5e23a29b0595f2f9daa8ac9bc76f9e4c3adb1a0695a7fbb5ad5107fb1de0c1530caa5fa73628c4100052c13e4f21859f110f311a03d98d4f7fbdaf32ef9aa992a70209a1cf7a85e746704dc3248f8c1ebbdaa08bba06388fe7b966ff5e278f29526c5c2e4ed1e2c11016d6ec1e437a37d3223ff90eca084b502688ae04d0b474585c2ad50dbcfa0df26b7ceb09732e3d242fb854c5ab7a08d42490450e1385bdfef861f41d597d2693f4c2b5c4e1a8751b2096185f1d364a0ed9ee1e21920ec422f026b70439d6cfa0e7b3992b482e7591909eec6ddf751b4a01bd96f3d6fc795e66d82116ddef3d38865bafa04e426c1b51e446d38b79dc3a1a0910782b346b7dcd82c6709ec62ef1f13aa487576ddd5cb8019f0201fe15ef009a0491b867e5a84cf4046b39a78315504d529feda45cab7f99e1f6f3101bdf00c89a034f545d3a349cfb6c8098c638f87d7b2a14706400544d743187afcb337b9b9d0a057994926d9422d5d969fffc0b2677cdb6e289b86625219fede0bc84421e4db0680", + "f90211a0f3cdaf60d79fb61e893b369b710937ac23e0c2847bcbccff7009922d4db5bd01a0fce77948227c2a286b84ef12e23e853388bb8b12f72fd9bf0a84e92f63164e53a039e92b76a5aec3250c46b68db0534c0b7730026a91299f4144ae2124536000cfa0f987345194d91423f8dfcda5412ef4a12464835103a26c2822f848d194cb4bfaa04bea5e4005db61e7bef013096cd5e23a29b0595f2f9daa8ac9bc76f9e4c3adb1a0695a7fbb5ad5107fb1de0c1530caa5fa73628c4100052c13e4f21859f110f311a03d98d4f7fbdaf32ef9aa992a70209a1cf7a85e746704dc3248f8c1ebbdaa08bba06388fe7b966ff5e278f29526c5c2e4ed1e2c11016d6ec1e437a37d3223ff90eca0ae8a9a65f35ae639ed37965d8a252d2b4da7bf9d631c02e32ce88247964e6369a08d42490450e1385bdfef861f41d597d2693f4c2b5c4e1a8751b2096185f1d364a0ed9ee1e21920ec422f026b70439d6cfa0e7b3992b482e7591909eec6ddf751b4a01bd96f3d6fc795e66d82116ddef3d38865bafa04e426c1b51e446d38b79dc3a1a0910782b346b7dcd82c6709ec62ef1f13aa487576ddd5cb8019f0201fe15ef009a0491b867e5a84cf4046b39a78315504d529feda45cab7f99e1f6f3101bdf00c89a034f545d3a349cfb6c8098c638f87d7b2a14706400544d743187afcb337b9b9d0a057994926d9422d5d969fffc0b2677cdb6e289b86625219fede0bc84421e4db0680" + ] + }, + { + "start": null, + "extension_branch": { + "is_extension": false, + "is_mod_extension": [ + false, + false + ], + "is_placeholder": [ + false, + false + ], + "extension": { + "list_rlp_bytes": "00000000000000000000000000000000000000000000000000000000000000000000" + }, + "branch": { + "modified_index": 5, + "drifted_index": 5, + "list_rlp_bytes": [ + "f90211", + "f90211" + ] + } + }, + "account": null, + "storage": null, + "mod_extension": null, + "values": [ + "a0335f88c3426aac199fed5e159ed2cf7f9f1a62f93d3a47204773364d06e6508b00", + "a0643223afd2cdf8850275b8fefeda7aa35da0c26ef0c39c60cfb1e24cc52762c100", + "a0d3e07435e99ae94fa784d0b48f7955cc327f3283c54728a0f0657e9873d4aa7600", + "a031cdb1d9522f06bc78049c39940f21a511531017c651f00d53cca82c0b6f34b200", + "a01ec8ea4b4424cf744e29c7d218af2dfe9140256e58171305ab1472bd2df95afb00", + "a02c69884acac1b6212b90cdd721b88dcfe9b00c2ccbf411d5e9ecdda90f93c23400", + "a0e89d484463e0251b72bb36be031c1182e81685bf852f637a2c8fd74f2f1edc4900", + "a01c190836d2eca2384e06b124b900da5aa4ab874ab762c06342600aa8c34c07d300", + "a0a7d794c34193c548e12e2089d9109e25d3d1b13f87be3be358412b6ea906e4cd00", + "a0176b3d097548b67aa6dd67f4311323285f773fa5bc64894515fb1fb40fe1b87c00", + "a0add35369e46f48b4fffcee149bbd8e780bd8dcf784c6bb4da5d371742a439ff200", + "a0d4c92afc344f8c1fed0a3a9a0973e0e2af3a9e92f6c11b041c1c4839b4c04f4700", + "a083a4cfd6d2fac8a31b13d1723323be55233091ad3d280637084983a8531d326600", + "a0b1eafa8ec6b94928b4ac69306d1ea447cab455a023bdd31c1b7c667265aec99800", + "a074f76c46d44c70a53fb64d3801444d9739854e7af0ba12749864929e0f3466a900", + "a037d17318bd52b12c443d1c609a64646fad41e1d5a6a9e5f46f1bb6c2b4a9f9a400", + "a03f855b509146866d83d593409f9c0f95f0c49a22ec5d86b4b9d0adb930425ef100", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000" + ], + "keccak_data": [ + "f90211a0643223afd2cdf8850275b8fefeda7aa35da0c26ef0c39c60cfb1e24cc52762c1a0d3e07435e99ae94fa784d0b48f7955cc327f3283c54728a0f0657e9873d4aa76a031cdb1d9522f06bc78049c39940f21a511531017c651f00d53cca82c0b6f34b2a01ec8ea4b4424cf744e29c7d218af2dfe9140256e58171305ab1472bd2df95afba02c69884acac1b6212b90cdd721b88dcfe9b00c2ccbf411d5e9ecdda90f93c234a0e89d484463e0251b72bb36be031c1182e81685bf852f637a2c8fd74f2f1edc49a01c190836d2eca2384e06b124b900da5aa4ab874ab762c06342600aa8c34c07d3a0a7d794c34193c548e12e2089d9109e25d3d1b13f87be3be358412b6ea906e4cda0176b3d097548b67aa6dd67f4311323285f773fa5bc64894515fb1fb40fe1b87ca0add35369e46f48b4fffcee149bbd8e780bd8dcf784c6bb4da5d371742a439ff2a0d4c92afc344f8c1fed0a3a9a0973e0e2af3a9e92f6c11b041c1c4839b4c04f47a083a4cfd6d2fac8a31b13d1723323be55233091ad3d280637084983a8531d3266a0b1eafa8ec6b94928b4ac69306d1ea447cab455a023bdd31c1b7c667265aec998a074f76c46d44c70a53fb64d3801444d9739854e7af0ba12749864929e0f3466a9a037d17318bd52b12c443d1c609a64646fad41e1d5a6a9e5f46f1bb6c2b4a9f9a4a03f855b509146866d83d593409f9c0f95f0c49a22ec5d86b4b9d0adb930425ef180", + "f90211a0643223afd2cdf8850275b8fefeda7aa35da0c26ef0c39c60cfb1e24cc52762c1a0d3e07435e99ae94fa784d0b48f7955cc327f3283c54728a0f0657e9873d4aa76a031cdb1d9522f06bc78049c39940f21a511531017c651f00d53cca82c0b6f34b2a01ec8ea4b4424cf744e29c7d218af2dfe9140256e58171305ab1472bd2df95afba02c69884acac1b6212b90cdd721b88dcfe9b00c2ccbf411d5e9ecdda90f93c234a0335f88c3426aac199fed5e159ed2cf7f9f1a62f93d3a47204773364d06e6508ba01c190836d2eca2384e06b124b900da5aa4ab874ab762c06342600aa8c34c07d3a0a7d794c34193c548e12e2089d9109e25d3d1b13f87be3be358412b6ea906e4cda0176b3d097548b67aa6dd67f4311323285f773fa5bc64894515fb1fb40fe1b87ca0add35369e46f48b4fffcee149bbd8e780bd8dcf784c6bb4da5d371742a439ff2a0d4c92afc344f8c1fed0a3a9a0973e0e2af3a9e92f6c11b041c1c4839b4c04f47a083a4cfd6d2fac8a31b13d1723323be55233091ad3d280637084983a8531d3266a0b1eafa8ec6b94928b4ac69306d1ea447cab455a023bdd31c1b7c667265aec998a074f76c46d44c70a53fb64d3801444d9739854e7af0ba12749864929e0f3466a9a037d17318bd52b12c443d1c609a64646fad41e1d5a6a9e5f46f1bb6c2b4a9f9a4a03f855b509146866d83d593409f9c0f95f0c49a22ec5d86b4b9d0adb930425ef180" + ] + }, + { + "start": null, + "extension_branch": { + "is_extension": false, + "is_mod_extension": [ + false, + false + ], + "is_placeholder": [ + false, + false + ], + "extension": { + "list_rlp_bytes": "00000000000000000000000000000000000000000000000000000000000000000000" + }, + "branch": { + "modified_index": 6, + "drifted_index": 6, + "list_rlp_bytes": [ + "f90211", + "f90211" + ] + } + }, + "account": null, + "storage": null, + "mod_extension": null, + "values": [ + "a0cdb89f2e65e49e662f7f831085ce0573deb7f3dbcf1597a55c9c0c9e420c6ede00", + "a00dffd4fc7a7acbd11a09ab1a28fad6ce37a9d446dfb9ebf6be429bf800f45b0200", + "a0ea85244fcbe9cc89739872c5ed66efc8f67d331dfa18723e22948d0bc0e8cc7900", + "a02af9d9b113e3dd75c3544b71c112f9a14bd194cccb625bb9ee139c9fee95686a00", + "a0ff3ceb58292c96600ca5b75a541fde654b8d4d8950fbec1b5d26181f8ffb49d400", + "a03f4278f130a38121d771d6ab937d9ecb458596c6ecb60cab6cb4fbfae6d1d39d00", + "a0fec61d1f7a1c8224272521d7be099e7ad7e2e61d1021866c5e12ea01f47f934b00", + "a01dfa50994defea72ee8fe405f68f5d7c7e246cc871fb194ed69977e9095b03bb00", + "a0bf00c6c27397c5b9c3e6e2bc5545d74d1ad6eaa1443f88942a26a9e37a6207b400", + "a06518755c2762ea97b58027e8843c110ddbcd2f6a07e4d239c72386f1fc77edb700", + "a08f15a73b5cbc8f2da22ec5303993b971e96e72407145a76fe327dea836226f8f00", + "a040222473c2e4aaaa15d7806aec12e22cc0b64ecf44f47af45b9a0dfd72d1b77f00", + "a081c0a354ff213fed635c58e5c3b09774374bc72811386af11e8f3716bc8e08f300", + "a0003b48aebee15ad11ab9f4e0dfe94b54122261fe23e7ed056aca36f2123eb34400", + "a028c4fe56d5638df2d3b202c7332c748272fe84d9462c534128f68612c389138d00", + "a0e064b6c149ebf5772b53b33423d2d5cf9bd8565db4d76c7f8e3a7474025b324000", + "a01f4af370ae8e26ec0c81df057a2a53fbcf5824854e5f6a9253509539bbb277db00", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000" + ], + "keccak_data": [ + "f90211a00dffd4fc7a7acbd11a09ab1a28fad6ce37a9d446dfb9ebf6be429bf800f45b02a0ea85244fcbe9cc89739872c5ed66efc8f67d331dfa18723e22948d0bc0e8cc79a02af9d9b113e3dd75c3544b71c112f9a14bd194cccb625bb9ee139c9fee95686aa0ff3ceb58292c96600ca5b75a541fde654b8d4d8950fbec1b5d26181f8ffb49d4a03f4278f130a38121d771d6ab937d9ecb458596c6ecb60cab6cb4fbfae6d1d39da0fec61d1f7a1c8224272521d7be099e7ad7e2e61d1021866c5e12ea01f47f934ba01dfa50994defea72ee8fe405f68f5d7c7e246cc871fb194ed69977e9095b03bba0bf00c6c27397c5b9c3e6e2bc5545d74d1ad6eaa1443f88942a26a9e37a6207b4a06518755c2762ea97b58027e8843c110ddbcd2f6a07e4d239c72386f1fc77edb7a08f15a73b5cbc8f2da22ec5303993b971e96e72407145a76fe327dea836226f8fa040222473c2e4aaaa15d7806aec12e22cc0b64ecf44f47af45b9a0dfd72d1b77fa081c0a354ff213fed635c58e5c3b09774374bc72811386af11e8f3716bc8e08f3a0003b48aebee15ad11ab9f4e0dfe94b54122261fe23e7ed056aca36f2123eb344a028c4fe56d5638df2d3b202c7332c748272fe84d9462c534128f68612c389138da0e064b6c149ebf5772b53b33423d2d5cf9bd8565db4d76c7f8e3a7474025b3240a01f4af370ae8e26ec0c81df057a2a53fbcf5824854e5f6a9253509539bbb277db80", + "f90211a00dffd4fc7a7acbd11a09ab1a28fad6ce37a9d446dfb9ebf6be429bf800f45b02a0ea85244fcbe9cc89739872c5ed66efc8f67d331dfa18723e22948d0bc0e8cc79a02af9d9b113e3dd75c3544b71c112f9a14bd194cccb625bb9ee139c9fee95686aa0ff3ceb58292c96600ca5b75a541fde654b8d4d8950fbec1b5d26181f8ffb49d4a03f4278f130a38121d771d6ab937d9ecb458596c6ecb60cab6cb4fbfae6d1d39da0fec61d1f7a1c8224272521d7be099e7ad7e2e61d1021866c5e12ea01f47f934ba0cdb89f2e65e49e662f7f831085ce0573deb7f3dbcf1597a55c9c0c9e420c6edea0bf00c6c27397c5b9c3e6e2bc5545d74d1ad6eaa1443f88942a26a9e37a6207b4a06518755c2762ea97b58027e8843c110ddbcd2f6a07e4d239c72386f1fc77edb7a08f15a73b5cbc8f2da22ec5303993b971e96e72407145a76fe327dea836226f8fa040222473c2e4aaaa15d7806aec12e22cc0b64ecf44f47af45b9a0dfd72d1b77fa081c0a354ff213fed635c58e5c3b09774374bc72811386af11e8f3716bc8e08f3a0003b48aebee15ad11ab9f4e0dfe94b54122261fe23e7ed056aca36f2123eb344a028c4fe56d5638df2d3b202c7332c748272fe84d9462c534128f68612c389138da0e064b6c149ebf5772b53b33423d2d5cf9bd8565db4d76c7f8e3a7474025b3240a01f4af370ae8e26ec0c81df057a2a53fbcf5824854e5f6a9253509539bbb277db80" + ] + }, + { + "start": null, + "extension_branch": { + "is_extension": false, + "is_mod_extension": [ + false, + false + ], + "is_placeholder": [ + false, + false + ], + "extension": { + "list_rlp_bytes": "00000000000000000000000000000000000000000000000000000000000000000000" + }, + "branch": { + "modified_index": 12, + "drifted_index": 12, + "list_rlp_bytes": [ + "f8d1", + "f8d1" + ] + } + }, + "account": null, + "storage": null, + "mod_extension": null, + "values": [ + "a0b0375763c9c490c555bf594dc13ecf3e63003a136a5bada92ee4f48197c73c2d00", + "80000000000000000000000000000000000000000000000000000000000000000000", + "a034e0097d64dedfd3ecaff0702de289c4110f5b7b8243d49e8ea7969682c5b17a00", + "80000000000000000000000000000000000000000000000000000000000000000000", + "a07da532ec5da228b88092a7102ba227acb97d8295949c33d7c207ea1d95771cb200", + "80000000000000000000000000000000000000000000000000000000000000000000", + "80000000000000000000000000000000000000000000000000000000000000000000", + "80000000000000000000000000000000000000000000000000000000000000000000", + "a035f5e68adcf50eaa023741ba9d02a53ec950464f04cf8063f22eaa3f965d36e600", + "80000000000000000000000000000000000000000000000000000000000000000000", + "80000000000000000000000000000000000000000000000000000000000000000000", + "80000000000000000000000000000000000000000000000000000000000000000000", + "80000000000000000000000000000000000000000000000000000000000000000000", + "a0a8891c6de20c065da5e4ae6fc6a52d81e29d1d18926429c50236b4949f41f52a00", + "a0dd96313bf54b09798f4c5b5958b5bd8f2c3f079b5a24c0b89033fc9a088fb08e00", + "80000000000000000000000000000000000000000000000000000000000000000000", + "a086c80e661a30f3e76d27611ee60125b0fb3deebea9a5b36236e1dc6ad87f9db400", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000" + ], + "keccak_data": [ + "f8d180a034e0097d64dedfd3ecaff0702de289c4110f5b7b8243d49e8ea7969682c5b17a80a07da532ec5da228b88092a7102ba227acb97d8295949c33d7c207ea1d95771cb2808080a035f5e68adcf50eaa023741ba9d02a53ec950464f04cf8063f22eaa3f965d36e680808080a0a8891c6de20c065da5e4ae6fc6a52d81e29d1d18926429c50236b4949f41f52aa0dd96313bf54b09798f4c5b5958b5bd8f2c3f079b5a24c0b89033fc9a088fb08e80a086c80e661a30f3e76d27611ee60125b0fb3deebea9a5b36236e1dc6ad87f9db480", + "f8d180a034e0097d64dedfd3ecaff0702de289c4110f5b7b8243d49e8ea7969682c5b17a80a07da532ec5da228b88092a7102ba227acb97d8295949c33d7c207ea1d95771cb2808080a035f5e68adcf50eaa023741ba9d02a53ec950464f04cf8063f22eaa3f965d36e680808080a0b0375763c9c490c555bf594dc13ecf3e63003a136a5bada92ee4f48197c73c2da0dd96313bf54b09798f4c5b5958b5bd8f2c3f079b5a24c0b89033fc9a088fb08e80a086c80e661a30f3e76d27611ee60125b0fb3deebea9a5b36236e1dc6ad87f9db480" + ] + }, + { + "start": null, + "extension_branch": { + "is_extension": false, + "is_mod_extension": [ + false, + false + ], + "is_placeholder": [ + true, + false + ], + "extension": { + "list_rlp_bytes": "00000000000000000000000000000000000000000000000000000000000000000000" + }, + "branch": { + "modified_index": 0, + "drifted_index": 4, + "list_rlp_bytes": [ + "f851", + "f851" + ] + } + }, + "account": null, + "storage": null, + "mod_extension": null, + "values": [ + "a05a5c24d87e3c29db49e2def81af9f175bfa4bf067e6081e69fdd6768ceb5b54d00", + "a05a5c24d87e3c29db49e2def81af9f175bfa4bf067e6081e69fdd6768ceb5b54d00", + "80000000000000000000000000000000000000000000000000000000000000000000", + "80000000000000000000000000000000000000000000000000000000000000000000", + "80000000000000000000000000000000000000000000000000000000000000000000", + "a01d7f6211d4254b8cde93b7a9797babd2e4d76e21d81e78e9e0aafb417c99c17900", + "80000000000000000000000000000000000000000000000000000000000000000000", + "80000000000000000000000000000000000000000000000000000000000000000000", + "80000000000000000000000000000000000000000000000000000000000000000000", + "80000000000000000000000000000000000000000000000000000000000000000000", + "80000000000000000000000000000000000000000000000000000000000000000000", + "80000000000000000000000000000000000000000000000000000000000000000000", + "80000000000000000000000000000000000000000000000000000000000000000000", + "80000000000000000000000000000000000000000000000000000000000000000000", + "80000000000000000000000000000000000000000000000000000000000000000000", + "80000000000000000000000000000000000000000000000000000000000000000000", + "80000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000" + ], + "keccak_data": [ + "f851a05a5c24d87e3c29db49e2def81af9f175bfa4bf067e6081e69fdd6768ceb5b54d808080a01d7f6211d4254b8cde93b7a9797babd2e4d76e21d81e78e9e0aafb417c99c179808080808080808080808080", + "f851a05a5c24d87e3c29db49e2def81af9f175bfa4bf067e6081e69fdd6768ceb5b54d808080a01d7f6211d4254b8cde93b7a9797babd2e4d76e21d81e78e9e0aafb417c99c179808080808080808080808080" + ] + }, + { + "start": null, + "extension_branch": null, + "account": { + "address": "caac46d9bd68bffb533320545a90cd92c6e98e58", + "key": "c856c0d4438ec2fa5935cb6f47e96b22b75968689748d23db05fa7e9d908e4f5", + "list_rlp_bytes": [ + "f86d", + "f867" + ], + "value_rlp_bytes": [ + "b84c", + "b846" + ], + "value_list_rlp_bytes": [ + "f84a", + "f844" + ], + "drifted_rlp_bytes": "f86d", + "wrong_rlp_bytes": "f867", + "is_mod_extension": [ + false, + false + ], + "mod_list_rlp_bytes": [ + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000" + ] + }, + "storage": null, + "mod_extension": null, + "values": [ + "9e345ac5795a845ff38a9ecfa2dbdecee089a41a45c2958ba2aeb719c5ff6c000000", + "9e20d4438ec2fa5935cb6f47e96b22b75968689748d23db05fa7e9d908e4f5000000", + "01000000000000000000000000000000000000000000000000000000000000000000", + "86e5eb96330000000000000000000000000000000000000000000000000000000000", + "a056e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b42100", + "a0c5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a47000", + "80000000000000000000000000000000000000000000000000000000000000000000", + "62000000000000000000000000000000000000000000000000000000000000000000", + "a056e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b42100", + "a0c5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a47000", + "9e205ac5795a845ff38a9ecfa2dbdecee089a41a45c2958ba2aeb719c5ff6c000000", + "9e20d4438ec2fa5935cb6f47e96b22b75968689748d23db05fa7e9d908e4f5000000", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000" + ], + "keccak_data": [ + "f86d9e345ac5795a845ff38a9ecfa2dbdecee089a41a45c2958ba2aeb719c5ff6cb84cf84a0186e5eb96330000a056e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421a0c5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470", + "f8679e20d4438ec2fa5935cb6f47e96b22b75968689748d23db05fa7e9d908e4f5b846f8448062a056e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421a0c5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470", + "caac46d9bd68bffb533320545a90cd92c6e98e58", + "f86d9e205ac5795a845ff38a9ecfa2dbdecee089a41a45c2958ba2aeb719c5ff6cb84cf84a0186e5eb96330000a056e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421a0c5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470" + ] + }, + { + "start": { + "disable_preimage_check": false, + "proof_type": "Disabled" + }, + "extension_branch": null, + "account": null, + "storage": null, + "mod_extension": null, + "values": [ + "a0000000000000000000000000000000000000000000000000000000000000000000", + "a0000000000000000000000000000000000000000000000000000000000000000000" + ], + "keccak_data": [] + }, + { + "start": { + "disable_preimage_check": false, + "proof_type": "StorageDoesNotExist" + }, + "extension_branch": null, + "account": null, + "storage": null, + "mod_extension": null, + "values": [ + "a0caf6653ccaaaa78601ce2fb67faa13084dfc7c2391ef77ead89284a09c02b3ec00", + "a0caf6653ccaaaa78601ce2fb67faa13084dfc7c2391ef77ead89284a09c02b3ec00" + ], + "keccak_data": [] + }, + { + "start": null, + "extension_branch": { + "is_extension": false, + "is_mod_extension": [ + false, + false + ], + "is_placeholder": [ + false, + false + ], + "extension": { + "list_rlp_bytes": "00000000000000000000000000000000000000000000000000000000000000000000" + }, + "branch": { + "modified_index": 12, + "drifted_index": 12, + "list_rlp_bytes": [ + "f90211", + "f90211" + ] + } + }, + "account": null, + "storage": null, + "mod_extension": null, + "values": [ + "a01d7faae436001d10cf96100d8fb1e13cd4a031d605a96f53c21a64dff0f4629700", + "a072c16366d0bbb992f6d5515a9ff895ee5c6eecfc3cbf34c1e264a8dd934e5a6500", + "a049565dab20afe6ae478427b0356f569865d9f42eda630659c2939d62721e0a7f00", + "a028146412dbe3e474ec9348a726feab497f273a27511776e9d6ff0f8f05a126ac00", + "a0a51cfec42ea9d7a4c3deac3daf2a1b364b01e2f71bdc40af02f738742f5d01ff00", + "a04c023f80d2d18f1a3e4cdc5242bf9e9ae4fe3850e324fa31f6cf0d66eac38af700", + "a052d345bf981d5e996b4bc2906d72a7fd2b30f36fd93146485beb70b46c9c6db800", + "a080a18f6ee76e65d2dde38a13d774f43c7b4205d247f46f9eb1327964dac357b400", + "a0406dc489f30576ba4475cc4d1aedeef4d531e56a52ded0bb6c0d38f601ca9b4a00", + "a0e82e0c5066e06cd1346b0475d2485723f50d5d2f3ea9d085bb0ba6264f286b5000", + "a021ae734f2f6928c9fc4910eb901c4878c87345d6f4fc1288e2f5aa72888db07400", + "a05f2d744390aa2bd1ab7e6244552162a1ebad0f975f551965776742c506ce8bd200", + "a050c4d55e661be3f28a0d41c1e2bfbd6ecc0c7551f606c341de9e6310e9e2c67100", + "a01d7faae436001d10cf96100d8fb1e13cd4a031d605a96f53c21a64dff0f4629700", + "a07fac0edb04f86c1660a9fbcf361686c59608f142482f7b0c1b60ebf433c698f400", + "a0d3841ee2a7ff3cedbe4ef083217f87d3cc285261adebd3304029ecc09f080d3800", + "a0765f7869c81a6518af91dfa6feccaff661551eae3c7e6eec1d1e376c9c46ec0d00", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000" + ], + "keccak_data": [ + "f90211a072c16366d0bbb992f6d5515a9ff895ee5c6eecfc3cbf34c1e264a8dd934e5a65a049565dab20afe6ae478427b0356f569865d9f42eda630659c2939d62721e0a7fa028146412dbe3e474ec9348a726feab497f273a27511776e9d6ff0f8f05a126aca0a51cfec42ea9d7a4c3deac3daf2a1b364b01e2f71bdc40af02f738742f5d01ffa04c023f80d2d18f1a3e4cdc5242bf9e9ae4fe3850e324fa31f6cf0d66eac38af7a052d345bf981d5e996b4bc2906d72a7fd2b30f36fd93146485beb70b46c9c6db8a080a18f6ee76e65d2dde38a13d774f43c7b4205d247f46f9eb1327964dac357b4a0406dc489f30576ba4475cc4d1aedeef4d531e56a52ded0bb6c0d38f601ca9b4aa0e82e0c5066e06cd1346b0475d2485723f50d5d2f3ea9d085bb0ba6264f286b50a021ae734f2f6928c9fc4910eb901c4878c87345d6f4fc1288e2f5aa72888db074a05f2d744390aa2bd1ab7e6244552162a1ebad0f975f551965776742c506ce8bd2a050c4d55e661be3f28a0d41c1e2bfbd6ecc0c7551f606c341de9e6310e9e2c671a01d7faae436001d10cf96100d8fb1e13cd4a031d605a96f53c21a64dff0f46297a07fac0edb04f86c1660a9fbcf361686c59608f142482f7b0c1b60ebf433c698f4a0d3841ee2a7ff3cedbe4ef083217f87d3cc285261adebd3304029ecc09f080d38a0765f7869c81a6518af91dfa6feccaff661551eae3c7e6eec1d1e376c9c46ec0d80", + "f90211a072c16366d0bbb992f6d5515a9ff895ee5c6eecfc3cbf34c1e264a8dd934e5a65a049565dab20afe6ae478427b0356f569865d9f42eda630659c2939d62721e0a7fa028146412dbe3e474ec9348a726feab497f273a27511776e9d6ff0f8f05a126aca0a51cfec42ea9d7a4c3deac3daf2a1b364b01e2f71bdc40af02f738742f5d01ffa04c023f80d2d18f1a3e4cdc5242bf9e9ae4fe3850e324fa31f6cf0d66eac38af7a052d345bf981d5e996b4bc2906d72a7fd2b30f36fd93146485beb70b46c9c6db8a080a18f6ee76e65d2dde38a13d774f43c7b4205d247f46f9eb1327964dac357b4a0406dc489f30576ba4475cc4d1aedeef4d531e56a52ded0bb6c0d38f601ca9b4aa0e82e0c5066e06cd1346b0475d2485723f50d5d2f3ea9d085bb0ba6264f286b50a021ae734f2f6928c9fc4910eb901c4878c87345d6f4fc1288e2f5aa72888db074a05f2d744390aa2bd1ab7e6244552162a1ebad0f975f551965776742c506ce8bd2a050c4d55e661be3f28a0d41c1e2bfbd6ecc0c7551f606c341de9e6310e9e2c671a01d7faae436001d10cf96100d8fb1e13cd4a031d605a96f53c21a64dff0f46297a07fac0edb04f86c1660a9fbcf361686c59608f142482f7b0c1b60ebf433c698f4a0d3841ee2a7ff3cedbe4ef083217f87d3cc285261adebd3304029ecc09f080d38a0765f7869c81a6518af91dfa6feccaff661551eae3c7e6eec1d1e376c9c46ec0d80" + ] + }, + { + "start": null, + "extension_branch": { + "is_extension": false, + "is_mod_extension": [ + false, + false + ], + "is_placeholder": [ + false, + false + ], + "extension": { + "list_rlp_bytes": "00000000000000000000000000000000000000000000000000000000000000000000" + }, + "branch": { + "modified_index": 8, + "drifted_index": 8, + "list_rlp_bytes": [ + "f90211", + "f90211" + ] + } + }, + "account": null, + "storage": null, + "mod_extension": null, + "values": [ + "a0ae8a9a65f35ae639ed37965d8a252d2b4da7bf9d631c02e32ce88247964e636900", + "a0f3cdaf60d79fb61e893b369b710937ac23e0c2847bcbccff7009922d4db5bd0100", + "a0fce77948227c2a286b84ef12e23e853388bb8b12f72fd9bf0a84e92f63164e5300", + "a039e92b76a5aec3250c46b68db0534c0b7730026a91299f4144ae2124536000cf00", + "a0f987345194d91423f8dfcda5412ef4a12464835103a26c2822f848d194cb4bfa00", + "a04bea5e4005db61e7bef013096cd5e23a29b0595f2f9daa8ac9bc76f9e4c3adb100", + "a0695a7fbb5ad5107fb1de0c1530caa5fa73628c4100052c13e4f21859f110f31100", + "a03d98d4f7fbdaf32ef9aa992a70209a1cf7a85e746704dc3248f8c1ebbdaa08bb00", + "a06388fe7b966ff5e278f29526c5c2e4ed1e2c11016d6ec1e437a37d3223ff90ec00", + "a0ae8a9a65f35ae639ed37965d8a252d2b4da7bf9d631c02e32ce88247964e636900", + "a08d42490450e1385bdfef861f41d597d2693f4c2b5c4e1a8751b2096185f1d36400", + "a0ed9ee1e21920ec422f026b70439d6cfa0e7b3992b482e7591909eec6ddf751b400", + "a01bd96f3d6fc795e66d82116ddef3d38865bafa04e426c1b51e446d38b79dc3a100", + "a0910782b346b7dcd82c6709ec62ef1f13aa487576ddd5cb8019f0201fe15ef00900", + "a0491b867e5a84cf4046b39a78315504d529feda45cab7f99e1f6f3101bdf00c8900", + "a034f545d3a349cfb6c8098c638f87d7b2a14706400544d743187afcb337b9b9d000", + "a057994926d9422d5d969fffc0b2677cdb6e289b86625219fede0bc84421e4db0600", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000" + ], + "keccak_data": [ + "f90211a0f3cdaf60d79fb61e893b369b710937ac23e0c2847bcbccff7009922d4db5bd01a0fce77948227c2a286b84ef12e23e853388bb8b12f72fd9bf0a84e92f63164e53a039e92b76a5aec3250c46b68db0534c0b7730026a91299f4144ae2124536000cfa0f987345194d91423f8dfcda5412ef4a12464835103a26c2822f848d194cb4bfaa04bea5e4005db61e7bef013096cd5e23a29b0595f2f9daa8ac9bc76f9e4c3adb1a0695a7fbb5ad5107fb1de0c1530caa5fa73628c4100052c13e4f21859f110f311a03d98d4f7fbdaf32ef9aa992a70209a1cf7a85e746704dc3248f8c1ebbdaa08bba06388fe7b966ff5e278f29526c5c2e4ed1e2c11016d6ec1e437a37d3223ff90eca0ae8a9a65f35ae639ed37965d8a252d2b4da7bf9d631c02e32ce88247964e6369a08d42490450e1385bdfef861f41d597d2693f4c2b5c4e1a8751b2096185f1d364a0ed9ee1e21920ec422f026b70439d6cfa0e7b3992b482e7591909eec6ddf751b4a01bd96f3d6fc795e66d82116ddef3d38865bafa04e426c1b51e446d38b79dc3a1a0910782b346b7dcd82c6709ec62ef1f13aa487576ddd5cb8019f0201fe15ef009a0491b867e5a84cf4046b39a78315504d529feda45cab7f99e1f6f3101bdf00c89a034f545d3a349cfb6c8098c638f87d7b2a14706400544d743187afcb337b9b9d0a057994926d9422d5d969fffc0b2677cdb6e289b86625219fede0bc84421e4db0680", + "f90211a0f3cdaf60d79fb61e893b369b710937ac23e0c2847bcbccff7009922d4db5bd01a0fce77948227c2a286b84ef12e23e853388bb8b12f72fd9bf0a84e92f63164e53a039e92b76a5aec3250c46b68db0534c0b7730026a91299f4144ae2124536000cfa0f987345194d91423f8dfcda5412ef4a12464835103a26c2822f848d194cb4bfaa04bea5e4005db61e7bef013096cd5e23a29b0595f2f9daa8ac9bc76f9e4c3adb1a0695a7fbb5ad5107fb1de0c1530caa5fa73628c4100052c13e4f21859f110f311a03d98d4f7fbdaf32ef9aa992a70209a1cf7a85e746704dc3248f8c1ebbdaa08bba06388fe7b966ff5e278f29526c5c2e4ed1e2c11016d6ec1e437a37d3223ff90eca0ae8a9a65f35ae639ed37965d8a252d2b4da7bf9d631c02e32ce88247964e6369a08d42490450e1385bdfef861f41d597d2693f4c2b5c4e1a8751b2096185f1d364a0ed9ee1e21920ec422f026b70439d6cfa0e7b3992b482e7591909eec6ddf751b4a01bd96f3d6fc795e66d82116ddef3d38865bafa04e426c1b51e446d38b79dc3a1a0910782b346b7dcd82c6709ec62ef1f13aa487576ddd5cb8019f0201fe15ef009a0491b867e5a84cf4046b39a78315504d529feda45cab7f99e1f6f3101bdf00c89a034f545d3a349cfb6c8098c638f87d7b2a14706400544d743187afcb337b9b9d0a057994926d9422d5d969fffc0b2677cdb6e289b86625219fede0bc84421e4db0680" + ] + }, + { + "start": null, + "extension_branch": { + "is_extension": false, + "is_mod_extension": [ + false, + false + ], + "is_placeholder": [ + false, + false + ], + "extension": { + "list_rlp_bytes": "00000000000000000000000000000000000000000000000000000000000000000000" + }, + "branch": { + "modified_index": 5, + "drifted_index": 5, + "list_rlp_bytes": [ + "f90211", + "f90211" + ] + } + }, + "account": null, + "storage": null, + "mod_extension": null, + "values": [ + "a0335f88c3426aac199fed5e159ed2cf7f9f1a62f93d3a47204773364d06e6508b00", + "a0643223afd2cdf8850275b8fefeda7aa35da0c26ef0c39c60cfb1e24cc52762c100", + "a0d3e07435e99ae94fa784d0b48f7955cc327f3283c54728a0f0657e9873d4aa7600", + "a031cdb1d9522f06bc78049c39940f21a511531017c651f00d53cca82c0b6f34b200", + "a01ec8ea4b4424cf744e29c7d218af2dfe9140256e58171305ab1472bd2df95afb00", + "a02c69884acac1b6212b90cdd721b88dcfe9b00c2ccbf411d5e9ecdda90f93c23400", + "a0335f88c3426aac199fed5e159ed2cf7f9f1a62f93d3a47204773364d06e6508b00", + "a01c190836d2eca2384e06b124b900da5aa4ab874ab762c06342600aa8c34c07d300", + "a0a7d794c34193c548e12e2089d9109e25d3d1b13f87be3be358412b6ea906e4cd00", + "a0176b3d097548b67aa6dd67f4311323285f773fa5bc64894515fb1fb40fe1b87c00", + "a0add35369e46f48b4fffcee149bbd8e780bd8dcf784c6bb4da5d371742a439ff200", + "a0d4c92afc344f8c1fed0a3a9a0973e0e2af3a9e92f6c11b041c1c4839b4c04f4700", + "a083a4cfd6d2fac8a31b13d1723323be55233091ad3d280637084983a8531d326600", + "a0b1eafa8ec6b94928b4ac69306d1ea447cab455a023bdd31c1b7c667265aec99800", + "a074f76c46d44c70a53fb64d3801444d9739854e7af0ba12749864929e0f3466a900", + "a037d17318bd52b12c443d1c609a64646fad41e1d5a6a9e5f46f1bb6c2b4a9f9a400", + "a03f855b509146866d83d593409f9c0f95f0c49a22ec5d86b4b9d0adb930425ef100", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000" + ], + "keccak_data": [ + "f90211a0643223afd2cdf8850275b8fefeda7aa35da0c26ef0c39c60cfb1e24cc52762c1a0d3e07435e99ae94fa784d0b48f7955cc327f3283c54728a0f0657e9873d4aa76a031cdb1d9522f06bc78049c39940f21a511531017c651f00d53cca82c0b6f34b2a01ec8ea4b4424cf744e29c7d218af2dfe9140256e58171305ab1472bd2df95afba02c69884acac1b6212b90cdd721b88dcfe9b00c2ccbf411d5e9ecdda90f93c234a0335f88c3426aac199fed5e159ed2cf7f9f1a62f93d3a47204773364d06e6508ba01c190836d2eca2384e06b124b900da5aa4ab874ab762c06342600aa8c34c07d3a0a7d794c34193c548e12e2089d9109e25d3d1b13f87be3be358412b6ea906e4cda0176b3d097548b67aa6dd67f4311323285f773fa5bc64894515fb1fb40fe1b87ca0add35369e46f48b4fffcee149bbd8e780bd8dcf784c6bb4da5d371742a439ff2a0d4c92afc344f8c1fed0a3a9a0973e0e2af3a9e92f6c11b041c1c4839b4c04f47a083a4cfd6d2fac8a31b13d1723323be55233091ad3d280637084983a8531d3266a0b1eafa8ec6b94928b4ac69306d1ea447cab455a023bdd31c1b7c667265aec998a074f76c46d44c70a53fb64d3801444d9739854e7af0ba12749864929e0f3466a9a037d17318bd52b12c443d1c609a64646fad41e1d5a6a9e5f46f1bb6c2b4a9f9a4a03f855b509146866d83d593409f9c0f95f0c49a22ec5d86b4b9d0adb930425ef180", + "f90211a0643223afd2cdf8850275b8fefeda7aa35da0c26ef0c39c60cfb1e24cc52762c1a0d3e07435e99ae94fa784d0b48f7955cc327f3283c54728a0f0657e9873d4aa76a031cdb1d9522f06bc78049c39940f21a511531017c651f00d53cca82c0b6f34b2a01ec8ea4b4424cf744e29c7d218af2dfe9140256e58171305ab1472bd2df95afba02c69884acac1b6212b90cdd721b88dcfe9b00c2ccbf411d5e9ecdda90f93c234a0335f88c3426aac199fed5e159ed2cf7f9f1a62f93d3a47204773364d06e6508ba01c190836d2eca2384e06b124b900da5aa4ab874ab762c06342600aa8c34c07d3a0a7d794c34193c548e12e2089d9109e25d3d1b13f87be3be358412b6ea906e4cda0176b3d097548b67aa6dd67f4311323285f773fa5bc64894515fb1fb40fe1b87ca0add35369e46f48b4fffcee149bbd8e780bd8dcf784c6bb4da5d371742a439ff2a0d4c92afc344f8c1fed0a3a9a0973e0e2af3a9e92f6c11b041c1c4839b4c04f47a083a4cfd6d2fac8a31b13d1723323be55233091ad3d280637084983a8531d3266a0b1eafa8ec6b94928b4ac69306d1ea447cab455a023bdd31c1b7c667265aec998a074f76c46d44c70a53fb64d3801444d9739854e7af0ba12749864929e0f3466a9a037d17318bd52b12c443d1c609a64646fad41e1d5a6a9e5f46f1bb6c2b4a9f9a4a03f855b509146866d83d593409f9c0f95f0c49a22ec5d86b4b9d0adb930425ef180" + ] + }, + { + "start": null, + "extension_branch": { + "is_extension": false, + "is_mod_extension": [ + false, + false + ], + "is_placeholder": [ + false, + false + ], + "extension": { + "list_rlp_bytes": "00000000000000000000000000000000000000000000000000000000000000000000" + }, + "branch": { + "modified_index": 6, + "drifted_index": 6, + "list_rlp_bytes": [ + "f90211", + "f90211" + ] + } + }, + "account": null, + "storage": null, + "mod_extension": null, + "values": [ + "a0cdb89f2e65e49e662f7f831085ce0573deb7f3dbcf1597a55c9c0c9e420c6ede00", + "a00dffd4fc7a7acbd11a09ab1a28fad6ce37a9d446dfb9ebf6be429bf800f45b0200", + "a0ea85244fcbe9cc89739872c5ed66efc8f67d331dfa18723e22948d0bc0e8cc7900", + "a02af9d9b113e3dd75c3544b71c112f9a14bd194cccb625bb9ee139c9fee95686a00", + "a0ff3ceb58292c96600ca5b75a541fde654b8d4d8950fbec1b5d26181f8ffb49d400", + "a03f4278f130a38121d771d6ab937d9ecb458596c6ecb60cab6cb4fbfae6d1d39d00", + "a0fec61d1f7a1c8224272521d7be099e7ad7e2e61d1021866c5e12ea01f47f934b00", + "a0cdb89f2e65e49e662f7f831085ce0573deb7f3dbcf1597a55c9c0c9e420c6ede00", + "a0bf00c6c27397c5b9c3e6e2bc5545d74d1ad6eaa1443f88942a26a9e37a6207b400", + "a06518755c2762ea97b58027e8843c110ddbcd2f6a07e4d239c72386f1fc77edb700", + "a08f15a73b5cbc8f2da22ec5303993b971e96e72407145a76fe327dea836226f8f00", + "a040222473c2e4aaaa15d7806aec12e22cc0b64ecf44f47af45b9a0dfd72d1b77f00", + "a081c0a354ff213fed635c58e5c3b09774374bc72811386af11e8f3716bc8e08f300", + "a0003b48aebee15ad11ab9f4e0dfe94b54122261fe23e7ed056aca36f2123eb34400", + "a028c4fe56d5638df2d3b202c7332c748272fe84d9462c534128f68612c389138d00", + "a0e064b6c149ebf5772b53b33423d2d5cf9bd8565db4d76c7f8e3a7474025b324000", + "a01f4af370ae8e26ec0c81df057a2a53fbcf5824854e5f6a9253509539bbb277db00", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000" + ], + "keccak_data": [ + "f90211a00dffd4fc7a7acbd11a09ab1a28fad6ce37a9d446dfb9ebf6be429bf800f45b02a0ea85244fcbe9cc89739872c5ed66efc8f67d331dfa18723e22948d0bc0e8cc79a02af9d9b113e3dd75c3544b71c112f9a14bd194cccb625bb9ee139c9fee95686aa0ff3ceb58292c96600ca5b75a541fde654b8d4d8950fbec1b5d26181f8ffb49d4a03f4278f130a38121d771d6ab937d9ecb458596c6ecb60cab6cb4fbfae6d1d39da0fec61d1f7a1c8224272521d7be099e7ad7e2e61d1021866c5e12ea01f47f934ba0cdb89f2e65e49e662f7f831085ce0573deb7f3dbcf1597a55c9c0c9e420c6edea0bf00c6c27397c5b9c3e6e2bc5545d74d1ad6eaa1443f88942a26a9e37a6207b4a06518755c2762ea97b58027e8843c110ddbcd2f6a07e4d239c72386f1fc77edb7a08f15a73b5cbc8f2da22ec5303993b971e96e72407145a76fe327dea836226f8fa040222473c2e4aaaa15d7806aec12e22cc0b64ecf44f47af45b9a0dfd72d1b77fa081c0a354ff213fed635c58e5c3b09774374bc72811386af11e8f3716bc8e08f3a0003b48aebee15ad11ab9f4e0dfe94b54122261fe23e7ed056aca36f2123eb344a028c4fe56d5638df2d3b202c7332c748272fe84d9462c534128f68612c389138da0e064b6c149ebf5772b53b33423d2d5cf9bd8565db4d76c7f8e3a7474025b3240a01f4af370ae8e26ec0c81df057a2a53fbcf5824854e5f6a9253509539bbb277db80", + "f90211a00dffd4fc7a7acbd11a09ab1a28fad6ce37a9d446dfb9ebf6be429bf800f45b02a0ea85244fcbe9cc89739872c5ed66efc8f67d331dfa18723e22948d0bc0e8cc79a02af9d9b113e3dd75c3544b71c112f9a14bd194cccb625bb9ee139c9fee95686aa0ff3ceb58292c96600ca5b75a541fde654b8d4d8950fbec1b5d26181f8ffb49d4a03f4278f130a38121d771d6ab937d9ecb458596c6ecb60cab6cb4fbfae6d1d39da0fec61d1f7a1c8224272521d7be099e7ad7e2e61d1021866c5e12ea01f47f934ba0cdb89f2e65e49e662f7f831085ce0573deb7f3dbcf1597a55c9c0c9e420c6edea0bf00c6c27397c5b9c3e6e2bc5545d74d1ad6eaa1443f88942a26a9e37a6207b4a06518755c2762ea97b58027e8843c110ddbcd2f6a07e4d239c72386f1fc77edb7a08f15a73b5cbc8f2da22ec5303993b971e96e72407145a76fe327dea836226f8fa040222473c2e4aaaa15d7806aec12e22cc0b64ecf44f47af45b9a0dfd72d1b77fa081c0a354ff213fed635c58e5c3b09774374bc72811386af11e8f3716bc8e08f3a0003b48aebee15ad11ab9f4e0dfe94b54122261fe23e7ed056aca36f2123eb344a028c4fe56d5638df2d3b202c7332c748272fe84d9462c534128f68612c389138da0e064b6c149ebf5772b53b33423d2d5cf9bd8565db4d76c7f8e3a7474025b3240a01f4af370ae8e26ec0c81df057a2a53fbcf5824854e5f6a9253509539bbb277db80" + ] + }, + { + "start": null, + "extension_branch": { + "is_extension": false, + "is_mod_extension": [ + false, + false + ], + "is_placeholder": [ + false, + false + ], + "extension": { + "list_rlp_bytes": "00000000000000000000000000000000000000000000000000000000000000000000" + }, + "branch": { + "modified_index": 12, + "drifted_index": 12, + "list_rlp_bytes": [ + "f8d1", + "f8d1" + ] + } + }, + "account": null, + "storage": null, + "mod_extension": null, + "values": [ + "a0b0375763c9c490c555bf594dc13ecf3e63003a136a5bada92ee4f48197c73c2d00", + "80000000000000000000000000000000000000000000000000000000000000000000", + "a034e0097d64dedfd3ecaff0702de289c4110f5b7b8243d49e8ea7969682c5b17a00", + "80000000000000000000000000000000000000000000000000000000000000000000", + "a07da532ec5da228b88092a7102ba227acb97d8295949c33d7c207ea1d95771cb200", + "80000000000000000000000000000000000000000000000000000000000000000000", + "80000000000000000000000000000000000000000000000000000000000000000000", + "80000000000000000000000000000000000000000000000000000000000000000000", + "a035f5e68adcf50eaa023741ba9d02a53ec950464f04cf8063f22eaa3f965d36e600", + "80000000000000000000000000000000000000000000000000000000000000000000", + "80000000000000000000000000000000000000000000000000000000000000000000", + "80000000000000000000000000000000000000000000000000000000000000000000", + "80000000000000000000000000000000000000000000000000000000000000000000", + "a0b0375763c9c490c555bf594dc13ecf3e63003a136a5bada92ee4f48197c73c2d00", + "a0dd96313bf54b09798f4c5b5958b5bd8f2c3f079b5a24c0b89033fc9a088fb08e00", + "80000000000000000000000000000000000000000000000000000000000000000000", + "a086c80e661a30f3e76d27611ee60125b0fb3deebea9a5b36236e1dc6ad87f9db400", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000" + ], + "keccak_data": [ + "f8d180a034e0097d64dedfd3ecaff0702de289c4110f5b7b8243d49e8ea7969682c5b17a80a07da532ec5da228b88092a7102ba227acb97d8295949c33d7c207ea1d95771cb2808080a035f5e68adcf50eaa023741ba9d02a53ec950464f04cf8063f22eaa3f965d36e680808080a0b0375763c9c490c555bf594dc13ecf3e63003a136a5bada92ee4f48197c73c2da0dd96313bf54b09798f4c5b5958b5bd8f2c3f079b5a24c0b89033fc9a088fb08e80a086c80e661a30f3e76d27611ee60125b0fb3deebea9a5b36236e1dc6ad87f9db480", + "f8d180a034e0097d64dedfd3ecaff0702de289c4110f5b7b8243d49e8ea7969682c5b17a80a07da532ec5da228b88092a7102ba227acb97d8295949c33d7c207ea1d95771cb2808080a035f5e68adcf50eaa023741ba9d02a53ec950464f04cf8063f22eaa3f965d36e680808080a0b0375763c9c490c555bf594dc13ecf3e63003a136a5bada92ee4f48197c73c2da0dd96313bf54b09798f4c5b5958b5bd8f2c3f079b5a24c0b89033fc9a088fb08e80a086c80e661a30f3e76d27611ee60125b0fb3deebea9a5b36236e1dc6ad87f9db480" + ] + }, + { + "start": null, + "extension_branch": { + "is_extension": false, + "is_mod_extension": [ + false, + false + ], + "is_placeholder": [ + false, + false + ], + "extension": { + "list_rlp_bytes": "00000000000000000000000000000000000000000000000000000000000000000000" + }, + "branch": { + "modified_index": 0, + "drifted_index": 0, + "list_rlp_bytes": [ + "f851", + "f851" + ] + } + }, + "account": null, + "storage": null, + "mod_extension": null, + "values": [ + "a05a5c24d87e3c29db49e2def81af9f175bfa4bf067e6081e69fdd6768ceb5b54d00", + "a05a5c24d87e3c29db49e2def81af9f175bfa4bf067e6081e69fdd6768ceb5b54d00", + "80000000000000000000000000000000000000000000000000000000000000000000", + "80000000000000000000000000000000000000000000000000000000000000000000", + "80000000000000000000000000000000000000000000000000000000000000000000", + "a01d7f6211d4254b8cde93b7a9797babd2e4d76e21d81e78e9e0aafb417c99c17900", + "80000000000000000000000000000000000000000000000000000000000000000000", + "80000000000000000000000000000000000000000000000000000000000000000000", + "80000000000000000000000000000000000000000000000000000000000000000000", + "80000000000000000000000000000000000000000000000000000000000000000000", + "80000000000000000000000000000000000000000000000000000000000000000000", + "80000000000000000000000000000000000000000000000000000000000000000000", + "80000000000000000000000000000000000000000000000000000000000000000000", + "80000000000000000000000000000000000000000000000000000000000000000000", + "80000000000000000000000000000000000000000000000000000000000000000000", + "80000000000000000000000000000000000000000000000000000000000000000000", + "80000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000" + ], + "keccak_data": [ + "f851a05a5c24d87e3c29db49e2def81af9f175bfa4bf067e6081e69fdd6768ceb5b54d808080a01d7f6211d4254b8cde93b7a9797babd2e4d76e21d81e78e9e0aafb417c99c179808080808080808080808080", + "f851a05a5c24d87e3c29db49e2def81af9f175bfa4bf067e6081e69fdd6768ceb5b54d808080a01d7f6211d4254b8cde93b7a9797babd2e4d76e21d81e78e9e0aafb417c99c179808080808080808080808080" + ] + }, + { + "start": null, + "extension_branch": null, + "account": { + "address": "caac46d9bd68bffb533320545a90cd92c6e98e58", + "key": "c856c0d4438ec2fa5935cb6f47e96b22b75968689748d23db05fa7e9d908e4f5", + "list_rlp_bytes": [ + "f867", + "f867" + ], + "value_rlp_bytes": [ + "b846", + "b846" + ], + "value_list_rlp_bytes": [ + "f844", + "f844" + ], + "drifted_rlp_bytes": "00", + "wrong_rlp_bytes": "f867", + "is_mod_extension": [ + false, + false + ], + "mod_list_rlp_bytes": [ + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000" + ] + }, + "storage": null, + "mod_extension": null, + "values": [ + "9e20d4438ec2fa5935cb6f47e96b22b75968689748d23db05fa7e9d908e4f5000000", + "9e20d4438ec2fa5935cb6f47e96b22b75968689748d23db05fa7e9d908e4f5000000", + "80000000000000000000000000000000000000000000000000000000000000000000", + "62000000000000000000000000000000000000000000000000000000000000000000", + "a056e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b42100", + "a0c5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a47000", + "80000000000000000000000000000000000000000000000000000000000000000000", + "62000000000000000000000000000000000000000000000000000000000000000000", + "a056e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b42100", + "a0c5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a47000", + "00000000000000000000000000000000000000000000000000000000000000000000", + "9e20d4438ec2fa5935cb6f47e96b22b75968689748d23db05fa7e9d908e4f5000000", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000" + ], + "keccak_data": [ + "f8679e20d4438ec2fa5935cb6f47e96b22b75968689748d23db05fa7e9d908e4f5b846f8448062a056e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421a0c5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470", + "f8679e20d4438ec2fa5935cb6f47e96b22b75968689748d23db05fa7e9d908e4f5b846f8448062a056e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421a0c5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470", + "caac46d9bd68bffb533320545a90cd92c6e98e58" + ] + }, + { + "start": null, + "extension_branch": null, + "account": null, + "storage": { + "address": "0000000000000000000000000000000000000000000000000000000000000000", + "key": "290decd9548b62a8d60345a988386fc84ba6bc95484008f6362f93160ef3e563", + "list_rlp_bytes": [ + "e3", + "e3" + ], + "value_rlp_bytes": [ + "00", + "00" + ], + "drifted_rlp_bytes": "00", + "wrong_rlp_bytes": "00000000000000000000000000000000000000000000000000000000000000000000", + "is_mod_extension": [ + false, + false + ], + "mod_list_rlp_bytes": [ + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000" + ] + }, + "mod_extension": null, + "values": [ + "a1200000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000", + "a1200000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000", + "00000000000000000000000000000000000000000000000000000000000000000000" + ], + "keccak_data": [ + "e3a12000000000000000000000000000000000000000000000000000000000000000", + "e3a12000000000000000000000000000000000000000000000000000000000000000", + "0000000000000000000000000000000000000000000000000000000000000000" + ] + }, + { + "start": { + "disable_preimage_check": false, + "proof_type": "Disabled" + }, + "extension_branch": null, + "account": null, + "storage": null, + "mod_extension": null, + "values": [ + "a0000000000000000000000000000000000000000000000000000000000000000000", + "a0000000000000000000000000000000000000000000000000000000000000000000" + ], + "keccak_data": [] + } +] \ No newline at end of file diff --git a/zkevm-circuits/src/mpt_circuit/witness_row.rs b/zkevm-circuits/src/mpt_circuit/witness_row.rs index 4b75019537..9ce6c47f52 100644 --- a/zkevm-circuits/src/mpt_circuit/witness_row.rs +++ b/zkevm-circuits/src/mpt_circuit/witness_row.rs @@ -39,14 +39,14 @@ pub(crate) enum AccountRowType { CodehashC, Drifted, Wrong, - LongExtNodeKey, - LongExtNodeNibbles, - LongExtNodeValue, - ShortExtNodeKey, - ShortExtNodeNibbles, - ShortExtNodeValue, - Address, - Key, + LongExtNodeKey, // only used when extension node nibbles are modified + LongExtNodeNibbles, // only used when extension node nibbles are modified + LongExtNodeValue, // only used when extension node nibbles are modified + ShortExtNodeKey, // only used when extension node nibbles are modified + ShortExtNodeNibbles, // only used when extension node nibbles are modified + ShortExtNodeValue, // only used when extension node nibbles are modified + Address, // account address + Key, // hashed account address Count, } @@ -150,61 +150,73 @@ pub struct ExtensionBranchNode { /// MPT account node #[derive(Clone, Debug, Serialize, Deserialize)] pub struct AccountNode { - /// TODO Doc. + /// Account address. pub address: Hex, - /// TODO Doc. + /// Hashed account address. pub key: Hex, - /// TODO Doc. + /// RLP bytes denoting the length of the whole account leaf stream. pub list_rlp_bytes: [Hex; 2], - /// TODO Doc. + /// RLP bytes denoting the length of the RLP list denoting the value stream (containing nonce, + /// balance storage, codehash). pub value_rlp_bytes: [Hex; 2], - /// TODO Doc. + /// RLP bytes denoting the length of the RLP of the value stream. pub value_list_rlp_bytes: [Hex; 2], - /// TODO Doc. + /// RLP bytes denoting the length of the RLP stream of the drifted leaf (neighbour leaf). + /// This is only needed in the case when a new branch is created which replaces the existing + /// leaf in the trie and this leaf drifts down into newly created branch. pub drifted_rlp_bytes: Hex, - /// TODO Doc. + /// RLP bytes denoting the length of the RLP stream of the (wrong) leaf that has been returned + /// by `getProof` which has the same address up to a certain nibble as the required leaf. + /// This is only needed for some special cases of the AccountDoesNotExist proof. pub wrong_rlp_bytes: Hex, - /// TODO Doc. + /// Denotes whether the extension node nibbles have been modified in either `S` or `C` proof. + /// In these special cases, an additional extension node is inserted (deleted). pub(crate) is_mod_extension: [bool; 2], - /// TODO Doc. + /// RLP bytes denoting the length of the RLP of the long and short modified extension node. pub(crate) mod_list_rlp_bytes: [Hex; 2], } /// MPT storage node #[derive(Clone, Debug, Serialize, Deserialize)] pub struct StorageNode { - /// TODO Doc. + /// Storage key. pub address: Hex, - /// TODO Doc. + /// Hashed storage key. pub key: Hex, - /// TODO Doc. + /// RLP bytes denoting the length of the whole storage leaf stream. pub list_rlp_bytes: [Hex; 2], - /// TODO Doc. + /// RLP bytes denoting the length of the value stream. pub value_rlp_bytes: [Hex; 2], - /// TODO Doc. + /// RLP bytes denoting the length of the RLP stream of the drifted leaf (neighbour leaf). + /// This is only needed in the case when a new branch is created which replaces the existing + /// leaf in the trie and this leaf drifts down into newly created branch. pub drifted_rlp_bytes: Hex, - /// TODO Doc. + /// RLP bytes denoting the length of the RLP stream of the (wrong) leaf that has been returned + /// by `getProof` which has the same address up to a certain nibble as the required leaf. + /// This is only needed for some special cases of the StorageDoesNotExist proof. pub wrong_rlp_bytes: Hex, - /// TODO Doc. + /// Denotes whether the extension node nibbles have been modified in either `S` or `C` proof. + /// In these special cases, an additional extension node is inserted (deleted). pub(crate) is_mod_extension: [bool; 2], - /// TODO Doc. + /// RLP bytes denoting the length of the RLP of the long and short modified extension node. pub(crate) mod_list_rlp_bytes: [Hex; 2], } /// MPT node #[derive(Clone, Debug, Default, Serialize, Deserialize)] pub struct Node { - /// TODO Doc. + /// A node denoting the start / end of the proof. pub start: Option, - /// TODO Doc. + /// A node as an abstraction of extension node and branch. pub extension_branch: Option, - /// TODO Doc. + /// An account leaf node. pub account: Option, - /// TODO Doc. + /// A storage leaf node. pub storage: Option, - /// MPT node values + /// RLP substreams of the node (for example for account leaf it contains substreams for key, + /// nonce, balance, storage, codehash, drifted key, wrong key...) pub values: Vec, - /// MPT keccak data + /// Streams to be hashed and verified by Keccak circuit. pub keccak_data: Vec, }