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

[crypto] add aggregation for BLS public keys #679

Merged
merged 4 commits into from
Jan 16, 2024

Conversation

wlawt
Copy link
Contributor

@wlawt wlawt commented Jan 15, 2024

Add AggregatePublicKeys as well

Tests:

  • BLS unit tests
  • MorpheusVM Integration test

@wlawt wlawt changed the title [crypto] remove agg function for BLS signatures [crypto] add aggregation for BLS public keys Jan 16, 2024
@@ -36,3 +36,22 @@ func TestPublicKeyBytes(t *testing.T) {
require.Equal(pk, pk2)
require.Equal(pkBytes, pk2Bytes)
}

func TestAggregatePublicKeysNoop(t *testing.T) {
Copy link
Contributor

@patrick-ogrady patrick-ogrady Jan 16, 2024

Choose a reason for hiding this comment

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

Can we add another test that aggregates 2 public keys and 2 signatures and verifies the aggregate signature with the aggregate public key?

require.NoError(err)

// Verifies aggregate signature with aggregate public key
require.True(Verify(msg, aggPks, aggSigs))
Copy link
Contributor

Choose a reason for hiding this comment

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

❤️

@patrick-ogrady patrick-ogrady merged commit f97070b into ava-labs:main Jan 16, 2024
26 of 30 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

2 participants