Go JOSE projectのGo JOSEにおけるキャッチされない例外に関する脆弱性
タイトル Go JOSE projectのGo JOSEにおけるキャッチされない例外に関する脆弱性
概要

Go JOSEは、GoでJavaScriptのオブジェクト署名および暗号化の標準セットを実装しており、JSON Web Encryption(JWE)、JSON Web Signature(JWS)、およびJSON Web Token(JWT)の各標準をサポートしています。バージョン4.1.4および3.0.5より前では、algフィールドがキーラッピングアルゴリズム(A128GCMKW、A192GCMKW、A256GCMKWを除くKWで終わるもの)を示し、encrypted_keyフィールドが空の場合にJSON Web Encryption(JWE)オブジェクトの復号時にパニックが発生します。このパニックは、key_wrap.go内のcipher.KeyUnwrap()がencrypted_keyの長さに基づいて長さゼロまたは負のスライスを割り当てようとするときに発生します。このコードパスには、ParseEncrypted()、ParseEncryptedJSON()、ParseEncryptedCompact()のいずれかで解析し、その後に生成されたオブジェクトでDecrypt()を呼び出すことで到達できます。なお、解析関数は許容されるキーアルゴリズムのリストを受け取ります。もし許容されるキーアルゴリズムにキーラッピングアルゴリズムが含まれていなければ、解析は失敗し、アプリケーションに影響はありません。このパニックはまた、16バイト未満の任意の暗号文パラメータでcipher.KeyUnwrap()を直接呼び出すことでも発生しますが、この関数を直接呼び出すことはあまり一般的ではありません。このパニックはサービス拒否(DoS)につながる可能性があります。この脆弱性はバージョン4.1.4および3.0.5で修正されています。

想定される影響 当該ソフトウェアが扱う情報について、外部への漏えいは発生しません。 また、当該ソフトウェアが扱う情報について、書き換えは発生しません。 さらに、当該ソフトウェアが完全に停止する可能性があります。 そして、この脆弱性を悪用した攻撃の影響は、他のソフトウェアには及びません。 
対策

正式な対策が公開されています。ベンダ情報を参照して適切な対策を実施してください。

公表日 2026年4月6日0:00
登録日 2026年5月7日11:27
最終更新日 2026年5月7日11:27
CVSS3.0 : 重要
スコア 7.5
ベクター CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
影響を受けるシステム
Go JOSE project
Go JOSE 3.0.0 以上 3.0.5 未満
Go JOSE 4.0.0 以上 4.1.4 未満
CVE (情報セキュリティ 共通脆弱性識別子)
CWE (共通脆弱性タイプ一覧)
ベンダー情報
その他
変更履歴
No 変更内容 変更日
1 [2026年05月07日]
  掲載
2026年5月7日11:27

NVD脆弱性情報
CVE-2026-34986
概要

Go JOSE provides an implementation of the Javascript Object Signing and Encryption set of standards in Go, including support for JSON Web Encryption (JWE), JSON Web Signature (JWS), and JSON Web Token (JWT) standards. Prior to 4.1.4 and 3.0.5, decrypting a JSON Web Encryption (JWE) object will panic if the alg field indicates a key wrapping algorithm (one ending in KW, with the exception of A128GCMKW, A192GCMKW, and A256GCMKW) and the encrypted_key field is empty. The panic happens when cipher.KeyUnwrap() in key_wrap.go attempts to allocate a slice with a zero or negative length based on the length of the encrypted_key. This code path is reachable from ParseEncrypted() / ParseEncryptedJSON() / ParseEncryptedCompact() followed by Decrypt() on the resulting object. Note that the parse functions take a list of accepted key algorithms. If the accepted key algorithms do not include any key wrapping algorithms, parsing will fail and the application will be unaffected. This panic is also reachable by calling cipher.KeyUnwrap() directly with any ciphertext parameter less than 16 bytes long, but calling this function directly is less common. Panics can lead to denial of service. This vulnerability is fixed in 4.1.4 and 3.0.5.

公表日 2026年4月7日2:17
登録日 2026年4月15日11:27
最終更新日 2026年4月7日22:20
関連情報、対策とツール
共通脆弱性一覧