4269 Commits

Author SHA1 Message Date
Warren Togami
9cffb23c2d Litecoin v0.8.7.5 2015-01-12 16:55:18 -10:00
Warren Togami
fb92215a09 Litecoin: Upgrade to openssl-1.0.1k 2015-01-12 16:55:18 -10:00
Wladimir J. van der Laan
af4beb8e70 Improve robustness of DER recoding code
Add some defensive programming on top of #5634.

This copies the respective OpenSSL code in ECDSA_verify in
OpenSSL pre-1.0.1k (e.g. https://github.com/openssl/openssl/blob/OpenSSL_1_0_1j/crypto/ecdsa/ecs_vrf.c#L89)
more closely.

As reported by @sergiodemianlerner.

Bitcoin Github-Pull: #5640
Rebased-From: c6b7b29f232c651f898eeffb93f36c8f537c56d2
2015-01-12 16:55:18 -10:00
Cory Fields
95479ca7f6 consensus: guard against openssl's new strict DER checks
New versions of OpenSSL will reject non-canonical DER signatures. However,
it'll happily decode them. Decode then re-encode before verification in order
to ensure that it is properly consumed.

Rebased-from: 488ed32f2ada1d1dd108fc245d025c4d5f252783

fail immediately on an empty signature

Rebased-from: 8dccba6a45db0466370726ed462b9da2eae43bce
2015-01-09 20:56:32 -10:00
Warren Togami
c1e46ab3a9 Litecoin v0.8.7.4 2014-09-15 23:53:37 -10:00
Warren Togami
52b3c6d66b Litecoin: Lockin v2 blocks at 710k mainnet, 400k testnet 2014-09-15 23:53:32 -10:00
Warren Togami
e77aede122 Litecoin v0.8.7.3 2014-09-11 18:01:37 -10:00
Warren Togami
304477779f Litecoin: Release notes for 0.8.7.3 2014-09-11 18:01:37 -10:00
Warren Togami
c1d70885c2 Litecoin: Upgrade to openssl-1.0.1i 2014-09-11 18:01:33 -10:00
Warren Togami
ea4717af74 Litecoin: Lock in v2 blocks at height 700000 2014-09-11 18:01:22 -10:00
Warren Togami
57ab38f589 Litecoin: Checkpoint at block 638902 2014-09-11 18:01:22 -10:00
Warren Togami
5dfe402720 Litecoin: Reduce DEFAULT_MAX_ORPHAN_TRANSACTIONS to 25 2014-09-11 18:01:22 -10:00
Gavin Andresen
e0199e9ae8 Store fewer orphan tx by default, add -maxorphantx option
There is no reason to store thousands of orphan transactions;
normally an orphan's parents will either be broadcast or
mined reasonably quickly.

This pull drops the maximum number of orphans from 10,000 down
to 100, and adds a command-line option (-maxorphantx) that is
just like -maxorphanblocks to override the default.

Rebased-from: aa3c697e90c02d5797a59a7bfb1ecac6fbd918cf
2014-09-11 18:01:22 -10:00
Jeff Garzik
056353a2e3 Avoid returning many "inv" orphans
Rebased-from: 540ac4514dbe4e077917bad1750768218ef5f9cf
2014-09-11 18:01:22 -10:00
Wladimir J. van der Laan
4f7e47a64e Limit CNode::mapAskFor
Tighten resource constraints on CNode.

Rebased-From: d4168c82bef0d86fd254a9d993906a09f5fd7fc0 for 0.8
2014-09-11 18:01:22 -10:00
Gavin Andresen
826cd8b909 Fix crashing bug caused by orphan(s) with duplicate prevout.hash
Rebased-From: def2fdb
Rebased-By: Wladimir J. van der Laan
2014-09-11 18:01:22 -10:00
Wladimir J. van der Laan
f8d9593ce0 Avoid repeated lookups in mapOrphanTransactions and mapOrphanTransactionsByPrev
Rebased-From: 89d91f6
Rebased-By: Wladimir J. van der Laan <laanwj@gmail.com>
2014-09-11 18:01:22 -10:00
Wladimir J. van der Laan
85a4b6da55 Don't poll showmyip.com, it doesn't exist anymore
Fixes #4679.

This leaves us with only one candidate, checkip.dyndns.org.
GetMyExternalIP should be phased out as soon as possible.

Rebased-from: c33b983903c64d88a2aef24da1827b86aadce596
2014-09-11 18:01:22 -10:00
pooler
91b6a2cd53 Litecoin: update pnSeed array 2014-09-12 04:24:18 +02:00
Warren Togami
fab1907372 Litecoin v0.8.7.2 2014-06-13 11:36:21 -10:00
Warren Togami
cc924b775c Litecoin: Checkpoint at block 585010 2014-06-13 11:32:29 -10:00
Warren Togami
dabb4df745 Merge pull request #159 from whitj00/patch-1
Changed old bitcoin links
2014-06-13 10:50:25 -10:00
Warren Togami
f91b455f59 Merge pull request #162 from linki/fix/openssl-1.0.1h
gitian: upgrade to openssl-1.0.1h for CVE-2014-0224
2014-06-13 10:49:41 -10:00
Martin Linkhorst
73f892b590 upgrade to openssl-1.0.1h for CVE-2014-0224 2014-06-13 20:43:52 +02:00
whitj00
c2cf47946a Changed old bitcoin links 2014-05-31 22:46:20 -07:00
pooler
ccd9a1f5f7 Update testnet DNS seeds 2014-04-22 22:37:24 +02:00
Warren Togami
aa77ae3a8c Litecoin v0.8.7.1 2014-04-19 01:43:29 -10:00
Warren Togami
cbe869e153 Revert "RPC: prevent crash with walletpassphrase"
This crash seemed to have never happened in 0.8.x, and we are missing the later commit
in a8db31c83d6a43e07f741f7f61b1bf0df87621c7 so it seems better to just revert this.

This reverts commit 036a69c13c06670b46d3c02cb47e3fc7b2487854.
2014-04-18 20:57:04 -10:00
seikochan
9ec7b25cd6 Litecoin: Update more copyright notices. 2014-04-18 14:49:41 -10:00
Warren Togami
6ce2f0b2fb Litecoin v0.8.6.9 2014-04-09 01:20:21 -10:00
Warren Togami
41fa624525 Litecoin: Upgrade openssl, qt, miniupnpc, zlib, libpng, qrencode 2014-04-09 01:06:20 -10:00
Warren Togami
06e78495d5 Litecoin: Checkpoint at block 541794 2014-04-03 22:03:45 -10:00
Warren Togami
09137b47e4 getnormalizedtxid now explains itself. 2014-04-03 21:59:20 -10:00
Pieter Wuille
bc7bc9d751 Add normalized transaction hash
Rebased-from: e7853a91cf646a6a4701158d148f036924575a97
Rebased-by:   Warren Togami <wtogami@gmail.com>

Original code from https://github.com/bitcoin/bitcoin/pull/3656

Warning
=======
This patch was rejected from Bitcoin Core and must be considered experimental.
Theoretically it is compatible with the de facto standard as utilized by
blockchain.info and a few vendors.
2014-04-03 21:59:20 -10:00
Warren Togami
bb85fc8477 Litecoin: reject fee > 1 LTC in sendrawtransaction 2014-04-03 21:59:20 -10:00
Warren Togami
70313dd1e7 Litecoin: settxfee label in LTC 2014-04-03 21:59:20 -10:00
Wladimir J. van der Laan
55929d483b Remove "conflicted" as transaction category.
We were losing information about sent/received by overriding the
category in case of a conflicted transaction.

Hence, remove the "conflicted" category.

Conflicted status of a transaction can still be determined by looking
for confirmations<0.

Rebased-from: b77ecd66b6b19921c98422bf70a39c4338c2f8b9 0.8.x
2014-04-03 21:59:19 -10:00
Pieter Wuille
fc1426bc0a Add HasCanonicalPushes(), and use it in IsStandardTx
Conflicts:
	src/script.cpp
	src/script.h

Rebased-from: b8ee034b9f47b562932ba21cd0334d803f77ec98 0.8.x
2014-04-03 21:59:19 -10:00
Wladimir J. van der Laan
9b8b8075df qt: Add option to (not) spend unconfirmed change
- Add a wallet tab to options dialog
- Move fee setting to wallet tab
- Add new setting to set -nospendzeroconfchange from UI

Conflicts:
	src/qt/optionsmodel.cpp
	src/qt/optionsmodel.h

Conflicts:
	src/qt/forms/optionsdialog.ui
	src/qt/optionsmodel.h

Rebased-from: 391cf691d5eee2934ed0e2e2b59bd99987c394a5 0.8.x
2014-04-03 21:59:19 -10:00
Luke Dashjr
9ae42ca79b Bump copyright years to 2014 for changed files
Rebased-from: 0de199f4b52774afd6af583db9962705abbfa98a 0.8.x
2014-04-03 21:59:19 -10:00
Gavin Andresen
1222b1b59c Handle "conflicted" transactions properly
Extend CMerkleTx::GetDepthInMainChain with the concept of
a "conflicted" transaction-- a transaction generated by the wallet
that is not in the main chain or in the mempool, and, therefore,
will likely never be confirmed.

GetDepthInMainChain() now returns -1 for conflicted transactions
(0 for unconfirmed-but-in-the-mempool, and >1 for confirmed).

This makes getbalance, getbalance '*', and listunspent all agree when there are
mutated transactions in the wallet.

Before:
 listunspent: one 49BTC output
 getbalance: 96 BTC (change counted twice)
 getbalance '*': 46 BTC (spends counted twice)

After: all agree, 49 BTC available to spend.

Conflicts:
	src/qt/walletmodel.cpp
	src/wallet.cpp

Conflicts:
	src/wallet.cpp

Rebased-from: 07986591be1610f3a209f15755dabad14322f16c 0.8.x
2014-04-03 21:59:19 -10:00
b6393ce9-d324-4fe1-996b-acf82dbc3d53
441f09f263 If requested, actually treat uncomfirmed change as being uncomfirmed
This commit strengthens 1bbca249b202c4802cc2c4d4de4a26e6392b4d92 by updating the CWalletTx::IsConfirmed() function.

If (bSpendZeroConfChange==false), then IsConfirmed() should actually treat unconfirmed change as being unconfirmed.

Rebased-from: cd46fbf38e9a518633c254381209ed05410bc280
2014-04-03 21:59:18 -10:00
Peter Todd
3a67c1ff27 Partial: Fix off-by-one errors in use of IsFinalTx()
Conflicts:
	src/main.cpp
	src/miner.cpp
	src/qt/transactiondesc.cpp
	src/qt/transactionrecord.cpp

Rebased-from: 3f25f26edcc41b22130c5845024b86a9b1aa6183 0.8.x
2014-04-03 21:59:18 -10:00
Wladimir J. van der Laan
d2ee3aecbe qt: add missing cs_wallet lock in AddressTableModel::setData
duplicate check in AddressTableModel::setData accesses
wallet data structure as well as SetAddressBook without proper LOCK, fix this.

Conflicts:
	src/qt/addresstablemodel.cpp

Rebased-from: 72378a3b67c559310f8047a622ee109850f80e59 0.8.x
2014-04-03 21:59:18 -10:00
Gregory Maxwell
6a51fcf1bd [raw] reject insanely high fees by default in sendrawtransaction
There have been several incidents where mainnet experimentation with
 raw transactions  resulted in insane fees.  This is hard to prevent
 in the raw transaction api because the inputs may not be known.
 Since sending doesn't work if the inputs aren't known, we can catch
 it there.

This rejects fees > than 10000 * nMinRelayTxFee or 1 BTC with the
 defaults and can be overridden with a bool at the rpc.

Conflicts:
	src/main.cpp
	src/main.h
	src/rpcrawtransaction.cpp

Rebased-from: 6349de20f90f046aefa9eaae0de8e3faf11527fa 0.8.x
2014-04-03 21:59:18 -10:00
Wladimir J. van der Laan
6b7c937114 Add option to avoid spending unconfirmed change
Conflicts:
	src/init.cpp
	src/wallet.cpp
	src/wallet.h

Rebased-from: 86d40cab2725e758f4ddaf1e1149f0ab897df110 0.8.x
2014-04-03 21:59:18 -10:00
Wladimir J. van der Laan
c1c35358fb Fix getaddednodeinfo RPC call with dns=false
The getaddednodeinfo RPC call, when invoked with the dns flag set to
false, returns a malformed JSON object with duplicate keys.

Change this to return an array of objects with one key as
shown in the help message.

Fixes #3581.

Rebased-from: a41825be5762ff36dcf0d89c20b95572af30c6bb 0.8.x
2014-04-03 21:59:18 -10:00
Wladimir J. van der Laan
7e1d5ca894 Add check for valid keys in importprivkey
The base58 armoring was checked, but not the resulting private key,
which could be out of range. Fix this by adding a check.

Conflicts:
	src/rpcdump.cpp

Conflicts:
	src/rpcdump.cpp

Rebased-from: b403ab80ab39d41a6f965479cdf878cd8e58a399 0.8.x
2014-04-03 21:59:17 -10:00
Wladimir J. van der Laan
56646670e1 qt: Fix richtext detection hang issue on very old Qt versions
Alternative implementation. Thanks to @awoland for the original.
Fixes #3486.

Rebased-from: 90a28680bd8b24800428b301f7bf6cbf534de2ca 0.8.x
2014-04-03 21:59:17 -10:00
Luke Dashjr
7f85c10736 Bugfix: Undefine _FORTIFY_SOURCE before redefining it, to avoid warnings on compilers that define it by default
Rebased-from: 2b5514138ab0b4e7fd1cbebe77852d41d09ca38d 0.8.x
2014-04-03 21:59:17 -10:00