Why is Microsoft reissuing this bulletin?
Subsequent to the release of this bulletin it was determined that the vulnerability is not in the OpenRowSet command, which is a SQL Server command. Rather, the vulnerability is with the underlying MDAC component ODBC, which is present in all versions of Windows. Additionally, the original patch did not install correctly on some systems because of a flaw in the way that Microsoft Windows Installer updated the System File Protection cache. The bulletin has been updated to include this additional information and to direct users to an updated patch.
The updated patch is included with the MS03-033 bulletin, not this bulletin. Why?
The original patch in this bulletin is superceded by the patch in MS03-033. The MS03-033 patch contains the fix for this vulnerability, as well as an additional security vulnerability that is discussed in MS03-033. Customers who are seeking the patch for MS02-040 should instead apply the patch from MS03-033.
What is the scope of this vulnerability?
This is a buffer overrun vulnerability. An attacker who successfully exploited this flaw could gain complete control over the affected process, thereby gaining the ability to take any action at the same level of privilege as the exploited ODBC process under which it is running. This could include creating, modifying, or deleting data on the system, or reconfiguring the system. This could also include reformatting the hard disk or running programs of the attacker's choice.
What causes the vulnerability?
The vulnerability results because a flaw in the Microsoft Data Access Components that provides some of the underlying functionality that is used to load an ODBC driver and to connect to a data source. This function contains an unchecked buffer. An attacker could seek to exploit this by using HTML e-mail or by using an ActiveX control. An attacker might seek to exploit this vulnerability by using this vector because some ActiveX controls provide access to MDAC functionality. Also, it could be possible to exploit this vulnerability on systems that are running SQL Server by using the Transact-SQL OpenRowSet command by submitting a database query that contains a specially malformed parameter within a call to OpenRowSet.
What is Microsoft Data Access Components?
Microsoft Data Access Components (MDAC) is a collection of components that make it easy for programs to access databases and then to manipulate the data within them. Modern databases may take a variety of forms (for example, SQL databases, Microsoft Access databases, and XML files) and may be housed in a variety of locations (for example, on the local system or on a remote database server). MDAC provides a consolidated set of functions for working with different kinds of data sources in a consistent manner. One of the MDAC components is known as ODBC.
What is ODBC?
ODBC (Open Database Connectivity) is a standard application programming interface (API) for accessing a data source. It is a component of MDAC and is an interface that allows applications to access data in any database for which there is an ODBC driver. By using ODBC, you can create database applications with access to any database for which an ODBC driver exists. Windows contains drivers for Microsoft Excel, Access, and SQL Server, for example.
What could an attacker do by exploiting the vulnerability?
It would depend on the specific way that the attacker overran the buffer. If the attacker provided input data that overran the buffer with random data, it could cause the attacker's application to fail, which would not pose a security risk to the user. On the other hand, if the attacker carefully selected the data, it would be possible to modify the functionality of MDAC to perform any task that the attacker specified.
| • | An attacker could seek to exploit the vulnerability by constructing a Web page that, when visited by the user, would execute code of the attacker's choice with the logged on user's privileges. The Web page could be hosted on a Web site or sent directly to the user in an e-mail message. |
| • | It could also be possible to exploit this vulnerability using the Transact-SQL OpenRowSet command. An attacker could submit a database query that contains a specially malformed parameter within a call to OpenRowSet that could overrun the buffer, either to cause the server that is running SQL Server to fail or to cause the SQL Server service to take actions that are dictated by the attacker. |
How do I know which version of the patch I need?
There is a patch for each supported version of MDAC. The following table shows which version of MDAC was supplied with various Microsoft products:
MDAC 2.5 | Windows 2000, Office 2000 SR1 and later, SQL Server 7.0 Service Packs 2 and later |
MDAC 2.6 | SQL Server 2000 |
MDAC 2.7 | Windows XP, Visual Studio .Net |
A second way to determine the version of MDAC that you are using is to consult the HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\DataAccess registry key. The FullInstallVer key provides a value of the form x.xx.yyyy.y, where x.xx is the version number (for example, if the FullInstallVer value is 2.70.7713.0, MDAC 2.7 is installed on the system). A third way to determine the version of MDAC is to right-click the C:\Program Files\Common Files\System\Ado\Msado15.dll file, click Properties, click the Version tab, and then see the version information. The version information has the same format as that of the FullInstallVer value, x.xx.yyyy.y, where x.xx is the version number.
I see that MDAC was included with various versions of Windows and Office. Does this mean that anyone who is using these versions of Windows or Office needs the patch?
Yes. Because many different applications use the MDAC component ODBC, anyone who is using a product that included MDAC should apply the patch. MDAC is a ubiquitous technology that is included with many Microsoft products:
| • | By default, MDAC is included as part of Microsoft Windows XP, Windows 2000, and Windows Millennium Edition. |
| • | MDAC is available for download as a stand-alone technology. |
| • | MDAC is either included in or installed by a number of other products and technologies. For example, MDAC is included in the Microsoft Windows NT® 4.0 Option Pack, as part of Microsoft Access, and as part of SQL Server. Some MDAC components are also present as part of Microsoft Internet Explorer even if MDAC itself is not installed. |
A tool is also available that can help you determine what version of MDAC is running on your system. Microsoft Knowledge Base Article 307255 describes this tool and how to use it.
How does the patch eliminate the vulnerability?
The patch institutes proper buffer handling in the vulnerable function.