Skip to content

Commit

Permalink
recompute Y always
Browse files Browse the repository at this point in the history
  • Loading branch information
callebtc committed Feb 26, 2024
1 parent 13e2a1b commit d048037
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions cashu/core/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -110,8 +110,7 @@ class Proof(BaseModel):

def __init__(self, **data):
super().__init__(**data)
if not self.Y:
self.Y = hash_to_curve(self.secret.encode("utf-8")).serialize().hex()
self.Y = hash_to_curve(self.secret.encode("utf-8")).serialize().hex()

@classmethod
def from_dict(cls, proof_dict: dict):
Expand Down

0 comments on commit d048037

Please sign in to comment.