一个基于插件扫描器,帮助安全研究人员识别多个CMS中的问题。
未经事先双方同意,使用droopescan攻击目标是非法的。最终用户有责任遵守所有适用的地方、州和联邦法律。开发者不承担任何责任,也不对因使用本程序造成的任何误用或损害负责。请注意,虽然droopescan输出远程主机上最可能安装的CMS版本,但版本号与漏洞之间的任何关联必须由用户手动完成。
支持的CMS包括:
部分功能支持:
computer:~/droopescan$ droopescan scan drupal -u http://example.org/ -t 32
[+] 未找到主题。
[+] 发现可能的感兴趣URL:
Default changelog file - https://www.example.org/CHANGELOG.txt
Default admin - https://www.example.org/user/login
[+] 可能的版本:
7.34
[+] 发现的插件:
views https://www.example.org/sites/all/modules/views/
https://www.example.org/sites/all/modules/views/README.txt
https://www.example.org/sites/all/modules/views/LICENSE.txt
token https://www.example.org/sites/all/modules/token/
https://www.example.org/sites/all/modules/token/README.txt
https://www.example.org/sites/all/modules/token/LICENSE.txt
pathauto https://www.example.org/sites/all/modules/pathauto/
https://www.example.org/sites/all/modules/pathauto/README.txt
https://www.example.org/sites/all/modules/pathauto/LICENSE.txt
https://www.example.org/sites/all/modules/pathauto/API.txt
libraries https://www.example.org/sites/all/modules/libraries/
https://www.example.org/sites/all/modules/libraries/CHANGELOG.txt
https://www.example.org/sites/all/modules/libraries/README.txt
https://www.example.org/sites/all/modules/libraries/LICENSE.txt
entity https://www.example.org/sites/all/modules/entity/
https://www.example.org/sites/all/modules/entity/README.txt
https://www.example.org/sites/all/modules/entity/LICENSE.txt
google_analytics https://www.example.org/sites/all/modules/google_analytics/
https://www.example.org/sites/all/modules/google_analytics/README.txt
https://www.example.org/sites/all/modules/google_analytics/LICENSE.txt
ctools https://www.example.org/sites/all/modules/ctools/
https://www.example.org/sites/all/modules/ctools/CHANGELOG.txt
https://www.example.org/sites/all/modules/ctools/LICENSE.txt
https://www.example.org/sites/all/modules/ctools/API.txt
features https://www.example.org/sites/all/modules/features/
https://www.example.org/sites/all/modules/features/CHANGELOG.txt
https://www.example.org/sites/all/modules/features/README.txt
https://www.example.org/sites/all/modules/features/LICENSE.txt
https://www.example.org/sites/all/modules/features/API.txt
[... 为README省略 ...]
[+] 扫描完成(耗时 0:04:59.502427)
你可以通过运行以下命令获取完整的选项列表:
droopescan --help
droopescan scan --help
因为droopescan:
使用pip安装很方便:
apt-get install python-pip
pip install droopescan
手动安装步骤如下:
git clone https://github.com/droope/droopescan.git
cd droopescan
pip install -r requirements.txt
./droopescan scan --help
master分支对应最新发布版(即pypi上的版本)。development分支不稳定,所有拉取请求必须针对development分支提交。
BlackArch 软件包安装(由第三方维护):
sudo pacman -S droopescan
你可以构建一个Docker镜像并从Docker运行droopescan:
git clone https://github.com/droope/droopescan.git
cd droopescan
docker build -t droope/droopescan .
# 显示帮助
docker run --rm droope/droopescan
# 扫描Drupal站点的示例
docker run --rm droope/droopescan scan drupal -u https://drupal.example.com
Droopescan旨在默认情况下尽可能准确,同时避免因过多并发请求而使目标服务器过载。因此,默认情况下会使用四个线程发送大量请求;可以通过--number和--threads参数更改这些设置。
该工具能够执行四种类型的测试。默认情况下会运行所有测试,但你可以使用-e或--enumerate标志指定其中一种:
你可以通过传递-u或--url参数指定要扫描的特定主机:
droopescan scan drupal -u example.org
你也可以省略drupal参数。这将触发“CMS识别”,如下所示:
droopescan scan -u example.org
可以使用-U或--url-file参数扫描多个URL。此参数应设置为包含URL列表的文件的路径。
droopescan scan drupal -U list_of_urls.txt
在此示例中也可以省略drupal参数。对于每个站点,它将执行若干GET请求以进行CMS识别,如果站点被认定为支持的CMS,则会进行扫描并添加到输出列表中。例如,这对于在整个组织的站点上运行droopescan非常有用。
droopescan scan -U list_of_urls.txt
下面的代码块包含一个URL列表示例,每行一个:
http://localhost/drupal/6.0/
http://localhost/drupal/6.1/
http://localhost/drupal/6.10/
http://localhost/drupal/6.11/
http://localhost/drupal/6.12/
包含URL和用于覆盖默认Host头的值(由制表符或空格分隔)的文件也可以用于URL文件。当扫描大量主机且希望避免不必要的DNS查询时,这非常方便。为清楚起见,下面是一个示例:
192.168.1.1 example.org
http://192.168.1.1/ example.org
http://192.168.1.2/drupal/ example.org
扫描官方站点(例如WordPress的wordpress.org)来测试扫描器是否适用于特定CMS是很有诱惑力的,但官方站点很少运行纯净的CMS安装,或者会做一些非常规的事情。例如,wordpress.org运行的是WordPress的最新开发版本,droopescan无法将其识别为WordPress,因为校验和与任何已知的WordPress版本都不匹配。
该应用程序完全支持.netrc文件和http_proxy环境变量。
对于基本身份验证,请使用.netrc文件。一个示例netrc文件(名为.netrc,放在你的主目录中)可能如下所示:
machine secret.google.com
login [email protected]
password Winter01
你可以设置http_proxy和https_proxy变量。这些变量允许你设置父HTTP代理,在其中可以处理更复杂的身份验证类型(例如Fiddler、ZAP、Burp)。
export http_proxy='user:password@localhost:8080'
export https_proxy='user:password@localhost:8080'
droopescan scan drupal --url http://localhost/drupal
警告: 为了允许拦截代理和测试具有不良SSL的应用程序,droopescan默认允许自签名或无效证书。˙ ͜ʟ˙
该应用程序支持“标准输出”(适合人工阅读)和JSON(更适合机器消费)。输出在主要版本之间保持稳定。
这可以通过--output标志控制。一些JSON输出示例如下(省略多余空格):
{
"themes": {
"is_empty": true,
"finds": [
]
},
"interesting urls": {
"is_empty": false,
"finds": [
{
"url": "https:\/\/www.drupal.org\/CHANGELOG.txt",
"description": "Default changelog file."
},
{
"url": "https:\/\/www.drupal.org\/user\/login",
"description": "Default admin."
}
]
},
"version": {
"is_empty": false,
"finds": [
"7.29",
"7.30",
"7.31"
]
},
"plugins": {
"is_empty": false,
"finds": [
{
"url": "https:\/\/www.drupal.org\/sites\/all\/modules\/views\/",
"name": "views"
},
[...snip...]
]
}
}
如果未运行扫描的某些部分,JSON对象中可能会缺少某些属性。
多站点输出如下所示;每一行包含一个如上所示的有效JSON对象。