CVE-2026-66032: Double free in libssh2 sftp_open()
- Vendor
- Libssh2
A double-free vulnerability in libssh2 through version 1.11.1 affects sftp_open() when an authenticated client processes responses from a malicious SSH server. An SSH_FXP_STATUS response containing FX_OK to an SSH_FXP_OPEN request causes the response buffer to be freed. If a subsequent sftp_packet_require() call returns a qualifying error, such as LIBSSH2_ERROR_CHANNEL_PACKET_EXCEEDED, the same pointer is freed again. The resulting heap corruption can enable tcache duplication, overlapping allocations, and function-pointer overwrites on glibc systems, potentially leading to arbitrary code execution in the client process.
Impact, mitigation & remediation
What it means and what to do now: patch path, interim mitigations, and the assume-compromise checklist.
Impact
What an attacker gets, and what they’ve been doing with it.
A malicious SSH server can crash a connecting libssh2 client or corrupt its heap. Successful manipulation of overlapping allocations and function pointers may permit arbitrary code execution with the privileges of the client process, compromising its confidentiality, integrity, and availability. The vulnerability affects the connecting client rather than the SSH server.
Mitigation
If you can’t patch tonight, do this now.
Until patched, avoid connecting libssh2-based clients to untrusted SSH or SFTP servers and restrict outbound SSH/SFTP connections to trusted servers. On XCP-ng hosts, avoid using curl or Midnight Commander to access untrusted SSH/SFTP servers. These restrictions reduce exposure but do not correct the double free.
Remediation
Patch, then assume compromise.
Apply libssh2 commit 5e47761 or install a vendor-supported package containing the backported fix. A fixed upstream release number is not specified. Ubuntu fixes include libssh2-1t64 version 1.11.1-1ubuntu0.26.04.4 for Ubuntu 26.04 LTS and 1.11.0-4.1ubuntu0.24.04.4 for Ubuntu 24.04 LTS. XCP-ng 8.3 users should install libssh2 version 1.11.0-1.2.xcpng8.3. Assess distribution packages by their security revision and patch status, since fixed packages may retain an upstream version number within the affected range.
Exploits
No public exploits tracked yet. Mallory keeps watching.
Affected products & vendors
Products and vendors Mallory has correlated with this vulnerability. Open in Mallory to drill down to specific CPE configurations and version ranges.
References
Frequently asked questions
- Is CVE-2026-66032 exploited in the wild?
- As of Nov 27, 2026, Mallory has no reports of CVE-2026-66032 being exploited in the wild. It is not listed in CISA KEV.
- Is there a public exploit for CVE-2026-66032?
- As of Nov 27, 2026, Mallory has found no public exploit for CVE-2026-66032.
- Is there a patch for CVE-2026-66032?
- Apply libssh2 commit 5e47761 or install a vendor-supported package containing the backported fix. A fixed upstream release number is not specified.
- What products are affected by CVE-2026-66032?
- Libssh2.
- How severe is CVE-2026-66032?
- CVE-2026-66032 has a CVSS v4 score of 8.7 (High) and an EPSS score of 0.53% (38th percentile) as of Nov 27, 2026.
Recent activity
43 sources tracked across advisories, community write-ups, and news. New activity surfaces here as Mallory finds it.