CVE-2026-126345 basic-ftp: Uncaught TypeError in MLSD directory-listing parser via __proto__ fact name causes DoS in Client.list()
A malicious FTP server can crash Node.js apps using basic-ftp by sending a __proto__ fact name that triggers an unhandled TypeError.
- Exploited in the wild
- Not known
- Login needed
- Not needed
- Attackable
- Over the internet
- Victim action needed
- Not needed
- Harmful if only installed
- No
- Needs a specific call
- Yes
- Fix
- Available
What is CVE-2026-126345?
CVE-2026-126345 is a medium-severity denial of service vulnerability in patrickjuchli basic-ftp, published on 12 Nov 2026. An attacker can exploit it over the internet without logging in, with no action from the victim.
Official description
basic-ftp is an FTP client for Node.js. Prior to 6.2.4, the MLSD directory-listing parser in src/parseListMLSD.ts uses untrusted fact names from the FTP server as keys in the plain-object factHandlersByName dictionary without checking that the resolved property is an own handler. A fact named __proto__ therefore resolves to Object.prototype, bypasses the missing-handler guard, and is called as though it were a function, producing a TypeError. The error propagates through Client.list() and APIs that depend on it because it is not an FTPError. A malicious or compromised FTP server, or an on-path attacker on a plaintext FTP session, can make the affected operation reject, and the Node.js process terminates under the default behavior in Node.js 15 and later only if the application leaves that rejection unhandled. This issue is fixed in version 6.2.4.
Which versions are affected by CVE-2026-126345?
1 open source package ship an affected version, including basic-ftp.
An affected version is only exploitable if your software calls Client.list(). Many projects that include it are not exposed.
| Package | Affected | Fixed in |
|---|---|---|
basic-ftp npm | All versions | 6.2.4 |
How do I fix CVE-2026-126345?
Upgrade basic-ftp to 6.2.4 or later.
Upgrade, then put limits on request size, rate and nesting depth so one client cannot exhaust the service. More about Denial of service.
Is CVE-2026-126345 being exploited?
There is no known exploitation of CVE-2026-126345 in the wild and no public exploit code.
Sources
Also known as GHSA-5pm8-86m8-9m6r.