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

feat: bad block list for invalid blocks after sync #3637

Merged
merged 7 commits into from
Dec 6, 2021

Conversation

sdbondi
Copy link
Member

@sdbondi sdbondi commented Dec 1, 2021

Description

Maintain a list of "bad blocks" that should never be accepted
Remove pending headers if block sync fails to validate the block body against the (now invalid) headers.

Motivation and Context

(Partially) valid headers may become invalid (MMR) once the block body is synced. This PR removes those headers and adds the offending block to a banned block list.

How Has This Been Tested?

Some new unit tests, basic manual test

stringhandler
stringhandler previously approved these changes Dec 1, 2021
@aviator-app aviator-app bot added the mq-failed label Dec 2, 2021
@delta1
Copy link
Contributor

delta1 commented Dec 2, 2021

Looks like a test might need updating?

stringhandler
stringhandler previously approved these changes Dec 3, 2021
@aviator-app aviator-app bot removed the mq-failed label Dec 3, 2021
@aviator-app aviator-app bot added the mq-failed label Dec 3, 2021
therustmonk
therustmonk previously approved these changes Dec 6, 2021
* development:
  fix(pruned mode)!: prune inputs, allow horizon sync resume and other fixes (tari-project#3521)
@aviator-app aviator-app bot removed the mq-failed label Dec 6, 2021
@aviator-app aviator-app bot merged commit 5969723 into tari-project:development Dec 6, 2021
@sdbondi sdbondi deleted the core-bad-blocks-list branch December 6, 2021 12:55
sdbondi added a commit to sdbondi/tari that referenced this pull request Dec 6, 2021
* development:
  feat: bad block list for invalid blocks after sync (tari-project#3637)
sdbondi added a commit to sdbondi/tari that referenced this pull request Dec 6, 2021
* development:
  feat: bad block list for invalid blocks after sync (tari-project#3637)
sdbondi added a commit to sdbondi/tari that referenced this pull request Dec 7, 2021
* development:
  feat(consensus)!: add tari script byte size limit check to validation (tari-project#3640)
  fix: minor improvements to available neighbouring peer search (tari-project#3598)
  feat: bad block list for invalid blocks after sync (tari-project#3637)
@sdbondi sdbondi restored the core-bad-blocks-list branch February 3, 2022 05:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants