Skip to content

Circuit: Check pk_d_old = derived_pk_d_old only when split_flag = 0#64

Merged
PaulLaux merged 1 commit intozsa1from
pk_d_old_check_and_split_flag
May 29, 2023
Merged

Circuit: Check pk_d_old = derived_pk_d_old only when split_flag = 0#64
PaulLaux merged 1 commit intozsa1from
pk_d_old_check_and_split_flag

Conversation

@ConstanceBeguier
Copy link
Collaborator

In the circuit derived_pk_d_old is evaluated from rivk, ak, nk and g_d_old.
rivk, ak and nk comes from the FullViewingKey stored in the spent note.
For split note, the FullViewingKey stored in the spent note is random in order to derive a random Nullifier nf_old.
Thus, the constraint pk_d_old = derived_pk_d_old must not be checked for split note (split_flag=1).

@ConstanceBeguier ConstanceBeguier requested a review from PaulLaux May 26, 2023 11:33
@what-the-diff
Copy link

what-the-diff bot commented May 26, 2023

PR Summary

  • Add a new constraint to the Orchard circuit checks
    This change introduces an additional constraint to ensure the split_flag is set to 1 or the derived public key remains the same as the original public key. This helps in maintaining data consistency and correct functioning of the system.

@PaulLaux PaulLaux merged commit 95fcf88 into zsa1 May 29, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants