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

Goal: 1000 CNY · Raised: 1336 CNY

100%

CVE-2022-48734— btrfs: fix deadlock between quota disable and qgroup rescan worker

Quick assessment

Affected
Linux Linux
Exploitation
No confirmed in-the-wild exploitation; assess based on exposure
Recommended action
Check the vendor advisory and references for a fixed version. If immediate upgrade is impossible, restrict exposure and increase monitoring.

Linux kernel是美国Linux基金会的开源操作系统Linux所使用的内核。 Linux kernel 存在安全漏洞,该漏洞源于 btrfs 模块配额禁用和 qgroup 重新扫描工作器之间的死锁。

AI Predicted 5.3 Difficulty: Moderate EPSS 0.18% · P7

Possible ATT&CK Techniques 1 AI

T1499 · Endpoint Denial of Service

Affected Version Matrix 12

VendorProduct Version RangeStatus
Linux Linux 967ef5131e42d6e3bb216c44161d893048a49957< 26b3901d20bf9da2c6a00cb1fb48932166f80a45 affected
967ef5131e42d6e3bb216c44161d893048a49957< 32747e01436aac8ef93fe85b5b523b4f3b52f040 affected
967ef5131e42d6e3bb216c44161d893048a49957< 89d4cca583fc9594ee7d1a0bc986886d6fb587e6 affected
967ef5131e42d6e3bb216c44161d893048a49957< 31198e58c09e21d4f65c49d2361f76b87aca4c3f affected
967ef5131e42d6e3bb216c44161d893048a49957< e804861bd4e69cc5fe1053eedcb024982dde8e48 affected
4.4 affected
< 4.4 unaffected
5.4.178≤ 5.4.* unaffected
… +4 more rows
Get alerts for future matching vulnerabilities Log in to subscribe

I. Basic Information for CVE-2022-48734

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
btrfs: fix deadlock between quota disable and qgroup rescan worker
Source: CVE Program / CVE List V5
Vulnerability Description
In the Linux kernel, the following vulnerability has been resolved: btrfs: fix deadlock between quota disable and qgroup rescan worker Quota disable ioctl starts a transaction before waiting for the qgroup rescan worker completes. However, this wait can be infinite and results in deadlock because of circular dependency among the quota disable ioctl, the qgroup rescan worker and the other task with transaction such as block group relocation task. The deadlock happens with the steps following: 1) Task A calls ioctl to disable quota. It starts a transaction and waits for qgroup rescan worker completes. 2) Task B such as block group relocation task starts a transaction and joins to the transaction that task A started. Then task B commits to the transaction. In this commit, task B waits for a commit by task A. 3) Task C as the qgroup rescan worker starts its job and starts a transaction. In this transaction start, task C waits for completion of the transaction that task A started and task B committed. This deadlock was found with fstests test case btrfs/115 and a zoned null_blk device. The test case enables and disables quota, and the block group reclaim was triggered during the quota disable by chance. The deadlock was also observed by running quota enable and disable in parallel with 'btrfs balance' command on regular null_blk devices. An example report of the deadlock: [372.469894] INFO: task kworker/u16:6:103 blocked for more than 122 seconds. [372.479944] Not tainted 5.16.0-rc8 #7 [372.485067] "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message. [372.493898] task:kworker/u16:6 state:D stack: 0 pid: 103 ppid: 2 flags:0x00004000 [372.503285] Workqueue: btrfs-qgroup-rescan btrfs_work_helper [btrfs] [372.510782] Call Trace: [372.514092] <TASK> [372.521684] __schedule+0xb56/0x4850 [372.530104] ? io_schedule_timeout+0x190/0x190 [372.538842] ? lockdep_hardirqs_on+0x7e/0x100 [372.547092] ? _raw_spin_unlock_irqrestore+0x3e/0x60 [372.555591] schedule+0xe0/0x270 [372.561894] btrfs_commit_transaction+0x18bb/0x2610 [btrfs] [372.570506] ? btrfs_apply_pending_changes+0x50/0x50 [btrfs] [372.578875] ? free_unref_page+0x3f2/0x650 [372.585484] ? finish_wait+0x270/0x270 [372.591594] ? release_extent_buffer+0x224/0x420 [btrfs] [372.599264] btrfs_qgroup_rescan_worker+0xc13/0x10c0 [btrfs] [372.607157] ? lock_release+0x3a9/0x6d0 [372.613054] ? btrfs_qgroup_account_extent+0xda0/0xda0 [btrfs] [372.620960] ? do_raw_spin_lock+0x11e/0x250 [372.627137] ? rwlock_bug.part.0+0x90/0x90 [372.633215] ? lock_is_held_type+0xe4/0x140 [372.639404] btrfs_work_helper+0x1ae/0xa90 [btrfs] [372.646268] process_one_work+0x7e9/0x1320 [372.652321] ? lock_release+0x6d0/0x6d0 [372.658081] ? pwq_dec_nr_in_flight+0x230/0x230 [372.664513] ? rwlock_bug.part.0+0x90/0x90 [372.670529] worker_thread+0x59e/0xf90 [372.676172] ? process_one_work+0x1320/0x1320 [372.682440] kthread+0x3b9/0x490 [372.687550] ? _raw_spin_unlock_irq+0x24/0x50 [372.693811] ? set_kthread_struct+0x100/0x100 [372.700052] ret_from_fork+0x22/0x30 [372.705517] </TASK> [372.709747] INFO: task btrfs-transacti:2347 blocked for more than 123 seconds. [372.729827] Not tainted 5.16.0-rc8 #7 [372.745907] "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message. [372.767106] task:btrfs-transacti state:D stack: 0 pid: 2347 ppid: 2 flags:0x00004000 [372.787776] Call Trace: [372.801652] <TASK> [372.812961] __schedule+0xb56/0x4850 [372.830011] ? io_schedule_timeout+0x190/0x190 [372.852547] ? lockdep_hardirqs_on+0x7e/0x100 [372.871761] ? _raw_spin_unlock_irqrestore+0x3e/0x60 [372.886792] schedule+0xe0/0x270 [372.901685] wait_current_trans+0x22c/0x310 [btrfs] [372.919743] ? btrfs_put_transaction+0x3d0/0x3d0 [btrfs] [372.938923] ? finish_wait+0x270/0x270 [372.959085] ? join_transaction+0xc7 ---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 存在安全漏洞,该漏洞源于 btrfs 模块配额禁用和 qgroup 重新扫描工作器之间的死锁。
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

Vendor Product Affected Versions CPE Subscribe
Linux Linux 967ef5131e42d6e3bb216c44161d893048a49957 ~ 26b3901d20bf9da2c6a00cb1fb48932166f80a45 -
Linux Linux 4.4 -

II. Public POCs for CVE-2022-48734

# POC Description Source Link Shenlong Link
AI-Generated POC Premium

No public POC found.

Login to generate AI POC

III. Intelligence Information for CVE-2022-48734

登录查看更多情报信息。

Other References for CVE-2022-48734 (5)

Same Patch Batch · Linux · 2024-06-20 · 67 CVEs total

CVE-2022-48711 9.8 CRITICAL tipc: improve size validations for received domain records
CVE-2024-38620 8.8 HIGH Bluetooth: HCI: Remove HCI_AMP support
CVE-2021-47620 8.1 HIGH Bluetooth: refactor malicious adv data check
CVE-2022-48743 8.1 HIGH net: amd-xgbe: Fix skb data length underflow
CVE-2022-48720 7.8 HIGH net: macsec: Fix offload support for NETDEV_UNREGISTER event
CVE-2022-48716 7.8 HIGH ASoC: codecs: wcd938x: fix incorrect used of portid
CVE-2022-48771 7.8 HIGH drm/vmwgfx: Fix stale file descriptors on failed usercopy
CVE-2022-48751 7.8 HIGH net/smc: Transitional solution for clcsock race issue
CVE-2022-48742 7.8 HIGH rtnetlink: make sure to refresh master_dev/m_ops in __rtnl_newlink()
CVE-2022-48754 7.8 HIGH phylib: fix potential use-after-free
CVE-2022-48733 7.8 HIGH btrfs: fix use-after-free after failure to create a snapshot
CVE-2022-48721 7.8 HIGH net/smc: Forward wakeup to smc socket waitqueue after fallback
CVE-2022-48762 7.8 HIGH arm64: extable: fix load_unaligned_zeropad() reg indices
CVE-2022-48726 7.8 HIGH RDMA/ucma: Protect mc during concurrent multicast leaves
CVE-2022-48735 7.8 HIGH ALSA: hda: Fix UAF of leds class devs at unbinding
CVE-2022-48729 7.8 HIGH IB/hfi1: Fix panic with larger ipoib send_queue_size
CVE-2022-48759 7.8 HIGH rpmsg: char: Fix race between the release of rpmsg_ctrldev and cdev
CVE-2022-48744 7.5 HIGH net/mlx5e: Avoid field-overflowing memcpy()
CVE-2022-48727 7.3 HIGH KVM: arm64: Avoid consuming a stale esr value when SError occur
CVE-2022-48739 7.1 HIGH ASoC: hdmi-codec: Fix OOB memory accesses

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

IV. Related Vulnerabilities

V. Comments for CVE-2022-48734

No comments yet


Leave a comment