CVE-2025-4877Libssh: write beyond bounds in binary to base64 conversion functions
- 4.5MediumCVSS base score
- 0.22%Exploitation in 30 daysEPSS · top 87% of all CVEs
- NoKnown exploitednot in CISA's KEV catalog
- NonePublic exploitsnone known yet
Description
There's a vulnerability in the libssh package where when a libssh consumer passes in an unexpectedly large input buffer to ssh_get_fingerprint_hash() function. In such cases the bin_to_base64() function can experience an integer overflow leading to a memory under allocation, when that happens it's possible that the program perform out of bounds write leading to a heap corruption. This issue affects only 32-bits builds of libssh.
Timeline
ID reserved
By redhat
- 3 months later
· 3 months later
Published
- 15 months later
· 15 months later
Record updated
Changes after publication (a new score, a public exploit, EPSS crossing 1, 10 or 50 %, leaving KEV) are kept since November 2026; earlier ones are not known.
Scores
| Scored by | CVSS | Score | Vector |
|---|---|---|---|
| redhatCNA (assigner) | 3.1 | Medium4.5 | CVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:U/C:L/I:L/A:L |
| NVDNVD · Deferred | 3.1 | Medium4.5 | CVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:U/C:L/I:L/A:L |
- EPSS (exploitation in 30 days)
- 0.22% · top 87% of all CVEs (12 Nov 2026)
- CISA SSVC
- Exploitation: none · Automatable: no · Technical impact: partial
The list uses the assigner's score when there is one, then CISA's, then NVD's: Medium 4.5.
Affected products
libssh
- affected < 0.11.2
Red Hat · Red Hat Enterprise Linux 9
- unaffected 0:0.10.4-18.el9 – < *
Red Hat · Red Hat Enterprise Linux 9
- unaffected 0:0.10.4-18.el9 – < *
Red Hat · Red Hat Enterprise Linux 10
All versions: unaffected
Red Hat · Red Hat Enterprise Linux 6
All versions: unaffected
Red Hat · Red Hat Enterprise Linux 7
All versions: unaffected
Red Hat · Red Hat Enterprise Linux 8
All versions: unaffected
Red Hat · Red Hat OpenShift Container Platform 4
All versions: unaffected
Red Hat · Red Hat OpenShift Container Platform 4
All versions: unaffected
References
References5
- RHSA-2026:18683 (opens in a new tab)vendor-advisoryx_refsource_REDHAT
- https://access.redhat.com/security/cve/CVE-2025-4877 (opens in a new tab)vdb-entryx_refsource_REDHAT
- RHBZ#2376193 (opens in a new tab)issue-trackingx_refsource_REDHAT
- https://git.libssh.org/projects/libssh.git/commit/?h=stable-0.11&id=6fd9cc8ce3958092a1aae11f1f2e911b2747732d (opens in a new tab)
- https://www.libssh.org/security/advisories/CVE-2025-4877.txt (opens in a new tab)
Sources
The same CVE in the primary databases and aggregators, to check against.
- CVE.org record (opens in a new tab)
- CVE List JSON (GitHub) (opens in a new tab)
- NVD (opens in a new tab)
- FIRST EPSS (opens in a new tab)
- EUVD EUVD-2025-28257 (opens in a new tab)
- OSV.dev (opens in a new tab)
- GitHub Advisories (opens in a new tab)
- CIRCL Vulnerability-Lookup (opens in a new tab)
Badge for a README or a ticket
[](https://cveledger.app/cve/CVE-2025-4877)Record last updated .