netfilter: nf_tables: Fix potential data-race in __nft_obj_type_get()
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
≥ e50092404c1bc7aaeb0a0f4077fa6f07b073a20f · < d78d867dcea69c328db30df665be5be7d0148484| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
netfilter: nf_tables: Fix potential data-race in __nft_obj_type_get()
nft_unregister_obj() can concurrent with __nft_obj_type_get(), and there is not any protection when iterate over nf_tables_objects list in __nft_obj_type_get(). Therefore, there is potential data-race of nf_tables_objects list entry.
Use list_for_each_entry_rcu() to iterate over nf_tables_objects list in __nft_obj_type_get(), and use rcu_read_lock() in the caller nft_obj_type_get() to protect the entire type query process.
From the CVE record · Linux
The Linux kernel's nf_tables object-type lookup can race with object unregistration because it iterates the object list without protection. This can cause a data race when the operations occur concurrently. The input does not specify an attack path, authentication requirements, or user interaction.
Engineers running Linux kernels with the affected netfilter nf_tables code should check their kernel versions against the vendor advisory; affected versions are not specified.