CVE-2021-47394
Last modified
CVE-2021-47394 is a high-severity vulnerability rated 7.8/10 on the CVSS scale. In the Linux kernel, the following vulnerability has been resolved: netfilter: nf_tables: unlink table before deleting it syzbot reports following UAF: BUG: KASAN: use-after-free in memcmp+0x18f/0x1c0 lib/string.c:955 nla_strcmp+0xf2/0x130 lib/nlattr.c:836 nft_table_lookup.part.0+0x1a2/0x460 net/netfilter/nf_tables_api.c:570 nft_table_lookup net/netfilter/nf_tables_api.c:4064 [inline] nf_tables_getset+0x1b3/0x860 net/netfilter/nf_tables_api.c:4064 nfnetlink_rcv_msg+0x659/0x13f0 net/netfilter/nfnetlink.c:285 netlink_rcv_skb+0x153/0x420 net/netlink/af_netlink.c:2504 Problem is that all get operations are lockless, so the commit_mutex held by nft_rcv_nl_event() isn't enough to stop a parallel GET request from doing read-accesses to the table object even after synchronize_rcu(). To avoid this, unlink the table first and store the table objects in on-stack scratch space.. EPSS estimates a 0.23% chance of exploitation in the next 30 days.
Description
In the Linux kernel, the following vulnerability has been resolved: netfilter: nf_tables: unlink table before deleting it syzbot reports following UAF: BUG: KASAN: use-after-free in memcmp+0x18f/0x1c0 lib/string.c:955 nla_strcmp+0xf2/0x130 lib/nlattr.c:836 nft_table_lookup.part.0+0x1a2/0x460 net/netfilter/nf_tables_api.c:570 nft_table_lookup net/netfilter/nf_tables_api.c:4064 [inline] nf_tables_getset+0x1b3/0x860 net/netfilter/nf_tables_api.c:4064 nfnetlink_rcv_msg+0x659/0x13f0 net/netfilter/nfnetlink.c:285 netlink_rcv_skb+0x153/0x420 net/netlink/af_netlink.c:2504 Problem is that all get operations are lockless, so the commit_mutex held by nft_rcv_nl_event() isn't enough to stop a parallel GET request from doing read-accesses to the table object even after synchronize_rcu(). To avoid this, unlink the table first and store the table objects in on-stack scratch space.
Metrics
CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
Weakness Enumeration
Affected Software
| Vendor | Product | Versions | Update |
|---|---|---|---|
| Linux | Linux Kernel | >= 5.12, < 5.14.10 | — |
| Linux | Linux Kernel | 5.15 | Rc1 |
References
Timeline
- Published
- Last Modified
- Status
- Modified
Frequently Asked Questions
What is CVE-2021-47394?
How severe is CVE-2021-47394?
How do I fix CVE-2021-47394?
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-47388In the Linux kernel, the following vulnerability has been re…7.8
- CVE-2021-47389In the Linux kernel, the following vulnerability has been re…5.1
- CVE-2021-47390In the Linux kernel, the following vulnerability has been re…7.1
- CVE-2021-47391In the Linux kernel, the following vulnerability has been re…7.8
- CVE-2021-47392In the Linux kernel, the following vulnerability has been re…5.5
- CVE-2021-47393In the Linux kernel, the following vulnerability has been re…7.1
- CVE-2021-47395In the Linux kernel, the following vulnerability has been re…5.5
- CVE-2021-47396In the Linux kernel, the following vulnerability has been re…5.5
- CVE-2021-47397In the Linux kernel, the following vulnerability has been re…5.5
- CVE-2021-47398In the Linux kernel, the following vulnerability has been re…5.5
- CVE-2021-47399In the Linux kernel, the following vulnerability has been re…5.5
- CVE-2021-47400In the Linux kernel, the following vulnerability has been re…5.5
Are you affected by CVE-2021-47394?
Run a free Strix scan to check your systems for this vulnerability.
Scan your code nowSource: NVD / NIST
