Executive brief
A security flaw has been identified in libssh, a library used by many applications to provide secure encrypted communications. When built with older versions of the OpenSSL security toolkit, the library may fail to properly generate encryption keys but continue as if it had succeeded. This could allow an attacker to compromise the confidentiality and integrity of SSH sessions, potentially leading to the exposure of sensitive data or unauthorized access to systems.
Technical details
A flaw exists in the ssh_kdf() function of libssh when compiled against OpenSSL versions older than 3.0. The vulnerability stems from an inconsistent interpretation of return values: OpenSSL uses 0 to signal a failure, whereas libssh interprets 0 as success. Consequently, if the key derivation function fails, libssh may proceed using uninitialized cryptographic key buffers. This can be exploited by a network-based attacker to compromise the confidentiality, integrity, and availability of SSH sessions. The issue is addressed in libssh version 0.11.2 and various Red Hat package updates.
Affected products
- libssh libssh < 0.11.2
- Red Hat Enterprise Linux 6.0, 7.0, 8.0, 9.0, 10.0
- Red Hat OpenShift Container Platform 4.0
Timeline
- 2025-07-04: disclosed
- 2025-07-04: advisory
- 2025-11-24: patched: Red Hat released initial patches for RHEL 8