Hacking Facebook by exploiting two reflected file download flaws

Pierluigi Paganini March 12, 2015

A security researcher has discovered two different  reflected file download flaws in Facebook that could be exploited to hit its users.

Security researcher David Sopas from WebSegura has discovered a couple of security flaw in Facebook that could be exploited by an attacker respectively to upload an arbitrary file to the social network or to gain control of a machine.

One of the issues is a reflected file download (RFD) flaw that could be exploited by bad actors to insert a malware into the victim’s machine that appears like it is coming from a legitimate Facebook domain.

Sopas explained that he has discovered two distinct reflected file download vulnerabilities in Facebook that are still unpatched. In order to exploit the flaw, the attacker needs the interaction of the victims.

“The first one was present on Graph Facebook API and could be replicated under Internet Explorer 9 just by sending a link,”

https://graph.facebook.com/v2.2/me/photo%22%7C%7Ccalc%7C%7C;/run.bat?access_token=CAACEdEose0cBAFz0qmT8eIVwEy7n6MIeUwXjBeudWCoy3IzJ
SNqonNYI5LKVmIN18IJIhwGLitFK2CXjDmnESLFttFQND1Q0ZCdYyibBbPqur
3I6U3G5eISuk4o4NZAza1K2vmj3NfzVWMwlvAYuJjlZBFguwm21bD0vzAO09j
JAC8Y6bEPDJjce9P6hffB3pzHuuKh4USAiPJ0e8yVc9CH2ZChsZCNcZD&format=json&
method=get&pretty=0&suppress_http_code=0

Sopas wrote in a blog post.

facebook rfd 1 reflected file download

The above image shows the attack on IE, but it is also effective with the current versions of Chrome and Opera. The expert also provided an online proof-of-concept at the following URL:

http://www.websegura.net/facebook.htm

“To the user the entire process looks like a file is offered for download by Facebook trusted domain and it would not raise any suspicious. A malicious user could gain total control over a victims computer and launch multiple attacks.”

Sopas was contacted by the Facebook security, the experts from Facebook replied that they “couldn’t control all the ways web browsers may allow content downloads or the different app formats that a computer may allow.” According Facebook, the flaw discovered by Sopas could not be rewarded in a bug bounty program.

“Our bug bounty program excludes reports that have no practical security implications, as well as social engineering techniques that require significant interaction from the victim because technical changes are usually not the best way to address these threats,” replied Facebook.

At the time I’m writing there is no news about a possible release date for the fix for the two reflected file download flaws.

Sopas discovered a second reflected file download vulnerability that allows an attacker to upload an arbitrary file by using a tool available on Facebook to check the ads content to publish.

“The first security issue I found was that it’s possible to upload a file with any kind of extension to Facebook server via Ads/Tools/Text_Overlay tool. This online tool checks the upload image for too many text on a image to user on their ads,” wrote Sopas. “A user can upload executable files or just use Facebook servers as file repository. In my proof-of-concept I uploaded a batch file without any restriction and I can access to it anytime anywhere as long as I’m logged in on my account.”

A user can upload any kind of file on Facebook servers by exploiting the flaw. Sopas invites Facebook users to carefully inspect links, even if they appear to come from a trusted source.

Pierluigi Paganini

(Security Affairs –  Facebook, reflected file download)



you might also like

leave a comment