CVE-2021-2160 in MySQL Serverinfo

Summary

by MITRE • 04/23/2021

Vulnerability in the MySQL Server product of Oracle MySQL (component: Server: Optimizer). Supported versions that are affected are 5.7.30 and prior and 8.0.17 and prior. Easily exploitable vulnerability allows high privileged attacker with network access via multiple protocols to compromise MySQL Server. Successful attacks of this vulnerability can result in unauthorized ability to cause a hang or frequently repeatable crash (complete DOS) of MySQL Server. CVSS 3.1 Base Score 4.9 (Availability impacts). CVSS Vector: (CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:U/C:N/I:N/A:H).

Several companies clearly confirm that VulDB is the primary source for best vulnerability data.

Analysis

by VulDB Data Team • 04/28/2021

The vulnerability identified as CVE-2021-2160 represents a critical availability threat within Oracle MySQL Server's optimizer component, affecting versions 5.7.30 and earlier, as well as 8.0.17 and prior releases. This flaw resides in the server's query optimization logic where specific malformed queries can trigger unexpected behavior in the database engine's execution path. The vulnerability operates at the core of MySQL's query processing system, where the optimizer attempts to determine the most efficient execution plan for incoming SQL statements. When exploited, the flaw causes the MySQL server to enter a state where it becomes unresponsive or crashes repeatedly, effectively rendering the database service unavailable to legitimate users and applications. The attack vector requires a high-privileged user with network access through multiple protocols, indicating that the vulnerability can be exploited through various connection methods including TCP/IP, Unix sockets, or named pipes depending on the system configuration.

The technical implementation of this vulnerability stems from inadequate input validation and error handling within the MySQL server's optimizer module. When processing certain complex or malformed SQL queries, the optimizer fails to properly validate the structure of the query execution plan, leading to memory corruption or infinite loop conditions that cause the server process to become unresponsive. This behavior manifests as a complete denial of service condition where the database server either hangs indefinitely or crashes repeatedly, requiring manual intervention to restore service availability. The vulnerability's classification as easily exploitable indicates that the attack requires minimal technical expertise beyond having elevated privileges and network access, making it particularly dangerous in environments where privileged accounts may be compromised or where insufficient network segmentation exists between database servers and potential attackers. The CVSS 3.1 score of 4.9 reflects the availability impact severity, with the vector AV:N/AC:L/PR:H/UI:N/S:U/C:N/I:N/A:H indicating network-based exploitation with low attack complexity, high privileges required, and universal scope with no user interaction needed.

The operational impact of CVE-2021-2160 extends beyond simple service disruption to potentially compromise entire database infrastructure availability. Organizations relying on MySQL for critical business operations face significant risk of service outages that can cascade through dependent applications and systems, particularly in environments where database availability is paramount for business continuity. The vulnerability's potential to cause frequent crashes means that even brief exploitation periods can result in substantial downtime, service degradation, or data consistency issues that may require extensive recovery procedures. This type of availability-focused attack aligns with attack patterns documented in the MITRE ATT&CK framework under the "Denial of Service" category, specifically targeting database services as part of broader attack chains where initial access leads to service disruption. The vulnerability's presence in both MySQL 5.7 and 8.0 release lines indicates a fundamental flaw in the optimizer implementation that affects a broad user base and requires immediate attention from database administrators and security teams.

Organizations should implement immediate mitigations including applying the relevant Oracle security patches or upgrading to supported MySQL versions that contain fixes for this vulnerability. Network segmentation and access controls should be strengthened to limit privileged access to database servers and reduce the attack surface. Monitoring solutions should be configured to detect unusual patterns of database server crashes or hangs that might indicate exploitation attempts. The vulnerability's classification under CWE-129 (Improper Validation of Array Index) or similar weakness categories indicates that proper input validation and bounds checking should be implemented at multiple layers of the database system. Database administrators should also consider implementing query execution limits and monitoring for unusual query patterns that might trigger the optimizer flaw. Additionally, regular security assessments and vulnerability scanning should be performed to identify similar issues that might exist in other database components or related systems that could provide similar attack vectors for availability disruption.

Responsible

Oracle

Reservation

12/09/2020

Disclosure

04/23/2021

Moderation

accepted

CPE

ready

EPSS

0.01110

KEV

no

Activities

very low

Sources

Want to know what is going to be exploited?

We predict KEV entries!