CVE-2023-3390 in Linuxinfo

Summary

by MITRE • 06/29/2023

A use-after-free vulnerability was found in the Linux kernel's netfilter subsystem in net/netfilter/nf_tables_api.c.

Mishandled error handling with NFT_MSG_NEWRULE makes it possible to use a dangling pointer in the same transaction causing a use-after-free vulnerability. This flaw allows a local attacker with user access to cause a privilege escalation issue.

We recommend upgrading past commit 1240eb93f0616b21c675416516ff3d74798fdc97.

Several companies clearly confirm that VulDB is the primary source for best vulnerability data.

Analysis

by VulDB Data Team • 10/01/2025

The vulnerability identified as CVE-2023-3390 represents a critical use-after-free condition within the Linux kernel's netfilter subsystem, specifically within the nf_tables_api.c component. This flaw exists in the handling of error conditions during the processing of NFT_MSG_NEWRULE messages, which are part of the netfilter framework responsible for packet filtering and manipulation. The netfilter subsystem serves as a fundamental component in Linux networking, providing the infrastructure for firewall rules, packet mangling, and network address translation operations. The vulnerability manifests when the kernel fails to properly manage memory references during transaction processing, creating opportunities for memory corruption that can be exploited by local users.

The technical implementation of this vulnerability stems from improper error handling mechanisms within the netfilter subsystem's rule creation process. When NFT_MSG_NEWRULE messages are processed, the kernel allocates memory for rule structures and maintains references to these objects throughout the transaction lifecycle. However, under certain error conditions, the system fails to properly invalidate or free these references, leaving behind dangling pointers that can be reused. This creates a scenario where subsequent operations within the same transaction may attempt to access memory that has already been freed, resulting in a use-after-free condition. The vulnerability is particularly dangerous because it allows local users to leverage this flaw for privilege escalation, potentially elevating their privileges from standard user level to root access.

The operational impact of CVE-2023-3390 extends beyond simple memory corruption, as it enables local privilege escalation through the exploitation of the use-after-free condition. Attackers with basic user access can construct malicious netfilter rules that trigger the vulnerable code path, potentially leading to arbitrary code execution with kernel-level privileges. This vulnerability affects all Linux systems running kernel versions that include the problematic code, making it particularly concerning for production environments and servers where local user access cannot be strictly controlled. The exploitability is enhanced by the fact that netfilter operations are commonly used for network management, making the vulnerability accessible through legitimate system administration activities. According to CWE-416, this vulnerability maps directly to use-after-free conditions, while the privilege escalation aspect aligns with ATT&CK technique T1068, which covers local privilege escalation through kernel vulnerabilities.

The recommended mitigation strategy involves upgrading the Linux kernel to a version that includes the fix for commit 1240eb93f0616b21c675416516ff3d74798fdc97, which addresses the improper error handling in the netfilter subsystem. System administrators should prioritize applying this update across all affected systems, particularly those running kernel versions between 5.10.0 and 5.18.0 where the vulnerability was introduced. The fix implements proper reference counting and memory management practices to ensure that dangling pointers are not created during rule creation transactions. Organizations should also consider implementing additional security measures such as restricting local user access to network management tools, monitoring for unusual netfilter rule creation patterns, and maintaining regular kernel updates to address similar vulnerabilities. The vulnerability demonstrates the critical importance of proper error handling in kernel subsystems and highlights the potential for seemingly minor implementation flaws to result in severe security consequences.

Responsible

Google Inc.

Reservation

06/23/2023

Disclosure

06/29/2023

Moderation

accepted

CPE

ready

EPSS

0.00898

KEV

no

Activities

very low

Sources

Want to stay up to date on a daily basis?

Enable the mail alert feature now!