JWX vulnerable to a denial of service attack using compressed JWE message in github.com/lestrrat-go/jwx
Published 20 May 2024 · Updated 4 Feb 2026
Is your project on an affected github.com/lestrrat-go/jwx?
Look after several Go apps? Indie watches up to 15 repos, private ones too, for $5 a month. See Indie
Affected packages
- Affected
- <1.2.29
- Fixed in
- 1.2.29
go get github.com/lestrrat-go/jwx@v1.2.29- Affected
- <2.0.21
- Fixed in
- 2.0.21
go get github.com/lestrrat-go/jwx/v2@v2.0.21Details
An attacker with a trusted public key may cause a Denial-of-Service (DoS) condition by crafting a malicious JSON Web Encryption (JWE) token with an exceptionally high compression ratio. When this token is processed by the recipient, it results in significant memory allocation and processing time during decompression.
Is GO-2024-2632 in any of your client repos?
Checking one package by hand is fine. Checking it across forty client projects is not. NPMscan reads the lockfiles in every GitHub repo you pick, finds each project with an affected github.com/lestrrat-go/jwx, and gives you the command that fixes it.
More advisories for github.com/lestrrat-go/jwx
- LowCVE-2024-21664Panic due to nil pointer dereference in github.com/lestrrat-go/jwx/v2 · 23 Jan 2024
- MediumCVE-2024-21664Parsing JSON serialized payload without protected field can lead to segfault · 9 Jan 2024
- LowCVE-2023-49290Denial of service due to malicious parameters in github.com/lestrrat-go/jwx · 11 Dec 2023
- MediumCVE-2023-49290lestrrat-go/jwx's malicious parameters in JWE can cause a DOS · 5 Dec 2023
- LowGO-2023-1859Padding oracle vulnerability in github.com/lestrrat-go/jwx · 22 Jun 2023
- MediumGHSA-rm8v-mxj3-5rmqgithub.com/lestrrat-go/jwx vulnerable to Potential Padding Oracle Attack · 14 Jun 2023
References
- Advisorygithub.com/lestrrat-go/jwx/security/advisories/GHSA-hj3v-m684-v259
- Fixgithub.com/lestrrat-go/jwx/commit/d01027d74c7376d66037a10f4f64af9af26a7e34
- Fixgithub.com/lestrrat-go/jwx/commit/d43f2ceb7f0c13714dfe8854d6439766e86faa76
- Linkgithub.com/lestrrat-go/jwx/releases/tag/v1.2.29
- Linkgithub.com/lestrrat-go/jwx/releases/tag/v2.0.21
Advisory data from OSV.dev (opens OSV.dev in a new tab), refreshed daily.