Vulnerability · Published Apr 13, 2026 · Assigned by GitHub_M

CVE-2026-32316jq: Integer overflow in jvp_string_append() allows Heap-based Buffer Overflow

High 8.2

In plain English

A high-severity heap buffer overflow in jq from jqlang. Proof-of-concept exploit code is public. The chance it is exploited in the next 30 days is estimated at 0.8% (higher than 56% of all known vulnerabilities). Fixed versions are available - upgrade the affected package.

Severity (CVSS 3.1)8.2High
Exploit odds (30 days)0.8%top 43.5% of all CVEs
Exploited in the wildNo reportsCISA SSVC: poc
Attack toolingNoneno public tooling known

Official description

jq is a command-line JSON processor. An integer overflow vulnerability exists through version 1.8.1 within the jvp_string_append() and jvp_string_copy_replace_bad functions, where concatenating strings with a combined length exceeding 2^31 bytes causes a 32-bit unsigned integer overflow in the buffer allocation size calculation, resulting in a drastically undersized heap buffer. Subsequent memory copy operations then write the full string data into this undersized buffer, causing a heap buffer overflow classified as CWE-190 (Integer Overflow) leading to CWE-122 (Heap-based Buffer Overflow). Any system evaluating untrusted jq queries is affected, as an attacker can crash the process or potentially achieve further exploitation through heap corruption by crafting queries that produce extremely large strings. The root cause is the absence of string size bounds checking, unlike arrays and objects which already have size limits. The issue has been addressed in commit e47e56d226519635768e6aab2f38f0ab037c09e5.

Affected packages & fixed versions

EcosystemPackageFixed inAdvisory
Alpine:v3.22jq1.8.2-r0ALPINE-CVE-2026-32316
Alpine:v3.23jq1.8.2-r0ALPINE-CVE-2026-32316
Alpine:v3.24jq1.8.2-r0ALPINE-CVE-2026-32316
Debian:12jq1.6-2.1+deb12u3DEBIAN-CVE-2026-32316
Debian:13jq1.7.1-6+deb13u3DEBIAN-CVE-2026-32316
Debian:14jq1.8.1-5DEBIAN-CVE-2026-32316
Ubuntu:22.04:LTSjq1.6-2.1ubuntu3.2USN-8202-1
Ubuntu:22.04:LTSjq1.6-2.1ubuntu3.2UBUNTU-CVE-2026-32316
Ubuntu:24.04:LTSjq1.7.1-3ubuntu0.24.04.2USN-8202-1
Ubuntu:24.04:LTSjq1.7.1-3ubuntu0.24.04.2UBUNTU-CVE-2026-32316
Ubuntu:25.10jq1.8.1-3ubuntu1.1UBUNTU-CVE-2026-32316
Ubuntu:25.10jq1.8.1-3ubuntu1.1USN-8202-1
Ubuntu:26.04:LTSjq1.8.1-4ubuntu2UBUNTU-CVE-2026-32316

Affected products (as reported)

VendorProductVersions
jqlang jq < e47e56d226519635768e6aab2f38f0ab037c09e5

Weakness: CWE-122, CWE-190 · Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:H

References