Skip to content
KitploitKITPLOIT
ToolsBlog
Log in
Submit
ToolsBlog
Submit

Hacking, PenTest, and Cybersecurity Tools for Your Security Arsenal!

Kitploit is a directory of hacking, cybersecurity, and pentesting tools. Discover the latest project updates to find vulnerabilities, analyze systems, automate testing, and strengthen your security.

FeedsContactPrivacy© 2026 Kitploit

Tool Directory

Categories

View all categories
Loading categories
CVE-2026-72898 — Docker lab reproducing CVE-2026-72898, a Metabase SQL injection via the password-reset API, with vulnerable and patched instances, exploit script, and recovery tooling. | Kitploit
Tools/GitHubGitHub/amier-ge/cve-2026-72898
Vulnerability AnalysisExploitationWeb Application ExploitationPenetration TestingLearning & EducationLabs & Practice
GitHubamier-ge/cve-2026-72898

CVE-2026-72898

Docker lab reproducing CVE-2026-72898, a Metabase SQL injection via the password-reset API, with vulnerable and patched instances, exploit script, and recovery tooling.

View Repository
81 month agoNot yet reviewed
Share

CVE-2026-72898: Metabase SQL Injection Lab

Metabase is an analytics tool that connects to databases to create query results and dashboards. CVE-2026-72898 is a vulnerability that allowed unauthenticated users to inject SQL into the Metabase application DB by adding an unexpected user-id value to the password reset API. The input schema allowed additional fields, the entire request body was passed into the authentication flow, and the raw expression of the SQL generator was interpreted during the user ID lookup process. As a result, it was possible to create an administrator session and access data in the connected DB.

This repository uses only fictitious customer and order data. The vulnerable Metabase v0.63.2 runs on localhost:3001, and the patched version v0.63.18.3 runs on localhost:3002. The two Metabase instances use separate application DBs and share a single fictitious shopping mall analytics DB. The Docker images contain the built Metabase, and the Python files in this folder run on the PC and send HTTP requests.

Prerequisites

  • Docker Desktop's Linux container engine and Docker Compose
  • Python 3.10 or later (exp.py and recover.py use only the standard library)
  • Windows PowerShell
  • An internet connection to download the Docker images on first run

The web ports are bound only to 127.0.0.1. If an existing metabase-lab is running, stop it first. Both configurations use ports 3001 and 3002 on the PC.

1. Run

In PowerShell, navigate to this folder and run it.

.\start.ps1

On first run, start.ps1 creates a random DB password in .env, downloads the images, and starts the containers. .env is included in .gitignore, so do not upload it to GitHub. Metabase may take a few minutes to become ready.

To run only one side, use .\start.ps1 -Mode vulnerable or .\start.ps1 -Mode patched. The comparison exercise below requires both sides to be running.

2. Initial setup for each Metabase

  1. In your browser, open http://localhost:3001/setup and http://localhost:3002/setup and create a separate practice admin account for each.
  2. On both screens, go to Admin settings → Databases → Add a database → PostgreSQL and connect the virtual analytics DB below. The screen labels may differ slightly depending on the version.
ItemInput value
Display nameVirtual shopping mall
Hostanalytics-db
Port5432
Databaseshop_demo
Useranalytics_reader
PasswordThe ANALYTICS_READER_PASSWORD value in this folder's .env

What you connect on this screen is the target DB for analysis. The application DB that stores Metabase accounts and sessions is already connected via the MB_DB_* settings in compose.yaml.

Check the initial state.

.\verify.ps1

Four virtual customers and five orders are expected, with order_105_present=true.

3. Comparing the Vulnerable and Patched Versions

python .\exp.py localhost:3001
.\verify.ps1
python .\exp.py localhost:3002

exp.py accepts only the localhost address of this lab as specified and sends the same password reset request. Because it uses an invalid token, the HTTP 400 on the first request is the expected result on both sides. It then checks whether the admin session can access /api/user/current.

  • 3001: The admin session check succeeds. Through Metabase, it saves the virtual customer and order data as CSV under exports/run-.../ and deletes one row of the virtual order order_id=105 from the connected analytics.orders. In verify.ps1, the order count drops from 5 to 4 and order_105_present=false.
  • 3002: The admin session check fails with HTTP 401. It does not proceed to the CSV save and order deletion steps.

The direct target of the SQL injection is the Metabase application DB. The order deletion is a follow-up action performed by connecting to Metabase with the admin session that was created. To demonstrate this, the analytics DB connection account was intentionally granted only the DELETE privilege on the virtual order table. If the connection account were read-only, this deletion step could not be performed. The password reset request does not directly delete the order table.

4. Recovery and Shutdown

python .\recover.py
.\verify.ps1
docker compose --profile vulnerable --profile patched down

recover.py restores virtual order 105 and cleans up the CSV files created by the lab script. To keep the CSVs, use python .\recover.py --keep-exports. After recovery, 5 orders and order_105_present=true are expected. down preserves the DB volume.

File Structure

FileRole
compose.yamlConfigures the vulnerable and patched Metabase instances, their respective application databases, and the shared virtual analytics database
start.ps1Generates .env passwords and starts Docker Compose
data/01-seed.sh, data/02-seed.sqlInitializes virtual customer and order data, connection accounts, and privileges
exp.pySends the same SQL injection request to both local versions, and on success saves a CSV and deletes order 105
recover.pyRestores and cleans up order 105 and the lab CSVs
verify.ps1Checks container status and virtual data record counts
.gitignoreExcludes local passwords and CSVs so they don't get committed to Git

To see the vulnerable point in the source, compare the v0.63.2 password reset API with the same section in the patched line. The lab's v0.63.18.3 is a Docker image tag, while v0.63.18 in this link is the public source tag.

Download Tool

Most Popular

View all →

Discover the most used tools by our community.

  • 1

    OsintHunter

    letox4/osinthunter

    🎯 The ultimate OSINT toolkit: investigation graph, confidence scoring, alias families, map, timeline and reports. 49 modules, 400+ sites, no API keys required.

    755
  • 2

    ghostlock-app

    yukonga/ghostlock-app

    GhostLock One-Tap Execution App (CVE-2026-43499)

    510
  • 3

    ARTEX

    baarai/artex

    LLM multi-agent autonomous penetration testing platform with planner/worker agents, asset and exploration graphs, MITM traffic recording, and vulnerability retesting.

    415
  • 4

    redforge

    cybersecurity91/redforge

    Browser-side red team toolkit with 102 offline tools for recon, payload generation, credential attacks, crypto, encoding and engagement reporting.

    343
  • 5

    antifox

    antifox-ai/antifox

    AI multi-agent autonomous penetration testing platform that runs recon, attack-surface discovery, exploitation validation and evidence-backed report delivery.

    259
  • 6

    CyberStrikeAI

    ed1s0nz/cyberstrikeai

    The system of action for AI-native cybersecurity—where intent becomes governed execution, evidence becomes operational memory, and every operation improves the next.

    258

Explore all tools

Browse our collection of tools

View all tools →