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: verification module for drand quicknet #3887

Merged
merged 4 commits into from
Jan 19, 2024

Conversation

hanabi1224
Copy link
Contributor

@hanabi1224 hanabi1224 commented Jan 19, 2024

Summary of changes

Part of #3763

This PR(originally part of #3873) implements the beacon verification logic for drand quicknet.
Please read the G1 - G2 swap section for the details.

Changes introduced in this pull request:

  • Implement quicket beacon verification with unit tests
  • Refactor mainnet beacon verification to support batching with unit tests and replace bls_signatues::verify_messages which is designed to verify bls messages in tipsets instead of beacons

Reference issue to close (if applicable)

Closes

Other information and links

https://drand.love/blog/2023/10/16/quicknet-is-live/

Change checklist

  • I have performed a self-review of my own code,
  • I have made corresponding changes to the documentation,
  • I have added tests that prove my fix is effective or that my feature works (if possible),
  • I have made sure the CHANGELOG is up-to-date. All user-facing changes should be reflected in this document.

@hanabi1224 hanabi1224 marked this pull request as ready for review January 19, 2024 08:34
@hanabi1224 hanabi1224 requested a review from a team as a code owner January 19, 2024 08:34
@hanabi1224 hanabi1224 requested review from lemmih and elmattic and removed request for a team January 19, 2024 08:34
Copy link
Member

@LesnyRumcajs LesnyRumcajs left a comment

Choose a reason for hiding this comment

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

It's some kind of Elvish, I can't read it.

Comment on lines +15 to +16
const CSUITE_G1: &[u8] = b"BLS_SIG_BLS12381G1_XMD:SHA-256_SSWU_RO_NUL_";
const CSUITE_G2: &[u8] = b"BLS_SIG_BLS12381G2_XMD:SHA-256_SSWU_RO_NUL_";
Copy link
Member

Choose a reason for hiding this comment

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

Where do these come from?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Added to the comment

@LesnyRumcajs LesnyRumcajs mentioned this pull request Jan 19, 2024
4 tasks
@hanabi1224 hanabi1224 added this pull request to the merge queue Jan 19, 2024
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Jan 19, 2024
@hanabi1224 hanabi1224 added this pull request to the merge queue Jan 19, 2024
Merged via the queue into main with commit fa6731f Jan 19, 2024
27 checks passed
@hanabi1224 hanabi1224 deleted the hm/drand-quicknet-verification branch January 19, 2024 14:48
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.

3 participants