Skip to main content

MariaDB Server EUVDEUVD-2026-102940

| CVE-2026-85746 CRITICAL
Out-of-bounds Write (CWE-787)
2026-10-16 GitHub_M
9.9
CVSS 3.1 · Vendor: GitHub_M
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Authenticate as low-privileged DB user
  2. Delivery
    Submit crafted nested GeometryCollection WKB
  3. Exploit
    Call ST_AsText triggering under-reserved WKT serializer
  4. Execution
    Write past allocated output buffer
  5. Impact
    Corrupt mariadbd memory for crash or potential RCE

Vulnerability Assessment

Weakness
CWE
ASVS 5.0
V15 - Secure Coding and Architecture Bounds checking, write limits
MITRE ATT&CK

2 techniques across 2 tactics: Execution, Privilege Escalation

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Exploitation Conditions

Exploitation requires an authenticated database session (CVSS PR:L) with the ability to execute SQL that invokes the ST_AsText/AsText spatial function on attacker-controlled WKB geometry data forming a deeply nested GeometryCollection (the public PoC nests ~200 levels via repeat(x'010700000001000000', 200)). Affected builds are MariaDB 10.6.1 up to the listed fixed versions. Limiting factors: it is NOT remote-unauthenticated - the attacker needs valid low-privilege credentials or an application SQL-injection path into a spatial query; the input must reach the GIS WKT serialization code path; and full remote code execution is not standalone, explicitly requiring combination with another vulnerability, so the reliable standalone outcome is memory corruption / denial of service.

Impact

Signals are mixed and must be read carefully. The input CVSS of 9.9 (CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H) is vendor/NVD-supplied and rates this at the top of the scale, driven largely by the Scope:Changed flag and assumed full C/I/A impact. However, the description itself qualifies the worst outcome: the bug is an out-of-bounds write (CWE-787) during recursive WKT serialization that corrupts memory, and code execution is only 'potentially' achievable 'when combined with another vulnerability.' Standalone, the reliably-demonstrated effect is memory corruption / server crash (denial of service), as shown by the public regression test that trips the Binary_string::qs_append assertion. PR:L is an important limiter: exploitation requires an authenticated, even if low-privileged, database session able to execute SQL invoking ST_AsText/AsText - this is not remote-unauthenticated. No EPSS score and no CISA KEV entry were provided, so there is no evidence of active or widespread exploitation; the exploitation signal here is a public proof-of-trigger embedded in the fix commit, not a weaponized RCE. I also dispute the Scope:Changed metric - the OOB write corrupts the mariadbd process's own memory within the same security authority, which argues for S:U and a lower real-world base score. Net: a genuinely serious memory-safety bug in a ubiquitous database worth prompt patching, but the headline 9.9 overstates standalone impact; realistic near-term risk is authenticated DoS, with RCE contingent on chaining. Verify the S:C choice and the RCE assumption against the MariaDB advisory.

Exploit ScenarioDerived

A low-privileged but authenticated database user (or an attacker who has gained such credentials, or a web application with SQL-injection into a spatial query path) submits a crafted WKB blob representing a deeply nested GeometryCollection and calls ST_AsText/AsText on it, as demonstrated by the public reproducer select astext(concat(x'00000000', repeat(x'010700000001000000', 200), ...)). Because the recursive WKT serializer under-reserves buffer space, the server writes past the allocated output buffer, corrupting heap memory and crashing or destabilizing mariadbd. A public trigger exists in the fix commit's regression test; achieving code execution rather than a crash would require chaining with an additional primitive.

Act Now Prioritize within 24-48h. Why: CRITICAL severity.
Patch available

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Oct 16, 2026

An out-of-bounds write in MariaDB Server's spatial WKT serialization allows an authenticated, low-privileged database user who can execute SQL against a GIS function to corrupt server memory by supplying a deeply nested GeometryCollection to ST_AsText/AsText. Affected builds are MariaDB 10.6.1 through the fixed releases 10.6.28, 10.11.19, 11.4.13, 11.8.9, 12.3.3 and 13.0.2; the assessed vector is CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H (the published score of 9.9 assumes a scope change that the independent assessment does not confirm). There is no confirmation of active exploitation (the issue is not in CISA KEV), but the upstream fix commit contains a public regression test that reproduces the crash and constitutes a working proof-of-concept; the reliable standalone outcome is memory corruption and denial of service, with code execution only achievable in combination with a second vulnerability.

RemediationAI

Vendor-released patch: upgrade to MariaDB 10.6.28, 10.11.19, 11.4.13, 11.8.9, 12.3.3 or 13.0.2 (the branch-appropriate fixed build) or apply the upstream fix commit 5c04ca5524385356ff7cf84974a7d491974c1f85, which changes qs_append(')')/qs_append('(') to append(')')/append('(') in Geometry::as_wkt() and Gis_geometry_collection::get_data_as_wkt(); see the advisory at https://github.com/MariaDB/server/security/advisories/GHSA-8fvj-c57c-pggx and MDEV-40329 at https://jira.mariadb.org/browse/MDEV-40329. Because exploitation requires an authenticated session able to invoke the GIS functions, the most effective short-term compensating controls are: (1) review and reduce database privileges so untrusted accounts cannot execute spatial conversion functions such as ST_AsText/AsText on attacker-supplied geometry - this is a real mitigation but it breaks legitimate GIS reporting for those accounts; (2) validate and reject application input before it reaches the database, enforcing a maximum nesting depth for GEOMETRYCOLLECTION structures and normalizing or re-encoding WKB from untrusted sources rather than passing it through verbatim, which prevents the deep-recursion trigger but requires a code change in every affected integration; (3) restrict network reachability of the MariaDB listener to trusted application hosts and remediate any SQL-injection entry points that would let a low-privileged or anonymous user influence a spatial query, understanding that this only raises the bar and does not fix the underlying memory-safety bug. Since code execution is not standalone and requires combination with a second flaw, patching remains the only definitive remedy; monitor the fixed branches for follow-up releases.

Affected VersionsENISA

Server 10.6.1, < 10.6.28
Server 13.0.1, < 13.0.2
Server 11.8.1, < 11.8.9
Server 10.11.1, < 10.11.19
Server 11.4.1, < 11.4.13
Server 12.3.1, < 12.3.3

Affected Packages

euvd server fix: 10.6.28, 10.11.19, 11.4.13, 11.8.9, 12.3.3, 13.0.2

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in euvd

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

MariaDB's spatial support (sql/spatial.cc) serializes internal geometry objects to Well-Known Text (WKT) via Geometry::as_wkt() and Gis_geometry_collection::get_data_as_wkt(), which recursively descend into nested GEOMETRYCOLLECTION members and append characters to a String buffer. When the input is a WKB geometry consisting of ~200 nested GeometryCollections wrapping a POINT, recursion depth causes the buffer-size accounting to diverge: the code used Binary_string::qs_append(')' ) / qs_append('('), which assumes pre-reserved capacity in the String object, while get_data_as_wkt() had already consumed part of that reserved space during recursive serialization. The write therefore runs past the allocated output buffer, matching CWE-787 (out-of-bounds write). The upstream fix (MDEV-40329) replaces qs_append() with append() in Geometry::as_wkt() and both call sites in Gis_geometry_collection::get_data_as_wkt(), so the buffer reallocates correctly instead of assuming untouched reserved space. A single pooled-connection MariaDB backend is enough to hit the vulnerable path; any application that passes attacker-influenced WKB/WKT into ST_AsText, AsText or equivalent spatial conversion functions is exposed.

Know when MariaDB gets its next vulnerability

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (GitHub_M) PRIMARY 9.9 CRITICAL
AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H
vuln.today AI 8.8 HIGH

Authenticated low-priv SQL access (PR:L) over the network (AV:N) with a reliably craftable input (AC:L); OOB write stays within the mariadbd process so S:U, not S:C.

3.1 AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
4.0 AV:N/AC:L/AT:N/PR:L/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N

Primary rating from Vendor (GitHub_M).

CVSS VectorVendor: GitHub_M

Attack Vector
Network
Attack Complexity
Low
Privileges Required
Low
User Interaction
None
Scope
Changed
Confidentiality
High
Integrity
High
Availability
High

Lifecycle Timeline

2
Patch available
Oct 16, 2026 - 18:03 EUVD
CVE Published
Oct 16, 2026 - 16:27 cve.org
CRITICAL 9.9

DescriptionCVE.org

MariaDB server is a community developed fork of MySQL server. From 10.6.1 until 10.6.28, 10.11.19, 11.4.13, 11.8.9, 12.3.3, and 13.0.2, ST_AsText can write beyond an allocated output buffer when converting deeply nested GeometryCollections because recursive WKT serialization does not account for bytes consumed or reserve sufficient space. A low-privileged remote attacker can submit a specially crafted GIS object to corrupt memory and potentially achieve code execution when combined with another vulnerability. This issue is fixed in versions 10.6.28, 10.11.19, 11.4.13, 11.8.9, 12.3.3, and 13.0.2.

Technical POC Analysis

The bug class is CWE-787: out-of-bounds write.

Full technical POC analysis - root cause, step-by-step exploitation and patch breakdown - is part of the Pro and Business plans.

Executive ViewAI

Why It Matters

MariaDB Server is affected by a critical out-of-bounds write in its spatial WKT serialization that any authenticated, low-privileged database user with SQL access to GIS functions can trigger, corrupting server memory and causing denial of service across affected 10.6 through 13.0 builds. Publicly available exploit code exists, so organizations running unpatched MariaDB instances with spatial features exposed to non-privileged database accounts face a realistic risk of database crashes and service disruption, with remote code execution achievable only when chained with a second vulnerability. Because MariaDB frequently sits in production data tiers, leadership should treat this as a high-priority availability and data-integrity risk and drive rapid remediation.

Business Impact: High
Compensating Controls

Apply vendor patch (upgrade to fixed MariaDB releases 10.6.28, 10.11.19, 11.4.13, 11.8.9, 12.3.3, or 13.0.2); where immediate upgrade is not feasible, restrict EXECUTE on GIS/spatial functions such as ST_AsText/AsText to trusted accounts, minimize low-privileged SQL access, and monitor for database crashes and anomalous spatial queries.

Threat Intelligence Overview

Prevalence
High
MariaDB server is a default database across many Linux distros and web stacks
Data Quality
5 sources
Confidence: Medium
EUVD NVD CVE.org Vulnrichment GitHub

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity CRITICAL
CISA KEV No
Public POC No
EPSS N/A
Patch available Yes
Active threat No
Deciding rule
CRITICAL severity
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision
Scheduled
Exploitation
None
System Exposure· derived
Open
Automatable
No
Human Impact
High
Technical Impact
Total

Priority Score

50
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +50
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

A buffer overflow occurs when a program writes more data to a memory buffer than it was allocated to hold, causing the excess data to spill into adjacent memory regions.

Memory corruption occurs when a program writes data beyond the boundaries of allocated memory regions or accesses memory in unintended ways, violating the integrity of the process's address space.

Remote Code Execution represents the critical moment when an attacker successfully runs arbitrary code on a target system without physical access.

CVE-2016-6662 CRITICAL POC
9.8 Sep 20

Oracle MySQL through 5.5.52, 5.6.x through 5.6.33, and 5.7.x through 5.7.15; MariaDB before 5.5.51, 10.0.x before 10.0.2

CVE-2012-5613 MEDIUM POC
6.0 Dec 03

MySQL 5.5.19 and possibly other versions, and MariaDB 5.5.28a and possibly other versions, when configured to assign the

CVE-2014-0195 MEDIUM POC
6.8 Jun 05

The dtls1_reassemble_fragment function in d1_both.c in OpenSSL before 0.9.8za, 1.0.0 before 1.0.0m, and 1.0.1 before 1.0

CVE-2014-0224 HIGH POC
7.4 Jun 05

OpenSSL before 0.9.8za, 1.0.0 before 1.0.0m, and 1.0.1 before 1.0.1h does not properly restrict processing of ChangeCiph

CVE-2012-2122 MEDIUM POC
5.1 Jun 26

sql/password.c in Oracle MySQL 5.1.x before 5.1.63, 5.5.x before 5.5.24, and 5.6.x before 5.6.6, and MariaDB 5.1.x befor

CVE-2012-5612 MEDIUM POC
6.5 Dec 03

Heap-based buffer overflow in Oracle MySQL 5.5.19 and other versions through 5.5.28, and MariaDB 5.5.28a and possibly ot

CVE-2012-5611 MEDIUM POC
6.5 Dec 03

Stack-based buffer overflow in the acl_get function in Oracle MySQL 5.5.19 and other versions through 5.5.28, and 5.1.53

CVE-2014-3470 MEDIUM
4.3 Jun 05

The ssl3_send_client_key_exchange function in s3_clnt.c in OpenSSL before 0.9.8za, 1.0.0 before 1.0.0m, and 1.0.1 before

CVE-2016-6664 HIGH POC
7.0 Dec 13

mysqld_safe in Oracle MySQL through 5.5.51, 5.6.x through 5.6.32, and 5.7.x through 5.7.14; MariaDB; Percona Server befo

CVE-2014-0221 MEDIUM
4.3 Jun 05

The dtls1_get_message_fragment function in d1_both.c in OpenSSL before 0.9.8za, 1.0.0 before 1.0.0m, and 1.0.1 before 1.

CVE-2015-3152 MEDIUM POC
5.9 May 16

Oracle MySQL before 5.7.3, Oracle MySQL Connector/C (aka libmysqlclient) before 6.1.3, and MariaDB before 5.5.44 use the

CVE-2022-0778 HIGH POC
7.5 Mar 15

The BN_mod_sqrt() function, which computes a modular square root, contains a bug that can cause it to loop forever for n

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy