Skip to main content

CVE-2023-53105: Vulnerability in Linux Linux

High
VulnerabilityCVE-2023-53105cvecve-2023-53105
Published: Fri May 02 2025 (05/02/2025, 15:55:46 UTC)
Source: CVE
Vendor/Project: Linux
Product: Linux

Description

In the Linux kernel, the following vulnerability has been resolved: net/mlx5e: Fix cleanup null-ptr deref on encap lock During module is unloaded while a peer tc flow is still offloaded, first the peer uplink rep profile is changed to a nic profile, and so neigh encap lock is destroyed. Next during unload, the VF reps netdevs are unregistered which causes the original non-peer tc flow to be deleted, which deletes the peer flow. The peer flow deletion detaches the encap entry and try to take the already destroyed encap lock, causing the below trace. Fix this by clearing peer flows during tc eswitch cleanup (mlx5e_tc_esw_cleanup()). Relevant trace: [ 4316.837128] BUG: kernel NULL pointer dereference, address: 00000000000001d8 [ 4316.842239] RIP: 0010:__mutex_lock+0xb5/0xc40 [ 4316.851897] Call Trace: [ 4316.852481] <TASK> [ 4316.857214] mlx5e_rep_neigh_entry_release+0x93/0x790 [mlx5_core] [ 4316.858258] mlx5e_rep_encap_entry_detach+0xa7/0xf0 [mlx5_core] [ 4316.859134] mlx5e_encap_dealloc+0xa3/0xf0 [mlx5_core] [ 4316.859867] clean_encap_dests.part.0+0x5c/0xe0 [mlx5_core] [ 4316.860605] mlx5e_tc_del_fdb_flow+0x32a/0x810 [mlx5_core] [ 4316.862609] __mlx5e_tc_del_fdb_peer_flow+0x1a2/0x250 [mlx5_core] [ 4316.863394] mlx5e_tc_del_flow+0x(/0x630 [mlx5_core] [ 4316.864090] mlx5e_flow_put+0x5f/0x100 [mlx5_core] [ 4316.864771] mlx5e_delete_flower+0x4de/0xa40 [mlx5_core] [ 4316.865486] tc_setup_cb_reoffload+0x20/0x80 [ 4316.865905] fl_reoffload+0x47c/0x510 [cls_flower] [ 4316.869181] tcf_block_playback_offloads+0x91/0x1d0 [ 4316.869649] tcf_block_unbind+0xe7/0x1b0 [ 4316.870049] tcf_block_offload_cmd.isra.0+0x1ee/0x270 [ 4316.879266] tcf_block_offload_unbind+0x61/0xa0 [ 4316.879711] __tcf_block_put+0xa4/0x310

AI-Powered Analysis

AILast updated: 07/01/2025, 04:25:03 UTC

Technical Analysis

CVE-2023-53105 is a vulnerability identified in the Linux kernel's mlx5e driver, which is part of the Mellanox (now NVIDIA) network driver stack used for high-performance network interface cards (NICs). The issue arises during the unloading of the mlx5e kernel module when a peer traffic control (tc) flow remains offloaded. Specifically, the vulnerability is a NULL pointer dereference caused by improper handling of the encap lock during cleanup. When the module unloads, the peer uplink representative profile is changed to a NIC profile, destroying the neigh encap lock. Subsequently, the virtual function (VF) representative network devices are unregistered, triggering deletion of the original non-peer tc flow, which in turn deletes the peer flow. The peer flow deletion attempts to detach the encapsulation entry and acquire the already destroyed encap lock, leading to a kernel NULL pointer dereference and a kernel crash (BUG). This flaw manifests as a kernel panic or system crash, which can cause denial of service (DoS) conditions on affected systems. The root cause is a race condition and improper cleanup sequence in the mlx5e_tc_esw_cleanup() function. The vulnerability does not require user interaction but does require the module to be unloaded while certain tc flows are active. No known exploits are reported in the wild, and no CVSS score has been assigned yet. The vulnerability affects specific Linux kernel versions containing the mlx5e driver with the described code paths. The technical trace shows the kernel stack leading to the NULL pointer dereference in __mutex_lock, confirming the locking issue. This vulnerability is critical for environments relying on Mellanox NICs with advanced traffic control offloading features, especially in data centers and cloud infrastructures.

Potential Impact

For European organizations, the impact of CVE-2023-53105 can be significant in environments using Linux servers with Mellanox NICs, particularly in data centers, cloud service providers, and enterprises with high-performance computing needs. The vulnerability can cause kernel crashes leading to denial of service, disrupting critical network services and applications. This can affect availability of services, potentially impacting business operations, especially for sectors relying on continuous network uptime such as finance, telecommunications, and public services. Although the vulnerability does not directly lead to privilege escalation or data leakage, the resulting DoS can be exploited by attackers to disrupt operations or as part of a larger attack chain. The lack of known exploits reduces immediate risk, but the complexity of the issue and its presence in core network drivers means that patching is essential to maintain system stability and security. Organizations using Linux distributions with Mellanox hardware should prioritize updates to avoid unexpected outages.

Mitigation Recommendations

1. Apply the official Linux kernel patches that address CVE-2023-53105 as soon as they become available from your Linux distribution vendor or the upstream kernel source. 2. Avoid unloading the mlx5e kernel module while peer tc flows are still offloaded; implement operational procedures to ensure proper cleanup of traffic control flows before module unload. 3. Monitor kernel logs for signs of mlx5e driver errors or kernel NULL pointer dereferences to detect potential exploitation or instability. 4. In virtualized or containerized environments, isolate workloads using Mellanox NICs to limit the blast radius of potential DoS caused by this vulnerability. 5. Coordinate with hardware vendors (e.g., NVIDIA/Mellanox) for firmware updates or driver recommendations that may mitigate related risks. 6. Implement redundancy and failover mechanisms in network infrastructure to maintain availability in case of kernel crashes. 7. Conduct thorough testing of kernel updates in staging environments to ensure compatibility and stability before production deployment.

Need more detailed analysis?Get Pro

Technical Details

Data Version
5.1
Assigner Short Name
Linux
Date Reserved
2025-05-02T15:51:43.553Z
Cisa Enriched
false
Cvss Version
null
State
PUBLISHED

Threat ID: 682d9830c4522896dcbe6fdb

Added to database: 5/21/2025, 9:09:04 AM

Last enriched: 7/1/2025, 4:25:03 AM

Last updated: 7/29/2025, 12:41:26 AM

Views: 13

Actions

PRO

Updates to AI analysis are available only with a Pro account. Contact root@offseq.com for access.

Please log in to the Console to use AI analysis features.

Need enhanced features?

Contact root@offseq.com for Pro access with improved analysis and higher rate limits.

Latest Threats