CVE-2026-58051
libssh2 - Free of Uninitialized Pointer in publickey List Cleanup
- State
- Published
- Severity
- 8.3 High
- Published
- Jun 28, 2026
- Updated
- Jun 29, 2026
- Reserved
- Jun 28, 2026
Description
libssh2 through 1.11.1 grows its publickey list with SSH2_REALLOC but does not zero-initialize new entries before parsing populates them, so a parse failure reaching the cleanup path leaves libssh2_publickey_list_free operating on an uninitialized entry. A malicious SSH server offering the publickey subsystem can use a malformed response to make cleanup free an uninitialized, attacker-influenceable attrs pointer in a connecting libssh2 client.
Scores
| CVSS | Score | Vector | Source |
|---|---|---|---|
| 4.0 | 8.3 High | CVSS:4.0/AV:N/AC:H/AT:N/PR:N/UI:N/VC:N/VI:L/VA:H/SC:N/SI:N/SA:N | VulnCheck |
| 3.1 | 6.5 Medium | CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:L/A:H | VulnCheck |
Weaknesses
- CWE-908 Use of Uninitialized Resource
Affected Products
| Product | Versions |
|---|---|
libssh2libssh2 |
|
References
- Proof of Conceptexploitthird-party-advisory
- src/publickey.cproduct
- VulnCheck Advisory: libssh2 - Free of Uninitialized Pointer in publickey List Cleanupthird-party-advisory
Every record here comes from the CVE Program’s CVE List. © 1999–2026 The MITRE Corporation. CVE is a registered trademark of The MITRE Corporation. The records are reproduced under the CVE Program terms of use.