At this moment I am being hacked and I do not know to stop it. Let me explain...
My website is hosted in a VPS where I am the only person who has access to it. The page is builtwith Codeigniter(updated), and Doctrine (updated too). Once I browse to at index.php I see this code in source:
<!--
top.location="http://pagesinxt.com/?dn=eqtisad.u13.biz&fp=uG6gKivovi4x8JjEAROV%2FTKBtIWD%2Blle7UNutYwxGdAyGVrZoBm5Bekjw2z7vZmvYE9r56BxR%2FdwKJnOW1e8aQ%3D%3D&prvtof=3um92iAJbFQD4ie3mqlX9yNOXQElLxUpPsdwROXtIXk%3D&poru=8V8ohaa543uO%2BrtgyMrGBIAkgU2lu1ckclS6TcL72%2BnBM2%2BYG73v%2FyLI9ZhKVjCGL2w0E5BxYal2xKLR2ERsB3mlhGebCpkQgGj4df%2BIkrc%3D&cifr=1&flrdr=yes&nxte=gif";
/*
-->
<script type="text/javascript">
<!--
dimensionUpdated = 0;
function applyFrameKiller()
{
if(window.top != self)
{
cHeight = 0;
if( typeof( window.innerHeight ) != 'undefined' ) {
//Non-IE
cHeight = window.innerHeight;
dimensionUpdated = 1;
} else if( document.documentElement && ( document.documentElement.clientWidth || document.documentElement.clientHeight ) ) {
//IE 6+ in 'standards compliant mode'
cHeight = document.documentElement.clientHeight;
dimensionUpdated = 1;
} else if( document.body && ( document.body.clientWidth || document.body.clientHeight ) ) {
//IE 4 compatible
cHeight = document.body.clientHeight;
dimensionUpdated = 1;
}
if( cHeight <= 250 && dimensionUpdated == 1)
{
window.top.location = "http://pagesinxt.com/?dn=eqtisad.u13.biz&fp=uG6gKivovi4x8JjEAROV%2FTKBtIWD%2Blle7UNutYwxGdAyGVrZoBm5Bekjw2z7vZmvYE9r56BxR%2FdwKJnOW1e8aQ%3D%3D&prvtof=H4TY0TTX3NzJR65BWTqd5iL%2FuG%2FrWNlJRpGGD7lLlAI%3D&poru=VPQxzhVHETonB83RBOqqTOJMW1rvUm850o6RD0TzdI6oyXwlzAeOG%2FK17FifSzcxHolUxHDNgpTE%2BnRQSwqPDCIL8FKABEYRdUxAEcBGi8s%3D&cifr=1&flrdr=yes&nxte=gif";
}
}
}
applyFrameKiller();
// -->
</script><frameset rows="100%,*" frameborder="no" border="0" framespacing="0">
<frame src="http://pagesinxt.com/?dn=eqtisad.u13.biz&fp=uG6gKivovi4x8JjEAROV%2FTKBtIWD%2Blle7UNutYwxGdAyGVrZoBm5Bekjw2z7vZmvYE9r56BxR%2FdwKJnOW1e8aQ%3D%3D&prvtof=QNdLHvfpmQDcCjmfkLp0UoTOm9%2FlbsSY5zwRjXbMEDs%3D&poru=ZFDh3zFdBl8oLoFKYzmbIrndO0AsgI5yGs9la3B3DvUnOwJwZj4aeWo5bo5PRkvlGhqLFIwXyhV4DxStH7tHRS%2FbB902y5I8kPm7LLxSgJ0%3D&flrdr=yes&nxte=gif">
</frameset>
<noframes>
<body bgcolor="#ffffff" text="#000000">
<a href="http://pagesinxt.com/?dn=eqtisad.u13.biz&fp=uG6gKivovi4x8JjEAROV%2FTKBtIWD%2Blle7UNutYwxGdAyGVrZoBm5Bekjw2z7vZmvYE9r56BxR%2FdwKJnOW1e8aQ%3D%3D&prvtof=DFirIGqMqM7SgRb4jbom9x%2FWLKk2BsDoNNUAtuffLcM%3D&poru=h4Hln0ENUyIUaYgUi37Z6zIj6%2FYWgvyln3NWEddNbSBI1tQexg46ZMAGiZ0lsT6C4pkl6AcLCw9x0J6hZhJcNgm04ONcuO4STG69vF4Nue8%3D&flrdr=yes&nxte=gif">Click here to proceed</a>.
</body>
</noframes><!--
*/
-->
Somethings that I do not understand
If a open the
index.phpthe code is correct (original code), so.. how is possible to see the code above in the browser, but by ftp the file is ok?I have never been attacked before, so, what should be the first guidelines to review? what should be a correct troubleshooting in order to find/minimize the hole security?
(Here I am getting most confused). This hack is intermittent, because when I press
F5the hack disappear for 2 or 3 minutes, but it comes back again! I am very scared :(
