Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Fix] core/rawdb: Compare right hash generation for Istanbul when reading from Ancient DB #1182

Merged

Conversation

ricardolyn
Copy link
Contributor

Summary

Base Geth Ancient DB performs a block header hash check each time it retrieves a block from filesytem. It does so by computing the hash of the raw rlp encoded block stored data.

This leads to an issue when running on IBFT for which block header hash is not equal to the raw rlp encoded block data hash.

To avoid this issue, we parse the data from freezerdb into a Block Header and then we obtain the right hash (which will filter the header for IBFT).

Fixes #1179

Changes

  • Modify the read rlp from ancient db to consider the block header hash mechanism used in IBFT

Copy link
Contributor

@nicolae-leonte-go nicolae-leonte-go left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks good

Copy link
Contributor

@nmvalera nmvalera left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants