Every CVE Search/ Get API key

CVE-2018-5268

Out-of-bounds Write in OpenCV.

5.5 MediumFix available

In OpenCV 3.3.1, a heap-based buffer overflow happens in cv::Jpeg2KDecoder::readComponent8u in modules/imgcodecs/src/grfmt_jpeg2000.cpp when parsing a crafted image file.

Attack profile

How easy it is to exploit

Attack vector
Local
Complexity
Low
Privileges needed
None
User interaction
Required

What an attacker can affect

Confidentiality
None
Integrity
None
Availability
High

Exploit likelihood

1.52%Up 0.5 points since Apr 14, 2021
90%50%10%1%

What each source reports

NVD Score used 5.5

In OpenCV 3.3.1, a heap-based buffer overflow happens in cv::Jpeg2KDecoder::readComponent8u in modules/imgcodecs/src/grfmt_jpeg2000.cpp when parsing a crafted image file.

Record
CVE-2018-5268
CVSS 3.1
5.5 MediumCVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:N/I:N/A:H
CVSS 2.0
4.3 MediumAV:N/AC:M/Au:N/C:N/I:N/A:P
Weakness
CWE-787
Updated
2026-11-02
CVE List No score

In OpenCV 3.3.1, a heap-based buffer overflow happens in cv::Jpeg2KDecoder::readComponent8u in modules/imgcodecs/src/grfmt_jpeg2000.cpp when parsing a crafted image file.

Record
CVE-2018-5268
Updated
2026-11-02
EUVDEUVD-2021-2185 No score

In OpenCV 3.3.1, a heap-based buffer overflow happens in cv::Jpeg2KDecoder::readComponent8u in modules/imgcodecs/src/grfmt_jpeg2000.cpp when parsing a crafted image file.

Record
EUVD-2021-2185
Updated
2026-11-03
GitHub AdvisoriesGHSA-9g8h-pjm4-q92p 5.5

Out-of-bounds Write in OpenCV.

In OpenCV 3.3.1 (corresponding with OpenCV-Python 3.3.1.11), a heap-based buffer overflow happens in cv::Jpeg2KDecoder::readComponent8u in modules/imgcodecs/src/grfmt_jpeg2000.cpp when parsing a crafted image file.

Record
GHSA-9g8h-pjm4-q92p
CVSS 3.0
5.5 MediumCVSS:3.0/AV:L/AC:L/PR:N/UI:R/S:U/C:N/I:N/A:H
Weakness
CWE-787
Updated
2026-11-02
OSV 5.5

In OpenCV 3.3.1, a heap-based buffer overflow happens in cv::Jpeg2KDecoder::readComponent8u in modules/imgcodecs/src/grfmt_jpeg2000.cpp when parsing a crafted image file.

Record
CVE-2018-5268
CVSS 3.1
5.5 MediumCVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:N/I:N/A:H
Updated
2026-11-02
OSVDEBIAN-CVE-2018-5268 5.5

In OpenCV 3.3.1, a heap-based buffer overflow happens in cv::Jpeg2KDecoder::readComponent8u in modules/imgcodecs/src/grfmt_jpeg2000.cpp when parsing a crafted image file.

Record
DEBIAN-CVE-2018-5268
CVSS 3.1
5.5 MediumCVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:N/I:N/A:H
Updated
2026-11-02
Show 4 moreShow less
OSVGHSA-9g8h-pjm4-q92p 5.5

Out-of-bounds Write in OpenCV.

In OpenCV 3.3.1 (corresponding with OpenCV-Python 3.3.1.11), a heap-based buffer overflow happens in cv::Jpeg2KDecoder::readComponent8u in modules/imgcodecs/src/grfmt_jpeg2000.cpp when parsing a crafted image file.

Record
GHSA-9g8h-pjm4-q92p
CVSS 3.0
5.5 MediumCVSS:3.0/AV:L/AC:L/PR:N/UI:R/S:U/C:N/I:N/A:H
Weakness
CWE-787
Updated
2026-11-02
OSVPYSEC-2026-2814 5.5

Out-of-bounds Write in OpenCV.

In OpenCV 3.3.1 (corresponding with OpenCV-Python 3.3.1.11), a heap-based buffer overflow happens in cv::Jpeg2KDecoder::readComponent8u in modules/imgcodecs/src/grfmt_jpeg2000.cpp when parsing a crafted image file.

Record
PYSEC-2026-2814
CVSS 3.0
5.5 MediumCVSS:3.0/AV:L/AC:L/PR:N/UI:R/S:U/C:N/I:N/A:H
Updated
2026-11-02
OSVPYSEC-2026-705 5.5

Out-of-bounds Write in OpenCV.

In OpenCV 3.3.1 (corresponding with OpenCV-Python 3.3.1.11), a heap-based buffer overflow happens in cv::Jpeg2KDecoder::readComponent8u in modules/imgcodecs/src/grfmt_jpeg2000.cpp when parsing a crafted image file.

Record
PYSEC-2026-705
CVSS 3.0
5.5 MediumCVSS:3.0/AV:L/AC:L/PR:N/UI:R/S:U/C:N/I:N/A:H
Updated
2026-11-02
OSVUBUNTU-CVE-2018-5268 5.5

In OpenCV 3.3.1, a heap-based buffer overflow happens in cv::Jpeg2KDecoder::readComponent8u in modules/imgcodecs/src/grfmt_jpeg2000.cpp when parsing a crafted image file.

Record
UBUNTU-CVE-2018-5268
CVSS 3.1
5.5 MediumCVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:N/I:N/A:H
CVSS 3.0
5.5 MediumCVSS:3.0/AV:L/AC:L/PR:N/UI:R/S:U/C:N/I:N/A:H
Updated
2026-11-02

Affected products

Affected packages

Affected packages
PackageAffectedFixed
opencv-python
PyPI
through 3.3.1.11
3.4.1.15
opencv-contrib-python
PyPI
through 3.3.1.11
3.4.1.15
opencv
Debian:12
before 3.2.0+dfsg-6
3.2.0+dfsg-6
opencv
Debian:13
before 3.2.0+dfsg-6
3.2.0+dfsg-6
opencv
Debian:14
before 3.2.0+dfsg-6
3.2.0+dfsg-6
opencv
Debian:7
before 2.3.1-11+deb7u4, plus listed versions
2.3.1-112.3.1-11+deb7u12.3.1-11+deb7u22.3.1-11+deb7u3
2.3.1-11+deb7u4
opencv
Debian:8
before 2.4.9.1+dfsg-1+deb8u2, plus listed versions
2.4.9.1+dfsg-12.4.9.1+dfsg-1+deb8u1
2.4.9.1+dfsg-1+deb8u2
opencv
Debian:9
before 2.4.9.1+dfsg1-2+deb9u1, plus listed versions
2.4.9.1+dfsg1-2
2.4.9.1+dfsg1-2+deb9u1
opencv-python
PyPI
before 3.4.1.15, plus listed versions
3.4.0.14
3.4.1.15
opencv-contrib-python
PyPI
before 3.4.1.15
3.4.1.15
opencv
Ubuntu:16.04:LTS
before 2.4.9.1+dfsg-1.5ubuntu1.1, plus listed versions
2.4.9+dfsg-1ubuntu62.4.9.1+dfsg-1.2ubuntu12.4.9.1+dfsg-1.3ubuntu12.4.9.1+dfsg-1.5ubuntu1
2.4.9.1+dfsg-1.5ubuntu1.1
opencv
Ubuntu:18.04:LTS
before 3.2.0+dfsg-4ubuntu0.1, plus listed versions
3.1.0+dfsg1-1~exp1ubuntu33.2.0+dfsg-33.2.0+dfsg-43.2.0+dfsg-4build13.2.0+dfsg-4build2
3.2.0+dfsg-4ubuntu0.1

History

History
RecordedChangedSources
aliasesEUVD
first indexedCVE List, GitHub Advisories, NVD, OSV

Dates are when Every CVE recorded each change. Upstream dates may differ.

In short

CVE-2018-5268 is a medium vulnerability (CVSS 5.5) in Opencv, published January 8, 2018. No source lists public exploit code. EPSS puts the chance of exploitation in the next 30 days at 1.52%, the 74th percentile. Fixed in opencv-python 3.4.1.15.

References

Show 8 moreShow less
MoveEnter Open