CVE-2026-87690
Metasploit Framework ios_image_gather Path Traversal Leading to Arbitrary File Write and Code Execution
- High 8.8
Description
The Metasploit Framework post module post/apple_ios/gather/ios_image_gather is affected by a relative path traversal vulnerability (CWE-22). The module interpolates file names taken from a Meterpreter directory listing — data fully controlled by a hostile or tampered iOS device — directly into the local destination path passed to client.fs.file.download_file(), with no sanitization. The underlying stdapi sink (lib/rex/post/meterpreter/extensions/stdapi/fs/file.rb) writes to whatever path is supplied, so a listing entry such as ../../msfconsole.rc escapes the intended ~/.msf4/loot/<random> directory and overwrites ~/.msf4/msfconsole.rc, a resource file that every msfconsole invocation automatically executes at startup (lib/msf/ui/console/driver.rb:196). An attacker-controlled device that lures an operator into running this gather module achieves an arbitrary file write as the operator; because the written msfconsole.rc can load a second written file (a Ruby plugin whose top-level code runs on require), this converts into persistent code execution and an interactive shell as the operator (frequently root) on the pentester's workstation at the next console launch. The same traversal was previously fixed upstream in the recursive downloader (stdapi/fs/dir.rb scrubs separators); this module omitted the equivalent scrub. The fix applies the same separator scrub (or File.basename) to listing entries before building the local path.
Key facts
- Published
- 12 Oct 2026
- Last changed
- 14 Oct 2026
- Assigned by
- rapid7
- EPSS
- 0.411% likely to be exploited in the next 30 days, higher than 36.046% of CVEs (scores for 18 Nov 2026)
- SSVC (CISA)
- Exploitation: none; Automatable: no; Technical impact: total
Severity scores
Each score is shown as its source gave it. They are not averaged or merged.
- 8.8CVSS 3.1, Highfrom the CNA (rapid7)
CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H
Historical context and remediation
This reference retains the original CVE publication date. A recent record update does not mean a new attack occurred.
No separately sourced impact summary is available on this page yet. Consult the description, version data and dated exploitation evidence.
No explicit remediation statement is available on this page yet. Consult the original record and vendor references before choosing a fix.
Version statuses below come from the CNA. An “unaffected” version is not necessarily a currently supported release or proof of a patch date. EPSS is a dated risk estimate, not a count of historical attacks.
Affected products
| Vendor | Product | Versions |
|---|---|---|
| Rapid7 | Metasploit Framework |
|
Timeline
- 27 Aug 2026 Vulnerability reported to Rapid7
- 2 Sep 2026 Rapid7 acknowledged receipt and forwarded to the Metasploit team
- 10 Sep 2026 Vulnerability confirmed legitimate; CVE-2026-87690 reserved
- 23 Sep 2026 Fix released in Metasploit Framework 6.5.5
- 12 Oct 2026 Published
Weakness
Practice this bug class
HackZoneLabs has a hands-on lab on Path traversal (CWE-22).