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

feat: new handle computation method #507

Merged
merged 1 commit into from
Sep 17, 2024
Merged

feat: new handle computation method #507

merged 1 commit into from
Sep 17, 2024

Conversation

jatZama
Copy link
Member

@jatZama jatZama commented Sep 17, 2024

In summary: when computing any handle (except for fheRand(Bounded) and user inputs inside verifyCiphertext) , in the preimage of the hash we append both the ACL address and chainID.
For fheRand(Bounded), we also take into account both of the ACL address and chainID, but we are also adding the timestamp (proportional to the slot) as well as the blockhash of the previous block in the preimage of the seed given to the OPRF - taking the first 16 bytes from the 32 bytes of the hash since the OPRF takes u128 inputs as seed. This seed is then also used in the preimage of the handle.

I guess for user inputs, the ZKPOK metadata should also include both of ACL address and chainID for consistency, wdyt @mortendahl @immortal-tofu ?

@jatZama jatZama merged commit ff22021 into main Sep 17, 2024
3 checks passed
@jatZama jatZama deleted the newHandlesComputation branch September 17, 2024 16:18
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