CVE-2024-28180
JSON

4.3medium

Go JOSE vulnerable to Improper Handling of Highly Compressed Data (Data Amplification)

Severity
4.3medium CVSS:3.1 by GitHub_M
Exploit likelihood
1.96% (higher than 80% of CVEs; EPSS, by FIRST)
Published
Last changed
Assigned by
GitHub_M
Also known as
GHSA-c5q2-7r4c-mv6gGO-2024-2631

Description

Package jose aims to provide an implementation of the Javascript Object Signing and Encryption set of standards. An attacker could send a JWE containing compressed data that used large amounts of memory and CPU when decompressed by Decrypt or DecryptMulti. Those functions now return an error if the decompressed data would exceed 250kB or 10x the compressed size (whichever is larger). This vulnerability has been patched in versions 4.0.1, 3.0.3 and 2.6.3.

Affected

Product or packageVersionsReported by
go-jose go-jose< 4.0.1, < 3.0.3, < 2.6.3CVE List
go-jose_project go-josebefore 4.0.1, before 3.0.3, before 2.6.3, from 2.0.0 before 2.6.3, from 3.0.0 before 3.0.3, from 4.0.0 before 4.0.1CVE List, NVD
github.com/go-jose/go-jose/v4 (Go)before 4.0.1GitHub Advisory Database, Go Vulnerability Database
github.com/go-jose/go-jose/v3 (Go)before 3.0.3GitHub Advisory Database, Go Vulnerability Database
gopkg.in/go-jose/go-jose.v2 (Go)before 2.6.3GitHub Advisory Database, Go Vulnerability Database
gopkg.in/square/go-jose.v2 (Go)up to 2.6.0, all versionsGitHub Advisory Database, Go Vulnerability Database
fedoraproject fedorafrom 38 up to 40NVD

All scores

GitHub_M4.3medium CVSS:3.1CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:L
GitHub4.3medium CVSS:3.1CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:L

Classification

CWE-409

SSVC (CISA-ADP): exploitation none, automatable no, technical impact total.

What each source says

CVE List

Package jose aims to provide an implementation of the Javascript Object Signing and Encryption set of standards. An attacker could send a JWE containing compressed data that used large amounts of memory and CPU when decompressed by Decrypt or DecryptMulti. Those functions now return an error if the decompressed data would exceed 250kB or 10x the compressed size (whichever is larger). This vulnerability has been patched in versions 4.0.1, 3.0.3 and 2.6.3.

GitHub Advisory Database
Impact

An attacker could send a JWE containing compressed data that used large amounts of memory and CPU when decompressed by Decrypt or DecryptMulti. Those functions now return an error if the decompressed data would exceed 250kB or 10x the compressed size (whichever is larger). Thanks to Enze Wang@Alioth and Jianjun Chen@Zhongguancun Lab (@zer0yu and @chenjj) for reporting.

Patches

The problem is fixed in the following packages and versions:

  • github.com/go-jose/go-jose/v4 version 4.0.1
  • github.com/go-jose/go-jose/v3 version 3.0.3
  • gopkg.in/go-jose/go-jose.v2 version 2.6.3

The problem will not be fixed in the following package because the package is archived:

  • gopkg.in/square/go-jose.v2
Go Vulnerability Database

An attacker could send a JWE containing compressed data that used large amounts of memory and CPU when decompressed by Decrypt or DecryptMulti.

NVD (es)

El paquete jose tiene como objetivo proporcionar una implementación del conjunto de estándares de cifrado y firma de objetos Javascript. Un atacante podría enviar un JWE que contenga datos comprimidos que utilicen grandes cantidades de memoria y CPU cuando los descomprima Decrypt o DecryptMulti. Esas funciones ahora devuelven un error si los datos descomprimidos superan los 250 kB o 10 veces el tamaño comprimido (lo que sea mayor). Esta vulnerabilidad ha sido parcheada en las versiones 4.0.1, 3.0.3 y 2.6.3.

References

https://github.com/go-jose/go-jose/security/advisories/GHSA-c5q2-7r4c-mv6gadvisory, vendor-advisory, web
https://github.com/go-jose/go-jose/commit/0dd4dd541c665fb292d664f77604ba694726f298fix, patch, web
https://github.com/go-jose/go-jose/commit/add6a284ea0f844fd6628cba637be5451fe4b28afix, patch, web
https://github.com/go-jose/go-jose/commit/f4c051a0653d78199a053892f7619ebf96339502fix, patch, web
https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/XJDO5VSIAOGT2WP63AXAAWNRSVJCNCRH/mailing-list, third-party-advisory
https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/KXKGNCRU7OTM5AHC7YIYBNOWI742PRMY/mailing-list, third-party-advisory
https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/I6MMWFBOXJA6ZCXNVPDFJ4XMK5PVG5RG/mailing-list, third-party-advisory
https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/UJO2U5ACZVACNQXJ5EBRFLFW6DP5BROY/mailing-list, third-party-advisory
https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/UG5FSEYJ3GP27FZXC5YAAMMEC5XWKJHG/mailing-list, third-party-advisory
https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/IJ6LAJJ2FTA2JVVOACCV5RZTOIZLXUNJ/mailing-list, third-party-advisory
https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/JNPMXL36YGS3GQEVI3Q5HKHJ7YAAQXL5/mailing-list, third-party-advisory
https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/MSOMHDKRPU3A2JEMRODT2IREDFBLVPGS/mailing-list, third-party-advisory

Related

Sources

SourceRecordLicence
CVE ListCVE-2024-28180 changed 2025-02-13CVE Terms of Use
GitHub Advisory DatabaseGHSA-c5q2-7r4c-mv6g changed 2026-09-10CC-BY-4.0
Go Vulnerability DatabaseGO-2024-2631 changed 2026-02-04CC-BY-4.0
NVDCVE-2024-28180 changed 2026-06-17Public domain