0xPolygonHermez / cdk-erigon

Ethereum implementation on the efficiency frontier
GNU Lesser General Public License v3.0
35 stars 39 forks source link

[Improvement] Zero tracer validation #1351

Open cffls opened 1 month ago

cffls commented 1 month ago

This has been mentioned in zk_evm discussion. Basically, we want to validate the trace of each transaction from zero tracer before it returns.

Steps:

  1. Apply state deltas from zero trace on top of block witness and compute the pre-state trie for each transaction.
  2. Execute a transaction from the pre-state trie and compute the post-state trie.
  3. For each transaction in the block, compare if the post-state trie yielded by transaction execution (from step2) matches to the pre-state trie computed for the next transaction (from step1).

Prerequisites:

cffls commented 1 month ago

Sub-tasks: