Descrizione
In the Linux kernel, the following vulnerability has been resolved: atm: fore200e: fix use-after-free in tasklets during device removal When the PCA-200E or SBA-200E adapter is being detached, the fore200e is deallocated. However, the tx_tasklet or rx_tasklet may still be running or pending, leading to use-after-free bug when the already freed fore200e is accessed again in fore200e_tx_tasklet() or fore200e_rx_tasklet(). One of the race conditions can occur as follows: CPU 0 (cleanup) | CPU 1 (tasklet) fore200e_pca_remove_one() | fore200e_interrupt() fore200e_shutdown() | tasklet_schedule() kfree(fore200e) | fore200e_tx_tasklet() | fore200e-> // UAF Fix this by ensuring tx_tasklet or rx_tasklet is properly canceled before the fore200e is released. Add tasklet_kill() in fore200e_shutdown() to synchronize with any pending or running tasklets. Moreover, since fore200e_reset() could prevent further interrupts or data transfers, the tasklet_kill() should be placed after fore200e_reset() to prevent the tasklet from being rescheduled in fore200e_interrupt(). Finally, it only needs to do tasklet_kill() when the fore200e state is greater than or equal to FORE200E_STATE_IRQ, since tasklets are uninitialized in earlier states. In a word, the tasklet_kill() should be placed in the FORE200E_STATE_IRQ branch within the switch...case structure. This bug was identified through static analysis.
Come correggere
Priorità: Media — correggere nel prossimo ciclo di patch. Motivazione: CVSS 7.5.
Versioni da aggiornare
- Linux Linux Kernel: vulnerabili le versioni dalla
2.6.12.1precedenti alla5.10.252→ aggiornare alla5.10.252o successiva. - Linux Linux Kernel: vulnerabili le versioni dalla
5.11precedenti alla5.15.202→ aggiornare alla5.15.202o successiva. - Linux Linux Kernel: vulnerabili le versioni dalla
5.16precedenti alla6.1.165→ aggiornare alla6.1.165o successiva. - Linux Linux Kernel: vulnerabili le versioni dalla
6.2precedenti alla6.6.128→ aggiornare alla6.6.128o successiva. - Linux Linux Kernel: vulnerabili le versioni dalla
6.7precedenti alla6.12.75→ aggiornare alla6.12.75o successiva. - Linux Linux Kernel: vulnerabili le versioni dalla
6.13precedenti alla6.18.16→ aggiornare alla6.18.16o successiva. - Linux Linux Kernel: vulnerabili le versioni dalla
6.19precedenti alla6.19.6→ aggiornare alla6.19.6o successiva. - Linux Linux Kernel: vulnerabile la versione
2.6.12→ installare l'ultima release supportata dal vendor. - Linux Linux Kernel: vulnerabile la versione
2.6.12 rc2→ installare l'ultima release supportata dal vendor. - Linux Linux Kernel: vulnerabile la versione
2.6.12 rc3→ installare l'ultima release supportata dal vendor. - Linux Linux Kernel: vulnerabile la versione
2.6.12 rc4→ installare l'ultima release supportata dal vendor. - Linux Linux Kernel: vulnerabile la versione
2.6.12 rc5→ installare l'ultima release supportata dal vendor.
Patch e advisory
- Patch: git.kernel.org/stable/c/5189368f10903956be05062d160…
- Patch: git.kernel.org/stable/c/73fbc5d1a9ccb626937500bbd67…
- Patch: git.kernel.org/stable/c/8930878101cd40063888a68af73…
- Patch: git.kernel.org/stable/c/91f25749aaf57c47ae1e1247814…
- Patch: git.kernel.org/stable/c/97900f512252a59f23d6ce4ab21…
- Patch: git.kernel.org/stable/c/aba0b4bc09376dfc3d53c826514…
- Patch: git.kernel.org/stable/c/e075ec9b08f862dade801148105…
- Patch: git.kernel.org/stable/c/e4ff4e3ffcf9d5aad380cdd1d8c…
Mitigazioni temporanee
Da applicare solo se non è possibile aggiornare subito:
- Ridurre la superficie esposta (disattivare servizi e funzionalità inutilizzati), mantenere attive le protezioni del sistema operativo (ASLR, DEP/NX) e segmentare la rete.
Verifica
- Individuare tutti gli asset con il prodotto interessato (inventario, scanner di vulnerabilità, CMDB).
- Confrontare la versione installata con quelle indicate sopra.
- Applicare l'aggiornamento in un ambiente di test, poi in produzione; riavviare i servizi se richiesto.
- Ripetere la scansione per confermare la correzione.
Configurazioni interessate
| Vendor | Prodotto | Versioni vulnerabili | Corretta in |
|---|---|---|---|
| Linux | Linux Kernel | ≥ 2.6.12.1 < 5.10.252 | 5.10.252 |
| Linux | Linux Kernel | ≥ 5.11 < 5.15.202 | 5.15.202 |
| Linux | Linux Kernel | ≥ 5.16 < 6.1.165 | 6.1.165 |
| Linux | Linux Kernel | ≥ 6.2 < 6.6.128 | 6.6.128 |
| Linux | Linux Kernel | ≥ 6.7 < 6.12.75 | 6.12.75 |
| Linux | Linux Kernel | ≥ 6.13 < 6.18.16 | 6.18.16 |
| Linux | Linux Kernel | ≥ 6.19 < 6.19.6 | 6.19.6 |
| Linux | Linux Kernel | 2.6.12 | — |
| Linux | Linux Kernel | 2.6.12 rc2 | — |
| Linux | Linux Kernel | 2.6.12 rc3 | — |
| Linux | Linux Kernel | 2.6.12 rc4 | — |
| Linux | Linux Kernel | 2.6.12 rc5 | — |
Riferimenti
- Patchhttps://git.kernel.org/stable/c/5189368f10903956be05062d160b2804bf5e5016
- Patchhttps://git.kernel.org/stable/c/73fbc5d1a9ccb626937500bbd67136f077d8237b
- Patchhttps://git.kernel.org/stable/c/8930878101cd40063888a68af73b1b0f8b6c79bc
- Patchhttps://git.kernel.org/stable/c/91f25749aaf57c47ae1e12478144e6ea8c8562f2
- Patchhttps://git.kernel.org/stable/c/97900f512252a59f23d6ce4ab215cc88fed66e68
- Patchhttps://git.kernel.org/stable/c/aba0b4bc09376dfc3d53c826514fe38fc8337f52
- Patchhttps://git.kernel.org/stable/c/e075ec9b08f862dade8011481058f7eb5f716c57
- Patchhttps://git.kernel.org/stable/c/e4ff4e3ffcf9d5aad380cdd1d8cdc008bb34f97d