NmapApplication

CVE-2018-1000161

MEDIUM · 5.7 CVSS v3.0 Published 2018-04-18
Mitigation only
No fix yet — a mitigation exists. There is no fixed release. A documented workaround reduces exposure in the meantime.
See remediation →
61/100
Remediation priority · Elevated
Remotely reachable

Official description Straight from the sourceThe vendor's or NVD's own wording, published unedited. Authoritative, but often terse — it says what broke, rarely what to do.

NVD · unedited
nmap version 6.49BETA6 through 7.60, up to and including SVN revision 37147 contains a Directory Traversal vulnerability in NSE script http-fetch that can result in file overwrite as the user is running it. This attack appears to be exploitable via a victim that runs NSE script http-fetch against a malicious web site. This vulnerability appears to have been fixed in 7.7.

Technical summary Written by usOur analysis, written from the advisory, the CVSS vector and the affected-version data. It adds context the advisory leaves out, and never invents facts that are not in the source.

dbcve analysis · high confidence

A directory traversal vulnerability exists in nmap's NSE (Nmap Scripting Engine) http-fetch script versions 6.49BETA6 through 7.60 (up to SVN revision 37147). When a user runs the http-fetch script against a malicious website, the attacker can use path traversal sequences (e.g., ../) in the response to write files to arbitrary locations on the victim's filesystem, overwriting existing files with the privileges of the user running nmap.

MitigationUpgrade nmap to version 7.7 or later. Until then, avoid running the http-fetch NSE script against untrusted or unknown websites, and run nmap with minimal necessary privileges to limit the impact of file overwrite attacks.

Verify against the referenced sources before acting — the references below are authoritative for this CVE, this summary is not.

Affected products & versions What the vendor confirmedThe version ranges the vendor confirmed as vulnerable. If your version sits inside a range here, treat yourself as exposed until you have upgraded.

NVD · CPE data
NmapApplication
Affected:= 6.49= 7.00= 7.01= 7.10= 7.11= 7.12= 7.25= 7.30= 7.31= 7.40= 7.50= 7.60

CVSS breakdown How the score is builtThe industry scoring standard. It rates how the flaw is reached, what it takes to exploit, and what an attacker gains — the score is derived from those, not the other way round.

From the vector
Attack vector
Network
Complexity
Low
Privileges
Low
User interaction
Required
Scope
Unchanged
Confidentiality
None
Integrity
High
Availability
None

CVSS:3.0/AV:N/AC:L/PR:L/UI:R/S:U/C:N/I:H/A:N

Am I affected? How to checkSteps we derive from the advisory and the affected-version data, so you can decide whether this CVE reaches your setup. They are a guide, not a scan — your own configuration is the authority.

dbcve checks

Work through these to decide whether this CVE applies to you.

  1. Check installed nmap version
    Run 'nmap --version' or 'nmap -V' to retrieve the installed version number
    Affected if The version listed is 6.49BETA6, 7.00, 7.01, 7.10, 7.11, 7.12, 7.25, 7.30, 7.31, 7.40, 7.50, or 7.60 (or any version between 6.49BETA6 and 7.60)
  2. Locate http-fetch script
    Find the http-fetch.nse script in the nmap scripts directory, typically at $(nmap --script-path 2>/dev/null)/http-fetch.nse or in the nmap installation under scripts/ directory
    Affected if The http-fetch script exists in the nmap installation and the nmap version is in the affected range
  3. Verify script is executable
    Check if the http-fetch script has execute permissions with 'ls -la' on the script file
    Affected if The script is present and executable, and nmap version is in the affected range
  4. Review nmap usage logs or history
    Check shell history, system logs, or any recorded nmap command executions for usage of 'nmap --script http-fetch' or 'nmap -sC' if http-fetch was loaded
    Affected if The http-fetch script was run against any website, especially untrusted or unknown ones, on an affected nmap version
  5. Check for suspicious newly created or modified files
    Review filesystem for unexpected file creations or modifications, particularly in system directories or sensitive locations, that coincide with nmap http-fetch execution times
    Affected if Files were created or overwritten outside the intended download directory after running http-fetch, indicating exploitation

You are affected if you run nmap version 6.49BETA6 through 7.60 and have executed the http-fetch script against a website, as the directory traversal flaw allows arbitrary file writes.

Generated from the published advisory. Verify against your own configuration.

Check your environment

Paste your version and any relevant configuration and it will be compared against the affected criteria above. Do not include secrets or credentials.

AI-assisted, checked against the advisory. Informational, not a guarantee.

Remediation Closing itWhat it takes to close this. Where a vendor fix exists we point at it; where none exists we say so plainly, and can build one. Effort estimates are scoped from the advisory, not from your codebase.

From vendor data
Mitigation available No clean upgrade yet — mitigate in the meantime
Mitigation

Upgrade nmap to version 7.7 or later. Until then, avoid running the http-fetch NSE script against untrusted or unknown websites, and run nmap with minimal necessary privileges to limit the impact of file overwrite attacks.

Fix this in Nmap Scoped from the published advisory
  • Consultation1.0 h
  • Implementation2.0 h
  • Testing1.0 h
  • Review / QA1.0 h
5.0 hours of engineering $890
Get help mitigating

An estimate, not a bill — we confirm scope with you before any work starts. Need it this week? Rush from $1,424.

Scan for this in your stack

Free · runs locally
dbcve dependency scanner

Check whether your project pulls in CVE-2018-1000161 — or any other known-vulnerable package — straight from your lock files. Free and open source; it runs locally and uploads nothing.

References Go to the primary sourcePrimary sources — vendor advisories, patches and trackers. Where our summary and a reference disagree, the reference wins.

Primary sources

Practitioner notes

Contributed

Peer-ranked notes from engineers who’ve handled CVE-2018-1000161 in production — separate from our analysis above.

No notes yet

Be the first to add a field note for this CVE — a mitigation you’ve verified, a version caveat, or a link to a working fix. Sign in above to contribute.

What this is

A place for practitioners to share what actually worked: a mitigation you’ve tested, a configuration change, a version- or environment-specific caveat, or a link to a verified patch. The most useful notes rise to the top as peers upvote them, so the signal stays high.

What belongs here
  • Verified mitigations, workarounds, and config changes
  • Version or environment caveats, and links to real fixes
  • No weaponised exploit code, or anything meant to cause harm
  • No spam, self-promotion, credentials, or personal data