aboutsummaryrefslogtreecommitdiff
path: root/src/policy/policy.cpp
AgeCommit message (Collapse)Author
2017-07-17Remove factor of 3 from definition of dust.Alex Morcos
This redefines dust to be the value of an output such that it would cost that value in fees to (create and) spend the output at the dust relay rate. The previous definition was that it would cost 1/3 of the value. The default dust relay rate is correspondingly increased to 3000 sat/kB so the actual default dust output value of 546 satoshis for a non-segwit output remains unchanged. This commit is a refactor only unless a dustrelayfee is passed on the commandline in which case that number now needs to be increased by a factor of 3 to get the same behavior. -dustrelayfee is a hidden command line option. Note: It's not exactly a refactor due to edge case changes in rounding as evidenced by the required change to the unit test.
2017-07-14Remove confusing MAX_BLOCK_BASE_SIZE.Gregory Maxwell
Some people keep thinking that MAX_BLOCK_BASE_SIZE is a separate size limit from the weight limit when it fact it is superfluous, and used in early tests before the witness data has been validated or just to compute worst case sizes. The size checks that use it would not behave any differently consensus wise if they were eliminated completely. Its correct value is not independently settable but is a function of the weight limit and weight formula. This patch just eliminates it and uses the scale factor as required to compute the worse case constants. It also moves the weight factor out of primitives into consensus, which is a more logical place for it.
2017-06-22scripted-diff: Remove #include <boost/foreach.hpp>Jorge Timón
-BEGIN VERIFY SCRIPT- sed -i ':a;N;$!ba;s/#include <boost\/foreach.hpp>\n//' ./src/*.h ./src/*.cpp ./src/*/*.h ./src/*/*.cpp ./src/*/*/*.h ./src/*/*/*.cpp -END VERIFY SCRIPT-
2017-06-05scripted-diff: Fully remove BOOST_FOREACHJorge Timón
-BEGIN VERIFY SCRIPT- sed -i 's/BOOST_FOREACH *(\(.*\),/for (\1 :/' ./src/*.h ./src/*.cpp ./src/*/*.h ./src/*/*.cpp ./src/*/*/*.h ./src/*/*/*.cpp ; -END VERIFY SCRIPT-
2017-06-01Merge CCoinsViewCache's GetOutputFor and AccessCoinPieter Wuille
They're doing the same thing now.
2017-05-19Prevent shadowing the global dustRelayFee.Pavel Janík
2017-05-03Consensus: Minimal way to move dust out of consensusJorge Timón
2017-04-13Missing includesJorge Timón
2017-01-16Introduce -dustrelayfeeAlex Morcos
2017-01-16Introduce -incrementalrelayfeeAlex Morcos
2016-12-04Move CTxInWitness inside CTxInPieter Wuille
2016-12-02Rename the remaining main.{h,cpp} to validation.{h,cpp}Matt Corallo
2016-11-14update comments for tx weightBrian Deery
2016-11-06[copyright] copyright header style uniformisle2983
Three categories of modifications: 1) 1 instance of 'The Bitcoin Core developers \n', 1 instance of 'the Bitcoin Core developers\n', 3 instances of 'Bitcoin Core Developers\n', and 12 instances of 'The Bitcoin developers\n' are made uniform with the 443 instances of 'The Bitcoin Core developers\n' 2) 3 instances of 'BitPay, Inc\.\n' are made uniform with the other 6 instances of 'BitPay Inc\.\n' 3) 4 instances where there was no '(c)' between the 'Copyright' and the year where it deviates from the style of the local directory.
2016-10-16Add standard limits for P2WSH with testsJohnson Lau
2016-07-26Merge #8381: Make witness v0 outputs non-standardWladimir J. van der Laan
c59c434 qa: Add test for standardness of segwit v0 outputs (Suhas Daftuar) 1ffaff2 Make witness v0 outputs non-standard before segwit activation (Johnson Lau)
2016-07-23qa: Add test for standardness of segwit v0 outputsSuhas Daftuar
2016-07-22Make witness v0 outputs non-standard before segwit activationJohnson Lau
2016-07-19Treat high-sigop transactions as larger rather than rejecting themPieter Wuille
2016-07-18Rename "block cost" to "block weight"Suhas Daftuar
2016-06-22BIP141: Other consensus critical limits, and BIP145Pieter Wuille
Includes changes by Suhas Daftuar, Luke-jr, and mruddy.
2016-06-22BIP143: Verification logicPieter Wuille
Includes simplifications by Eric Lombrozo.
2016-04-08Doc: Update isStandardTx commentMatthew English
2016-03-18Policy: allow transaction version 2 relay policy.BtcDrak
This commit introduces a way to gracefully bump the default transaction version in a two step process.
2016-02-01Get rid of inaccurate ScriptSigArgsExpectedPieter Wuille
(cherry picked from commit 52b29dca7670c3f6d2ab918c0fff1d17c4e494ad)
2016-01-07Merge pull request #7266Wladimir J. van der Laan
6cd198f Removed comment about IsStandard for P2SH scripts (Marcel Krüger)
2015-12-30Removed comment about IsStandard for P2SH scriptsMarcel Krüger
Since #4365 (62599373883a66a958136f48ab0e2b826e3d5bf8) P2SH scripts do not have to be IsStandard scripts.
2015-12-13Bump copyright headers to 2015MarcoFalke
2015-11-28Constrain constant values to a single location in codeLuke Dashjr
2015-10-01Accept any sequence of PUSHDATAs in OP_RETURN outputsPeter Todd
Previously only one PUSHDATA was allowed, needlessly limiting applications such as matching OP_RETURN contents with bloom filters that operate on a per-PUSHDATA level. Now any combination that passes IsPushOnly() is allowed, so long as the total size of the scriptPubKey is less than 42 bytes. (unchanged modulo non-minimal PUSHDATA encodings) Also, this fixes the odd bug where previously the PUSHDATA could be replaced by any single opcode, even sigops consuming opcodes such as CHECKMULTISIG. (20 sigops!)
2015-06-26Policy: MOVEONLY: 3 functions to policy.o:Luke Dashjr
- [script/standard.o] IsStandard - [main.o] IsStandardTx - [main.o] AreInputsStandard Also, don't use namespace std in policy.cpp