News for hackers. Stuff that matters.
Re:Php.net detected as a malware host by Google Safe Browsing by pierrefar on Thursday October 24, 2013 @07:47AM (#6604639)
I work at Google and was the one who posted on our forums about this.

What our systems found was definitely a compromised JS file, and others on this thread have posted something similar to what we saw. This is not a false positive.

We have detailed help for webmasters in this kind of situation:

http://www.google.com/webmasters/hacked/

One thing that I strongly suggest to any webmaster in this situation is to look for any server vulnerability that allowed this file to get compromised in the first place. We sometimes see webmasters simply fix the affected files without digging into security hole that allowed the hack, which leaves the server vulnerable for repeat attacks.

Happy to answer questions.

Re:Php.net detected as a malware host by Google Safe Browsing by bruceboughton on Thursday October 24, 2013 @08:50AM (#6604916)
From the dignostics page (http://www.google.com/safebrowsing/diagnostic?site=http://ph...):

>> Malicious software is hosted on 4 domain(s), including cobbcountybankruptcylawyer.com/, stephaniemari.com/, northgadui.com/.

What does this mean? How do these sites relate to php.net?

Re:Php.net detected as a malware host by Google Safe Browsing by ajankovic on Thursday October 24, 2013 @08:53AM (#6604929)
Probably javascript files planted on php.net are being pulled from servers behind those domains.
Re:Php.net detected as a malware host by Google Safe Browsing by donrhummy on Thursday October 24, 2013 @02:46PM (#6607097)
php.net allows users to post answers and examples of code throughout the website. Likely, one of the submission forms has/had a hole that allowed someone to submit or alter actual JS code.
Re:Php.net detected as a malware host by Google Safe Browsing by Apofis on Thursday October 24, 2013 @09:14PM (#6609192)
This seems like a pretty darn good example of cross-side scripting... and possibly someone not sanitizing inputs?
Re:Php.net detected as a malware host by Google Safe Browsing by stedaniels on Friday October 25, 2013 @03:54AM (#6610312)
No, not at all.
Re:Php.net detected as a malware host by Google Safe Browsing by deanclatworthy on Thursday October 24, 2013 @07:58AM (#6604681)
Thanks for the information. Can you confirm how long the malware has been on the site for, and if it's possible that people may have been drive-by'd before you flagged the domain? Also what systems did the malware target?

Thanks

Re:Php.net detected as a malware host by Google Safe Browsing by pierrefar on Thursday October 24, 2013 @08:05AM (#6604711)
What we can share publicly is at this diagnostics page accessible to anyone (it's linked from the warning page browsers show):

http://www.google.com/safebrowsing/diagnostic?site=http://ph...

Verified owners in Webmasters Tools get more info.

Re:Php.net detected as a malware host by Google Safe Browsing by deanc on Thursday October 24, 2013 @08:20AM (#6604772)
It's a pity you don't disclose which malware specifically the sites were distributing. As a user who may have been affected prior to google flagging it, it's frustrating to have no information on what to look for.
Re:Php.net detected as a malware host by Google Safe Browsing by mavroprovato on Thursday October 24, 2013 @08:53AM (#6604930)
I think that you should direct your frustration towards the php.net admins and not Google.
Re:Php.net detected as a malware host by Google Safe Browsing by nwh on Thursday October 24, 2013 @08:33AM (#6604844)
It's linked further down the page.
Re:Php.net detected as a malware host by Google Safe Browsing by dpeck on Thursday October 24, 2013 @11:33AM (#6605826)
You link seems to indicate that the site isn't suspicious and hasn't served malware in the last 90 days, what changed?
Re:Php.net detected as a malware host by Google Safe Browsing by rictic on Thursday October 24, 2013 @01:28PM (#6606578)
When I go to that page I see: "Of the 1838 pages we tested on the site over the past 90 days, 4 page(s) resulted in malicious software being downloaded and installed without user consent. The last time Google visited this site was on 2013-10-24, and the last time suspicious content was found on this site was on 2013-10-23."
Re:Php.net detected as a malware host by Google Safe Browsing by yeukhon on Thursday October 24, 2013 @11:16AM (#6605728)
@pierrefar

As a student interested in security, will the js file be provided so we can examine and learn how this was done outside of privileged access?

EDIT

OKay looks like safe browsing said it is no longer suspicious. And I think someone already provided the JS file below.

Google's safe browsing looks pretty cool! Really powerful infrastructure. I wonder if they did this with virustotal? Can virustotal recongize this?

Another thing is other search engines dont seem to have this built-in. I wonder people using DDG will ever think about querying Google safe browsing or not.

Does google provide an api (beside just querying safebrowsing directly).

Re:Php.net detected as a malware host by Google Safe Browsing by karma_fountain on Thursday October 24, 2013 @11:37AM (#6605851)
Here is a pastebin which I found http://pastebin.com/XD0KyLxu
Re:Php.net detected as a malware host by Google Safe Browsing by samcrawford on Thursday October 24, 2013 @11:43AM (#6605878)
> Does google provide an api (beside just querying safebrowsing directly).

https://developers.google.com/safe-browsing/

Re:Php.net detected as a malware host by Google Safe Browsing by joekrill on Thursday October 24, 2013 @10:00AM (#6605254)
I don't understand: you guys CLEARLY have the information on what, specifically, is causing the problem (which JS file, in this case). Yet for the site owner, you don't make it available? Or if it is, it's not at all easy to find the information. It's just this black box "go figure it out yourself" thing. Meanwhile you've essentially killed access to their site. Or is there something I'm missing?
Re:Php.net detected as a malware host by Google Safe Browsing by Guvante on Thursday October 24, 2013 @10:04AM (#6605276)
They have access to details, they posted that userprefs.js was to blame.
Re:Php.net detected as a malware host by Google Safe Browsing by joekrill on Thursday October 24, 2013 @11:46AM (#6605899)
But wasn't that only after rasmus posted about it on Twitter? And how would that have worked out for someone not running such a high profile site as him?
Re:Php.net detected as a malware host by Google Safe Browsing by dchest on Thursday October 24, 2013 @12:59PM (#6606387)
No, such information is available to any webmaster who verifies their website ownership in Google's Webmaster Tools.
Re:Php.net detected as a malware host by Google Safe Browsing by JohnTHaller on Thursday October 24, 2013 @04:19PM (#6607680)
Once you're a confirmed webmaster for a given site, Google provides you with access to exactly what files are infected on your site. To provide that information publicly would be open the site up to further exploitation.
Re:Php.net detected as a malware host by Google Safe Browsing by jimbobsyourmom on Thursday October 24, 2013 @09:52AM (#6605220)
You sir, get -9,001 Internets.

There are huge repercussions for any website that gets blacklisted with the Stop Badware clearinghouse, the least of which is the inability to figure out exactly where the problem actually is because the company you work for's information for a webmaster to resolve the problem is ridiculously minimal. There are no notifications (unless you are signed up for Google Webmaster Tools) and restoring a website to normal globally can take anywhere from 48 hours to two weeks. There are millions of developers who rely on the PHP website daily for performing their day jobs and you've now made it that much harder for us to do our jobs.

Stop Badware needs a serious overhaul. At the very least, they should contact the contacts in the WHOIS record for the domain BEFORE doing anything. Give the website owners 24 hours to resolve the issue before blacklisting the site. And give them a heck of a lot more information to go on than some vague text.

Also, there are several anti-virus vendors out there who use the clearinghouse database for their products...6 to 12 months after the original blacklisting. So this will happen all over again 6 to 12 months from now. Finding contacts for anti-virus vendors for removing domain blocks is a lot harder than removal from the blacklist on the Stop Badware site.

The CORRECT solution for this situation was to find a contact at PHP who could resolve the issue quickly and amicably. Seriously, how hard is it to locate Rasmus' e-mail address? Always try to find a human contact before using Stop Badware. You can chalk using Stop Badware for the PHP website as being the dumbest decision you've made this year. Hopefully this decision of yours will raise the ire of the Internet just enough to force the company you work for to revamp Stop Badware so it doesn't suck, Google Webmaster Tools so they don't suck, and the reporting tools for sending information to Stop Badware so they also don't suck.

Re:Php.net detected as a malware host by Google Safe Browsing by Silhouette on Thursday October 24, 2013 @10:18AM (#6605350)
Stop Badware needs a serious overhaul. At the very least, they should contact the contacts in the WHOIS record for the domain BEFORE doing anything.

Why? This isn't a responsible disclosure, "we found a potential vulnerability but we don't know if it's being exploited yet" kind of situation. This is a "there's a real threat to anyone visiting that site via your search engine right now" kind of situation.

As a user, I'd be much happier if the search engine flagged this immediately.

As a site owner, if someone found malware on my site I'd want to know ASAP too. Obviously it would be helpful if they sent me a notification and made the specific details of the identified threat available. However, I could hardly criticise them for blacklisting my site while it should be blacklisted, or for claiming that we were dangerous while we were actually serving malware.

Not clearing up the blacklists promptly after the threat is identified and removed is an entirely different question. If you're going to go around blacklisting sites then I think you also have a responsibility (and, for that matter, you should also have a legal obligation) to remove them from the blacklist with similar efficiency if you're notified that the threat has been removed. Claiming that someone's site is dangerous when it isn't is defamatory, and should be treated as such.

Re:Php.net detected as a malware host by Google Safe Browsing by ryeguy on Thursday October 24, 2013 @10:40AM (#6605504)
Google is not doing this as a service to the website, they are doing it as a service to the user. Giving the owner some kind of grace period to fix the issue could mean hundreds of thousands of people could get hit with a malicious script in the meantime.

> You sir, get -9,001 Internets.

Cut this shit out, you're not on reddit.

Re:Php.net detected as a malware host by Google Safe Browsing by skymt on Thursday October 24, 2013 @10:20AM (#6605362)
If Google waited 24 hours before blacklisting a site, how many people would be infected during the grace period?

It's incorrect to say that Google doesn't attempt to contact the site owner. According to the Webmaster Tools support site [0], Google will send notices to several common email addresses when it blacklists a site.

[0]: https://support.google.com/webmasters/answer/163633?hl=en#2

Re:Php.net detected as a malware host by Google Safe Browsing by camus2 on Thursday October 24, 2013 @10:25AM (#6605391)
> Seriously, how hard is it to locate Rasmus' e-mail address?

Why should google do that ? because it's Rasmus? they dont have to do that period.

The CORRECT SOLUTION is to protect users FIRST and not allow the site to infect more computers.

IT IS NOT google responsability to warn webmasters if their site are infected (though they can be warned by email automatically).

IT IS the webmaster's responsability to audit his website security, which obviously did not happen with php.net. If they get punished for that , that's FAIR , because it will force them to take security more seriously.

[edit] it's hight time people move from httpd to something else like nginx. httpd is insecure by default, this is not how you deal with security. as for PHP, since it doesnt promote any good security practice by default, it should be avoided.

Re:Php.net detected as a malware host by Google Safe Browsing by dscrd on Thursday October 24, 2013 @10:21AM (#6605367)
Are you seriously suggesting that Google should not immediately block a website when they detect malware on it... because millions of people are using that site?
Re:Php.net detected as a malware host by Google Safe Browsing by furyofantares on Thursday October 24, 2013 @10:15AM (#6605341)
I don't understand your suggestion that Google should have waited to protect their users from a site that is serving malware. Why would that be a good idea?
Re:Php.net detected as a malware host by Google Safe Browsing by paraboul on Thursday October 24, 2013 @10:53AM (#6605586)
"We know that your child has a bad contagious cold, but don't worry you can still bring him at school for 24 hours and infects other people"
Re:Php.net detected as a malware host by Google Safe Browsing by bitlord_219 on Thursday October 24, 2013 @12:21PM (#6606115)
> You sir, get -9,001 Internets.

A million times THIS!