smb: prevent use-after-free due to open_cached_dir error paths
In the Linux kernel, the following vulnerability has been resolved: smb: prevent use-after-free due to open_cached_dir error paths If open_cached_dir() encounters an error parsing the lease from the server, the error handling may race with receiving a lease break, resulting in open_cached_dir() freeing the cfid while the queued work is pending. Update open_cached_dir() to drop refs rather than directly freeing the cfid. Have cached_dir_lease_break(), cfids_laundromat_worker(), and invalidate_all_cached_dirs() clear has_lease immediately while still holding cfids->cfid_list_lock, and then use this to also simplify the reference counting in cfids_laundromat_worker() and invalidate_all_cached_dirs(). Fixes this KASAN splat (which manually injects an error and lease break in open_cached_dir()): ================================================================== BUG: KASAN: slab-use-after-free in smb2_cached_lease_break+0x27/0xb0 Read of size 8 at addr ffff88811cc24c10 by task kworker/3:1/65 CPU: 3 UID: 0 PID: 65 Comm: kworker/3:1 Not tainted 6.12.0-rc6-g255cf264e6e5-dirty #87 Hardware name: VMware, Inc. VMware Virtual Platform/440BX Desktop Reference Platform, BIOS 6.00 11/12/2020 Workqueue: cifsiod smb2_cached_lease_break Call Trace: <TASK> dump_stack_lvl+0x77/0xb0 print_report+0xce/0x660 kasan_report+0xd3/0x110 smb2_cached_lease_break+0x27/0xb0 process_one_work+0x50a/0xc50 worker_thread+0x2ba/0x530 kthread+0x17c/0x1c0 ret_from_fork+0x34/0x60 ret_from_fork_asm+0x1a/0x30 </TASK> Allocated by task 2464: kasan_save_stack+0x33/0x60 kasan_save_track+0x14/0x30 __kasan_kmalloc+0xaa/0xb0 open_cached_dir+0xa7d/0x1fb0 smb2_query_path_info+0x43c/0x6e0 cifs_get_fattr+0x346/0xf10 cifs_get_inode_info+0x157/0x210 cifs_revalidate_dentry_attr+0x2d1/0x460 cifs_getattr+0x173/0x470 vfs_statx_path+0x10f/0x160 vfs_statx+0xe9/0x150 vfs_fstatat+0x5e/0xc0 __do_sys_newfstatat+0x91/0xf0 do_syscall_64+0x95/0x1a0 entry_SYSCALL_64_after_hwframe+0x76/0x7e Freed by task 2464: kasan_save_stack+0x33/0x60 kasan_save_track+0x14/0x30 kasan_save_free_info+0x3b/0x60 __kasan_slab_free+0x51/0x70 kfree+0x174/0x520 open_cached_dir+0x97f/0x1fb0 smb2_query_path_info+0x43c/0x6e0 cifs_get_fattr+0x346/0xf10 cifs_get_inode_info+0x157/0x210 cifs_revalidate_dentry_attr+0x2d1/0x460 cifs_getattr+0x173/0x470 vfs_statx_path+0x10f/0x160 vfs_statx+0xe9/0x150 vfs_fstatat+0x5e/0xc0 __do_sys_newfstatat+0x91/0xf0 do_syscall_64+0x95/0x1a0 entry_SYSCALL_64_after_hwframe+0x76/0x7e Last potentially related work creation: kasan_save_stack+0x33/0x60 __kasan_record_aux_stack+0xad/0xc0 insert_work+0x32/0x100 __queue_work+0x5c9/0x870 queue_work_on+0x82/0x90 open_cached_dir+0x1369/0x1fb0 smb2_query_path_info+0x43c/0x6e0 cifs_get_fattr+0x346/0xf10 cifs_get_inode_info+0x157/0x210 cifs_revalidate_dentry_attr+0x2d1/0x460 cifs_getattr+0x173/0x470 vfs_statx_path+0x10f/0x160 vfs_statx+0xe9/0x150 vfs_fstatat+0x5e/0xc0 __do_sys_newfstatat+0x91/0xf0 do_syscall_64+0x95/0x1a0 entry_SYSCALL_64_after_hwframe+0x76/0x7e The buggy address belongs to the object at ffff88811cc24c00 which belongs to the cache kmalloc-1k of size 1024 The buggy address is located 16 bytes inside of freed 1024-byte region [ffff88811cc24c00, ffff88811cc25000)
- Yayın
- 27 Ara 2024
- Güncelleme
- 5 Ağu 2026
- EPSS
- %0,6 · 44. yüzdelik
- CWE
- CWE-416
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
39
İzleyin
Şimdilik düşük öncelik.
- CVSS
- 39 / 40 · 9.8 / 10
- CISA KEV
- 0 / 30 · Listede değil
- EPSS
- 0 / 30 · %0,6
CISA SSVC kararı
- Sömürü
- yok
- Otomatikleştirilebilir
- hayır
- Teknik etki
- tam
Vulnrichment: CISA'nın karar ağacı girdileri.
CNA ile NVD puanı
- NVD
- —
- CNA · Linux
- 9,8
- NVD henüz kendi puanını vermedi; gösterilen puan CNA’nın.
Kaydı açan otoritenin puanı ile NVD’nin bağımsız puanı. İki puan arasındaki fark ciddiyetin tartışmalı olduğunu gösterir.
Noroxi analizi
Bu kayıt için henüz Noroxi analizi yok
Veritabanındaki yüz binlerce 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 isteyinEtkilenen 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 kernel6.6.64 öncesi
- linux linux kernel6.7 ve sonrası · 6.11.11 öncesi
- linux linux kernel6.12 ve sonrası · 6.12.2 öncesi
Ü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
- 6db94d08359c43f2c8fe372811cdee04564a41b9, 6.7etkilenir
- 93877b9afc2994c89362007aac480a7b150f386f ve sonrası · 791f833053578b9fd24252ebb7162a61bc3f805b öncesietkilenir · git
- 5c86919455c1edec99ebd3338ad213b59271a71b ve sonrası · 97e2afcac0bebfef6a5360f4267ce4c44507b845 öncesietkilenir · git
- 5c86919455c1edec99ebd3338ad213b59271a71b ve sonrası · 47655a12c6b1bca8fa230085eab2e85a076932b7 öncesietkilenir · git
- 5c86919455c1edec99ebd3338ad213b59271a71b ve sonrası · a9685b409a03b73d2980bbfa53eb47555802d0a9 öncesietkilenir · git
- 6.6.3 ve sonrası · 6.6.64 öncesietkilenir · semver
- 6.5.13 ve sonrası · 6.6 öncesietkilenir · semver
- 6.7 öncesietkilenmez · semver
- 6.6.64 ve sonrası · 6.6.* dahil öncesietkilenmez · semver
- 6.11.11 ve sonrası · 6.11.* dahil öncesietkilenmez · semver
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:13 | linux | 6.12.3-1 öncesi | 6.12.3-1 |
| SUSE:Linux Enterprise High Performance Computing 15 SP4-ESPOS | kernel-64kb | 5.14.21-150400.24.176.1 öncesi | 5.14.21-150400.24.176.1 |
| SUSE:Linux Enterprise High Performance Computing 15 SP4-ESPOS | kernel-64kb | 5.14.21-150400.24.150.1 öncesi | 5.14.21-150400.24.150.1 |
| SUSE:Linux Enterprise High Performance Computing 15 SP4-ESPOS | kernel-docs | 5.14.21-150400.24.176.1 öncesi | 5.14.21-150400.24.176.1 |
| SUSE:Linux Enterprise High Performance Computing 15 SP4-ESPOS | kernel-docs | 5.14.21-150400.24.150.1 öncesi | 5.14.21-150400.24.150.1 |
| SUSE:Linux Enterprise High Performance Computing 15 SP4-ESPOS | kernel-obs-build | 5.14.21-150400.24.176.1 öncesi | 5.14.21-150400.24.176.1 |
| SUSE:Linux Enterprise High Performance Computing 15 SP4-ESPOS | kernel-obs-build | 5.14.21-150400.24.150.1 öncesi | 5.14.21-150400.24.150.1 |
| SUSE:Linux Enterprise High Performance Computing 15 SP4-ESPOS | kernel-source | 5.14.21-150400.24.176.1 öncesi | 5.14.21-150400.24.176.1 |
| SUSE:Linux Enterprise High Performance Computing 15 SP4-ESPOS | kernel-source | 5.14.21-150400.24.150.1 öncesi | 5.14.21-150400.24.150.1 |
| SUSE:Linux Enterprise High Performance Computing 15 SP4-ESPOS | kernel-syms | 5.14.21-150400.24.176.1 öncesi | 5.14.21-150400.24.176.1 |
| SUSE:Linux Enterprise High Performance Computing 15 SP4-ESPOS | kernel-syms | 5.14.21-150400.24.150.1 öncesi | 5.14.21-150400.24.150.1 |
| SUSE:Linux Enterprise High Performance Computing 15 SP5-ESPOS | kernel-64kb | 5.14.21-150500.55.121.2 öncesi | 5.14.21-150500.55.121.2 |
| SUSE:Linux Enterprise High Performance Computing 15 SP5-ESPOS | kernel-docs | 5.14.21-150500.55.121.1 öncesi | 5.14.21-150500.55.121.1 |
| SUSE:Linux Enterprise High Performance Computing 15 SP5-ESPOS | kernel-obs-build | 5.14.21-150500.55.121.1 öncesi | 5.14.21-150500.55.121.1 |
| SUSE:Linux Enterprise High Performance Computing 15 SP5-ESPOS | kernel-syms | 5.14.21-150500.55.121.1 öncesi | 5.14.21-150500.55.121.1 |
| SUSE:Linux Enterprise Live Patching 15 SP4 | kernel-livepatch-SLE15-SP4_Update_36 | 1-150400.9.3.1 öncesi | 1-150400.9.3.1 |
| SUSE:Linux Enterprise Live Patching 15 SP5 | kernel-livepatch-SLE15-SP5_Update_30 | 1-150500.11.5.1 öncesi | 1-150500.11.5.1 |
| SUSE:Linux Enterprise Micro 5.3 | kernel-default | 5.14.21-150400.24.150.1 öncesi | 5.14.21-150400.24.150.1 |
| SUSE:Linux Enterprise Micro 5.3 | kernel-default | 5.14.21-150400.24.176.1 öncesi | 5.14.21-150400.24.176.1 |
| SUSE:Linux Enterprise Micro 5.3 | kernel-default-base | 5.14.21-150400.24.176.1.150400.24.90.1 öncesi | 5.14.21-150400.24.176.1.150400.24.90.1 |
| SUSE:Linux Enterprise Micro 5.3 | kernel-default-base | 5.14.21-150400.24.150.1.150400.24.74.1 öncesi | 5.14.21-150400.24.150.1.150400.24.74.1 |
| SUSE:Linux Enterprise Micro 5.3 | kernel-rt | 5.14.21-150400.15.130.1 öncesi | 5.14.21-150400.15.130.1 |
| SUSE:Linux Enterprise Micro 5.3 | kernel-rt | 5.14.21-150400.15.109.1 öncesi | 5.14.21-150400.15.109.1 |
| SUSE:Linux Enterprise Micro 5.3 | kernel-source-rt | 5.14.21-150400.15.109.1 öncesi | 5.14.21-150400.15.109.1 |
+9
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 | 47655a12c6b1bca8fa230085eab2e85a076932b7 | Üretici (CNA) |
| Linux Linux | 6.6 | Üretici (CNA) |
| Linux Linux | 6.6.64 | Üretici (CNA) |
| Linux Linux | 791f833053578b9fd24252ebb7162a61bc3f805b | Üretici (CNA) |
| Linux Linux | 97e2afcac0bebfef6a5360f4267ce4c44507b845 | Üretici (CNA) |
| Linux Linux | a9685b409a03b73d2980bbfa53eb47555802d0a9 | Üretici (CNA) |
| debian:linux | 6.12.3-1 · Debian:13 | Paket deposu (OSV) |
| suse:kernel-64kb | 5.14.21-150400.24.176.1 · SUSE:Linux Enterprise High Performance Computing 15 SP4-ESPOS | Paket deposu (OSV) |
| suse:kernel-default | 5.14.21-150400.24.176.1 · SUSE:Linux Enterprise Micro 5.3 | Paket deposu (OSV) |
| suse:kernel-default-base | 5.14.21-150400.24.176.1.150400.24.90.1 · SUSE:Linux Enterprise Micro 5.3 | Paket deposu (OSV) |
| suse:kernel-docs | 5.14.21-150400.24.176.1 · SUSE:Linux Enterprise High Performance Computing 15 SP4-ESPOS | Paket deposu (OSV) |
| suse:kernel-livepatch-SLE15-SP4_Update_36 | 1-150400.9.3.1 · SUSE:Linux Enterprise Live Patching 15 SP4 | Paket deposu (OSV) |
| suse:kernel-livepatch-SLE15-SP5_Update_30 | 1-150500.11.5.1 · SUSE:Linux Enterprise Live Patching 15 SP5 | Paket deposu (OSV) |
| suse:kernel-obs-build | 5.14.21-150400.24.176.1 · SUSE:Linux Enterprise High Performance Computing 15 SP4-ESPOS | Paket deposu (OSV) |
| suse:kernel-rt | 5.14.21-150500.13.106.1 · SUSE:Linux Enterprise Micro 5.5 | Paket deposu (OSV) |
| suse:kernel-source | 5.14.21-150400.24.176.1 · SUSE:Linux Enterprise High Performance Computing 15 SP4-ESPOS | Paket deposu (OSV) |
| suse:kernel-source-rt | 5.14.21-150500.13.106.1 · SUSE:Linux Enterprise Micro 5.5 | Paket deposu (OSV) |
| suse:kernel-syms | 5.14.21-150400.24.176.1 · SUSE:Linux Enterprise High Performance Computing 15 SP4-ESPOS | Paket deposu (OSV) |
| suse:kernel-zfcpdump | 5.14.21-150400.24.176.1 · SUSE:Linux Enterprise Server 15 SP4-LTSS | 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ı
- İnternetten erişebilen herkes tetikleyebilir.
- Hesap ya da parola gerekmez.
- Kullanıcının bir şey yapması gerekmez.
- Özel bir koşul gerekmez; tekrarlanabilir.
Başarılı olursa
- Gizlilik
- yüksek · veriler okunabilir
- Bütünlük
- yüksek · veri ya da yapılandırma değiştirilebilir
- Erişilebilirlik
- yüksek · hizmet durdurulabilir
- Saldırı vektörü
- Ağ
- Karmaşıklık
- Düşük
- Gereken yetki
- Yok
- Kullanıcı etkileşimi
- Gerekmez
- Kapsam
- Değişmez
- Gizlilik etkisi
- Yüksek
- Bütünlük etkisi
- Yüksek
- Erişilebilirlik etkisi
- Yüksek
Zayıflık sınıfı (CWE)
CWE-416 · Use After FreeCVSS vektörü
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
nvd-secondary
Kök neden
Bir bellek alanı serbest bırakıldıktan sonra ona işaret eden başka bir referans kullanılmaya devam ediyor. Aynı alan o sırada başka bir veri için ayrılmış olabilir.
Hatanın kod karşılığı
CWE-416 sınıfının tamamıBu zafiyet sınıfının temsili örneği. Üreticinin kaynak kodu değildir; hatalı kalıbı ve düzeltmesini gösterir.
Hatalı
free(dev->buf);/* ... başka bir iş parçacığı hâlâ çalışıyor ... */process(dev->buf);Düzeltilmiş
lock(&dev->lock);free(dev->buf);dev->buf = NULL;unlock(&dev->lock);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.
Değ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/47655a12c6b1bca8fa230085eab2e85a076932b7
- git.kernel.org/stable/c/791f833053578b9fd24252ebb7162a61bc3f805b
- git.kernel.org/stable/c/97e2afcac0bebfef6a5360f4267ce4c44507b845
- git.kernel.org/stable/c/a9685b409a03b73d2980bbfa53eb47555802d0a9
Üretici bildirimleri ve resmî kayıtlar. İstismar/PoC bağlantıları bilinçli olarak dışarıda bırakıldı.