A proof-of-concept tool that demonstrates an unauthenticated SQL injection and RCE chain in WordPress via a batch route confusion vulnerability.

Stars

613

7-day growth

+120

Forks

143

Open issues

1

License

MIT

Last updated

2026-07-23

AI repository intelligence
FR-AI / ANALYSIS

Why it is worth attention

It provides a full pre-auth to RCE exploit chain, including a novel SQLi-to-admin bridge, with multiple extraction techniques and minimal dependencies.

Who it is for

  • Security researchers analyzing WordPress core vulnerabilities
  • WordPress site administrators needing to assess exposure
  • Penetration testers performing authorized security assessments
  • CTF participants and educational exploit developers

Use cases

  • Check if a WordPress site is vulnerable to the wp2shell SQLi
  • Extract database contents like user hashes or custom queries via SQL injection
  • Execute commands by chaining SQL injection to administrator account creation and plugin upload
  • Demonstrate the full exploit path for training or reporting

Strengths

  • No third-party dependencies (only Python standard library)
  • Supports multiple SQLi techniques (UNION, error-based, blind) with automatic fallback
  • Automates the entire pre-auth to RCE process, including cleanup of generated accounts and shells
  • Includes a non-destructive check mode that uses marker probes without sending an SQLi payload

Considerations

  • Only works on specific vulnerable WordPress versions (6.9.0–6.9.4, 7.0.0–7.0.1)
  • The active SQLi confirmation and shell steps may be blocked by Web Application Firewalls (WAFs)
  • Command execution requires either supplied admin credentials or successful pre-auth bridge, which may fail in hardened environments

README quick start

wp2shell-poc

Independent proof-of-concept for the unauthenticated WordPress REST batch route-confusion SQL injection associated with Searchlight Cyber's wp2shell advisory.

This repository is not Searchlight Cyber's official checker. check confirms the SQLi path, read demonstrates database read, and shell opens a plugin-backed command shell either with supplied administrator credentials or by first exercising the SQLi-to-admin bridge.

Detection / IoCs: Elastic Security Labs and Eye Security published detection guidance and indicators for this chain. See the Elastic write-up and the Eye Security defenders guide.

Affected versions

Searchlight Cyber's advisory lists these wp2shell RCE exposure ranges:

Version rangeStatus
[options]

Or `pip install .` to get a `wp2shell` command on your `PATH`.

### check — non-destructive vulnerability check

Prints passive WordPress markers and public version hints first, then sends a benign batch marker
probe. A vulnerable batch implementation returns HTTP 207 with the route-confusion marker pattern
`parse_path_failed`, `block_cannot_read`, and `rest_batch_not_allowed`.

The marker probe is based on the WordPress core fix. The malformed `///` request creates
`parse_path_failed`; a `/wp/v2/posts` request acts as a batch-allowed spacer; the
`/wp/v2/block-renderer/...` route is not batch-allowed but returns `block_cannot_read` if its
handler is reached anonymously; `/batch/v1` gives `rest_batch_not_allowed`. On vulnerable builds
the parse error shifts the batch handler arrays out of step, so the spacer request is dispatched
under the block-renderer handler. Fixed builds keep the arrays aligned, so this exact all-three
pattern should not appear for the crafted probe.

By default, `check` stops there and does not send an SQLi payload. Use `--confirm-sqli` when you
also want an active SQLi confirmation. The confirmation tries the UNION read primitive first and
falls back to paired timing probes if UNION reflection is unavailable.

The signals are independent: a version hint is only a hint, the marker pattern shows route
confusion, and `--confirm-sqli` shows a payload reached the database. A WAF can block the payload,
so a failed

Description

wp2shell (CVE-2026-63030 & CVE-2026-60137) - full RCE chain

Related repositories

Similar projects matched by category, topics, and programming language.

lopopolo
Featured
lopopolo GitHub avatar

harness-engineering

Harness Engineering is a methodology for improving coding agent outputs by carefully crafting the environment around them—providing curated context, tools, and executable constraints that encode an organization’s nonfunctional requirements and cumulative lessons.

AI & Machine LearningAI Agents
2,390
slvDev
Featured
slvDev GitHub avatar

esp32-ai

A 28.9 million parameter language model runs on an $8 ESP32-S3 microcontroller entirely on-device, generating simple stories at about 9.5 tokens per second.

AI & Machine LearningLarge Language Models
1,960
littledivy
Featured
littledivy GitHub avatar

mimic

mimic captures traffic from any iOS or web app and automatically generates a Python client library that lets you call the app's API like a regular library.

AI & Machine Learning
1,482