| عنوان | Dromara UJCMS v12.3.1 CWE-285 Improper Authorization |
|---|
| الوصف | Root Cause
The com.ujcms.cms.core.web.api.UserController exposes multiple user-existence checking endpoints without requiring authentication or authorization.
The affected methods directly query the user database and return a boolean value indicating whether the supplied username, mobile number, or email address exists.
For example:
@GetMapping("/username-exist")
public boolean usernameExist(@Parameter(description = "用户名")
@NotBlank String username) {
return service.selectByUsername(username) != null;
}
The same behavior is implemented by the following methods:
usernameNotExist()
usernameExist()
mobileNotExist()
mobileExist()
emailNotExist()
emailExist()
No authentication or authorization check is performed before returning the result.
Impact
An unauthenticated remote attacker can enumerate registered usernames, mobile phone numbers, and email addresses by submitting arbitrary values to the affected endpoints.
The disclosed information can be used to identify valid accounts and may facilitate subsequent attacks such as password spraying, credential attacks, phishing, or social engineering.
Vulnerability Details and POC
The following endpoints are affected:
/username-exist
/username-not-exist
/mobile-exist
/mobile-not-exist
/email-exist
/email-not-exist
For example, an unauthenticated request can be sent:
GET /api/user/username-exist?username=admin HTTP/1.1
Host: target.example
If the username exists, the application returns:
true
For a username that does not exist, the application returns:
false
Therefore, an attacker can automatically send requests using a username dictionary and determine which usernames are registered.
The same issue exists for the mobile-number and email-address existence-checking endpoints.
No authentication is required to reproduce the issue. |
|---|
| المصدر | ⚠️ https://github.com/dromara/ujcms/issues/22 |
|---|
| المستخدم | mjh_123 (UID 92618) |
|---|
| ارسال | 23/08/2026 05:05 PM (27 أيام منذ) |
|---|
| الاعتدال | 19/09/2026 11:19 AM (27 days later) |
|---|
| الحالة | تمت الموافقة |
|---|
| إدخال VulDB | 407920 [Dromara UJCMS حتى 12.3.1 UserController UserController.java usernameExist أسم المستخدم تجاوز الصلاحيات] |
|---|
| النقاط | 20 |
|---|