CVE Vulnerabilities

CVE-2021-20588

Improper Restriction of Operations within the Bounds of a Memory Buffer

Published: Feb 19, 2021 | Modified: Oct 18, 2023
CVSS 3.x
9.8
CRITICAL
Source:
NVD
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
CVSS 2.x
7.5 HIGH
AV:N/AC:L/Au:N/C:P/I:P/A:P
RedHat/V2
RedHat/V3
Ubuntu

Improper handling of length parameter inconsistency vulnerability in Mitsubishi Electric FA Engineering Software(CPU Module Logging Configuration Tool versions 1.112R and prior, CW Configurator versions 1.011M and prior, Data Transfer versions 3.44W and prior, EZSocket versions 5.4 and prior, FR Configurator all versions, FR Configurator SW3 all versions, FR Configurator2 versions 1.24A and prior, GT Designer3 Version1(GOT1000) versions 1.250L and prior, GT Designer3 Version1(GOT2000) versions 1.250L and prior, GT SoftGOT1000 Version3 versions 3.245F and prior, GT SoftGOT2000 Version1 versions 1.250L and prior, GX Configurator-DP versions 7.14Q and prior, GX Configurator-QP all versions, GX Developer versions 8.506C and prior, GX Explorer all versions, GX IEC Developer all versions, GX LogViewer versions 1.115U and prior, GX RemoteService-I all versions, GX Works2 versions 1.597X and prior, GX Works3 versions 1.070Y and prior, iQ Monozukuri ANDON (Data Transfer) all versions, iQ Monozukuri Process Remote Monitoring (Data Transfer) all versions, M_CommDTM-HART all versions, M_CommDTM-IO-Link versions 1.03D and prior, MELFA-Works versions 4.4 and prior, MELSEC WinCPU Setting Utility all versions, MELSOFT EM Software Development Kit (EM Configurator) versions 1.015R and prior, MELSOFT Navigator versions 2.74C and prior, MH11 SettingTool Version2 versions 2.004E and prior, MI Configurator versions 1.004E and prior, MT Works2 versions 1.167Z and prior, MX Component versions 5.001B and prior, Network Interface Board CC IE Control utility versions 1.29F and prior, Network Interface Board CC IE Field Utility versions 1.16S and prior, Network Interface Board CC-Link Ver.2 Utility versions 1.23Z and prior, Network Interface Board MNETH utility versions 34L and prior, PX Developer versions 1.53F and prior, RT ToolBox2 versions 3.73B and prior, RT ToolBox3 versions 1.82L and prior, Setting/monitoring tools for the C Controller module (SW4PVC-CCPU) versions 4.12N and prior and SLMP Data Collector versions 1.04E and prior) allows a remote unauthenticated attacker to cause a DoS condition of the software products, and possibly to execute a malicious program on the personal computer running the software products although it has not been reproduced, by spoofing MELSEC, GOT or FREQROL and returning crafted reply packets.

Weakness

The product performs operations on a memory buffer, but it can read from or write to a memory location that is outside of the intended boundary of the buffer.

Affected Software

Name Vendor Start Version End Version
C_controller_module_setting_and_monitoring_tool Mitsubishielectric * *
Cpu_module_logging_configuration_tool Mitsubishielectric * 1.112r (including)
Cw_configurator Mitsubishielectric * 1.011m (including)
Data_transfer Mitsubishielectric * 3.44w (including)
Ezsocket Mitsubishielectric * *
Fr_configurator Mitsubishielectric * *
Fr_configurator_sw3 Mitsubishielectric * *
Fr_configurator2 Mitsubishielectric * 1.24a (including)
Gt_designer3 Mitsubishielectric * 1.250l (including)
Gt_softgot1000 Mitsubishielectric * 3.245f (including)
Gt_softgot2000 Mitsubishielectric * 1.250l (including)
Gx_configurator-dp Mitsubishielectric * 7.14q (including)
Gx_configurator-qp Mitsubishielectric * *
Gx_developer Mitsubishielectric * 8.506c (including)
Gx_explorer Mitsubishielectric * *
Gx_iec_developer Mitsubishielectric * *
Gx_logviewer Mitsubishielectric * 1.115u (including)
Gx_remoteservice-i Mitsubishielectric * *
Gx_works2 Mitsubishielectric * 1.597x (including)
Gx_works3 Mitsubishielectric * 1.070y (including)
Iq_monozukuri_andon Mitsubishielectric - (including) - (including)
Iq_monozukuri_process_remote_monitoring Mitsubishielectric - (including) - (including)
M_commdtm-hart Mitsubishielectric * *
M_commdtm-io-link Mitsubishielectric * *
Melfa-works Mitsubishielectric * 4.4 (including)
Melsec_wincpu_setting_utility Mitsubishielectric * *
Melsoft_em_software_development_kit Mitsubishielectric * *
Melsoft_navigator Mitsubishielectric * 2.74c (including)
Mh11_settingtool_version2 Mitsubishielectric * 2.004e (including)
Mi_configurator Mitsubishielectric * *
Mt_works2 Mitsubishielectric * 1.167z (including)
Mx_component Mitsubishielectric * 5.001b (including)
Network_interface_board_cc-link Mitsubishielectric * *
Network_interface_board_cc_ie_control_utility Mitsubishielectric * *
Network_interface_board_cc_ie_field_utility Mitsubishielectric * *
Network_interface_board_mneth_utility Mitsubishielectric * *
Px_developer Mitsubishielectric * 1.53f (including)
Rt_toolbox2 Mitsubishielectric * 3.73b (including)
Rt_toolbox3 Mitsubishielectric * 1.82l (including)
Setting/monitoring_tools_for_the_c_controller_module Mitsubishielectric * *
Slmp_data_collector Mitsubishielectric * 1.04e (including)

Extended Description

Certain languages allow direct addressing of memory locations and do not automatically ensure that these locations are valid for the memory buffer that is being referenced. This can cause read or write operations to be performed on memory locations that may be associated with other variables, data structures, or internal program data. As a result, an attacker may be able to execute arbitrary code, alter the intended control flow, read sensitive information, or cause the system to crash.

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, many languages that perform their own memory management, such as Java and Perl, are not subject to buffer overflows. Other languages, such as Ada and C#, typically provide overflow protection, but the protection can be disabled by the programmer.

  • Be wary that a language’s interface to native code may still be subject to overflows, even if the language itself is theoretically safe.

  • Use a vetted library or framework that does not allow this weakness to occur or provides constructs that make this weakness easier to avoid.

  • Examples include the Safe C String Library (SafeStr) by Messier and Viega [REF-57], and the Strsafe.h library from Microsoft [REF-56]. These libraries provide safer versions of overflow-prone string-handling functions.

  • Use automatic buffer overflow detection mechanisms that are offered by certain compilers or compiler extensions. Examples include: the Microsoft Visual Studio /GS flag, Fedora/Red Hat FORTIFY_SOURCE GCC flag, StackGuard, and ProPolice, which provide various mechanisms including canary-based detection and range/index checking.

  • D3-SFCV (Stack Frame Canary Validation) from D3FEND [REF-1334] discusses canary-based detection in detail.

  • Consider adhering to the following rules when allocating and managing an application’s memory:

  • Run or compile the software using features or extensions that randomly arrange the positions of a program’s executable and libraries in memory. Because this makes the addresses unpredictable, it can prevent an attacker from reliably jumping to exploitable code.

  • Examples include Address Space Layout Randomization (ASLR) [REF-58] [REF-60] and Position-Independent Executables (PIE) [REF-64]. Imported modules may be similarly realigned if their default memory addresses conflict with other modules, in a process known as “rebasing” (for Windows) and “prelinking” (for Linux) [REF-1332] using randomly generated addresses. ASLR for libraries cannot be used in conjunction with prelink since it would require relocating the libraries at run-time, defeating the whole purpose of prelinking.

  • For more information on these techniques see D3-SAOR (Segment Address Offset Randomization) from D3FEND [REF-1335].

  • Use a CPU and operating system that offers Data Execution Protection (using hardware NX or XD bits) or the equivalent techniques that simulate this feature in software, such as PaX [REF-60] [REF-61]. These techniques ensure that any instruction executed is exclusively at a memory address that is part of the code segment.

  • For more information on these techniques see D3-PSEP (Process Segment Execution Prevention) from D3FEND [REF-1336].

References