Linux: wifi: virt_wifi: don't transfer operstate before register
What fixes it
- 9ce26201f6dedf3fa02b97da8c67ee6f6c5f7225LinuxCVE List
- 293c56a66510bb7de073a1aba388e38abddff1fbLinuxCVE List
A fixed version on one release line is not the upgrade target for every line. Check your exact version and any vendor backports.
Description
In the Linux kernel, the following vulnerability has been resolved:
wifi: virt_wifi: don't transfer operstate before register
virt_wifi_newlink() calls netif_stacked_transfer_operstate() before register_netdevice(). If the lower device is dormant, that queues the new netdev on lweventlist while it is still uninitialized. If registration fails after that, for example because of an invalid name such as "bad/name", free_netdev() immediately frees the object. A later linkwatch_fire_event() then use-after-frees the list entry.
Move the transfer to after netdev_upper_dev_link(), as macvlan and ipvlan already do.
Text from CVE List
Affected versions 18
- Linuxaffected: c7cdba31ed8b87526db978976392802d3f93110c before ee9ea1afd6990def51d52b3a0aecd5cfcc951da0CVE List
- Linuxaffected: c7cdba31ed8b87526db978976392802d3f93110c before 9ce26201f6dedf3fa02b97da8c67ee6f6c5f7225CVE List
- Linuxaffected: c7cdba31ed8b87526db978976392802d3f93110c before f9526054c2b2cace5916b7225603d008834ec011CVE List
- Linuxaffected: c7cdba31ed8b87526db978976392802d3f93110c before e8304e25c6dabb8accf38b807969438d0ce84fd7CVE List
- Linuxaffected: c7cdba31ed8b87526db978976392802d3f93110c before ca49763c42c1089d654bf11b037980a9ede3772cCVE List
- Linuxaffected: c7cdba31ed8b87526db978976392802d3f93110c before 293c56a66510bb7de073a1aba388e38abddff1fbCVE List
- Linuxaffected: c7cdba31ed8b87526db978976392802d3f93110c before b808a9af5fd21f9c68b0d024eda7535b5dce6a4eCVE List
- Linuxaffected: c7cdba31ed8b87526db978976392802d3f93110c before e5c8d7acd31b27057ea42cd405d0b3ece097bc89CVE List
- Linuxaffected: 5.0CVE List
- Linuxunaffected: all versions before 5.0CVE List
- Linuxunaffected: 5.10.271 through 5.10.*CVE List
- Linuxunaffected: 5.15.222 through 5.15.*CVE List
- Linuxunaffected: 6.1.189 through 6.1.*CVE List
- Linuxunaffected: 6.6.158 through 6.6.*CVE List
- Linuxunaffected: 6.12.112 through 6.12.*CVE List
- Linuxunaffected: 6.18.54 through 6.18.*CVE List
- Linuxunaffected: 7.2.8 through 7.2.*CVE List
- Linuxunaffected: 7.3CVE List
References 8
- git.kernel.org/stable/c/ee9ea1afd6990def51d52b3a0aecd5cfcc951da0Referencevia CVE List
- git.kernel.org/stable/c/9ce26201f6dedf3fa02b97da8c67ee6f6c5f7225Referencevia CVE List
- git.kernel.org/stable/c/f9526054c2b2cace5916b7225603d008834ec011Referencevia CVE List
- git.kernel.org/stable/c/e8304e25c6dabb8accf38b807969438d0ce84fd7Referencevia CVE List
- git.kernel.org/stable/c/ca49763c42c1089d654bf11b037980a9ede3772cReferencevia CVE List
- git.kernel.org/stable/c/293c56a66510bb7de073a1aba388e38abddff1fbReferencevia CVE List
- git.kernel.org/stable/c/b808a9af5fd21f9c68b0d024eda7535b5dce6a4eReferencevia CVE List
- git.kernel.org/stable/c/e5c8d7acd31b27057ea42cd405d0b3ece097bc89Referencevia CVE List