Cis Nginx V300 3 4CAUTION
Open-source AI-powered offensive security harness for automated penetration testing.
Overview
Open-source AI-powered offensive security harness for automated penetration testing.
eaf7d03223fcOBSERVED · 2026-10-18What it tells the agent
The instruction file, verbatim from the audited commit — this is the text the model reads, and the surface the audit's instruction layer examines. Quoted here so you can judge it without cloning anything.
---
name: cis-nginx-v300-3-4
description: "Ensure proxies pass source IP information (Manual)"
category: cis-nginx
version: "3.0"
author: cyberstrike-official
tags: [cis, nginx, web-server, reverse-proxy, logging]
cis_id: "3.4"
cis_benchmark: "CIS NGINX Benchmark v3.0.0"
tech_stack: [nginx, linux, web-server]
cwe_ids: []
chains_with: []
prerequisites: []
severity_boost: {}
---
# CIS 3.4 — Ensure proxies pass source IP information
## Profile Applicability
- Level 1 - Proxy
- Level 1 - Loadbalancer
## Description
When NGINX acts as a reverse proxy or load balancer, it terminates the client connection and opens a new connection to the upstream application server. By default, the upstream server sees the NGINX server's internal IP address as the source, obscuring the original client IP. Standard HTTP headers like `X-Forwarded-For` and `X-Real-IP` must be explicitly configured to pass the original client's IP address and protocol information to the backend application.
## Rationale
Visibility of the true client IP address is essential for security auditing, incident response, and access control within the backend application. Without forwarding this information:
1. **Forensics:** Application logs will show all traffic coming from the NGINX proxy IP, making it impossible to trace malicious activity to a specific attacker.
2. **Access Control:** Application-level IP allow/deny lists or rate limits will fail or mistakenly block the entire proxy.
3. **Compliance:** Accurate logging of the user origin is often a regulatory requirement.
## Impact
Enabling these headers allows the backend application to see the original client IP. However, if NGINX simply appends to an existing `X-Forwarded-For` header sent by a malicious client, the backend might be tricked into trusting a spoofed IP at the beginning of the list.
## Audit Procedure
**1. Verify Configuration:**
Check the active configuration for proxy header directives in proxied locations:
```bash
nginx -T 2>/dev/null | grep -E "proxy_set_header (X-Real-IP|X-Forwarded-For)"
```
**Evaluation:**
- **Presence:** Verify that `proxy_set_header X-Forwarded-For` **and** `proxy_set_header X-Real-IP` are present in `location` blocks that use `proxy_pass` (or `grpc_pass`, `fastcgi_pass`).
- **Correctness:**
- `X-Forwarded-For` should typically use `$proxy_add_x_forwarded_for` (to preserve the chain) or `$remote_addr` (if NGINX is the first trusted hop).
- `X-Real-IP` should use `$remote_addr`.
- **Scope:** Check that this is applied to all relevant proxied locations.
## Remediation
Configure NGINX to forward client IP information in your `server` or `location` blocks where `proxy_pass` is used.
**Configuration Example:**
```nginx
location / {
# Use 'https' for Zero Trust environments (requires proxy_ssl_verify configuration)
# Use 'http' for standard TLS offloading (upstream traffic is unencrypted)
proxy_pass <protocol>://example_backend_application;
# Standard header: Appends the client IP to the list of proxies
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
# NGINX-specific header: Sets the direct client IP (useful for apps expecting a single value)
proxy_set_header X-Real-IP $remote_addr;
# Recommended: Forward the protocol (http vs https)
proxy_set_header X-Forwarded-Proto $scheme;
}
```
## Default Value
By default, NGINX does not add these headers. The upstream server receives requests appearing to originate from the NGINX server's IP address.
## References
1. https://developer.mozilla.org/en-US/docs/Web/HTTP/Reference/Headers/X-Forwarded-For
2. https://nginx.org/en/docs/http/ngx_http_proxy_module.html#proxy_set_header
## Additional Information
**Privacy:** Users' privacy should be considered when forwarding client IP addresses. Ensure your organization's privacy policy discloses the collection and processing of IP address information.
**Security Trust:** Any information in the `X-Forwarded-For` header supplied by the client (before reaching your trusted infrastructure) is untrusted and can be easily spoofed. Backend applications and security controls (like rate limiting) must be configured to trust only the IPs appended by your own NGINX instance or known trusted proxies, ignoring the client-supplied part of the chain.
## CIS Controls
| Controls Version | Control | IG 1 | IG 2 | IG 3 |
| ---------------- | ------------------------------ | ---- | ---- | ---- |
| v8 | 8.11 Conduct Audit Log Reviews | N | Y | Y |
| v7 | 6.7 Regularly Review Logs | N | Y | Y |
## MITRE ATT&CK Mappings
| Tactic | Technique |
| ------------------- | ------------------------- |
| Defense Evasion | T1070 - Indicator Removal |
| Command and Control | T1090 - Proxy |
## Profile
- Level 1 - Proxy
- Level 1 - LoadbalancerTrust audit
CAUTIONgrade B · trust 89/100 Install with care. The audit found things worth knowing before you trust its output.
| Layer | What it checks | Result |
|---|---|---|
| L0 | Provenance & inventory | WARN |
| L1 | Static analysis of the code | NA |
| L2 | Instruction surface (what it tells the agent) | PASS |
| L3 | Class-specific surface | PASS |
| L4 | Behavioural (sandbox) | SKIPPED |
What the source does
- Filesystem
- none-observed
- Network
- none-observed
- Shell
- none-observed
- Dependencies
- pinned
- Secrets in source
- none-found
Findings (5)
packages/app/public/apple-touch-icon-v3.png
packages/app/public/apple-touch-icon.png
packages/app/public/favicon-96x96-v3.png
packages/app/public/favicon-96x96.png
packages/app/public/favicon-v3.ico
Gates applied: no_behavioural_pass.
eaf7d03223fcfull audit observations/trust-audit/skill/cyberstrikeus__cis-nginx-v300-3-4.json · Report an issue / request a re-scanAudit history
Every audit this skill has had.
| Date | Source | Verdict | Grade | Score | Change |
|---|---|---|---|---|---|
| 2026-10-18 | eaf7d03223fc | CAUTION | B | 89 | first audit |
Questions
What does the Cis Nginx V300 3 4 skill do?
Open-source AI-powered offensive security harness for automated penetration testing.
Is Cis Nginx V300 3 4 safe to install?
With care. The audit graded it B (89/100) and found 5 things worth knowing before you trust this skill, listed below with the exact line each was found on.
What can Cis Nginx V300 3 4 access on my machine?
The audit observed no filesystem, network or shell use at all in its source.
How current is this page?
The grade is for one exact copy of the source (eaf7d03223fc), read on 2026-10-18. The repository is watched, and a new audit runs when it changes — this is the first audit.
Add this badge to your README
Shows this page's audit result and links back to it. It updates when the audit does.
[](https://modelsatlas.com/skills/cyberstrikeus/cis-nginx-v300-3-4/)
Not your listing, or something out of date? Claim or update your listing.