WordPress静态代码分析工具

2020-01-12 3,473 0

安装
只需克隆存储库,安装需求并运行脚本即可

$ git clone https://github.com/webarx-security/wpbullet wpbullet
$ cd wpbullet
$ pip install -r requirements.txt
$ python wpbullet.py

用法
可用选项:

--path (required) System path or download URL
Examples:
--path="/path/to/plugin"
--path="https://wordpress.org/plugins/example-plugin"
--path="https://downloads.wordpress.org/plugin/example-plugin.1.5.zip"

--enabled (optional) Check only for given modules, ex. --enabled="SQLInjection,CrossSiteScripting"
--disabled (optional) Don't check for given modules, ex. --disabled="SQLInjection,CrossSiteScripting"
--cleanup (optional) Automatically remove content of .temp folder after scanning remotely downloaded plugin

$ python wpbullet.py --path="/var/www/wp-content/plugins/plugin-name"

创建模块

创建模块是灵活的,允许覆盖BaseClass每个模块的方法以及创建自己的方法
Modules目录中的每个模块都是从中实现属性和方法core.modules.BaseClass,因此每个模块的必需参数是BaseClass
创建后,需要导入模块modules/init.py。模块和类名必须一致才能加载模块。
如果您要打开拉取请求以添加新模块,请同时为您的模块提供单元测试。

文章来源:

https://www.agesec.com/2233.html

相关文章

【严重】微软2025年5月补丁日 多个安全漏洞
免密支付陷阱,尽快解除
微软2024年10月补丁日 多个安全漏洞
ThinkPHP 的老漏洞依旧是黑客手中的大杀器
我在代码里面故意留个漏洞,违法吗?
Google Chrome 类型混淆漏洞

发布评论