CVE-2024-50287
JSON

5.5medium

media: v4l2-tpg: prevent the risk of a division by zero

Severity
5.5medium CVSS:3.1 by CISA-ADP
Exploit likelihood
0.25% (higher than 18% of CVEs; EPSS, by FIRST)
Published
Last changed
Assigned by
Linux

Description

In the Linux kernel, the following vulnerability has been resolved: media: v4l2-tpg: prevent the risk of a division by zero As reported by Coverity, the logic at tpg_precalculate_line() blindly rescales the buffer even when scaled_witdh is equal to zero. If this ever happens, this will cause a division by zero. Instead, add a WARN_ON_ONCE() to trigger such cases and return without doing any precalculation.

Affected

Product or packageVersionsReported by
Linux Linuxfrom 63881df94d3ecbb0deafa0b77da62ff2f32961c4 before e3c36d0bde309f690ed1f9cd5f7e63b3a513f94a, from 63881df94d3ecbb0deafa0b77da62ff2f32961c4 before 0bfc6e38ee2250f0503d96f1a1de441c31d88715, from 63881df94d3ecbb0deafa0b77da62ff2f32961c4 before 054931ca3cfcb8e8fa036e887d6f379942b02565, from 63881df94d3ecbb0deafa0b77da62ff2f32961c4 before a749c15dccc58d9cbad9cd23bd8ab4b5fa96cf47, from 63881df94d3ecbb0deafa0b77da62ff2f32961c4 before c63c30c9d9f2c8de34b16cd2b8400240533b914e, from 63881df94d3ecbb0deafa0b77da62ff2f32961c4 before 2d0f01aa602fd15a805771bdf3f4d9a9b4df7f47, from 63881df94d3ecbb0deafa0b77da62ff2f32961c4 before 0cdb42ba0b28f548c1a4e86bb8489dba0d78fc21, from 63881df94d3ecbb0deafa0b77da62ff2f32961c4 before e6a3ea83fbe15d4818d01804e904cbb0e64e543b and 1 more
Not affected: before 3.18, from 4.19.324 up to 4.19.*, from 5.4.286 up to 5.4.*, from 5.10.230 up to 5.10.*, from 5.15.172 up to 5.15.*, from 6.1.117 up to 6.1.*
CVE List
linux linux_kernelfrom 3.18 before 4.19.324, from 4.20 before 5.4.286, from 5.5 before 5.10.230, from 5.11 before 5.15.172, from 5.16 before 6.1.117, from 6.2 before 6.6.61, from 6.7 before 6.11.8, 6.12NVD

All scores

CISA-ADP5.5medium CVSS:3.1CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H
NVD5.5medium CVSS:3.1CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H

Classification

CWE-369

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: media: v4l2-tpg: prevent the risk of a division by zero As reported by Coverity, the logic at tpg_precalculate_line() blindly rescales the buffer even when scaled_witdh is equal to zero. If this ever happens, this will cause a division by zero. Instead, add a WARN_ON_ONCE() to trigger such cases and return without doing any precalculation.

NVD (es)

En el kernel de Linux, se ha resuelto la siguiente vulnerabilidad: media: v4l2-tpg: evitar el riesgo de una división por cero Como lo informó Coverity, la lógica en tpg_precalculate_line() reescala ciegamente el búfer incluso cuando scaled_witdh es igual a cero. Si esto sucede alguna vez, provocará una división por cero. En su lugar, agregue un WARN_ON_ONCE() para activar dichos casos y regresar sin realizar ningún cálculo previo.

References

Sources

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