Описание
label-studio vulnerable to Cross-Site Scripting (Reflected) via the label_config parameter.
Summary
The vulnerability allows an attacker to inject a malicious script into the context of a web page, which can lead to data theft, unauthorized actions on behalf of the user, and other attacks.
Details
The vulnerability is reproducible when sending a properly formatted request to the POST /projects/upload-example/ endpoint. In the source code, the vulnerability is located at label_studio/projects/views.py.
The vulnerability is specifically located in line 57, where HttpResponse is used.
PoC
Send the following request after changing the {host} to your own.
Or you can create a vulnerable HTML page by changing {domain} beforehand, which can later be sent to the victim.
Impact
- Malicious code execution: The user may be forced to perform unwanted actions within their Label Studio account. This includes accessing
document.cookie, but note that Label Studio session cookies are marked http-only, mitigating any possibility of session theft.
Пакеты
label-studio
< 1.18.0
1.18.0
Связанные уязвимости
Label Studio is a multi-type data labeling and annotation tool. A vulnerability in versions prior to 1.18.0 allows an attacker to inject a malicious script into the context of a web page, which can lead to data theft, session hijacking, unauthorized actions on behalf of the user, and other attacks. The vulnerability is reproducible when sending a properly formatted request to the `POST /projects/upload-example/` endpoint. In the source code, the vulnerability is located at `label_studio/projects/views.py`. Version 1.18.0 contains a patch for the issue.