staging: iio: frequency: ad9834: Validate frequency parameter value
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
≥ 12b9d5bf76bfa20d3207ef24fca9c8254a586a58 · < dc12e49f970b08d8b007b8981b97e2eb93c0e89d| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
staging: iio: frequency: ad9834: Validate frequency parameter value
In ad9834_write_frequency() clk_get_rate() can return 0. In such case ad9834_calc_freqreg() call will lead to division by zero. Checking 'if (fout > (clk_freq / 2))' doesn't protect in case of 'fout' is 0. ad9834_write_frequency() is called from ad9834_write(), where fout is taken from text buffer, which can contain any value.
Modify parameters checking.
Found by Linux Verification Center (linuxtesting.org) with SVACE.
From the CVE record · Linux
The Linux kernel’s ad9834 frequency driver can divide by zero when the clock rate is zero. A frequency value supplied through the driver’s text-based write interface can trigger the error; the input does not specify authentication requirements.
Engineers running Linux kernels with the ad9834 frequency driver should check whether their kernel includes the fix; affected versions are not specified.