ubi: Fix rollback for explicit UBI device numbers
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
≥ 83ff59a066637a6c28844bbf43009459408240f4 · < e3f7e58189bc222971ddc860f1716f37e51ba996| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
ubi: Fix rollback for explicit UBI device numbers
ubi_init_attach() rolls back module initialization failures by scanning ubi_devices[0..i-1], where i is the mtd= parameter index. That assumes the parameter index matches the UBI device number.
That assumption is not true when mtd= specifies an explicit ubi_num. A successfully attached device can be stored at a higher ubi_devices[] slot, and a later failure can miss it during rollback.
Scan the full ubi_devices[] array and detach by the actual array index, matching the way UBI devices are stored.
From the CVE record · Linux
Linux kernel UBI initialization can fail to detach a previously attached device during rollback when an mtd= parameter specifies an explicit UBI device number and a later initialization step fails. The input does not establish an attacker action or specify network access, authentication, or user interaction requirements.
Engineers running the Linux kernel with UBI devices configured through mtd= parameters that specify explicit UBI device numbers should check their deployments; affected versions are not provided.