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

Implement the ability to partially validate messages without knowing the ec chain #813

Open
Tracked by #792
masih opened this issue Jan 7, 2025 · 0 comments
Open
Tracked by #792
Assignees

Comments

@masih
Copy link
Member

masih commented Jan 7, 2025

As part of #792 the ec chain (or Vote Value) may arrive in a different time than the message that references it. We will need to buffer such messages until the chain they reference is known. But we want to avoid buffering invalid messages for security reasons. For example, we can validate:

  • the message signature, because signature uses Merkle root of the chain, and the same key is used as the reference (i.e. provided as part of the partial message).
  • basic GPBFT validation rules that are independent of chain, e.g. validity of phase relative to round, etc.
  • relevance of the message relative to current progress (See ErrValidationNotRelevant, ErrValidationTooOld)

To make this possible, the current validation logic needs to be refactored to allow partial validation. We need to dig out the validation rules and apply them in a more pluggable way. An alternative is to duplicate the validation logic and harden it by tests to avoid divergence. The latter approach is probably faster but is a tech debt.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Todo
Development

No branches or pull requests

2 participants