whatisgithub

What is wp2shell-lab?

47cid/wp2shell-lab — explained in plain English

Analysis updated 2026-05-18

13PythonAudience · researcherComplexity · 4/5Setup · moderate

In one sentence

An educational lab and PoC demonstrating a disclosed WordPress REST API vulnerability (CVE-2026-63030 / CVE-2026-60137) that leads to pre-auth SQL injection.

Mindmap

mindmap
  root((wp2shell-lab))
    What it does
      Vulnerable WP Docker lab
      SQLi exploit PoC
      Writeup of the bug
    Tech stack
      Python
      Docker
      WordPress
      MySQL
    Use cases
      Study disclosed CVE
      Detect the bug
      Extract data via oracle
    Audience
      Security researchers
      WordPress maintainers

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

What do people build with it?

USE CASE 1

Spin up a deliberately vulnerable WordPress instance in Docker to study a disclosed SQL injection vulnerability safely.

USE CASE 2

Run a detection check against a lab target to confirm whether the batch-route confusion bug is present.

USE CASE 3

Extract database contents through the vulnerable REST batch endpoint using fast or blind extraction modes.

USE CASE 4

Study a step-by-step writeup of how two internal WordPress tracking arrays fall out of sync to cause the bug.

What is it built with?

PythonDockerWordPressMySQL

How does it compare?

47cid/wp2shell-lab1lystore/awaekactashui/sjtu-ppt-template-skill
Stars131313
LanguagePythonPythonPython
Setup difficultymoderatemoderatemoderate
Complexity4/52/52/5
Audienceresearchervibe coderresearcher

Figures from each repo's GitHub metadata at analysis time.

How do you get it running?

Difficulty · moderate Time to first run · 30min

Requires Docker to run the vulnerable WordPress lab locally, for educational and authorized testing only.

So what is it?

This repository is an educational proof of concept and practice lab for two related WordPress security vulnerabilities, tracked as CVE-2026-63030 and CVE-2026-60137. Both were discovered by an outside security researcher and have already been fixed in WordPress versions 6.9.5 and 7.0.2, so the project exists to help people study a real, disclosed bug rather than to attack live sites. The underlying issue lives in WordPress's REST API batch endpoint, which lets a single HTTP request bundle several API calls together. A bug in how that endpoint keeps track of which sub request goes to which handler causes the requests to get mismatched, so one sub request can end up processed by the wrong part of WordPress entirely. By nesting these batched requests and exploiting that mismatch twice, an attacker can get a request meant for one part of the API handled by a different part that does not expect it, in a way that lets attacker controlled text flow into a database query without being properly cleaned first. That is a SQL injection: a bug where the database ends up running commands hidden inside what should have been ordinary data. The lab spins up a deliberately vulnerable WordPress site inside Docker so the technique can be studied safely and locally. A companion Python tool lets you detect whether a target is vulnerable, extract data from its database, and, if the database user has the right privileges, even write files to the server as a way of demonstrating how far the bug could be pushed in the worst case. The repository's writeup walks through the bug step by step, from how the two internal tracking lists in WordPress's code drift out of sync, to how that drift is chained twice to reach the vulnerable code path, to the exact line where a check for an array type is bypassed by passing a string instead. The project also documents a faster way to pull data out through the vulnerable endpoint than the usual slow, one bit at a time approach, by reading information back through a response header WordPress normally uses to report result counts. This is aimed at security researchers and WordPress maintainers who want to understand exactly how the vulnerability works, not at anyone looking to attack a site they do not own or have permission to test.

Copy-paste prompts

Prompt 1
Set up the wp2shell-lab Docker environment and explain the vulnerable WordPress REST batch endpoint.
Prompt 2
Walk me through how the array desync in serve_batch_request_v1 leads to SQL injection.
Prompt 3
Explain the X-WP-Total header oracle technique this repo uses for faster data extraction.
Prompt 4
Help me understand the difference between the fast and blind extraction modes in this exploit tool.

Frequently asked questions

What is wp2shell-lab?

An educational lab and PoC demonstrating a disclosed WordPress REST API vulnerability (CVE-2026-63030 / CVE-2026-60137) that leads to pre-auth SQL injection.

What language is wp2shell-lab written in?

Mainly Python. The stack also includes Python, Docker, WordPress.

How hard is wp2shell-lab to set up?

Setup difficulty is rated moderate, with roughly 30min to a first successful run.

Who is wp2shell-lab for?

Mainly researcher.

Open on GitHub → Ask about another repo

This repo across BitVibe Labs

Verify against the repo before relying on details.