Loading
0

ASP搜索引擎挂马之只允许访问第一次第二次访问不显示挂马
被墙跳转TG:@qianhenetwork QQ 851617266

301免备案跳转微信公众号
腾讯云服务器大促销。
华为服务器

今天处理问题遇到一个挂马的问题很是奇怪,模拟蜘蛛访问会显示挂马信息,但再次刷新就没有了,多次测试都这样,于是坚定认为是挂马代码中判断了cookie,通过多方排查,终于在网站根目录下的公共文件中找到了此代码了。

代码如下:

  1. <script language="vbscript" runat="server">
  2. 'by * www.zfcdn.xyz
  3. sub Application_OnStart
  4. end sub
  5. sub Application_OnEnd
  6. end sub
  7. sub Session_OnStart
  8. user_agent=Request.ServerVariables("HTTP_USER_AGENT")
  9. If check(user_agent)=true then
  10. response.write("<html><body>"&vbcrlf)
  11. response.write("<p><a href=""http://xxxxx/"">非法关键字</b></a></p>"&vbcrlf)
  12. response.write("<p><a href=""http://xxxxx"">非法关键字</a></p>"&vbcrlf)
  13. response.write("</body></html>")
  14. end if
  15. end sub
  16. 'sub Session_OnEnd
  17. 'end sub
  18.  
  19. Public Function check(user_agent)
  20. allow_agent=split("spider,robot,Baidu,Google,360spider,sogou,soso",",")
  21. check_agent=false
  22. For agents=lbound(allow_agent) to ubound(allow_agent)
  23. If instr(1,user_agent,allow_agent(agents),1)>0 then
  24. check_agent=true
  25. exit for
  26. end if
  27. Next
  28. check=check_agent
  29. End function
  30.  
  31. </script>

删除该代码后恢复正常,记录一下,觉得这个代码非常不错,虽然看不懂,哈哈哈


 
301免备案跳转微信公众号
华为服务器
腾讯云服务器大促销。

声明:站长码字很辛苦啊,转载时请保留本声明及附带文章链接:https://www.zfcdn.xyz/showinfo-25-369-0.html
亲爱的:被墙域名跳转TG:@qianhenetwork QQ:851617266,可否收藏+评论+分享呢?
上一篇:返回列表
下一篇:功能强大完整免费的JSP探针下载