Merge pull request #3418

20a00266 blockchain: forbid bulletproof types before v8 (moneromooo-monero)
This commit is contained in:
Riccardo Spagni 2018-03-17 16:51:47 +02:00
commit 83651630bc
No known key found for this signature in database
GPG Key ID: 55432DF31CCD4FCD
1 changed files with 2 additions and 1 deletions

View File

@ -2446,7 +2446,8 @@ bool Blockchain::check_tx_outputs(const transaction& tx, tx_verification_context
// from v8, allow bulletproofs
if (hf_version < 8) {
if (!tx.rct_signatures.p.bulletproofs.empty())
const bool bulletproof = tx.rct_signatures.type == rct::RCTTypeFullBulletproof || tx.rct_signatures.type == rct::RCTTypeSimpleBulletproof;
if (bulletproof || !tx.rct_signatures.p.bulletproofs.empty())
{
MERROR("Bulletproofs are not allowed before v8");
tvc.m_invalid_output = true;