In the Linux kernel, the following vulnerability has been resolved:
net: ipv6: ensure we call ipv6_mc_down() at most once
There are two reasons for addrconf_notify() to be called with NETDEV_DOWN:
either the network device is actually going down, or IPv6 was disabled
on the interface.
If either of them stays down while the other is toggled, we repeatedly
call the code for NETDEV_DOWN, including ipv6_mc_down(), while never
calling the corresponding ipv6_mc_up() in between. This will cause a
new entry in idev->mc_tomb to be allocated for each multicast group
the interface is subscribed to, which in turn leaks one struct ifmcaddr6
per nontrivial multicast group the interface is subscribed to.
The following reproducer will leak at least $n objects:
ip addr add ff2e::4242/32 dev eth0 autojoin
sysctl -w net.ipv6.conf.eth0.disable_ipv6=1
for i in $(seq 1 $n); do
ip link set up eth0; ip link set down eth0
done
Joining groups with IPV6_ADD_MEMBERSHIP (unprivileged) or setting the
sysctl net.ipv6.conf.eth0.forwarding to 1 (=> subscribing to ff02::2)
can also be used to create a nontrivial idev->mc_list, which will the
leak objects with the right up-down-sequence.
Based on both sources for NETDEV_DOWN events the interface IPv6 state
should be considered:
OS | Version | Architecture | Package | Version | Filename |
---|---|---|---|---|---|
ubuntu | 18.04 | noarch | linux | < any | UNKNOWN |
ubuntu | 20.04 | noarch | linux | < 5.4.0-124.140 | UNKNOWN |
ubuntu | 18.04 | noarch | linux-aws | < any | UNKNOWN |
ubuntu | 20.04 | noarch | linux-aws | < 5.4.0-1083.90 | UNKNOWN |
ubuntu | 18.04 | noarch | linux-aws-5.4 | < any | UNKNOWN |
ubuntu | 16.04 | noarch | linux-aws-hwe | < 4.15.0-1139.150~16.04.1 | UNKNOWN |
ubuntu | 20.04 | noarch | linux-azure | < 5.4.0-1089.94 | UNKNOWN |
ubuntu | 14.04 | noarch | linux-azure | < 4.15.0-1149.164~14.04.1 | UNKNOWN |
ubuntu | 16.04 | noarch | linux-azure | < 4.15.0-1149.164~16.04.1 | UNKNOWN |
ubuntu | 18.04 | noarch | linux-azure-4.15 | < any | UNKNOWN |
git.kernel.org/linus/9995b408f17ff8c7f11bc725c8aa225ba3a63b1c (5.17-rc7)
git.kernel.org/stable/c/72124e65a70b84e6303a5cd21b0ac1f27d7d61a4
git.kernel.org/stable/c/9588ac2eddc2f223ebcebf6e9f5caed84d32922b
git.kernel.org/stable/c/9995b408f17ff8c7f11bc725c8aa225ba3a63b1c
git.kernel.org/stable/c/9a8736b2da28b24f01707f592ff059b9f90a058c
git.kernel.org/stable/c/b11781515208dd31fbcd0b664078dce5dc44523f
git.kernel.org/stable/c/c71bf3229f9e9dd60ba02f5a5be02066edf57012
git.kernel.org/stable/c/f4c63b24dea9cc2043ff845dcca9aaf8109ea38a
launchpad.net/bugs/cve/CVE-2022-48910
nvd.nist.gov/vuln/detail/CVE-2022-48910
security-tracker.debian.org/tracker/CVE-2022-48910
www.cve.org/CVERecord?id=CVE-2022-48910