Skip to main content

Jq CVE-2026-33948

LOW
Improper Input Validation (CWE-20)
2026-04-14 security-advisories@github.com
2.9
CVSS 4.0 · Vendor: github
View

Attack ChainAIDerived

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

  1. Recon
    Craft JSON with valid prefix and NUL byte
  2. Delivery
    Submit to jq validator
  3. Exploit
    jq truncates at NUL, validates prefix only
  4. Install
    Attacker's suffix silently discarded by jq
  5. C2
    Full input forwarded to downstream consumer
  6. Execute
    Consumer processes suffix payload
  7. Impact
    Injection or bypass succeeds

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V2 - Validation and Business Logic Input validation, allowlisting
Impact

CVSS 2.9 is exceptionally low, yet the vulnerability has meaningful real-world impact in specific contexts. The CVSS vector shows attack timing complexity (AT:P), indicating attacks require precise timing or interaction setup, which suppresses severity. However, the vulnerability is deliberately craftable: an attacker can reliably construct malicious input with embedded NUL bytes; timing is not random but deterministic. The VI:L (Integrity, Low) rating reflects that only input validation is bypassed, not direct system compromise. EPSS value of P (Proof-of-Concept) signals that public exploit code exists or is feasible. KEV status is not confirmed in the data, but upstream fix is available (commit 6374ae0bcdfe33a18eb0ae6db28493b1f34a0a5b), indicating developer awareness and remediation readiness. Real-world risk is contingent on deployment pattern: if jq is used as a trust boundary (e.g., validating JSON before passing to a web framework, message queue, or script processor), this is a high-priority issue because it breaks that boundary. If jq is merely reformatting user-controlled JSON for display, risk is minimal. The low CVSS should not dismiss this-it reflects attack complexity, not threat model relevance. Organizations relying on jq for security-critical validation must prioritize patching.

Exploit ScenarioDerived

An attacker submits JSON input containing a valid JSON object (e.g., {"status":"ok"}) followed by an embedded NUL byte (0x00) and arbitrary trailing bytes. A validation service using jq to check the JSON parses the prefix, reports it as valid, and forwards the complete untouched input (with the suffix intact) to a downstream processor such as a web framework or logging system. If that processor handles NUL bytes differently (e.g., a C-based JSON parser without NUL-aware length validation), the attacker's trailing payload may be processed as additional JSON fields, JavaScript code injection, or command injection depending on the downstream consumer's interpretation.

Monitor Track and reassess. Why: LOW severity (CVSS 0.1-3.9).
Patch available 0.1% exploitation probability (EPSS)

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

Alert me

AnalysisAIv1 – Apr 14, 2026

Input validation bypass in jq command-line JSON processor allows attackers to craft JSON with embedded NUL bytes that jq incorrectly truncates, validating only a benign prefix while silently discarding malicious trailing data. Versions before commit 6374ae0bcdfe33a18eb0ae6db28493b1f34a0a5b are affected; the vulnerability enables parser differential attacks where jq validates hostile input as safe JSON, but downstream consumers process the complete input including injected payloads. With low CVSS (2.9) and attack timing complexity, exploitation risk remains moderate in scenarios where jq serves as a validation gate for untrusted JSON forwarded to other processors.

RemediationAI

Update jq to a version incorporating commit 6374ae0bcdfe33a18eb0ae6db28493b1f34a0a5b or later. For Linux distributions, use your package manager (apt, yum, brew, etc.) to upgrade to the latest available jq release; most distributions have already patched this in recent versions. For users building from source, clone the jq repository and build from the main branch or any release tagged after the fix commit. Interim mitigation for systems unable to patch immediately: pre-filter untrusted JSON input using a binary-safe parser or octet-stream validator (e.g., a Python script using json.loads with proper byte handling) before passing to jq, thereby avoiding reliance on jq as a sole validation gate. Detailed patching guidance is available at https://github.com/jqlang/jq/security/advisories/GHSA-32cx-cvvh-2wj9.

Affects your stack

Find out whether the stacks and servers you run are on an affected version.

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

Technical ContextAI · show details

jq implements JSON parsing by reading input via fgets() into a buffer, then calculating the string length using strlen(), which terminates at the first NUL byte (0x00 character). This causes a length mismatch: fgets() may fill the buffer with N bytes of actual data, but strlen() reports only the count before the first NUL, artificially truncating the logical input. The root cause is improper input length handling (CWE-20: Improper Input Validation) combined with a classic buffer handling error where length calculation ignores embedded NUL bytes. Attackers exploit this by supplying input structured as valid_json\x00malicious_data-jq parses and validates only the benign prefix, then discards the suffix without error, while a parser that respects the full octet stream (e.g., one reading from a file descriptor or memory without relying on strlen()) will process both parts. This is a parser differential vulnerability stemming from how C's str-based APIs (strlen) conflict with true binary-safe I/O semantics.

Know when Jq 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) PRIMARY 2.9 LOW
CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:N/VI:L/VA:N/SC:N/SI:N/SA:N/E:P

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

CVSS VectorVendor: github

Attack Vector
Network
Attack Complexity
Low
Attack Requirements
Present
Privileges Required
None
User Interaction
None
Vulnerable system: Confidentiality
None
Vulnerable system: Integrity
Low
Vulnerable system: Availability
None
Subsequent system: Confidentiality
None
Subsequent system: Integrity
None
Subsequent system: Availability
None

Lifecycle Timeline

2
Patch released
Apr 24, 2026 - 00:16 nvd
Patch available
CVE Published
Apr 14, 2026 - 00:16 nvd
LOW 2.9

DescriptionCVE.org

jq is a command-line JSON processor. Commits before 6374ae0bcdfe33a18eb0ae6db28493b1f34a0a5b contain a vulnerability where CLI input parsing allows validation bypass via embedded NUL bytes. When reading JSON from files or stdin, jq uses strlen() to determine buffer length instead of the actual byte count from fgets(), causing it to truncate input at the first NUL byte and parse only the preceding prefix. This enables an attacker to craft input with a benign JSON prefix before a NUL byte followed by malicious trailing data, where jq validates only the prefix as valid JSON while silently discarding the suffix. Workflows relying on jq to validate untrusted JSON before forwarding it to downstream consumers are susceptible to parser differential attacks, as those consumers may process the full input including the malicious trailing bytes. This issue has been patched by commit 6374ae0bcdfe33a18eb0ae6db28493b1f34a0a5b.

Threat Intelligence Overview

EPSS Score
0.1%
Top 73% exploitable
Data Quality
6 sources
Confidence: High
NVD CVE.org EPSS Vulnrichment 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 LOW
CISA KEV No
Public POC No
EPSS 0.1%
Patch available Yes
Active threat No
Deciding rule
LOW severity (CVSS 0.1-3.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· derived
Scheduled
Exploitation
Poc
System Exposure· derived
Open
Automatable
No
Human Impact· derived
Low
Technical Impact
Partial

Priority Score

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

Attack Technique

Authentication bypass attacks exploit flaws in the verification mechanisms that control access to systems and applications.

Affected Products (CPE)CVE.org

cpe:2.3:a:jqlang:jq:*:*:*:*:*:*:*:*

Related Vulnerabilities in jq JSON Processor Vulnerabilities

View all 2

More in Jq

View all
CVE-2024-53427 HIGH POC
8.1 Feb 26

decNumberCopy in decNumber.c in jq through 1.7.1 does not properly consider that NaN is interpreted as numeric, which ha

CVE-2015-8863 CRITICAL
9.8 May 06

Off-by-one error in the tokenadd function in jv_parse.c in jq allows remote attackers to cause a denial of service (cras

CVE-2025-48060 HIGH POC
7.7 May 21

jq is a command-line JSON processor. Rated high severity (CVSS 7.7), this vulnerability is remotely exploitable, no auth

CVE-2016-4074 HIGH POC
7.5 May 06

The jv_dump_term function in jq 1.5 allows remote attackers to cause a denial of service (stack consumption and applicat

CVE-2023-49355 HIGH POC
7.5 Dec 11

decToString in decNumber/decNumber.c in jq 88f01a7 has a one-byte out-of-bounds write via the " []-1.2e-1111111111" inpu

CVE-2023-50268 MEDIUM POC
5.5 Dec 13

jq is a command-line JSON processor. Rated medium severity (CVSS 5.5), this vulnerability is low attack complexity. Publ

CVE-2023-50246 MEDIUM POC
5.5 Dec 13

jq is a command-line JSON processor. Rated medium severity (CVSS 5.5), this vulnerability is low attack complexity. Publ

CVE-2026-32316 HIGH
7.5 Apr 13

A heap-based buffer overflow in jqlang/jq through version 1.8.1 allows remote, unauthenticated attackers to crash - and

CVE-2026-49839 HIGH
7.1

Out-of-bounds write in the jq command-line JSON processor (CWE-787) lets a crafted JSON input corrupt memory when parsed

CVE-2026-54679 MEDIUM
6.9

jq, the command-line JSON processor, was patched in Alpine Linux with package version 1.8.2-r0. The specific vulnerabili

CVE-2026-39979 MEDIUM
6.9 Apr 13

Out-of-bounds read in libjq's jv_parse_sized() API exposes any embedding application to memory disclosure or process ter

CVE-2026-47770 MEDIUM
6.8

jq on Alpine Linux was patched in package version 1.8.2-r0, addressing an unspecified vulnerability. The nature of the f

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