21 lines
448 B
Python
Raw Normal View History

2024-05-27 18:58:45 +04:00
from noir_constraint import NoirProof
from constraints import Constraint
2024-05-28 23:25:53 +04:00
from crypto import Field
2024-05-27 18:58:45 +04:00
class Vacuous(Constraint):
"""
This is the empty constraint, it return true for any proof
"""
2024-05-28 23:25:53 +04:00
def hash(self):
# chosen by a fair 2**64 sided die.
return Field(14500592324922987342)
2024-05-27 18:58:45 +04:00
def prove(self) -> NoirProof:
return NoirProof("vacuous")
def verify(self, _proof: NoirProof):
return True