CVE-2026-33468
March 26, 2026
Kysely is a type-safe TypeScript SQL query builder. Prior to version 0.28.14, Kysely's "DefaultQueryCompiler.sanitizeStringLiteral()" only escapes single quotes by doubling them ("'" → "''") but does not escape backslashes. When used with the MySQL dialect (where "NO_BACKSLASH_ESCAPES" is OFF by default), an attacker can use a backslash to escape the trailing quote of a string literal, breaking out of the string context and injecting arbitrary SQL. This affects any code path that uses "ImmediateValueTransformer" to inline values — specifically "CreateIndexBuilder.where()" and "CreateViewBuilder.as()". Version 0.28.14 contains a fix.
Affected Packages
kysely (NPM):
Affected version(s) >=0.1.0 <0.28.14Fix Suggestion:
Update to version 0.28.14Related Resources (3)
Do you need more information?
Contact UsCVSS v4
Base Score:
9.2
Attack Vector
NETWORK
Attack Complexity
HIGH
Attack Requirements
NONE
Privileges Required
NONE
User Interaction
NONE
Vulnerable System Confidentiality
HIGH
Vulnerable System Integrity
HIGH
Vulnerable System Availability
HIGH
Subsequent System Confidentiality
NONE
Subsequent System Integrity
NONE
Subsequent System Availability
NONE
CVSS v3
Base Score:
8.1
Attack Vector
NETWORK
Attack Complexity
HIGH
Privileges Required
NONE
User Interaction
NONE
Scope
UNCHANGED
Confidentiality
HIGH
Integrity
HIGH
Availability
HIGH
Weakness Type (CWE)
Improper Neutralization of Special Elements used in an SQL Command ('SQL Injection')
EPSS
Base Score:
0.05