JWE is missing AES-GCM authentication tag validation in encrypted JWE
Published 7 Aug 2025 · Updated 8 Aug 2025
Is your project on an affected jwe?
Look after several Rails or Ruby apps? Indie watches up to 15 repos, private ones too, for $5 a month. See Indie
Affected package
- Affected
- <1.1.1
- Fixed in
- 1.1.1
bundle update --conservative jwe # Gemfile: '>= 1.1.1'Details
Overview
The authentication tag of encrypted JWEs can be brute forced, which may result in loss of confidentiality for those JWEs and provide ways to craft arbitrary JWEs.
Impact
- JWEs can be modified to decrypt to an arbitrary value
- JWEs can be decrypted by observing parsing differences
- The GCM internal GHASH key%20is%20the-,hash%20key,-%2C%20a%20string%20of) can be recovered
Am I Affected?
You are affected by this vulnerability even if you do not use an AES-GCM encryption algorithm for your JWEs.
Patches
The version 1.1.1 fixes the issue by adding the tag length check for the AES-GCM algorithm.
Important: As the GHASH key%20is%20the-,hash%20key,-%2C%20a%20string%20of) could have leaked, you must rotate the encryption keys after upgrading to version 1.1.1.
References
Is GHSA-c7p4-hx26-pr73 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 jwe, and gives you the command that fixes it.
References
Advisory data from OSV.dev (opens OSV.dev in a new tab), refreshed daily.