Skip to main content
Press slash or control plus K to focus the search. Use the arrow keys to navigate results and press enter to open a threat.
Reconnecting to live updates…
EPSS 0.4%top 71%

CVE-2026-40164: CWE-328: Use of Weak Hash in jqlang jq

0
High
VulnerabilityCVE-2026-40164cvecve-2026-40164cwe-328cwe-407
Published: 04/13/2026 (04/13/2026, 23:40:12 UTC)
Source: CVE Database V5
Vendor/Project: jqlang
Product: jq

Description

jq is a command-line JSON processor. Before commit 0c7d133c3c7e37c00b6d46b658a02244fdd3c784, jq used MurmurHash3 with a hardcoded, publicly visible seed (0x432A9843) for all JSON object hash table operations, which allowed an attacker to precompute key collisions offline. By supplying a crafted JSON object (~100 KB) where all keys hashed to the same bucket, hash table lookups degraded from O(1) to O(n), turning any jq expression into an O(n²) operation and causing significant CPU exhaustion. This affected common jq use cases such as CI/CD pipelines, web services, and data processing scripts, and was far more practical to exploit than existing heap overflow issues since it required only a small payload. This issue has been patched in commit 0c7d133c3c7e37c00b6d46b658a02244fdd3c784.

CVSS v3.1

Score 7.5high

Attack Vector
Network
Attack Complexity
Low
Privileges Required
None
User Interaction
None
Scope
Unchanged
Confidentiality
None
Integrity
None
Availability
High
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H

AI-Powered Analysis

Machine-generated threat intelligence

AILast updated: 07/15/2026, 13:17:33 UTC

Technical Analysis

Before commit 0c7d133c3c7e37c00b6d46b658a02244fdd3c784, jq used MurmurHash3 with a fixed, publicly known seed (0x432A9843) for all JSON object hash table operations. This allowed attackers to precompute key collisions offline and supply crafted JSON objects (~100 KB) where all keys hash to the same bucket. Consequently, hash table lookups degrade from constant time O(1) to linear time O(n), causing jq expressions to exhibit quadratic O(n²) time complexity and significant CPU exhaustion. This vulnerability affects typical jq usage scenarios including CI/CD pipelines, web services, and data processing scripts. The vulnerability has been patched in the specified commit. Red Hat has published multiple advisories referencing this CVE and providing security updates for affected products including OpenShift Container Platform 4.12.

Potential Impact

An attacker can cause denial of service by supplying a crafted JSON object that triggers hash collisions in jq's hash table implementation, leading to significant CPU exhaustion due to degraded performance from O(1) to O(n) hash lookups and O(n²) overall operation complexity. This impacts availability but does not affect confidentiality or integrity. The vulnerability is rated high severity with a CVSS 3.1 score of 7.5 (AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H).

Mitigation Recommendations

A patch fixing this vulnerability is available in jq as of commit 0c7d133c3c7e37c00b6d46b658a02244fdd3c784. Users should update jq to a version including this commit. Red Hat has released security advisories and updates addressing this issue for their affected products, including OpenShift Container Platform 4.12. Users of Red Hat products should apply these updates promptly. Patch status is confirmed by vendor advisories. No additional mitigations are specified.

Pro Console: star threats, build custom feeds, automate alerts via Slack, email & webhooks.Upgrade to Pro

Technical Details

Data Version
5.2
Assigner Short Name
GitHub_M
Date Reserved
2026-04-09T19:31:56.014Z
Cvss Version
3.1
State
PUBLISHED
Remediation Level
null
Vendor Advisory Urls
[{"url":"https://access.redhat.com/security/cve/CVE-2026-40164","vendor":"Red Hat"},{"url":"https://access.redhat.com/errata/RHSA-2026:26528","vendor":"Red Hat"},{"url":"https://access.redhat.com/errata/RHSA-2026:26542","vendor":"Red Hat"},{"url":"https://access.redhat.com/errata/RHSA-2026:23233","vendor":"Red Hat"},{"url":"https://access.redhat.com/errata/RHSA-2026:25044","vendor":"Red Hat"},{"url":"https://access.redhat.com/errata/RHSA-2026:25181","vendor":"Red Hat"},{"url":"https://access.redhat.com/errata/RHSA-2026:23245","vendor":"Red Hat"},{"url":"https://access.redhat.com/errata/RHSA-2026:16252","vendor":"Red Hat"},{"url":"https://access.redhat.com/errata/RHSA-2026:18048","vendor":"Red Hat"},{"url":"https://access.redhat.com/errata/RHSA-2026:18047","vendor":"Red Hat"},{"url":"https://access.redhat.com/errata/RHSA-2026:18046","vendor":"Red Hat"},{"url":"https://access.redhat.com/errata/RHSA-2026:18045","vendor":"Red Hat"},{"url":"https://access.redhat.com/errata/RHSA-2026:18044","vendor":"Red Hat"},{"url":"https://access.redhat.com/errata/RHSA-2026:18040","vendor":"Red Hat"},{"url":"https://access.redhat.com/errata/RHSA-2026:16692","vendor":"Red Hat"},{"url":"https://access.redhat.com/errata/RHSA-2026:19151","vendor":"Red Hat"},{"url":"https://access.redhat.com/errata/RHSA-2026:18043","vendor":"Red Hat"},{"url":"https://access.redhat.com/errata/RHSA-2026:18042","vendor":"Red Hat"},{"url":"https://access.redhat.com/errata/RHSA-2026:16693","vendor":"Red Hat"},{"url":"https://access.redhat.com/errata/RHSA-2026:19365","vendor":"Red Hat"},{"url":"https://access.redhat.com/errata/RHSA-2026:25096","vendor":"Red Hat"},{"url":"https://access.redhat.com/errata/RHSA-2026:30078","vendor":"Red Hat"},{"url":"https://access.redhat.com/errata/RHSA-2026:30089","vendor":"Red Hat"},{"url":"https://access.redhat.com/errata/RHSA-2026:30088","vendor":"Red Hat"},{"url":"https://access.redhat.com/errata/RHSA-2026:30087","vendor":"Red Hat"},{"url":"https://access.redhat.com/errata/RHSA-2026:8579","vendor":"Red Hat"}]

Threat ID: 69dd83f182d89c981f8ff25a

Added to database: 04/14/2026, 00:01:53 UTC

Last enriched: 07/15/2026, 13:17:33 UTC

Last updated: 07/31/2026, 19:22:58 UTC

Views: 177

Community Reviews

0 reviews

Crowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.

Sort by
Loading community insights…

Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.

Need more coverage?

Upgrade to Pro Console for AI refresh and higher limits.

For incident response and remediation, OffSeq services can help resolve threats faster.

Latest Threats

Breach by OffSeqOFFSEQFRIENDS — 25% OFF

Check if your credentials are on the dark web

Instant breach scanning across billions of leaked records. Free tier available.

Scan now
OffSeq TrainingCredly Certified

Lead Pen Test Professional

Technical5-day eLearningPECB Accredited
View courses