Security Experts:

Facebook Rewards Researcher For Reporting Critical Vulnerability

A researcher has found a way to upload potentially malicious code to Facebook's servers by hiding it inside a harmless-looking Microsoft Word document file.

In July, Egypt-based security researcher Mohamed Ramadan discovered what he called a blind XML External Entity (XXE) out-of-band (OOB) vulnerability on Facebook's facebook.com/careers website.

On this site, users who want to apply for a job with Facebook can upload their résumé in .pdf or .docx format. This normally prevents the uploading of malicious files. However, .docx (Office Open XML) is a zipped, XML-based file format, which allowed the researcher to extract its contents using a file archiving application.

By altering the extracted files and placing them inside a .docx file, the expert managed to upload arbitrary code to Facebook's server. The test code developed by the researcher was simply designed to contact an HTTP server running on his computer. It took roughly 15 minutes for the file uploaded to Facebook to contact Ramadan's server, but the attack method had worked.

According to the researcher, the security hole could have been leveraged for a wide range of malicious tasks, including denial-of-service (DoS) attacks, TCP scans, and access to XML files. In certain circumstances, an attacker could have also gained access to sensitive information and launch DDoS attacks, the expert believes.

Facebook initially failed to reproduce the attack, but after further investigations the social media giant admitted it was a security issue and fixed it. In August, the company rewarded Ramadan with $6,300 for his findings.

In a blog post published over the weekend, the researcher said Facebook paid out the reward after he identified similar vulnerabilities on other websites.

This isn't the first time Ramadan is rewarded by Facebook for reporting security bugs. In December 2012, he identified a flaw in the Facebook Camera app for iOS which could have been exploited to hijack user accounts through man-in-the-middle (MitM) attacks. In October 2013, the expert reported discovering a way to hijack Facebook accounts by leveraging a vulnerability in the social media network's Android application.

In January, Facebook announced rewarding Brazilian computer engineer Reginaldo Silva with $33,500 for reporting a critical vulnerability. Silva found a way to remotely execute arbitrary code by leveraging an XXE issue.

A proof-of-concept video published by Ramadan is available below:

view counter
Eduard Kovacs (@EduardKovacs) is a contributing editor at SecurityWeek. He worked as a high school IT teacher for two years before starting a career in journalism as Softpedia’s security news reporter. Eduard holds a bachelor’s degree in industrial informatics and a master’s degree in computer techniques applied in electrical engineering.