nixos/oauth2-proxy: fix warning condition

This commit is contained in:
K900
2026-05-16 12:52:09 +03:00
parent 4a7f7d6354
commit 2a6a67b8d4
@@ -629,7 +629,7 @@ in
}
];
warnings = lib.mkIf (cfg.reverseProxy -> cfg.trustedProxyIP == [ ]) [
warnings = lib.mkIf (cfg.reverseProxy && cfg.trustedProxyIP == [ ]) [
''
When config.services.oauth2-proxy.reverseProxy is enabled, configure config.services.oauth2-proxy.trustedProxyIP to the IPs or CIDR range(s) of the reverse proxies that are allowed to send X-Forwarded-* headers.
If you leave it unset, OAuth2 Proxy currently trusts all source IPs for backwards compatibility, which means a client that can reach OAuth2 Proxy directly may be able to spoof forwarded headers.