{"id":"CVE-2021-3779","aliases":["CVE-2021-3779","GHSA-73pr-g6jj-5hc9"],"related":[],"kind":"vulnerability","state":"published","title":"Ruby-MySQL Gem Client File Read","summary":"A malicious MySQL server can request local file content from a client using ruby-mysql prior to version 2.10.0 without explicit authorization from the user. This issue was resolved in version 2.10.0 and later.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"A malicious MySQL server can request local file content from a client using ruby-mysql prior to version 2.10.0 without explicit authorization from the user. This issue was resolved in version 2.10.0 and later.","source":"cvelist"},{"lang":"en","text":"A malicious actor can read arbitrary files from a client that uses ruby-mysql to communicate to a rogue MySQL server and issue database queries. In these cases, the server has the option to create a database reply using the LOAD DATA LOCAL statement, which instructs the client to provide additional data from a local file readable by the client (and not a \"local\" file on the server).","format":"markdown","source":"ghsa"},{"lang":"es","text":"Un servidor MySQL malicioso puede solicitar el contenido de un archivo local a un cliente usando ruby-mysql versiones anteriores a 2.10.0, sin autorización explícita del usuario. Este problema ha sido resuelto en versiones 2.10.0 y posteriores","source":"nvd"}],"published":"2022-06-28T16:30:15.611Z","modified":"2026-06-17T04:05:44.840Z","severity":{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:N/A:N","score":6.5,"rating":"MEDIUM"},"severities":[{"scorer":"GitHub","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:N/A:N","score":6.5,"rating":"MEDIUM"},{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:N/A:N","score":6.5,"rating":"MEDIUM"},{"scorer":"NVD","scheme":"CVSS:2.0","vector":"AV:N/AC:M/Au:N/C:P/I:N/A:N","score":4.3,"rating":"MEDIUM"}],"cwes":["CWE-610"],"affected":[{"ranges":[{"type":"custom","introduced":"2.9.14","lastAffected":"2.9.14","status":"affected"}],"vendor":"Tomita Masahiro","product":"ruby-mysql","source":"cvelist"},{"ranges":[{"type":"ecosystem","introduced":"0","status":"affected","fixed":"2.10.0"}],"ecosystem":"RubyGems","package":"ruby-mysql","purl":"pkg:gem/ruby-mysql","source":"ghsa"},{"ranges":[{"status":"affected","fixed":"2.10.0"}],"vendor":"ruby-mysql_project","product":"ruby-mysql","cpe":"cpe:2.3:a:ruby-mysql_project:ruby-mysql:*:*:*:*:*:ruby:*:*","source":"nvd"}],"references":[{"url":"https://www.rapid7.com/blog/post/2022/06/28/cve-2021-3779-ruby-mysql-gem-client-file-read-fixed/","tags":["exploit","mitigation","third-party-advisory","x-refsource-misc","x-transferred"],"sources":["cvelist","nvd"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2021-3779","tags":["advisory"],"sources":["ghsa"]},{"url":"https://github.com/rubysec/ruby-advisory-db/blob/master/gems/ruby-mysql/CVE-2021-3779.yml","tags":["web"],"sources":["ghsa"]},{"url":"https://www.rapid7.com/blog/post/2022/06/28/cve-2021-3779-ruby-mysql-gem-client-file-read-fixed","tags":["web"],"sources":["ghsa"]},{"url":"http://github.com/tmtm/ruby-mysql","tags":["package"],"sources":["ghsa"]}],"credits":["Discovered by Hans-Martin Münch of MOGWAI LABS GmbH, reported by Rapid7, coordinated by CERT/CC and JPCERT/CC"],"assigner":"rapid7","sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2021-3779","url":"https://www.cve.org/CVERecord?id=CVE-2021-3779","licence":"CVE Terms of Use","modified":"2024-09-17T00:16:17.183Z"},{"source":"ghsa","name":"GitHub Advisory Database","id":"GHSA-73pr-g6jj-5hc9","url":"https://github.com/advisories/GHSA-73pr-g6jj-5hc9","licence":"CC-BY-4.0","modified":"2024-02-21T05:29:44.756Z"},{"source":"nvd","name":"NVD","id":"CVE-2021-3779","url":"https://nvd.nist.gov/vuln/detail/CVE-2021-3779","licence":"Public domain","modified":"2026-06-17T04:05:44.840Z"}],"updatedAt":"2026-11-25T22:58:07.689Z","epss":{"score":0.01221,"percentile":0.6954,"date":"2026-12-01T12:00:22.000Z"}}