Логотип exploitDog
Консоль
Логотип exploitDog

exploitDog

redhat логотип

CVE-2026-39979

Опубликовано: 13 апр. 2026
Источник: redhat
CVSS3: 8.2

Описание

jq is a command-line JSON processor. In commits before 2f09060afab23fe9390cce7cb860b10416e1bf5f, the jv_parse_sized() API in libjq accepts a counted buffer with an explicit length parameter, but its error-handling path formats the input buffer using %s in jv_string_fmt(), which reads until a NUL terminator is found rather than respecting the caller-supplied length. This means that when malformed JSON is passed in a non-NUL-terminated buffer, the error construction logic performs an out-of-bounds read past the end of the buffer. The vulnerability is reachable by any libjq consumer calling jv_parse_sized() with untrusted input, and depending on memory layout, can result in memory disclosure or process termination. The issue has been patched in commit 2f09060afab23fe9390cce7cb860b10416e1bf5f.

A flaw was found in jq, a command line JSON processor, specifically in the libjq API. Parsing a malformed JSON input from a non-NUL-terminated buffer using the jv_parse_sized function can cause an out-of-bounds read, resulting in an application crash and a possible memory disclosure within the error message generated by the parser.

Отчет

To exploit this flaw, an attacker needs to supply malformed JSON from a non-NUL-terminated buffer to an application using the jv_parse_sized function. This allows the attacker to trigger the out-of-bounds read, causing an application crash and potentially disclosing memory with no other security impact. As this issue affects the libjq library, it is more likely to be exposed to untrusted input. Due to these reasons, this vulnerability has been rated with an important severity.

Меры по смягчению последствий

To mitigate this issue, manually ensure that every buffer is NUL-terminated before passing it to the 'jv_parse_sized' function.

Затронутые пакеты

ПлатформаПакетСостояниеРекомендацияРелиз
Red Hat Ansible Automation Platform 2ansible-automation-platform-26/controller-rhel9Affected
Red Hat Ansible Automation Platform 2ansible-automation-platform-26/hub-rhel9Not affected
Red Hat Ansible Automation Platform 2automation-controllerNot affected
Red Hat Ceph Storage 4jqFix deferred
Red Hat Enterprise Linux 10jqFixedRHSA-2026:1669213.05.2026
Red Hat Enterprise Linux 10jqFixedRHSA-2026:1915119.05.2026
Red Hat Enterprise Linux 10.0 Extended Update SupportjqFixedRHSA-2026:1804018.05.2026
Red Hat Enterprise Linux 8jqFixedRHSA-2026:1625212.05.2026
Red Hat Enterprise Linux 8.4 Advanced Mission Critical Update SupportjqFixedRHSA-2026:1804818.05.2026
Red Hat Enterprise Linux 8.4 Extended Update Support Long-Life Add-OnjqFixedRHSA-2026:1804818.05.2026

Показывать по

Дополнительная информация

Статус:

Important
Дефект:
CWE-125
https://bugzilla.redhat.com/show_bug.cgi?id=2458077jq: out-of-bounds read in jv_parse_sized() on error formatting for non-NUL-terminated buffers

8.2 High

CVSS3

Связанные уязвимости

CVSS3: 6.5
ubuntu
4 месяца назад

jq is a command-line JSON processor. In commits before 2f09060afab23fe9390cce7cb860b10416e1bf5f, the jv_parse_sized() API in libjq accepts a counted buffer with an explicit length parameter, but its error-handling path formats the input buffer using %s in jv_string_fmt(), which reads until a NUL terminator is found rather than respecting the caller-supplied length. This means that when malformed JSON is passed in a non-NUL-terminated buffer, the error construction logic performs an out-of-bounds read past the end of the buffer. The vulnerability is reachable by any libjq consumer calling jv_parse_sized() with untrusted input, and depending on memory layout, can result in memory disclosure or process termination. The issue has been patched in commit 2f09060afab23fe9390cce7cb860b10416e1bf5f.

CVSS3: 6.5
nvd
4 месяца назад

jq is a command-line JSON processor. In commits before 2f09060afab23fe9390cce7cb860b10416e1bf5f, the jv_parse_sized() API in libjq accepts a counted buffer with an explicit length parameter, but its error-handling path formats the input buffer using %s in jv_string_fmt(), which reads until a NUL terminator is found rather than respecting the caller-supplied length. This means that when malformed JSON is passed in a non-NUL-terminated buffer, the error construction logic performs an out-of-bounds read past the end of the buffer. The vulnerability is reachable by any libjq consumer calling jv_parse_sized() with untrusted input, and depending on memory layout, can result in memory disclosure or process termination. The issue has been patched in commit 2f09060afab23fe9390cce7cb860b10416e1bf5f.

msrc
4 месяца назад

jq: Out-of-Bounds Read in jv_parse_sized() Error Formatting for Non-NUL-Terminated Counted Buffers

CVSS3: 6.5
debian
4 месяца назад

jq is a command-line JSON processor. In commits before 2f09060afab23fe ...

CVSS3: 9.1
fstec
4 месяца назад

Уязвимость функции jv_parse_sized() функционального языка программирования jq, позволяющая нарушителю вызвать отказ в обслуживании

8.2 High

CVSS3