# CVE-2021-31810: An issue was discovered in Ruby through 2.6.7, 2.7.x through 2.7.3, and 3.x through 3.0.1.

- Severity: Medium 5.8 (CVSS:3.1, scored by NVD) `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:L/I:N/A:N`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 3.10%, higher than 88% of CVEs (2026-12-01)
- Public exploit code or proof of concept: one link below, marked "exploit"
- Published: 2021-07-13T00:00:00.000Z
- Modified: 2026-09-08T08:48:19.407Z
- Also known as: BIT-RUBY-2021-31810, BIT-RUBY-MIN-2021-31810
- Assigned by: mitre

## Description

An issue was discovered in Ruby through 2.6.7, 2.7.x through 2.7.3, and 3.x through 3.0.1. A malicious FTP server can use the PASV response to trick Net::FTP into connecting back to a given IP address and port. This potentially makes curl extract information about services that are otherwise private and not disclosed (e.g., the attacker can conduct port scans and service banner extractions).

(As written by CVE List.)

## Affected

- Unspecified product: n/a
- ruby-lang ruby: up to 2.6.7; from 2.7.0 up to 2.7.3; from 3.0.0 up to 3.0.1
- debian debian_linux: 9.0
- oracle jd_edwards_enterpriseone_tools: before 9.2.6.1
- ruby (Bitnami): before 2.6.8; from 2.7.0 before 2.7.4; from 3.0.0 before 3.0.2
- ruby-min (Bitnami): before 2.6.8; from 2.7.0 before 2.7.4; from 3.0.0 before 3.0.2

## Every score

- NVD: CVSS:3.1 5.8 Medium `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:L/I:N/A:N`
- NVD: CVSS:2.0 5.0 Medium `AV:N/AC:L/Au:N/C:P/I:N/A:N`
- Bitnami Vulnerability Database: rating Medium

## References

- <https://hackerone.com/reports/1145454> (exploit, advisory, patch, third-party-advisory)
- <https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/MWXHK5UUHVSHF7HTHMX6JY3WXDVNIHSL/> (vendor-advisory, web)
- <https://lists.debian.org/debian-lts-announce/2021/10/msg00009.html> (advisory, mailing-list, third-party-advisory)
- <https://www.oracle.com/security-alerts/cpuapr2022.html> (advisory, patch, third-party-advisory)
- <https://www.ruby-lang.org/en/news/2021/07/07/trusting-pasv-responses-in-net-ftp/> (advisory, vendor-advisory)
- <https://security.netapp.com/advisory/ntap-20210917-0001/> (advisory, third-party-advisory)
- <https://lists.debian.org/debian-lts-announce/2023/04/msg00033.html> (mailing-list, web)
- <https://security.gentoo.org/glsa/202401-27> (vendor-advisory, web)
- <https://nvd.nist.gov/vuln/detail/CVE-2021-31810> (web)

## Sources

- CVE List: [CVE-2021-31810](https://www.cve.org/CVERecord?id=CVE-2021-31810), CVE Terms of Use, modified 2024-08-03
- NVD: [CVE-2021-31810](https://nvd.nist.gov/vuln/detail/CVE-2021-31810), Public domain, modified 2026-06-17
- Bitnami Vulnerability Database: [BIT-RUBY-2021-31810](https://osv.dev/vulnerability/BIT-RUBY-2021-31810), Apache-2.0, modified 2026-09-08
- Bitnami Vulnerability Database: [BIT-RUBY-MIN-2021-31810](https://osv.dev/vulnerability/BIT-RUBY-MIN-2021-31810), Apache-2.0, modified 2026-09-08

---

Page: https://cve.day/CVE-2021-31810 · Whole record: https://cve.day/CVE-2021-31810.json · Rebuilt by cve.day 2026-11-25T22:58:02.593Z
