aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2018-06-18test: Add functional tests for unloadwallet RPCJoão Barbosa
2018-06-18rpc: Add unloadwallet RPCJoão Barbosa
2018-06-18Merge #13437: wallet: Erase wtxOrderd wtx pointer on removeprunedfundsWladimir J. van der Laan
faa18ca046e9043b2cf68cb1bd17cc8c60fe26d9 wallet: Erase wtxOrderd wtx pointer on removeprunedfunds (MarcoFalke) Pull request description: This prevents segfaults, when reading from the freed memory. Tree-SHA512: 04f8190dea7901cf1cc298d5db98c83b02858f27114c5ef4da738accd176d6647d6b81f3dc39f3d5912b1a981cf0599370fd391c4154ffbde97afc1fac389123
2018-06-18Merge #13412: Make ReceivedBlockTransactions return voidWladimir J. van der Laan
fafa27032876832ab2ed9bf0e20e2d448f012179 Make ReceivedBlockTransactions return void (MarcoFalke) Pull request description: Instead of always returning `bool{true}` and forcing the caller to handle the return code, make it void and remove "a bunch" of dead code at the call sites. Tree-SHA512: 10e41461c0516c0441d8b8eedcf6385874355c224b9e9d65e89addb142b4cf3e3be2d4ca0a7f2bd95c76aecdaa8537b6bd2d25631bf804bc42863ad5e84fa271
2018-06-18Merge #13438: Improve coverage of SHA256 SelfTest codeWladimir J. van der Laan
1e1eb6367f67dcf968bb62993b98b5873b926fc0 Improve coverage of SHA256 SelfTest code (Pieter Wuille) Pull request description: The existing SelfTest code does not cover the specialized double-SHA256-for-64-byte-inputs transforms added in #13191. Fix this. Tree-SHA512: 593c7ee5dc9e77fc4c89e0a7753a63529b0d3d32ddbc015ae3895b52be77bee8a80bf16b754b30a22c01625a68db83fb77fa945a543143542bebb5b0f017ec5b
2018-06-18Merge #13443: Removed unused == operator from CMutableTransaction.Wladimir J. van der Laan
55771b7c6a8d4a204c63e70db73a0071c41a0dc4 Removed unused == operator from CMutableTransaction. (lucash.dev@gmail.com) Pull request description: This removes the unused == operator from `CMutableTransaction`. The motivation is that unused code has a cost but offers no benefit (in general), while also adding the risk of introducing silent bugs. On top of that this particular code is quite inefficient, unnecessarily calculating the hash (it could, say, compare serializations). So if anyone ever needs to use a == comparison on `CMutableTransaction`, they'd be better of having to reimplement it (and add tests) than relying on code that's not being maintained. Note: after this, trying to use the == operator on CMutableTransactions results in a compilation error: ``` ./primitives/transaction.h:405:15: error: invalid operands to binary expression ('CMutableTransaction' and 'CMutableTransaction') ``` Tree-SHA512: a565af563e09d99347b6fe419f6d48c750b1377295af293a3e0c3c0d815e58aede8d7058987a68d66cfa7ed023e5d3285b12afabd17d0ff9cf11322ba3ce20fe
2018-06-18Merge #13494: Follow-up to #13454: Fix broken build by exporting LC_ALL=CMarcoFalke
7b23e6e13f Follow-up to #13454: Fix broken build by exporting LC_ALL=C (practicalswift) Pull request description: Follow-up to #13454: Fix broken build by exporting `LC_ALL=C`. Tree-SHA512: 5cca3182ba034dce28a0df5f4a4b343de6c2526048f17fee30e2f8d946e976b39d9cc54faae6c31bfe89022f9f4c360e9ec8e163a1690bc0656410a48bb81dbf
2018-06-18Follow-up to #13454: Fix broken build by exporting LC_ALL=Cpracticalswift
2018-06-18Merge #13454: Make sure LC_ALL=C is set in all shell scriptsWladimir J. van der Laan
47776a958b08382d76d69b5df7beed807af168b3 Add linter: Make sure all shell scripts opt out of locale dependence using "export LC_ALL=C" (practicalswift) 3352da8da1243c03fc83ba678d2f5d193bd5a0c2 Add "export LC_ALL=C" to all shell scripts (practicalswift) Pull request description: ~~Make sure `LC_ALL=C` is set when using `grep` range expressions.~~ Make sure `LC_ALL=C` is set in all shell scripts. From the `grep(1)` documentation: > Within a bracket expression, a range expression consists of two characters separated by a hyphen. It matches any single character that sorts between the two characters, inclusive, using the locale's collating sequence and character set. For example, in the default C locale, `[a-d]` is equivalent to `[abcd]`. Many locales sort characters in dictionary order, and in these locales `[a-d]` is typically not equivalent to `[abcd]`; it might be equivalent to `[aBbCcDd]`, for example. To obtain the traditional interpretation of bracket expressions, you can use the C locale by setting the `LC_ALL` environment variable to the value C. Context: [Locale issue found when reviewing #13450](https://github.com/bitcoin/bitcoin/pull/13450/files#r194877736) Tree-SHA512: fd74d2612998f9b49ef9be24410e505d8c842716f84d085157fc7f9799d40e8a7b4969de783afcf99b7fae4f91bbb4559651f7dd6578a6a081a50bdea29f0909
2018-06-18doc: Remove mention of Qt4 from build docsWladimir J. van der Laan
2018-06-18test: Update travis to not test Qt4 anymoreWladimir J. van der Laan
Change Qt4 & system libs build to Qt5 & system libs build.
2018-06-18gui: Remove QT_VERSION fallbacks for Qt < 5Wladimir J. van der Laan
There were surprisingly many `#ifdef` fallbacks for Qt 4. Remiving them simplifies maintenance, as well as adding new GUI functionality.
2018-06-18Move rpc/util.cpp from libbitcoin-util to libbitcoin-serverChun Kuan Lee
2018-06-17Merge #13488: Docs: Improve readability of "Squashing commits"MarcoFalke
42c499614a Docs: Improve readability of "Squashing commits" (wodry) Pull request description: It was not easy to read the comment lines for me because I was not sure whether the sentence ended with the line or not ("pull set commits"?). Therefore, dots had been invented and I have added them to signal the end of a sentence. Also begin New sentence with a capital letter. I guess, not all 'pick' words should be replaced by 'squash'? At least I found [this DO](https://www.digitalocean.com/community/tutorials/how-to-rebase-and-update-a-pull-request) rebase/squash documentation helpful, where is written that the first line should not be changed. Tree-SHA512: 1cb6d866a7295d44e2c8a7911f8a2650eb2f0ba0cffe2b97e90f7e1ed36ac942480b45ef46e01dd3871beb20d04840fb5093fdb414b60f6cc4f88f95fe70f47b
2018-06-17Docs: Improve readability of "Squashing commits"wodry
It was not easy to read the comment lines for me because I was not sure whether the sentence ended with the line or not ("pull set commits"?). Therefore, dots had been invented and I have added them to signal the end of a sentence. Also begin New sentence with a capital letter. I guess, not all 'pick' words should be replaced by 'squash'? At least I found [https://www.digitalocean.com/community/tutorials/how-to-rebase-and-update-a-pull-request](this) rebase/squash documentation helpful, where is written that the first line should not be changed.
2018-06-16Merge #13448: Add linter: Make sure we explicitly open all text files using ↵Wladimir J. van der Laan
UTF-8 encoding in Python c8176b3cc7556d7bcec39a55ae4d6ba16453baaa Add linter: Make sure we explicitly open all text files using UTF-8 or ASCII encoding in Python (practicalswift) 634bd970013eca90f4b4c1f9044eec8c97ba62c2 Explicitly specify encoding when opening text files in Python code (practicalswift) Pull request description: Add linter: Make sure we explicitly open all text files using UTF-8 encoding in Python. As requested by @laanwj in #13440. Tree-SHA512: 1651c00fe220ceb273324abd6703aee504029b96c7ef0e3029145901762c733c9b9d24927da281394fd4681a5bff774336c04eed01fafea997bb32192c334c06
2018-06-16Merge #13479: contrib: Fix CVE-2018-12356 by hardening the regexWladimir J. van der Laan
9e2e5626dabb7208dafedcc9904940b666be1c3b Fix CVE-2018-12356 by hardening the regex. (Loganaden Velvindron) Pull request description: Detailed write-up here: https://neopg.io/blog/pass-signature-spoof/ Tree-SHA512: 2020474ff4c7b5e7f1bea932c63da62aca48d3dc6dcd04507afefad6c40f2977ed2d2916defe2e8e7936a2d498125c578077870147954a7af9b29b823cbb0b10
2018-06-15Merge #13465: Avoid concurrency issue when make multiple targetMarcoFalke
cf01fd6f9c Avoid concurrency issue (Chun Kuan Lee) Pull request description: From #13406, changed travis job target for Mac to `all deploy`, but this could cause a race condition. Simply add `.NOTPARALLEL` to avoid it. Related jobs: https://travis-ci.org/bitcoin/bitcoin/jobs/391863281 https://travis-ci.org/bitcoin/bitcoin/jobs/391907335 Close #13469 Tree-SHA512: 75c6585fe770dc70e6256dcdf97af37274f95a9240ed5a5cea2ca92b8411893b80327335587270351b128f56cb2e00f684db7c19b1602048132b734dad6ececa
2018-06-15Fix CVE-2018-12356 by hardening the regex.Loganaden Velvindron
2018-06-15build: add warning to detect hidden copies in range-for loopsCory Fields
2018-06-15cleanup: avoid hidden copies in range-for loopsCory Fields
2018-06-15Merge #13241: scripted-diff: Avoid temporary copies when looping over std::mapMarcoFalke
9b72c988a0 scripted-diff: Avoid temporary copies when looping over std::map (Ben Woosley) Pull request description: The ::value_type of the std::map/std::multimap/std::unordered_map containers is std::pair<const Key, T>. Dropping the const results in an unnecessary copy, for example in C++11 range-based loops. For this I started with a more general scripted diff, then narrowed it down based on the inspection showing that all actual map/multimap/unordered_map variables used in loops start with m or have map in the name. Tree-SHA512: b656d66b69ffa1eb954124aa8ae2bc5436ca50262abefa93bdda55cfcdaffc5ff90cd40539051a2bd06355ba69ddf245265cc8764eebff66d761b3aec06155a9
2018-06-15doc: Add historical release notes for 0.16.1Wladimir J. van der Laan
Tree-SHA512: cca8188f954eeded58f705749b2ae51b08aadf4feddafaaafc57df2f84c10a3340a373c1602e9aa290c54b67cdcce53f61f4ca2db87bd98de5449afc53e25f86
2018-06-15Merge #13402: Document validationinterace callback blocking deadlock potential.MarcoFalke
25bc9615b7 Document validationinterace callback blocking deadlock potential. (Matt Corallo) Pull request description: From the branches-I've-had-lying-around-and-forgot-to-PR department... This is a comment-only PR, but the comments point out an API quirk that isn't exactly trivial. None of our use-cases right now hit this, but if we were to call SyncWithValidationInterfaceQueue (eg to limit queue depth) in ATMP, I'm pretty sure we'd hit a deadlock there. Tree-SHA512: 889dd8fc9eb15d1f2aa5ca467e783bc8f07bc543b166b032741795b0db7a0df11a2846d3cb7c69bafa8d1acf970021001b742f52be06725a932813230c5b4a7b
2018-06-15Merge #13450: Add linter: Enforce the source code file naming convention ↵MarcoFalke
described in the developer notes ad691f666b Add linter: Enforce the source code file naming convention described in the developer notes (practicalswift) Pull request description: Add linter: Enforce the source code file naming convention described in the developer notes. Tree-SHA512: 6458acf5383de7e81554bdd954c3a74c2bbf26286687ea69d934f11174d2f6bd573e8d2c16a7e77bbd12065e65be7700ecd7791d215f286e18f346bf964cd17d
2018-06-15Merge #13476: Fix incorrect shell quoting in FreeBSD build instructions.MarcoFalke
c9924a2756 Fix incorrect shell quoting in FreeBSD build instructions. (murrayn) Pull request description: The current instructions suggest: BDB_PREFIX='$PWD/db4' which results in BDB_PREFIX being set, literally, to '$PWD/db4'. Tree-SHA512: 4a920d7a506ff94fb12793f0b8161fdfe0798382cfa88290a0eadd6926843b577328f7159a55039e2655def7ddf2e7a1eaa3dd30490292d4a920c98759becf56
2018-06-15Fix incorrect shell quoting in FreeBSD build instructions.murrayn
2018-06-14Merge #13422: Drop ParseHashUV in favor of calling ParseHashStrMarcoFalke
abd2678ac1 Drop ParseHashUV in favor of calling ParseHashStr (Ben Woosley) Pull request description: The one existing call already validates `get_str` will pass via `checkObject`: https://github.com/bitcoin/bitcoin/pull/13422/files#diff-8fe4d6985ee4acf8bfc1ed8db1e83cb5L586 Split from #13420 Tree-SHA512: 35dfa8c28d0c3ceac7a6de7f4eb4a44d912f4c31f5d21c9438f899566ca2b34851f1a58c3417355e55d0c33abb97385f4a47e034bfc8e3cdbbf5f73813ca0582
2018-06-14Add linter: Enforce the source code file naming convention described in the ↵practicalswift
developer notes
2018-06-14Merge #13460: doc: Remove note to install all boost dev packagesMarcoFalke
fa3d39ec53 doc: Remove note to install all boost dev packages (MarcoFalke) Pull request description: Those notes are for systems that are EOL. Also, those instructions would pull in a ton of additional dependencies such as `python2`. Can be reviewed with `git diff HEAD~ --word-diff` Tree-SHA512: 7e379b3f0b7fe88452baed8860438a7867a025e650a265ed0cd5d47076983f4176545b7d96a4b7f25ae9fcb325f0116d909f3ffb6ff2d7573fddd777fe5b4c79
2018-06-14Avoid concurrency issueChun Kuan Lee
2018-06-14Merge #13451: rpc: expose CBlockIndex::nTx in getblock(header)Wladimir J. van der Laan
86edf4a2a502416ba8d6cebbce61030992f7ff6f expose CBlockIndex::nTx in getblock(header) (Gregory Sanders) Pull request description: Recent publication of a weakness in Bitcoin's merkle tree construction demonstrates many SPV applications vulnerable to an expensive to pull off yet still plausible attack: https://bitslog.wordpress.com/2018/06/09/leaf-node-weakness-in-bitcoin-merkle-tree-design/ Including the coinbase in the txoutproof seems the most effective fix, however results in a significant efficiency downgrade. Transactors will not even know a priori what the size of their proof will be within a couple orders of magnitude, unless they use the mid-state of SHA2 as detailed in the blog post. Some applications, like Elements blockchain platform that take SPV-style proofs have optional access to a bitcoind to verify these proofs of inclusion and check depth in the chain. Returning `CBlockIndex::nTx` would allow an extremely easy and compact way of checking the depth of the tree, with no additional overhead to the codebase, and works with pruned nodes. `getblockheader` is arguably not the place for it, but as mentioned before, is a natural workflow for us checking depth of a block in a possibly pruned node. We should also ensure that `verifytxoutproof` ends up validating this depth fact as well, but left this for another PR. Tree-SHA512: af4cf48e704c6088f8da06a477fda1aaa6f8770cee9b876c4465d1075966d6a95831a88817673fe5a0d6bbcdc1ffcbc1892e2be0d838c60fc6958d33eacdcc14
2018-06-14Add linter: Make sure all shell scripts opt out of locale dependence using ↵practicalswift
"export LC_ALL=C"
2018-06-14Add "export LC_ALL=C" to all shell scriptspracticalswift
2018-06-13doc: Remove note to install all boost dev packagesMarcoFalke
2018-06-13Merge #13441: Prevent shared conf files from failing with different ↵MarcoFalke
available options in different binaries c2dfbb4a97 Add unavailable options to hidden options category (Andrew Chow) Pull request description: From IRC: ``` <ossifrage> FYI, bitcoin-qt from the head I built today won't start if you have "daemon=0" in the config file, so you can't use the same config for either bitcoind or bitcoin-qt <ossifrage> Seems like bitcoin-qt should ignore this option? <provoostenator> ossifrage: probably caused by 13112. Another problem is disablewallet=1 will prevent a launch if you compile bitcoind without wallet. It probably needs to be relaxed slightly. ``` Adds all of the options that are unavailable due to compiling options to the hidden category so that shared config files do not break with the alternative binaries. Tree-SHA512: 1ef43f5f7ad46ecc2865d22ee683ef22831e8f131ec99b732bb36d90381f7964bf64829595e993c2d435823fe4425a20323c8e65307cf2463a9e40b8049ab559
2018-06-13Merge #13457: tests: Drop variadic macroWladimir J. van der Laan
faf52f953b47aac6a39892b037eaa3f08d46b655 tests: Drop variadic macro (MarcoFalke) Pull request description: The C++11 constructor of `std::vector` that takes an initializer list, is not `explicit`. Thus, the macro is not required and can be dropped. Hopefully fixes #13456 Tree-SHA512: 4095ed205f88138a7cd5b14790cc426899966f622a924a9b3f7de646a0d801a48ffb8921da760f1f93d5481298477c8a64dbec291381bb9aa77b075bdd2659f2
2018-06-13Merge #13406: travis: Change Mac goal to all deployMarcoFalke
3d69853090 travis: Change Mac goal to all deploy so that travis can build all executables for Mac. (Chun Kuan Lee) Pull request description: Currently, travis only build bitcoin-qt for Mac with make deploy, so I think that we can add a make step to build cli, daemon, test and bench executables. Tree-SHA512: 346c207836ee7313a57e0cd03367ada7e95c182d0f58b06c4ee5b8f2865ba4ee077b030a5494b58a808c015afe0569fa3252d0a5a687c47b7094dc77599ce50e
2018-06-13build: Build system changes to support only Qt5Wladimir J. van der Laan
2018-06-13Merge #13350: [tests] Add logging to provide anchor points when debugging ↵MarcoFalke
p2p_sendheaders 2ce81867b2 [tests] Add logging to provide anchor points when debugging failures. (Lowell Manners) Pull request description: refs #12453 Tree-SHA512: 0ad432bd848723a5b813df4d35fcd8c81d152f042499c8340a9a2a9b7918d6e785efbf9f07b63b6c0253a949044cebdb51802971c09fb8dde0efa5169f34ef20
2018-06-13expose CBlockIndex::nTx in getblock(header)Gregory Sanders
2018-06-13tests: Drop variadic macroMarcoFalke
2018-06-13Merge #13445: build: Reset default -g -O2 flags when enable debugWladimir J. van der Laan
9882d1f044133832b3c0809676d5f26a861b9f44 Reset default -g -O2 flags when enable debug (Chun Kuan Lee) Pull request description: The default CXXFLAGS is -g -O2, this should not appear when enable debug. fixes #13432 Tree-SHA512: 79447f3e1fab9e6cd12f5ca49b3d42187e856e0c159ed01140ea93d6ef1fbb1af3d65b338308566330491052c0177d12abe26796513502ddde31692665a0dbb4
2018-06-13Merge #13435: When build fails due to lib missing, indicate which oneWladimir J. van der Laan
51cd508e2fb429f7c23a0bbbf4b8687386276105 When build fails due to lib missing, indicate which one (Ben Woosley) Pull request description: A failure of "lib missing" has limited utility. Tree-SHA512: de77c077ea223bb862a6261fd99e9ddc533e28ed42837ac4262a1c0f24d73add4d2baae6be5cb5ef2012be32bcc3ae587dbc1eab0c42b633bea8eec64b18a249
2018-06-13Merge #13428: validation: check the specified number of blocks (off-by-one)Wladimir J. van der Laan
f6f8026e40326e74293dc8ecc270a7e3b4850727 validation: check the specified number of blocks (off-by-one) (Karl-Johan Alm) Pull request description: ``` echeveria | 2018-06-11 02:03:03.384975 Verifying last 3 blocks at level 3 echeveria | 2018-06-11 02:03:23.676793 No coin database inconsistencies in last 4 blocks (6564 transactions) echeveria | off by one? sipa | echeveria: possibly! kallewoof | Looks like it checks one more block than suggested. `if (pindex->nHeight < chainActive.Height()-nCheckDepth) break;` should probably be `<=`. sipa | kallewoof: agree ``` Post-commit: ``` 2018-06-11T05:24:02Z Verifying last 6 blocks at level 3 2018-06-11T05:24:02Z [0%]...[16%]...[33%]...[50%]...[66%]...[83%]...[99%]...[DONE]. 2018-06-11T05:25:07Z No coin database inconsistencies in last 6 blocks (7258 transactions) ``` Pre-commit: ``` 2018-06-11T05:27:11Z Verifying last 6 blocks at level 3 2018-06-11T05:27:11Z [0%]...[16%]...[33%]...[50%]...[66%]...[83%]...[99%]...[DONE]. 2018-06-11T05:27:12Z No coin database inconsistencies in last 7 blocks (9832 transactions) ``` Tree-SHA512: 6e68dc4ba74232518c2ba8ea624d65893534f3619d43ccdf0b9c65992f25b68cb52cf54fa35e6e3d092d1eee5c9a8887057828895f1acdafc0ebb48f683fffdc
2018-06-13Merge #13447: travis: Increase travis_wait time while verifying commitsMarcoFalke
51ed05a2b9 travis: Increase travis_wait time while verifying commits (Chun Kuan Lee) Pull request description: From https://travis-ci.org/ken2812221/bitcoin-verify-commits/builds I have run vecify-commits.py nightly on travis, as you can see that 30 minutes is not enough, it took 30-50 minutes to run the script with no extra options. So change it to 50 minutes would be better. Forgot to change this at #13066 Tree-SHA512: fced346edcb7dc626fa6e714d7db9a34d3e9f283ada64e19c30565ed214f72e26a57a905b4eb71ab24a16c97a1bd35e57e9a83dbb7dc1fff2db26505b810e61e
2018-06-12travis: Change Mac goal to all deploy so that travis can build all ↵Chun Kuan Lee
executables for Mac.
2018-06-12Add unavailable options to hidden options categoryAndrew Chow
Options that are not available (but known in the source code) will cause an error if they are specified. Make these options "available" by adding them to the hidden options category to prevent conf files from failing when shared between binaries that have different options available.
2018-06-12Add linter: Make sure we explicitly open all text files using UTF-8 or ASCII ↵practicalswift
encoding in Python
2018-06-12tests: Fix lock-order-inversion (potential deadlock) in DoS_tests. Reported ↵practicalswift
by TSAN. Makes `src/test/test_bitcoin --run_test=DoS_tests` pass also when compiled with TreadSanitizer (`./configure --with-sanitizers=thread`).