-
Notifications
You must be signed in to change notification settings - Fork 146
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
How to specify the verification key and public / private inputs #369
Comments
Okay, found the way to get all inputs and outputs from the proof, and also a bug! Adding these lines just after generating the proof: println!("proof.proof.program_io.inputs: {:?}", &proof.proof.program_io.inputs);
println!("proof.proof.program_io.outputs: {:?}", &proof.proof.program_io.outputs); prints out:
So, questions:
Pushed the above example here: imikushin@0ca5de1 |
Hi Ivan, Good question, and thanks for flagging. Currently there is no way to hide some of the inputs; Jolt currently isn't "hiding" (and probably won't be until we compose the prover with Groth16). Re: the example linked, the It's still kind of strange to me that the raw byte representation would be |
The byte representation of the inputs and outputs is from encoding using the |
Thanks @ncitron! let (proof_p, proof_a, proof_b): (i32, i32, i32) = postcard::from_bytes(&proof.proof.program_io.inputs).unwrap();
let proof_output: bool = postcard::from_bytes(&proof.proof.program_io.outputs).unwrap();
println!("(proof_p, proof_a, proof_b): {:?}", (proof_p, proof_a, proof_b));
println!("proof_output: {:?}", proof_output); prints:
|
The original issue, boiling down to marking some of the inputs as private and omitting them from the proof, still stands though. I'm willing to help address it. |
Opened a new issue: #371 Closing this one as I feel it's resolved. |
RV32IJoltVM::verify
requires aJoltPreprocessing
, which I guess is easy to obtain by callingRV32IJoltVM::preprocess
with the bytecode of the program we're tryin to verify. Is this the recommended way at the moment?Also, how do we specify public inputs when verifying a function run?
For example, we have a guest function:
In this example, I'd like to specify the value of
p
as public input when verifying this function for a set of arguments, some of which I'd like to keep private (a
andb
).I can't figure if this is currently possible. This is the flow as I currently see it:
What I can't see is how I can verify the proof against the particular public input value (
p == 15
)The text was updated successfully, but these errors were encountered: