Symlink following in ngx_cache_purge lets attackers delete files
Key facts
- Attack vector
- Local
- Privileges required
- Low
- User interaction
- None
- Attack complexity
- High
- Impact type
- —
- Confidentiality · integrity · availability
- None · Low · Low
- Fix status
- Fixed
Attack profile from CVSS 3.1 · CNA. Fix status from CNA.
Summary
ngx_cache_purge from 2.4.0 through 2.5.6 and from 3.0.0 before 3.0.4 follows symlinks while walking the cache directory tree during purge operations. Attackers with low privileges who can create a symlink inside the cache path can delete files when nginx and a served application such as WordPress run under the same user account.
Written with Claude Haiku 5.5 from the sources below · 2026-10-29
Description from the CNA
ngx_cache_purge before 3.0.4 can allow file deletion via a symlink attack in certain situations where nginx and a served application (e.g., WordPress) run under the same user account. The attacker must be able to create a symlink inside the cache path. Version 3.0.4 fixes this for the case of a symlink created at an arbitrary earlier time, but does not resolve an applicable TOCTOU race condition. (The ngx_cache_purge module follows symlinks while walking the cache directory tree during purge operations. The module relies on nginx's ngx_walk_tree(), which relies on stat() and therefore follows symlinks.)
Why it matters now
SSVC decision points
CISA ADP · SSVC 2.0.3
- Exploitation
- None
- Automatable
- No
- Technical impact
- Partial
The decision (Track, Attend, Act) also depends on your mission and well-being impact; see CISA's SSVC guide.
Affected products
Remediation
Upgrade ngx_cache_purge to version 3.0.4, which fixes the symlink case for a symlink created at an arbitrary earlier time. The CNA's description states that 3.0.4 does not resolve an applicable TOCTOU race condition.
Written with Claude Haiku 5.5 from the sources below · 2026-10-29
- Fix · CNA ngx_cache_purge (denji) Fixed in 3.0.4
Timeline
- 2026-10-12 Threatist record created from CVE-2026-108981
- 2026-10-12 Alias added: GHSA-5fhq-3m7h-fqv8
- 2026-10-15 CISA SSVC decision points changed
References
Sources
- CVE-2026-108981 · CVE Program
- CVE-2026-108981 · NVD
- FIRST EPSS
- GHSA-5fhq-3m7h-fqv8 · GitHub Advisory Database · CC BY 4.0
This product uses the NVD API but is not endorsed or certified by the NVD. Sources and licences