erigon-pulse/p2p
Felix Lange a98d1d67d6 p2p/discover, p2p/discv5: prevent relay of invalid IPs and low ports
The discovery DHT contains a number of hosts with LAN and loopback IPs.
These get relayed because some implementations do not perform any checks
on the IP.

go-ethereum already prevented relay in most cases because it verifies
that the host actually exists before adding it to the local table. But
this verification causes other issues. We have received several reports
where people's VPSs got shut down by hosting providers because sending
packets to random LAN hosts is indistinguishable from a slow port scan.

The new check prevents sending random packets to LAN by discarding LAN
IPs sent by Internet hosts (and loopback IPs from LAN and Internet
hosts). The new check also blacklists almost all currently registered
special-purpose networks assigned by IANA to avoid inciting random
responses from services in the LAN.

As another precaution against abuse of the DHT, ports below 1024 are now
considered invalid.
2016-11-22 22:21:18 +01:00
..
discover p2p/discover, p2p/discv5: prevent relay of invalid IPs and low ports 2016-11-22 22:21:18 +01:00
discv5 p2p/discover, p2p/discv5: prevent relay of invalid IPs and low ports 2016-11-22 22:21:18 +01:00
nat Merge pull request #2914 from fjl/node-coinhabit 2016-09-29 14:24:37 +02:00
netutil p2p/netutil: new package for network utilities 2016-11-22 22:20:38 +01:00
dial_test.go node, p2p: move network config out of Server 2016-05-18 12:19:04 +02:00
dial.go node, p2p, internal: Add ability to remove peers via admin interface 2016-07-14 18:51:41 -04:00
message_test.go all: fix go vet warnings 2016-04-15 11:17:27 +02:00
message.go all: fix license headers one more time 2015-07-23 18:35:11 +02:00
metrics.go eth, metrics, p2p: prepare metrics and net packets to eth/62 2015-08-21 10:30:57 +03:00
peer_error.go p2p: fix value of DiscSubprotocolError 2015-08-12 14:15:54 +02:00
peer_test.go all: fix license headers one more time 2015-07-23 18:35:11 +02:00
peer.go p2p: EIP-8 changes 2016-02-19 11:14:48 +01:00
protocol.go eth, p2p, rpc/api: polish protocol info gathering 2015-10-28 12:44:15 +02:00
rlpx_test.go all: Rename crypto.Sha3{,Hash}() to crypto.Keccak256{,Hash}() 2016-02-21 22:34:34 +00:00
rlpx.go p2p: enable EIP-8 handshake sending 2016-04-03 23:10:11 +02:00
server_test.go node, p2p, internal: Add ability to remove peers via admin interface 2016-07-14 18:51:41 -04:00
server.go cmd, mobile, node, p2p: surface the discovery V5 bootnodes 2016-11-14 18:00:14 +02:00