聊聊 Burpsuite Engagement Tools
直入burp右键菜单中的Engagement tools,中文翻译为作战工具。

从上往下依次为
Search 搜索
Find Comments 查找注释
Find scripts 查找js代码
Find references 查找引用
Analyze target 分析目标
Discover content 内容勘测
Schedule task 定时任务
Simulate manual testing 人工模拟
以上翻译属于个人理解,非字面意思。如有不同见解,欢迎交流。
依次聊一下个人的使用心得:
0x01 Search 搜索
在选定的上右键打开后默认如下:

输入字符串即可查找需要的字符串,相当于浏览器view-source后再Ctrl + F查找字符串。
如果只用到这里的话有点不太黑阔,正则搜索这么强大,不用可惜了。
贴一条自己常用的正则:
(.user|pass|accessKeyId|accessKeySecret|secretToken|callback|admin|config|key|access|token?)

擅用该功能,在SRC捡洞可能可能只是一个习惯而已。(比如每次准备关Burp之前考虑全选site map中所有的站点,再拿正则去尝试一下。)
0x02 Find Comments 查找注释
选择目标右键打开后如下图:


可以理解为Search功能的正则写为:
<!--(.*?)-->
不同语言的注释不一样,burp内置的正则更为全面。测试过程中适当看一下注释内容,没准一个未授权就出来了。
0x03 Find scripts 查找js代码
选择目标右键打开后如下图:


该功能处理.js后缀的文件之外,页面中script标签的内容也会自动匹配出来。等同于右键看完当前页面的js逻辑后在接着Ctrl F 搜.js然后继续看代码,在Burp里相对方便得多。
0x04 Find references 查找引用
选择目标右键打开后如下图:


如果用过LinksDumper的话会发现Burp这个功能和它一模一样,都是匹配出页面中存在的各类链接。
默认自带的功能还有不少人是去用插件或者用独立的程序跑。burp自带的它不香咩?
0x05 Analyze target 分析目标
选择目标右键打开后总共有四个页面
1.总结页面:

假设拿到100个目标,筛选软柿子的时候通过总结页面判断一下,寻找交互点多的站点/链接进行单点突破,未尝不是一个高效的选择。
2.动态Urls:

该功能可以快速筛选出带外部参数的url,并统计了参数的数量,秉着交互点越多可能存在的问题就越多的原则,筛选一下,效率++。
3.其他Url:

该功能可以理解为Find references功能遍历出来所有的连接后再去除Dynamic URLs中带交互点的Url的结果。
4.参数统计:

首先是统计了出现过那些参数,其次是这些参数在Url里面出现过次数。有了这个功能在瓶颈渗透提取本站存在的参数时根本不需要第三方插件工具辅助,直接复制name字段即可;某个参数存在漏洞后也可通过该功能查找其他可能存在相同问题的Url。
0x06 Discover content 内容勘测
该功能秒杀一切目录扫描工具。
下面是关于如何巧用它去递归扫描站点备份的:
此前在米斯特BurpSuite 插件生态开发组
里有提到想开发一款主动的备份扫描插件,寄生于BurpSuite
强大的爬虫功能对每个目录/文件进行备份扫描。写一半发现BurpSuite
本来就有这样的功能,只是很少有人用到罢了,本文仅对相关功能进行简要的分析以及优化。
0x06_1 简介
正常访问时爬虫被动收集到的目录:

下面是本文的主角:

位于Engagement tools
==> Discover content
看看默认配置:

图中圈起来的第一部分默认勾选了burp内置的四个字典,第二个圈也是默认配置,其作用时从站点中提取各种目录并递归扫描,前面的配置可根据情况修改,后面不建议动它。

默认配置就是这四项了,下面具体分析一下他扫描的流量,取其精华。
0x06_2 扫描分析
流程1:

先去除所有文件的后缀以及提取目录名当作文件扫一遍。
流程2:

在所有去了后缀的文件名后面加上Test these extentsions
配置中的所有后缀并进行扫描,在已知站点语言的情况下此处明显多了很多无效流量。
流程3:

将流程1中的所有文件名当作目录扫一遍。
流程4:

按照配置中Filenames中的字典顺序依次遍历并结合流程2的方式遍历文件。
流程5:
依次在每层目录执行一遍流程1-4,如果新目录或文件发现就添加到列队里面。
0x06_3 优化扫描

缺陷很明显,仅仅三个目录三个文件总共请求了14048次,流量超过20M。
递归扫描产生的无效流量太多了。
首要原因出现在:

大多数时候,已知语言情况下完全没必要吧所有后缀都跑一遍,留特定语言以及相关后缀。如st2时加上.action/.do,流量去掉大半。
其次出现在:

此处主要针对扫备份,原生字典长这样:
bac
BAC
backup
BACKUP
bak
BAK
conf
cs
csproj
gz
inc
INC
ini
java
log
lst
old
OLD
orig
ORIG
sav
save
tar
temp
tmp
TMP
vb
vbproj
zip
$$$
-OLD
-old
0
1
~1
~bk
主要针对国外的站吧。这里提供一份。
txt
md
xml
db
7z
rar
zip
gz
tar
tar.gz
sql
bak
swp
old
properties
inc
ini
mdb
mdf
conf
config
log
rar
最后是字典的选择:

burp内置的4个字典内容重复率极高,比如about这个词在四个字典里都分别出现了...四个字典共3266个,去重后2265个。
结果保存在:
https://raw.githubusercontent.com/TheKingOfDuck/myScripts/master/burp_dir.txt
文件名方面推荐:
https://raw.githubusercontent.com/TheKingOfDuck/myScripts/master/burp_filenames.txt

如此一来在扫描目录的过程也可把备份一并扫了。

0x06 Schedule task 定时任务
选择目标右键打开后如下图:

定时任务,没啥特别的值得说。
0x07 Simulate manual testing 人工模拟
This function sends common test payloads to random URL s and parameters at irregular intervals, to generate traflic similar to that caused by manual penetration testing. Its only real use is to let you take a break from testing while still looking busy according to the server's logs. Only items which you selected in the site map will be requested.
正如功能描述中所说的,这是一个懒人挖洞选项。

缺陷很明显,不会自动寻找并提交表单,只能依托于已有的表单/参数的基础上进行探测,相当于一款被动扫描器。结合Discover content使用,法力无边。
0x08 总结
熟练使用这些作战功能,扫描器从此是路人。
技术交流:https://github.com/TheKingOfDuck

也无风雨也无晴