4103 Commits

Author SHA1 Message Date
acerix
984e204d7c apply bitcoin patch for miniupnpc 1.9 2015-10-12 11:35:15 -04:00
langerhans
81e3357b0e Update the version numbers to 1.8.3 2015-06-29 20:26:15 +02:00
langerhans
fdd74c2069 Add a fresh set of fixed and DNS seeds. 2015-06-29 20:22:49 +02:00
Pieter Wuille
cc0ac7a749 Scale up addrman
This change was suggested as Countermeasure 6 in
Eclipse Attacks on Bitcoin’s Peer-to-Peer Network, Ethan Heilman,
Alison Kendler, Aviv Zohar, Sharon Goldberg. ePrint Archive Report
2015/263. March 2015.

Rebased-From: 1d21ba2f5ecbf03086d0b65c4c4c80a39a94c2ee
Github-Pull: #5941

Conflicts:
	src/addrman.h
2015-06-27 14:15:32 +00:00
Pieter Wuille
9b95692530 Always use a 50% chance to choose between tried and new entries
This change was suggested as Countermeasure 2 in
Eclipse Attacks on Bitcoin’s Peer-to-Peer Network, Ethan Heilman,
Alison Kendler, Aviv Zohar, Sharon Goldberg. ePrint Archive Report
2015/263. March 2015.

Rebased-From: c6a63ceeb4956933588995bcf01dc3095aaeb1fc
Github-Pull: #5941
2015-06-27 14:15:32 +00:00
Pieter Wuille
7902f4cc01 Do not bias outgoing connections towards fresh addresses
This change was suggested as Countermeasure 2 in
Eclipse Attacks on Bitcoin’s Peer-to-Peer Network, Ethan Heilman,
Alison Kendler, Aviv Zohar, Sharon Goldberg. ePrint Archive Report
2015/263. March 2015.

Rebased-From: 68ba3f67bd500a64fb8932c6b41924ddc31d76f
Github-Pull: #5941
2015-06-27 14:15:32 +00:00
Pieter Wuille
a56e94f913 Simplify hashing code
Conflicts:
	src/addrman.cpp

Rebased-From: a8ff7c62edc63c7c94bc91c30b80995539ed7477
Github-Pull: #5941
2015-06-27 14:15:32 +00:00
Pieter Wuille
6ae9da28d4 Make addrman's bucket placement deterministic.
Give each address a single fixed location in the new and tried tables,
which become simple fixed-size arrays instead of sets and vectors.

This prevents attackers from having an advantages by inserting an
address multiple times.

This change was suggested as Countermeasure 1 in
Eclipse Attacks on Bitcoin’s Peer-to-Peer Network, Ethan Heilman,
Alison Kendler, Aviv Zohar, Sharon Goldberg. ePrint Archive Report
2015/263. March 2015.

It is also more efficient.

Rebased-From: e6b343d880f50d52390c5af8623afa15fcbc65a2
Github-Pull: #5941

Conflicts:
	src/addrman.cpp
	src/addrman.h
2015-06-27 14:15:32 +00:00
Pieter Wuille
bd36a593d6 Switch addrman key from vector to uint256
Conflicts:
	src/addrman.cpp

Rebased-From: b23add5521e4207085d41a0266617e94435fc22e
Github-Pull: #5941
2015-06-27 14:15:32 +00:00
Pieter Wuille
b8ad085955 Reduce fingerprinting through timestamps in 'addr' messages.
Suggested by Jonas Nick.

Rebased-From: 9c2737901b5203f267d21d728019d64b46f1d9f3
Github-Pull: #5860
2015-06-27 14:15:32 +00:00
Pieter Wuille
fe3a31384c Limit message sizes before transfer
This introduces a fixed limit for the size of p2p messages, and enforces it
before download.

Rebased-From: ba04c4a7801e7d68a5e84035b919e5c3626eb7a7
Github-Pull: #5843
2015-06-27 14:15:26 +00:00
Philip Kaufmann
c118e9d275 prevent SOCKET leak in BindListenPort()
- the call to CloseSocket() is placed after the WSAGetLastError(), because
  a CloseSocket() can trigger an error also, which we don't want for the
  logging in this two cases
2015-06-27 14:11:36 +00:00
Wladimir J. van der Laan
a15d1b4fc1 Convert closesocket 'compat wrapper' to function in netbase
Simpler alternative to #4348.

The current setup with closesocket() is strange. It poses
as a compatibility wrapper but adds functionality.

Rename it and make it a documented utility function in netbase.

Code movement only, zero effect on the functionality.
2015-06-27 14:11:36 +00:00
Pieter Wuille
19d00a2dff Break up CAddrMan's IMPLEMENT_SERIALIZE 2015-06-27 14:11:36 +00:00
Pieter Wuille
6f86ee9cae Introduce whitelisted peers.
This adds a -whitelist option to specify subnet ranges from which peers
that connect are whitelisted. In addition, there is a -whitebind option
which works like -bind, except peers connecting to it are also
whitelisted (allowing a separate listen port for trusted connections).

Being whitelisted has two effects (for now):
* They are immune to DoS disconnection/banning.
* Transactions they broadcast (which are valid) are always relayed,
  even if they were already in the mempool. This means that a node
  can function as a gateway for a local network, and that rebroadcasts
  from the local network will work as expected.

Whitelisting replaces the magic exemption localhost had for DoS
disconnection (local addresses are still never banned, though), which
implied hidden service connects (from a localhost Tor node) were
incorrectly immune to DoS disconnection as well. This old
behaviour is removed for that reason, but can be restored using
-whitelist=127.0.0.1 or -whitelist=::1 can be specified. -whitebind
is safer to use in case non-trusted localhost connections are expected
(like hidden services).
2015-06-27 14:11:36 +00:00
Philip Kaufmann
33333d2e88 error out, when we detect -socks argument 2015-06-27 13:45:18 +00:00
Philip Kaufmann
c5c5ddce02 remove SOCKS4 support from core and GUI
- now we support SOCKS5 only
2015-06-27 13:45:18 +00:00
Pieter Wuille
d0952adabd Use pong receive time rather than processing time 2015-06-27 13:45:18 +00:00
Philip Kaufmann
fbf7c3623d add missing BOOST_FOREACH indentation in ThreadSocketHandler() 2015-06-27 13:45:18 +00:00
Philip Kaufmann
a8fe7c245b small cleanup of #ifdefs in BindListenPort()
- SO_NOSIGPIPE isn't available on WIN32 so merge the 2 non-WIN32 blocks
- use predefined names from header for IPV6_PROTECTION_LEVEL and
  PROTECTION_LEVEL_UNRESTRICTED
2015-06-27 13:44:15 +00:00
Philip Kaufmann
845fc0eb13 add missing vhListenSocket.clear(); to CNetCleanup() 2015-06-27 13:44:15 +00:00
Philip Kaufmann
636716439a remove unused CNode::Cleanup() 2015-06-27 13:44:14 +00:00
Pieter Wuille
d617424616 Ping automatically every 2 minutes (unconditionally)
... instead of after 30 minutes of no sending, for latency measurement
and keep-alive. Also, disconnect if no reply arrives within 20 minutes,
instead of 90 of inactivity (for peers supporting the 'pong' message).
2015-06-27 13:44:14 +00:00
Philip Kaufmann
f347f7ebb3 rename fNoListen to fListen and move to net
- better code readability and it belongs to net
- this is a prerequisite for a pull to add -listen to the GUI
2015-06-27 13:44:14 +00:00
langerhans
d9ff1efb5d Update release type and copyright year 2015-01-17 19:22:19 +01:00
Wladimir J. van der Laan
35fc9351d0 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.

Github-Pull: #5640
Rebased-From: c6b7b29f232c651f898eeffb93f36c8f537c56d2
2015-01-12 20:20:01 +00:00
Wladimir J. van der Laan
3835f3d091 fail immediately on an empty signature
Github-Pull: #5634
Rebased-From: 8dccba6a45db0466370726ed462b9da2eae43bce
2015-01-11 20:54:55 +01:00
Cory Fields
6fa9a5e31a 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.

Github-Pull: #5634
Rebased-From: 488ed32f2ada1d1dd108fc245d025c4d5f252783
2015-01-11 20:54:47 +01:00
langerhans
e5f85a3b99 Adjust version for 1.8.2 2014-12-24 23:11:46 +01:00
langerhans
432ce93412 Bump to release version 2014-12-20 20:21:50 +01:00
langerhans
93d0ddad73 Introduce -maxoutconnections= to set the maximum number of outbound connections 2014-12-20 18:11:15 +01:00
langerhans
e993b12278 Add %i to -blocknotify and replace it by the height of the block that the notification is about 2014-12-20 17:21:29 +01:00
Daniel Kraft
876f23f5f1 Remove unreachable code.
The removed case (pcHead == script.end()) can never be reached, since
we explicitly error out above if that is the case.  It is legacy from
Namecoin's merge-mining, which does not forbid this case earlier.
2014-11-21 11:22:28 +01:00
Abderraouf Adjal
438c40dcf9 optionsmodel.cpp; Use HTTPS with dogechain.info 2014-11-17 23:02:33 +01:00
nameEO
5f6b382db2 Update bitcoin_ko_KR.ts
1. Fix some mistakes(typo, omission, spacing).
2. Re-adjust sentences to proper form.
3. Replace translation of certain words to better one.
4, Update legacy translations of upstream.
-----------------------------------------------------------------------------
I commit this first, and will commit another updates after 'translation resources' updates.

thanks.
2014-10-25 19:44:10 +09:00
langerhans
ea2f35aace Merge pull request #726 from Andymeows/1.8.1-dev
Add a warning message about printing paper wallets while online
2014-10-05 18:11:35 +02:00
Andymeows
a1257a223f When printing paper wallets, add a warning message about security if connected to any peers.
Regenerate addresses at the end of the loop so that the shown wallet is the first to print.
Elaborating on the message after paper wallets are printed about ensuring print quality.
2014-10-04 21:13:26 -05:00
Ross Nicoll
66ba4b436a
Switched to older QT API calls to that paper wallet printing is compatible with Qt 4.6.4. 2014-10-04 20:49:47 +01:00
langerhans
e3de091a6a Merge pull request #721 from rnicoll/1.8.1-dev-orphan
Stricter handling of orphan transactions
2014-10-04 20:25:26 +02:00
Ross Nicoll
77f17ccf20
Add checkpoints for 371,337 and 400,000 blocks, as well as intermediary blocks. 2014-10-04 19:12:52 +01:00
Gavin Andresen
e67aacadd5 Stricter handling of orphan transactions
Prevent denial-of-service attacks by banning
peers that send us invalid orphan transactions
and only storing orphan transactions given to
us by a peer while the peer is connected.

Rebased-From: c74332c67806ed92e6e18de174671a7c30608780

Conflicts:
	src/main.cpp
2014-10-04 01:25:58 +01:00
Ross Nicoll
76ebacb657 Merge pull request #718 from michilumin/1.8.1-dev-limit-orphan-tx
1.8.1 dev limit orphan tx
2014-09-28 13:29:04 +00:00
shshshsh
5cda7594f0 Make max number of orphan blocks kept in memory a startup parameter (fixes #4253)
Rebased-From: 7b45d943b29a443f1ac808c9ee4eeed6df0db9cc

Conflicts:
	src/init.cpp
	src/main.h
2014-09-27 20:03:01 -06:00
Gavin Andresen
8a88bb6550 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.

Conflicts:
	src/main.h
2014-09-27 14:33:07 -06:00
michilumin
94cf9e41d5
Initial check in of branch for conflict resolution 2014-09-27 14:30:53 -06:00
langerhans
649b819fe9 Merge pull request #716 from patricklodder/1.8.1-dev-lang-cleanup
Locale cleanup
2014-09-25 21:58:38 +02:00
langerhans
921685ceab Merge pull request #715 from patricklodder/1.8.1-dev-nl-update
NL translation update
2014-09-25 21:54:56 +02:00
Patrick Lodder
331609fe3e Clean up all locale .ts files
Used the new update-translations.py script to clean up all
locale files. Unlike bitcoin/bitcoin, we're keeping the
unfinished translation tags in place as long as we have
manual translations (whereas bitcoin uses transifex)
2014-09-25 00:43:39 +02:00
Patrick Lodder
d00af20df5 Fix translation sprintf and qt string formats
Some translations had non-matching formats, the update-translations
script would normally remove those and set it to "unfinished".
However, since those are fairly trivial to fix, those have been
manually corrected before doing a cleanup run with the update script.
2014-09-25 00:43:39 +02:00
Patrick Lodder
25573eb06b locale fix: DogecoinS -> DOGECOINS
Fix wrong capitalization in wallet encryption warning message:

"If you encrypt your wallet and lose your passphrase, you will
LOSE ALL OF YOUR DOGECOINS"
2014-09-25 00:18:43 +02:00