{"id":"CVE-2026-108981","published":"2026-10-12T02:27:15Z","modified":"2026-10-14T17:18:00Z","title":"ngx_cache_purge before 3.0.4 can allow file deletion via a symlink attack in certain situations where nginx and a…","vendor":"denji","product":"ngx_cache_purge","tier":"tail","description":{"text":"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.)","provenance":"source","from":"CVE.org"},"cvss":{"score":3.6,"severity":"LOW","version":"3.1","vector":"CVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:U/C:N/I:L/A:L","provenance":"source","from":"CVE.org CNA"},"epss":{"score":0.00138,"percentile":0.01588,"provenance":"source"},"cwes":[{"id":"CWE-61","name":"UNIX Symbolic Link (Symlink) Following"}],"references":[{"url":"https://github.com/nginx-modules/ngx_cache_purge/pull/72","tags":["patch"]},{"url":"https://github.com/nginx-modules/ngx_cache_purge/commit/a6da1352f52a8a02dd6828e88c39ed42fddcee96","tags":["patch"]},{"url":"https://github.com/nginx-modules/ngx_cache_purge/releases/tag/3.0.4","tags":[]}],"priority":{"score":2.8,"factors":[{"name":"EPSS percentile","points":0.32},{"name":"CVSS severity","points":2.52}]},"vendorSlug":"denji","affectedVersions":[{"vendor":"denji","product":"ngx_cache_purge","versions":[">= 2.4.0, <= 2.5.6",">= 3.0.0, < 3.0.4"]}],"solutions":{"items":["Fixed in commit a6da135 (PR #72) on the releases/stable-3.0 branch. 2.4 through 2.5.6 users should upgrade to 3.x, or backport the change to the two ngx_walk_tree() call sites in those versions."],"from":"CVE.org CNA","provenance":"source"},"workarounds":{"items":["Restrict write access to the cache directories and all of their parent directories to the nginx user only, and do not run nginx and untrusted application code (for example PHP-FPM) as the same user. Remove any symbolic links found inside configured cache paths (find <cache_path> -type l). These measures also limit the similar traversal in nginx's own cache loader, which the fix in the module does not change."],"from":"CVE.org CNA","provenance":"source"},"ssvc":{"exploitation":"none","automatable":"no","technicalImpact":"partial","timestamp":"2026-10-14T17:17:47.968041Z","from":"CISA ADP","provenance":"source"},"euvd":{"id":"EUVD-2026-97159","exploited":false,"provenance":"source"}}