S6 · size S · part of inbuxa for Kubernetes (tracking issue in inbuxa-charts)
PROXY protocol v2 from MetalLB/HAProxy, and externalTrafficPolicy: Local, on 25, 465, 587, 143, 993, 110, 995 and 4190.
Done when
The server logs the real client IP on every port, in both modes
Config needed is written up for K-C6
**S6** · size S · part of inbuxa for Kubernetes (tracking issue in inbuxa-charts)
PROXY protocol v2 from MetalLB/HAProxy, and `externalTrafficPolicy: Local`, on 25, 465, 587, 143, 993, 110, 995 and 4190.
**Done when**
- The server logs the real client IP on every port, in both modes
- Config needed is written up for K-C6
jcoffey-dev
added this to the 27.1 milestone 2026-11-18 05:14:37 +00:00
Why the spoof worked. With the Cluster policy, SNAT makes every peer look like a node, so a listener that trusts nodes trusts anyone who can reach the port. Not a server bug: PROXY protocol trusts whatever its trusted peers send.
Rules for the chart (K-C6):
PROXY goes to dedicated listeners (high ports, e.g. 10025), never the plain ones, so in-cluster clients and mode A keep working.
Those listeners' overrideProxyTrustedNetworks = the load balancer's source addresses only (a required value in PROXY mode). Never pod or node ranges; the schema refuses them.
The PROXY Service uses externalTrafficPolicy: Local (so the LB's address is what the pod sees) plus loadBalancerSourceRanges where the platform supports it.
Listener changes take effect on restart, not on reload: the chart rolls the server pods when listener values change.
Also confirmed: the default listener set on a fresh store is 25, 443, 465, 993, 995, 4190, 8080 (no 587, 143 or 110 until added).
**Answer (lab, 2026-11-18): real client IPs work in both modes, and PROXY mode has one rule that must be enforced.**
Setup: kind, MetalLB (L2), one server pod; clients in their own containers on the kind network.
| Test | Server logged `remoteIp` | Result |
|---|---|---|
| A: LoadBalancer `externalTrafficPolicy: Local` → port 25 | 172.19.0.7 (the client) | pass |
| B: client → HAProxy `send-proxy-v2` → LoadBalancer (Cluster policy) → PROXY-only listener 10025 trusting node + pod ranges | 172.19.0.8 (the client) | pass |
| B, no PROXY header, direct to 10025 | refused, `invalid proxy header` | pass |
| **B, forged `PROXY TCP4 203.0.113.66 …` sent directly to 10025** | **203.0.113.66** | **spoofed** |
| B': same but `externalTrafficPolicy: Local` and trusted networks = the load balancer's own address only | through LB: 172.19.0.8; forged direct: header ignored (`500 Invalid command`), logged 172.19.0.8 | pass |
**Why the spoof worked.** With the Cluster policy, SNAT makes every peer look like a node, so a listener that trusts nodes trusts anyone who can reach the port. Not a server bug: PROXY protocol trusts whatever its trusted peers send.
**Rules for the chart (K-C6):**
1. PROXY goes to dedicated listeners (high ports, e.g. 10025), never the plain ones, so in-cluster clients and mode A keep working.
2. Those listeners' `overrideProxyTrustedNetworks` = the load balancer's source addresses only (a required value in PROXY mode). Never pod or node ranges; the schema refuses them.
3. The PROXY Service uses `externalTrafficPolicy: Local` (so the LB's address is what the pod sees) plus `loadBalancerSourceRanges` where the platform supports it.
4. Listener changes take effect on restart, not on reload: the chart rolls the server pods when listener values change.
Also confirmed: the default listener set on a fresh store is 25, 443, 465, 993, 995, 4190, 8080 (no 587, 143 or 110 until added).
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
S6 · size S · part of inbuxa for Kubernetes (tracking issue in inbuxa-charts)
PROXY protocol v2 from MetalLB/HAProxy, and
externalTrafficPolicy: Local, on 25, 465, 587, 143, 993, 110, 995 and 4190.Done when
Folded into the checklist on inbuxa/inbuxa-charts#14 to keep the issue list short. The details stay here; reopen this when work on it starts.
Answer (lab, 2026-11-18): real client IPs work in both modes, and PROXY mode has one rule that must be enforced.
Setup: kind, MetalLB (L2), one server pod; clients in their own containers on the kind network.
remoteIpexternalTrafficPolicy: Local→ port 25send-proxy-v2→ LoadBalancer (Cluster policy) → PROXY-only listener 10025 trusting node + pod rangesinvalid proxy headerPROXY TCP4 203.0.113.66 …sent directly to 10025externalTrafficPolicy: Localand trusted networks = the load balancer's own address only500 Invalid command), logged 172.19.0.8Why the spoof worked. With the Cluster policy, SNAT makes every peer look like a node, so a listener that trusts nodes trusts anyone who can reach the port. Not a server bug: PROXY protocol trusts whatever its trusted peers send.
Rules for the chart (K-C6):
overrideProxyTrustedNetworks= the load balancer's source addresses only (a required value in PROXY mode). Never pod or node ranges; the schema refuses them.externalTrafficPolicy: Local(so the LB's address is what the pod sees) plusloadBalancerSourceRangeswhere the platform supports it.Also confirmed: the default listener set on a fresh store is 25, 443, 465, 993, 995, 4190, 8080 (no 587, 143 or 110 until added).