Heap-based Buffer Overflow Affecting socat package, versions <1.8.0.0-4ubuntu0.1


Severity

Recommended
medium

Based on Ubuntu security rating.

Threat Intelligence

EPSS
0.31% (23rd 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 IDSNYK-UBUNTU2404-SOCAT-17534262
  • published7 Jul 2026
  • disclosed25 Jun 2026

Introduced: 25 Jun 2026

CVE-2026-56123  (opens in a new tab)
CWE-122  (opens in a new tab)

How to fix?

Upgrade Ubuntu:24.04 socat to version 1.8.0.0-4ubuntu0.1 or higher.

NVD Description

Note: Versions mentioned in the description apply only to the upstream socat package and not the socat package as distributed by Ubuntu. See How to fix? for Ubuntu:24.04 relevant fixed versions and status.

socat versions 1.8.0.0 through 1.8.1.1 contain a heap-based buffer overflow vulnerability that allows a malicious SOCKS5 proxy server to overwrite adjacent heap memory by exploiting a sign-extension flaw in the DOMAINNAME reply parser. During connection setup, the domain name length byte is read through a signed char field causing a negative bytes_to_read value that is implicitly converted to size_t, resulting in an unbounded heap write into the 262-byte reply buffer with attacker-controlled size and content.

CVSS Base Scores

version 3.1