Skip to content

Gadget verify creates unsatisfied constraints when passed a default proof  #7

@nirvantyagi

Description

@nirvantyagi

This issue was run into on the zexe library and has not been attempted to be reproduced on arkworks yet.

The constraints method verify for computing a BooleanVar representing whether a proof is valid or not produces unsatisfied constraints when a Default::default proof is passed as input. The correct behavior would be to simply return a BooleanVar with value false.

The method works as expected when passing in the correct proof (returns a true BooleanVar) or passing in a proof with values not initialized to Default, e.g. random group elements or canonical generator (returns a false BooleanVar). This indicates that there might be some odd behavior with how verify interacts with a proof that has 0 values (which I believe is what Default sets the group elements to).

https://github.com/arkworks-rs/groth16/blob/master/src/constraints.rs#L243

Metadata

Metadata

Assignees

No one assigned

    Labels

    D-mediumDifficulty: mediumP-mediumPriority: mediumT-bugType: bug

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions