Vulnerabilities / CVE-2026-56123

critical

CVE-2026-56123

socat: Socat: Heap-based buffer overflow allows arbitrary code execution via malicious SOCKS5 proxy server

Published Modified CWE 122
In the Trivy database since at least 24 Oct 2026, 07:11 UTCWhen it arrived before that build is not recorded.

Severity by source

NVD9.8CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
Red Hat8.1CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H

Trivy's own label is CRITICAL. Rated critical by NVD. Rated lower by Red Hat (high), Ubuntu (medium).

Description

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.

Affected packages and fixed versions

SourcePackageFixed in
alpine 3.21socat1.8.1.2-r0
alpine 3.22socat1.8.1.2-r0
alpine 3.23socat1.8.1.2-r0
alpine 3.24socat1.8.1.2-r0
alpine edgesocat1.8.1.2-r0
debian 13socat1.8.0.3-1+deb13u1
debian 14socat1.8.1.3-1
echosocat1.8.1.3-1
rapidfort alpine 3.20socat1.8.0.3-r0
rapidfort alpine 3.23socat1.8.0.3-r0
rapidfort debian 12socat0:1.8.0.3-1+deb13u1, 0:1.8.1.3-1
rapidfort debian 13socat0:1.8.0.3-1+deb13u1, 0:1.8.1.3-1
Show all 21 entries from 18 sources
SourcePackageFixed in
alpine 3.21socat1.8.1.2-r0
alpine 3.22socat1.8.1.2-r0
alpine 3.23socat1.8.1.2-r0
alpine 3.24socat1.8.1.2-r0
alpine edgesocat1.8.1.2-r0
debian 13socat1.8.0.3-1+deb13u1
debian 14socat1.8.1.3-1
echosocat1.8.1.3-1
rapidfort alpine 3.20socat1.8.0.3-r0
rapidfort alpine 3.23socat1.8.0.3-r0
rapidfort debian 12socat0:1.8.0.3-1+deb13u1, 0:1.8.1.3-1
rapidfort debian 13socat0:1.8.0.3-1+deb13u1, 0:1.8.1.3-1
rapidfort fedora 43socat1.8.1.3-1.fc43
rapidfort ubuntu 20.04rf-socat0:1.8.0.0-4ubuntu0.1, 0:1.8.1.1-1ubuntu0.1
rapidfort ubuntu 20.04socat0:1.8.0.0-4ubuntu0.1, 0:1.8.1.1-1ubuntu0.1
rapidfort ubuntu 22.04rf-socat0:1.8.0.0-4ubuntu0.1, 0:1.8.1.1-1ubuntu0.1
rapidfort ubuntu 22.04socat0:1.8.0.0-4ubuntu0.1, 0:1.8.1.1-1ubuntu0.1
rapidfort ubuntu 24.04rf-socat0:1.8.0.0-4ubuntu0.1, 0:1.8.1.1-1ubuntu0.1
rapidfort ubuntu 24.04socat0:1.8.0.0-4ubuntu0.1, 0:1.8.1.1-1ubuntu0.1
ubuntu 24.04socat1.8.0.0-4ubuntu0.1
ubuntu 26.04socat1.8.1.1-1ubuntu0.1

References

Vulnerability data compiled from the Trivy vulnerability database (trivy-db, Aqua Security, Apache License 2.0), which aggregates third-party advisories. CVE records are published by The MITRE Corporation under the CVE Terms of Use; CVE is a trademark of MITRE. This product uses data from the NVD API but is not endorsed or certified by the NVD. Severity, titles and advisory data from the GitHub Advisory Database (CC BY 4.0), Red Hat security data (CC BY 4.0) and the other sources linked on each entry. Entries may be summarised or re-formatted; the linked original is the authoritative record.