SQL injection in MariaDB Connector/Node.js with NO_BACKSLASH_ESCAPES
Key facts
- Attack vector
- Network
- Privileges required
- None
- User interaction
- None
- Attack complexity
- High
- Impact type
- SQL injection
- Confidentiality · integrity · availability
- None · High · High
- Fix status
- Fixed
Attack profile from CVSS 3.1 · CNA. Fix status from CNA and GitHub. Impact type from CWE-89.
Summary
MariaDB Connector/Node.js before 3.2.5, from 3.3.0 before 3.3.4, from 3.4.0 before 3.4.7, and from 3.5.0-rc.0 before 3.5.4 does not escape quotes correctly when the session uses NO_BACKSLASH_ESCAPES (CWE-89). Text-protocol escaping adds a backslash that is an ordinary character in that mode, so a placeholder value can end the SQL string literal. A remote attacker can inject arbitrary SQL with the application's database privileges.
Written with Claude Haiku 5.5 from the sources below · 2026-11-06
Description from the CNA
MariaDB Connector/Node.js is used to connect applications developed on Node.js to MariaDB and MySQL databases. Prior to 3.2.5, 3.3.4, 3.4.7, and 3.5.4, text-protocol escaping always prefixes quotes with a backslash and does not honor the session's NO_BACKSLASH_ESCAPES mode, including in Connection.escape(). When that mode is enabled, the backslash is an ordinary character, so an attacker-controlled placeholder value can close the SQL string literal and inject arbitrary SQL with the application's database privileges. The vulnerable configuration may be enabled server-wide, through connector initialization options, or with an application-issued SET sql_mode; execute() and batch() use binary protocols and are not affected. This issue is fixed in versions 3.2.5, 3.3.4, 3.4.7, and 3.5.4.
Why it matters now
SSVC decision points
CISA ADP · SSVC 2.0.3
- Exploitation
- None
- Automatable
- No
- Technical impact
- Total
The decision (Track, Attend, Act) also depends on your mission and well-being impact; see CISA's SSVC guide.
Affected products
| Vendor | Product | Affected versions | Fixed in | Status | Source |
|---|---|---|---|---|---|
| MariaDB | mariadb-connector-nodejs | before 3.2.5; 3.3.0 to before 3.3.4; 3.4.0 to before 3.4.7; 3.5.0-rc.0 to before 3.5.4 | 3.2.5, 3.3.4, 3.4.7, 3.5.4 | Patch available | CNA |
| — | mariadb (npm) | before 3.2.5 | 3.2.5 | Patch available | GHSA-r3rv-jm3r-62q2 |
| — | mariadb (npm) | 3.3.0 to before 3.3.4 | 3.3.4 | Patch available | GHSA-r3rv-jm3r-62q2 |
| — | mariadb (npm) | 3.4.0 to before 3.4.7 | 3.4.7 | Patch available | GHSA-r3rv-jm3r-62q2 |
| — | mariadb (npm) | 3.5.0-rc.0 to before 3.5.4 | 3.5.4 | Patch available | GHSA-r3rv-jm3r-62q2 |
- mariadb-connector-nodejs VendorMariaDB Affected before 3.2.5; 3.3.0 to before 3.3.4; 3.4.0 to before 3.4.7; 3.5.0-rc.0 to before 3.5.4 Fixed in 3.2.5, 3.3.4, 3.4.7, 3.5.4 Patch available CNA
- mariadb (npm) Vendor— Affected before 3.2.5 Fixed in 3.2.5 Patch available GHSA-r3rv-jm3r-62q2
- mariadb (npm) Vendor— Affected 3.3.0 to before 3.3.4 Fixed in 3.3.4 Patch available GHSA-r3rv-jm3r-62q2
- mariadb (npm) Vendor— Affected 3.4.0 to before 3.4.7 Fixed in 3.4.7 Patch available GHSA-r3rv-jm3r-62q2
- mariadb (npm) Vendor— Affected 3.5.0-rc.0 to before 3.5.4 Fixed in 3.5.4 Patch available GHSA-r3rv-jm3r-62q2
Remediation
Upgrade mariadb-connector-nodejs to 3.2.5, 3.3.4, 3.4.7, or 3.5.4, matching the release line in use, and upgrade the npm package mariadb to the same fixed version.
Written with Claude Haiku 5.5 from the sources below · 2026-11-06
- Fix · CNA mariadb-connector-nodejs (mariadb-corporation) Fixed in 3.2.5, 3.3.4, 3.4.7, 3.5.4
- Fix · GHSA-r3rv-jm3r-62q2 mariadb (npm) Fixed in 3.2.5 Advisory →
- Fix · GHSA-r3rv-jm3r-62q2 mariadb (npm) Fixed in 3.3.4 Advisory →
- Fix · GHSA-r3rv-jm3r-62q2 mariadb (npm) Fixed in 3.4.7 Advisory →
- Fix · GHSA-r3rv-jm3r-62q2 mariadb (npm) Fixed in 3.5.4 Advisory →
Vendor assessments
Timeline
- 2026-10-09 Threatist record created from CVE-2026-107385
- 2026-10-09 Alias added: GHSA-r3rv-jm3r-62q2
- 2026-10-09 CISA SSVC decision points changed
- 2026-10-09 Priority changed: MEDIUM → LOW
- 2026-11-06 Affected versions changed · Red Hat
- 2026-11-06 CVSS score added · Red Hat
References
Other 12
- https://github.com/mariadb-corporation/mariadb-connector-nodejs/security/advisories/GHSA-r3rv-jm3r-62q2
- https://github.com/mariadb-corporation/mariadb-connector-nodejs/commit/6995c8cf8e51b2ad055de63dcaa4094eebbef5ce
- https://github.com/mariadb-corporation/mariadb-connector-nodejs/commit/7670d90949307e735c0ae148d80b3776478a599d
- https://github.com/mariadb-corporation/mariadb-connector-nodejs/commit/95886df9fa0cca991e2be339caa6c3979be61553
- https://github.com/mariadb-corporation/mariadb-connector-nodejs/commit/e5a9d732d9574177749488336319b73074072779
- https://hackerone.com/reports/3889197
- https://github.com/mariadb-corporation/mariadb-connector-nodejs/releases/tag/3.2.5
- https://github.com/mariadb-corporation/mariadb-connector-nodejs/releases/tag/3.3.4
- https://github.com/mariadb-corporation/mariadb-connector-nodejs/releases/tag/3.4.7
- https://github.com/mariadb-corporation/mariadb-connector-nodejs/releases/tag/3.5.4
- https://jira.mariadb.org/browse/CONJS-368
- https://github.com/mariadb-corporation/mariadb-connector-nodejs
More MariaDB vulnerabilities
- TI-2023-11776 MariaDB v10.5 was discovered to contain a remote code execution (RCE) vulnerability via… CVSS 3.1CRITICAL 9.8
- TI-2016-05707 Oracle MySQL through 5.5.52, 5.6.x through 5.6.33, and 5.7.x through 5.7.15; MariaDB… CVSS 3.0CRITICAL 9.8
- TI-2022-00687 Infinite loop in BN_mod_sqrt() reachable when parsing certificates CVSS 3.1HIGH 7.5
- TI-2014-00217 OpenSSL before 0.9.8za, 1.0.0 before 1.0.0m, and 1.0.1 before 1.0.1h does not properly… CVSS 3.1HIGH 7.4
- TI-2014-00188 The dtls1_reassemble_fragment function in d1_both.c in OpenSSL before 0.9.8za, 1.0.0… CVSS 2.0MEDIUM 6.8
- TI-2018-15259 zlib before 1.2.12 allows memory corruption when deflating (i.e., when compressing) if… CVSS 3.1HIGH 7.5
Sources
- CVE-2026-107385 · CVE Program
- CVE-2026-107385 · NVD
- FIRST EPSS
- GHSA-r3rv-jm3r-62q2 · GitHub Advisory Database · CC BY 4.0
- CVE-2026-107385 · Red Hat security data · CC BY 4.0
This product uses the NVD API but is not endorsed or certified by the NVD. Sources and licences