dash/src
Wladimir J. van der Laan 35d60de2b5 Merge #11458: Don't process unrequested, low-work blocks
01b52ce Add comment explaining forced processing of compact blocks (Suhas Daftuar)
08fd822 qa: add test for minchainwork use in acceptblock (Suhas Daftuar)
ce8cd7a Don't process unrequested, low-work blocks (Suhas Daftuar)

Pull request description:

  A peer could try to waste our resources by sending us unrequested blocks with
  low work (eg to fill up our disk).  Since e265200 we no longer request blocks until we
  know we're on a chain with more than nMinimumChainWork (our anti-DoS
  threshold), but we would still process unrequested blocks that had more work
  than our tip (which generally has low-work during IBD), even though we may not
  yet have found a headers chain with sufficient work.

  Fix this and add a test.

Tree-SHA512: 1a4fb0bbd78054b84683f995c8c3194dd44fa914dc351ae4379c7c1a6f83224f609f8b9c2d9dde28741426c6af008ffffea836d21aa31a5ebaa00f8e0f81229e
2019-09-29 12:42:14 +02:00
..
bench Merge #10662: Initialize randomness in benchmarks 2019-09-03 22:21:17 -05:00
bls Fix excessive memory use when flushing chainstate and EvoDB (#3008) 2019-07-02 07:16:27 +03:00
compat Merge #9544: [trivial] Add end of namespace comments. Improve consistency. 2019-07-11 10:34:46 -05:00
config
consensus scripted-diff: Refactor llmq type consensus param names (#3093) 2019-09-24 12:38:50 +03:00
crypto #10483 scripted-diff: Use the C++11 keyword nullptr to denote the pointer literal instead of the macro NULL 2019-08-12 09:07:03 -05:00
evo Remove unused code (#3097) 2019-09-22 23:45:22 +03:00
governance Respect logips config option in few more log outputs (#3078) 2019-09-22 23:48:15 +03:00
immer Update immer library to current master (0a718d2d76bab6ebdcf43de943bd6c7d2dbfe2f9) (#2821) 2019-04-01 14:10:49 +03:00
leveldb Merge #10958: Update to latest Bitcoin patches for LevelDB 2019-08-12 09:07:03 -05:00
llmq A couple of minor improvements in IS code (#3114) 2019-09-27 20:25:45 +02:00
masternode Respect logips config option in few more log outputs (#3078) 2019-09-22 23:48:15 +03:00
obj
obj-test
policy Merge pull request #3101 from codablock/pr_backports_v15_v16_1 2019-09-22 23:44:41 +03:00
primitives Merge #10892: Replace traditional for with ranged for in block and transaction primitives 2019-08-01 14:36:08 -05:00
privatesend Respect logips config option in few more log outputs (#3078) 2019-09-22 23:48:15 +03:00
qt Merge pull request #3111 from codablock/pr_backports_v15_v16_3 2019-09-28 00:47:12 +03:00
rpc Merge pull request #3111 from codablock/pr_backports_v15_v16_3 2019-09-28 00:47:12 +03:00
script A few compilation fixes 2019-09-24 17:47:35 +02:00
secp256k1 Merge #10633: doc: Fix various typos 2019-07-11 10:34:46 -05:00
support #10483 scripted-diff: Use the C++11 keyword nullptr to denote the pointer literal instead of the macro NULL 2019-08-12 09:07:03 -05:00
test Merge #10357: Allow setting nMinimumChainWork on command line 2019-09-29 12:42:14 +02:00
univalue
wallet Merge #11476: Avoid opening copied wallet databases simultaneously 2019-09-29 12:42:14 +02:00
zmq #10483 scripted-diff: Use the C++11 keyword nullptr to denote the pointer literal instead of the macro NULL 2019-08-12 09:07:03 -05:00
.clang-format \#10193 clang-format: Delete ForEachMacros 2019-07-24 11:59:09 -05:00
addrdb.cpp Merge #10248: Rewrite addrdb with less duplication using CHashVerifier 2019-07-11 10:34:46 -05:00
addrdb.h Merge #10248: Rewrite addrdb with less duplication using CHashVerifier 2019-07-11 10:34:46 -05:00
addressindex.h
addrman.cpp Respect logips config option in few more log outputs (#3078) 2019-09-22 23:48:15 +03:00
addrman.h #10483 scripted-diff: Use the C++11 keyword nullptr to denote the pointer literal instead of the macro NULL 2019-08-12 09:07:03 -05:00
amount.h Merge #9279: Consensus: Move CFeeRate out of libconsensus 2019-06-26 15:26:07 -05:00
arith_uint256.cpp Merge #10530: Fix invalid instantiation and possibly unsafe accesses of array in class base_uint<BITS> 2019-07-11 10:34:46 -05:00
arith_uint256.h #10483 scripted-diff: Use the C++11 keyword nullptr to denote the pointer literal instead of the macro NULL 2019-08-12 09:07:03 -05:00
base58.cpp #10483 scripted-diff: Use the C++11 keyword nullptr to denote the pointer literal instead of the macro NULL 2019-08-12 09:07:03 -05:00
base58.h #10483 scripted-diff: Use the C++11 keyword nullptr to denote the pointer literal instead of the macro NULL 2019-08-12 09:07:03 -05:00
batchedlogger.cpp Update copyright date (2019) (#2970) 2019-06-11 14:46:07 +03:00
batchedlogger.h Backport Bitcoin#9424, Bitcoin#10123 and Bitcoin#10153 (#2918) 2019-05-23 00:51:39 +03:00
bip39_english.h
bip39.cpp
bip39.h
blockencodings.cpp Merge #10553: Simplify "bool x = y ? true : false". Remove unused function and trailing semicolon. 2019-07-09 13:08:20 -05:00
blockencodings.h
bloom.cpp #10193 scripted-diff: Remove #include <boost/foreach.hpp> 2019-07-24 11:59:09 -05:00
bloom.h Merge #9750: Bloomfilter: parameter variables made constant 2019-06-24 11:39:34 -05:00
cachemap.h Update copyright date (2019) (#2970) 2019-06-11 14:46:07 +03:00
cachemultimap.h Update copyright date (2019) (#2970) 2019-06-11 14:46:07 +03:00
chain.cpp #10483 scripted-diff: Use the C++11 keyword nullptr to denote the pointer literal instead of the macro NULL 2019-08-12 09:07:03 -05:00
chain.h #10483 scripted-diff: Use the C++11 keyword nullptr to denote the pointer literal instead of the macro NULL 2019-08-12 09:07:03 -05:00
chainparams.cpp scripted-diff: Refactor llmq type consensus param names (#3093) 2019-09-24 12:38:50 +03:00
chainparams.h Use chainparams factory for devnet (#3087) 2019-09-17 15:08:37 +03:00
chainparamsbase.cpp Change regtest and devnet p2p/rpc ports (#3064) 2019-08-28 10:52:00 +03:00
chainparamsbase.h Merge #8855: Use a proper factory for creating chainparams 2019-06-26 12:45:10 -05:00
chainparamsseeds.h
checkpoints.cpp #10483 scripted-diff: Use the C++11 keyword nullptr to denote the pointer literal instead of the macro NULL 2019-08-12 09:07:03 -05:00
checkpoints.h
checkqueue.h #10483 scripted-diff: Use the C++11 keyword nullptr to denote the pointer literal instead of the macro NULL 2019-08-12 09:07:03 -05:00
clientversion.cpp
clientversion.h Merge #10168: Fix build warning from #error text 2019-06-14 01:25:59 -05:00
coins.cpp Merge #10148: Use non-atomic flushing with block replay 2019-08-01 14:57:28 -05:00
coins.h Merge #10148: Use non-atomic flushing with block replay 2019-08-01 14:57:28 -05:00
compat.h Merge #10865: Move CloseSocket out of SetSocketNonBlocking and pass socket as const reference 2019-08-12 09:07:03 -05:00
compressor.cpp Merge #9804: Fixes subscript 0 (&var[0]) where should use (var.data()) instead. 2019-07-17 19:01:41 -05:00
compressor.h
core_io.h Merge #10999: Fix amounts formatting in decoderawtransaction 2019-08-12 09:07:03 -05:00
core_memusage.h Merge #10760: Avoid dereference-of-casted-pointer 2019-07-24 11:59:09 -05:00
core_read.cpp Merge #10792: Replace MAX_OPCODE for OP_NOP10. 2019-08-12 09:07:03 -05:00
core_write.cpp Add missing tx type to TxToUniv (#3069) 2019-08-28 10:54:44 +03:00
ctpl.h
cuckoocache.h Merge #10577: Add an explanation of quickly hashing onto a non-power of two range. 2019-07-11 10:34:46 -05:00
cxxtimer.hpp
dash-cli-res.rc
dash-cli.cpp Dashify 2019-08-13 11:27:56 -05:00
dash-tx-res.rc
dash-tx.cpp BIP143: Signing logic 2019-09-20 11:09:59 +02:00
dashd-res.rc
dashd.cpp Merge #10919: Fix more init bugs. 2019-09-20 10:30:04 -05:00
dbwrapper.cpp #10483 scripted-diff: Use the C++11 keyword nullptr to denote the pointer literal instead of the macro NULL 2019-08-12 09:07:03 -05:00
dbwrapper.h #10483 scripted-diff: Use the C++11 keyword nullptr to denote the pointer literal instead of the macro NULL 2019-08-12 09:07:03 -05:00
dsnotificationinterface.cpp #10483 scripted-diff: Use the C++11 keyword nullptr to denote the pointer literal instead of the macro NULL 2019-08-12 09:07:03 -05:00
dsnotificationinterface.h Drop CDSNotificationInterface::SyncTransaction() 2019-05-28 11:59:55 +02:00
flat-database.h Update copyright date (2019) (#2970) 2019-06-11 14:46:07 +03:00
fs.cpp Merge #10546: Remove 33 unused Boost includes 2019-07-08 13:50:05 -05:00
fs.h Merge #10432: [Trivial] Add BITCOIN_FS_H endif footer in fs.h 2019-06-24 11:39:34 -05:00
hash.cpp Merge #9804: Fixes subscript 0 (&var[0]) where should use (var.data()) instead. 2019-07-17 19:01:41 -05:00
hash.h Update copyright date (2019) (#2970) 2019-06-11 14:46:07 +03:00
hdchain.cpp Update copyright date (2019) (#2970) 2019-06-11 14:46:07 +03:00
hdchain.h Update copyright date (2019) (#2970) 2019-06-11 14:46:07 +03:00
httprpc.cpp Merge #10849: Multiwallet: simplest endpoint support 2019-08-01 09:05:19 -05:00
httprpc.h Merge #10568: Remove unnecessary forward class declarations in header files 2019-07-09 13:08:20 -05:00
httpserver.cpp #10483 scripted-diff: Use the C++11 keyword nullptr to denote the pointer literal instead of the macro NULL 2019-08-12 09:07:03 -05:00
httpserver.h Merge #10849: Multiwallet: simplest endpoint support 2019-08-01 09:05:19 -05:00
indirectmap.h
init.cpp Merge #10357: Allow setting nMinimumChainWork on command line 2019-09-29 12:42:14 +02:00
init.h Merge #10832: init: Factor out AppInitLockDataDirectory and fix startup core dump issue 2019-08-01 09:02:48 -05:00
keepass.cpp #10483 scripted-diff: Use the C++11 keyword nullptr to denote the pointer literal instead of the macro NULL 2019-08-12 09:07:03 -05:00
keepass.h Update copyright date (2019) (#2970) 2019-06-11 14:46:07 +03:00
key.cpp #10483 scripted-diff: Use the C++11 keyword nullptr to denote the pointer literal instead of the macro NULL 2019-08-12 09:07:03 -05:00
key.h Merge #11081: Add length check for CExtKey deserialization (jonasschnelli, guidovranken) 2019-09-23 20:49:54 +02:00
keystore.cpp Merge #10546: Remove 33 unused Boost includes 2019-07-08 13:50:05 -05:00
keystore.h Merge #10546: Remove 33 unused Boost includes 2019-07-08 13:50:05 -05:00
limitedmap.h Collection of minor performance optimizations (#2855) 2019-04-11 15:42:14 +03:00
Makefile.am Merge #9172: Resurrect pstratem's "Simple fuzzing framework" 2019-08-24 10:22:40 -05:00
Makefile.bench.include Merge #15649: Add ChaCha20Poly1305@Bitcoin AEAD 2019-07-23 09:14:30 -05:00
Makefile.leveldb.include Merge #10806: build: verify that the assembler can handle crc32 functions 2019-07-17 19:01:41 -05:00
Makefile.qt.include Backport #12783: macOS: disable AppNap during sync (and mixing) (#3024) 2019-07-15 14:38:55 +03:00
Makefile.qttest.include Merge #11234: Remove redundant testutil.cpp|h files 2019-09-24 17:47:35 +02:00
Makefile.test.include Merge #11433: qa: Restore bitcoin-util-test py2 compatibility 2019-09-24 17:47:35 +02:00
memusage.h #10193 scripted-diff: Remove #include <boost/foreach.hpp> 2019-07-24 11:59:09 -05:00
merkleblock.cpp Merge #9980: Fix mem access violation merkleblock 2019-07-24 11:59:09 -05:00
merkleblock.h Merge #9980: Fix mem access violation merkleblock 2019-07-24 11:59:09 -05:00
messagesigner.cpp Update copyright date (2019) (#2970) 2019-06-11 14:46:07 +03:00
messagesigner.h Update copyright date (2019) (#2970) 2019-06-11 14:46:07 +03:00
miner.cpp Merge bitcoin#8329: Consensus: MOVEONLY: Move functions for tx verification (#3030) 2019-07-23 12:20:23 +03:00
miner.h Merge #10568: Remove unnecessary forward class declarations in header files 2019-07-09 13:08:20 -05:00
net_processing.cpp Merge #11458: Don't process unrequested, low-work blocks 2019-09-29 12:42:14 +02:00
net_processing.h Merge #9725: CValidationInterface Cleanups 2019-05-27 09:03:19 -05:00
net.cpp Respect logips config option in few more log outputs (#3078) 2019-09-22 23:48:15 +03:00
net.h Respect logips config option in few more log outputs (#3078) 2019-09-22 23:48:15 +03:00
netaddress.cpp #10483 scripted-diff: Use the C++11 keyword nullptr to denote the pointer literal instead of the macro NULL 2019-08-12 09:07:03 -05:00
netaddress.h #10483 scripted-diff: Use the C++11 keyword nullptr to denote the pointer literal instead of the macro NULL 2019-08-12 09:07:03 -05:00
netbase.cpp Merge #11397: net: Improve and document SOCKS code 2019-09-25 10:33:21 +02:00
netbase.h Merge #10865: Move CloseSocket out of SetSocketNonBlocking and pass socket as const reference 2019-08-12 09:07:03 -05:00
netfulfilledman.cpp Update copyright date (2019) (#2970) 2019-06-11 14:46:07 +03:00
netfulfilledman.h Update copyright date (2019) (#2970) 2019-06-11 14:46:07 +03:00
netmessagemaker.h Optimize DKG debug message processing for performance and lower bandwidth (#2672) 2019-02-01 10:49:01 +03:00
noui.cpp
noui.h
pow.cpp #10483 scripted-diff: Use the C++11 keyword nullptr to denote the pointer literal instead of the macro NULL 2019-08-12 09:07:03 -05:00
pow.h
prevector.h #10483 scripted-diff: Use the C++11 keyword nullptr to denote the pointer literal instead of the macro NULL 2019-08-12 09:07:03 -05:00
protocol.cpp Merge #9544: [trivial] Add end of namespace comments. Improve consistency. 2019-07-11 10:34:46 -05:00
protocol.h Merge #10842: Fix incorrect Doxygen tag (@ince → @since). Doxygen parameter name matching. 2019-07-24 11:59:09 -05:00
pubkey.cpp #10483 scripted-diff: Use the C++11 keyword nullptr to denote the pointer literal instead of the macro NULL 2019-08-12 09:07:03 -05:00
pubkey.h
random.cpp #10483 scripted-diff: Use the C++11 keyword nullptr to denote the pointer literal instead of the macro NULL 2019-08-12 09:07:03 -05:00
random.h Merge #15512: Add ChaCha20 encryption option (XOR) 2019-07-23 09:14:28 -05:00
rest.cpp #10483 scripted-diff: Use the C++11 keyword nullptr to denote the pointer literal instead of the macro NULL 2019-08-12 09:07:03 -05:00
reverse_iterator.h Merge #10835: Rename member field according to the style guide 2019-09-08 10:52:42 -05:00
reverselock.h
saltedhasher.cpp Implement std::unordered_map/set compatible hasher classes for salted hashes 2019-02-27 14:40:52 +01:00
saltedhasher.h Implement std::unordered_map/set compatible hasher classes for salted hashes 2019-02-27 14:40:52 +01:00
scheduler.cpp Merge #10914: Add missing lock in CScheduler::AreThreadsServicingQueue() 2019-09-08 00:10:37 -05:00
scheduler.h Merge #10179: Give CValidationInterface Support for calling notifications on the CScheduler Thread 2019-09-07 12:33:13 -05:00
serialize.h Merge #9804: Fixes subscript 0 (&var[0]) where should use (var.data()) instead. 2019-07-17 19:01:41 -05:00
spentindex.h Optimize on-disk deterministic masternode storage to reduce size of evodb (#3017) 2019-07-09 08:59:57 +03:00
spork.cpp Refactor few things here and there (#3066) 2019-08-28 14:51:59 +03:00
spork.h Remove legacy InstantSend code (#3020) 2019-07-09 17:50:08 +03:00
stacktraces.cpp #10483 scripted-diff: Use the C++11 keyword nullptr to denote the pointer literal instead of the macro NULL 2019-08-12 09:07:03 -05:00
stacktraces.h Enable stacktrace support in gitian builds (#3006) 2019-07-02 07:16:11 +03:00
streams.h #10483 scripted-diff: Use the C++11 keyword nullptr to denote the pointer literal instead of the macro NULL 2019-08-12 09:07:03 -05:00
sync.cpp #10483 scripted-diff: Use the C++11 keyword nullptr to denote the pointer literal instead of the macro NULL 2019-08-12 09:07:03 -05:00
sync.h #10483 scripted-diff: Use the C++11 keyword nullptr to denote the pointer literal instead of the macro NULL 2019-08-12 09:07:03 -05:00
threadinterrupt.cpp
threadinterrupt.h
threadsafety.h
timedata.cpp #10193 scripted-diff: Remove #include <boost/foreach.hpp> 2019-07-24 11:59:09 -05:00
timedata.h Merge #8808: Do not shadow variables (gcc set) 2019-02-01 00:41:12 -06:00
tinyformat.h Merge bitcoin#9963: util: Properly handle errors during log message formatting (#2917) 2019-05-21 15:32:33 +02:00
torcontrol.cpp #10483 scripted-diff: Use the C++11 keyword nullptr to denote the pointer literal instead of the macro NULL 2019-08-12 09:07:03 -05:00
torcontrol.h
txdb.cpp add gArgs 2019-08-02 12:41:37 -05:00
txdb.h Merge #10148: Use non-atomic flushing with block replay 2019-08-01 14:57:28 -05:00
txmempool.cpp Merge #10199: Better fee estimates 2019-07-24 11:59:09 -05:00
txmempool.h #10483 scripted-diff: Use the C++11 keyword nullptr to denote the pointer literal instead of the macro NULL 2019-08-12 09:07:03 -05:00
ui_interface.cpp
ui_interface.h Merge #10568: Remove unnecessary forward class declarations in header files 2019-07-09 13:08:20 -05:00
uint256.cpp
uint256.h Update copyright date (2019) (#2970) 2019-06-11 14:46:07 +03:00
undo.h
unordered_lru_cache.h Replace BITCOIN_UNORDERED_LRU_CACHE_H with DASH_UNORDERED_LRU_CACHE_H 2019-03-11 15:18:25 +01:00
util.cpp Remove p2p alert leftovers (#3050) 2019-08-16 14:49:15 +03:00
util.h Remove p2p alert leftovers (#3050) 2019-08-16 14:49:15 +03:00
utilmoneystr.cpp
utilmoneystr.h Merge #10999: Fix amounts formatting in decoderawtransaction 2019-08-12 09:07:03 -05:00
utilstrencodings.cpp Merge #10357: Allow setting nMinimumChainWork on command line 2019-09-29 12:42:14 +02:00
utilstrencodings.h Merge #10357: Allow setting nMinimumChainWork on command line 2019-09-29 12:42:14 +02:00
utiltime.cpp #10483 scripted-diff: Use the C++11 keyword nullptr to denote the pointer literal instead of the macro NULL 2019-08-12 09:07:03 -05:00
utiltime.h Revert " Add real timestamp to log output when mock time is enabled (#2604)" 2019-06-24 11:39:34 -05:00
validation.cpp Merge #11458: Don't process unrequested, low-work blocks 2019-09-29 12:42:14 +02:00
validation.h Merge #10357: Allow setting nMinimumChainWork on command line 2019-09-29 12:42:14 +02:00
validationinterface.cpp Merge #11440: Fix validationinterface build on super old boost/clang 2019-09-25 10:33:21 +02:00
validationinterface.h Still pass the disconect block index 2019-09-07 22:37:16 -05:00
version.h Merge #10560: Remove unused constants 2019-07-08 13:50:05 -05:00
versionbits.cpp Merge #10957: Avoid returning a BIP9Stats object with uninitialized values 2019-09-24 20:06:48 +02:00
versionbits.h #10483 scripted-diff: Use the C++11 keyword nullptr to denote the pointer literal instead of the macro NULL 2019-08-12 09:07:03 -05:00
warnings.cpp Merge #10501: remove some unused functions -- ignoring removal of SetPort due to dash#2168 2019-09-08 00:10:48 -05:00
warnings.h Merge #10501: remove some unused functions -- ignoring removal of SetPort due to dash#2168 2019-09-08 00:10:48 -05:00