CVE-2025-5351
Fixed in a distro release EPSS <1%CVSS 6.5
A flaw was found in the key export functionality of libssh. The issue occurs in the internal function responsible for converting cryptographic keys into serialized formats. During error handling, a memory structure is freed but not cleared, leading to a potential double free issue if an additional failure occurs later in the function. This condition may result in heap corruption or application instability in low-memory scenarios, posing a risk to system reliability where key export operations are performed.
Products: libssh, Red Hat Enterprise Linux 9, Red Hat Enterprise Linux 10, Red Hat Enterprise Linux 6, Red Hat Enterprise Linux 7, Red Hat Enterprise Linux 8, Red Hat OpenShift Container Platform 4
Distro releases
| Release | Package | Fixed in |
|---|---|---|
| AlmaLinux 9 | libssh | 0.10.4-18.el9 |
| AlmaLinux 9 | libssh-config | 0.10.4-18.el9 |
| AlmaLinux 9 | libssh-devel | 0.10.4-18.el9 |
| Amazon Linux 2023 | libssh | 0.10.6-1.amzn2023.0.2 |
| Amazon Linux 2023 | libssh-config | 0.10.6-1.amzn2023.0.2 |
| Amazon Linux 2023 | libssh-devel | 0.10.6-1.amzn2023.0.2 |
| Debian 12 | libssh | 0.10.6-0+deb12u2 |
| Debian 13 | libssh | 0.11.2-1 |
| Debian 14 | libssh | 0.11.2-1 |
| Red Hat Enterprise Linux 9 | libssh | 0:0.10.4-18.el9 |
| Red Hat Enterprise Linux 9 | libssh-config | 0:0.10.4-18.el9 |
| Red Hat Enterprise Linux 9 | libssh-debuginfo | 0:0.10.4-18.el9 |
| Red Hat Enterprise Linux 9 | libssh-debugsource | 0:0.10.4-18.el9 |
| Red Hat Enterprise Linux 9 | libssh-devel | 0:0.10.4-18.el9 |
| Rocky Linux 9 | libssh | 0:0.10.4-18.el9 |
| SUSE Linux Micro 6.0 | libssh | 0.10.6-2.1 |
| SUSE Linux Micro 6.1 | libssh | 0.10.6-slfo.1.1_2.1 |
| Ubuntu 22.04 LTS | libssh | 0.9.6-2ubuntu0.22.04.4 |
| Ubuntu 24.04 LTS | libssh | 0.10.6-2ubuntu0.1 |
| openSUSE Tumbleweed | libssh | 0.11.2-1.1 |