Description
Canonical snapd before version 2.37.1 incorrectly performed socket owner validation, allowing an attacker to run arbitrary commands as root. This issue affects: Canonical snapd versions prior to 2.37.1.
Affected products
| Vendor | Product | Affected | Fixed |
|---|---|---|---|
| Canonical | snapd | unspecified – < 2.37.1 | 2.37.1 |
Fixed in Linux distributions
Distributions backport fixes, so the version that fixes this vulnerability differs per release — upgrade to at least the version shown. From the distributions' security trackers and advisories.
Debian
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Debian 14 | snapd | 2.37.1-1 | — |
| Debian 13 | snapd | 2.37.1-1 | — |
| Debian 12 | snapd | 2.37.1-1 | — |
Ubuntu
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Ubuntu 18.04 LTS | snapd | 2.34.2+18.04.1 | USN-3887-1 |
| Ubuntu 16.04 LTS | snapd | 2.34.2ubuntu0.1 | USN-3887-1 |
| Ubuntu 14.04 LTS | snapd | 2.34.2~14.04.1 | USN-3887-1 |
Public exploits
Exploit or proof-of-concept code for this vulnerability is publicly available, which lowers the bar for attackers. Treat it as a reason to patch sooner.
Exploit-DB 2
- snapd < 2.37 (Ubuntu) - 'dirty_sock' Local Privilege Escalation (1) EDB-46361 · local · Feb 13, 2019
- snapd < 2.37 (Ubuntu) - 'dirty_sock' Local Privilege Escalation (2) EDB-46362 · local · Feb 13, 2019
GitHub 5 repositories
-
initstring/dirty_sock ★ 680 · Feb 12, 2019
Linux privilege escalation exploit via snapd (CVE-2019-7304)
-
SecuritySi/CVE-2019-7304_DirtySock ★ 6 · Feb 14, 2019
Payload Generator
-
f4T1H21/dirty_sock ★ 1 · Jul 28, 2021
Local Privilege Escalation via snapd (CVE-2019-7304) Remastered PoC exploit
-
elvi7major/snap_priv_esc ★ 1 · Mar 28, 2021
Another implementation for linux privilege escalation exploit via snap(d) (CVE-2019-7304)
-
Kaine105/Document-Linux-Privilege-Escalation ★ 0 · Jun 11, 2025
Exploiting the vulnerability called "Dirty_Sock" (CVE-2019-7304) in the REST API for Canonical's snapd daemon.
Sources: PoC-in-GitHub, Metasploit Framework, Exploit-DB — updated daily. Only links are listed; no exploit code is hosted here.
Advisories 1
- USN-3887-1 snapd vulnerability Ubuntu Security Notices (USN) · Feb 10, 2026