SQL Injection Hack By Googlebot Proxy
Earlier today on entering work I was faced with worried colleagues and angry customers who were complaining about Googlebot being banned from their site. I was tasked to finding out why.
First off all my large systems run with a custom built logger database that I created to help track visitors, page requests, traffic trends as well as having security features that constantly analyse recent traffic looking for signs of malicious intent such as spammers, scrapers and hackers. If my system identifies a hacker it logs the details and bans the user. If a user comes to my site and its already in my banned table then it's met with a 403 error.
Today I found out that Googlebot had been hacking my site using known SQL Injection techniques. The IP address was a legitimate Google IP coming from the 66.249 subnet and there were 20 or so records from one site in which SQL injection attack vectors had been passed in the querystring.
Why this has happened I do not know as an examination of the page in question found no trace of the logged links however I can think of a theoretical example which may explain it.
1. A malicious user has either created a page containing links to my site that contain SQL Injection attack vectors or has added content through a blog, message board or other form of user generated CMS that has not sanitised the input correctly.
2. This content has then been indexed by Google or even just appeared in a sitemap somewhere.
3. Googlebot has visited this content and crawled it following the links containing the attack vectors which have then been logged by site.
This attack by proxy has left no trace of the actual attacker and the trail only leads back to Google who I cannot believe tried to hack me on purpose. Therefore this is a very clever little trick as websites are rarely inclined to block the worlds foremost search engine from their site.
Therefore I was faced with the difficult choice of either adding this IP to my exception list of users never to block under any circumstance or blocking it from my site.
Obviously my sites database is secure and it's security policy is such that even if a hackbot found an exploitable hole updates couldn't be carried out by the websites login however this does not mean that in future an XSS attack vector could be created and then exploited.
Do I risk the wrath of customers and let my security system carry on doing it's job and block anyone trying to do my site harm even if its a Google by Proxy attack or do I risk a potential future attack by ignoring attacks coming from supposedly safe IP addresses?
Obviously it would be nice if Googlebot analysed all links before crawling them to ensure they are not hacking by proxy but then I cannot wait for them to do that.
I would be interested to know what other people think about this.
Labels: Googlebot, hacking, Logging, Proxy, SQL injection, XSS
1 Comments:
thanks for mentioning this. we're seeing this occasionally as well.
Post a Comment
Subscribe to Post Comments [Atom]
Links to this post:
Create a Link
<< Home