Description
The DHCPv4 client in subsys/net/lib/dhcpv4/dhcpv4.c maintained its transaction identifier (iface->config.dhcpv4.xid) as a counter rather than as a per-transaction random value. It was seeded once with sys_rand32_get() in dhcpv4_start_internal(), incremented by one in dhcpv4_send_discover() and dhcpv4_send_decline(), and never changed by dhcpv4_send_request() — so every RENEWING and REBINDING exchange reused, unchanged, the identifier that had already appeared on the wire in the broadcast DHCPDISCOVER at boot, and where the identifier did move it moved predictably by one. RFC 2131 4.1 requires a single identifier per transaction, chosen so that clients are unlikely to collide.

This identifier is the client's only unpredictable reply-validation token. net_dhcpv4_input() accepts a BOOTP reply on op, a matching xid, and a matching chaddr (the interface MAC, which is public); the UDP callback is registered with a wildcard remote address and port, and no server-identifier or source-address check is applied. An attacker who learns one identifier — for example any host on the same segment that sees the broadcast DHCPDISCOVER, or a DHCP server or relay on a network the device previously joined — therefore retains a valid token for the device's whole uptime, and can predict the identifiers of later exchanges, without having to observe the unicast renew traffic or race the legitimate server.

A forged reply that passes those checks has effect regardless of client state, because dhcpv4_parse_options() applies its side effects before the state machine gate in dhcpv4_handle_reply(): the router option calls net_if_ipv4_set_gw() and the DNS option calls dns_resolve_reconfigure(). A single accepted datagram can thus repoint the device's default gateway and resolvers at attacker-controlled addresses, redirecting its traffic; during RENEWING or REBINDING a forged DHCPACK re-binds the lease with attacker-chosen parameters and a forged DHCPNAK removes the address and restarts configuration.

The fix draws a fresh sys_rand32_get() value at each point where a transaction begins — entering SELECTING, RENEWING and REBINDING, and at the INIT/INIT-REBOOT entry taken when an interface with a lease goes down — while REQUESTING and DECLINE keep the identifier of the exchange they belong to, as RFC 2131 requires. As a side effect the client also no longer discards a slow server's offer after retransmitting a discover, and the initial-discover backoff now draws its own randomness instead of deriving it from the identifier.
Published: 2026-10-23
Score: 5.6 Medium
EPSS: n/a
KEV: No
Impact: Unauthorized device configuration via spoofed DHCP responses, enabling an attacker to redirect traffic by changing gateway and DNS settings
Action: Apply Patch
AI Analysis

Impact

The vulnerability lies in the DHCPv4 client using a predictable, counter‑based transaction identifier rather than a random value per transaction. This identifier is reused across RENEWING and REBINDING exchanges and is only seeded once when the client starts. Because the client accepts a DHCP reply if the transaction ID and MAC address match, an attacker who learns a single identifier—by observing a broadcast DHCPDISCOVER or by having prior network access—can forge subsequent replies. Such forged packets can inject gateway or DNS options, reconfigure the device’s networking stack, and disrupt connectivity. The weakness is a misuse of cryptographic randomness (CWE‑340).

Affected Systems

Devices running the Zephyr RTOS, particularly those using the DHCPv4 client implementation in subsys/net/lib/dhcpv4/dhcpv4.c. The vulnerability applies to any Zephyr build using the default DHCP client behavior before the recent update that introduces per‑transaction random identifiers.

Risk and Exploitability

The CVSS score is 5.6, indicating a moderate impact. The EPSS score is not available, so the current exploitation probability cannot be quantified from public data, and the vulnerability is not listed in the CISA KEV catalog. The likelihood of exploitation is facilitated by the fact that any host on the same broadcast domain can capture a DHCPDISCOVER and thus learn the transaction ID. No special privileges or credentials are required on the target device. An attacker can exploit the flaw by sending a single forged DHCPACK containing malicious gateway or DNS options; the client will accept it because the packet satisfies the existing validation checks. This can be performed repeatedly during RENEWING or REBINDING phases or by sending a DHCPNAK to force reconfiguration.

Generated by OpenCVE AI on October 23, 2026 at 21:51 UTC.

Remediation

No solution or workaround provided in the CVE record.

OpenCVE Recommended Actions

  • Upgrade the Zephyr firmware to a version that includes the recent commit which generates a fresh random transaction ID for each new DHCP transaction.
  • Validate that the DHCP client is using per‑transaction random identifiers by observing DHCP logs or performing controlled tests after the upgrade.
  • Implement network‑level controls—such as enabling DHCP snooping on switches and enforcing VLAN segmentation—to limit the impact of rogue DHCP traffic.

Generated by OpenCVE AI on October 23, 2026 at 21:51 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories yet.

History

Fri, 23 Oct 2026 20:15:00 +0000

Type Values Removed Values Added
Description The DHCPv4 client in subsys/net/lib/dhcpv4/dhcpv4.c maintained its transaction identifier (iface->config.dhcpv4.xid) as a counter rather than as a per-transaction random value. It was seeded once with sys_rand32_get() in dhcpv4_start_internal(), incremented by one in dhcpv4_send_discover() and dhcpv4_send_decline(), and never changed by dhcpv4_send_request() — so every RENEWING and REBINDING exchange reused, unchanged, the identifier that had already appeared on the wire in the broadcast DHCPDISCOVER at boot, and where the identifier did move it moved predictably by one. RFC 2131 4.1 requires a single identifier per transaction, chosen so that clients are unlikely to collide. This identifier is the client's only unpredictable reply-validation token. net_dhcpv4_input() accepts a BOOTP reply on op, a matching xid, and a matching chaddr (the interface MAC, which is public); the UDP callback is registered with a wildcard remote address and port, and no server-identifier or source-address check is applied. An attacker who learns one identifier — for example any host on the same segment that sees the broadcast DHCPDISCOVER, or a DHCP server or relay on a network the device previously joined — therefore retains a valid token for the device's whole uptime, and can predict the identifiers of later exchanges, without having to observe the unicast renew traffic or race the legitimate server. A forged reply that passes those checks has effect regardless of client state, because dhcpv4_parse_options() applies its side effects before the state machine gate in dhcpv4_handle_reply(): the router option calls net_if_ipv4_set_gw() and the DNS option calls dns_resolve_reconfigure(). A single accepted datagram can thus repoint the device's default gateway and resolvers at attacker-controlled addresses, redirecting its traffic; during RENEWING or REBINDING a forged DHCPACK re-binds the lease with attacker-chosen parameters and a forged DHCPNAK removes the address and restarts configuration. The fix draws a fresh sys_rand32_get() value at each point where a transaction begins — entering SELECTING, RENEWING and REBINDING, and at the INIT/INIT-REBOOT entry taken when an interface with a lease goes down — while REQUESTING and DECLINE keep the identifier of the exchange they belong to, as RFC 2131 requires. As a side effect the client also no longer discards a slow server's offer after retransmitting a discover, and the initial-discover backoff now draws its own randomness instead of deriving it from the identifier.
Title Predictable and reused DHCPv4 transaction identifier allows spoofed DHCP replies to reconfigure gateway and DNS
Weaknesses CWE-340
References
Metrics cvssV3_1

{'score': 5.6, 'vector': 'CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:L/I:L/A:L'}


Subscriptions

No data.

cve-icon MITRE

Status: PUBLISHED

Assigner: zephyr

Published:

Updated: 2026-10-23T19:56:17.213Z

Reserved: 2026-08-25T16:06:34.541Z

Link: CVE-2026-79980

cve-icon Vulnrichment

No data.

cve-icon NVD

Status : Received

Published: 2026-10-23T20:17:27.913

Modified: 2026-10-23T20:17:27.913

Link: CVE-2026-79980

cve-icon Redhat

No data.

cve-icon OpenCVE Enrichment

Updated: 2026-10-23T22:00:28Z

Weaknesses
  • CWE-340

    Generation of Predictable Numbers or Identifiers