SQL Server Management Studio Information Disclosure Vulnerability (CVE-2018-8527)
SSMS parses XEL files with XML external entity support, allowing an attacker to read arbitrary files. The attacker must convince a user to open a malicious XEL file.
John Page - ApparitionSec Follow
Originally disclosed on Microsoft
Description
An information disclosure vulnerability exists in Microsoft SQL Server Management Studio (SSMS) when parsing a malicious XEL file containing a reference to an external entity. An attacker who successfully exploited this vulnerability could read arbitrary files via an XML external entity declaration. To exploit the vulnerability, an attacker must entice a user on an affected SSMS server to open a specially crafted XEL file. In an email attack scenario, an attacker could exploit the vulnerability by sending the specially crafted file to the user and then convincing the user to open the file. In a web-based attack scenario, an attacker could host a website (or leverage a compromised website that accepts or hosts user-provided content) that contains a specially crafted file designed to exploit the vulnerability. An attacker would have no way to force a user to visit the website. Instead, an attacker would have to convince a user to click a link and open the specially crafted file. The security update addresses the vulnerability by correcting how SQL Server Management Studio parses XML input.
FAQ
- What type of information could be disclosed by this vulnerability? The type of information that could be disclosed if an attacker successfully exploited this vulnerability is unauthorized file system access - reading from file system. 2. How can I ensure my computer is protected from this vulnerability? For all versions of SQL Server Management Studio installed on this computer, you can protect your system from this vulnerability by disabling DTD processing of XML query results. Please follow the steps described in the Workaround section.
SQL Server
SQL Server
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, SSMS allows XML external entity declarations when parsing XEL files, enabling file disclosure.
Impact
An attacker could read arbitrary files from the victim's file system, but only if the victim opens the malicious file.
What the attacker needed
Victim opens a malicious XEL file; SSMS installed
The fix
The vulnerability was fixed by correcting how SSMS parses XML input; a workaround is to disable DTD processing of XML query results.
How it was found
- Create a malicious XEL file containing an XML external entity declaration.
- Send the file to the victim or host it on a website.
- Convince the victim to open the file in SSMS.
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 an XML External Entity (XXE) flaw. When SSMS opens a specially crafted XEL file, it processes XML that can reference external files, letting an attacker read files on the victim's computer. The victim must open the malicious file.
What is XXE?
An XML parser resolves entities the attacker defines, reading local files or making the server send requests.