CVE-2021-47555
Last modified
CVE-2021-47555 is a medium-severity vulnerability rated 5.5/10 on the CVSS scale. In the Linux kernel, the following vulnerability has been resolved: net: vlan: fix underflow for the real_dev refcnt Inject error before dev_hold(real_dev) in register_vlan_dev(), and execute the following testcase: ip link add dev dummy1 type dummy ip link add name dummy1.100 link dummy1 type vlan id 100 ip link del dev dummy1 When the dummy netdevice is removed, we will get a WARNING as following: ======================================================================= refcount_t: decrement hit 0; leaking memory. WARNING: CPU: 2 PID: 0 at lib/refcount.c:31 refcount_warn_saturate+0xbf/0x1e0 and an endless loop of: ======================================================================= unregister_netdevice: waiting for dummy1 to become free. Usage count = -1073741824 That is because dev_put(real_dev) in vlan_dev_free() be called without dev_hold(real_dev) in register_vlan_dev(). EPSS estimates a 0.21% chance of exploitation in the next 30 days.
Description
In the Linux kernel, the following vulnerability has been resolved: net: vlan: fix underflow for the real_dev refcnt Inject error before dev_hold(real_dev) in register_vlan_dev(), and execute the following testcase: ip link add dev dummy1 type dummy ip link add name dummy1.100 link dummy1 type vlan id 100 ip link del dev dummy1 When the dummy netdevice is removed, we will get a WARNING as following: ======================================================================= refcount_t: decrement hit 0; leaking memory. WARNING: CPU: 2 PID: 0 at lib/refcount.c:31 refcount_warn_saturate+0xbf/0x1e0 and an endless loop of: ======================================================================= unregister_netdevice: waiting for dummy1 to become free. Usage count = -1073741824 That is because dev_put(real_dev) in vlan_dev_free() be called without dev_hold(real_dev) in register_vlan_dev(). It makes the refcnt of real_dev underflow. Move the dev_hold(real_dev) to vlan_dev_init() which is the call-back of ndo_init(). That makes dev_hold() and dev_put() for vlan's real_dev symmetrical.
Metrics
CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H
Weakness Enumeration
Affected Software
| Vendor | Product | Versions | Update |
|---|---|---|---|
| Linux | Linux Kernel | >= 5.4.160, < 5.4.163 | — |
| Linux | Linux Kernel | >= 5.10.80, < 5.10.83 | — |
| Linux | Linux Kernel | >= 5.14.19, < 5.15 | — |
| Linux | Linux Kernel | >= 5.15.3, < 5.15.6 | — |
| Linux | Linux Kernel | 5.16 | Rc1 |
References
Timeline
- Published
- Last Modified
- Status
- Modified
Frequently Asked Questions
What is CVE-2021-47555?
How severe is CVE-2021-47555?
How do I fix CVE-2021-47555?
How Strix Helps
- How Strix found a critical auth bypass in etcdStrix autonomously discovered a critical authentication bypass in etcd, later designated CVE-2026-33413.
- Autonomous PentestingAI agents that find and validate exploitable vulnerabilities like this one across your applications.
- PR ReviewsPentest every pull request so vulnerable code is caught before it ships to production.
- AI Penetration TestingHow AI-driven penetration testing continuously covers your attack surface.
Related CVEs from 2021
- CVE-2021-47549In the Linux kernel, the following vulnerability has been re…7.8
- CVE-2021-47550In the Linux kernel, the following vulnerability has been re…5.5
- CVE-2021-47551In the Linux kernel, the following vulnerability has been re…7.8
- CVE-2021-47552In the Linux kernel, the following vulnerability has been re…5.5
- CVE-2021-47553In the Linux kernel, the following vulnerability has been re…7.8
- CVE-2021-47554In the Linux kernel, the following vulnerability has been re…5.5
- CVE-2021-47556In the Linux kernel, the following vulnerability has been re…5.5
- CVE-2021-47557In the Linux kernel, the following vulnerability has been re…5.5
- CVE-2021-47558In the Linux kernel, the following vulnerability has been re…5.5
- CVE-2021-47559In the Linux kernel, the following vulnerability has been re…5.5
- CVE-2021-47560In the Linux kernel, the following vulnerability has been re…5.5
- CVE-2021-47561In the Linux kernel, the following vulnerability has been re…7.8
Are you affected by CVE-2021-47555?
Run a free Strix scan to check your systems for this vulnerability.
Scan your code nowSource: NVD / NIST
