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

fix: add exclusive constraint for Miller loop and Final exp masks #174

Open
wants to merge 10 commits into
base: fix/audit-la-i-firstline-binary
Choose a base branch
from

Conversation

ivokub
Copy link
Contributor

@ivokub ivokub commented Oct 10, 2024

This PR fixes LA audit Issue J.

We didn't have constraint which required ToMillerLoopCircuitMask and ToFinalExpCircuitMask to be exclusive. The recommendation was to check that they are exclusive and sum equals to ECPair.IsActive.

However, I couldn't add this constraint as ECPair.IsActive may also hold for G2 membership data. I added additional ECPair.UnalignedPairingData.IsActive column and corresponding constraints to ensure that only G2 membership data or pairing data submodules are active at a time.

Additionally, I added constraints to ensure the IsComputed/IsPulling columns are only set when the corresponding submodules were active. This allowed to remove previous explicit binary constraints as they are already checked in common_constraints package.

Finally, updated the tests to check that the newly added UnalignedPairingData.IsActive column is correctly computed.

NB! This PR depends on #173 (which depends on #172). After the previous PRs are merged then update the base branch for this PR to main.

Checklist

  • I wrote new tests for my new core changes.
  • I have successfully ran tests, style checker and build against my new changes locally.
  • I have informed the team of any breaking changes if there are any.

@ivokub ivokub added bug Something isn't working Prover Tag to use for all work impacting the prover labels Oct 10, 2024
@ivokub ivokub self-assigned this Oct 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working Prover Tag to use for all work impacting the prover
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant