trustedproxy
Trustedproxy is a concept referring to a proxy server or set of proxies that are explicitly trusted by an origin system to forward client requests and convey client identity information. In modern web architectures, trusted proxies are usually reverse proxies, load balancers, or content delivery networks positioned between clients and application servers. They terminate client connections, perform tasks such as TLS termination, request routing, caching, and authentication, and attach metadata such as the client IP to requests, typically via headers like X-Forwarded-For or X-Real-IP. The receiving application must be configured to trust only these proxies to avoid header spoofing.
Configuration and operation: Operators maintain an allowlist of trusted proxy IP addresses or networks. Applications and
Security and reliability: The trust boundary rests on the integrity of the proxy layer. Compromising a trusted
Examples and implementations: Common trusted proxies include Nginx and HAProxy, as well as CDNs and cloud load