Security Intelligence Operations - Cisco Systems
Guest
 

Security Intelligence Operations


Microsoft SQL Server Memory Corruption Vulnerability

 
Vulnerability AlertPowered by Cisco Security IntelliShield Alert Manager

Threat Type:Unintended Weakness: Software Fault (Vul)
IntelliShield ID:16191
Version:2
First Published:July 08, 2008 03:27 PM EDT
Last Published:July 09, 2008 06:07 PM EDT
Vector:Network
Authentication:Single
Exploit:Unproven
Port: Not Available
CVE:CVE-2008-0107
BugTraq ID:30119
 
Urgency: Unlikely Use
Credibility: Confirmed
Severity: Moderate Damage
CVSS Base:9.0 CVSS Calculator
CVSS Version 2
CVSS Temporal:6.7
 
Version Summary:

Additional technical details are available for the memory corruption vulnerability in Microsoft SQL Server.

 
 
Description

Microsoft SQL Server, Desktop Engine, and Windows Internal Database contain a vulnerability that could allow an authenticated, remote attacker to execute arbitrary code with the privileges of the affected SQL Server process.

This vulnerability exists due to insufficient validation on certain types of files.  An authenticated, remote attacker could exploit this vulnerability by placing a malicious file on an affected system and then utilizing a SQL statement to cause the affected service to process the file.  Memory corruption resulting from the error could allow the attacker to execute arbitrary code with elevated privileges.

Microsoft has confirmed this vulnerability in a security bulletin and released software updates that correct it.

 
Warning Indicators

The following Microsoft applications are vulnerable:

  • Microsoft SQL Server 7.0 SP4 and prior
  • Microsoft SQL Server 2000 SP4 and prior
  • Microsoft SQL Server 2000 Itanium-based Edition SP4 and prior
  • Microsoft SQL Server 2005 SP2 and prior
  • Microsoft SQL Server 2005 x64 Edition SP2 and prior
  • Microsoft SQL Server 2005 for Itanium-based Systems SP2 and prior 
  • Microsoft Data Engine (MSDE) 1.0 SP4 and prior
  • Microsoft SQL Server 2000 Desktop Engine (MSDE 2000) SP4 and prior
  • Microsoft SQL Server 2005 Express Edition SP2 and prior
  • Microsoft SQL Server 2005 Express Edition with Advanced Services SP2 and prior
  • Microsoft SQL Server 2000 Desktop Engine (WMSDE)
  • Windows Internal Database (WYukon) SP2 and prior
  • Windows Internal Database (WYukon) x64 Edition SP2 and prior
 
IntelliShield Analysis

Attackers require credentials sufficient to authenticate to the affected SQL Server and place a file on the affected system in order to exploit this vulnerability.  The attacker may also require access to internal networks to connect to an affected system.  These access requirements may restrict the source of potential attacks.  If an exploit is successful, the attacker could execute arbitrary code with the privileges of the affected SQL Server process.  By default, SQL Server 2005 does not run with System privileges.  An exploit against that version would likely not result in a system compromise, but could allow an attacker to gain complete control over an affected SQL Server. Other versions may default to Local System privileges, and therefore a successful exploit in such cases may result in a complete system compromise.

If a facility is exposed on websites or other network-accessible applications that allow an unauthenticated user to access the vulnerable application, and if an attacker can identify a method of placing a file and directing input to the affected SQL Server, the attacker could exploit the vulnerability remotely and without authentication.  However, this exploit scenario is highly dependent on site configuration.  An attacker may be able to bypass the authentication requirement by leveraging an unrelated SQL injection vulnerability in a web application hosted on a Microsoft SQL Server.  In this manner, the attacker may be able to place a malicious file on the server.  Due to the recent rise in SQL injection attacks, administrators should take care to mitigate this vulnerability in affected systems.

The Cisco Applied Intelligence team has created an Applied Mitigation Bulletin to address vulnerabilities disclosed in this month's Microsoft security bulletin release that can be identified or mitigated using Cisco devices. This Cisco bulletin is available at the following link: Cisco Applied Mitigation Bulletin: Microsoft Security Bulletin for July 2008

The update from Microsoft corrects this vulnerability by properly validating files loaded by the affected application.

 
Vendor Announcements

Microsoft has released a security bulletin at the following link: MS08-040

 
Impact

An authenticated, remote attacker could exploit this vulnerability to execute arbitrary code with elevated privileges.  A successful exploit may result in a complete system compromise.

 
Technical Information

This vulnerability exists due to an integer underflow error when the affected service processes stored backup files.  Microsoft SQL Server accepts a 32-bit integer value to determine the number of bytes needed to read data into a heap-based buffer.  A malicious value could cause a calculation error, causing the SQL Server to allocate an insufficient amount of memory for the buffer.

An authenticated, remote attacker could exploit this vulnerability by placing a malicious file on the affected system and then processing the file by issuing an SQL statement to the affected SQL Server process.  If successful, the attacker could gain the ability to execute arbitrary code with the privileges of the affected service.

 
Safeguards

Administrators are advised to apply the applicable software updates.

Administrators are advised to restrict network access to affected systems.

Administrators are advised to restrict access to the affected SQL Server.

 
Patches/Software

Microsoft has released updated software at the following links:

GDR Software Updates

QFE Software Updates

Windows Components


Signatures
 
Cisco Systems Cisco Intrusion Prevention System (IPS) 6.0
6792/0SQL Memory Corruption VulnerabilityS41007/03/2009
 
Alert History
 

Version 1, July 8, 2008, 3:27 PM: Microsoft SQL Server contains a vulnerability that could allow an authenticated, remote attacker to execute arbitrary code with the privileges of the affected SQL Server process.  An update is available.



Product Sets
 
The security vulnerability applies to the following combinations of products.

Primary Products:
Microsoft, Inc.Microsoft Data Engine (MSDE)1.0 Base, SP1, SP2, SP3, SP4 | 2000 Base
Microsoft, Inc.Microsoft SQL Server Desktop Engine (MSDE)2000 Base, SP1, SP2, SP3, SP4
Microsoft, Inc.Microsoft SQL Server Express Edition2005 Base, SP1, SP2
Microsoft, Inc.Microsoft SQL Server Express Edition with Advanced2005 Base, SP1, SP2
Microsoft, Inc.SQL Server2000 Base, SP1, SP2, SP3, SP3a, SP4 | 2000 (Itanium) Base, SP1, SP2, SP3, SP4 | 2005 Base, SP1, SP2 | 2005 (Itanium) Base, SP1, SP2 | 2005 (x64) Base, SP1, SP2 | 7.0 Base, SP1, SP2, SP3, SP4
Microsoft, Inc.Windows Internal DatabaseOriginal Release Base, SP2 | x64 Edition Base, SP2

Associated Products:
Microsoft, Inc.Windows 2000Advanced Server Base, SP1, SP2, SP3, SP4 | Professional Base, SP1, SP2, SP3, SP4 | Server Base, SP1, SP2, SP3, SP4
Microsoft, Inc.Windows Server 2003Datacenter Edition Base, SP1, SP2 | Datacenter Edition x64 (AMD/EM64T) Base, SP2 | Enterprise Edition Base, SP1, SP2 | Enterprise Edition x64 (AMD/EM64T) Base, SP2 | Standard Edition Base, SP1, SP2 | Standard Edition x64 (AMD/EM64T) Base, SP2 | Web Edition Base, SP1, SP2
Microsoft, Inc.Windows Server 2008Datacenter Edition Base | Datacenter Edition, 64-bit Base | Enterprise Edition Base | Enterprise Edition, 64-bit Base | Itanium-Based Systems Edition Base | Standard Edition Base | Standard Edition, 64-bit Base | Web Server Base | Web Server, 64-bit Base



LEGAL DISCLAIMER
The urgency and severity ratings of this alert are not tailored to individual users; users may value alerts differently based upon their network configurations and circumstances. THE ALERT, AND INFORMATION CONTAINED THEREIN, ARE PROVIDED ON AN "AS IS" BASIS AND DO NOT IMPLY ANY KIND OF GUARANTEE OR WARRANTY, INCLUDING THE WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR USE. YOUR USE OF THE ALERT, AND INFORMATION CONTAINED THEREIN, OR MATERIALS LINKED FROM THE ALERT, IS AT YOUR OWN RISK. INFORMATION IN THIS ALERT AND ANY RELATED COMMUNICATIONS IS BASED ON OUR KNOWLEDGE AT THE TIME OF PUBLICATION AND IS SUBJECT TO CHANGE WITHOUT NOTICE. CISCO RESERVES THE RIGHT TO CHANGE OR UPDATE ALERTS AT ANY TIME.