net: ipip: require CAP_NET_ADMIN in the device netns for changelink
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
≥ 6c742e714d8c282fd8f8b22d3e20b5141738c1ee · < 68cadc3698c7de88966d306d12ec9c6217da228a| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
net: ipip: require CAP_NET_ADMIN in the device netns for changelink
ipip_changelink() operates on at most two netns, dev_net(dev) and the tunnel link netns t->net. They differ once the device is created in or moved to a netns other than the one the request runs in. The rtnl changelink path checks CAP_NET_ADMIN only against dev_net(dev), so a caller privileged there but not in t->net can rewrite a tunnel that lives in t->net.
Gate ipip_changelink() on rtnl_dev_link_net_capable() at its top, before any attribute is parsed.
From the CVE record · Linux
The Linux kernel's ipip changelink path checks CAP_NET_ADMIN in the device's network namespace but not in the tunnel link's namespace. When those namespaces differ, a caller with CAP_NET_ADMIN in the device namespace can change a tunnel in the link namespace without that capability there.
Engineers running Linux kernels with ipip tunnels should check their kernel against the vendor advisory; affected versions are not specified.