aboutsummaryrefslogtreecommitdiff
path: root/src/wallet
AgeCommit message (Collapse)Author
2017-04-01Change LogAcceptCategory to use uint32_t rather than sets of strings.Gregory Maxwell
This changes the logging categories to boolean flags instead of strings. This simplifies the acceptance testing by avoiding accessing a scoped static thread local pointer to a thread local set of strings. It eliminates the only use of boost::thread_specific_ptr outside of lockorder debugging. This change allows log entries to be directed to multiple categories and makes it easy to change the logging flags at runtime (e.g. via an RPC, though that isn't done by this commit.) It also eliminates the fDebug global. Configuration of unknown logging categories now produces a warning.
2017-03-29Merge #9294: Use internal HD chain for change outputs (hd split)Wladimir J. van der Laan
4115af7 Fix rebase issue where pwalletMain was used instead of pwallet Ser./Deser. nInternalChainCounter as last element (Jonas Schnelli) 9382f04 Do not break backward compatibility during wallet encryption (Jonas Schnelli) 1df08d1 Add assertion for CanSupportFeature(FEATURE_HD_SPLIT) (Jonas Schnelli) cd468d0 Define CWallet::DeriveNewChildKey() as private (Jonas Schnelli) ed79e4f Optimize GetOldestKeyPoolTime(), return as soon as we have both oldest keys (Jonas Schnelli) 771a304 Make sure we set the wallets min version to FEATURE_HD_SPLIT at the very first point (Jonas Schnelli) 1b3b5c6 Slightly modify fundrawtransaction.py test (change getnewaddress() into getrawchangeaddress()) (Jonas Schnelli) 003e197 Remove FEATURE_HD_SPLIT bump TODO (Jonas Schnelli) d9638e5 Overhaul the internal/external key derive switch (Jonas Schnelli) 1090502 Fix superfluous cast and code style nits in RPC wallet-hd.py test (Jonas Schnelli) 58e1483 CKeyPool avoid "catch (...)" in SerializationOp (Jonas Schnelli) e138876 Only show keypoolsize_hd_internal if HD split is enabled (Jonas Schnelli) add38d9 GetOldestKeyPoolTime: if HD & HD Chain Split is enabled, response max(oldest-internal-key, oldest-external-key) (Jonas Schnelli) dd526c2 Don't switch to HD-chain-split during wallet encryption of non HD-chain-split wallets (Jonas Schnelli) 79df9df Switch to 100% for the HD internal keypool size (Jonas Schnelli) bcafca1 Make sure we always generate one keypool key at minimum (Jonas Schnelli) d0a627a Fix issue where CDataStream->nVersion was taken a CKeyPool record version (Jonas Schnelli) 9af8f00 Make sure we hand out keypool keys if HD_SPLIT is not enabled (Jonas Schnelli) 469a47b Make sure ReserveKeyFromKeyPool only hands out internal keys if HD_SPLIT is supported (Jonas Schnelli) 05a9b49 Fix wrong keypool internal size in RPC getwalletinfo help (Jonas Schnelli) 01de822 Removed redundant IsLocked() check in NewKeyPool() (Jonas Schnelli) d59531d Immediately return setKeyPool's size if HD or HD_SPLIT is disabled or not supported (Jonas Schnelli) 02592f4 [Wallet] split the keypool in an internal and external part (Jonas Schnelli) Tree-SHA512: 80d355d5e844b48c3163b56c788ab8b5b5285db0ceeb19858a3ef517d5a702afeca21dbae526d7b8fb4101c2a745af1d92bf557c40cf516780f17992bf678c1a
2017-03-28ApproximateBestSubset should take inputs by reference, not valueRyan Havar
2017-03-28Fix rebase issue where pwalletMain was used instead of pwalletJonas Schnelli
Ser./Deser. nInternalChainCounter as last element
2017-03-27Do not break backward compatibility during wallet encryptionJonas Schnelli
2017-03-24Add assertion for CanSupportFeature(FEATURE_HD_SPLIT)Jonas Schnelli
2017-03-24Define CWallet::DeriveNewChildKey() as privateJonas Schnelli
2017-03-24Optimize GetOldestKeyPoolTime(), return as soon as we have both oldest keysJonas Schnelli
2017-03-24Make sure we set the wallets min version to FEATURE_HD_SPLIT at the very ↵Jonas Schnelli
first point
2017-03-24Remove FEATURE_HD_SPLIT bump TODOJonas Schnelli
2017-03-24Overhaul the internal/external key derive switchJonas Schnelli
2017-03-24Fix superfluous cast and code style nits in RPC wallet-hd.py testJonas Schnelli
2017-03-24CKeyPool avoid "catch (...)" in SerializationOpJonas Schnelli
2017-03-24Only show keypoolsize_hd_internal if HD split is enabledJonas Schnelli
2017-03-24GetOldestKeyPoolTime: if HD & HD Chain Split is enabled, response ↵Jonas Schnelli
max(oldest-internal-key, oldest-external-key)
2017-03-24Don't switch to HD-chain-split during wallet encryption of non ↵Jonas Schnelli
HD-chain-split wallets
2017-03-24Switch to 100% for the HD internal keypool sizeJonas Schnelli
2017-03-24Make sure we always generate one keypool key at minimumJonas Schnelli
2017-03-24Fix issue where CDataStream->nVersion was taken a CKeyPool record versionJonas Schnelli
2017-03-24Make sure we hand out keypool keys if HD_SPLIT is not enabledJonas Schnelli
2017-03-24Make sure ReserveKeyFromKeyPool only hands out internal keys if HD_SPLIT is ↵Jonas Schnelli
supported
2017-03-24Fix wrong keypool internal size in RPC getwalletinfo helpJonas Schnelli
2017-03-24Removed redundant IsLocked() check in NewKeyPool()Jonas Schnelli
2017-03-24Immediately return setKeyPool's size if HD or HD_SPLIT is disabled or not ↵Jonas Schnelli
supported
2017-03-24[Wallet] split the keypool in an internal and external partJonas Schnelli
2017-03-18Rename first iterator to prevent shadowing.Pavel Janík
2017-03-17Merge #9818: Save watch only key timestamps when reimporting keysWladimir J. van der Laan
7759aa2 Save watch only key timestamps when reimporting keys (Russell Yanofsky) Tree-SHA512: 433b5a78e5626fb2f3166e6c84c22eabd5239d451dc82694da95af237e034612a24f1a8bc959b7d2f2e576ce0b679be1fa4af929ebfae758c7e832056ab67061
2017-03-17Merge #9592: [Qt] Add checkbox in the GUI to opt-in to RBF when creating a ↵Jonas Schnelli
transaction c4e4792 [Qt] Change RBF checkbox to reflect -walletrbf setting (Russell Yanofsky) 838a58e [Qt] Add simple optin-RBF checkbox and confirmation info (Jonas Schnelli) 568c05a Allow to opt-into RBF when creating a transaction (Jonas Schnelli) Tree-SHA512: 3d52dcd4e44da8aed4d631748074afef78d38c860f2a8b95323f4801a989d6599a3498a753fc10daba4098c527ef5a0eb942e5b3f1bfd656e1a6bd272b8e6c57
2017-03-14Initialize nRelockTimePatrick Strateman
2017-03-10Add safe flag to listunspent resultNicolasDorier
2017-03-10Add COutput::fSafe member for safe handling of unconfirmed outputsRussell Yanofsky
This exposes a value computed in CWallet::AvailableCoins so it can used for other things, like inclusion in listunspent output.
2017-03-09Merge #9960: Trivial: Add const modifier to GetHDChain and IsHDEnabledWladimir J. van der Laan
3cef950 Trivial: Add const modifier to GetHDChain and IsHDEnabled (NicolasDorier) Tree-SHA512: 73126689e179d70e6823950b51aae4da0a1e348436bc72338814f3afeec27868bb479d9e8261f86e4fe851e84492778a30c5f1fe76c9d7dd91796d0e38baeaf0
2017-03-09Merge #9853: Fix error codes from various RPCsWladimir J. van der Laan
adaa281 Update release notes to include RPC error code changes. (John Newbery) 338bf06 Add commenting around JSON error codes (John Newbery) dab804c Return correct error codes in fundrawtransaction(). (John Newbery) a012087 Return correct error codes in setban(). (John Newbery) 960bc7f Return correct error codes in removeprunedfunds(). (John Newbery) c119096 Return correct error codes in blockchain.cpp. (John Newbery) 6d07c62 Return correct error codes in bumpfee(). (John Newbery) Tree-SHA512: 4bb39ad221cd8c83d98ac5d7ad642f3a8c265522720dc86b2eebc70e74439a85b06d6ddcd6a874e879d986511de3ab0878bb7fe58b50cb0546b78913632ea809
2017-03-09Trivial: Add const modifier to GetHDChain and IsHDEnabledNicolasDorier
2017-03-08Refactor: Remove using namespace <xxx> from wallet/Karl-Johan Alm
2017-03-08Merge #9936: [trivial] Fix three typos introduced into walletdb.h in commit ↵MarcoFalke
7184e25 fdab309 [trivial] Fix typos introduced in 7184e25c80aa8b1629a700bb7a7e290ad0bb2792 (practicalswift) Tree-SHA512: 091666f996267fc5d9f911e6ff25051df5c198851a9c2a6cae73692ffacc64f4275932260487aa48a224ca7f80c58f79933065c72d42aeccae540293c67bcee9
2017-03-07Return correct error codes in fundrawtransaction().John Newbery
The fundrawtransaction() RPC was returning misleading or incorrect error codes (for example RPC_INTERNAL_ERROR when funding the transaction failed). This commit fixes those error codes: - RPC_INTERNAL_ERROR should not be returned for application-level errors, only for genuine internal errors such as corrupted data. That error code has been replaced with RPC_WALLET_ERROR. This commit also updates the test cases to explicitly test the error code.
2017-03-07Return correct error codes in removeprunedfunds().John Newbery
The removeprunedfunds() RPC was returning misleading or incorrect error codes (for example RPC_INTERNAL_ERROR when the transaction was not found in the wallet). This commit fixes those error codes: - RPC_INTERNAL_ERROR should not be returned for application-level errors, only for genuine internal errors such as corrupted data. This error code has been replaced with RPC_WALLET_ERROR. This commit also updates the test cases to explicitly test the error code.
2017-03-07Return correct error codes in bumpfee().John Newbery
The bumpfee() RPC was returning misleading or incorrect error codes (for example RPC_INVALID_ADDRESS_OR_KEY when the transaction was not BIP125 replacable). This commit fixes those error codes: - RPC_INVALID_ADDRESS_OR_KEY if an invalid address was provided: - Invalid change address given - RPC_INVALID_PARAMETER if a single (non-address/key) parameter is incorrect - confTarget and totalFee options should not both be set. - Invalid confTarget - Insufficient totalFee (cannot be less than required fee) - RPC_WALLET_ERROR for any other error - Transaction has descendants in the wallet - Transaction has descendants in the mempool - Transaction has been mined, or is conflicted with a mined transaction - Transaction is not BIP 125 replaceable - Transaction has already been bumped - Transaction contains inputs that don't belong to the wallet - Transaction has multiple change outputs - Transaction does not have a change output - Fee is higher than maxTxFee - New fee rate is less than the minimum fee rate - Change output is too small. This commit also updates the test cases to explicitly test the error code.
2017-03-07Merge #9602: Remove coin age priority and free transactions - implementationWladimir J. van der Laan
b421e6d Update example bitcoin.conf (Alex Morcos) 7d4e950 Allow setting minrelaytxfee to 0 (Alex Morcos) 359e8a0 [cleanup] Remove coin age priority completely. (Alex Morcos) f9b9371 [rpc] Remove priorityDelta from prioritisetransaction (Alex Morcos) 49be7e1 [rpc] Remove priority information from mempool RPC calls (Alex Morcos) 0315888 [test] Remove priority from tests (Alex Morcos) f838005 No longer allow "free" transactions (Alex Morcos) ad727f4 [rpc] sendrawtransaction no longer bypasses minRelayTxFee (Alex Morcos) fe282ac [cleanup] Remove estimatePriority and estimateSmartPriority (Alex Morcos) 400b151 [debug] Change -printpriority option (Alex Morcos) 272b25a [mining] Remove -blockprioritysize. (Alex Morcos) 12839cd [rpc] Remove estimatepriority and estimatesmartpriority. (Alex Morcos) ddf58c7 wallet: Remove sendfree (MarcoFalke) Tree-SHA512: a9a4499405923ce794ef18f9e334dbbd59dfc73a3dc2df6f85cc9c62af6f353ec2eed9c2d5e58e904f918d0d7ab738f403dd4939d9bc2276136864fe63710782
2017-03-07Merge #9369: Factor out CWallet::nTimeSmart computation into a method.Wladimir J. van der Laan
630fc54 Clean up braces in CWallet::ComputeTimeSmart (Russell Yanofsky) 6c996c2 Add documentation describing CWallet::nTimeSmart. (Russell Yanofsky) 1f98abe Factor out CWallet::nTimeSmart computation into a method. (Russell Yanofsky) c6b82d1 Add tests for CWalletTx::nTimeSmart (Russell Yanofsky) Tree-SHA512: 457a30251e572cf20dac0198af1a94128d269b1e0ce6605a213d56fc14d85c84a0a494e3dcbb18c201c4f39e6f7b000bd9cb6f283930d8452e4bb93ba406f8d4
2017-03-07[trivial] Fix typos introduced in 7184e25c80aa8b1629a700bb7a7e290ad0bb2792practicalswift
2017-03-06Rename FlushWalletDB -> CompactWalletDB, add function descriptionMatt Corallo
2017-03-06Use CScheduler for wallet flushing, remove ThreadFlushWalletDBMatt Corallo
2017-03-06Merge #9906: Disallow copy constructor CReserveKeysWladimir J. van der Laan
188f89c Disallow copy of CReserveKeys (Gregory Sanders) Tree-SHA512: e55ce10bf7f2dc91de9797e60ab7767fb51f25255995d62ddf358c52b7aaa23c26fbfb522e1610ff950b86804ddbc38dc0d7708bfab2c4d33ad99a275d8c77db
2017-03-06Disallow copy of CReserveKeysGregory Sanders
2017-03-06[Wallet] refactor CWallet/CWalletDB/CDBJonas Schnelli
Try to hide CDB/bitdb behinde CWalletDB. Prepare for full wallet database abstraction.
2017-03-06Merge #9333: Document CWalletTx::mapValue entries and remove erase of ↵Wladimir J. van der Laan
nonexistent "version" entry. 87ed396 [trivial] Add comment documenting bumpfee mapValues (Russell Yanofsky) a1fe944 Remove reference to nonexistent "version" wallet transaction mapvalue field (Russell Yanofsky) 654e044 [trivial] Add comment documenting CWalletTx::mapValue (Russell Yanofsky) Tree-SHA512: 1fd1860e345c59b13634db2007fff4ba30aaf1f177fdd765f47bf9257fac117cdcd5d491424416da304c08e85effbb27f3424f072f7c9587ef39cb98531b932a
2017-03-06Merge #9908: Define 7200 second timestamp window constantWladimir J. van der Laan
e57a1fd Define 7200 second timestamp window constant (Russell Yanofsky) Tree-SHA512: 449d20e4fd23905cd96be36f717c55a0a2360aba1002aaf55a3699cce4a41f6e94acc2fbe511a93c5cbe8f8e68386995a76cad67620ebb66ba9283e6080ab567
2017-03-06Merge #9576: [wallet] Remove redundant initializationWladimir J. van der Laan
343ba8f [wallet] Remove redundant initialization (practicalswift) Tree-SHA512: 54b94d7703b1735cb1ae0bd7eba61ca9d2f18e20b70e46c94aa3b0653495dce4fdea00cf953ec08215b96b5792eabb8b38c3f9b3cd36e52b82fcb2f1fd8a3540