cryptonote_core: rm confusing/redundant BP consensus rule
What changed, and why it matters
This commit removes a redundant safety check in Monero's transaction validation code. The commit message argues the check was unnecessary because other rules already enforce the same limits: no bulletproofs before protocol version 8, and only one bulletproof covering all outputs from version 8 onward. The change is presented as cleanup, not a security fix.
Verify the author's three cited claims independently: confirm that no Bulletproof path exists before v8, that exactly one Bulletproof is enforced from v8 on, and that the single Bulletproof must cover all outputs. If all three hold, this is a safe cleanup; if any is incomplete or conditional, the removed check could have provided defense in depth and should be restored or replaced.
Security signals we found
Removal of a consensus/validation rule
Author-provided rationale that the rule is redundant with other checks
No accompanying test or advisory indicating a vulnerability
Evidence from the diff
The deleted code in blockchain.cpp rejected multi-output Bulletproofs before hardfork version 8. The commit author states this was redundant because (1) before v8, all Bulletproofs are rejected elsewhere, and (2) from v8 onward, the format utilities enforce exactly one Bulletproof that must cover all transaction outputs. Removing the check therefore should not change accepted transaction behavior, assuming the cited rules are correct and active.
Changed components
src/cryptonote_core/blockchain.cppTransaction input validation (check_tx_inputs)Bulletproof range-proof consensus rulesInspect captured patch +0 / −16
diff --git a/src/cryptonote_core/blockchain.cpp b/src/cryptonote_core/blockchain.cpp
index 552dbb6..81c0716 100644
--- a/src/cryptonote_core/blockchain.cpp
+++ b/src/cryptonote_core/blockchain.cpp
@@ -3606,22 +3606,6 @@ bool Blockchain::check_tx_inputs(transaction& tx, tx_verification_context &tvc,
MERROR_VER("Unsupported rct type: " << rv.type);
return false;
}
-
- // for bulletproofs, check they're only multi-output after v8
- if (rct::is_rct_bulletproof(rv.type))
- {
- if (hf_version < 8)
- {
- for (const rct::Bulletproof &proof: rv.p.bulletproofs)
- {
- if (proof.V.size() > 1)
- {
- MERROR_VER("Multi output bulletproofs are invalid before v8");
- return false;
- }
- }
- }
- }
}
return true;
}
Why this scored 12/100
Community notes
Notes can correct, qualify, or add evidence to the AI analysis. Every note shown here has been validated by a human moderator.
The AI analysis stands alone for now. Submit a note if you can add evidence or important context.