btrfs: subpage: keep TOWRITE tag until folio is cleaned
In the Linux kernel, the following vulnerability has been resolved: btrfs: subpage: keep TOWRITE tag until folio is cleaned btrfs_subpage_set_writeback() calls folio_start_writeback() the first time a folio is written back, and it also clears the PAGECACHE_TAG_TOWRITE tag even if there are still dirty blocks in the folio. This can break ordering guarantees, such as those required by btrfs_wait_ordered_extents(). That ordering breakage leads to a real failure. For example, running generic/464 on a zoned setup will hit the following ASSERT. This happens because the broken ordering fails to flush existing dirty pages before the file size is truncated. assertion failed: !list_empty(&ordered->list) :: 0, in fs/btrfs/zoned.c:1899 ------------[ cut here ]------------ kernel BUG at fs/btrfs/zoned.c:1899! Oops: invalid opcode: 0000 [#1] SMP NOPTI CPU: 2 UID: 0 PID: 1906169 Comm: kworker/u130:2 Kdump: loaded Not tainted 6.16.0-rc6-BTRFS-ZNS+ #554 PREEMPT(voluntary) Hardware name: Supermicro Super Server/H12SSL-NT, BIOS 2.0 02/22/2021 Workqueue: btrfs-endio-write btrfs_work_helper [btrfs] RIP: 0010:btrfs_finish_ordered_zoned.cold+0x50/0x52 [btrfs] RSP: 0018:ffffc9002efdbd60 EFLAGS: 00010246 RAX: 000000000000004c RBX: ffff88811923c4e0 RCX: 0000000000000000 RDX: 0000000000000000 RSI: ffffffff827e38b1 RDI: 00000000ffffffff RBP: ffff88810005d000 R08: 00000000ffffdfff R09: ffffffff831051c8 R10: ffffffff83055220 R11: 0000000000000000 R12: ffff8881c2458c00 R13: ffff88811923c540 R14: ffff88811923c5e8 R15: ffff8881c1bd9680 FS: 0000000000000000(0000) GS:ffff88a04acd0000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 00007f907c7a918c CR3: 0000000004024000 CR4: 0000000000350ef0 Call Trace: <TASK> ? srso_return_thunk+0x5/0x5f btrfs_finish_ordered_io+0x4a/0x60 [btrfs] btrfs_work_helper+0xf9/0x490 [btrfs] process_one_work+0x204/0x590 ? srso_return_thunk+0x5/0x5f worker_thread+0x1d6/0x3d0 ? __pfx_worker_thread+0x10/0x10 kthread+0x118/0x230 ? __pfx_kthread+0x10/0x10 ret_from_fork+0x205/0x260 ? __pfx_kthread+0x10/0x10 ret_from_fork_asm+0x1a/0x30 </TASK> Consider process A calling writepages() with WB_SYNC_NONE. In zoned mode or for compressed writes, it locks several folios for delalloc and starts writing them out. Let's call the last locked folio folio X. Suppose the write range only partially covers folio X, leaving some pages dirty. Process A calls btrfs_subpage_set_writeback() when building a bio. This function call clears the TOWRITE tag of folio X, whose size = 8K and the block size = 4K. It is following state. 0 4K 8K |/////|/////| (flag: DIRTY, tag: DIRTY) <-----> Process A will write this range. Now suppose process B concurrently calls writepages() with WB_SYNC_ALL. It calls tag_pages_for_writeback() to tag dirty folios with PAGECACHE_TAG_TOWRITE. Since folio X is still dirty, it gets tagged. Then, B collects tagged folios using filemap_get_folios_tag() and must wait for folio X to be written before returning from writepages(). 0 4K 8K |/////|/////| (flag: DIRTY, tag: DIRTY|TOWRITE) However, between tagging and collecting, process A may call btrfs_subpage_set_writeback() and clear folio X's TOWRITE tag. 0 4K 8K | |/////| (flag: DIRTY|WRITEBACK, tag: DIRTY) As a result, process B won't see folio X in its batch, and returns without waiting for it. This breaks the WB_SYNC_ALL ordering requirement. Fix this by using btrfs_subpage_set_writeback_keepwrite(), which retains the TOWRITE tag. We now manually clear the tag only after the folio becomes clean, via the xas operation.
- Yayın
- 11 Eyl 2025
- Güncelleme
- 5 Ağu 2026
- EPSS
- %0,2 · 4. yüzdelik
- CWE
- —
Takip etmek için giriş yap · Takip ettiğin kayıt KEV’e girer, istismarı çıkar ya da güncellenirse bildirim alırsın.
Rapor araçları
Aksiyon skoru
22
İzleyin
Şimdilik düşük öncelik.
- CVSS
- 22 / 40 · 5.5 / 10
- CISA KEV
- 0 / 30 · Listede değil
- EPSS
- 0 / 30 · %0,2
CNA ile NVD puanı
- NVD
- 5,5
- CNA · Linux
- 7,8
- 2,3 puan fark
CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
Kaydı açan otoritenin puanı ile NVD’nin bağımsız puanı. İki puan arasındaki fark ciddiyetin tartışmalı olduğunu gösterir.
Etkilenen sistemler
| Üretici | Ürün | CPE |
|---|---|---|
| linux | linux kernel | cpe:2.3:o:linux:linux_kernel |
Etkilenen sürümler
NVD sürüm aralıkları (katalogdaki ürünler için). Stack’ine sürümle eklersen eşleşme bunlarla yapılır.
- linux linux kernel5.13 ve sonrası · 6.12.44 öncesi
- linux linux kernel6.13 ve sonrası · 6.16.4 öncesi
- linux linux kernel6.17
Üreticinin bildirdiği sürümler
Kaydı açan otorite (Linux) tarafından bildirilen etkilenen sürüm aralıkları. NVD'nin CPE analizinden bağımsızdır ve genellikle ondan önce gelir.
Linux Linux
- 5.13etkilenir
- 3470da3b7d87fde4b9729d4e29c2dc074cd59c10 ve sonrası · 3d61136945a7008fc90d013c3c67007ce0c96131 öncesietkilenir · git
- 3470da3b7d87fde4b9729d4e29c2dc074cd59c10 ve sonrası · bce7a5c77a1e7a759e227b7713dde18c52da4759 öncesietkilenir · git
- 3470da3b7d87fde4b9729d4e29c2dc074cd59c10 ve sonrası · b1511360c8ac882b0c52caa263620538e8d73220 öncesietkilenir · git
- 5.13 öncesietkilenmez · semver
- 6.12.44 ve sonrası · 6.12.* dahil öncesietkilenmez · semver
- 6.16.4 ve sonrası · 6.16.* dahil öncesietkilenmez · semver
- 6.17 ve sonrasıetkilenmez · original_commit_for_fix
Paket düzeyi etkilenme
OSV ve GitHub Advisory verisi: ekosistem, paket ve aralık. SBOM eşleşmesi bu tabloyu kullanır.
| Ekosistem | Paket | Etkilenen aralık | Düzeltme |
|---|---|---|---|
| Debian:12 | linux | tüm sürümler | — |
| Debian:13 | linux | 6.12.48-1 öncesi | 6.12.48-1 |
| Debian:14 | linux | 6.16.5-1 öncesi | 6.16.5-1 |
| openSUSE:Leap 16.0 | dtb-aarch64 | 6.12.0-160000.7.1 öncesi | 6.12.0-160000.7.1 |
| openSUSE:Leap 16.0 | kernel-64kb | 6.12.0-160000.7.1 öncesi | 6.12.0-160000.7.1 |
| openSUSE:Leap 16.0 | kernel-default | 6.12.0-160000.7.1 öncesi | 6.12.0-160000.7.1 |
| openSUSE:Leap 16.0 | kernel-default-base | 6.12.0-160000.6.1.160000.2.4 öncesi | 6.12.0-160000.6.1.160000.2.4 |
| openSUSE:Leap 16.0 | kernel-docs | 6.12.0-160000.7.1 öncesi | 6.12.0-160000.7.1 |
| openSUSE:Leap 16.0 | kernel-kvmsmall | 6.12.0-160000.7.1 öncesi | 6.12.0-160000.7.1 |
| openSUSE:Leap 16.0 | kernel-obs-build | 6.12.0-160000.7.1 öncesi | 6.12.0-160000.7.1 |
| openSUSE:Leap 16.0 | kernel-obs-qa | 6.12.0-160000.7.1 öncesi | 6.12.0-160000.7.1 |
| openSUSE:Leap 16.0 | kernel-rt | 6.12.0-160000.7.1 öncesi | 6.12.0-160000.7.1 |
| openSUSE:Leap 16.0 | kernel-source | 6.12.0-160000.7.1 öncesi | 6.12.0-160000.7.1 |
| openSUSE:Leap 16.0 | kernel-syms | 6.12.0-160000.7.1 öncesi | 6.12.0-160000.7.1 |
| openSUSE:Leap 16.0 | kernel-zfcpdump | 6.12.0-160000.7.1 öncesi | 6.12.0-160000.7.1 |
| SUSE:Linux Enterprise Server 16.0 | kernel-docs | 6.12.0-160000.7.1 öncesi | 6.12.0-160000.7.1 |
| SUSE:Linux Enterprise Server 16.0 | kernel-kvmsmall | 6.12.0-160000.7.1 öncesi | 6.12.0-160000.7.1 |
| SUSE:Linux Enterprise Server 16.0 | kernel-obs-qa | 6.12.0-160000.7.1 öncesi | 6.12.0-160000.7.1 |
| SUSE:Linux Enterprise Server 16.0 | kernel-syms | 6.12.0-160000.7.1 öncesi | 6.12.0-160000.7.1 |
| SUSE:Linux Enterprise Server 16.0 | kernel-zfcpdump | 6.12.0-160000.7.1 öncesi | 6.12.0-160000.7.1 |
| SUSE:Linux Micro 6.2 | kernel-64kb | 6.12.0-160000.7.1 öncesi | 6.12.0-160000.7.1 |
| SUSE:Linux Micro 6.2 | kernel-default | 6.12.0-160000.7.1 öncesi | 6.12.0-160000.7.1 |
| SUSE:Linux Micro 6.2 | kernel-default-base | 6.12.0-160000.6.1.160000.2.4 öncesi | 6.12.0-160000.6.1.160000.2.4 |
| SUSE:Linux Micro 6.2 | kernel-rt | 6.12.0-160000.7.1 öncesi | 6.12.0-160000.7.1 |
+2
Aynı üründe
linux: tüm kayıtlarAynı birincil ürünün en yüksek skorlu diğer kayıtları.
- CVE-2022-0847A flaw was found in the way the "flags" member of the new pipe buffer structure was lacking proper initialization in copy_page_to_iter_pipe KEV89Hemen
- CVE-2021-22555Heap Out-Of-Bounds Write in Netfilter IP6T_SO_SET_REPLACEKEV85Hemen
- CVE-2016-5195Race condition in mm/gup.c in the Linux kernel 2.x through 4.x before 4.8.3 allows local users to gain privileges by leveraging incorrect haKEV83Hemen
- CVE-2019-13272In the Linux kernel before 5.1.17, ptrace_link in kernel/ptrace.c mishandles the recording of the credentials of a process that wants to creKEV77Bu hafta
- CVE-2013-6282The (1) get_user and (2) put_user API functions in the Linux kernel before 3.5.5 on the v6k and v7 ARM platforms do not validate certain addKEV77Bu hafta
- CVE-2013-2094The perf_swevent_init function in kernel/events/core.c in the Linux kernel before 3.8.9 uses an incorrect integer data type, which allows loKEV77Bu hafta
Düzeltme
Hangi sürüme geçmeli
Üretici, paket deposu ve Microsoft kayıtlarından derlenen düzeltme sürümleri. Yükseltmeden önce üreticinin notunu doğrulayın.
| Ürün / paket | Düzeltilmiş sürüm | Kaynak |
|---|---|---|
| Linux Linux | 3d61136945a7008fc90d013c3c67007ce0c96131 | Üretici (CNA) |
| Linux Linux | b1511360c8ac882b0c52caa263620538e8d73220 | Üretici (CNA) |
| Linux Linux | bce7a5c77a1e7a759e227b7713dde18c52da4759 | Üretici (CNA) |
| debian:linux | 6.12.48-1 · Debian:13 | Paket deposu (OSV) |
| opensuse:dtb-aarch64 | 6.12.0-160000.7.1 · openSUSE:Leap 16.0 | Paket deposu (OSV) |
| opensuse:kernel-64kb | 6.12.0-160000.7.1 · openSUSE:Leap 16.0 | Paket deposu (OSV) |
| opensuse:kernel-default | 6.12.0-160000.7.1 · openSUSE:Leap 16.0 | Paket deposu (OSV) |
| opensuse:kernel-default-base | 6.12.0-160000.6.1.160000.2.4 · openSUSE:Leap 16.0 | Paket deposu (OSV) |
| opensuse:kernel-docs | 6.12.0-160000.7.1 · openSUSE:Leap 16.0 | Paket deposu (OSV) |
| opensuse:kernel-kvmsmall | 6.12.0-160000.7.1 · openSUSE:Leap 16.0 | Paket deposu (OSV) |
| opensuse:kernel-obs-build | 6.12.0-160000.7.1 · openSUSE:Leap 16.0 | Paket deposu (OSV) |
| opensuse:kernel-obs-qa | 6.12.0-160000.7.1 · openSUSE:Leap 16.0 | Paket deposu (OSV) |
| opensuse:kernel-rt | 6.12.0-160000.7.1 · openSUSE:Leap 16.0 | Paket deposu (OSV) |
| opensuse:kernel-source | 6.12.0-160000.7.1 · openSUSE:Leap 16.0 | Paket deposu (OSV) |
| opensuse:kernel-syms | 6.12.0-160000.7.1 · openSUSE:Leap 16.0 | Paket deposu (OSV) |
| opensuse:kernel-zfcpdump | 6.12.0-160000.7.1 · openSUSE:Leap 16.0 | Paket deposu (OSV) |
| suse:kernel-64kb | 6.12.0-160000.7.1 · SUSE:Linux Micro 6.2 | Paket deposu (OSV) |
| suse:kernel-default | 6.12.0-160000.7.1 · SUSE:Linux Micro 6.2 | Paket deposu (OSV) |
| suse:kernel-default-base | 6.12.0-160000.6.1.160000.2.4 · SUSE:Linux Micro 6.2 | Paket deposu (OSV) |
| suse:kernel-docs | 6.12.0-160000.7.1 · SUSE:Linux Enterprise Server 16.0 | Paket deposu (OSV) |
| suse:kernel-kvmsmall | 6.12.0-160000.7.1 · SUSE:Linux Enterprise Server 16.0 | Paket deposu (OSV) |
| suse:kernel-obs-build | 6.12.0-160000.7.1 · SUSE:Linux Micro Extras 6.2 | Paket deposu (OSV) |
| suse:kernel-obs-qa | 6.12.0-160000.7.1 · SUSE:Linux Enterprise Server 16.0 | Paket deposu (OSV) |
| suse:kernel-rt | 6.12.0-160000.7.1 · SUSE:Linux Micro 6.2 | Paket deposu (OSV) |
| suse:kernel-source | 6.12.0-160000.7.1 · SUSE:Linux Micro 6.2 | Paket deposu (OSV) |
| suse:kernel-syms | 6.12.0-160000.7.1 · SUSE:Linux Enterprise Server 16.0 | Paket deposu (OSV) |
| suse:kernel-zfcpdump | 6.12.0-160000.7.1 · SUSE:Linux Enterprise Server 16.0 | Paket deposu (OSV) |
İstismar durumu
Bilinen kamuya açık istismar yok
Şu an kamuya açık bir istismar görülmedi. Bu, güvende olduğunuz anlamına gelmez; yalnızca eşiğin biraz daha yüksek olduğunu gösterir.
Araştırma bağlamı
Pentester ve araştırmacı için: saldırı profili, puan anlaşmazlığı, zaman çizelgesi, yama commit’leri, kredi, varyant ve zincir adayları, bug bounty kapsamı. Hepsi mevcut veriden türetilir; istismar kodu içermez.
Zaman çizelgesi
Yayından bugüne: kavram kanıtı, Metasploit modülü, CISA KEV ve düzeltme kaydı. Tarihler kaynakların bildirdiği tarihlerdir.
Yayın dışında tarihli olay yok.
FIRST EPSS günlük puanı; yalnızca 0,01 ve üstü değişimler kaydedilir (adım grafiği).
Yama ve commit bağlantıları
Referanslardaki commit, PR ve diff adresleri. Patch-diff ve varyant avı için başlangıç noktası; istismar değil, düzeltmedir.
Referanslarda commit ya da PR bağlantısı yok.
Kredi
Tüm araştırmacılarCNA kaydında adı geçen bulan, bildiren ve analistler. Ada tıkla, aynı araştırmacının diğer kayıtlarını gör.
CNA kaydında kredi yok.
Varyant adayları
Aynı üründe aynı zafiyet sınıfı, 18 ay içinde. Yama kök nedeni kapatmadıysa kardeş hata burada olur.
Gece hesaplanan ilişki yok.
Zincir adayları
Aynı üründe kimlik doğrulama atlatma ile yetki isteyen bir açık kısa aralıkla yayımlanmış: birlikte kimlik doğrulamasız bir yola dönüşebilir.
—
Bug bounty kapsamı
Bilinen herkese açık program yok.
Kaynak: bounty-targets-data (HackerOne, Bugcrowd, Intigriti, YesWeHack herkese açık listeleri).
Teknik detay
Saldırı koşulları
- Sisteme yerel erişimi olan biri tetikleyebilir.
- Düşük yetkili bir hesap yeterli.
- Kullanıcının bir şey yapması gerekmez.
- Özel bir koşul gerekmez; tekrarlanabilir.
Başarılı olursa
- Gizlilik
- yok
- Bütünlük
- yok
- Erişilebilirlik
- yüksek · hizmet durdurulabilir
- Saldırı vektörü
- Yerel
- Karmaşıklık
- Düşük
- Gereken yetki
- Düşük
- Kullanıcı etkileşimi
- Gerekmez
- Kapsam
- Değişmez
- Gizlilik etkisi
- Yok
- Bütünlük etkisi
- Yok
- Erişilebilirlik etkisi
- Yüksek
Zayıflık sınıfı (CWE)
—
CVSS vektörü
CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H
nvd-primary
Saldırı bağlamı
Bu zafiyet sınıfının (CWE) MITRE CAPEC saldırı desenleri ve ATT&CK teknikleri. Tespit kuralı ve tehdit avı için başlangıç noktası.
Bu CWE için MITRE'de CAPEC/ATT&CK eşlemesi yok.
Noroxi analizi
Bu kayıt için henüz Noroxi analizi yok
385 binden fazla zafiyetin tamamına elle analiz yazmıyoruz; bu dürüst olmazdı. Öne çıkan ve sahada etkisi olan zafiyetler için mekanizma, tespit ve kapatma adımlarını ekibimiz yazıyor.
Bu ürünü kullanıyoruz, yardım isteyinDeğişiklik günlüğü
- Düzeltme✗ → ✓
Takip ettiğiniz kayıtlarda bu değişiklikler bildirim olarak da gelir. →
Referanslar
- git.kernel.org/stable/c/3d61136945a7008fc90d013c3c67007ce0c96131
- git.kernel.org/stable/c/b1511360c8ac882b0c52caa263620538e8d73220
- git.kernel.org/stable/c/bce7a5c77a1e7a759e227b7713dde18c52da4759
Üretici bildirimleri ve resmî kayıtlar. İstismar/PoC bağlantıları bilinçli olarak dışarıda bırakıldı.