Vulnerabilities/

SQL Injection via unsanitized JSON path keys when ignoring/silencing compilation errors or using `Kysely<any>`.

Severity:
High

Description

Kysely through 0.28.11 has a SQL injection vulnerability in JSON path compilation for MySQL and SQLite dialects. The visitJSONPathLeg() function appends user-controlled values from .key() and .at() directly into single-quoted JSON path string literals ('$.key') without escaping single quotes.

Recommendation

Update the kysely package to the latest compatible version. Followings are version details:

References

Related Issues

Tags:
npm
kysely
Anything's wrong? Let us know Last updated on March 20, 2026