BurpSuite搭配Sqlmap進行自動化SQL注入測試
使用gason插件+SqlMap測試SQL注入漏洞
sqlmap官網(wǎng)
http://sqlmap.org/
python官網(wǎng)
https://www.python.org/downloads/windows/
sqlmap的github地址
https://github.com/sqlmapproject/sqlmap
https://code.google.com/p/gason/
https://code.google.com/archive/p/gason/downloads
最終獲取的插件gason-version.jar
這個插件安裝都沒有問題,但是在執(zhí)行的時候執(zhí)行sqlmap的窗口彈不出來,不知道啥原因,這個插件可以當作是命令參考
上述安裝完成,配置好路徑,沒有什么問題,直接針對請求包發(fā)送到sqlmap即可
也可以使用BurpSuite商店BApp Store中的SQLiPy
使用加強版sqlmap4burp插件+SqlMap批量測試SQL注入漏洞
原理就是BurpSuite獲取的請求包然后生成日志,通過插件sqlmap4burp進行批量測試sql注入漏洞
sqlmap4burp此插件到目前位置沒有更新維護過了,但網(wǎng)上有大佬基于此插件進行改進,現(xiàn)在
已經(jīng)演變成非常精簡好用的sqlmap4burp-plus-plus,可以直接編譯此插件然后加載到burp即可使用
編譯sqlmap4burp-plus-plus
編譯前需要安裝的環(huán)境:jdk和maven
安裝jdk
官網(wǎng)下載jdk文件安裝之后添加系統(tǒng)的環(huán)境變量
安裝maven
https://www.runoob.com/maven/maven-setup.html
安裝完成執(zhí)行mvn -v確保能夠執(zhí)行java和javac
開始編譯生成jar文件
git clone https://github.com/c0ny1/sqlmap4burp-plus-plus.git
mvn package
如果報錯的話,需要配置代理
http://maven.apache.org/guides/mini/guide-proxies.html
需要新建文件名為settings.xml 保存下面代碼
如下:
<settings>
? <proxies>
? <proxy>
? ? ? <id>example-proxy</id>
? ? ? <active>true</active>
? ? ? <protocol>http</protocol>
? ? ? <host>192.168.189.1</host>
? ? ? <port>9988</port>
? ? ? <nonProxyHosts>www.google.com|*.github.com</nonProxyHosts>
? ? </proxy>
? </proxies>
</settings>
編譯完成會生成:sqlmap4burp-plus-plus-0.1.jar文件
然后加載到burpsuite即可使用
項目地址:https://github.com/c0ny1/sqlmap4burp-plus-plus
作者博客:http://gv7.me/articles/2019/refactoring-sqlmap4burp/
自動化批量使用sqlmap測試BurpSuite的Proxy-HTTP History的請求記錄,配置生成本地請求日志文件的操作如下:
Project options --- Misc --- Logging --- Proxy -> Requests
然后本地保存一個文件名為burp-autosqlmap.txt
當所有需要被測試的請求記錄在burp-autosqlmap.txt的時候使用批處理進行快速使用sqlmap批量測試SQL注入
保存成批處理文件然后執(zhí)行,代碼如下:
sqlmap.py -l C:\tools\burpsuite_pro_v2020.2\/burp-autosqlmap.txt --batch -smart
https://github.com/difcareer/sqlmap4burp
https://www.freebuf.com/sectool/74445.html
https://www.freebuf.com/sectool/75296.html
https://www.secpulse.com/archives/4213.html
http://gv7.me/articles/2017/compile-sqlmap4burp/