H: deny IPv6 link-local and metadata addresses by default Add fe80::/10, ::/128 and fd00:ec2::254/128 to the default deny_cidrs and sync config.example.toml, README and docs/consolidator.md
This commit is contained in:
1 parent
6e74d3d99b
commit
97c81f899c
6 files changed
+54
-5
No files matched your search
@@ -43,7 +43,7 @@ request_timeout_secs = 10 # one proxied request, connect to body
|
||||
max_response_bytes = 8388608 # buffered bodies above this are refused
|
||||
max_concurrent_per_peer = 4 # proxied requests in flight per peer
|
||||
max_concurrent_total = 16 # ... across all peers
|
||||
deny_cidrs = ["169.254.0.0/16", "0.0.0.0/8"] # resolved peer addresses in these ranges are refused
|
||||
deny_cidrs = ["169.254.0.0/16", "0.0.0.0/8", "fe80::/10", "::/128", "fd00:ec2::254/128"] # resolved peer addresses in these ranges are refused
|
||||
|
||||
[[peers.peer]]
|
||||
name = "minipc1" # ^[a-z0-9][a-z0-9_-]{0,31}$, unique, at most 64
|
||||
@@ -56,7 +56,7 @@ enabled = true # false keeps the declaration without contacting
|
||||
|
||||
Scalar keys accept environment overrides (`SKYG_PEERS__ENABLED`, `SKYG_PEERS__API_INTERVAL_SECS`, ...); `[[peers.peer]]` entries are file-only. `slinuxm --print-config` prints `token_file` paths, never their contents. Validation refuses: a timeout that is not below its interval, more than 64 peers, duplicate names, a bad name, a relative `token_file` or `ca_file`, a non-http(s) URL, userinfo/query/fragment in a URL, an IP literal in `deny_cidrs`, and plain `http` to a non-loopback host without `allow_plain_http = true` (which also logs a warning: the bearer token travels in cleartext). `enabled = true` with no peers logs a warning.
|
||||
|
||||
`deny_cidrs` is checked against every **resolved** address at connect time, so a name where any address lands in a denied range is refused as `unreachable`. Private LAN ranges are deliberately allowed; the default denies only link-local/metadata and the unspecified range.
|
||||
`deny_cidrs` is checked against every **resolved** address at connect time, so a name where any address lands in a denied range is refused as `unreachable`. IPv4-mapped addresses are compared in their IPv4 form, so `::ffff:169.254.169.254` is caught by `169.254.0.0/16`. Private LAN ranges are deliberately allowed; the defaults deny only link-local and cloud-metadata addresses in both families (`169.254.0.0/16`, `fe80::/10`, `fd00:ec2::254/128`) and the unspecified address (`0.0.0.0/8`, `::/128`).
|
||||
|
||||
## REST and MCP
|
||||
|
||||
|
||||
Reference in new issue
Block a user