From 6c62a68c96f52aa1466fc167d831932369ac08b4 Mon Sep 17 00:00:00 2001 From: samkim-crypto Date: Fri, 12 Jan 2024 21:58:33 +0900 Subject: [PATCH] [zk-token-proof] include `VerifyBatchRangeProofU256` in the `enable_zk_transfer_with_fee` feature gate (#34747) include `VerifyBatchRangeProofU256` in the `enable_zk_transfer_with_fee` feature (cherry picked from commit bc136423b4a6f4609e2d07a0b863bc452b84a3ea) --- programs/zk-token-proof/src/lib.rs | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/programs/zk-token-proof/src/lib.rs b/programs/zk-token-proof/src/lib.rs index 9a9396b15f1fdb..e262950201181a 100644 --- a/programs/zk-token-proof/src/lib.rs +++ b/programs/zk-token-proof/src/lib.rs @@ -257,6 +257,11 @@ declare_process_instruction!(Entrypoint, 0, |invoke_context| { ) } ProofInstruction::VerifyBatchedRangeProofU256 => { + // transfer with fee related proofs are not enabled + if !enable_zk_transfer_with_fee { + return Err(InstructionError::InvalidInstructionData); + } + if native_programs_consume_cu { invoke_context .consume_checked(VERIFY_BATCHED_RANGE_PROOF_U256_COMPUTE_UNITS)