compress provides various compression algorithms. Prior to version 1.18.7, a signed integer overflow vulnerability in s2.NewDict() allows an attacker to bypass repeat index validation by supplying a dictionary with a uvarint-encoded repeat value exceeding MaxInt64. When Dict.Encode() is subsequently called, the overflowed negative repeat value causes an out-of-bounds memory access via unsafe.Pointer arithmetic, crashing the process with SIGSEGV. This issue has been patched in version 1.18.7.
https://github.com/klauspost/compress/security/advisories/GHSA-259r-337f-4rfw
https://github.com/klauspost/compress/releases/tag/v1.18.7
https://github.com/klauspost/compress/pull/1163
https://github.com/klauspost/compress/commit/8668e357e776d5152ed62f33c17f21b8690664fa
https://github.com/klauspost/compress/commit/539243b8823ee8f03e49969823d57c348c917536
Published: 2026-09-29
Updated: 2026-09-30
Named Vulnerability: GO-2026-5841Named Vulnerability: GHSA-259r-337f-4rfw
Base Score: 7.8
Vector: CVSS2#AV:N/AC:L/Au:N/C:N/I:N/A:C
Severity: High
Base Score: 7.5
Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
Severity: High
EPSS: 0.00572