Multiple Vulnerabilities in ResourceSpace
ResourceSpace contained an unauthenticated SQL injection in the external upload share feature, allowing an attacker to dump the database including admin session cookies and then gain admin access to upload a malicious plugin and achieve remote code execution. Two other vulnerabilities were a path traversal that could delete arbitrary files and a reflected XSS.
horizon3.ai
Published on horizon3.ai
A few months ago, while scanning the external attack surface of one of our clients, our autonomous pentesting product NodeZero identified an instance of an application called ResourceSpace exposed to the Internet. ResourceSpace is a digital asset management tool that enables users to organize their digital assets.
The full write-up lives on its author's site
It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.
Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.
How it worked
Root cause
Likely the external upload share feature passed an unsanitised authorization key directly into a SQL query, and other endpoints failed to sanitise path and parameter inputs.
Impact
An unauthenticated attacker could gain remote code execution on the server, delete arbitrary files causing denial of service, or run script in a victim's browser via reflected XSS.
What the attacker needed
ResourceSpace version 9.5 to 9.6.18229; No authentication needed for SQLi and path traversal; Victim must click a crafted link for XSS
The fix
The vulnerabilities were fixed by the vendor, who also removed the ability for administrators to upload custom plugins through the web interface.
How it was found
- Identify the vulnerable parameter `k` in the external upload share feature.
- Use sqlmap to confirm a boolean-based blind SQL injection.
- Dump the database to obtain admin session cookies.
- Set the stolen session cookie in a browser to access the admin interface.
- Upload a plugin containing a PHP webshell to execute commands on the server.
Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.
Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.
This report describes three security holes in a digital asset management tool. The most serious let an attacker who had not logged in run database commands, steal an administrator's session, and then upload a malicious plugin to run commands on the server. The other two let an attacker delete files or run script in a victim's browser.
What is SQL injection?
Input reaches a database query as code, letting an attacker read or change data the application never meant to expose.