CVE-2023-51774: json-jwt allows bypass of identity checks via a sign/encryption confusion attack
The json-jwt (aka JSON::JWT) gem 1.16.x before 1.16.6, 1.15.x before 1.15.3.1 for Ruby sometimes allows bypass of identity checks via a sign/encryption confusion attack. For example, JWE can sometimes be used to bypass JSON::JWT.decode.
Published Feb 29, 2024 · Updated Mar 6, 2024
Affected packages
json-jwt
- Ecosystem
- RubyGems
- Affected
- >= 1.16.0, < 1.16.6
- Fixed in
- 1.16.6
- Check
bundle info json-jwt
json-jwt
- Ecosystem
- RubyGems
- Affected
- < 1.15.3.1
- Fixed in
- 1.15.3.1
- Check
bundle info json-jwt
Advisory details
From the GitHub Advisory Database (CC BY 4.0).
The json-jwt (aka JSON::JWT) gem 1.16.x before 1.16.6, 1.15.x before 1.15.3.1 for Ruby sometimes allows bypass of identity checks via a sign/encryption confusion attack. For example, JWE can sometimes be used to bypass JSON::JWT.decode.
Credited to postmodern, sorah, Capncavedan.
References
- https://nvd.nist.gov/vuln/detail/CVE-2023-51774
- https://github.com/P3ngu1nW/CVE_Request/blob/main/novjson-jwt.md
- https://github.com/nov/json-jwt/issues/120
- https://github.com/nov/json-jwt/commit/9c4d842a9465bd7960570ca326c3de79b4abc9d0
- https://github.com/rubysec/ruby-advisory-db/blob/master/gems/json-jwt/CVE-2023-51774.yml
- https://github.com/nov/json-jwt/issues/121
- https://github.com/nov/json-jwt/commit/593ea8bcaf2629048bad8c036191f2da0a2e713c
- https://github.com/advisories/GHSA-c8v6-786g-vjx6
How this page is made: the data panel comes from the GitHub Advisory Database, CISA’s KEV catalog, the NVD and FIRST EPSS, and updates twice a day. No analysis has been written for this entry yet. Methodology
