CVE-2025-5372 | Libssh: incorrect return code handling in ssh_kdf() in libssh

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.

Published: 2025-07-04 Last update: 2026-06-17 Assigner: [email protected] Source: [email protected]

Conclusion & alert: CVE-2025-5372 is rated Low Risk (31.4/100): CVSS Medium severity, with low exploitation likelihood (EPSS 0.41%). Mandatory action: Monitor for updates and reassess as exploit intelligence or EPSS changes.

Risk is dynamic; we continuously reassess and refresh what is shown on this page as upstream context changes.

Exploit prediction scoring system (EPSS) score for CVE-2025-5372

EPSS lead: Daily EPSS estimates relative likelihood of exploitation; percentile ranks this CVE among scored vulnerabilities (higher = more severe relative rank).

# Date Old EPSS score New EPSS score Delta (New - Old)
1 2026-06-15 0.30% 0.41% +0.11%
2 2026-06-08 0.25% 0.30% +0.06%
3 2026-05-30 0.25%

Full EPSS history (10 records total)

Common vulnerability scoring system (CVSS) metrics for CVE-2025-5372

CVSS metrics for this CVE.

Base score Version Severity Vector Exploitability Impact Score source
5.0 3.1 MEDIUM
CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:U/C:L/I:L/A:L Click to expand
Attack vector (AV:N)
Could be attacked over the internet or any normal routed network—not just someone sitting at the machine.
Attack complexity (AC:H)
Even with access, the exploit needs extra luck, timing, or a fussy environment to actually work.
Privileges required (PR:L)
A normal user session is enough; they don’t have to be admin.
User interaction (UI:N)
Nobody has to click “OK” or open a trap file; it can work without a victim helping.
Scope (S:U)
Damage stays in the same “trust bubble” as the broken component—no big spill into unrelated systems.
Confidentiality (C:L)
Some sensitive info could get out, but not a total data dump.
Integrity (I:L)
Attackers could change some data, but it’s limited—not everything goes.
Availability (A:L)
Might cause slowdowns, glitches, or partial disruption—not a full brick.
1.6 3.4 [email protected]
8.8 3.1 HIGH
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H Click to expand
Attack vector (AV:N)
Could be attacked over the internet or any normal routed network—not just someone sitting at the machine.
Attack complexity (AC:L)
Once they can reach the bug, pulling it off is straightforward—no weird race conditions or rare setup.
Privileges required (PR:L)
A normal user session is enough; they don’t have to be admin.
User interaction (UI:N)
Nobody has to click “OK” or open a trap file; it can work without a victim helping.
Scope (S:U)
Damage stays in the same “trust bubble” as the broken component—no big spill into unrelated systems.
Confidentiality (C:H)
Serious risk that confidential data gets exposed in a big way.
Integrity (I:H)
They could widely tamper with or forge data—trust in the data is badly hurt.
Availability (A:H)
Could take the service down hard or make it unusable for people who depend on it.
2.8 5.9 [email protected]

Weakness enumeration for CVE-2025-5372

GitHub Security Advisory for CVE-2025-5372

GHSA-59w5-j22f-h3rv · Severity: medium — A flaw was found in libssh versions built with OpenSSL versions older than 3.0, specifically in...

OS Trackers for CVE-2025-5372

vendor priority summary link
alpine CVE-2025-5372: 1 source package rows (libssh); 16 state rows across 2 repos (3.22-community, edge-community); fixed 2, open 14. https://security.alpinelinux.org/vuln/CVE-2025-5372
debian not yet assigned CVE-2025-5372 not yet assigned priority: Debian including 1 source packages (libssh), 5 status rows across 5 suites (bookworm, bullseye, forky, sid, trixie): resolved 5. https://security-tracker.debian.org/tracker/CVE-2025-5372
redhat medium https://access.redhat.com/security/cve/CVE-2025-5372
suse high CVE-2025-5372 severity important: SUSE including 357 source package names (0.0.17-1.1:libssh-config-0.9.8-150600.11.3.1, 0.0.17-1.1:libssh4-0.9.8-150600.11.3.1, …), 1055 product×package rows across 366 product lines (Container bci/kiwi, Container bci/spack, … (366 product lines)): Fixed 831, Known Affected 221, Known Not Affected 3. https://www.suse.com/security/cve/CVE-2025-5372/
ubuntu medium CVE-2025-5372 medium priority: Ubuntu including 1 source packages (libssh), 8 status rows across 8 suites (bionic, focal, jammy, noble, oracular, plucky, upstream, xenial): released 5, ignored 3. https://ubuntu.com/security/CVE-2025-5372

Affected software / configurations for CVE-2025-5372

Vendor Product Version Raw CPE
libssh libssh < 0.11.2 cpe:2.3:a:libssh:libssh:*:*:*:*:*:*:*:*
redhat openshift_container_platform 4.0 cpe:2.3:a:redhat:openshift_container_platform:4.0:*:*:*:*:*:*:*
redhat enterprise_linux 6.0 cpe:2.3:o:redhat:enterprise_linux:6.0:*:*:*:*:*:*:*
redhat enterprise_linux 7.0 cpe:2.3:o:redhat:enterprise_linux:7.0:*:*:*:*:*:*:*
redhat enterprise_linux 8.0 cpe:2.3:o:redhat:enterprise_linux:8.0:*:*:*:*:*:*:*
redhat enterprise_linux 9.0 cpe:2.3:o:redhat:enterprise_linux:9.0:*:*:*:*:*:*:*
redhat enterprise_linux 10.0 cpe:2.3:o:redhat:enterprise_linux:10.0:*:*:*:*:*:*:*

References for CVE-2025-5372

cvelogic Threat Intelligence