看过第六轮黑防实验室的两位大侠对Oblog3.0 Access版本的渗透过程,敬佩之情犹如滔滔江水连绵不绝,又如黄河之水一发而不可收拾,尤其是他们把社会工程学原理利用得淋漓尽致,以及巧妙的后台上传shell的方法。佩服,佩服。说了这么多废话,我们进入正题,本人在通读Oblog3.0代码的时候发现user_blogmanage.asp文件存在安全隐患,看看下面移动blog日志的操作代码:
sub moveblog()
if id="" then
Oblog.adderrstr("请指定要移动的日志")
Oblog.showusererr
exit sub
end if
dim subjectid
subjectid=trim(request("subject"))
if subjectid="" then
Oblog.adderrstr("请指定要移动的目标专题")
Oblog.showusererr
exit sub
else
subjectid=Clng(subjectid)
end if
if instr(id,",")>0 then
‘如果id变量中含有逗号,去掉变量中的空格,执行下面的sql语句。设为第一条
id=replace(id," ","")
sql="Update [Oblog_log] set subjectid="&subjectid&" where logid in (" & id & ")"&wsql
‘否则执行这个sql语句,设为第二条。
else
sql="Update [Oblog_log] set subjectid="&subjectid&" where logid=" & id &wsql
end if
Oblog.Execute sql
dim blog,rs1
set blog=new class_blog
blog.userid=Oblog.logined_uid
blog.update_allsubjectid()
blog.update_index_subject 0,0,0,""
set blog=nothing
set rs=Oblog.execute("select subjectid from Oblog_subject where userid="&Oblog.logined_uid)
while not rs.eof
set rs1=Oblog.execute("select count(logid) from Oblog_log where Oblog_log.subjectid="&rs(0))
Oblog.execute("update Oblog_subject set subjectlognum="&rs1(0)&" where Oblog_subject.subjectid="&rs(0))
rs.movenext
wend
set rs=nothing
set rs1=nothing
Oblog.showok "更新专题成功,需要重新发布首页,才可使专题统计准确!",""
end sub
[1] [2] [3] 下一页