CVE-2026-85748

MariaDB: Use-after-free with a large number of SYS_REFCURSOR's

Published Oct 16, 2026 CVSS 3.1 · 9.9 Critical EPSS 1.3% KEV · Not listed
Description
MariaDB server is a community developed fork of MySQL server. From 12.3.1 until 12.3.3 and 13.0.2, SYS_REFCURSOR handling is affected because cursor-array reallocation can leave stale references in routine contexts. A low-privileged attacker can open a large number of SYS_REFCURSORs and then fetch one to trigger a use-after-free that can enable remote code execution when combined with another vulnerability. This issue is fixed in versions 12.3.3 and 13.0.2.

Analysis

AI-generated

Technical impact

A use‑after‑free flaw in MariaDB’s SYS_REFCURSOR handling allows a low‑privileged attacker to open a large number of cursors and subsequently fetch one, leaking a stale reference that can be exploited to execute arbitrary code. The vulnerability is identified as CWE‑416 and can lead to remote code execution when combined with another defect. The official description limits the impact to environments running MariaDB server versions where the cursor reallocation logic has not been patched.

Affected Systems

The flaw affects MariaDB Server versions 12.3.1 through 12.3.3 and the 13.0.2 release. Users running these builds are vulnerable; MariaDB releases 12.3.3 and 13.0.2 contain the fix and are not impacted.

Risk and Exploitability

With a CVSS score of 9.9, this vulnerability is classified as critical. The EPSS score is currently unavailable and the defect is not listed in CISA’s KEV catalog, suggesting a low public exploitation likelihood at present. However, the low‑privileged attack vector and potential for remote code execution mean that the risk is high for affected systems. A likely exploitation path involves an attacker with limited database access opening many SYS_REFCURSORs, then fetching a cursor to trigger the use‑after‑free and injecting malicious payloads if another vulnerability is present.

Remediation

No solution or workaround provided in the CVE record.

OpenCVE Recommended Actions

  • Update MariaDB Server to version 12.3.3 or later (or 13.0.2 or newer).
  • Limit database user privileges so that only trusted consumers can open large numbers of SYS_REFCURSORs.
  • Implement monitoring or logging to detect abnormal cursor creation or access patterns and investigate unusual activity.

Generated by OpenCVE AI on October 16, 2026 at 18:22 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories available
History
Type Values Removed Values Added
First Time appeared Mariadb server
Vendors & Products Mariadb server
Type Values Removed Values Added
First Time appeared Mariadb
Mariadb mariadb
CPEs cpe:2.3:a:mariadb:mariadb:*:*:*:*:*:*:*:*
cpe:2.3:a:mariadb:mariadb:13.0.1:*:*:*:*:*:*:*
Vendors & Products Mariadb
Mariadb mariadb
Type Values Removed Values Added
Metrics ssvc

{'options': {'Automatable': 'no', 'Exploitation': 'none', 'Technical Impact': 'total'}, 'version': '2.0.3'}

Type Values Removed Values Added
Description MariaDB server is a community developed fork of MySQL server. From 12.3.1 until 12.3.3 and 13.0.2, SYS_REFCURSOR handling is affected because cursor-array reallocation can leave stale references in routine contexts. A low-privileged attacker can open a large number of SYS_REFCURSORs and then fetch one to trigger a use-after-free that can enable remote code execution when combined with another vulnerability. This issue is fixed in versions 12.3.3 and 13.0.2.
Title MariaDB: Use-after-free with a large number of SYS_REFCURSOR's
Weaknesses CWE-416
References
Metrics cvssV3_1

{'score': 9.9, 'vector': 'CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H'}

Weaknesses

Sources

Status
PUBLISHED
Assigner
GitHub_M
Published
Updated
Oct 16, 2026, 4:54 PM
Reserved
Sep 4, 2026, 2:50 PM
Status
Analyzed
Published
Oct 16, 2026, 5:17 PM
Modified
Oct 20, 2026, 3:32 PM
Severity
Important
Public date
Oct 15, 2026, 12:00 AM