crud-query-parser SQL Injection vulnerability
Impact
Improper neutralization of the order/sort parameter in the TypeORM adapter, which allows SQL injection.
You are impacted by this vulnerability if you are using the TypeORM adapter, ordering is enabled and you have not set-up a property filter.
Versions 0.0.1, 0.0.2 and 0.0.3 are affected by this vulnerability.
Patches
This vulnerability has been fixed in version 0.1.0 and newer, which introduces TypeORM field validation (enabled by default).
Workarounds
Add an allowlist of fields
List all valid fields and use the filterProperties function to filter out invalid fields before passing the crudRequest to the TypeOrmQueryAdapter. Here's an example:
crudRequest = filterProperties(crudRequest, ['id', 'title', 'category.name']);
Disable ordering
Cleanup the order field just before passing it to the TypeOrmQueryAdapter. Here's an example:
crudRequest.order = [];
Affected software
Click a technology to see all vulnerabilities affecting it.
| Platform | Package | Vulnerable versions | Fixed in |
|---|---|---|---|
| npm package | crud-query-parser | < 0.1.0 | 0.1.0 |
References
- CVSS vector
CVSS:4.0/AV:A/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:N/SC:N/SI:N/SA:N- Weakness (CWE)
CWE-89- Platform
- npm
- Package
crud-query-parser- Disclosed
- 09.04.2025
- Updated
- 11.10.2026 10:22
Sources and licenses
OSV / GitHub Advisory Database - GHSA-9r25-rp3p-h2w4 - CC BY 4.0
Vulnerability history: crud-query-parser
All published vulnerabilities of this package (npm package), newest first. Shows whether this is a one-off slip or a package that needs watching.
This is the only known vulnerability of this package.
Know which vulnerabilities affect your application
With the DockRay integration and software inventory enabled, DockRay checks reported component versions against known vulnerabilities and notifies you about confirmed matches. Coverage depends on the supported technology and available advisory data.