CVE-2025-5987

HIGH CVSS 3.1: 8.1 EPSS 1.73%
Updated Nov 24, 2026
Libssh
Parameter Value
CVSS 8.1 (HIGH)
Affected Versions 0.10.0 — 0.11.2
Fixed In 0.11.2
Type CWE-393
Vendor Libssh
Public PoC No

A flaw was found in libssh when using the ChaCha20 cipher with the OpenSSL library. If an attacker manages to exhaust the heap space, this error is not detected and may lead to libssh using a partially initialized cipher context. This occurs because the OpenSSL error code returned aliases with the SSH_OK code, resulting in libssh not properly detecting the error returned by the OpenSSL library.

This issue can lead to undefined behavior, including compromised data confidentiality and integrity or crashes.

Attack Parameters

Attack Vector
Network
Can be exploited remotely
Attack Complexity
High
Difficult to exploit
Privileges Required
None
No privileges needed
User Interaction
None
No user interaction needed

Impact Assessment

Confidentiality
High
Complete data leak
Integrity
High
Complete data modification
Availability
High
Complete denial of service

CVSS Vector v3.1

Weakness Type (CWE)

Vulnerable Products 1

Configuration From (including) Up to (excluding)
Libssh Libssh
cpe:2.3:a:libssh:libssh:*:*:*:*:*:*:*:*
0.10.0 0.11.2