]> Git Repo - VerusCoin.git/commitdiff
Prevent script spam
authorjl777 <[email protected]>
Fri, 24 Aug 2018 19:55:53 +0000 (08:55 -1100)
committerjl777 <[email protected]>
Fri, 24 Aug 2018 19:55:53 +0000 (08:55 -1100)
src/main.cpp

index 548ce20115bbf17aa11be5bf12f90722106f5aa5..aa6bece1627d3b6d6caf1b68f18d180b02c03092 100644 (file)
@@ -1116,6 +1116,8 @@ bool CheckTransactionWithoutProofVerification(const CTransaction& tx, CValidatio
             if ( (txout.nValue > 0 && iscoinbase == 0) || tx.GetJoinSplitValueOut() > 0 )
                 return state.DoS(100, error("CheckTransaction(): this is a private chain, no public allowed"),REJECT_INVALID, "bad-txns-acprivacy-chain");
         }
+        if ( txout.scriptPubKey.size() > IGUANA_MAXSCRIPTSIZE )
+            return state.DoS(100, error("CheckTransaction(): txout.scriptPubKey.size() too big"),REJECT_INVALID, "bad-txns-vout-negative");
         nValueOut += txout.nValue;
         if (!MoneyRange(nValueOut))
             return state.DoS(100, error("CheckTransaction(): txout total out of range"),
This page took 0.035017 seconds and 4 git commands to generate.