aboutsummaryrefslogtreecommitdiff
path: root/src
AgeCommit message (Collapse)Author
2018-11-15fix uninitialized read when stringifying an addrLocalKaz Wesley
Reachable from either place where SetIP is used when our best-guess addrLocal for a peer is IPv4, but the peer tells us it's reaching us at an IPv6 address. In that case, SetIP turns an IPv4 address into an IPv6 address without setting the scopeId, which is subsequently read in GetSockAddr during CNetAddr::ToStringIP and passed to getnameinfo. Fix by ensuring every constructor initializes the scopeId field with something.
2018-11-15add test demonstrating addrLocal UBKaz Wesley
2018-11-14Merge #14411: [wallet] Restore ability to list incoming transactions by labelMarcoFalke
da427dbd48 Rename ListTransactions filter variable (Russell Yanofsky) 65b740f92b [wallet] Restore ability to list incoming transactions by label (Russell Yanofsky) Pull request description: This change partially reverts #13075 and #14023. Fixes #14382 Tree-SHA512: 8c4e56104b3a45784cdc06bae8e5facdfff04fe3545b63a35e0ec2e440a41b79d84833ca4c4e728d8af7ebb8a519303a9eda7bee4bbfb92bd50c58587a33eb30
2018-11-14Merge #14478: Show error to user when corrupt wallet unlock failsMarcoFalke
b4f6e58ca5 Better error message for user when corrupt wallet unlock fails (MeshCollider) Pull request description: Mentioned here: https://github.com/bitcoin/bitcoin/issues/14461#issuecomment-429183503 Current behavior is to assert(false) and crash, only info is printed in the log. This shows the message to the user before abort() instead. Tree-SHA512: 526f9ed9262257fca55caf7153ab913ed958b13b079d2f01db797485614d8c375815a1554276e8cf73d3838104b2691a9cf85c8d097973127ae8de9e111446bf
2018-11-14Bump the minimum Qt version to 5.2Hennadii Stepanov
2018-11-13Rename ListTransactions filter variableRussell Yanofsky
Suggested by MeshCollider <dobsonsa68@gmail.com> in https://github.com/bitcoin/bitcoin/pull/14411#discussion_r232134086
2018-11-13Merge #14720: rpc: Correctly name argumentsMarcoFalke
fa0815c300 rpc: Correctly name arguments (Jon Layton) Pull request description: Consistently use the same name to describe arguments in the documentation and add a test that uses the name. By splitting it up, the changes are easier to potentially backport and also make review easier when we switch to `RPCHelpMan`. The tests should pass with or without the changes in `src`. Partly stolen from #14459 (More RPC help description fixes by ch4ot1c) Tree-SHA512: 1072992b1e93ac41006613523e54a0a8004f529fcb101eb9d74d91474abb0945a5a7539f249905151b904b87448f9efc0cacbd9e052fbe2ea9111e62f3e7249c
2018-11-13[wallet] Restore ability to list incoming transactions by labelRussell Yanofsky
This change partially reverts #13075 and #14023. Fixes #14382
2018-11-13Merge #14679: importmulti: Don't add internal addresses to address bookWladimir J. van der Laan
7afddfa8cefd01249ad59cf2370e7cec90b34f6f importmulti: Don't add internal addresses to address book (Gregory Sanders) Pull request description: Currently anything imported with `internal` will not be treated as change since checking the address book is a primary test of this. Added basic tests of all combinations of arguments and change identification. Resolves https://github.com/bitcoin/bitcoin/issues/14662 Tree-SHA512: a1f08dc624a3fadee93cc5392d50c4796b0c5eedf38e295382f71570f2066d9e978ed6e3962084b902989863fe1273a8642d8fdb094a266d69de10622a4176b0
2018-11-13rpc: Correctly name argumentsJon Layton
2018-11-13Merge #14530: Use RPCHelpMan to generate RPC doc stringsMarcoFalke
fa483e13b3 rpc: Add RPCHelpMan for machine-generated help (MarcoFalke) fa0d36f712 rpc: Include rpc/util.h where needed for RPCHelpMan (MarcoFalke) Pull request description: This introduces a manager for the RPC help generation and demonstrates its use of it in some RPCs. It is the first non-exhaustive step toward #14378 and I will create pull requests for the next steps after this one is merged. Tree-SHA512: 86f68322443ff01cd964aaf0ebe186be63fbebe4c47676cf7a622cc2b5305fd176bd57badfd1bbf788a036812253eb0dead74ecc3b30664c3e0d9392b2248054
2018-11-13Merge #14714: util.h: explicitly include required QString headerWladimir J. van der Laan
27154ce765971619efcd2ee59384c549957711f5 util.h: explicitly include required QString header (1Il1) Pull request description: Alternative to #14713. Instead of depending on clang formatter to not reorder includes, another fix is to explicitly include the missing header file. Tree-SHA512: f419ef2fd1dfd8da28160a94d187af78463fb398ef6aadd6c68ebf57e6d02380d93f5f370bf2d39e88dcbfeb252c3e5f245c0a157c7d0a64c38fc0f0c7004515
2018-11-13Merge #14690: Throw error if CPubKey is invalid during PSBT keypath ↵Wladimir J. van der Laan
serialization 4e4de10f69d5d705256cadfb15d76314dff16e77 Throw error if CPubKey is invalid during PSBT keypath serialization (Gregory Sanders) Pull request description: Related to https://github.com/bitcoin/bitcoin/pull/14689 We should catch this error before attempting to deserialize it later. Tree-SHA512: d2f3ea7f363818ac70c81ee988231b2bb50d055b6919f7bff3f27120c85a7048bfa183efae33e23e6b81d684bcb8bb81e5b209abb3acbcaff1d88014f4f1aa93
2018-11-13Merge #14608: qt: Remove the "Pay only required fee..." checkboxJonas Schnelli
a16f44c04 qt: Remove "Pay only required fee" checkbox (Hennadii Stepanov) 8711cc0c7 qt: Improve BitcoinAmountField class (Hennadii Stepanov) Pull request description: Ref #13280 This PR removes the "Pay only the required fee..." checkbox from the custom transaction fee section in the "Send" tab. Instead, a minimum value will be enforced on the custom fee input box. All comments from #13280 are addressed. Before: ![screenshot from 2018-10-30 16-42-18](https://user-images.githubusercontent.com/32963518/47726622-866d8e80-dc63-11e8-8670-3f97ff0fa5da.png) After: ![screenshot from 2018-10-30 16-40-37](https://user-images.githubusercontent.com/32963518/47726633-8f5e6000-dc63-11e8-82cf-5b9ff4aae91d.png) cc: @promag @MarcoFalke @Sjors Tree-SHA512: 073577d38d8353b10e8f36fb52e3c6e81dd45d25d84df9b9e4f78f452ff0bdbff3e225bdd6122b5a03839ffdcc2a2a08175f81c2541cf2d12918536abbfa3fd1
2018-11-13Merge #13381: RPC: creates possibility to preserve labels on importprivkeyJonas Schnelli
a6b5ec18f rpc: creates possibility to preserve labels on importprivkey (marcoagner) Pull request description: Closes #13087. As discussed in the issue, this is a feature request instead of a bug report since the behaviour was as intended (i.e. label with default: `''`). With this, the old behaviour is kept while the possibility to achieve the preservation of labels, as expected in the open issue, is added. Tree-SHA512: b33be50e1e7f62f7ddfae953177ba0926e2d848961f9fac7501c2b513322c0cb95787745d07d137488267bad1104ecfdbe800c6747f94162eb07c976835c1386
2018-11-13util.h: explicitly include required QString header1Il1
2018-11-12Merge #14356: fix converttopsbt permitsigdata arg, add basic testWladimir J. van der Laan
88a79cb436b30b39d37d139da723f5a31e9d161b fix converttopsbt permitsigdata arg, add basic test (Gregory Sanders) Pull request description: The final check for extraneous sigdata has a flipped boolean, resulting in incorrect behavior. Resolves https://github.com/bitcoin/bitcoin/issues/14355 Tree-SHA512: 5157a74b8ddebd7d836fba96765c4d7ed15a73d4289817353d3566a0f6803bd4bbc3f936735c517c7a83a6cbdb4052b9c61d23f6cc4ad00a6077278cd51adbd4
2018-11-12rpc: Add RPCHelpMan for machine-generated helpMarcoFalke
2018-11-12Merge #14494: Error if # is used in rpcpassword in confWladimir J. van der Laan
0385109444646561a718f34ae437b7e0e4d4d5bc Add test for rpcpassword hash error (MeshCollider) 13fe258e91e7a92326aedf151c571994166a06d4 Error if rpcpassword in conf contains a hash character (MeshCollider) Pull request description: Fixes #13143 now #13482 was merged Tree-SHA512: e7d00c8df1657f6b8d0eee1e06b9ce2b1b0a2de487377699382c1b057836e1571dac313ca878b5877c862f0461ba789a50b239d2a9f34accd8a6321f126e3d2a
2018-11-12Merge #14228: Qt: Enable system tray icon by default if availableWladimir J. van der Laan
ec1201a36847f7aa942eab1b3a3d082f6daf0031 Don't use systray icon on inappropriate systems (Hennadii Stepanov) Pull request description: Prevent a user from losing access to the main window by minimizing it to the tray on the systems which have not “system tray” or “notification area” available (e.g. GNOME 3.26+). Tested on Fedora 28 + GNOME 3.28. Tree-SHA512: c2dc26ff31c38a882dbd7d1ff71af99f1ba38a04a1c8b7fe7b99b93e4c0719f2916c7db0e620806a36582402d18939c635e1913c276b452ecbf939936067407b
2018-11-12Merge #14123: gui: Add GUIUtil::bringToFrontWladimir J. van der Laan
0a656f85a9c694f25b06c6464d6e986816eecd58 qt: All tray menu actions call showNormalIfMinimized (João Barbosa) 6fc21aca6d5e16c3ece104fec8e5b3df116893b4 qt: Use GUIUtil::bringToFront where possible (João Barbosa) 5796671e1dd8a2d0b1e750c2dce19a10af624095 qt: Add GUIUtil::bringToFront (João Barbosa) 6b1d2972bf9a40f97ba3a5c95831fd179b1054cf Remove obj_c for macOS Dock icon menu (Hennadii Stepanov) 2464925e7be832d4926b6204169bbbc1646c6368 Use Qt signal for macOS Dock icon click event (Hennadii Stepanov) 53bb6be3f8a50ee9e5c4d7e9155236152e7c4b7c Remove obj_c for macOS Dock icon setting (Hennadii Stepanov) Pull request description: The sequence `show -> raise -> activateWindow` is factored out to the new function `GUIUtil::bringToFront` where a macOS fix is added in order to fix #13829. Also included: - simplification of `BitcoinGUI::showNormalIfMinimized` - simplified some connections to `BitcoinGUI::showNormalIfMinimized` - added missing connections to `BitcoinGUI::showNormalIfMinimized`. Tree-SHA512: a8e301aebc359aa353821e2af352ae356f44555724921b01da907e128653ef9dc55d8764a1bff72a579e5ff96df8a681f6804bfe83acba441da92fedff974a55
2018-11-12Merge #14651: Refactor: Fix compiler warning in prevector.hWladimir J. van der Laan
76e13b586ff690dd3312f719f305c0d1021cd505 warnings: Compiler warning on memset usage for non-trivial type (Lenny Maiorani) Pull request description: Fixing warnings reported by GCC: memset of non-trivial type Tree-SHA512: 357aeac60acfb922851daaf0bd8d4b81e377da7c9b31c2942b54cfdd4129dae61e577fc0a6aa430348cb07abd16ae32f986a64dbb2c1d90ec148f53e7451a229
2018-11-10Merge #12783: macOS: disable AppNap during syncWladimir J. van der Laan
1e0f3c44992fb82e6bf36c2ef9277b0759c17c4c macOS: disable AppNap during sync (Alexey Ivanov) Pull request description: Code based on pull/5804. Tested only on macOS 10.13.3 and should support 10.9+. What macOS versions bitcoin core currently supports? Tree-SHA512: 85809b8d8d8a05169437b4268988da0b7372c29c6da3223ebdc106dc16dcb6d3caa5c52ace3591467005b50a63fd8b2ab1cb071cb4f450032932df25d5063315
2018-11-09Merge #14689: Require a public key to be retrieved when signing a P2PKH inputPieter Wuille
6b8d86ddb8 Require a public key to be retrieved when signing a P2PKH input (Andrew Chow) Pull request description: If we do not have the public key for a P2PKH input, we should not continue to attempt to sign for it. This fixes a problem where a PSBT with a P2PKH output would include invalid BIP 32 derivation paths that are missing the public key. Tree-SHA512: 850d5e74c06833da937d5bf0348bd134180be7167b6f9b9cecbf09f75e3543fbad60d0abbc0b9afdfa51ce165aa36168849f24a7c5abf1e75f37ce8f9a13d127
2018-11-09Merge #14588: Refactor PSBT signing logic to enforce invariant and fix ↵Pieter Wuille
signing bug e13fea975d Add regression test for PSBT signing bug #14473 (Glenn Willen) 565500508a Refactor PSBTInput signing to enforce invariant (Glenn Willen) 0f5bda2bd9 Simplify arguments to SignPSBTInput (Glenn Willen) 53e6fffb8f Add bool PSBTInputSigned (Glenn Willen) 65166d4cf8 New PartiallySignedTransaction constructor from CTransction (Glenn Willen) 4f3f5cb4b1 Remove redundant txConst parameter to FillPSBT (Glenn Willen) fe5d22bc67 More concise conversion of CDataStream to string (Glenn Willen) Pull request description: As discussed in the comments on #14473, I think that bug was caused primarily by failure to adhere to the invariant that a PSBTInput always has exactly one of the two utxo fields present -- an invariant that is already enforced by PSBTInput::IsSane, but which we were temporarily suspending during signing. This refactor repairs the invariant, also fixing the bug. It also simplifies some other code, and removes redundant parameters from some related functions. fixes #14473 Tree-SHA512: cbad3428175e30f9b7bac3f600668dd1a8f9acde16b915d27a940a2fa6d5149d4fbe236d5808fd590fb20a032274c99e8cac34bef17f79a53fdf69a5948c0fd0
2018-11-10Better error message for user when corrupt wallet unlock failsMeshCollider
2018-11-09rpc: Include rpc/util.h where needed for RPCHelpManMarcoFalke
Just a preparatory commit to add the header to the includes and run clang-format to sort the include lists. Splitting this up into a separate commit makes future scripted-diffs easier.
2018-11-09Merge #14437: Refactor: Start to separate wallet from nodeMarcoFalke
081accb875 Pass chain locked variables where needed (Russell Yanofsky) 79d579f4e1 Remove uses of cs_main in wallet code (Russell Yanofsky) ea961c3d72 Remove direct node->wallet calls in init.cpp (Russell Yanofsky) 8db11dd0b1 Pass chain and client variables where needed (Russell Yanofsky) 7e2e62cf7c Add skeleton chain and client classes (Russell Yanofsky) Pull request description: This creates an incomplete [`Chain`](https://github.com/ryanofsky/bitcoin/blob/pr/wipc-sep/src/interfaces/chain.h) interface in [`src/interfaces/`](https://github.com/ryanofsky/bitcoin/tree/pr/wipc-sep/src/interfaces) and begins to update wallet code to use it. #10973 builds on this, changing the wallet to use the new interface to access chain state, instead of using CBlockIndex pointers and global variables like `chainActive`. Tree-SHA512: 6ef05a4d8ebf57f2ad71835e4d970c9c59e34057e39e48cee76b887492c2fee907e3f6a74a9861e5a9f97cdc6823f4865ebc41ec556ab371ebca1b664c20dbea
2018-11-08Merge #14684: [doc] conf: Remove deprecated options from docs, Other cleanupMarcoFalke
fa4da3c058 [doc] conf: Remove deprecated options from docs, Other cleanup (MarcoFalke) Pull request description: Some dumb fixes, like removing the mention that free transactions are still a thing or that rpcuser/pass should be used (as opposed to rpcauth or rpc cookie). Combined with other fixes because I don't want to create 3 pull requests: * conf: Remove deprecated options from docs * Remove only mention of MIT/X11 * Link to developer notes in README.md Tree-SHA512: 9e45dc6c63037e7618cf3c871d7d9e65b66f1a952f91a6e623d97d90171e29bc40299a06029c4dc21a0f579e68021e3663186bd3a65e3ab333aff711f7dcb2bf
2018-11-08Throw error if CPubKey is invalid during PSBT keypath serializationGregory Sanders
2018-11-08Require a public key to be retrieved when signing a P2PKH inputAndrew Chow
If we do not have the public key for a P2PKH input, we should not continue to attempt to sign for it.
2018-11-08build: Fix windows build error if `--disable-bip70`Chun Kuan Lee
2018-11-07Merge #14436: doc: add comment explaining recentRejects-DoS behaviorMarcoFalke
b191c7dfb7 doc: add comment explaining recentRejects-DoS behavior (James O'Beirne) Pull request description: When we receive invalid txs for the first time, we mark the sender as misbehaving. If we receive the same tx before a new block is seen, we *don't* punish the second sender (in the same way we do the original sender). It wasn't initially clear to me that this is intentional, so add a clarifying comment. Tree-SHA512: d12c674db137ed3ad83e0b941bffe6ddcd2982238048742afa574a4235881f0e58cfc0a4a576a0503e74c5c5240c270b9520fa30221e8b43a371fb3e0b37066b
2018-11-07importmulti: Don't add internal addresses to address bookGregory Sanders
2018-11-07[doc] conf: Remove deprecated options from docs, Other cleanupMarcoFalke
* conf: Remove deprecated options from docs * Remove only mention of MIT/X11 * Link to developer notes in README.md
2018-11-07Merge #14636: Avoid using numeric_limits for sequence numbers and lock timesMarcoFalke
535203075e Avoid using numeric_limits for sequence numbers and lock times (Russell Yanofsky) bafb921507 Remove duplicated code (Hennadii Stepanov) e4dc39b3bc Replace platform dependent type with proper const (Hennadii Stepanov) Pull request description: Switches to named constants, because numeric_limits calls can be harder to read and less portable. Change was suggested by jamesob in https://github.com/bitcoin/bitcoin/pull/10973#discussion_r213473620 There are no changes in behavior except on some platforms we don't support (ILP64, IP16L32, I16LP32), where `SignalsOptInRBF` and `MutateTxAddInput` functions would now work correctly. Tree-SHA512: 3f5c6393c260551f65a0edfba55ef7eb3625232eec8d85b1457f26e144aa0b90c7ef5f44b2fd2f7d9be3c3bcb301030a9f5473c21b3bac566cc59b8c8780737c
2018-11-06Pass chain locked variables where neededRussell Yanofsky
This commit does not change behavior. All it does is pass new function parameters. It is easiest to review this change with: git log -p -n1 -U0 --word-diff-regex=.
2018-11-06Remove uses of cs_main in wallet codeRussell Yanofsky
This commit does not change behavior. It is easiest to review this change with: git log -p -n1 -U0
2018-11-06Remove direct node->wallet calls in init.cppRussell Yanofsky
Route calls during node initialization and shutdown that would happen between a node process and wallet processes through the serializable `Chain::Client` interface, rather than `WalletInitInterface` which is now simpler and only deals with early initialization and parameter interaction. This commit mostly does not change behavior. The only change is that the "Wallet disabled!" and "No wallet support compiled in!" messages are now logged earlier during startup.
2018-11-06Pass chain and client variables where neededRussell Yanofsky
This commit does not change behavior. All it does is pass new function parameters. It is easiest to review this change with: git log -p -n1 -U0 --word-diff-regex=.
2018-11-06Add skeleton chain and client classesRussell Yanofsky
This commit does not change behavior. It just adds new skeleton classes that don't do anything and aren't instantiated yet.
2018-11-06Merge #14074: Use std::unordered_set instead of set in blockfilter interfaceWladimir J. van der Laan
fef5adcc331c4d7b92b71e03fc8a73343a865599 blockfilter: Use unordered_set instead of set in blockfilter. (Jim Posen) 4fb789e9b2ffdf48fd50293b3982b3fce4d5fbdf Extract CSipHasher to it's own file in crypto/ directory. (Jim Posen) Pull request description: Use `std::unordered_set` (hash set) instead of `std::set` (tree set) in blockfilter interface, as suggested by @ryanofsky in #12254. This may result in a very minor speedup, but I haven't measured. This moves `CSipHasher` to it's own file `crypto/siphash.h`, so that it can be used in the libbitcoin_util library without including `hash.{h,cpp}`. I'm open to other suggestions on solving this issue if people would prefer to leave CSipHasher where it is. Tree-SHA512: 593d1abda771e45f2860d5334272980d20df0b81925a402bb9ee875e17595c2517c0d8ac9c579218b84bbf66e15b49418241c1fe9f9265719bcd2377b0cd0d88
2018-11-06Error if rpcpassword in conf contains a hash characterMeshCollider
2018-11-05blockfilter: Use unordered_set instead of set in blockfilter.Jim Posen
2018-11-05Extract CSipHasher to it's own file in crypto/ directory.Jim Posen
This is a move-only commit with the exception of changes to includes.
2018-11-05trivial: Don't translate in help textken2812221
2018-11-05Merge #14092: tests: Dry run bench_bitcoin as part "make check" to allow for ↵MarcoFalke
quick identification of assertion/sanitizer failures in benchmarking code dfef0df840 tests: Dry run bench_bitcoin (-evals=1 -scaling=0: <1 second running time) as part "make check" to allow for quick identification of assertion/sanitizer failures in benchmarking code (practicalswift) 00c6306a61 Remove RUN_BENCH logic (practicalswift) Pull request description: Dry run `bench_bitcoin` (`-evals=1 -scaling=0`: <1 second running time) as part `make check` to allow for quick identification of assertion/sanitizer failures or crashes in benchmarking code. This is already tested in Travis but it is nice to have it locally too. The cost is near zero. Tree-SHA512: 1f51b86b34bf97f75785f2694891d80f1bfb3e050211e6f6c35d8d9bc80c75bdebaa5ebfa51855ac0cf76d8773c3026bc576f60d0227afb0e646d728b83abde7
2018-11-05Merge #14060: ZMQ: add options to configure outbound message high water ↵Wladimir J. van der Laan
mark, aka SNDHWM a4edb168b635b6f5c36324e44961cd42cf9bbbaa ZMQ: add options to configure outbound message high water mark, aka SNDHWM (mruddy) Pull request description: ZMQ: add options to configure outbound message high water mark, aka SNDHWM This is my attempt at https://github.com/bitcoin/bitcoin/pull/13315 Tree-SHA512: a4cc3bcf179776899261a97c8c4f31f35d1d8950fd71a09a79c5c064879b38e600b26824c89c4091d941502ed5b0255390882f7d44baf9e6dc49d685a86e8edb
2018-11-05Add SAFE_CHARS[SAFE_CHARS_URI]: Chars allowed in URIs (RFC 3986)practicalswift
2018-11-05rpc: Make HTTP RPC debug logging more informativepracticalswift