CVE Vulnerabilities

CVE-2022-1122

Improper Initialization

Published: Mar 29, 2022 | Modified: Nov 07, 2023
CVSS 3.x
5.5
MEDIUM
Source:
NVD
CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:N/I:N/A:H
CVSS 2.x
4.3 MEDIUM
AV:N/AC:M/Au:N/C:N/I:N/A:P
RedHat/V2
RedHat/V3
5.1 LOW
CVSS:3.1/AV:L/AC:H/PR:N/UI:N/S:U/C:N/I:N/A:H
Ubuntu
LOW

A flaw was found in the opj2_decompress program in openjpeg2 2.4.0 in the way it handles an input directory with a large number of files. When it fails to allocate a buffer to store the filenames of the input directory, it calls free() on an uninitialized pointer, leading to a segmentation fault and a denial of service.

Weakness

The product does not initialize or incorrectly initializes a resource, which might leave the resource in an unexpected state when it is accessed or used.

Affected Software

Name Vendor Start Version End Version
Openjpeg Uclouvain 2.4.0 (including) 2.4.0 (including)
Red Hat Enterprise Linux 8 RedHat openjpeg2-0:2.4.0-5.el8 *
Red Hat Enterprise Linux 9 RedHat openjpeg2-0:2.4.0-7.el9 *
Blender Ubuntu bionic *
Blender Ubuntu impish *
Blender Ubuntu kinetic *
Blender Ubuntu lunar *
Blender Ubuntu mantic *
Blender Ubuntu trusty *
Blender Ubuntu xenial *
Ghostscript Ubuntu trusty *
Ghostscript Ubuntu xenial *
Insighttoolkit4 Ubuntu bionic *
Insighttoolkit4 Ubuntu impish *
Insighttoolkit4 Ubuntu kinetic *
Insighttoolkit4 Ubuntu lunar *
Insighttoolkit4 Ubuntu trusty *
Insighttoolkit4 Ubuntu xenial *
Openjpeg Ubuntu upstream *
Openjpeg2 Ubuntu bionic *
Openjpeg2 Ubuntu impish *
Openjpeg2 Ubuntu kinetic *
Openjpeg2 Ubuntu lunar *
Openjpeg2 Ubuntu upstream *
Openjpeg2 Ubuntu xenial *
Qtwebengine-opensource-src Ubuntu bionic *
Qtwebengine-opensource-src Ubuntu impish *
Qtwebengine-opensource-src Ubuntu kinetic *
Qtwebengine-opensource-src Ubuntu lunar *
Qtwebengine-opensource-src Ubuntu mantic *
Texmaker Ubuntu bionic *
Texmaker Ubuntu impish *
Texmaker Ubuntu kinetic *
Texmaker Ubuntu lunar *
Texmaker Ubuntu mantic *
Texmaker Ubuntu trusty *
Texmaker Ubuntu xenial *

Potential Mitigations

  • Use a language that does not allow this weakness to occur or provides constructs that make this weakness easier to avoid.
  • For example, in Java, if the programmer does not explicitly initialize a variable, then the code could produce a compile-time error (if the variable is local) or automatically initialize the variable to the default value for the variable’s type. In Perl, if explicit initialization is not performed, then a default value of undef is assigned, which is interpreted as 0, false, or an equivalent value depending on the context in which the variable is accessed.

References