iio: light: veml6075: add bounds check to veml6075_it_ms index
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
| No fix yet |
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
iio: light: veml6075: add bounds check to veml6075_it_ms index
veml6075_it_ms has 5 elements but VEML6075_CONF_IT can yield values 0-7. If it returns a value >= 5, this causes an out-of-bounds array access. Add a bounds check and return -EINVAL if the index is out of range.
The problem values are reserved so should never be read from the register. Hence this is hardening against fault device, missprogramming or bus corruption.
From the CVE record · Linux
The Linux kernel’s veml6075 light sensor driver can access an array out of bounds when a register yields a reserved index of 5–7. This can occur with a faulty device, misprogramming, or bus corruption; the input does not describe an attacker path or authentication or user-interaction requirements.
Engineers running Linux with the veml6075 light sensor driver should check their kernel; affected versions are not specified.