feat: Compute random action for session proofs#377
Merged
paolodamico merged 11 commits intomainfrom Feb 17, 2026
Merged
Conversation
paolodamico
reviewed
Feb 9, 2026
crates/request/src/lib.rs
Outdated
| match self.action { | ||
| Some(action) => action, | ||
| None => todo!("Not ready"), | ||
| None => FieldElement::from_arbitrary_raw_bytes(self.nonce.to_string().as_bytes()), |
Collaborator
There was a problem hiding this comment.
hmm I'm not sure this is a good idea, this delegates the entropy to the RP and lets the RP somewhat influence the nullifier. it may be fine, but best to be on the safe side with a simple random field element generation here
…-action # Conflicts: # crates/request/src/lib.rs
…-action # Conflicts: # crates/request/Cargo.toml
paolodamico
approved these changes
Feb 10, 2026
…-action # Conflicts: # Cargo.lock # crates/request/Cargo.toml
paolodamico
approved these changes
Feb 12, 2026
paolodamico
approved these changes
Feb 17, 2026
dkales
approved these changes
Feb 17, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR generates the action deterministically based on the request
nonce. The idea behind this was to have the same action per request.Awaiting feedback from @paolodamico