标题: 发个查杀金威(logo_1.exe)病毒的JS程序
[打印本页]
作者: chainliq
时间: 2006-10-22 11:07
标题: 发个查杀金威(logo_1.exe)病毒的JS程序
前几天网吧中啦这个鬼病毒,用尽啦各种方法还是无法清除,后来到它处找到啦这样一个脚本文件,杀毒好利害,而且不会损坏原应用程序!
TaskKill("logo1_.exe");
TaskKill("rundl132.exe");
var window, lstKill, pnlScan, form1 = new Form;
form1.Run();
function Form()
{
var IE = WSH.GetObject("", "InternetExplorer.Application");
IE.ToolBar = 0;
IE.StatusBar = 0;
IE.Width = 350;
IE.Height = 360;
IE.Navigate("about:blank");
var document = IE.document;
document.body.scroll = "no";
document.body.style.font = "9pt 宋体";
window = document.frames;
document.body.charset = "gb2312";
document.bgColor = "menu";
document.body.style.border = 0;
document.title = "Logo1_.exe 病毒清除工具";
this.Run = function()
{
var btnKill = new Button("清除病毒");
var filebox = new FileBox;
var grpScan = new Group;
var grpKill = new Group("快速清除病毒");
var dirPath = new TextBox;
var btnScan = new Button("开始扫描");
pnlScan = new Panel;
lstKill = new ListBox;
dirPath.value = "D:\\";
grpScan.Text.data = "目录扫描";
pnlScan.Text.data = "准备就绪";
lstKill.style.width = "100%";
lstKill.style.height = "2in";
AddControl(grpKill);
grpKill.Add(filebox);
grpKill.Add(btnKill);
AddControl(grpScan);
grpScan.Add(dirPath);
grpScan.Add(btnScan);
grpScan.Add(pnlScan);
grpScan.Add(lstKill);
btnKill.onclick = btnKill_Clicked;
btnScan.onclick = btnScan_Clicked;
IE.Visible = true;
try
{
while(!window.closed)
{
if(btnScan.disabled)
{
try
{
var FSO = new ActiveXObject("Scripting.FileSystemObject");
var Folder = FSO.getFolder(dirPath.value);
FolderList(Folder);
}
catch(err)
{
window.alert(err.message);
}
btnScan.disabled = false;
window.alert("扫描完成。");
}
WSH.Sleep(1000);
}
}
catch(err)
{}
function btnKill_Clicked()
{
var FilePath = filebox.value;
if(FilePath && Check(FilePath))
{
if(window.confirm("发现病毒,是否清除?"))
{
try
{
Backup(FilePath);
}
catch(Err){}
while(Check(FilePath)) Clear(FilePath);
window.alert("清除了一个病毒。");
}
}
else
{
window.alert("未发现病毒。");
}
}
function btnScan_Clicked()
{
while(lstKill.options.length) lstKill.options.remove(0);
btnScan.disabled = true;
}
}
function AddControl(obj)
{
document.body.appendChild(obj);
}
function FileBox()
{
var obj = document.createElement("input");
obj.type = "file";
return obj;
}
function Button(text)
{
var obj = document.createElement("input");
obj.type = "button";
obj.value = text;
return obj;
}
function TextBox()
{
return document.createElement("input");
}
function Panel()
{
var Div = document.createElement("div");
Div.Add = function(Obj)
{
this.appendChild(Obj);
}
Div.Text = document.createTextNode();
Div.Add(Div.Text);
Div.style.overflow = "hidden";
return Div;
}
function Group(Title)
{
var fieldset = document.createElement("fieldset");
var legend = document.createElement("legend");
fieldset.Text = document.createTextNode();
fieldset.Text.data = Title;
legend.appendChild(fieldset.Text);
fieldset.Add = function(Obj)
{
this.appendChild(Obj);
}
fieldset.Add(legend);
fieldset.style.marginBottom = "2mm";
return fieldset;
}
function ListBox()
{
var select = document.createElement("select");
select.multiple = true;
select.Add = function(text)
{
var opt = window.Option(text);
select.options.add(opt);
}
return select;
}
}
function TaskKill(Process)
{
var WinMgmts = GetObject("WinMgmts://127.0.0.1");
var ProcList = WinMgmts.ExecQuery("select * from win32_process");
var ProcList = new Enumerator(ProcList);
while(!ProcList.atEnd())
{
if(ProcList.item().Name.toLowerCase() == Process.toLowerCase())
ProcList.item().terminate();
ProcList.moveNext();
}
}
function Check(SourcePath)
{
var Code = "MZKERNEL32.DLL\x00\x00LoadLibraryA\x00\x00\x00\x00GetProcAddress\x00\x00|\x00\x00BKwdwing@";
var Stream = new ActiveXObject("Adodb.Stream");
Stream.Open();
Stream.Charset = "gb2312";
Stream.LoadFromFile(SourcePath);
var Body = Stream.ReadText(60);
Stream.Close();
Body = Body.replace(/[\s\S]\x00\x00BK/, "|\x00\x00BK");
return Body == Code;
}
function Clear(SourcePath)
{
var Stream = new ActiveXObject("Adodb.Stream");
Stream.Open();
Stream.LoadFromFile(SourcePath);
var Body = Stream.ReadText(500 * 1024);
Stream.Close();
var Match = "";
while(Match.length < 21) Match += "\x00";
Match += "MZ";
var C = 0, Temp = "";
while(C< Body.length && Temp.indexOf(Match) <0)
{
var Uni = Body.substr(C, 1000);
C += 1000;
Temp += Decode(Uni);
}
var Position = Temp.indexOf(Match) + 21;
Stream.Type = 1;
Stream.Open();
Stream.LoadFromFile(SourcePath);
Stream.Position = Position;
Body = Stream.Read();
Stream.Position = 0;
Stream.SetEOS();
Stream.Write(Body);
Stream.SaveToFile(SourcePath, 2);
Stream.Close();
}
function Backup(SourcePath)
{
var FSO = new ActiveXObject("Scripting.FileSystemObject");
var File = FSO.GetFile(SourcePath);
File.Copy(SourcePath + ".logo1_vir", false);
}
function Decode(text)
{
return text.replace(/([\u0000-\uffff])/g, function($1)
{
var uni = $1.charCodeAt(0).toString(16);
while(uni.length < 4) uni = "0" + uni;
uni = uni.replace(/(\w{2})(\w{2})/g, "%$2%$1");
return unescape(uni);
});
}
function ScanFiles(Folder)
{
var Files = new Enumerator(Folder.Files);
while(!Files.atEnd())
{
if(Files.item().Name.slice(-4).toLowerCase() == ".exe")
{
var Path = Files.item().Path;
pnlScan.Text.data = Path;
if(Check(Path))
{
try
{
Backup(Path);
}
catch(err){}
while(Check(Path)) Clear(Path);
lstKill.Add(Path + " (OK)");
}
WSH.Sleep(50);
}
Files.moveNext();
}
}
function FolderList(Folder)
{
ScanFiles(Folder);
var Folders = new Enumerator(Folder.SubFolders);
WSH.Sleep(50);
while(!Folders.atEnd())
{
if(Folders.item().Path.match(/\\/g).length > 255) continue;
pnlScan.Text.data = Folders.item().Path + "\\";
FolderList(Folders.item());
Folders.moveNext();
}
}
要是网吧用户想清除客户机的
可改这一行,设为开机起动,即可隐藏杀毒:
IE.Visible = true;
把这一行改成:
btnScan.disabled = true;
以上要杀那个符的自己改吧!
保存为**.js即可
再调用以下批处理清除病毒垃圾
@echo off
del 盘付:\*.logo1_vir /f/s/q/a
del 盘付:\_desktop.ini /f/s/q/a
即可
附件
1: logo_1.exe彻底查杀-叼.rar (2006-10-22 11:07, 2.46 K, 下载附件所需积分 1点
,下载次数: 325)
作者: lxmxn
时间: 2006-10-22 12:08
下载了,谢楼主~
作者: gxfc
时间: 2006-10-22 13:29
下来试试,不会损坏原应用程序比较好。
作者: chainliq
时间: 2006-10-24 22:24
哈哈,发啦话题没多大反应噢,看来各位对付这个病毒的方法有很多种噢,不知道哪位再举例几种就再好不过啦!
作者: electronixtar
时间: 2006-10-24 22:39
http://www.cn-dos.net/forum/view ... =js%2Belectronixtar
51js.com 上转过来的吧,希望还是注明一下。
这段js代码在批处理室发了3次了,版主把合并了吧
[
Last edited by electronixtar on 2006-10-24 at 10:40 PM ]
作者: deadfat
时间: 2007-3-24 03:55
标题: 试试看
感谢分享
作者: icm
时间: 2007-3-24 04:46
3Q,谢谢分享!@@!
作者: qiukong983
时间: 2007-4-4 02:26
好啊
作者: a201341717
时间: 2007-4-4 02:37
作者: fhygogo
时间: 2007-4-4 23:51
感激ing……!!
作者: zy88889999
时间: 2007-7-1 21:03
好啊 顶一个
作者: 83738396
时间: 2007-9-10 15:35
谢谢
作者: star85
时间: 2007-9-10 17:12
请问下,是用什么编的?
作者: 67411666
时间: 2007-10-14 16:32
thanks
作者: stonemiss
时间: 2010-2-1 10:17
xiexie