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

[TASK] Sync the order of public inputs for R1CS and PLONK #180

Open
lazovicff opened this issue Mar 1, 2022 · 1 comment
Open

[TASK] Sync the order of public inputs for R1CS and PLONK #180

lazovicff opened this issue Mar 1, 2022 · 1 comment

Comments

@lazovicff
Copy link
Contributor

For Mixer:

  1. nullifier_hash
  2. root
  3. arbitrary data

For Anchor:

  1. chain_id
  2. nullifier_hash
  3. arbitrary_data
  4. roots[]

For VAnchor:

  1. public_amount
  2. public_chain_id
  3. arbitrary_data
  4. in_nullifier_hashes[]
  5. in_root_set[]
  6. out_commitments[]

We would have to sacrifice some of the performance to achieve this in PLONK. For example:
Set gadgets expects a set to be Vec<F> which are public inputs (https://github.com/webb-tools/arkworks-gadgets/blob/master/arkworks-plonk-circuits/src/set_membership/mod.rs#L15). They are inserted into the circuit at the specific time to avoid additional gates. We would have make a standard for PLONK to give us control where the public inputs are defined, which will make it easier for make PLONK and R1CS interoperable.

@lazovicff
Copy link
Contributor Author

Should be equal to solidity side

@dutterbutter dutterbutter moved this to Not Started 🕧 in Webb Universe Apr 6, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Not Started 🕧
Development

No branches or pull requests

1 participant