Security Advisory

CVE-2017-12240: Cisco IOS DHCP Relay Overflow RCE

Last updated:
  • CVE-2017-12240

CVE-2017-12240 is a buffer overflow in the DHCP relay subsystem of Cisco IOS and IOS XE: an unauthenticated attacker who sends a crafted DHCPv4 packet to a router, switch or CMTS acting as a DHCP relay agent can run code on it or make it reload. NVD scores it 9.8 and CISA KEV lists it as exploited. Cisco lists no workaround; upgrade.

Vulnerability summary

CVSS base score

9.8

Critical severity

EPSS score (FIRST)

13.8%

Probability of exploitation in the wild in the next 30 days

CISA KEV catalog

Yes

Listed as known exploited

Published

Vulnerability ID: CVE-2017-12240 · Source: NVD

Affected components

ComponentCPEVersion range
Cisco IOS and IOS XE Software configured as a DHCP relay agentcpe:2.3:o:cisco:ios:*:*:*:*:*:*:*:*NVD: IOS 12.2-15.6 (NVD lists no IOS XE CPE; Cisco names IOS XE); Cisco CSAF: 2,032 affected products. Fixed release per the Cisco IOS Software Checker

What does this mean for affected devices?

CVE-2017-12240 is a buffer overflow in the DHCP relay subsystem of Cisco IOS and IOS XE. Cisco says an unauthenticated remote attacker who sends a crafted DHCP version 4 packet can "execute arbitrary code and gain full control of the affected system" or make it reload. NVD scores it 9.8 (CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H), NVD CVSS v2 10.0, with CWE-119; CISA-ADP and Cisco's CSAF also give 9.8, while Cisco's CVE record names CWE-20, the CWE KEV uses (NVD, CVE record). NVD's configuration covers IOS 12.2 through 15.6 and lists no IOS XE CPE, although both the NVD description and Cisco name IOS XE.

Which Cisco devices are affected?

Cisco's advisory cisco-sa-20170927-dhcp, part of the September 2017 IOS and IOS XE bundle, covers devices running a vulnerable release that are configured as a DHCP relay agent. On routers and switches that means an ip helper-address in the configuration. Cable modem termination systems (CMTS) act as relay agents through cable helper-address; Cisco added them to the advisory on 2017-09-29. A device that returns nothing for show running-config | include ip helper-address (or cable helper-address on a CMTS) is not a relay agent. Cisco's CSAF lists 2,032 affected products, tracked as bugs CSCsm45390 and CSCuw77959 (Cisco CSAF).

How do I fix CVE-2017-12240?

Upgrade to the first fixed release that the Cisco IOS Software Checker returns; Cisco updated the checker with more fixed and non-vulnerable releases on 2018-02-12. Cisco states that "there are no workarounds that address this vulnerability", so a relay agent stays exposed until it runs a fixed image. Where a helper address is left over from an old design, removing it takes the device out of scope. Our guide on how to fix memory corruption in embedded firmware covers the bug class, and the CISA BOD 23-02 guide covers limiting what edge devices accept from untrusted networks.

Is CVE-2017-12240 exploited?

Cisco says that in March 2022 its PSIRT "became aware of additional attempted exploitation of this vulnerability in the wild". CISA added CVE-2017-12240 to the KEV catalog on 2022-03-03 with the action "Apply updates per vendor instructions." (due 2022-03-24; known ransomware campaign use: Unknown); it is still listed as of 2026-11-25 in catalog version 2026.11.24. FIRST EPSS gives 0.13773, the 96.58th percentile, in the 2026-11-24 dataset (FIRST EPSS). The IKEv2 denial of service from the same bundle, CVE-2017-12237, was added to KEV the same day, as were the IOS SNMP overflows such as CVE-2017-6743.

How to fix this class of issueThis advisory's weakness class is Memory corruption. Our practical guide covers how to detect, fix, verify and disclose it: How to fix memory corruption in embedded firmware.

Evidence

  • NVD: Analyzed; DHCP relay buffer overflow, crafted DHCPv4 packet, CSCsm45390, CSCuw77959; NVD Primary CVSS v3.1 9.8 AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H, NVD Primary CVSS v2 10.0; CISA-ADP Secondary 9.8; NVD CWE-119, Cisco CWE-20; CPE ios 12.2-15.6 only; published 2017-09-29; read 2026-11-25. — NVD
  • Cisco advisory v1.3 (2022-12-16): IOS and IOS XE configured as DHCP relay agent; ip helper-address; CMTS cable helper-address (v1.1, 2017-09-29); no workarounds; checker updated with new fixed releases (v1.2, 2018-02-12); March 2022 additional attempted exploitation in the wild. — Cisco Security Advisory cisco-sa-20170927-dhcp
  • Cisco CSAF 1.3.0: CVE-2017-12240 bugs CSCsm45390, CSCuw77959, 2,032 known-affected products, CVSS 3.0 9.8. — Cisco CSAF
  • CVE record: PUBLISHED, CNA Cisco, CWE-20, no CNA CVSS metric. — CVE.org
  • KEV catalog 2026.11.24: dateAdded 2022-03-03, due 2022-03-24, 'Apply updates per vendor instructions.', knownRansomwareCampaignUse Unknown, CWE-20; checked 2026-11-25. — CISA KEV
  • EPSS 0.13773, percentile 0.96581, dataset 2026-11-24, read 2026-11-25. — FIRST EPSS

Related advisories

Sources

  1. NVD
  2. Cisco Security Advisory: Cisco IOS and IOS XE Software DHCP Remote Code Execution Vulnerability
  3. Cisco CSAF: cisco-sa-20170927-dhcp
  4. CVE.org record CVE-2017-12240 (CNA: Cisco)
  5. CISA KEV
  6. FIRST EPSS

Frequently asked questions

Which devices are exposed to CVE-2017-12240?

Cisco IOS and IOS XE devices on a vulnerable release that are configured as a DHCP relay agent, which on routers and switches means an ip helper-address on an interface, and on a CMTS a cable helper-address. A device without either is not affected, per Cisco.

Is there a workaround for CVE-2017-12240?

No. Cisco states there are no workarounds. The fix is an upgrade to the first fixed release from the Cisco IOS Software Checker. Removing helper addresses that are no longer needed takes a device out of scope.

Does CVE-2017-12240 need authentication?

No. NVD scores it with no privileges and no user interaction (9.8), and Cisco describes the attacker as unauthenticated and remote: one crafted DHCPv4 packet processed by the relay agent is enough.

Is CVE-2017-12240 exploited in the wild?

Yes. Cisco reports additional attempted exploitation seen in March 2022, and CISA KEV has listed it since 2022-03-03. FIRST EPSS gives 0.13773 (96.58th percentile) in the 2026-11-24 dataset, as of 2026-11-25.