CVE-2026-54658: @hypequery/clickhouse has SQL Injection in parameter escaping that allows arbitrary SQL execution
Hypequery is a TypeScript semantic layer for ClickHouse. Prior to 2.5.1, escapeValue() in packages/clickhouse/src/core/utils.ts did not escape backslashes before single quotes during parameter substitution, allowing attacker controlled query parameters with a trailing backslash to escape the closing quote and inject arbitrary SQL. This issue is fixed in version 2.0.2. Version 2.0.2 fixes string parameters, while version 2.5.1 fixes all known vectors. Upgrading to 2.5.1 or later is the only complete fix. In versions 2.0.2 through 2.5.0, serializing non-scalar parameters with JSON.stringify() before passing them is a workaround for the object/array vector only.
Security readout for executives and security teams
Plain-English summary
A flaw in Hypequery’s ClickHouse parameter handling can let unauthenticated attackers turn crafted application input into unintended database commands. Systems using @hypequery/clickhouse versions below 2.5.1 are affected when attacker-controlled values reach query parameters. Successful abuse could expose, alter, or disrupt ClickHouse data.
Executive priority
Treat as an urgent remediation for internet-facing or untrusted-input applications. Inventory immediately and prioritize upgrading exposed production services to 2.5.1 or later. Systems without attacker-controlled parameter paths remain affected by version but may have lower practical exposure pending confirmation.
Technical view
escapeValue() failed to escape backslashes before single quotes during parameter substitution. A crafted value could escape its quoted context and inject SQL. Version 2.0.2 corrected string parameters, but object and array vectors remained through 2.5.0. Version 2.5.1 addresses all known vectors.
Likely exposure
Exposure depends on application data flow, not merely package presence. Highest risk exists where remote, unauthenticated users can influence parameters passed through vulnerable @hypequery/clickhouse versions. Impact is governed by the permissions and accessible data of the application’s ClickHouse connection.
Exploitation context
The CVSS 3.1 score is 9.8, reflecting remote, low-complexity, unauthenticated exploitation without user interaction and potentially high confidentiality, integrity, and availability impact. The bundle marks this CVE as absent from KEV and provides no evidence of active exploitation.
Researcher notes
This is CWE-89 caused by incorrect string escaping during client-side parameter substitution. Researchers should distinguish the partial 2.0.2 string fix from the comprehensive 2.5.1 fix. The supplied evidence does not identify public exploitation, KEV inclusion, affected deployment counts, or a confirmed proof-of-concept campaign.
Mitigation direction
Upgrade @hypequery/clickhouse to version 2.5.1 or later; this is the only complete fix identified.
Rebuild and redeploy affected applications so production runtimes actually use the upgraded dependency.
For versions 2.0.2–2.5.0, JSON.stringify non-scalar parameters as a temporary object and array workaround.
Restrict untrusted input from reaching vulnerable query paths until the complete upgrade is deployed.
Validation and detection
Inspect manifests, lockfiles, deployed artifacts, and runtime dependency trees for @hypequery/clickhouse versions below 2.5.1.
Generated from the cited source records. This long-tail analysis has not been individually reviewed by a named human.
Potential ATT&CK relevance
Conservative CVE-to-ATT&CK context
These mappings and lookup hints may be relevant to the vulnerability behavior, CWE, affected product, or exposure path. Glexia-inferred context is not an official MITRE, ATT&CK, CWE, or CVE Program mapping.
ATT&CK lookup starting points
Use these exact CWE pages and searches to review the Glexia ATT&CK library from this CVE's weakness and description context.
cwe · medium confidence lookup
CWE-89: Database access and collection lookup
Injection into data stores can inform collection, data access, and exfiltration detection reviews. Open the exact CWE lookup page first, then review the ATT&CK searches from that MITRE weakness context. This is a Glexia lookup hint, not an official ATT&CK mapping.
The CVE wording references database injection or access, so collection and exfiltration review may help. This is a Glexia inferred lookup path, not an official MITRE, ATT&CK, or CVE Program mapping.
These fields come from the CVE record and ADP containers, not from Glexia's Take. They preserve time-varying source decisions such as CISA SSVC, KEV status, CVSS metrics, and provider references.
1CVSS vectors
3Timeline events
1ADP providers
9Source links
SSVC decision data
CISA-ADPCISA Coordinator
Timestamp
Version
2.0.3
Exploitation: noneAutomatable: yesTechnical Impact: total
CVSS vector scores
1 official score
We collect every scored CVSS vector available in the official CNA and ADP containers. When more than one version is present, the table keeps the source vectors side by side instead of collapsing them into the highest score.