Commit Graph

16683 Commits

Author SHA1 Message Date
Alexander Block
40399fd973 Circumvent BIP69 sorting in fundrawtransaction.py test (#3100)
"subtractFeeFromOutputs" is applied to the ordering of the input
transaction and after that BIP69 sorting is performed. This causes
flakiness in tests.
2019-09-22 23:47:17 +03:00
Nathan Marley
e2d651f601 Add OpenSSL termios fix for musl libc (#3099) 2019-09-22 23:47:02 +03:00
Nathan Marley
783653f6a8 Ensure execinfo.h and linker flags set in autoconf (#3098)
* Ensure execinfo.h and linker flags set in autoconf

* Only check for backtrace() if not Windows
2019-09-22 23:46:45 +03:00
Nathan Marley
7320c3da24 Refresh zmq 4.1.5 patches (#3092)
Some implementations of the `patch` tool cannot handle fuzz / divergence
2019-09-22 23:46:18 +03:00
Nathan Marley
822e617bef Fix chia_bls include prefix (#3091) 2019-09-22 23:46:04 +03:00
PastaPastaPasta
35f079cbf1 Remove unused code (#3097)
* remove unused code

Signed-off-by: Pasta <pasta@dashboost.org>

* remove unused code

Signed-off-by: Pasta <pasta@dashboost.org>

* remove unused code

Signed-off-by: Pasta <pasta@dashboost.org>

* remove unused code

Signed-off-by: Pasta <pasta@dashboost.org>

* remove unused code

Signed-off-by: Pasta <pasta@dashboost.org>

* remove unused code

Signed-off-by: Pasta <pasta@dashboost.org>

* remove unused code

Signed-off-by: Pasta <pasta@dashboost.org>

* remove unused code

Signed-off-by: Pasta <pasta@dashboost.org>

* remove unused code

Signed-off-by: Pasta <pasta@dashboost.org>

* remove unused code

Signed-off-by: Pasta <pasta@dashboost.org>

* remove unused code

Signed-off-by: Pasta <pasta@dashboost.org>

* remove unused code

Signed-off-by: Pasta <pasta@dashboost.org>

* remove unused code

Signed-off-by: Pasta <pasta@dashboost.org>

* remove unused code, maybe need to revert / change the surrounding values

Signed-off-by: Pasta <pasta@dashboost.org>

* remove unused code

Signed-off-by: Pasta <pasta@dashboost.org>

* remove unused code

Signed-off-by: Pasta <pasta@dashboost.org>

* remove unused code

Signed-off-by: Pasta <pasta@dashboost.org>

* remove unused code

Signed-off-by: Pasta <pasta@dashboost.org>

* Revert "remove unused code"

This reverts commit 8ea0bbbc7b.
2019-09-22 23:45:22 +03:00
UdjinM6
b12cd5fbd3
Merge pull request #3101 from codablock/pr_backports_v15_v16_1
Backport changes in TX verification/signing API
2019-09-22 23:44:41 +03:00
UdjinM6
78a7ed8d18
Merge pull request #3096 from PastaPastaPasta/backports-0.15-pr26
Backports 0.15 pr26
2019-09-22 23:42:26 +03:00
Pasta
a72fc7c7d4
resolve NIT, remove extra line
Signed-off-by: Pasta <pasta@dashboost.org>
2019-09-22 09:30:00 -05:00
Pasta
f7a9b0df41
move deterministicMNManager->UpgradeDBIfNeeded(); to be after LoadChainTip
Signed-off-by: Pasta <pasta@dashboost.org>
2019-09-22 09:28:59 -05:00
Pasta
64dde0f6c3
add back the todo
Signed-off-by: Pasta <pasta@dashboost.org>
2019-09-22 09:26:55 -05:00
Alexander Block
689eff3aa0 Drop unused GetScriptForWitness 2019-09-20 19:36:28 +02:00
UdjinM6
4b579c77aa
Fix remaining issues 2019-09-20 10:30:04 -05:00
Wladimir J. van der Laan
02328ae966
Merge #11044: [wallet] Keypool topup cleanups
67ceff4 [wallet] Add logging to MarkReserveKeysAsUsed (John Newbery)
1221f60 [wallet] Remove keypool_topup_cleanups (John Newbery)

Pull request description:

  A couple of minor cleanups suggested by @ryanofsky here: https://github.com/bitcoin/bitcoin/pull/11022#pullrequestreview-55598940

  Does not affect functionality. Not required for v0.15.

Tree-SHA512: d8d0698fd26ea49a4157e68669d5511095760c3a1ecfa3f917e3f273efbafb55c51a202d677614216eae3f796b6e8d17506b2ec2d4799a94f18981b396e65eec
2019-09-20 10:30:04 -05:00
Pasta
ac07bf609e
revert unintentional change, 10758
Signed-off-by: Pasta <pasta@dashboost.org>
2019-09-20 10:30:04 -05:00
Pasta
3d445628a4
remove LogPrintf("Initializing databases...\n");
Signed-off-by: Pasta <pasta@dashboost.org>
2019-09-20 10:30:04 -05:00
Wladimir J. van der Laan
e941c9ba5a
Merge #11028: Avoid masking of difficulty adjustment errors by checkpoints
85c82b5 Avoid masking of difficulty adjustment errors by checkpoints (Pieter Wuille)

Pull request description:

  Currently difficulty adjustment violations are not reported for chains that branch off before the last checkpoint. Change this by moving the checkpoint check after the difficulty check.

Tree-SHA512: 33666f2c3459151b28c42041a463779e6df18f61d3dd5b1879a0af4e5b199ef74d1e33e06af68bebfdfb211569ad5fb56556bfebe9d63b5688d910ea211b839a
2019-09-20 10:30:04 -05:00
Pasta
2d922f5d31
fix
Signed-off-by: Pasta <pasta@dashboost.org>
2019-09-20 10:30:04 -05:00
Wladimir J. van der Laan
c438c9322f
Merge #11022: Basic keypool topup
d34957e [wallet] [tests] Add keypool topup functional test (Jonas Schnelli)
095142d [wallet] keypool mark-used and topup (John Newbery)
c25d90f [wallet] Add HasUnusedKeys() helper (John Newbery)
f2123e3 [wallet] Cache keyid -> keypool id mappings (John Newbery)
83f1ec3 [wallet] Don't hold cs_LastBlockFile while calling setBestChain (John Newbery)
2376bfc [wallet] [moveonly] Move LoadKeyPool to cpp (Matt Corallo)
cab8557 [wallet] [moveonly] Move CAffectedKeysVisitor (Jonas Schnelli)

Pull request description:

  This PR contains the first part of #10882 :

  - if a key from the keypool is used, mark all keys up to that key as used, and then try to top up the keypool
  - top up the keypool on startup

  Notably, it does not stop the node or prevent the best block from advancing if the keypool drops below a threshold (which means that transactions may be missed and funds lost if restoring from an old HD wallet backup).

Tree-SHA512: ac681fefeaf7ec2aab2fa1da93d12273ea80bd05eb48d7b3b551ea6e5d975dd97ba7de52b7fba52993823280ac4079cc36cf78a27dac708107ebf8fb6326142b
2019-09-20 10:30:04 -05:00
Wladimir J. van der Laan
d5fdf62faa
Merge #10919: Fix more init bugs.
e7539f8 Fix some broken init-time prints/constants (Matt Corallo)
13ab353 Check for empty coinsview instead of just-reset coinsview in init (Matt Corallo)
fce3f4f Fix resume-of-reindex-after-restart (Matt Corallo)
efac91e Always wait for threadGroup to exit in bitcoind shutdown (Matt Corallo)

Pull request description:

  This is a follow-on to #10758 to help move 10758 along. The first fixes a regression in master that was partially fixed in 10758, the second I'm not sure if its a regression or not, but its clearly a bug that should be fixed.

Tree-SHA512: aca7b97a97dca66e1a218a33cc6f4aa002292ff1bb0af64e35b81fbaa91b9504f2605375808b43e93a63fc73634ad079b30ef6c9f4ba338d3b5f72d816dfeaff
2019-09-20 10:30:04 -05:00
Alexander Block
7662c0b79a A couple of fixes 2019-09-20 11:10:07 +02:00
Alexander Block
16bd20e57c Remove segwit related code 2019-09-20 11:10:06 +02:00
Pieter Wuille
21eca6481f BIP143: Signing logic 2019-09-20 11:09:59 +02:00
Pieter Wuille
fff708d3a3 BIP143: Verification logic
Includes simplifications by Eric Lombrozo.
2019-09-19 21:04:36 +02:00
Pieter Wuille
8da543f279 Refactor script validation to observe amounts
This is a preparation for BIP143 support.
2019-09-19 21:04:36 +02:00
Pasta
1f06ecdd5a add gargs
Signed-off-by: Pasta <pasta@dashboost.org>
2019-09-18 17:44:58 -05:00
Pasta
9f71ab04bd remove chainparams from method call (10758)
Signed-off-by: Pasta <pasta@dashboost.org>
2019-09-18 17:41:16 -05:00
Pasta
05ad6d2ecb change nEnd to index (might break the progress bar on wallet creation, should test)
Signed-off-by: Pasta <pasta@dashboost.org>
2019-09-18 17:35:44 -05:00
Wladimir J. van der Laan
cd5a12f9fb Merge #10862: Remove unused variable int64_t nEnd. Fix typo: "conditon" → "condition".
5a6671c Fix typo: "conditon" → "condition" (practicalswift)
35aff43 Remove unused variable int64_t nEnd (practicalswift)

Pull request description:

  * Remove unused variable `int64_t nEnd`. Last use of `nEnd` removed in commit 1fc8c3d.
  * Fix typo: "conditon" → "condition". Typo introduced in commit 439c4e8.

Tree-SHA512: 61624e6f70828c485fe46dbe00df76f1a07b7a5849d41bf7d279323b687420e60e9b85192f611a37211f17f3dea8eb3f6f6dc65d90c92e5516404fd81d37785a
2019-09-18 17:31:02 -05:00
Pasta
714438af44 remove rewinding blocks
Signed-off-by: Pasta <pasta@dashboost.org>
2019-09-18 17:31:02 -05:00
Wladimir J. van der Laan
dbd4993084 Merge #10758: Fix some chainstate-init-order bugs.
c0025d0 Fix segfault when shutting down before fully loading (Matt Corallo)
1385697 Order chainstate init more logically. (Matt Corallo)
ff3a219 Call RewindBlockIndex even if we're about to run -reindex-chainstate (Matt Corallo)
b0f3249 More user-friendly error message if UTXO DB runs ahead of block DB (Matt Corallo)
eda888e Fix some LoadChainTip-related init-order bugs. (Matt Corallo)

Pull request description:

  This does a number of things to clean up chainstate init order,
  fixing some issues as it goes:

  * Order chainstate init more logically - first all of the
    blocktree-related loading, then coinsdb, then
    pcoinsTip/chainActive. Only create objects as needed.

  * More clearly document exactly what is and isn't called in
    -reindex and -reindex-chainstate both with comments noting
    calls as no-ops and by adding if guards.

  * Move the writing of fTxIndex to LoadBlockIndex - this fixes a
    bug introduced in d6af06d68a where
    InitBlockIndex was writing to fTxIndex which had not yet been
    checked (because LoadChainTip hadn't yet initialized the
    chainActive, which would otherwise have resulted in
    InitBlockIndex being a NOP), allowing you to modify -txindex
    without reindex, potentially corrupting your chainstate!

  * Rename InitBlockIndex to LoadGenesisBlock, which is now a more
    natural name for it. Also check mapBlockIndex instead of
    chainActive, fixing a bug where we'd write the genesis block out
    on every start.

  * Move LoadGenesisBlock further down in init. This is a more logical
    location for it, as it is after all of the blockindex-related
    loading and checking, but before any of the UTXO-related loading
    and checking.

  * Give LoadChainTip a return value - allowing it to indicate that
    the UTXO DB ran ahead of the block DB. This just provides a nicer
    error message instead of the previous mysterious
    assert(!setBlockIndexCandidates.empty()) error.

  * Calls ActivateBestChain in case we just loaded the genesis
    block in LoadChainTip, avoiding relying on the ActivateBestChain
    in ThreadImport before continuing init process.

  * Move all of the VerifyDB()-related stuff into a -reindex +
    -reindex-chainstate if guard. It couldn't do anything useful
    as chainActive.Tip() would be null at this point anyway.

Tree-SHA512: 3c96ee7ed44f4130bee3479a40c5cd99a619fda5e309c26d60b54feab9f6ec60fabab8cf47a049c9cf15e88999b2edb7f16cbe6819e97273560b201a89d90762
2019-09-18 17:31:02 -05:00
Wladimir J. van der Laan
0631cd95da Merge #10789: Punctuation/grammer fixes in rpcwallet.cpp
a5ecaf1 Fix misspellings and remove safety verbiage (Steven D. Lander)

Pull request description:

  Standardizing punctuation on CLI output and also including a few fixes for grammer.  This PR is for text only changes and includes no code edits.

Tree-SHA512: afde551bf1212838822188b6723f2bf1b7222decfa1cd7aa6b04967489108a29f80833af6059252af028c53437755f258275af0614e0d4d0311e09421cd8e131
2019-09-18 17:31:02 -05:00
Pasta
75e8e0a45a add a zero to the GenerateNewKey call
Signed-off-by: Pasta <pasta@dashboost.org>
2019-09-18 17:30:20 -05:00
Pasta
11e41b90c9 internal -> fInternal
Signed-off-by: Pasta <pasta@dashboost.org>
2019-09-18 17:30:20 -05:00
Wladimir J. van der Laan
b8c1d66fb9 Merge #10795: No longer ever reuse keypool indexes
1fc8c3d No longer ever reuse keypool indexes (Matt Corallo)

Pull request description:

  This fixes an issue where you could reserve a keypool entry, then
  top up the keypool, writing out a new key at the given index, then
  return they key from the pool. This isnt likely to cause issues,
  but given there is no reason to ever re-use keypool indexes
  (they're 64 bits...), best to avoid it alltogether.

  Builds on #10235, should probably get a 15 tag.

Tree-SHA512: c13a18a90f1076fb74307f2d64e9d80149811524c6bda259698ff2c65adaf8c6c3f2a3a07a5f4bf03251bc942ba8f5fd33a4427aa4256748c40b062991682caf
2019-09-18 17:30:20 -05:00
Pieter Wuille
d04633d28c Merge #10707: Better API for estimatesmartfee RPC
06bcdb8da Convert named argument from nblocks to conf_target (Alex Morcos)
439c4e8ad Improve api to estimatesmartfee (Alex Morcos)

Pull request description:

  Through 0.14 branch, the estimatesmartfee API was tagged "WARNING: This interface is unstable and may disappear or change!" and this warning is removed for 0.15, so any wanted API updates should happen now.

  The changes here are to make the additional parameter for conservative estimates a more general estimate_mode string , to omit the feerate and include an error string instead of returning -1 on error, and to do better parameter checking initially.

  ~It is only the last 2 commits, but it's built on #10706 and #10543~.

  See https://github.com/bitcoin/bitcoin/pull/10707#issuecomment-314869251 for renaming of nblocks argument to conf_target.  Will need to be included before string freeze.

  PR description edited for clarity

Tree-SHA512: 6d8ebee8bb410e2950ffd59663eebfed8d1611d995dc935bb91e430d9da7e2f306796f45631458376027d26341c660f09e825e61748103d2f2736ec6dc3df3ae
2019-09-18 17:30:20 -05:00
PastaPastaPasta
1acde17e8a Don't care about governance cache while the blockchain isn't synced yet (#3089)
`2019-09-14 05:31:13 CGovernanceManager::UpdateCachesAndClean -- Governance Objects: 0 (Proposals: 0, Triggers: 0, Other: 0; Erased: 0), Votes: 0
 59m
 60m
`

Signed-off-by: Pasta <pasta@dashboost.org>
2019-09-17 15:09:04 +03:00
UdjinM6
0d126c2ae4
Use chainparams factory for devnet (#3087) 2019-09-17 15:08:37 +03:00
PastaPastaPasta
ac90abe892 When mixing, always try to join an exsisting queue, only fall back to starting a new queue (#3085)
Signed-off-by: Pasta <pasta@dashboost.org>
2019-09-17 15:07:56 +03:00
PastaPastaPasta
65cd334794 Tools window: Information - make "InstantSend locks" and "Number of Masternodes" fields copyable
Signed-off-by: Pasta <pasta@dashboost.org>
2019-09-15 23:09:01 +03:00
PastaPastaPasta
68d575dc0d Masternodes should have no wallet enabled (#3084) 2019-09-15 23:08:21 +03:00
PastaPastaPasta
6b5b70fab8 Remove liquidity provider privatesend (#3082)
* remove liquidity provider. The reason behind this is two fold:
1. it is very likely nobody is currently running this on the mainnet (due to already strong liquidity), it provides no use for testnet as there you can just enable mixing and get the same affect. Because of this reason I don't find it okay to just remove it outright.
2. even if people did use it (or if some do as a novelty) it likely hurts the privacy of the system. This is because as a liquidity provider your outputs will always take many (sometimes hundreds) blocks before being used in a new mixing round, whereas real user's funds will normally be mixed again very rapidly.

Signed-off-by: Pasta <pasta@dashboost.org>

* remove unused function

Signed-off-by: Pasta <pasta@dashboost.org>
2019-09-15 23:08:05 +03:00
PastaPastaPasta
0b2221ed6b Clarify default max peer connections (#3081)
* clarify comment regarding default peer connections and how that applies to MNs

Signed-off-by: Pasta <pasta@dashboost.org>

* clarify debug log when maxconnections is force set

Signed-off-by: Pasta <pasta@dashboost.org>
2019-09-15 23:07:11 +03:00
UdjinM6
b874fcc8c5
Merge pull request #3080 from PastaPastaPasta/backport-0.15-pr25
Backport 0.15 pr25
2019-09-15 23:06:37 +03:00
PastaPastaPasta
ddef2025bb
sat -> duff
thanks @thephez
2019-09-11 15:42:05 -05:00
UdjinM6
a7e20cd4c2
Use chainparams passed into ATMPW 2019-09-08 21:01:02 -05:00
UdjinM6
e6df5690a2
Drop segwit related parts and fix cs_main issues 2019-09-08 21:00:54 -05:00
UdjinM6
70e386580d
Backport meaningful parts of 8149/2b1f6f9ccf36f1e0a2c9d99154e1642f796d7c2b 2019-09-08 21:00:44 -05:00
Wladimir J. van der Laan
6fd35565a3
Merge #13527: policy: Remove promiscuousmempoolflags
faa24441ec047ec336b86f586016b9d318c1c0ad policy: Remove promiscuousmempoolflags (MarcoFalke)

Pull request description:

  It seems odd to clutter validation code with features that can only ever be used for testing (testnet or regtest). Removing that test-only code makes the mempool logic less painful to understand and easier to reason about when changed or refactored in the future.

Tree-SHA512: 3b897aa9604ac8d82ebe9573c6efd468c93ddaa08d378ebc902e247b7aa6c68fcde71e5b449c08f17a067146cdc66dc50a67ce06d07607c27e5189a49c3fba3f
2019-09-08 21:00:33 -05:00
PastaPastaPasta
9b8df2f52a
add dip3params
Co-Authored-By: UdjinM6 <UdjinM6@users.noreply.github.com>
2019-09-08 11:10:36 -05:00