CVE-2024-12987
DrayTek Vigor Routers OS Command Injection Vulnerability
- Actively exploited
- Medium · 6.9 of 10
- Exploited since
- 15 May 2025 added to the CISA list
- Chance of attacks
- 98% in the next 30 days (FIRST EPSS)
- Fix deadline
- 5 Jun 2025 for US federal agencies
- Published
- 27 Dec 2024 in the NVD
What this means
DrayTek Vigor2960, Vigor300B, and Vigor3900 routers contain an OS command injection vulnerability due to an unknown function of the file /cgi-bin/mainfunction.cgi/apmcfgupload of the component web management interface.
CISA
A vulnerability, which was classified as critical, was found in DrayTek Vigor2960 and Vigor300B 1.5.1.4. Affected is an unknown function of the file /cgi-bin/mainfunction.cgi/apmcfgupload of the component Web Management Interface. The manipulation of the argument session leads to os command injection. It is possible to launch the attack remotely. The exploit has been disclosed to the public and may be used. Upgrading to version 1.5.1.5 is able to address this issue. It is recommended to upgrade the affected component.
NIST National Vulnerability Database
What to do
Apply mitigations per vendor instructions, follow applicable BOD 22-01 guidance for cloud services, or discontinue use of the product if mitigations are unavailable.
CISA's required action. If you use the product, install the vendor's update as soon as possible.
Affected
- DrayTek Vigor2960
- DrayTek Vigor300B
Official sources
- nvd.nist.gov/vuln/detail/CVE-2024-12987
- netsecfish.notion.site/Command-Injection-in-apmcfgupload-endpoint-for-DrayTek-Gateway-Devi...
- vuldb.com/?ctiid.289380
- vuldb.com/?id.289380
- vuldb.com/?submit.468795
- fw.draytek.com.tw/Vigor2960/Firmware/v1.5.1.5/DrayTek_Vigor2960_V1.5.1.5_01release-note.pd...
- fw.draytek.com.tw/Vigor300B/Firmware/v1.5.1.5/DrayTek_Vigor300B_V1.5.1.5_01release-note.pd...
- fw.draytek.com.tw/Vigor3900/Firmware/v1.5.1.5/DrayTek_Vigor3900_V1.5.1.5_01release-note.pd...
- cisa.gov/known-exploited-vulnerabilities-catalog?field_cve=CVE-2024-12987
Data from the NIST National Vulnerability Database, the CISA Known Exploited Vulnerabilities list, FIRST EPSS and ENISA, checked 18 Nov 2026. CVSS vector CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:L/VI:L/VA:L/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:.