File upload to Remote Code Execution on Zenario CMS 9.0.54156

Minh Quang Nguyen
3 min readSep 28, 2021

Product: Zenario 9.0.54156

Vulnerability Title: Authenticated File upload to RCE

Detailed description: It is possible to execute arbitrary commands on the webserver due to unsecure file upload functionality. An authenticated user with admin rights can upload a file then modify the file name to a executable extension.

Steps to reproduce:

1. Login to the admin page of Zenario CMS, which is http://server_ip/zenario/admin.php

2. Navigate to “Go to Organizer” and select “Documents”.

3. Select “Upload documents” and select file, in this case, I’m using a Microsoft Word (.docx) file.

Capture the upload request and modify file content. I’m adding PHP code into file content, and forward.

Back to browser, hit “Save”. The file is then uploaded to server.

4. Edit the file extension

Select “Edit document metadata”.

Zenario does not allow edit the file extension in the web interface. Okay, just “Save”.

Let’s check Burp Suite. This is request when click “Save”.

Decode param “box”:


Ok, so, I’m modify “docx” to “php”, and forward this request.


4. Access to this file

Next, moving to “Action” and select “View public link”.

Got public link, access to this.

Exploit success!

uid=33(www-data) gid=33(www-data) groups=33(www-data)

Code exploit:
Discoverer: Minh Quang Nguyen / Hanoi, Vietnam.
Request CVE id: 28/09/2021.
CVE: CVE-2021–42171 (RCE)