Goal Reached Thanks to every supporter — we hit 100%!

Goal: 1000 CNY · Raised: 1336 CNY

100%

CVE-2023-53591— net/mlx5e: Fix deadlock in tc route query code

AI Predicted 4.7 Difficulty: Moderate EPSS 0.12% · P2

Possible ATT&CK Techniques 1AI

T1546 · Event Triggered Execution

Affected Version Matrix 14

VendorProductVersion RangeStatus
LinuxLinuxf9d196bd632b8b79261ec3366c30ec3923ea9a02< 69966bce28da6aadccfd968b75d128a79da32d17affected
f9d196bd632b8b79261ec3366c30ec3923ea9a02< 362063df6ceec80b0b6798b61ae03504dcc125a5affected
f9d196bd632b8b79261ec3366c30ec3923ea9a02< a7236e420a7d8082b1df4b3e05c739dd2642a662affected
f9d196bd632b8b79261ec3366c30ec3923ea9a02< 691c041bf20899fc13c793f92ba61ab660fa3a30affected
87a0625cf1c76caeaa15c576a0b2fcad4b9387d0affected
7778fe1a6a6c069a460e4e3ff8ed3722392a4b5baffected
5.13.17< 5.14affected
5.14.4< 5.15affected
… +6 more rows
Get alerts for future matching vulnerabilitiesLog in to subscribe

I. Basic Information for CVE-2023-53591

Vulnerability Information

Have questions about the vulnerability? See if Shenlong's analysis helps!
View Shenlong Deep Dive ↗

Although we use advanced large model technology, its output may still contain inaccurate or outdated information.Shenlong tries to ensure data accuracy, but please verify and judge based on the actual situation.

Vulnerability Title
net/mlx5e: Fix deadlock in tc route query code
Source: CVE Program / CVE List V5
Vulnerability Description
In the Linux kernel, the following vulnerability has been resolved: net/mlx5e: Fix deadlock in tc route query code Cited commit causes ABBA deadlock[0] when peer flows are created while holding the devcom rw semaphore. Due to peer flows offload implementation the lock is taken much higher up the call chain and there is no obvious way to easily fix the deadlock. Instead, since tc route query code needs the peer eswitch structure only to perform a lookup in xarray and doesn't perform any sleeping operations with it, refactor the code for lockless execution in following ways: - RCUify the devcom 'data' pointer. When resetting the pointer synchronously wait for RCU grace period before returning. This is fine since devcom is currently only used for synchronization of pairing/unpairing of eswitches which is rare and already expensive as-is. - Wrap all usages of 'paired' boolean in {READ|WRITE}_ONCE(). The flag has already been used in some unlocked contexts without proper annotations (e.g. users of mlx5_devcom_is_paired() function), but it wasn't an issue since all relevant code paths checked it again after obtaining the devcom semaphore. Now it is also used by mlx5_devcom_get_peer_data_rcu() as "best effort" check to return NULL when devcom is being unpaired. Note that while RCU read lock doesn't prevent the unpaired flag from being changed concurrently it still guarantees that reader can continue to use 'data'. - Refactor mlx5e_tc_query_route_vport() function to use new mlx5_devcom_get_peer_data_rcu() API which fixes the deadlock. [0]: [ 164.599612] ====================================================== [ 164.600142] WARNING: possible circular locking dependency detected [ 164.600667] 6.3.0-rc3+ #1 Not tainted [ 164.601021] ------------------------------------------------------ [ 164.601557] handler1/3456 is trying to acquire lock: [ 164.601998] ffff88811f1714b0 (&esw->offloads.encap_tbl_lock){+.+.}-{3:3}, at: mlx5e_attach_encap+0xd8/0x8b0 [mlx5_core] [ 164.603078] but task is already holding lock: [ 164.603617] ffff88810137fc98 (&comp->sem){++++}-{3:3}, at: mlx5_devcom_get_peer_data+0x37/0x80 [mlx5_core] [ 164.604459] which lock already depends on the new lock. [ 164.605190] the existing dependency chain (in reverse order) is: [ 164.605848] -> #1 (&comp->sem){++++}-{3:3}: [ 164.606380] down_read+0x39/0x50 [ 164.606772] mlx5_devcom_get_peer_data+0x37/0x80 [mlx5_core] [ 164.607336] mlx5e_tc_query_route_vport+0x86/0xc0 [mlx5_core] [ 164.607914] mlx5e_tc_tun_route_lookup+0x1a4/0x1d0 [mlx5_core] [ 164.608495] mlx5e_attach_decap_route+0xc6/0x1e0 [mlx5_core] [ 164.609063] mlx5e_tc_add_fdb_flow+0x1ea/0x360 [mlx5_core] [ 164.609627] __mlx5e_add_fdb_flow+0x2d2/0x430 [mlx5_core] [ 164.610175] mlx5e_configure_flower+0x952/0x1a20 [mlx5_core] [ 164.610741] tc_setup_cb_add+0xd4/0x200 [ 164.611146] fl_hw_replace_filter+0x14c/0x1f0 [cls_flower] [ 164.611661] fl_change+0xc95/0x18a0 [cls_flower] [ 164.612116] tc_new_tfilter+0x3fc/0xd20 [ 164.612516] rtnetlink_rcv_msg+0x418/0x5b0 [ 164.612936] netlink_rcv_skb+0x54/0x100 [ 164.613339] netlink_unicast+0x190/0x250 [ 164.613746] netlink_sendmsg+0x245/0x4a0 [ 164.614150] sock_sendmsg+0x38/0x60 [ 164.614522] ____sys_sendmsg+0x1d0/0x1e0 [ 164.614934] ___sys_sendmsg+0x80/0xc0 [ 164.615320] __sys_sendmsg+0x51/0x90 [ 164.615701] do_syscall_64+0x3d/0x90 [ 164.616083] entry_SYSCALL_64_after_hwframe+0x46/0xb0 [ 164.616568] -> #0 (&esw->offloads.encap_tbl_lock){+.+.}-{3:3}: [ 164.617210] __lock_acquire+0x159e/0x26e0 [ 164.617638] lock_acquire+0xc2/0x2a0 [ 164.618018] __mutex_lock+0x92/0xcd0 [ 164.618401] mlx5e_attach_encap+0xd8/0x8b0 [mlx5_core] [ 164.618943] post_process_attr+0x153/0x2d0 [ ---truncated---
Source: CVE Program / CVE List V5
CVSS Information
N/A
Source: CVE Program / CVE List V5
Vulnerability Type
N/A
Source: CVE Program / CVE List V5
Vulnerability Title
Linux kernel 安全漏洞
Source: CNNVD (China National Vulnerability Database)
Vulnerability Description
Linux kernel是美国Linux基金会的开源操作系统Linux所使用的内核。 Linux kernel存在安全漏洞,该漏洞源于tc路由查询代码存在死锁,可能导致拒绝服务。
Source: CNNVD (China National Vulnerability Database)
CVSS Information
N/A
Source: CNNVD (China National Vulnerability Database)
Vulnerability Type
N/A
Source: CNNVD (China National Vulnerability Database)

Affected Products

VendorProductAffected VersionsCPESubscribe
LinuxLinux f9d196bd632b8b79261ec3366c30ec3923ea9a02 ~ 69966bce28da6aadccfd968b75d128a79da32d17 -
LinuxLinux 5.15 -

II. Public POCs for CVE-2023-53591

#POC DescriptionSource LinkShenlong Link
AI-Generated POCPremium

No public POC found.

Login to generate AI POC

III. Intelligence Information for CVE-2023-53591

登录查看更多情报信息。

Patches & Fixes for CVE-2023-53591 (4)

Same Patch Batch · Linux · 2025-10-04 · 144 CVEs total

CVE-2025-399329.8 CRITICALsmb: client: let smbd_destroy() call disable_work_sync(&info->post_send_credits_work)
CVE-2025-399489.8 CRITICALice: fix Rx page leak on multi-buffer frames
CVE-2025-399469.8 CRITICALtls: make sure to abort the stream if headers are bogus
CVE-2025-399339.4 CRITICALsmb: client: let recv_done verify data_offset, data_length and remaining_data_length
CVE-2025-399439.4 CRITICALksmbd: smbdirect: validate data_offset and data_length field of smb_direct_data_transfer
CVE-2023-536009.1 CRITICALtunnels: fix kasan splat when generating ipv4 pmtu error
CVE-2023-536158.8 HIGHscsi: qla2xxx: Fix deletion race condition
CVE-2025-399528.8 HIGHwifi: wilc1000: avoid buffer overflow in WID string configuration
CVE-2023-535898.8 HIGHwifi: iwlwifi: mvm: don't trust firmware n_channels
CVE-2023-535868.8 HIGHscsi: target: Fix multiple LUN_RESET handling
CVE-2022-504938.8 HIGHscsi: qla2xxx: Fix crash when I/O abort times out
CVE-2023-535988.4 HIGHbus: mhi: host: Range check CHDBOFF and ERDBOFF
CVE-2023-535667.8 HIGHnetfilter: nft_set_rbtree: fix null deref on element insertion
CVE-2023-535367.8 HIGHblk-crypto: make blk_crypto_evict_key() more robust
CVE-2023-535607.8 HIGHtracing/histograms: Add histograms to hist_vars if they have referenced variables
CVE-2023-535597.8 HIGHip_vti: fix potential slab-use-after-free in decode_session6
CVE-2023-535577.8 HIGHfprobe: Release rethook after the ftrace_ops is unregistered
CVE-2023-535377.8 HIGHf2fs: fix to avoid use-after-free for cached IPU bio
CVE-2023-535397.8 HIGHRDMA/rxe: Fix incomplete state save in rxe_requester
CVE-2023-535457.8 HIGHdrm/amdgpu: unmap and remove csa_va properly

Showing top 20 of 144 CVEs. View all on vendor page &rarr; →

IV. Related Vulnerabilities

V. Comments for CVE-2023-53591

No comments yet


Leave a comment