File upload filter bypass leading to stored XSS in microweber/microweber

Valid

Reported on

Mar 11th 2022


Description

A User can upload .[a-z]html file (e.g. ahtml, bhtml, chtml, ddhtml, AS LONG AS it ends with html) with XSS payload. Upon upload, a URL with malicious html can be accessed and javascript will be executed.

Proof of Concept (taking chtml as example)

Step (1) Login to the demo portal with admin creds at https://demo.microweber.org/demo/admin/

Step (2) Add new > Page > Add file in picture

Step (3) Upload below file with content below and named as xss.chtml <div onmouseover="alert(document.domain)" style="position:fixed;left:0;top:0;width:9999px;height:9999px;"></div>

Step(4) Access the link in response and once you move the cursor, alert box will be prompted image image

Impact

If an attacker can control a script that is executed in the victim's browser, they might compromise that user, in this case, an admin, by stealing its cookies.

We are processing your report and will contact the microweber team within 24 hours. 5 months ago
James Yeung modified the report
5 months ago
James Yeung modified the report
5 months ago
Bozhidar Slaveykov validated this vulnerability 5 months ago
James Yeung has been awarded the disclosure bounty
The fix bounty is now up for grabs
Bozhidar Slaveykov confirmed that a fix has been merged on 33eb4c 5 months ago
Bozhidar Slaveykov has been awarded the fix bounty
to join this conversation