Skip to content

[fix][ethereum2][offchain] fix period-tail sync committee verification#75

Open
fengjy73 wants to merge 1 commit into
AntChainOpenLabs:mainfrom
fengjy73:fix/ethereum2-period-tail-verification
Open

[fix][ethereum2][offchain] fix period-tail sync committee verification#75
fengjy73 wants to merge 1 commit into
AntChainOpenLabs:mainfrom
fengjy73:fix/ethereum2-period-tail-verification

Conversation

@fengjy73
Copy link
Copy Markdown
Contributor

@fengjy73 fengjy73 commented Jun 3, 2026

The previous implementation treated period * syncPeriodLength as the last slot of the current sync committee period, but that slot is actually the first slot of the next period. The real period tail is (period + 1) * syncPeriodLength - 1.

On minimal private networks this causes verification failures around 64n - 1 slots, where HCDVS may verify a sync aggregate with the wrong committee or fork domain and report sync committee signature is invalid.

This PR also preserves the actual slot that produced the sync aggregate, so missed slots and period-boundary endorsements no longer rely on guessing block slot + 1.

  • Fix Ethereum2 sync committee period-tail calculation.
  • Carry the actual sync aggregate signature_slot in consensus endorsements.
  • Verify block signatures with the committee matching the real signature period.
  • Keep current and next sync committees separately, and rotate only at the real period boundary.
  • Split block verification from light client update verification.
  • Exclude the duplicate lib/ptc/CommitteePtcVerifier.sol from web3j wrapper generation.

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.

1 participant