UBUNTU-CVE-2026-98240: Buffer Overflow
In the Linux kernel, the following vulnerability has been resolved: net: iptunnel: initialize optionslen before referencing options The following command triggers a kernel panic: ip link add d0 type dummy; ip link set d0 up ip route add 10.30.0.0/16 \ encap ip id 300 geneveopts 4660:66:11223344 dev d0 memcpy: detected buffer overflow: 4 byte write of buffer size 0 kernel BUG at lib/stringhelpers.c:1044! ... iptunparseopts.part.0.cold+0x10/0x10 iptunbuildstate+0x116/0x2a0 On kernels built with GCC 15+ and CONFIGFORTIFYSOURCE, the fortified memcpy() got 0 sized destination with request of 4 bytes length: static int iptunparseoptsgeneve(...) { ... attr = tb[LWTUNNELIPOPTGENEVEDATA]; datalen = nlalen(attr); / == 4 / struct geneveopt opt = iptunnelinfoopts(info) + optslen; memcpy(opt->optdata, nladata(attr), datalen); / ^^^^^^^^^^^^^ 0 since optionslen is assigned afterwards / Fixed by initializing the counter before the options are referenced. Matching what tunnelkeyoptsset() already does.
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Upgrade
Upgrade
ubuntu/linux-hwe-7.0to a version that resolves this vulnerability.Fixed in 7.0.0-42.42~24.04.1 - Upgrade
Upgrade
ubuntu/linux-riscv-7.0to a version that resolves this vulnerability.Fixed in 7.0.0-42.42.1~24.04.1 - Upgrade
Upgrade
ubuntu/linuxto a version that resolves this vulnerability.Fixed in 7.0.0-42.42 - Upgrade
Upgrade
ubuntu/linux-awsto a version that resolves this vulnerability.Fixed in 7.0.0-1016.17 - Upgrade
Upgrade
ubuntu/linux-gcpto a version that resolves this vulnerability.Fixed in 7.0.0-1016.18 - Upgrade
Upgrade
ubuntu/linux-ibmto a version that resolves this vulnerability.Fixed in 7.0.0-1017.17 - Upgrade
Upgrade
ubuntu/linux-oem-7.0to a version that resolves this vulnerability.Fixed in 7.0.0-1017.17 - Upgrade
Upgrade
ubuntu/linux-oracleto a version that resolves this vulnerability.Fixed in 7.0.0-1015.16 - Upgrade
Upgrade
ubuntu/linux-riscvto a version that resolves this vulnerability.Fixed in 7.0.0-42.42.1
Event History
Frequently Asked Questions
What level of access is needed to trigger the issue?
The provided trigger uses `ip link` and `ip route` commands to create and enable a dummy interface and add an encapsulated route with Geneve options. An attacker would therefore need the ability to make these network-link and routing configuration changes.
Which systems are most likely to exhibit the reported panic?
The reported buffer-overflow detection occurs on kernels built with GCC 15 or later with `CONFIG_FORTIFY_SOURCE` enabled. The issue concerns the Linux kernel packages listed for Ubuntu, including linux-riscv, linux-realtime, linux-hwe-edge, linux-azure, linux-gcp, linux-azure-fde, linux-gke, and linux-aws-5.0.
How can I recognize that this issue has been triggered?
The supplied reproduction causes a kernel panic with a fortified `memcpy()` buffer-overflow report, including a 4-byte write to a zero-sized buffer. Stack traces may include `ip_tun_parse_opts.part.0.cold` and `ip_tun_build_state`.