batch-v07h: real client address everywhere, detection and Overview warning, audit.ip (#864, v0.6.331) #881
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "batch-v07h"
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?
Closes #864. Built to the approved mockups and the decisions on #864.
Address plumbing and audit
auth.WithClientAddr, using trusted proxies, read from the right). The request log, audit, detector and API all use it.remote=as the resolved client, and addspeer=when the client came through a proxy.addrfield. It is stamped centrally throughAppendCtx, and a guard test pins every exemption to its exact call. Inbound peering events carry the peer instance's address.audit.ip: full | truncated | offsetting (envCAIRN_AUDIT_IP). It is applied before the event is written and hashed, and only parsed addresses are stored.Detection
States, in priority order:
0/0,::/0, or a private/CGNAT/loopback/ULA range wider than /24 (IPv4) or /64 (IPv6). Wide public ranges such as Cloudflare's are fine..0/.1SNAT signature, the service /16, or the pod /16 (R1). The fix isexternalTrafficPolicy: Local, and the card never suggests trusting a node address.peerPublic, andpodAddressfor an ingress pod (R7).Memory is bounded. The detector logs a WARN on every state change, and the admin bell gets an item that can't be muted. Admin API:
GET /api/v1/admin/client-address.UI (per the mockups)
Chart and docs
service.externalTrafficPolicy: Localby default, with a render test.data-protection-operators.md. It is marked not legal advice and needs a lawyer's review before it goes public.Review
-race, gofmt and web tests (574/574) all pass.