Descripción
En el kernel de Linux, se resolvió la siguiente vulnerabilidad: blk-mq: configura una cola bajo tag_list_lock blk_mq_init_allocated_queue() solo toma tag_list_lock al final, cuando agrega la cola al conjunto. Antes de eso dimensiona la cola según set->nr_hw_queues, asigna set->tags[], realiza el mapeo según set->map[], y blk_mq_map_swqueue() libera tags del conjunto. Una actualización que borre los mapas en ese momento hace que la nueva cola libere tags que comparten todas las demás colas. Un reinicio de un controlador NVMe durante un escaneo de namespaces hace exactamente eso. Se toma el bloqueo antes de la primera consulta al conjunto. Una actualización puede formar parte del manejo de errores, por lo que las asignaciones bajo el bloqueo no deben esperar operaciones de IO: memalloc_noio_save(), como en add_disk_fwnode().
Qué hacer
Revisa si usas el producto afectado y en qué versión, y aplica la actualización o la mitigación que indique el aviso del fabricante. CISA no ha confirmado que se esté explotando; si eso cambia, esta ficha pasa a «explotada» y te avisamos en el boletín.
Versiones afectadas
- Linux Afectadas: 868f2f0b72068a097508b6e8870a8950fd8eb7ef y anteriores a e7e089b61901be0f4bac6b1d8c8f8e25cf178280 · 868f2f0b72068a097508b6e8870a8950fd8eb7ef y anteriores a 515e211124113b4faecf3b0cb20087965286ee0c · 868f2f0b72068a097508b6e8870a8950fd8eb7ef y anteriores a 4fcc499ea9bc31b02393904a1903e794d146f5f7
- Linux Afectadas: 4.6 No afectadas: 6.18.65 · 7.3.6 · 7.4-rc1
Según el registro de la vulnerabilidad en CVE.org, tal como lo publicó el fabricante. Confirma tu versión exacta en el aviso del fabricante.
Referencias
- Referencia en git.kernel.orggit.kernel.org/stable/c/e7e089b61901be0f4bac6b1d8c8f8e25cf178280
- Referencia en git.kernel.orggit.kernel.org/stable/c/515e211124113b4faecf3b0cb20087965286ee0c
- Referencia en git.kernel.orggit.kernel.org/stable/c/4fcc499ea9bc31b02393904a1903e794d146f5f7
Ver el texto original en inglés (CVE.org)
blk-mq: set up a queue under tag_list_lock
In the Linux kernel, the following vulnerability has been resolved: blk-mq: set up a queue under tag_list_lock blk_mq_init_allocated_queue() only takes tag_list_lock at the end, when it adds the queue to the set. Before that it sizes the queue by set->nr_hw_queues, hands out set->tags[], maps by set->map[], and blk_mq_map_swqueue() frees tags of the set. An update clearing the maps at that time makes the new queue free tags that all the other queues share. An NVMe controller reset during a namespace scan does exactly that. Take the lock before the first look at the set. An update can be part of error handling, so the allocations under the lock must not wait for IO: memalloc_noio_save(), as in add_disk_fwnode().