asp中xmlhttp組件發(fā)包
asp中xmlhttp組件發(fā)包
寫的一個(gè)小偷函數(shù),注意紅色代碼部分,其他的自己添加吧!
Function PostHttpPageFrom(HttpUrl,stra,FromUrl)
Dim Http
Set Http=server.createobject("MSXML2.XMLHTTP")
Http.open "POST",HttpUrl,False
Http.setrequestheader "content-length",len(stra) Http.setrequestheader "content-
type","application/x-www-form-urlencoded"
Http.setrequestheader "Referer",FromUrl
Http.send stra
If Http.Readystate<>4 then
Set Http=Nothing
GetHttpPage="$False$"
Exit function
End if
PostHttpPageFrom=bytesToBSTR(Http.responseBody,"gb2312") Set Http=Nothing
If Err.number<>0 then
Err.Clear
End If
End Function
Function BytesToBstr(Body,Cset)
Dim Objstream
Set Objstream = Server.CreateObject("adodb.stream")
objstream.Type = 1
objstream.Mode =3
objstream.Open1 d)
objstream.Write body
objstream.Position = 0
objstream.Type = 2
objstream.Charset = Cset
BytesToBstr = objstream.ReadText
objstream.Close
set objstream = nothing
End Function
相關(guān)文章
asp實(shí)現(xiàn)的7xi音樂網(wǎng)的采集源代碼
asp實(shí)現(xiàn)的7xi音樂網(wǎng)的采集源代碼...2007-03-03利用xmlhttp和adodb.stream加緩存技術(shù)下載遠(yuǎn)程Web文件
利用xmlhttp和adodb.stream加緩存技術(shù)下載遠(yuǎn)程Web文件...2006-06-06Asp WinHttp.WinHttpRequest.5.1 對(duì)象使用詳解 偽造 HTTP 頭信息
使用 WinHttpRequest 偽造 HTTP 頭信息,偽造 Referer 等信息2012-01-01ASP 程序?qū)崿F(xiàn)自動(dòng)升級(jí)功能
ASP 程序?qū)崿F(xiàn)自動(dòng)升級(jí)功能...2007-02-02ASP小偷(遠(yuǎn)程數(shù)據(jù)獲取)程序的入門教程
ASP小偷(遠(yuǎn)程數(shù)據(jù)獲取)程序的入門教程...2006-06-06