製品・ソフトウェアに関する情報
jqlangのjqにおける再帰制御に関する脆弱性
Title jqlangのjqにおける再帰制御に関する脆弱性
Summary

jqはコマンドラインのJSONプロセッサです。バージョン1.8.2以前では、十分に深くネストされた2つの配列を==演算子で比較すると、jqの通常のコマンドライン操作中にCスタックが枯渇し、制御されていない再帰によるスタック枯渇でサービス拒否が発生します。クラッシュはjqの再帰的な構造比較コードで発生し、深くネストされた配列を比較する際にsrc/jv.cのjvp_array_equal()およびjv_equal()を通じて再帰が繰り返されます。また、再帰ガードが欠如しているため、src/jv_aux.cのjv_cmp()を経由する近接したソート比較パスでも、より深いネストの深度でスタックオーバーフローが発生します。攻撃者が制御する深くネストされたJSON値に対してjqで比較を実行する場合、または信頼できないデータが==比較パスに到達可能な環境にjqを埋め込んでいる場合、本脆弱性の影響を受けます。この脆弱性はバージョン1.8.2で修正されました。

Possible impacts ・当該ソフトウェアが扱う情報について、外部への漏えいは発生しません。 ・当該ソフトウェアが扱う情報について、書き換えは発生しません。 ・当該ソフトウェアが完全に停止する可能性があります。 
Solution

ベンダ情報を参照して適切な対策を実施してください。

Publication Date June 25, 2026, midnight
Registration Date June 29, 2026, 11:16 a.m.
Last Update June 29, 2026, 11:16 a.m.
CVSS3.0 : 警告
Score 5.5
Vector CVSS:3.0/AV:L/AC:L/PR:N/UI:R/S:U/C:N/I:N/A:H
Affected System
jqlang
jq 1.8.2 未満
CVE (情報セキュリティ 共通脆弱性識別子)
CWE (共通脆弱性タイプ一覧)
ベンダー情報
Change Log
No Changed Details Date of change
1 [2026年06月29日]
  掲載
June 29, 2026, 11:16 a.m.

NVD Vulnerability Information
CVE-2026-47770
Summary

jq is a command-line JSON processor. Prior to 1.8.2, comparing two sufficiently deeply nested arrays with the == operator exhausts the C stack on jq's ordinary command-line surface, resulting in denial of service via stack exhaustion (uncontrolled recursion). The crash occurs in jq's recursive structural comparison code, with the recursion repeating through jvp_array_equal() and jv_equal() in src/jv.c when comparing deeply nested arrays; a nearby sort comparator path through jv_cmp() in src/jv_aux.c overflows the stack at a larger nesting depth from the same missing recursion guard. Anyone running jq comparisons on attacker-controlled deeply nested JSON values, or embedding jq in a context where untrusted data can reach the == comparison path, is affected. This vulnerability is fixed in 1.8.2.

Publication Date June 26, 2026, 3:16 a.m.
Registration Date June 27, 2026, 4:29 a.m.
Last Update June 27, 2026, 3:53 a.m.
Affected software configurations
Configuration1 or higher or less more than less than
cpe:2.3:a:jqlang:jq:*:*:*:*:*:*:*:* 1.8.2
Related information, measures and tools
Common Vulnerabilities List