CVE-2023-52749
JSON

4.7medium

spi: Fix null dereference on suspend

Severity
4.7medium CVSS:3.1 by NVD
Exploit likelihood
0.18% (higher than 8% of CVEs; EPSS, by FIRST)
Published
Last changed
Assigned by
Linux

Description

In the Linux kernel, the following vulnerability has been resolved: spi: Fix null dereference on suspend A race condition exists where a synchronous (noqueue) transfer can be active during a system suspend. This can cause a null pointer dereference exception to occur when the system resumes. Example order of events leading to the exception: 1. spi_sync() calls __spi_transfer_message_noqueue() which sets ctlr->cur_msg 2. Spi transfer begins via spi_transfer_one_message() 3. System is suspended interrupting the transfer context 4. System is resumed 6. spi_controller_resume() calls spi_start_queue() which resets cur_msg to NULL 7. Spi transfer context resumes and spi_finalize_current_message() is called which dereferences cur_msg (which is now NULL) Wait for synchronous transfers to complete before suspending by acquiring the bus mutex and setting/checking a suspend flag.

Affected

Product or packageVersionsReported by
Linux Linuxfrom ae7d2346dc89ae89a6e0aabe6037591a11e593c0 before 4ec4508db97502a12daee88c74782e8d35ced068, from ae7d2346dc89ae89a6e0aabe6037591a11e593c0 before 96474ea47dc67b0704392d59192b233c8197db0e, from ae7d2346dc89ae89a6e0aabe6037591a11e593c0 before bef4a48f4ef798c4feddf045d49e53c8a97d5e37, 6.0
Not affected: before 6.0, from 6.1.66 up to 6.1.*, from 6.6.3 up to 6.6.*, from 6.7 up to *
CVE List
linux linux_kernelbefore 6.1.66, from 6.2 before 6.6.3NVD

Classification

CWE-362CWE-476

SSVC (CISA-ADP): exploitation none, automatable no, technical impact partial.

What each source says

CVE List

In the Linux kernel, the following vulnerability has been resolved: spi: Fix null dereference on suspend A race condition exists where a synchronous (noqueue) transfer can be active during a system suspend. This can cause a null pointer dereference exception to occur when the system resumes. Example order of events leading to the exception: 1. spi_sync() calls __spi_transfer_message_noqueue() which sets ctlr->cur_msg 2. Spi transfer begins via spi_transfer_one_message() 3. System is suspended interrupting the transfer context 4. System is resumed 6. spi_controller_resume() calls spi_start_queue() which resets cur_msg to NULL 7. Spi transfer context resumes and spi_finalize_current_message() is called which dereferences cur_msg (which is now NULL) Wait for synchronous transfers to complete before suspending by acquiring the bus mutex and setting/checking a suspend flag.

NVD (es)

En el kernel de Linux, se resolvió la siguiente vulnerabilidad: spi: corrige la desreferencia nula en suspensión. Existe una condición de ejecución donde una transferencia sincrónica (sin cola) puede estar activa durante una suspensión del sistema. Esto puede provocar que se produzca una excepción de desreferencia de puntero null cuando se reanude el sistema. Ejemplo de orden de eventos que conducen a la excepción: 1. spi_sync() llama a __spi_transfer_message_noqueue() que configura ctlr->cur_msg 2. La transferencia Spi comienza a través de spi_transfer_one_message() 3. El sistema se suspende interrumpiendo el contexto de transferencia 4. El sistema se reanuda 6. spi_controller_resume () llama a spi_start_queue(), lo que restablece cur_msg a NULL 7. El contexto de transferencia de Spi se reanuda y se llama a spi_finalize_current_message(), lo que desreferencia cur_msg (que ahora es NULL) Espere a que se completen las transferencias sincrónicas antes de suspender adquiriendo el mutex del bus y configurando/verificando una bandera suspendida.

References

Sources

SourceRecordLicence
CVE ListCVE-2023-52749 changed 2026-05-11CVE Terms of Use
NVDCVE-2023-52749 changed 2026-06-17Public domain