CrowdStrike has published guidance on CVE-2026-123007, dubbed NGINX2Root — a privilege escalation condition affecting NGINX deployments that allows an attacker who has code execution in the context of the NGINX worker process to escalate to root on the underlying host. Given that NGINX fronts a massive share of the internet's web traffic — reverse proxies, ingress controllers, API gateways, load balancers — the blast radius here is significant. A vulnerability that converts "compromised web tier" into "full host compromise" collapses one of the few trust boundaries defenders rely on in DMZ architecture.
The defensive priority is straightforward: identify every NGINX instance in your estate, verify the running version and patch state, and deploy behavioral detections for the exploitation pattern while you patch. This post gives you the detection content and remediation workflow to do exactly that.
Technical Analysis
What's affected
- Product: NGINX (open source and NGINX Plus builds), running on Linux distributions where the NGINX master process runs as root and spawns unprivileged worker processes (typically as
nginxorwww-data) — which is the default and near-universal deployment model. - Exposure condition: Any environment where an attacker can achieve code execution inside the worker process context — most commonly by chaining a separate web-facing bug (file upload, RCE in an upstream app, or a compromised reverse-proxied application) with this privilege escalation primitive.
The reason this matters operationally: on its own, a worker-context compromise should be a low-severity event — the worker user owns nothing sensitive. NGINX2Root breaks that assumption. Post-exploitation, the attacker holds root, which means persistence, credential theft from memory and disk, kernel-level evasion, and lateral movement from your DMZ inward.
How the attack chain looks from a defender's seat
The chain defenders should model is:
- Initial access — attacker lands code execution in the NGINX worker context (via a proxied application vulnerability, malicious module, or misconfiguration).
- Escalation (CVE-2026-123007) — the attacker abuses the trust relationship between the root-owned master process and the unprivileged workers to execute code as root.
- Post-exploitation — persistence (cron, systemd units, authorized_keys, LD_PRELOAD), credential access, and egress.
The critical observation: step 2 and step 3 are highly detectable. The NGINX worker process has an extremely narrow legitimate behavioral profile. It serves HTTP. It should virtually never spawn shells, interpreters, or system utilities, and it should never write to root-owned paths. That gives defenders a high-fidelity detection surface.
Exploitation status
This vulnerability is the subject of active vendor guidance (CrowdStrike), which is a strong signal that exploitation or credible weaponization risk exists. Treat this as patch-now priority for any internet-facing NGINX instance. Cross-check CISA's Known Exploited Vulnerabilities catalog for CVE-2026-123007 — if listed, federal civilian agencies face a Binding Operational Directive deadline, and private-sector teams should treat that date as their own ceiling.
Detection & Response
The detections below target the behavioral exploitation pattern, not a single file hash — that's what survives attacker adaptation.
Sigma Rules
---
title: NGINX Worker Process Spawning Shell or Interpreter
id: 1f7c2a94-3b6e-4d81-9c25-7a8f0e2b3d41
status: experimental
description: Detects NGINX worker processes spawning shells, interpreters, or system utilities - consistent with post-exploitation activity following compromise of the worker context, including CVE-2026-123007 (NGINX2Root) privilege escalation chains.
references:
- https://www.crowdstrike.com/en-us/blog/crowdstrike-helps-protect-against-nginx2root-cve-2026-123007/
- https://attack.mitre.org/techniques/T1059/
author: Security Arsenal
date: 2026/04/06
tags:
- attack.execution
- attack.t1059
- attack.privilege_escalation
logsource:
category: process_creation
product: linux
detection:
selection_parent:
ParentImage|endswith:
- '/nginx'
selection_child_img:
Image|endswith:
- '/sh'
- '/bash'
- '/dash'
- '/zsh'
- '/python'
- '/python3'
- '/perl'
- '/php'
- '/curl'
- '/wget'
- '/nc'
- '/ncat'
- '/socat'
- '/chmod'
- '/chown'
- '/useradd'
- '/usermod'
condition: selection_parent and selection_child_img
falsepositives:
- Custom NGINX modules or orchestration wrappers that legitimately invoke scripts (rare - investigate any hit)
level: high
---
title: Root-Level File Writes by Web Server User Context
id: 4e9d1b58-2c7a-4f93-b836-0d5e9a1c7f62
status: experimental
description: Detects writes to sensitive root-owned paths (cron directories, SSH authorized_keys, systemd units) originating from web-facing service accounts such as nginx or www-data, indicative of successful privilege escalation to root followed by persistence, as seen in CVE-2026-123007 (NGINX2Root) exploitation chains.
references:
- https://www.crowdstrike.com/en-us/blog/crowdstrike-helps-protect-against-nginx2root-cve-2026-123007/
- https://attack.mitre.org/techniques/T1053/003/
- https://attack.mitre.org/techniques/T1098/004/
author: Security Arsenal
date: 2026/04/06
tags:
- attack.persistence
- attack.t1053.003
- attack.t1098.004
- attack.t1543.002
logsource:
category: file_event
product: linux
detection:
selection_path:
TargetFilename|startswith:
- '/etc/cron.d/'
- '/etc/cron.daily/'
- '/etc/cron.hourly/'
- '/root/.ssh/'
- '/etc/systemd/system/'
- '/etc/sudoers.d/'
- '/etc/ld.so.preload'
selection_user:
User:
- 'root'
filter_legit:
Image|endswith:
- '/apt'
- '/apt-get'
- '/dpkg'
- '/yum'
- '/dnf'
- '/rpm'
- '/puppet'
- '/ansible-playbook'
condition: selection_path and selection_user and not filter_legit
falsepositives:
- Configuration management runs outside the filtered tool paths
- Manual administrator activity via sudo (verify via shell session correlation)
level: high
---
title: Setuid Bit Set on Binary Outside Standard Locations
id: 8c2f6e17-9a4d-4b58-ae71-3f0d8c6b2a95
status: experimental
description: Detects chmod setting the setuid bit on files in temporary or web-accessible directories, a common root-persistence artifact following privilege escalation such as CVE-2026-123007 (NGINX2Root).
references:
- https://www.crowdstrike.com/en-us/blog/crowdstrike-helps-protect-against-nginx2root-cve-2026-123007/
- https://attack.mitre.org/techniques/T1548/001/
author: Security Arsenal
date: 2026/04/06
tags:
- attack.persistence
- attack.privilege_escalation
- attack.t1548.001
logsource:
category: process_creation
product: linux
detection:
selection:
Image|endswith: '/chmod'
CommandLine|contains:
- 'u+s'
- '4755'
- '4777'
- '6755'
selection_path:
CommandLine|contains:
- '/tmp/'
- '/var/tmp/'
- '/dev/shm/'
- '/var/www/'
- '/usr/share/nginx/'
condition: selection and selection_path
falsepositives:
- Extremely rare in production; treat every hit as investigation-worthy
level: critical
KQL (Microsoft Sentinel / Defender)
Hunt for NGINX workers spawning unexpected child processes across your Linux fleet (via Syslog/CEF ingestion or Defender for Endpoint on Linux), plus sensitive-path file modifications:
let SuspiciousChildren = dynamic(["/bin/sh", "/bin/bash", "/usr/bin/python3", "/usr/bin/curl", "/usr/bin/wget", "/usr/bin/nc", "/usr/bin/chmod", "/usr/sbin/useradd"]);
union isfuzzy=true
(DeviceProcessEvents
| where InitiatingProcessFileName =~ "nginx"
| where FileName in~ ("sh", "bash", "dash", "python", "python3", "perl", "curl", "wget", "nc", "ncat", "chmod", "chown", "useradd")
| project TimeGenerated=TimeGenerated, DeviceName, AccountName=InitiatingProcessAccountName, ParentProcess=InitiatingProcessFileName, FileName, ProcessCommandLine, FolderPath, Source="MDE"),
(Syslog
| where Facility == "user" and SeverityLevel != "debug"
| where SyslogMessage has "nginx" and SyslogMessage has_any ("bash", "/bin/sh", "chmod u+s", "useradd", "authorized_keys", "cron.d")
| project TimeGenerated, DeviceName=HostName, AccountName=HostIP, ParentProcess="nginx", FileName=ProcessName, ProcessCommandLine=SyslogMessage, FolderPath="", Source="Syslog")
| summarize FirstSeen=min(TimeGenerated), LastSeen=max(TimeGenerated), Sources=make_set(Source) by DeviceName, ParentProcess, FileName, ProcessCommandLine
| order by LastSeen desc
Velociraptor VQL
Use this artifact to sweep Linux endpoints for NGINX worker anomalies and freshly-created persistence artifacts:
-- NGINX2Root (CVE-2026-123007) hunt: anomalous NGINX children and persistence artifacts
SELECT Pid, Ppid, Name, CommandLine, Exe, Username, CreateTime
FROM pslist()
WHERE Name =~ 'nginx'
OR (Exe =~ '/(sh|bash|python|perl|curl|wget|nc|chmod|useradd)$'
AND CommandLine =~ '/tmp/|/dev/shm|/var/www|authorized_keys|cron\.d|u\\+s')
-- Persistence sweep: recently modified root-owned persistence locations
SELECT FullPath, Mtime, Ctime, Size, Mode
FROM glob(globs=[
'/etc/cron.d/*',
'/etc/systemd/system/*.service',
'/root/.ssh/authorized_keys',
'/etc/sudoers.d/*',
'/etc/ld.so.preload'
])
WHERE Mtime > now() - 604800
ORDER BY Mtime DESC
Remediation and Verification Script
#!/bin/bash
# CVE-2026-123007 (NGINX2Root) - Exposure check and hardening verification
# Run as root on each NGINX host.
echo "=== NGINX Version ==="
nginx -v 2>&1
echo -e "\n=== Running NGINX Processes ==="
ps -eo user,pid,ppid,cmd | grep [n]ginx
echo -e "\n=== NGINX Worker User (must NOT be root) ==="
ps -eo user,cmd | grep 'nginx: worker' | awk '{print $1}' | sort -u
echo -e "\n=== Package Version (verify against vendor advisory for fixed build) ==="
if command -v dpkg &>/dev/null; then
dpkg -l | grep -E 'nginx'
elif command -v rpm &>/dev/null; then
rpm -qa | grep -i nginx
fi
echo -e "\n=== Suspicious child processes of nginx workers (last boot) ==="
for pid in $(pgrep -f 'nginx: worker'); do
children=$(ps --ppid "$pid" -o cmd= 2>/dev/null)
[ -n "$children" ] && echo "Worker $pid children: $children"
done
echo -e "\n=== Recently modified persistence locations (7 days) ==="
find /etc/cron.d /etc/systemd/system /etc/sudoers.d /root/.ssh -type f -mtime -7 2>/dev/null
ls -la /etc/ld.so.preload 2>/dev/null
echo -e "\n=== Setuid binaries in temp/web paths ==="
find /tmp /var/tmp /dev/shm /var/www /usr/share/nginx -perm -4000 -type f 2>/dev/null
echo -e "\n=== Exposed NGINX listeners ==="
ss -tlnp | grep nginx
echo -e "\n[ACTION] Patch NGINX per the CrowdStrike/vendor advisory, then re-run this script."
Remediation
- Inventory first. Enumerate every NGINX instance — including the ones you forgot: Kubernetes ingress controllers, container sidecars, appliance-embedded reverse proxies, and NGINX bundled inside third-party products. Version-check each against the fixed builds listed in the CrowdStrike advisory and your distribution's security tracker. Do not assume your package manager already pulled the fix — verify the running binary.
- Patch internet-facing instances within 24–72 hours. DMZ reverse proxies and ingress tiers are the primary exploitation surface. Internal instances follow on your standard urgent-patching SLA.
- Verify the worker user is unprivileged. Confirm
userdirective innginx.confmaps workers tonginxorwww-data, never root. Any deviation is a misconfiguration that makes this vulnerability far worse. - Apply systemd hardening to the NGINX unit where feasible:
NoNewPrivileges=true,ProtectSystem=strictwith explicitReadWritePathsonly for required directories (logs, pid, temp),ProtectHome=true, andPrivateTmp=true. These constrain what a successful escalation chain can touch even before the patch lands. - Hunt before and after patching. Run the Sigma/KQL/VQL content above retroactively over at least 30 days of telemetry. If you find worker-spawned shells or root-context writes from web paths, you have an incident, not a patching task — pivot to IR: isolate the host, capture memory, and scope lateral movement.
- Monitor CISA KEV for CVE-2026-123007. KEV listing triggers hard federal deadlines and should trigger yours.
- If you run CrowdStrike Falcon, confirm sensor coverage on all NGINX hosts and that Linux prevention policies are enabled — per CrowdStrike's advisory, the Falcon platform provides identification and protection coverage for this threat. Endpoint visibility on Linux web tiers is precisely what turns this from a silent root compromise into a detectable event.
The broader lesson: the worker/master privilege split in NGINX was your safety net. NGINX2Root cuts it. Defense-in-depth — behavioral EDR on Linux, hardened service configuration, and aggressive patch SLAs on edge infrastructure — is what replaces it.
Related Resources
Security Arsenal Penetration Testing Services AlertMonitor Platform Book a SOC Assessment vulnerability-management Intel Hub
Is your security operations ready?
Get a free SOC assessment or see how AlertMonitor cuts through alert noise with automated triage.