High

Integer Overflow or Wraparound in OpenCV

  • Disclosed: 12.10.2021
  • Updated: 11.10.2026 15:17

In opencv/modules/imgcodecs/src/grfmt_pxm.cpp, function ReadNumber did not checkout the input length, which lead to integer overflow. If the image is from remote, may lead to remote code execution or denial of service. This affects OpenCV 3.3 (corresponding with OpenCV-Python version 3.3.0.9) and earlier.

Affected software

Click a technology to see all vulnerabilities affecting it.

PlatformPackageVulnerable versionsFixed in
Python (PyPI) opencv-contrib-python < 3.3.1.11 3.3.1.11
Python (PyPI) opencv-python < 3.3.1.11 3.3.1.11

References

CVSS score 8.8/10
CVSS vector
CVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H
Weakness (CWE)
CWE-190
Platform
Python (PyPI)
Package
opencv-contrib-python, opencv-python
Disclosed
12.10.2021
Updated
11.10.2026 15:17

Sources and licenses

OSV / GitHub Advisory Database - PYSEC-2026-697 - PyPA Advisory Database; CC BY 4.0

OSV / GitHub Advisory Database - PYSEC-2026-2804 - PyPA Advisory Database; CC BY 4.0

OSV / GitHub Advisory Database - GHSA-267x-w5hx-8hjr - CC BY 4.0

Vulnerability history: opencv-python

All published vulnerabilities of this package (Python (PyPI)), newest first. Shows whether this is a one-off slip or a package that needs watching.

All (32) in the archive
Total entries
32
First → latest
10.2021 08.2024
Without a fix
2
Exploited in attacks
0

Severity breakdown

  • High 23
  • Medium 8
  • Unrated 1

Disclosures per year

  1. 2021: 30
  2. 2022: 0
  3. 2023: 1
  4. 2024: 1
  5. 2025: 0
  6. 2026: 0
Severity:
  1. High · 8.8 CVE-2019-5064 < 4.2.0.32 4.2.0.32
  2. High · 8.8 CVE-2019-5063 <= 4.1.0.25 no fix
  3. High · 7.8 CVE-2019-9423 <= 4.1.1.26 no fix
  4. High · 7.5 CVE-2019-14493 < 4.1.1.26 4.1.1.26
  5. High · 7.5 CVE-2019-14492 < 3.4.7.28, >= 4.0.0.21, < 4.1.1.26 3.4.7.28, 4.1.1.26
  6. High · 8.2 CVE-2019-14491 < 3.4.7.28, >= 4.0.0.21, < 4.1.1.26 3.4.7.28, 4.1.1.26
  7. High · 8.8 CVE-2017-1000450 < 3.3.1.11 3.3.1.11
  8. High · 7.5 CVE-2017-18009 < 3.4.1.15 3.4.1.15
  9. Integer Overflow or Wraparound in OpenCV this entry
    High · 8.8 CVE-2017-12864 < 3.3.1.11 3.3.1.11
  10. High · 8.8 CVE-2017-12863 < 3.3.1.11 3.3.1.11
  11. High · 8.8 CVE-2017-12606 < 3.3.1.11 3.3.1.11
  12. High · 8.8 CVE-2017-12605 < 3.3.1.11 3.3.1.11
  13. High · 8.8 CVE-2017-12604 < 3.3.1.11 3.3.1.11
  14. High · 8.8 CVE-2017-12603 < 3.3.1.11 3.3.1.11
  15. High · 7.5 CVE-2017-12602 < 3.3.1.11 3.3.1.11
  16. High · 7.5 CVE-2017-12600 < 3.3.1.11 3.3.1.11
  17. High · 8.8 CVE-2017-12599 < 3.3.1.11 3.3.1.11
  18. High · 8.8 CVE-2017-12598 < 3.3.1.11 3.3.1.11
  19. High · 8.8 CVE-2017-12597 < 3.3.1.11 3.3.1.11
  20. High · 8.8 CVE-2016-1516 < 3.3.1.11 3.3.1.11

Know which vulnerabilities affect your application

With the DockRay integration and software inventory enabled, DockRay checks reported component versions against known vulnerabilities and notifies you about confirmed matches. Coverage depends on the supported technology and available advisory data.

Connect your application
DockRay newsletter

Application security in your inbox

Important vulnerabilities, actionable guidance and practical advice for your applications. Choose your technologies and follow what matters to your project.

  • A daily digest of new vulnerabilities, critical ones included.
  • Notifications about important updates.
  • Practical advice on application security and monitoring.

Leave empty to receive updates for every technology.

Free to subscribe. Unsubscribe with one click in any email.