docs(config): record the hop-count residual, and pin it with a test #35
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "docs-hops-residual"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Found by Codex against
carddav-mcp's diff. Applies identically there, tojmap-mcpand towebmail, because the residual is in the topology rather than in any implementation.The residual
A caller reaching the Cilium gateway directly, bypassing the edge, supplies its own
X-Forwarded-For. Envoy appends the caller's address, so the chain is two long,len < hopsnever fires, and two hops selects the string the caller wrote.No single hop count is correct for both paths. The edge path wants 2, the direct path wants 1, so choosing either forges one of them. The mitigation is that only one path is supposed to exist, which is a fact about the cluster that nothing in this repository can assert, and the constant now says that rather than implying the value is safe on its own merits.
The 109-request measurement could not see it. It measured the path a real client takes, which is the only path a real client takes. The residual is the one it cannot reach, and that belongs beside the number rather than leaving the number to read as complete.
What I measured, and it does not settle the mitigation
One vantage, one moment. A single failure cannot separate filtered from unrouted from not-listening-on-this-path, and an HTTPS-upgrading fetcher cannot probe it from off-net at all, because there is no TLS listener to reach. The addresses being public shifts the burden; it does not discharge it. The measurement Clark was asked for is still the one that answers this.
The test
a_direct_caller_bypassing_the_edge_can_forge_the_recorded_addresspins the forged selection so the residual is visible in the code rather than only in a comment, and asserts the same chain resolving differently at one hop, which is what makes "no single value is right" concrete rather than a claim.Gates green: fmt, clippy
-D warnings, 123 + 9 tests. No behaviour change and no release needed.