insomniacslk/dhcp · Security
github.com/insomniacslk/dhcp permits denial of service through a malformed IPv4 payload length
- GHSA ID
- GHSA-jp3c-6v3g-mpxv
- Severity
- high
- Published
- Updated
- CVSS v4
- 7.1 · CVSS:4.0/AV:A/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N
Description
In github.com/insomniacslk/dhcp/dhcpv4/nclient4, BroadcastRawUDPConn.ReadFrom does not validate that the IPv4 payload length is sufficient to hold a UDP header before calculating the DHCP payload length. A frame with an IPv4 total-length field specifying fewer than eight payload bytes results in a negative DHCP length, causing a panic in buf.Consume due to a negative slice bound.
CWEs
- CWE-1284 · Improper Validation of Specified Quantity in Input