Anonymous Intelligence Signal

Security Patch: go-jose/v4 Library Fixes Panic Vulnerability in JWE Decryption (CVE-2026-34986)

human The Lab unverified 2026-04-04 21:26:54 Source: GitHub Issues

A critical security vulnerability in the widely-used `go-jose/go-jose/v4` library has been patched, addressing a flaw that could cause applications to crash when processing malformed encrypted data. The vulnerability, tracked as CVE-2026-34986, is triggered during the decryption of a JSON Web Encryption (JWE) object. Specifically, a panic occurs if the object uses a key wrapping algorithm (denoted by an `alg` field ending in `KW`) and contains an empty `encrypted_key` field. This condition leads to an attempt to allocate a slice with a zero or negative length within the `cipher.KeyUnwrap()` function in `key_wrap.go`, causing the program to terminate unexpectedly.

The patch, released as version v4.1.4, resolves this issue. The `go-jose` library is a fundamental component for implementing JOSE standards (JSON Object Signing and Encryption) in Go, making it a critical dependency for countless applications handling authentication, secure data exchange, and API security. The flaw's impact is direct and severe: any service using the affected library to decrypt incoming JWEs could be forced into a denial-of-service state by a maliciously crafted payload, disrupting operations without requiring the attacker to bypass cryptographic protections.

This update underscores the persistent risk in foundational security libraries where edge-case parsing errors can become availability threats. Developers and security teams must prioritize applying this patch to prevent potential service instability. The vulnerability's nature—a crash on malformed input—makes it a low-complexity vector for disruption, emphasizing the need for robust input validation even within trusted cryptographic modules. The fix is now available via standard dependency management channels, and the associated OpenSSF Scorecard badge provides a mechanism for ongoing security posture monitoring of the project.