| Título | yangzongzhuan RuoYi 4.8.3 Cross-Site Scripting |
|---|
| Descrição | RuoYi 4.8.3 contains stored cross-site scripting in the role user-view page. Any authenticated user can update their own userName; the role view formatter later concatenates that value into a data-search HTML attribute without attribute encoding. A crafted display name executes script when a privileged user views role membership details.
Affected flow: self-service userName -> role user list JSON -> searchKey -> data-search attribute. Attack prerequisites: authenticated attacker; victim can view role membership details.
Reproduction: (1) Update the attacker's own display name with a quote-breaking attribute payload. (2) Confirm the exact value is stored and returned by the role user-list endpoint. (3) Open the role membership view and interact with the crafted user card.
Fresh verification marker: gt481022 / gt481022ry43. Three independent runs returned the exact quote-breaking userName from storage. Sanitized payload: userName: gt481022" onclick = eval(name). The rendered pattern is <div class="user-card" data-search="...injected attribute...">.
Confirmed source/sink in ruoyi-admin/src/main/resources/templates/system/role/view.html lines 593-596:
var searchKey = [u.userName || '', u.loginName || '', u.phonenumber || ''].join('|').toLowerCase();
var card = ['<div class="user-card" data-search="' + searchKey + '">', ...].join('');
Database persistence and the unescaped trigger response were confirmed in all 3/3 fresh runs. CWE-79. CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:L/I:L/A:N (5.4). |
|---|
| Fonte | ⚠️ https://github.com/yangzongzhuan/RuoYi/blob/master/ruoyi-admin/src/main/resources/templates/system/role/view.html |
|---|
| Utilizador | sanktsimone (UID 102457) |
|---|
| Submissão | 24/10/2026 06h10 (há 1 mês) |
|---|
| Moderação | 23/11/2026 07h40 (1 month later) |
|---|
| Estado | Aceite |
|---|
| Entrada VulDB | 442255 [yangzongzhuan RuoYi até 4.8.3 Role Management User-View view.html renderUserCards userName Script de Site Cruzado] |
|---|
| Pontos | 20 |
|---|