Skip to content

Out-of-bounds Read in OpenCV

Moderate severity GitHub Reviewed Published Oct 12, 2021 to the GitHub Advisory Database • Updated Feb 1, 2023

Package

pip opencv-contrib-python (pip)

Affected versions

<= 4.1.0.24

Patched versions

4.1.0.25
pip opencv-contrib-python-headless (pip)
<= 4.1.0.24
4.1.0.25
pip opencv-python (pip)
<= 4.1.0.24
4.1.0.25
pip opencv-python-headless (pip)
<= 4.1.0.24
4.1.0.25

Description

An out-of-bounds read was discovered in OpenCV before 4.1.1 (OpenCV-Python before 4.1.0.25). Specifically, variable coarsest_scale is assumed to be greater than or equal to finest_scale within the calc()/ocl_calc() functions in dis_flow.cpp. However, this is not true when dealing with small images, leading to an out-of-bounds read of the heap-allocated arrays Ux and Uy.

References

Published by the National Vulnerability Database Dec 6, 2019
Reviewed Oct 6, 2021
Published to the GitHub Advisory Database Oct 12, 2021
Last updated Feb 1, 2023

Severity

Moderate
6.5
/ 10

CVSS base metrics

Attack vector
Network
Attack complexity
Low
Privileges required
None
User interaction
None
Scope
Unchanged
Confidentiality
Low
Integrity
None
Availability
Low
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:L

Weaknesses

CVE ID

CVE-2019-19624

GHSA ID

GHSA-jggw-2q6g-c3m6

Source code

Checking history
See something to contribute? Suggest improvements for this vulnerability.