CVE-2023-40165

HighCVSS 7.5/10Last modified Jun 17, 2026

Description

rubygems.org is the Ruby community's primary gem (library) hosting service. Insufficient input validation allowed malicious actors to replace any uploaded gem version that had a platform, version number, or gem name matching `/-\d/`, permanently replacing the legitimate upload in the canonical gem storage bucket, and triggering an immediate CDN purge so that the malicious gem would be served immediately. The maintainers have checked all gems matching the `/-\d/` pattern and can confirm that no unexpected `.gem`s were found. As a result, we believe this vulnerability was _not_ exploited. The easiest way to ensure that a user's applications were not exploited by this vulnerability is to check that all of your downloaded .gems have a checksum that matches the checksum recorded in the RubyGems.org database. RubyGems contributor Maciej Mensfeld wrote a tool to automatically check that all downloaded .gem files match the checksums recorded in the RubyGems.org database. You can use it by running: `bundle add bundler-integrity` followed by `bundle exec bundler-integrity`. Neither this tool nor anything else can prove you were not exploited, but the can assist your investigation by quickly comparing RubyGems API-provided checksums with the checksums of files on your disk. The issue has been patched with improved input validation and the changes are live. No action is required on the part of the user. Users are advised to validate their local gems.

Metrics

CVSS 3.1 7.5/10CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N

Weakness enumeration

Affected software

No affected versions have been published.

Timeline

Published
Aug 17, 2023
Last modified
Jun 17, 2026
NVD status
Modified

Related CVEs from 2023

CVE-2023-401665.5Notepad++ is a free and open-source source code editor. Versions 8.5.6 and prior are vulnerable to heap buffer read overflow in `FileManagerCVE-2023-401675.3Jetty is a Java based web server and servlet engine. Prior to versions 9.4.52, 10.0.16, 11.0.16, and 12.0.1, Jetty accepts the `+` characterCVE-2023-401686.5TurboWarp is a desktop application that compiles scratch projects to JavaScript. TurboWarp Desktop versions prior to version 1.8.0 allowed aCVE-2023-40176.1The Goya theme for WordPress is vulnerable to Reflected Cross-Site Scripting via the ‘attra-color’, 'attra-size', and 'product-cata' parameCVE-2023-401706.1jupyter-server is the backend for Jupyter web applications. Improper cross-site credential checks on `/files/` URLs could allow exposure of CVE-2023-401717.5Dispatch is an open source security incident management tool. The server response includes the JWT Secret Key used for signing JWT tokens inCVE-2023-401728.8Social media skeleton is an uncompleted/framework social media project implemented using a php, css ,javascript and html. A Cross-site requeCVE-2023-401737.5Social media skeleton is an uncompleted/framework social media project implemented using a php, css ,javascript and html. Prior to version 1CVE-2023-401749.8Social media skeleton is an uncompleted/framework social media project implemented using a php, css ,javascript and html. Insufficient sessiCVE-2023-401759.8Puma is a Ruby/Rack web server built for parallelism. Prior to versions 6.3.1 and 5.6.7, puma exhibited incorrect behavior when parsing chunCVE-2023-401765.4XWiki Platform is a generic wiki platform offering runtime services for applications built on top of it. Any registered user can exploit a sCVE-2023-401778.8XWiki Platform is a generic wiki platform offering runtime services for applications built on top of it. Any registered user can use the con
CVE-2023-40165: High severity, CVSS 7.5 | Vulnix