UBUNTU-CVE-2025-5987

Source
https://ubuntu.com/security/CVE-2025-5987
Import Source
https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2025/UBUNTU-CVE-2025-5987.json
JSON Data
https://api.osv.dev/v1/vulns/UBUNTU-CVE-2025-5987
Upstream
Downstream
Related
Published
2025-06-25T00:00:00Z
Modified
2025-07-16T05:22:09Z
Severity
  • 5.0 (Medium) CVSS_V3 - CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:U/C:L/I:L/A:L CVSS Calculator
  • Ubuntu - medium
Summary
[none]
Details

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.

References

Affected packages

Ubuntu:24.04:LTS / libssh

Package

Name
libssh
Purl
pkg:deb/ubuntu/libssh@0.10.6-2ubuntu0.1?arch=source&distro=noble

Affected ranges

Type
ECOSYSTEM
Events
Introduced
0Unknown introduced version / All previous versions are affected
Fixed
0.10.6-2ubuntu0.1

Affected versions

0.*

0.10.5-3ubuntu1
0.10.5-3ubuntu2
0.10.6-2
0.10.6-2build1
0.10.6-2build2

Ecosystem specific

{
    "binaries": [
        {
            "binary_name": "libssh-4",
            "binary_version": "0.10.6-2ubuntu0.1"
        },
        {
            "binary_name": "libssh-4-dbgsym",
            "binary_version": "0.10.6-2ubuntu0.1"
        },
        {
            "binary_name": "libssh-dev",
            "binary_version": "0.10.6-2ubuntu0.1"
        },
        {
            "binary_name": "libssh-doc",
            "binary_version": "0.10.6-2ubuntu0.1"
        },
        {
            "binary_name": "libssh-gcrypt-4",
            "binary_version": "0.10.6-2ubuntu0.1"
        },
        {
            "binary_name": "libssh-gcrypt-4-dbgsym",
            "binary_version": "0.10.6-2ubuntu0.1"
        },
        {
            "binary_name": "libssh-gcrypt-dev",
            "binary_version": "0.10.6-2ubuntu0.1"
        }
    ],
    "availability": "No subscription required"
}

Ubuntu:25.04 / libssh

Package

Name
libssh
Purl
pkg:deb/ubuntu/libssh@0.11.1-1ubuntu0.1?arch=source&distro=plucky

Affected ranges

Type
ECOSYSTEM
Events
Introduced
0Unknown introduced version / All previous versions are affected
Fixed
0.11.1-1ubuntu0.1

Affected versions

0.*

0.10.6-3ubuntu1
0.11.1-1

Ecosystem specific

{
    "binaries": [
        {
            "binary_name": "libssh-4",
            "binary_version": "0.11.1-1ubuntu0.1"
        },
        {
            "binary_name": "libssh-4-dbgsym",
            "binary_version": "0.11.1-1ubuntu0.1"
        },
        {
            "binary_name": "libssh-dev",
            "binary_version": "0.11.1-1ubuntu0.1"
        },
        {
            "binary_name": "libssh-doc",
            "binary_version": "0.11.1-1ubuntu0.1"
        }
    ],
    "availability": "No subscription required"
}