Péter Szilágyi
|
ebf2aabd25
|
core: fix up a deadlock caused by double locking
|
2015-06-09 16:26:44 +03:00 |
|
Péter Szilágyi
|
ff84352fb7
|
p2p: fix close data race
|
2015-06-09 16:12:24 +03:00 |
|
Péter Szilágyi
|
ca8cb65b73
|
core: fix data race accessing ChainManager.currentBlock
|
2015-06-09 15:30:46 +03:00 |
|
Péter Szilágyi
|
07baf66200
|
core: fix data race in accessing ChainManager.td
|
2015-06-09 15:23:20 +03:00 |
|
Péter Szilágyi
|
d09ead546c
|
eth: fix a data race in the hash announcement processing
|
2015-06-09 15:09:15 +03:00 |
|
Péter Szilágyi
|
f86707713c
|
eth: fix data race accessing peer.td
|
2015-06-09 14:56:27 +03:00 |
|
Péter Szilágyi
|
44147d057d
|
eth: fix data race accessing peer.recentHash
|
2015-06-09 14:27:44 +03:00 |
|
Péter Szilágyi
|
8216bb901c
|
eth: clean up pending announce download map, polish logs
|
2015-06-09 00:37:10 +03:00 |
|
Péter Szilágyi
|
9ed166c196
|
eth: split and handle explicitly vs. download requested blocks
|
2015-06-08 20:38:39 +03:00 |
|
Péter Szilágyi
|
fdccce781e
|
eth: fetch announced hashes from origin, periodically
|
2015-06-08 19:24:56 +03:00 |
|
Péter Szilágyi
|
8c012e103f
|
eth: mark blocks as known when broadcasting hashes too
|
2015-06-08 18:44:02 +03:00 |
|
Péter Szilágyi
|
6f415b96b3
|
eth: implement the NewBlockHashes protocol proposal
|
2015-06-08 18:44:02 +03:00 |
|
Péter Szilágyi
|
4ed3509a02
|
eth/downloader: test registration rejection on head ban
|
2015-06-08 15:02:52 +03:00 |
|
Péter Szilágyi
|
c4f224932f
|
eth/downloader: reject peer registration if head is banned
|
2015-06-08 14:46:31 +03:00 |
|
Péter Szilágyi
|
63c6cedb14
|
eth/downloader: cap the hash ban set, add test for it
|
2015-06-08 14:12:00 +03:00 |
|
Péter Szilágyi
|
4b2dd44711
|
eth/downloader: fix throttling test to be less timing dependent
|
2015-06-08 13:23:58 +03:00 |
|
Péter Szilágyi
|
2d627995cf
|
eth/downloader: fix another rebase error
|
2015-06-08 13:23:58 +03:00 |
|
Péter Szilágyi
|
b40c796ff7
|
eth/downloader: preallocate the block cache
|
2015-06-08 13:23:58 +03:00 |
|
Péter Szilágyi
|
1d7bf3d39f
|
eth/downloader: fix merge compile error
|
2015-06-08 13:23:58 +03:00 |
|
Péter Szilágyi
|
6d497f61c6
|
eth/downloader: don't block hash deliveries while pulling blocks
|
2015-06-08 13:23:58 +03:00 |
|
Péter Szilágyi
|
9da0232eef
|
eth/downloader: update test for shitty travis
|
2015-06-08 13:23:58 +03:00 |
|
Péter Szilágyi
|
0275fcb3d3
|
eth/downloader: clean up and simplify the code a bit
|
2015-06-08 13:23:58 +03:00 |
|
Péter Szilágyi
|
abdfcda4dd
|
eth/downloader: short circuit sync if head hash is banned
|
2015-06-08 13:23:58 +03:00 |
|
Péter Szilágyi
|
84bc93d8cb
|
eth/downloader: accumulating hash bans for reconnecting attackers
|
2015-06-08 13:23:58 +03:00 |
|
Péter Szilágyi
|
eedb25b22a
|
eth/downloader: clean up tests and unused variables
|
2015-06-08 13:23:57 +03:00 |
|
Péter Szilágyi
|
94e525ae12
|
eth, eth/downloader: fix #1098, elevate empty hash errors to peer drops
|
2015-06-05 12:52:48 +03:00 |
|
Péter Szilágyi
|
328ef60b85
|
eth/downloader: differentiate stale and nonexistent deliveries
|
2015-06-05 12:37:48 +03:00 |
|
Péter Szilágyi
|
94e4aa6ea9
|
eth/downloader: log hard timeouts and reset capacity
|
2015-06-05 11:53:46 +03:00 |
|
Péter Szilágyi
|
d754c25cc8
|
eth/downloader: drop log entry from peer, it's covered already
|
2015-06-04 16:22:55 +03:00 |
|
Péter Szilágyi
|
24cca2f18d
|
eth/downloader: log after state updates, easier to debug
|
2015-06-04 15:10:43 +03:00 |
|
Péter Szilágyi
|
28c32d1b1b
|
eth/downloader: fix #1178, don't request blocks beyond the cache bounds
|
2015-06-04 14:51:14 +03:00 |
|
Péter Szilágyi
|
3ec159ab6b
|
eth/downloader: demote peers if they exceed the soft limits at 1 blocks already
|
2015-06-03 15:43:12 +03:00 |
|
Péter Szilágyi
|
c9a546c310
|
eth/downloader: add a basic block download congestion control
|
2015-06-03 14:40:11 +03:00 |
|
Péter Szilágyi
|
14e7192d9c
|
crypto/sha3: pull in latest keccak from go crypto (45% speed increase)
|
2015-06-03 12:00:39 +03:00 |
|
Péter Szilágyi
|
b7fc85d68e
|
core: fix #1154, sort out data race accessing the future blocks
|
2015-05-29 23:46:10 +03:00 |
|
Péter Szilágyi
|
29b0480cfb
|
core, eth/downloader: expose the bad hashes, check in downloader
|
2015-05-28 14:03:10 +03:00 |
|
Péter Szilágyi
|
5235e01b8d
|
eth: hard disconnect if a peer is flaky
|
2015-05-27 18:58:51 +03:00 |
|
Péter Szilágyi
|
3f91ee4ff8
|
cmd/geth: expand admin.progress() to something meaningful
|
2015-05-27 16:46:46 +03:00 |
|
Péter Szilágyi
|
612f01400f
|
p2p/discover: bond with seed nodes too (runs only if findnode failed)
|
2015-05-26 23:30:41 +02:00 |
|
Péter Szilágyi
|
3630432dfb
|
p2p/discovery: fix a cornercase loop if no seeds or bootnodes are known
|
2015-05-26 23:30:40 +02:00 |
|
Péter Szilágyi
|
f539ed1e66
|
p2p/discover: force refresh if the table is empty
|
2015-05-26 23:30:40 +02:00 |
|
Péter Szilágyi
|
5076170f34
|
p2p/discover: permit temporary bond failures for previously known nodes
|
2015-05-26 23:30:40 +02:00 |
|
Péter Szilágyi
|
6078aa08eb
|
p2p/discover: watch find failures, evacuate on too many, rebond if failed
|
2015-05-26 23:30:40 +02:00 |
|
Péter Szilágyi
|
64174f196f
|
p2p/discover: add support for counting findnode failures
|
2015-05-26 23:30:40 +02:00 |
|
Péter Szilágyi
|
4de8213887
|
cmd/geth: fix js console test for p2p server update
|
2015-05-26 19:35:31 +03:00 |
|
Péter Szilágyi
|
68898a4d6b
|
p2p: fix Self() panic if listening is disabled
|
2015-05-26 19:16:05 +03:00 |
|
Péter Szilágyi
|
e1a0ee8fc5
|
cmd/geth, cmd/utils, eth, p2p: pass and honor a no discovery flag
|
2015-05-26 19:07:24 +03:00 |
|
Péter Szilágyi
|
278183c7e7
|
eth, p2p: start the p2p server even if maxpeers == 0
|
2015-05-26 17:49:37 +03:00 |
|
Péter Szilágyi
|
3083ec5e32
|
eth/downloader: silence "Added N blocks from..." if N == 0
|
2015-05-26 16:10:28 +03:00 |
|
Péter Szilágyi
|
eafdc1f8e3
|
eth, eth/downloader: surface downloaded block origin, drop on error
|
2015-05-26 14:00:21 +03:00 |
|
Péter Szilágyi
|
cbd3ae6906
|
p2p/discover: fix #838, evacuate self entries from the node db
|
2015-05-21 19:41:46 +03:00 |
|
Péter Szilágyi
|
af24c271c7
|
p2p/discover: fix database presistency test folder
|
2015-05-21 19:28:10 +03:00 |
|
Péter Szilágyi
|
06a041589f
|
eth, eth/downloader: remove duplicate consts, bump hash fetch to 2K
|
2015-05-21 18:16:04 +03:00 |
|
Péter Szilágyi
|
52db6d8be5
|
eth/downloader: circumvent a forged block chain with known parent attack
|
2015-05-21 08:37:27 +03:00 |
|
Péter Szilágyi
|
e8b22b9253
|
eth/downloader: prevent a peer from dripping bad hashes
|
2015-05-21 08:07:58 +03:00 |
|
Péter Szilágyi
|
3c8227b935
|
eth: fix odd method names in peer set
|
2015-05-20 10:34:45 +03:00 |
|
Péter Szilágyi
|
6f54eb6d9a
|
eth/downloader: fix test to it doesn't time out on a slow machine
|
2015-05-20 10:15:42 +03:00 |
|
Péter Szilágyi
|
4755caeb2d
|
eth: remote a superfluous peerSet method
|
2015-05-18 21:35:42 +03:00 |
|
Péter Szilágyi
|
5422fe5125
|
eth: make the peer set thread safe
|
2015-05-18 21:33:37 +03:00 |
|
Péter Szilágyi
|
412cf98bbc
|
eth/downloader: fix #992, where tests may time out on a slow machine
|
2015-05-15 21:16:42 +03:00 |
|
Péter Szilágyi
|
f3ae8f50a5
|
eth/downloader: circumvent download race between crosscheck and hashes
|
2015-05-15 20:54:10 +03:00 |
|
Péter Szilágyi
|
4f0d88cb02
|
eth/downloader: fix cancel channel double close
|
2015-05-15 19:43:42 +03:00 |
|
Péter Szilágyi
|
5c1a7b965c
|
eth/downloader: circumvent a fake blockchain attack
|
2015-05-15 15:04:15 +03:00 |
|
Péter Szilágyi
|
b517967f86
|
eth/downloader: don't penalize for stale cross checks
|
2015-05-15 15:03:08 +03:00 |
|
Péter Szilágyi
|
83226762c2
|
eth, eth/downloader: detect and handle madeup hash attacks
|
2015-05-15 15:01:58 +03:00 |
|
Péter Szilágyi
|
9ad515d2dc
|
eth: drop a sync peer if it sends an invalid hash chain
|
2015-05-15 15:01:58 +03:00 |
|
Péter Szilágyi
|
72411eb24c
|
eth/downloader: circumvent hash reordering attacks
|
2015-05-15 15:01:58 +03:00 |
|
Péter Szilágyi
|
bcc2980179
|
eth/downloader: check sync after failed attacks
|
2015-05-15 15:01:58 +03:00 |
|
Péter Szilágyi
|
366e9627e8
|
eth/downloader: add a test for detecting missing blocks
|
2015-05-15 15:01:58 +03:00 |
|
Péter Szilágyi
|
cd2fb09051
|
eth, eth/downloader: prevent hash repeater attack
|
2015-05-15 15:01:58 +03:00 |
|
Péter Szilágyi
|
fe87feccb1
|
eth/downloader: add a small additional check to the test
|
2015-05-14 15:44:54 +03:00 |
|
Péter Szilágyi
|
ebf1eb9359
|
eth/downloader: remove a previous leftover
|
2015-05-14 15:40:28 +03:00 |
|
Péter Szilágyi
|
3eda70c64c
|
eth, eth/downloader: remove parent verification from the downlaoder
|
2015-05-14 15:38:49 +03:00 |
|
Péter Szilágyi
|
a4246c2da6
|
eth, eth/downloader: handle a potential unknown parent attack
|
2015-05-14 15:24:18 +03:00 |
|
Péter Szilágyi
|
3edc4698fe
|
Merge pull request #954 from karalabe/fix-downloader-nil-panic
eth/downloader: fix nil panic caused by wrong variable use
|
2015-05-13 18:15:18 +02:00 |
|
Péter Szilágyi
|
910a6d4e46
|
eth/downloader: fix nil panic caused by wrong variable use
|
2015-05-13 17:25:01 +03:00 |
|
Péter Szilágyi
|
de3a71cafd
|
eth/downloader: remove a redundant sync progress check
|
2015-05-13 16:56:01 +03:00 |
|
Péter Szilágyi
|
48ee0777a5
|
eth/downloader: add a user sync notificaton
|
2015-05-13 16:03:05 +03:00 |
|
Péter Szilágyi
|
ec57aa64cd
|
eth/downloader: sync the cancel channel during cancel too
|
2015-05-13 14:01:08 +03:00 |
|
Péter Szilágyi
|
ee0c892303
|
eth/downloader: fix deliveries to check for sync cancels
|
2015-05-13 13:47:21 +03:00 |
|
Péter Szilágyi
|
d2d5dbc6fb
|
eth/downloader: fix active peer shadowing, polish func names
|
2015-05-13 13:13:43 +03:00 |
|
Péter Szilágyi
|
064cf16099
|
eth/downloader: use count instead of peers, clearer
|
2015-05-11 17:21:22 +02:00 |
|
Péter Szilágyi
|
d37a2559b9
|
eth/downloader: revert to demotion, use harsher penalty
|
2015-05-11 17:21:22 +02:00 |
|
Péter Szilágyi
|
70c65835f4
|
eth/downloader: fix #910, thread safe peers & polishes
|
2015-05-11 17:21:22 +02:00 |
|
Péter Szilágyi
|
fa53c5e074
|
eth/downloader: use count instead of peers, clearer
|
2015-05-11 17:10:00 +03:00 |
|
Péter Szilágyi
|
ebbd8b0743
|
eth/downloader: revert to demotion, use harsher penalty
|
2015-05-11 16:47:58 +03:00 |
|
Péter Szilágyi
|
685862d2ce
|
eth/downloader: fix #910, thread safe peers & polishes
|
2015-05-11 14:26:20 +03:00 |
|
Péter Szilágyi
|
0ad5898c0f
|
rpc, xeth: fix #881, gracefully handle offline whisper
|
2015-05-11 11:53:53 +03:00 |
|
Péter Szilágyi
|
edad47bf0e
|
eth/downloader: fix leftover state between syncs
|
2015-05-08 17:39:03 +03:00 |
|
Péter Szilágyi
|
bd5720f480
|
eth, eth/downloader: handle sync errors a bit more gracefully
|
2015-05-08 15:22:48 +03:00 |
|
Péter Szilágyi
|
9d188f73b5
|
eth, eth/downloader: make synchronize thread safe
|
2015-05-07 21:07:20 +03:00 |
|
Péter Szilágyi
|
8735e5addd
|
p2p: increase the handshake timeout in the tests
|
2015-05-07 15:30:56 +03:00 |
|
Péter Szilágyi
|
4d5a719f25
|
cmd, eth, p2p: introduce pending peer cli arg, add tests
|
2015-05-07 15:30:56 +03:00 |
|
Péter Szilágyi
|
af93217775
|
p2p: reduce the concurrent handshakes to 10/10 in/out
|
2015-05-07 15:22:09 +03:00 |
|
Péter Szilágyi
|
2060bc8bac
|
p2p: fix dial throttling race condition
|
2015-05-07 15:22:08 +03:00 |
|
Péter Szilágyi
|
29fef349ef
|
p2p: fix a dialing race in the throttler
|
2015-05-07 15:22:08 +03:00 |
|
Péter Szilágyi
|
3953bf0031
|
p2p: limit the outbound dialing too
|
2015-05-07 15:22:08 +03:00 |
|
Péter Szilágyi
|
43901c9282
|
eth/downloader: fix priority queue reset, add throttling test
|
2015-05-07 14:40:50 +03:00 |
|
Péter Szilágyi
|
45f8304f3c
|
eth/downloader: fix expiration not running while fetching
|
2015-05-07 12:59:19 +03:00 |
|
Péter Szilágyi
|
4800c94392
|
eth/downloader: prioritize block fetch based on chain position, cap memory use
|
2015-05-07 10:57:34 +03:00 |
|