Описание
OpenIDC/cjose is a C library implementing the Javascript Object Signing and Encryption (JOSE). In versions 0.6.1 through 0.6.2.5, when cjose encrypts a JWE using an AES-CBC-HMAC content-encryption algorithm (A128CBC-HS256, A192CBC-HS384, or A256CBC-HS512) together with any key-management algorithm that generates a fresh content-encryption key (CEK), the CEK is all zero bytes instead of being randomly generated. The resulting JWE is therefore encrypted and authenticated under a fixed, publicly known key, so anyone who obtains the JWE can recover the plaintext and forge or modify the content. This is fixed in version 0.6.2.6 by _cjose_jwe_set_cek_aes_cbc() generating the CEK from RAND_bytes. A regression test asserts that the encrypted_key differs across two encryptions for each AES-CBC-HMAC variant. Until upgrading, for data encrypted with cjose, three options are available. Use an AES-GCM enc (A128GCM / A192GCM / A256GCM) instead of an AES-CBC-HMAC enc, use alg=dir with a caller-supplied CEK, or avoid using cjose for JWE encryption with the affected algorithm pair. These are mitigations for new ciphertexts only; data already encrypted under the zero key remains compromised and should be re-encrypted (and any secrets it contained rotated).
A flaw was found in cjose. When encrypting a JSON Web Encryption (JWE) object using AES-CBC-HMAC algorithms, the library initializes the encryption key with all-zero bytes instead of generating a secure random key. As a result, an attacker who intercepts the encrypted message can decrypt sensitive plaintext and alter or forge content, leading to information disclosure and loss of data integrity.
Отчет
A CRITICAL severity vulnerability was found in cjose, a C library implementing the Javascript Object Signing and Encryption (JOSE) standards. The cjose package is affected in Red Hat Enterprise Linux 10, Red Hat In-Vehicle OS 2, and Fedora as shipped by Red Hat. When cjose encrypts a JSON Web Encryption (JWE) object using an AES-CBC-HMAC content-encryption algorithm (A128CBC-HS256, A192CBC-HS384, or A256CBC-HS512) together with any key-management algorithm that generates a fresh content-encryption key (CEK), the CEK is initialized to all zero bytes instead of being securely randomly generated. The resulting JWE is therefore encrypted and authenticated under a fixed, publicly known key. An attacker who obtains the encrypted JWE can decrypt it to recover sensitive plaintext and can alter or forge the encrypted content, causing information disclosure and loss of data integrity; availability is not affected. Red Hat and upstream both rate this flaw CRITICAL with a CVSS 3.1 score of 9.1 (CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N), so there is no difference from the upstream severity. Fixes for the affected Red Hat product streams are being pursued through delegated resolution.
Меры по смягчению последствий
Until the fixed package is installed, applications using cjose for JWE encryption can avoid the vulnerable code path by switching the content-encryption algorithm from AES-CBC-HMAC (A128CBC-HS256, A192CBC-HS384, A256CBC-HS512) to an AES-GCM enc (A128GCM, A192GCM, or A256GCM), by using alg=dir with a caller-supplied content-encryption key, or by not using cjose for JWE encryption with the affected algorithm pair. These options protect newly created ciphertexts only; data already encrypted under the all-zero key must be considered compromised, should be re-encrypted, and any secrets it contained should be rotated. Upgrading to a version containing the upstream fix (0.6.2.6 or later) resolves the issue.
Ссылки на источники
Дополнительная информация
Статус:
EPSS
9.1 Critical
CVSS3
Связанные уязвимости
OpenIDC/cjose is a C library implementing the Javascript Object Signing and Encryption (JOSE). In versions 0.6.1 through 0.6.2.5, when cjose encrypts a JWE using an AES-CBC-HMAC content-encryption algorithm (`A128CBC-HS256`, `A192CBC-HS384`, or `A256CBC-HS512`) together with any key-management algorithm that generates a fresh content-encryption key (CEK), the CEK is all zero bytes instead of being randomly generated. The resulting JWE is therefore encrypted and authenticated under a fixed, publicly known key, so anyone who obtains the JWE can recover the plaintext and forge or modify the content. This is fixed in version 0.6.2.6 by `_cjose_jwe_set_cek_aes_cbc()` generating the CEK from `RAND_bytes`. A regression test asserts that the `encrypted_key` differs across two encryptions for each AES-CBC-HMAC variant. Until upgrading, for data encrypted with cjose, three options are available. Use an AES-GCM `enc` (`A128GCM` / `A192GCM` / `A256GCM`) instead of an AES-CBC-HMAC `enc`, use `a...
OpenIDC/cjose is a C library implementing the Javascript Object Signing and Encryption (JOSE). In versions 0.6.1 through 0.6.2.5, when cjose encrypts a JWE using an AES-CBC-HMAC content-encryption algorithm (`A128CBC-HS256`, `A192CBC-HS384`, or `A256CBC-HS512`) together with any key-management algorithm that generates a fresh content-encryption key (CEK), the CEK is all zero bytes instead of being randomly generated. The resulting JWE is therefore encrypted and authenticated under a fixed, publicly known key, so anyone who obtains the JWE can recover the plaintext and forge or modify the content. This is fixed in version 0.6.2.6 by `_cjose_jwe_set_cek_aes_cbc()` generating the CEK from `RAND_bytes`. A regression test asserts that the `encrypted_key` differs across two encryptions for each AES-CBC-HMAC variant. Until upgrading, for data encrypted with cjose, three options are available. Use an AES-GCM `enc` (`A128GCM` / `A192GCM` / `A256GCM`) instead of an AES-CBC-HMAC `enc`, use `alg=
OpenIDC/cjose is a C library implementing the Javascript Object Signin ...
EPSS
9.1 Critical
CVSS3