CVE-2025-5372
High 8.8No known exploitationFix availableLibssh: incorrect return code handling in ssh_kdf() in libssh
Record last updated
CVSS score
High on a 0 to 10 scale
EPSS, chance of exploitation in 30 days
Higher than 44% of scored CVEs. A prediction, not evidence.
CISA remediation deadline
Not in the KEV catalog
Description
A flaw was found in libssh versions built with OpenSSL versions older than 3.0, specifically in the ssh_kdf() function responsible for key derivation. Due to inconsistent interpretation of return values where OpenSSL uses 0 to indicate failure and libssh uses 0 for success—the function may mistakenly return a success status even when key derivation fails. This results in uninitialized cryptographic key buffers being used in subsequent communication, potentially compromising SSH sessions' confidentiality, integrity, and availability.
Weakness: CWE-682
Patching and mitigation
- Patch status
- Fix available (source: CVE record (redhat))
- Fix documented (source date)
- Mitigation
- To mitigate this issue, administrators should ensure that libssh is built against OpenSSL version 3.0 or later. This change eliminates the return code mismatch and prevents the erroneous use of uninitialized key material. It is also strongly recommended to apply vendor supplied patches or update to the latest libssh security release as soon as possible. Source (opens in a new tab)
- Vendor guidance
- access.redhat.com (opens in a new tab)
Affected products
| Vendor | Product | Affected versions | Fixed in | Per |
|---|---|---|---|---|
| Red Hat | Red Hat Enterprise Linux 9 | Not documented | Not documented | CVE Program |
| Red Hat | Red Hat OpenShift Container Platform 4 | Not documented | Not documented | CVE Program |
| libssh | libssh | all versions before 0.11.2 | 0.11.2 | CVE Program |
| libssh | libssh | all versions before 0.11.2 | 0.11.2 | NIST NVD |
| redhat | enterprise_linux | 10.0 | Not documented | NIST NVD |
| redhat | enterprise_linux | 6.0 | Not documented | NIST NVD |
| redhat | enterprise_linux | 7.0 | Not documented | NIST NVD |
| redhat | enterprise_linux | 8.0 | Not documented | NIST NVD |
| redhat | enterprise_linux | 9.0 | Not documented | NIST NVD |
| redhat | openshift_container_platform | 4.0 | Not documented | NIST NVD |
| Red Hat | Red Hat Enterprise Linux 10 (status unknown) | Not documented | Not documented | CVE Program |
| Red Hat | Red Hat Enterprise Linux 6 (status unknown) | Not documented | Not documented | CVE Program |
| Red Hat | Red Hat Enterprise Linux 7 (status unknown) | Not documented | Not documented | CVE Program |
| Red Hat | Red Hat Enterprise Linux 8 (unaffected) | 0:0.9.6-16.el8_10 | Not documented | CVE Program |
| Red Hat | Red Hat Enterprise Linux 8 (unaffected) | 0:0.9.6-16.el8_10 | Not documented | CVE Program |
| Red Hat | Red Hat Enterprise Linux 8.4 Advanced Mission Critical Update Support (unaffected) | 0:0.9.4-2.el8_4.2 | Not documented | CVE Program |
| Red Hat | Red Hat Enterprise Linux 8.4 Extended Update Support Long-Life Add-On (unaffected) | 0:0.9.4-2.el8_4.2 | Not documented | CVE Program |
| Red Hat | Red Hat Enterprise Linux 8.6 Advanced Mission Critical Update Support (unaffected) | 0:0.9.6-4.el8_6.2 | Not documented | CVE Program |
| Red Hat | Red Hat Enterprise Linux 8.6 Extended Update Support Long-Life Add-On (unaffected) | 0:0.9.6-4.el8_6.2 | Not documented | CVE Program |
| Red Hat | Red Hat Enterprise Linux 8.8 Telecommunications Update Service (unaffected) | 0:0.9.6-13.el8_8.2 | Not documented | CVE Program |
| Red Hat | Red Hat Enterprise Linux 8.8 Update Services for SAP Solutions (unaffected) | 0:0.9.6-13.el8_8.2 | Not documented | CVE Program |
| Red Hat | Red Hat Enterprise Linux 9.0 Update Services for SAP Solutions (unaffected) | 0:0.9.6-3.el9_0.2 | Not documented | CVE Program |
| Red Hat | Red Hat OpenShift Container Platform 4 (status unknown) | Not documented | Not documented | CVE Program |
Timeline
Disclosure
CVE record published by redhat
Source: CVE Program (opens in a new tab)
Patch
Fix documented by CVE record (redhat)
Vendor guidance and references
- RHSA-2025:21977 (opens in a new tab)vendor-advisory, x_refsource_redhat
- RHSA-2025:23024 (opens in a new tab)vendor-advisory, x_refsource_redhat
- RHSA-2026:20610 (opens in a new tab)vendor-advisory, x_refsource_redhat
- RHSA-2026:24349 (opens in a new tab)vendor-advisory, x_refsource_redhat
- RHSA-2026:25911 (opens in a new tab)vendor-advisory, x_refsource_redhat
- https://access.redhat.com/security/cve/CVE-2025-5372 (opens in a new tab)third party advisory, vdb-entry, x_refsource_redhat
- RHBZ#2369388 (opens in a new tab)issue tracking, issue-tracking, third party advisory, x_refsource_redhat