clk: bcm: rpi: Add NULL check in raspberrypi_clk_register()
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
≥ 93d2725affd65686792f4b57e49ef660f3c8c0f9 · < 1b69a5299f28ce8e6afa37c3690dbc14c3a1f53f| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
clk: bcm: rpi: Add NULL check in raspberrypi_clk_register()
devm_kasprintf() returns NULL when memory allocation fails. Currently, raspberrypi_clk_register() does not check for this case, which results in a NULL pointer dereference.
Add NULL check after devm_kasprintf() to prevent this issue.
From the CVE record · Linux
The Linux kernel's raspberrypi_clk_register() does not check whether devm_kasprintf() failed to allocate memory. If that allocation fails, the kernel can dereference a NULL pointer. The input does not establish an attack path or whether authentication or user interaction is required.
Engineers running the Linux kernel with the Raspberry Pi clock component should check their deployments; affected versions are not specified.