CVE-2021-4189
CWE-252Published: August 24, 2022· Updated: Jun 17, 2026
Official Description
A flaw was found in Python, specifically in the FTP (File Transfer Protocol) client library in PASV (passive) mode. The issue is how the FTP client trusts the host from the PASV response by default. This flaw allows an attacker to set up a malicious FTP server that can trick FTP clients into connecting back to a given IP address and port. This vulnerability could lead to FTP client scanning ports, which otherwise would not have been possible.
Technical Analysis
CVE-2021-4189 can be exploited remotely over the network without requiring physical or adjacent access, significantly expanding the attack surface for threat actors.
The vulnerability requires no privileges and no user interaction, making it a prime target for automated exploitation campaigns and worm-like propagation.
CVSS v3.1 Vector Breakdown
Affected Vendors & Products
Exploit & PoC Resources
Official Patches & Advisories
All References (19)
Quick Facts
Related CVEs (CWE-252)
Recommended Actions
- →Apply vendor patches immediately
- →Monitor CVE-2021-4189 in threat intel feeds
- →Review IDS/IPS signatures for exploitation attempts