erigon-pulse/p2p
awskii a124bcf6ac
added --p2p.allowed-port flag (#6263)
Regarding https://github.com/ledgerwatch/erigon/issues/6260

added flag `--p2p.allowed-ports=<porta>,<portb>` to restrict which ports
to use for sentries for different protocol versions.

Default for this flag is `30303, 30304` (first port is inherited from
`--port` flag defaults.
If `--port` is changed and it's new value is not presented in allowed
port list, provided port will be allowed as well as list provided via
`--p2p.allowed-ports`

Port picking is straightforward, we create sentry gRPC server for
protocol over first allowed port that is not already taken.
If there are no allowed ports left, erigon exits with hint.
2022-12-12 13:25:47 +00:00
..
discover tweak(p2p): trace log level for error from t.matchWithCall (#6214) 2022-12-06 09:29:41 +07:00
dnsdisc move all packages from "internal" folder - to simplify users live (#5857) 2022-10-25 09:58:25 +07:00
enode Use hex package to convert bytes to string (#6205) 2022-12-05 09:06:16 +07:00
enr go1.19 gofmt (#4988) 2022-08-10 19:04:13 +07:00
nat Replace strings.Replace with strings.ReplaceAll (#5128) 2022-08-21 21:21:09 +07:00
netutil Use go:build lines and remove obsolete +build lines (#4175) 2022-05-17 14:46:53 +07:00
rlpx Enable gocritic linter (#5173) 2022-08-25 09:08:56 +07:00
simulations go1.19 gofmt (#4988) 2022-08-10 19:04:13 +07:00
dial_integration_test.go Use go:build lines and remove obsolete +build lines (#4175) 2022-05-17 14:46:53 +07:00
dial_test.go move all packages from "internal" folder - to simplify users live (#5857) 2022-10-25 09:58:25 +07:00
dial.go Enable gosec linter (#5083) 2022-08-17 12:18:19 +07:00
message_test.go p2p: move rlpx into separate package (#21464) 2020-10-06 14:12:09 +02:00
message.go go1.19 gofmt (#4988) 2022-08-10 19:04:13 +07:00
metrics.go MIT licensed metrics lib (#2462) 2021-07-29 17:27:46 +07:00
node_key_config.go go1.19 gofmt (#4988) 2022-08-10 19:04:13 +07:00
peer_error.go p2p: define DiscReason as uint8 (#4090) 2022-05-06 16:19:53 +01:00
peer_test.go Switch peerId from 256 to 512 bit (as in stable) (#3862) 2022-04-10 08:01:25 +01:00
peer.go Downloader extract, step2 (#6076) 2022-11-20 10:41:30 +07:00
protocol.go Switch peerId from 256 to 512 bit (as in stable) (#3862) 2022-04-10 08:01:25 +01:00
server_test.go fix(test): eliminate race conditions (#6019) 2022-11-11 15:22:09 +00:00
server.go added --p2p.allowed-port flag (#6263) 2022-12-12 13:25:47 +00:00
transport_test.go Refactor crypto.FromECDSAPub to MarshalPubkey/Std (#3797) 2022-03-31 11:06:20 +07:00
transport.go remove metrics package, step 1 (#4094) 2022-05-07 14:52:04 +07:00
util_test.go rename (#1978) 2021-05-20 19:25:53 +01:00
util.go Avoiding leaking the popped item (#6193) 2022-12-04 11:17:02 +07:00