We currently verify a submitted user batch by re-proving it and verifying it matches the submitted proof. This is because the batch proof kernel does not actually do any proving yet - it simply re-verifies the batch's transaction proofs.
Once the batch kernel lands for real, we should switch to verifying it instead.
|
// Verify batch transaction proofs. |
|
// |
|
// Need to do this because ProvenBatch has no real kernel yet, so we can only |
|
// really check that the calculated proof matches the one given in the request. |
|
let expected_proof = LocalBatchProver::new(MIN_PROOF_SECURITY_LEVEL) |
|
.prove(proposed_batch.clone()) |
|
.map_err(|err| { |
|
Status::invalid_argument(err.as_report_context("proposed block proof failed")) |
|
})?; |
We currently verify a submitted user batch by re-proving it and verifying it matches the submitted proof. This is because the batch proof kernel does not actually do any proving yet - it simply re-verifies the batch's transaction proofs.
Once the batch kernel lands for real, we should switch to verifying it instead.
node/crates/rpc/src/server/api.rs
Lines 475 to 483 in 9437942