This article has been updated, see below for details.
A security researcher has detected and disclosed a new vulnerability on Facebook that allows a third-party to use the social networkâ€™s Messages service to attach malicious files and send them to any user registered on the website.
The exploit, which focuses on how Facebook interprets file uploads within messages, was submitted to Facebook September 30 by penetration tester Nathan Power and was recognised by the company on Wednesday.
By default, Facebook blocks malicious file uploads, preventing users from attaching executable or batch files that would be able to infect a computer if downloaded and run. Facebook would typically issue the response:Â â€ťError Uploading: You cannot attach files of that type.â€ť
However, Power was able to analyse the responses that the Facebook website returned when his browser made a POST request to its webserver, finding a variable that would tell the system that a filename had been attached and determine whether it would be approved for sharing via the service:
Content-Disposition: form-data; name=â€ťattachmentâ€ť; filename=â€ťcmd.exeâ€ť
Power amended the POST request, adding a space to the filename variable, allowing him to bypass the filename check and attached a potentially malicious executable file.
Due to the nature of Facebookâ€™s messaging system, it could potentially allow an attacker to send messages to anyone on the service,Â regardlessÂ of whether they were friends.
Power notes that Facebook is aware of the issue, which is as much to say that the vulnerability may have already been patched by its development team, which is primarily located in California.
Yesterday, we reported that Facebookâ€™s cyber-security system processes and checks 650,000 actions every second to keep its users safe from spam and cyber-attacks on the social network. The Facebook Immunity System (FIS), as itâ€™s known, is said to highly efficient also, with just 1% of users reporting issues as spam.
We have contacted Facebook for comment and will update the article should we received a response.
Update:Â Facebookâ€™s Security ManagerÂ Ryan McGeehanÂ had this to say:
This finding will only allow one user to send an obfuscated renamed file to another Facebook user. The proof of concept, as is, would not execute on a recipients machine without an additional layer of social engineering. Beyond that, we are not going to rely solely on string matching as a protective measure, since zip files and other things could also have unpredictable behaviors when sent as an attachment.
We are AV scanning everything that comes through as a secondary measure, so we have defense in depth for this sort of vector. This puts us at a similar level of protection as most webmail providers who deal with the similar risk, and this finding is a very small part of how we protect against this threat overall.At the end of the day, it is more practical for a bad guy to hide an .exe on a convincing landing page behind a URL shortener, which is something weâ€™ve been dealing with for a while.