Skip to main content

Drizzle Orm EUVDEUVD-2026-19909

| CVE-2026-39356 HIGH
SQL Injection (CWE-89)
2026-04-07 GitHub_M GHSA-gpj5-g38j-94v9
7.5
CVSS 3.1 · Vendor: GitHub_M
View

Attack ChainAIDerived

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

  1. Access
    Provide attacker-controlled input to sql.identifier()
  2. Exploit
    Embedded delimiter bypasses quote escaping
  3. Execution
    Terminate quoted identifier and inject SQL
  4. Impact
    Extract sensitive database information

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V1 - Encoding and Sanitization Parameterized queries, prepared statements
MITRE ATT&CK

2 techniques across 2 tactics: Initial Access, Persistence

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

Exploitation Conditions

Drizzle ORM versions prior to 0.45.2 and 1.0.0-beta.20. Attacker must pass controlled input to sql.identifier(), .as(), or similar identifier-construction APIs. No authentication or user interaction required; exploitation occurs during query construction if application accepts untrusted input for identifiers.

Impact

Real-world risk is elevated for applications with exploitable code patterns. The CVSS vector (AV:N/AC:L/PR:N/UI:N) indicates network-accessible exploitation with low complexity and no authentication required, making this trivially exploitable if vulnerable code exists. However, exploitability depends entirely on whether the application passes unsanitized user input to identifier construction APIs-many applications use static identifiers or validate input, reducing attack surface. The High confidentiality impact (C:H) with no integrity or availability impact reflects read-only SQL injection potential (SELECT queries), though attacker creativity may enable broader impact depending on database permissions. No EPSS score provided, but GitHub advisory publication increases likelihood of reconnaissance and proof-of-concept development. No KEV listing or confirmed active exploitation. The SSVC decision framework would classify this as medium priority: exploitation status is POC-ready (technical details public), technical impact is significant (database exposure), but automatable exploitation requires specific vulnerable code patterns. Organizations should prioritize if they use Drizzle ORM with dynamic identifier construction from user input.

Exploit ScenarioDerived

An attacker identifies a web application using Drizzle ORM where a search filter allows users to specify a custom column name for sorting results. The application constructs a query using .as(userInput) to create a dynamic alias. The attacker submits payload 'col`; SELECT password FROM users--' which terminates the quoted identifier and injects a UNION-based SQL injection, exfiltrating password hashes from the database. With network accessibility, low attack complexity, and no authentication required per the CVSS vector, exploitation is straightforward once vulnerable code paths are identified through reconnaissance or code review.

This Week Schedule remediation this week. Why: HIGH severity (CVSS 7.0-8.9).
Patch available 0.0% exploitation probability (EPSS)

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

Alert me

AnalysisAIv1 – Apr 07, 2026

SQL injection in Drizzle ORM (TypeScript) allows unauthenticated remote attackers to extract database contents via improperly escaped SQL identifiers in versions prior to 0.45.2 and 1.0.0-beta.20. Applications passing user-controlled input to sql.identifier() or .as() methods are vulnerable to identifier termination and arbitrary SQL injection. CVSS 7.5 (High) with network attack vector and low complexity. EPSS data not available; no public exploit identified at time of analysis, though the GitHub security advisory provides technical details that could enable exploitation.

RemediationAI

Immediately upgrade Drizzle ORM to version 0.45.2 or later for stable releases, or version 1.0.0-beta.20 or later for beta track deployments. Update package.json dependencies and run npm update or yarn upgrade to install the patched version. As an interim mitigation for environments unable to upgrade immediately, implement strict input validation and sanitization before any user-controlled data reaches sql.identifier() or .as() API calls-whitelist allowed identifier names against a known-good set and reject any input containing SQL metacharacters (quotes, backticks, semicolons, dashes). Review application code for all usages of dynamic identifier construction and assess whether untrusted input can reach these code paths. Consider static analysis tooling to identify vulnerable patterns. Consult the GitHub security advisory at https://github.com/drizzle-team/drizzle-orm/security/advisories/GHSA-gpj5-g38j-94v9 for additional technical details and vendor guidance.

Affected VersionsENISA

drizzle-orm 1.0.0-beta.2, < 1.0.0-beta.20
drizzle-orm < 0.45.2

Affected Packages

npm drizzle-orm fix: 0.45.2, 1.0.0-beta.20
euvd drizzle_orm_1_0_0_beta_2 fix: 1.0.0-beta.20

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 2 packages in npm, euvd

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

Technical ContextAI · show details

Drizzle ORM is a TypeScript object-relational mapping library supporting multiple SQL dialects (PostgreSQL, MySQL, SQLite). The vulnerability exists in dialect-specific escapeName() implementations responsible for safely quoting SQL identifiers (table names, column names, aliases). The flaw (CWE-89: SQL Injection) stems from failure to escape embedded identifier delimiters (quotes, backticks) before wrapping identifiers. For example, if an attacker supplies input like 'users`--' to an .as() alias operation, the backtick character terminates the quoted identifier prematurely, allowing subsequent SQL code injection. This affects any application code path where external input flows into sql.identifier() or .as() API calls without prior validation. The CPE identifies drizzle-team:drizzle-orm as the affected product across all versions prior to the fixed releases.

Know when Drizzle Orm 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 7.5 HIGH
AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N

Primary rating from Vendor (GitHub_M) · only source for this CVE.

CVSS VectorVendor: GitHub_M

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

Lifecycle Timeline

2
Patch released
Apr 08, 2026 - 02:30 nvd
Patch available
CVE Published
Apr 07, 2026 - 19:58 nvd
HIGH 7.5

DescriptionCVE.org

Drizzle is a modern TypeScript ORM. Prior to 0.45.2 and 1.0.0-beta.20, Drizzle ORM improperly escaped quoted SQL identifiers in its dialect-specific escapeName() implementations. In affected versions, embedded identifier delimiters were not escaped before the identifier was wrapped in quotes or backticks. As a result, applications that pass attacker-controlled input to APIs that construct SQL identifiers or aliases, such as sql.identifier(), .as(), may allow an attacker to terminate the quoted identifier and inject SQL. This vulnerability is fixed in 0.45.2 and 1.0.0-beta.20.

Executive ViewAI

Why It Matters

Drizzle ORM versions prior to 0.45.2 and 1.0.0-beta.20 contain a critical SQL injection vulnerability in identifier handling that allows unauthenticated attackers to extract sensitive database contents. Organizations using Drizzle ORM in production applications risk unauthorized data exfiltration and potential database compromise if user input flows through sql.identifier() or .as() methods without additional sanitization.

Business Impact: High
Compensating Controls

If upgrade is not immediately feasible: (1) Implement strict input validation and whitelisting on all user inputs before passing to sql.identifier() or .as() methods-allow only alphanumeric characters and underscores; (2) Apply principle of least privilege to database service accounts used by Drizzle ORM applications to restrict data exposure scope; (3) Deploy Web Application Firewall (WAF) rules to detect and block SQL injection patterns in application requests; (4) Monitor database query logs for anomalous identifier patterns and unexpected column/table references. These controls reduce but do not eliminate risk-vendor patch application is mandatory for full remediation.

Threat Intelligence Overview

EPSS Score
0.0%
Top 91% exploitable
Threat Intel
1
1 source
Data Quality
7 sources
Confidence: High
EUVD NVD CVE.org EPSS Vulnrichment GHSA GitHub VulDB

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 HIGH
CISA KEV No
Public POC No
EPSS 0.0%
Patch available Yes
Active threat No
Deciding rule
HIGH severity (CVSS 7.0-8.9)
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
Yes
Human Impact
High
Technical Impact
Partial

Priority Score

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

Attack Technique

SQL injection exploits the way applications construct database queries by mixing user input directly into SQL statements.

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