Skip to content
Server Security Center
KEVcritical9.8 Used in ransomware campaigns

CVE-2017-7494: Samba Remote Code Execution

Samba · listed in the CISA catalog of actively exploited vulnerabilities since 2023-03-30.

CVSS v3.1 (CVE record)
9.8
critical
EPSS (exploit probability, 30 days)
99.4%
among the highest 0.1% of all CVEs
Added to CISA KEV
2023-03-30
US federal due date 2023-04-20
Ubuntu priority
high

CVE-2017-7494 explained

CVE-2017-7494 is a remote code execution flaw in Samba from version 3.5.0 up to releases before 4.6.4, 4.5.10 and 4.4.14. A malicious client can upload a shared library to a writable share and make the Samba server load and execute it. It is listed in the CISA Known Exploited Vulnerabilities catalog with known ransomware use.

Impact

An unauthenticated attacker with network access to the Samba server can run code on it. This requires a share the attacker can write to. Exploitation needs low complexity and no user interaction. Successful exploitation gives high impact to confidentiality, integrity and availability of the server. CISA reports known use in ransomware campaigns.

Who is affected

The samba source package is affected on Ubuntu 14.04 LTS and Ubuntu 16.04 LTS. Both have fixed versions in the standard archive: 2:4.3.11+dfsg-0ubuntu0.14.04.8 for Ubuntu 14.04 LTS and 2:4.3.11+dfsg-0ubuntu0.16.04.7 for Ubuntu 16.04 LTS. Both releases are end of life and should be upgraded to a supported release.

Written with AI from the data on this page and checked against it automatically.

Official description

Samba since version 3.5.0 and before 4.6.4, 4.5.10 and 4.4.14 is vulnerable to remote code execution vulnerability, allowing a malicious client to upload a shared library to a writable share, and then cause the server to load and execute it.

CISA required action: Apply updates per vendor instructions.

CISA notes

Upstream versions (CVE record)

From the CVE record published by the vendor or CVE numbering authority.

  • samba
    Affected
    • since 3.5.0
    Fixed in
    not stated

    Version statement as published by the CNA (free text).

Ubuntu and Debian releases

A server is vulnerable if it has a package built from the listed source package installed in a version lower than the fixed version for its release.

What to do

  1. Update the samba package to at least the fixed version listed for your release.
  2. Restart the Samba services so they stop running the vulnerable code.
  3. Plan an upgrade of Ubuntu 14.04 LTS and 16.04 LTS systems to a supported release, as both are end of life.
  4. Review writable shares and remove write access that is not needed.
  5. Limit network access to Samba ports to trusted hosts only.

Written with AI from the data on this page and checked against it automatically.

Check and fix on a server

Run on each Ubuntu or Debian server. Replace samba with the source package from the table above.

1. Show installed packages built from the source package, with their versions

dpkg-query -W -f='${binary:Package} ${Version} ${source:Package}\n' | awk '$3=="samba"'

2. Compare each installed version with the fixed version for your release from the table

I=INSTALLED_VERSION; F=FIXED_VERSION   # replace both
dpkg --compare-versions "$I" lt "$F"; case $? in 0) echo vulnerable ;; 1) echo "fixed or newer" ;; *) echo "check the versions" ;; esac

3. Install the fix

sudo apt update && sudo apt install --only-upgrade $(dpkg-query -W -f='${binary:Package} ${source:Package}\n' | awk '$2=="samba"{print $1}')

Services keep running the old code until they are restarted – restart the affected service or check with needrestart.

CISA's assessment (SSVC)

Exploitation
Exploited in the wild
Automatable
Yes – attackers can automate it at scale
Technical impact
Total – full control of the component or total information disclosure

Weakness: CWE-94 Improper Control of Generation of Code ('Code Injection')

Questions about CVE-2017-7494

Is this vulnerability exploited in practice?
Yes. CISA added CVE-2017-7494 to its Known Exploited Vulnerabilities catalog on 2023-03-30 and notes known ransomware use. The required action is to apply updates per vendor instructions.
Does an attacker need credentials?
The CVSS vector lists no privileges required and no user interaction. The attack does require a writable share on the server where the attacker can upload a shared library.
Are my Ubuntu 14.04 LTS or 16.04 LTS servers safe after updating?
Installing 2:4.3.11+dfsg-0ubuntu0.14.04.8 or 2:4.3.11+dfsg-0ubuntu0.16.04.7 fixes this CVE once Samba is restarted. Both releases are end of life, so upgrade to a supported release.

Written with AI from the data on this page and checked against it automatically.

References

Data: CISA Known Exploited Vulnerabilities (public domain) · CVE Program records incl. CISA ADP enrichment · OSV.dev (CC BY 4.0) incl. Ubuntu and Debian security data · FIRST EPSS · endoflife.date. Updated automatically – facts last changed 2026-11-22. Always confirm with the vendor's or distribution's advisory before patching.