Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.
Sources: National Vulnerability Database, CISA KEV, Exploit-DB
CVE-2026-113395 Overview
CVE-2026-113395 is a path traversal vulnerability in the DrayTek Vigor2960 router firmware version 1.5.1.6 Revision 8218. The flaw resides in the cgiEscape function of /cgi-bin/mainfunction.cgi within the swmconfigupload component. An attacker who manipulates the multipart argument can traverse directories outside the intended upload path. The exploit code has been published, and the vulnerability can be triggered remotely over the network. DrayTek has released firmware version 1.5.1.7 to resolve the issue. The vendor notes that the Vigor2960 is End-of-Sale with limited support, and only major issues such as unauthenticated vulnerabilities will be reviewed going forward.
Critical Impact
Authenticated remote attackers can write files to arbitrary locations on the device filesystem through the swmconfigupload endpoint, enabling potential configuration clobbering [CWE-22].
Affected Products
- DrayTek Vigor2960 firmware 1.5.1.6 Revision 8218
- DrayTek Vigor2960 (End-of-Sale device line)
- Any Vigor2960 deployment prior to firmware 1.5.1.7
Discovery Timeline
- 2026-10-20 - CVE-2026-113395 published to NVD
- 2026-10-20 - Last updated in NVD database
Technical Details for CVE-2026-113395
Vulnerability Analysis
The vulnerability resides in the cgiEscape function used by the swmconfigupload handler inside /cgi-bin/mainfunction.cgi. The handler processes multipart form uploads but fails to sanitize the fieldname component of the multipart argument. An authenticated attacker can embed directory traversal sequences in the field name to write files to paths outside the intended upload directory. Public analysis of this issue, catalogued as DRV2960-0012, describes it as an authenticated swmconfigupload fieldname path traversal and file clobber condition. See the GitHub Security Analysis case file for the full technical breakdown.
Root Cause
The cgiEscape function does not validate or canonicalize the fieldname extracted from multipart requests before using it as part of a filesystem path. Because traversal sequences are not stripped, the resulting path can escape the designated upload directory. This is a classic improper limitation of a pathname to a restricted directory, tracked under [CWE-22].
Attack Vector
Exploitation requires network access to the device web interface and low-privileged authenticated access. The attacker submits a crafted multipart POST request to /cgi-bin/mainfunction.cgi targeting the swmconfigupload action. The malicious multipart field name contains traversal sequences that redirect the write operation to an attacker-chosen path. Public exploit information is referenced in the VulDB CVE-2026-113395 entry.
No verified exploit code is reproduced here. The referenced advisory describes the vulnerable fieldname parsing in detail.
Detection Methods for CVE-2026-113395
Indicators of Compromise
- POST requests to /cgi-bin/mainfunction.cgi referencing the swmconfigupload action with multipart field names containing ../ or encoded traversal sequences.
- Unexpected file creation or modification outside the standard configuration upload directories on the Vigor2960.
- Authenticated web sessions originating from untrusted or geographically anomalous source IP addresses prior to configuration changes.
Detection Strategies
- Inspect HTTP logs on the device or upstream proxies for multipart requests to mainfunction.cgi where the name= attribute of a form part contains directory traversal characters.
- Correlate successful web authentications with subsequent swmconfigupload calls and compare against change-management records.
- Monitor firmware integrity and configuration file hashes to identify unauthorized overwrites consistent with path traversal clobber behavior.
Monitoring Recommendations
- Forward Vigor2960 syslog and web administration logs to a centralized logging platform for retention and analytics.
- Alert on administrative logins from new source networks, especially those followed by configuration upload actions.
- Review device CPU, storage, and process state for anomalies that may indicate attacker-written artifacts.
How to Mitigate CVE-2026-113395
Immediate Actions Required
- Upgrade affected Vigor2960 devices to firmware 1.5.1.7 using the official DrayTek Vigor2960 Firmware package.
- Restrict access to the device web administration interface to trusted management networks only.
- Rotate administrative credentials on all Vigor2960 devices after patching to invalidate any that may have been exposed.
- Plan device replacement, as the Vigor2960 line is End-of-Sale with limited vendor support.
Patch Information
DrayTek has published Vigor2960 firmware 1.5.1.7, which the vendor states corrects multiple security issues including this path traversal. Because the product is End-of-Sale, DrayTek has indicated that only major issues such as unauthenticated vulnerabilities will receive further review. Organizations should treat this patch as the final remediation path and plan hardware replacement for ongoing security coverage.
Workarounds
- Block external access to /cgi-bin/mainfunction.cgi at the network perimeter when the web UI must remain reachable internally.
- Enforce strong, unique administrative credentials and enable multi-factor authentication on any upstream access control layer protecting the device.
- Place the device behind a VPN or jump host so that only authenticated internal operators can reach the management interface.
Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.
Sources: National Vulnerability Database, CISA KEV, Exploit-DB

