Microsoft ODBC Driver for SQL Server Remote Code Execution Vulnerability (CVE-2024-28931)
The Microsoft ODBC Driver for SQL Server could allow remote code execution when a user connects to a malicious SQL server. An attacker could trick an authenticated user into connecting via ODBC, causing the client to receive a malicious networking packet and potentially execute code remotely.
FAQ
How could an attacker exploit this vulnerability? An attacker could exploit the vulnerability by tricking an authenticated user into attempting to connect to a malicious SQL server via ODBC, which could result in the client receiving a malicious networking packet. This could allow the attacker to execute code remotely on the client.
FAQ
According to the CVSS metric, user interaction is required (UI:R). What interaction would the user have to do? An attacker could exploit the vulnerability by tricking an authenticated user (CVSS metric UI:R) into attempting to connect to a malicious SQL server via a connection driver (for example: ODBC and / or OLEDB as applicable).
FAQ
I am running SQL Server on my system. What action do I need to take? Update your relevant version of SQL Server. Any applicable driver fixes are included in those updates. I am running my own application on my system. What action do I need to take? Update your application to use Microsoft ODBC Driver 17 or 18 for SQL Server. Update the drivers to the versions listed on this page, which provide protection against this vulnerability. I am running an application from a software vendor on my system. What action do I need to take? Consult with your application vendor if it is compatible with Microsoft ODBC Driver 17 or 18 for SQL Server. Update the drivers to the versions listed in this page, which provide protection against this vulnerability There are GDR and/or CU (Cumulative Update) updates offered for my version of SQL Server. How do I know which update to use? First, determine your SQL Server version number. For more information on determining your SQL Server version number, see Microsoft Knowledge Base Article 321185 - How to determine the version, edition, and update level of SQL Server and its components. Second, in the table below, locate your version number or the version range that your version number falls within. The corresponding update is the one you need to install. Note If your SQL Server version number is not represented in the table below, your SQL Server version is no longer supported. Please upgrade to the latest Service Pack or SQL Server product in order to apply this and future security updates. Update Number Title Apply if current product version is… This security update also includes servicing releases up through… 5036343 Security update for SQL Server 2022 CU12+GDR 16.0.4003.1 - 16.0.4115.5 KB 5033663 - SQL2022 RTM CU12 5035432 Security update for SQL Server 2022 RTM+GDR 16.0.1000.6 - 16.0.1110.1 KB 5032968 - Previous SQL2022 RTM GDR 5036335 Security update for SQL Server 2019 CU25+GDR 15.0.4003.23 - 15.0.4355.3 KB 5033688 - SQL2019 RTM CU25 5035434 Security update for SQL Server 2019 RTM+GDR 15.0.2000.5 - 15.0.2104.1 KB 5029377 - Previous SQL2019 RTM GDR What are the GDR and CU update designations and how do they differ? The General Distribution Release (GDR) and Cumulative Update (CU) designations correspond to the two different servicing options in place for SQL Server baseline releases. A baseline can be either an RTM release or a Service Pack release. GDR updates – cumulatively only contain security updates for the given baseline. CU updates – cumulatively contain all functional fixes and security updates for the given baseline. For any given baseline, either the GDR or CU updates could be options (see below). If SQL Server installation is at a baseline version, you can choose either the GDR or CU update. If SQL Server installation has intentionally only installed past GDR updates, then choose to install the GDR update package. If SQL Server installation has intentionally installed previous CU updates, then chose to install the CU security update package. Note: You are allowed to make a change from GDR updates to CU updates ONE TIME. Once a SQL Server CU update is applied to a SQL Server installation, there is NO way to go back to the GDR update path.
SQL Server
SQL Server
Microsoft
Microsoft
Customer Action Required
Yes
Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.
How it worked
Root cause
Likely a memory corruption bug in how the ODBC driver processes network packets from a SQL server.
Impact
An attacker could execute code remotely on the client, but only if the user is authenticated and attempts to connect to the malicious server.
What the attacker needed
Victim is authenticated; victim connects to malicious SQL server
The fix
The vulnerability was fixed by updating to Microsoft ODBC Driver 17 or 18 for SQL Server, or by applying the relevant SQL Server security updates.
Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.
Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.
This is a flaw in a piece of software called a driver, which helps programs talk to a database. If a user is tricked into connecting to a bad database server, that server can send a harmful message that lets the attacker run their own code on the user's computer. The user must first be logged in and then attempt the connection.
What is Memory corruption?
Native code reads or writes memory it should not: overflows, use-after-free, type confusion. The core of browser, kernel and parser bugs.