Skip to content

CVE-2026-39956 jq: Missing runtime type checks for _strindices lead to crash and limited memory disclosure

MediumCVSS 6.1 EPSS 0.18%
Published
Updated
Exploit status
No public exploit known
CISA SSVC
Proof of concept public · automatable: no · technical impact: partial
Technology
UbuntuDebianRed Hat

Description

jq is a command-line JSON processor. Prior to version 1.8.2, the _strindices builtin in jq's src/builtin.c passes its arguments directly to jv_string_indexes() without verifying they are strings, and jv_string_indexes() in src/jv.c relies solely on assert() checks that are stripped in release builds compiled with -DNDEBUG. This allows an attacker to crash jq trivially with input like _strindices(0), and by crafting a numeric value whose IEEE-754 bit pattern maps to a chosen pointer, achieve a controlled pointer dereference and limited memory read/probe primitive. Any deployment that evaluates untrusted jq filters against a release build is vulnerable. This issue has been patched in commit fdf8ef0f0810e3d365cdd5160de43db46f57ed03, which is part of version 1.8.2.

Upgrade path

22 packages: 14 fixed, 8 with no fix yet.

PackageAffectedFixed inStatus
redhat/ansible-automation-platform-26/controller-rhel9(Red Hat ansible_automation_platform 2) All versions No fix listed No fix yet
redhat/ansible-automation-platform-26/hub-rhel9(Red Hat ansible_automation_platform 2) All versions No fix listed No fix yet
redhat/automation-controller(Red Hat ansible_automation_platform 2) All versions No fix listed No fix yet
redhat/jq(Red Hat ceph_storage 4) All versions No fix listed No fix yet
redhat/jq(Red Hat enterprise_linux 10) All versions No fix listed No fix yet
redhat/jq(Red Hat enterprise_linux 8) All versions No fix listed No fix yet
redhat/jq(Red Hat enterprise_linux 9) All versions No fix listed No fix yet
redhat/rhcos(Red Hat openshift 4) All versions No fix listed No fix yet
alpine/jq(Alpine v3.21) < 1.8.2-r0 1.8.2-r0 Fixed
alpine/jq(Alpine v3.22) < 1.8.2-r0 1.8.2-r0 Fixed
alpine/jq(Alpine v3.23) < 1.8.2-r0 1.8.2-r0 Fixed
alpine/jq(Alpine v3.24) < 1.8.2-r0 1.8.2-r0 Fixed
azure linux jq(Azure Linux 3.0) < 1.7.1-5 1.7.1-5 Fixed
cbl-mariner jq(CBL-Mariner 2.0) < 1.6-6 1.6-6 Fixed
debian/jq(Debian 12) < 1.6-2.1+deb12u2; = 1.6-2.1; = 1.6-2.1+deb12u1 1.6-2.1+deb12u2 Fixed
debian/jq(Debian 13) < 1.7.1-6+deb13u2; = 1.7.1-6+deb13u1 1.7.1-6+deb13u2 Fixed
debian/jq(Debian 14) < 1.8.1-5; = 1.8.0-1; = 1.8.1-1; = 1.8.1-2 +2 more 1.8.1-5 Fixed
jqlang jq = < 1.8.2; >= 2026-04-02, < 2026-04-08 2026-04-08 Fixed
redhat/jq-main(Red Hat hummingbird 1) < 1.8.1-3.hum1 1.8.1-3.hum1 Fixed
ubuntu/jq(Ubuntu 22.04) < 1.6-2.1ubuntu3.2 1.6-2.1ubuntu3.2 Fixed
ubuntu/jq(Ubuntu 24.04) < 1.7.1-3ubuntu0.24.04.2 1.7.1-3ubuntu0.24.04.2 Fixed
ubuntu/jq(Ubuntu 26.04) < 1.8.1-4ubuntu2 1.8.1-4ubuntu2 Fixed

Affected products

ProductAffected versionsFixed in
cbl-mariner jq(CBL-Mariner:2.0) < 1.6-6 1.6-6
azure linux jq(Azure Linux:3.0) < 1.7.1-5 1.7.1-5
jqlang jq = < 1.8.2 No fix listed
debian/jq(Debian:12) < 1.6-2.1+deb12u2 1.6-2.1+deb12u2
debian/jq(Debian:12) = 1.6-2.1 No fix listed
debian/jq(Debian:12) = 1.6-2.1+deb12u1 No fix listed
debian/jq(Debian:13) < 1.7.1-6+deb13u2 1.7.1-6+deb13u2
debian/jq(Debian:13) = 1.7.1-6+deb13u1 No fix listed
debian/jq(Debian:14) < 1.8.1-5 1.8.1-5
debian/jq(Debian:14) = 1.8.0-1 No fix listed
debian/jq(Debian:14) = 1.8.1-1 No fix listed
debian/jq(Debian:14) = 1.8.1-2 No fix listed
debian/jq(Debian:14) = 1.8.1-3 No fix listed
debian/jq(Debian:14) = 1.8.1-4 No fix listed
redhat/jq-main(Red Hat:hummingbird:1) < 1.8.1-3.hum1 1.8.1-3.hum1
redhat/ansible-automation-platform-26/controller-rhel9(Red Hat:ansible_automation_platform:2) All versions No fix listed
redhat/ansible-automation-platform-26/hub-rhel9(Red Hat:ansible_automation_platform:2) All versions No fix listed
redhat/automation-controller(Red Hat:ansible_automation_platform:2) All versions No fix listed
redhat/jq(Red Hat:ceph_storage:4) All versions No fix listed
redhat/jq(Red Hat:enterprise_linux:10) All versions No fix listed
redhat/jq(Red Hat:enterprise_linux:8) All versions No fix listed
redhat/jq(Red Hat:enterprise_linux:9) All versions No fix listed
redhat/rhcos(Red Hat:openshift:4) All versions No fix listed
ubuntu/jq(Ubuntu:22.04) < 1.6-2.1ubuntu3.2 1.6-2.1ubuntu3.2
ubuntu/jq(Ubuntu:24.04) < 1.7.1-3ubuntu0.24.04.2 1.7.1-3ubuntu0.24.04.2
Show 6 more
ProductAffected versionsFixed in
ubuntu/jq(Ubuntu:26.04) < 1.8.1-4ubuntu2 1.8.1-4ubuntu2
jqlang jq >= 2026-04-02, < 2026-04-08 2026-04-08
alpine/jq(Alpine:v3.21) < 1.8.2-r0 1.8.2-r0
alpine/jq(Alpine:v3.22) < 1.8.2-r0 1.8.2-r0
alpine/jq(Alpine:v3.23) < 1.8.2-r0 1.8.2-r0
alpine/jq(Alpine:v3.24) < 1.8.2-r0 1.8.2-r0

References