CriticalCVE-2017-7494

    Samba Remote Code Execution Vulnerability (CVE-2017-7494)

    Published In CISA KEV since Sources: CVE.org, Schneider Electric

    What is affected, what to do

    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.

    The vulnerability is being actively exploited; treat it as a priority. CISA lists it as used in ransomware campaigns. Update samba to version 4.4.14. Immediate actions, mitigation and detection rules are in the runbook below.

    Affected
    • Samba eq since 3.5.0..since 3.5.0

    Not sure whether and how you are affected? Ask a question about this vulnerability

    Metrics

    9.8

    Priority

    XIEM Effective CVSS: highest available CVSS rating from NVD and vendor data.

    Source: NVD, CVSS v3

    9.8

    CVSS v3

    Severity Critical on the scale from 0 to 10.

    Source: CVE.org, Schneider Electric

    99.45 %

    EPSS score

    High — model estimates ≥ 50% chance of real-world exploitation within 30 days.

    Source: FIRST EPSS, percentile 99.94

    Show all metrics
    Severity
    Critical
    Priority (0–325)

    The priority score is a consolidated metric that condenses several individual signals into a single, action-guiding ranking: technical severity (CVSS), exploitation likelihood (EPSS), known-exploited status (KEV) and the context of the affected asset. The aim is to answer the only truly important question in vulnerability management: what first?

    Read in glossary
    253.90 Methodology
    Exploit maturity

    An exploit is code or a technique that specifically uses a concrete vulnerability to force unintended behaviour — such as executing code or escalating privileges. It is the tool that turns a theoretical flaw into a practical attack.

    Read in glossary
    actively exploited
    XIEM Effective CVSS

    XIEM® is the tiered managed-security operating model from NEOSEC and a registered trademark of NEOSEC GmbH. It extends classic SIEM — the central collection, normalisation and correlation of security-relevant events — with endpoint forensics, network visibility and deception technology, and consolidates them into three building tiers: Sentry, Orchestrate and Command.

    Read in glossary
    9.8 Methodology
    CVSS v3

    CVSS is the globally established, open standard for assessing the technical severity of a vulnerability on a scale from 0 to 10. It describes how easily a flaw can be exploited and what damage it can cause — but not how likely its actual exploitation is. CVSS and the complementary EPSS deliberately answer different questions.

    Read in glossary
    9.8
    EPSS score

    The EPSS score is the absolute model output for an individual vulnerability: the estimated probability of real-world exploitation within the next 30 days, expressed as a value between 0 and 1 (i.e. 0 % to 100 %). A score of 0.42 means „the model estimates a 42 % chance of real-world exploitation within 30 days“.

    Read in glossary
    99.45 %
    High — model estimates ≥ 50% chance of real-world exploitation within 30 days.
    EPSS percentile

    The EPSS percentile is the relative position of a vulnerability within all EPSS-scored CVEs, expressed as a value between 0 and 1. A percentile of 0.90 means „this CVE has a higher EPSS score than 90 % of all other scored CVEs“. Unlike the EPSS score, it is not a probability — but a positioning within a ranking.

    Read in glossary
    99.94
    Critical — this CVE ranks in the top fifth of all CVEs scored today (rank ≥ 80%).
    KEV status

    The KEV catalogue is a list maintained by the US authority CISA of vulnerabilities for which active exploitation in the wild has been confirmed. It answers not the question „how severe?“ but „is it already being attacked?“ — thereby sharply prioritising patching.

    Read in glossary
    Actively exploited
    Published
    In CISA KEV since

    The KEV catalogue is a list maintained by the US authority CISA of vulnerabilities for which active exploitation in the wild has been confirmed. It answers not the question „how severe?“ but „is it already being attacked?“ — thereby sharply prioritising patching.

    Read in glossary
    CISA assessment (SSVC)
    Exploitation: active · automatable · Technical impact: total
    Source: CISA Vulnrichment, as of 7 February 2025
    CWE

    CWE is a catalogue of typical weakness types in software and hardware — such as flawed input validation, unsafe memory handling or poor authentication. Where a CVE names a concrete vulnerability in a concrete product, a CWE describes the underlying class of defect.

    Read in glossary
    CWE-94

    Response and mitigation

    Why act now?

    Prioritisation rationale

    The flaw is exploitable over the network without authentication whenever a writable share is reachable, and a public Metasploit module makes exploitation trivial — it ranks among the CVEs most likely to be exploited at all. In the wild it has been used against Linux file servers and, at scale, against NAS and embedded devices for cryptomining and botnet recruitment, and CISA flags known use in ransomware campaigns. Treat any internet-reachable or guest-writable Samba host as critical and remediate immediately; internally segmented hosts that are patched or hardened with nt pipe support = no or noexec can follow in normal cycles, but long-lived embedded firmware means active inventorying is essential to avoid forgotten exposures.

    1. Runbook step 1

      Immediate response (0-24 h)

      • Inventory every Samba instance: Find all hosts exposing 445/TCP or 139/TCP (Linux file servers, NAS appliances, routers, embedded devices) and record versions via smbd -V or a network scan (nmap -p445 --script smb-os-discovery). Affected: everything from 3.5.0 before 4.4.14, 4.5.10 and 4.6.4.
      • Patch: Upgrade to Samba 4.6.4, 4.5.10 or 4.4.14 (or a newer supported branch), or install your distribution's backported packages (e.g. Debian 8 via the security repository). Branches 3.5.x through 4.3.x have no upstream fix — migrate to a supported branch or rely on a distro backport.
      • Immediate workaround if you cannot patch: Add nt pipe support = no to the [global] section of smb.conf and restart smbd. This may break some RPC-dependent features for Windows clients (e.g. share enumeration), so test first.
      • Remove internet exposure: Block 445/TCP and 139/TCP at the perimeter; pull internet-facing NAS/embedded devices offline or firewall them immediately.
      • Audit writable shares: List every share with writable = yes or guest access (guest ok = yes, map to guest = Bad User), revoke anonymous write, and hunt for unexpected .so/ELF files (find <share> -type f -exec file {} + | grep ELF).
      • If compromise is suspected: Isolate the host, capture a forensic image, and rotate credentials for service and machine accounts stored on it.
    2. Runbook step 2

      Mitigation layers

      • Network segmentation: Permit SMB only from defined client VLANs to the file-server segment; block server-to-server and OT/IoT-originated SMB. Move NAS and embedded devices into a dedicated VLAN with no internet egress.
      • Filesystem hardening: Place writable shares on separate filesystems mounted noexec — this stops uploaded shared libraries from being loaded out of the share path.
      • Mandatory access control: Run SELinux in enforcing mode (the stock RHEL/CentOS policy prevents smbd from loading modules from share paths) or apply an AppArmor profile to smbd; only enable booleans such as samba_export_all_rw where genuinely required.
      • Access control / least privilege: Disable guest access globally (map to guest = Never), restrict write to named authenticated groups (valid users, write list), set restrict anonymous = 2.
      • IPS/IDS: Enable vendor rules for SambaCry/is_known_pipename in your Suricata/Snort rulesets — pattern: SMB NT Create AndX / SMB2 Create against IPC$ with a pipe name containing an absolute path (/) or .so.
      • Unpatchable appliances: Check vendor firmware status; with no fix available, disable SMB on the device or decommission it.
    3. Runbook step 3

      Detection rules

      • Network (Zeek/Suricata): Named-pipe opens carrying a path — filter Zeek smb_files.log/dce_rpc.log for names containing / or ending in .so; SPL: index=zeek sourcetype=zeek_smb_files path="*IPC$*" (name="*/*" OR name="*.so").
      • File uploads: ELF binaries (magic 7f454c46) written to shares over SMB — alert on Zeek files.log with source=SMB and mime_type=application/x-executable or application/x-sharedlib.
      • Process ancestry (EDR/auditd): smbd spawning shells or downloaders (sh, bash, wget, curl, nc, python); auditd: -a always,exit -F arch=b64 -S execve -F ppid=<smbd> -k smbd_exec; Sigma shape: ParentImage|endswith: '/smbd' with Image|endswith: ['/sh','/bash','/wget','/curl'].
      • Library load from share path: Use EDR or Sysmon for Linux to flag smbd mapping .so files from share directories; add an auditd watch on share roots for newly created .so files (-w /srv/share -p wa -k share_write).
      • Post-exploitation: Unexplained CPU load and outbound connections to mining pools (Stratum, e.g. ports 3333/4444/5555), plus new cron jobs or services on file servers/NAS.

    Detection rules

    No NEOSEC detection rule is available for this vulnerability yet.

    Classification under NIS2 and CRA

    Rule-based classification from exploitation status and severity. It does not replace a case-by-case assessment.

    NIS2

    NIS2 is EU Directive (EU) 2022/2555 to raise the level of cybersecurity across the Union. It substantially broadens obligations compared with the first NIS directive: more sectors, mandatory risk management, staged reporting duties and personal accountability of senior management.

    Read in glossary
    Actively exploited: treat the vulnerability as a priority in vulnerability handling under Art. 21(2)(e) NIS2. If it is exploited in your environment, check the reporting obligation under Art. 23 (early warning within 24 hours).
    CRA

    The CRA is EU Regulation (EU) 2024/2847 setting horizontal cybersecurity requirements for „products with digital elements“ — from industrial controllers and software to connected consumer devices. For the first time manufacturers must ensure security across the entire product lifecycle, handle vulnerabilities and provide security updates.

    Read in glossary
    Since 11.09.2026, manufacturers of affected products with digital elements must report actively exploited vulnerabilities under Art. 14 CRA, with an early warning within 24 hours via ENISA's single reporting platform.
    ISO/IEC 27001

    ISO/IEC 27001 is the internationally leading standard for an information security management system (ISMS). It describes a risk-based, process-oriented framework to systematically plan, implement, review and improve information security.

    Read in glossary
    Control A.8.8, management of technical vulnerabilities: assess relevance to your systems, plan remediation and keep evidence.

    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.

    Source: NVD (NIST), schneider_csaf, cvelistv5, CISA KEV Catalog, CVE.org (MITRE)

    Affected products

    The following versions are affected. Older releases of the same product line are also vulnerable unless stated otherwise.

    Affected products
    Affected versionsFixed in
    Sambasamba
    • since 3.5.0
    • —
    sambasamba
    • 4.4.0 – < 4.4.14
    • 4.5.0 – < 4.5.10
    • 4.6.0 – < 4.6.4
    • 3.5.0 – < 4.4.0
    • 4.4.14
    • 4.5.10
    • 4.6.4
    • 4.4.0

    Vendors and products

    Affected operating systems

    Affected operating systems
    Linuxdebiandebian_linux8.0

    Weakness classes (CWE)

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

      Base

      The product constructs all or part of a code segment using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify the syntax or behavior of the intended code segment.

      Entry at MITRE CWE-94

    Public exploit references

    Publicly reported proof-of-concepts, exploit modules and detection templates for this vulnerability. NEOSEC links to the original sources only and does not provide any exploit code.

    Public exploit references
    CISA KEV CatalogCISA Known Exploited Vulnerability (opens in a new tab)cisa.govactively exploited
    Exploit-DBEDB-ID 42060 (opens in a new tab)exploit-db.comPoC (publicly reported)reported, not verified—
    Exploit-DBEDB-ID 42084 (opens in a new tab)exploit-db.comPoC (publicly reported)reported, not verified—
    PoC-in-GitHub (nomi-sec)vulhub-samba-cve-2017-7494 (opens in a new tab)github.comPoC (publicly reported)reported, not verified
    PoC-in-GitHub (nomi-sec)CVE-2017-7494 (opens in a new tab)github.comPoC (publicly reported)reported, not verified
    PoC-in-GitHub (nomi-sec)IS (opens in a new tab)github.comPoC (publicly reported)reported, not verified

    References & sources

    • securityfocus.com98636Vulnerability database, x_refsource_BID, Third-party advisory, Vulnerability database
    • debian.orgDSA-3860Vendor advisory, x_refsource_DEBIAN, Third-party advisory
    • exploit-db.com42084Exploit, x_refsource_EXPLOIT-DB, Third-party advisory, Vulnerability database
    • access.redhat.comRHSA-2017:1270Vendor advisory, x_refsource_REDHAT, Third-party advisory
    • samba.orgsamba/security/CVE-2017-7494.htmlx_refsource_CONFIRM, Patch, Vendor advisory
    • download.schneider-electric.comfiles?p_enDocType=Technical+leaflet&p_File_Name=SEVD-2018-095-0…x_refsource_MISC, Third-party advisory
    • access.redhat.comRHSA-2017:1390Vendor advisory, x_refsource_REDHAT, Third-party advisory
    • securitytracker.com1038552Vulnerability database, x_refsource_SECTRACK, Third-party advisory, Vulnerability database
    • access.redhat.comRHSA-2017:1273Vendor advisory, x_refsource_REDHAT, Third-party advisory
    • access.redhat.comRHSA-2017:1271Vendor advisory, x_refsource_REDHAT, Third-party advisory
    • security.gentoo.orgGLSA-201805-07Vendor advisory, x_refsource_GENTOO, Third-party advisory
    • h20566.www2.hpe.comhpsc/doc/public/display?docLocale=en_US&docId=emr_na-hpesbux037…x_refsource_CONFIRM, Third-party advisory
    • access.redhat.comRHSA-2017:1272Vendor advisory, x_refsource_REDHAT, Third-party advisory
    • security.netapp.comadvisory/ntap-20170524-0001x_refsource_CONFIRM, Third-party advisory
    • h20566.www2.hpe.comhpsc/doc/public/display?docLocale=en_US&docId=emr_na-hpesbns037…x_refsource_CONFIRM, Third-party advisory
    • exploit-db.com42060Exploit, x_refsource_EXPLOIT-DB, Third-party advisory, Vulnerability database
    • cisa.govknown-exploited-vulnerabilities-catalog?field_cve=CVE-2017-7494government-resource, US government resource
    Embed badge

    Show the severity and KEV status of this vulnerability on your site – with a link back here. The image is updated hourly.

    Badge preview for CVE-2017-7494
    <a href="https://intel.neosec.eu/en/cve/CVE-2017-7494"><img src="https://intel.neosec.eu/badge/cve/CVE-2017-7494.svg?lang=en" alt="CVE-2017-7494 – NEOSEC Intel" height="20"></a>