Double Free Affecting libssh package, versions [0.10.0,0.11.2)


Severity

Recommended
0.0
low
0
10

CVSS assessment by Snyk's Security Team. Learn more

Threat Intelligence

EPSS
0.03% (7th percentile)

Do your applications use this vulnerable package?

In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.

Test your applications

Snyk Learn

Learn about Double Free vulnerabilities in an interactive lesson.

Start learning
  • Snyk IDSNYK-UNMANAGED-LIBSSH-10753751
  • published16 Jul 2025
  • disclosed24 Jun 2025
  • creditRonald Crane

Introduced: 24 Jun 2025

NewCVE-2025-5351  (opens in a new tab)
CWE-415  (opens in a new tab)

How to fix?

Upgrade libssh to version 0.11.2 or higher.

Overview

Affected versions of this package are vulnerable to Double Free via the pki_key_to_blob() function when built with OpenSSL versions older than 3.0. The issue can lead to heap corruption or application instability during error handling in low-memory environments.

Workaround

This vulnerability can be mitigated by building the library against OpenSSL version 3.0 or later.

CVSS Base Scores

version 4.0
version 3.1