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

[ZKS-02] Use committee lookback at anchor_round - 1 for timestamp calculation #2358

Merged
merged 5 commits into from
Feb 16, 2024

Conversation

raychu86
Copy link
Contributor

Motivation

This PR is a continuation of https://github.com/AleoHQ/snarkVM/pull/2353, and fixes the committee usage for timestamp calculation. Previously, we were selecting the committee lookback based on the anchor round, however we should have been using the committee lookback based on anchor_round - 1.

This is needed because the timestamp is calculated with the weighted median using certificates in anchor_round - 1 for the committed subdag. Note that the previous approach was not an issue with static committees, however with more complex bond/unbond state, it was insufficient.

Audit Finding: [zksecurity 02] Dynamic Committee Feature is Not Safe

@raychu86 raychu86 force-pushed the feat/timestamp-committee branch from ad748ac to bbd466f Compare February 16, 2024 00:07
@howardwu howardwu merged commit bb54fc4 into mainnet Feb 16, 2024
0 of 8 checks passed
@howardwu howardwu deleted the feat/timestamp-committee branch February 16, 2024 18:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants