Vulnerability · Published Dec 24, 2025 · Assigned by Linux
CVE-2022-50780net: fix UAF issue in nfqnl_nf_hook_drop() when ops_init() failed
High 7.8
In plain English
A high-severity security flaw in Linux from Linux. There are no confirmed reports of exploitation so far. The chance it is exploited in the next 30 days is estimated at 0.2% (higher than 5% of all known vulnerabilities). Fixed versions are available - upgrade the affected package.
Official description
In the Linux kernel, the following vulnerability has been resolved: net: fix UAF issue in nfqnl_nf_hook_drop() when ops_init() failed When the ops_init() interface is invoked to initialize the net, but ops->init() fails, data is released. However, the ptr pointer in net->gen is invalid. In this case, when nfqnl_nf_hook_drop() is invoked to release the net, invalid address access occurs. The process is as follows: setup_net() ops_init() data = kzalloc(...) ---> alloc "data" net_assign_generic() ---> assign "date" to ptr in net->gen ... ops->init() ---> failed ... kfree(data); ---> ptr in net->gen is invalid ... ops_exit_list() ... nfqnl_nf_hook_drop() *q = nfnl_queue_pernet(net) ---> q is invalid The following is the Call Trace information: BUG: KASAN: use-after-free in nfqnl_nf_hook_drop+0x264/0x280 Read of size 8 at addr ffff88810396b240 by task ip/15855 Call Trace: <TASK> dump_stack_lvl+0x8e/0xd1 print_report+0x155/0x454 kasan_report+0xba/0x1f0 nfqnl_nf_hook_drop+0x264/0x280 nf_queue_nf_hook_drop+0x8b/0x1b0 __nf_unregister_net_hook+0x1ae/0x5a0 nf_unregister_net_hooks+0xde/0x130 ops_exit_list+0xb0/0x170 setup_net+0x7ac/0xbd0 copy_net_ns+0x2e6/0x6b0 create_new_namespaces+0x382/0xa50 unshare_nsproxy_namespaces+0xa6/0x1c0 ksys_unshare+0x3a4/0x7e0 __x64_sys_unshare+0x2d/0x40 do_syscall_64+0x35/0x80 entry_SYSCALL_64_after_hwframe+0x46/0xb0 </TASK> Allocated by task 15855: kasan_save_stack+0x1e/0x40 kasan_set_track+0x21/0x30 __kasan_kmalloc+0xa1/0xb0 __kmalloc+0x49/0xb0 ops_init+0xe7/0x410 setup_net+0x5aa/0xbd0 copy_net_ns+0x2e6/0x6b0 create_new_namespaces+0x382/0xa50 unshare_nsproxy_namespaces+0xa6/0x1c0 ksys_unshare+0x3a4/0x7e0 __x64_sys_unshare+0x2d/0x40 do_syscall_64+0x35/0x80 entry_SYSCALL_64_after_hwframe+0x46/0xb0 Freed by task 15855: kasan_save_stack+0x1e/0x40 kasan_set_track+0x21/0x30 kasan_save_free_info+0x2a/0x40 ____kasan_slab_free+0x155/0x1b0 slab_free_freelist_hook+0x11b/0x220 __kmem_cache_free+0xa4/0x360 ops_init+0xb9/0x410 setup_net+0x5aa/0xbd0 copy_net_ns+0x2e6/0x6b0 create_new_namespaces+0x382/0xa50 unshare_nsproxy_namespaces+0xa6/0x1c0 ksys_unshare+0x3a4/0x7e0 __x64_sys_unshare+0x2d/0x40 do_syscall_64+0x35/0x80 entry_SYSCALL_64_after_hwframe+0x46/0xb0
Affected packages & fixed versions
| Ecosystem | Package | Fixed in | Advisory |
|---|---|---|---|
| Debian:12 | linux | 6.0.7-1 | DEBIAN-CVE-2022-50780 |
| Debian:13 | linux | 6.0.7-1 | DEBIAN-CVE-2022-50780 |
| Debian:14 | linux | 6.0.7-1 | DEBIAN-CVE-2022-50780 |
| Ubuntu:22.04:LTS | linux | 5.15.0-60.66 | UBUNTU-CVE-2022-50780 |
| Ubuntu:22.04:LTS | linux-allwinner-5.19 | no fix listed | UBUNTU-CVE-2022-50780 |
| Ubuntu:22.04:LTS | linux-aws | 5.15.0-1030.34 | UBUNTU-CVE-2022-50780 |
| Ubuntu:22.04:LTS | linux-aws-5.19 | no fix listed | UBUNTU-CVE-2022-50780 |
| Ubuntu:22.04:LTS | linux-aws-6.2 | no fix listed | UBUNTU-CVE-2022-50780 |
| Ubuntu:22.04:LTS | linux-aws-6.5 | no fix listed | UBUNTU-CVE-2022-50780 |
| Ubuntu:22.04:LTS | linux-azure | 5.15.0-1033.40 | UBUNTU-CVE-2022-50780 |
| Ubuntu:22.04:LTS | linux-azure-5.19 | no fix listed | UBUNTU-CVE-2022-50780 |
| Ubuntu:24.04:LTS | linux-azure-6.11 | no fix listed | UBUNTU-CVE-2022-50780 |
| Ubuntu:22.04:LTS | linux-azure-6.2 | no fix listed | UBUNTU-CVE-2022-50780 |
| Ubuntu:22.04:LTS | linux-azure-6.5 | no fix listed | UBUNTU-CVE-2022-50780 |
| Ubuntu:22.04:LTS | linux-azure-fde | 5.15.0-1033.40.1 | UBUNTU-CVE-2022-50780 |
| Ubuntu:22.04:LTS | linux-azure-fde-5.19 | no fix listed | UBUNTU-CVE-2022-50780 |
| Ubuntu:22.04:LTS | linux-azure-fde-6.2 | no fix listed | UBUNTU-CVE-2022-50780 |
| Ubuntu:22.04:LTS | linux-gcp | 5.15.0-1029.36 | UBUNTU-CVE-2022-50780 |
| Ubuntu:22.04:LTS | linux-gcp-5.19 | no fix listed | UBUNTU-CVE-2022-50780 |
| Ubuntu:24.04:LTS | linux-gcp-6.11 | no fix listed | UBUNTU-CVE-2022-50780 |
| Ubuntu:22.04:LTS | linux-gcp-6.2 | no fix listed | UBUNTU-CVE-2022-50780 |
| Ubuntu:22.04:LTS | linux-gcp-6.5 | no fix listed | UBUNTU-CVE-2022-50780 |
| Ubuntu:22.04:LTS | linux-gke | 5.15.0-1027.32 | UBUNTU-CVE-2022-50780 |
| Ubuntu:22.04:LTS | linux-gkeop | 5.15.0-1015.19 | UBUNTU-CVE-2022-50780 |
| Ubuntu:22.04:LTS | linux-hwe-5.19 | no fix listed | UBUNTU-CVE-2022-50780 |
| Ubuntu:24.04:LTS | linux-hwe-6.11 | no fix listed | UBUNTU-CVE-2022-50780 |
| Ubuntu:22.04:LTS | linux-hwe-6.2 | no fix listed | UBUNTU-CVE-2022-50780 |
| Ubuntu:22.04:LTS | linux-hwe-6.5 | no fix listed | UBUNTU-CVE-2022-50780 |
| Ubuntu:22.04:LTS | linux-ibm | 5.15.0-1025.28 | UBUNTU-CVE-2022-50780 |
| Ubuntu:22.04:LTS | linux-intel-iot-realtime | no fix listed | UBUNTU-CVE-2022-50780 |
| Ubuntu:22.04:LTS | linux-intel-iotg | 5.15.0-1025.30 | UBUNTU-CVE-2022-50780 |
| Ubuntu:22.04:LTS | linux-kvm | 5.15.0-1028.33 | UBUNTU-CVE-2022-50780 |
| Ubuntu:22.04:LTS | linux-lowlatency | 5.15.0-60.66 | UBUNTU-CVE-2022-50780 |
| Ubuntu:22.04:LTS | linux-lowlatency-hwe-5.19 | no fix listed | UBUNTU-CVE-2022-50780 |
| Ubuntu:24.04:LTS | linux-lowlatency-hwe-6.11 | no fix listed | UBUNTU-CVE-2022-50780 |
| Ubuntu:22.04:LTS | linux-lowlatency-hwe-6.2 | no fix listed | UBUNTU-CVE-2022-50780 |
| Ubuntu:22.04:LTS | linux-lowlatency-hwe-6.5 | no fix listed | UBUNTU-CVE-2022-50780 |
| Ubuntu:22.04:LTS | linux-nvidia | 5.15.0-1017.17 | UBUNTU-CVE-2022-50780 |
| Ubuntu:24.04:LTS | linux-nvidia-6.11 | no fix listed | UBUNTU-CVE-2022-50780 |
| Ubuntu:22.04:LTS | linux-nvidia-6.2 | no fix listed | UBUNTU-CVE-2022-50780 |
| Ubuntu:22.04:LTS | linux-nvidia-6.5 | no fix listed | UBUNTU-CVE-2022-50780 |
| Ubuntu:22.04:LTS | linux-oem-5.17 | no fix listed | UBUNTU-CVE-2022-50780 |
| Ubuntu:22.04:LTS | linux-oem-6.0 | no fix listed | UBUNTU-CVE-2022-50780 |
| Ubuntu:22.04:LTS | linux-oem-6.1 | no fix listed | UBUNTU-CVE-2022-50780 |
| Ubuntu:24.04:LTS | linux-oem-6.11 | no fix listed | UBUNTU-CVE-2022-50780 |
| Ubuntu:22.04:LTS | linux-oem-6.5 | no fix listed | UBUNTU-CVE-2022-50780 |
| Ubuntu:24.04:LTS | linux-oem-6.8 | no fix listed | UBUNTU-CVE-2022-50780 |
| Ubuntu:22.04:LTS | linux-oracle | 5.15.0-1029.35 | UBUNTU-CVE-2022-50780 |
| Ubuntu:22.04:LTS | linux-oracle-6.5 | no fix listed | UBUNTU-CVE-2022-50780 |
| Ubuntu:22.04:LTS | linux-raspi | 5.15.0-1024.26 | UBUNTU-CVE-2022-50780 |
| Ubuntu:24.04:LTS | linux-raspi-realtime | no fix listed | UBUNTU-CVE-2022-50780 |
| Ubuntu:22.04:LTS | linux-realtime | no fix listed | UBUNTU-CVE-2022-50780 |
| Ubuntu:24.04:LTS | linux-realtime | no fix listed | UBUNTU-CVE-2022-50780 |
| Ubuntu:22.04:LTS | linux-riscv | no fix listed | UBUNTU-CVE-2022-50780 |
| Ubuntu:24.04:LTS | linux-riscv | no fix listed | UBUNTU-CVE-2022-50780 |
| Ubuntu:22.04:LTS | linux-riscv-5.19 | no fix listed | UBUNTU-CVE-2022-50780 |
| Ubuntu:24.04:LTS | linux-riscv-6.14 | no fix listed | UBUNTU-CVE-2022-50780 |
| Ubuntu:22.04:LTS | linux-riscv-6.5 | no fix listed | UBUNTU-CVE-2022-50780 |
| Ubuntu:22.04:LTS | linux-starfive-5.19 | no fix listed | UBUNTU-CVE-2022-50780 |
| Ubuntu:22.04:LTS | linux-starfive-6.2 | no fix listed | UBUNTU-CVE-2022-50780 |
| Ubuntu:22.04:LTS | linux-starfive-6.5 | no fix listed | UBUNTU-CVE-2022-50780 |
Affected products (as reported)
| Vendor | Product | Versions |
|---|---|---|
| Linux | Linux | f875bae065334907796da12523f9df85c89f5712 – before 5a2ea549be94924364f6911227d99be86e8cf34af875bae065334907796da12523f9df85c89f5712 – before 97ad240fd9aa9214497d14af2b91608e20856cacf875bae065334907796da12523f9df85c89f5712 – before c3edc6e808209aa705185f732e682a370981ced1f875bae065334907796da12523f9df85c89f5712 – before a1e18acb0246bfb001b08b8b1b830b5ec92a0f13f875bae065334907796da12523f9df85c89f5712 – before 4a4df5e78712de39d6f90d6a64b5eb48dca03bd5f875bae065334907796da12523f9df85c89f5712 – before d266935ac43d57586e311a087510fe6a084af742 |
| Linux | Linux | 2.6.33 |
References
- https://git.kernel.org/stable/c/5a2ea549be94924364f6911227d99be86e8cf34a
- https://git.kernel.org/stable/c/97ad240fd9aa9214497d14af2b91608e20856cac
- https://git.kernel.org/stable/c/c3edc6e808209aa705185f732e682a370981ced1
- https://git.kernel.org/stable/c/a1e18acb0246bfb001b08b8b1b830b5ec92a0f13
- https://git.kernel.org/stable/c/4a4df5e78712de39d6f90d6a64b5eb48dca03bd5
- https://git.kernel.org/stable/c/d266935ac43d57586e311a087510fe6a084af742