Add CVE-2024-39907: 1Panel SQL Injection Vulnerability #703
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
CVE-2024-39907: In-Depth Analysis of SQL Injection Vulnerability in 1Panel Control Panel
CVE-2024-39907 is a critical security vulnerability affecting the 1Panel server management control panel, involving multiple SQL injection points that could lead to remote code execution (RCE). Below is a detailed technical analysis of this vulnerability.
Vulnerability Overview
CVE-2024-39907 is a collection of multiple SQL injection vulnerabilities present in the 1Panel control panel. These vulnerabilities exist across several interfaces of 1Panel, where insufficient filtering could allow attackers to achieve arbitrary file writes and ultimately remote code execution (RCE)12.
1Panel is a web-based Linux server management control panel that provides a graphical interface for server administration. This vulnerability affects 1Panel v1.10.9-lts and earlier versions, and has been patched in v1.10.12-tls2.
Reference links:
Vulnerability Environment
Execute the following command to start a vulnerable instance of 1Panel v1.10.10-lts:
10086
1panel
1panel_password
entrance
Then access
http://your-ip:10086/entrance
to see the login page and log in using the default credentials.Vulnerability Reproduction
The vulnerability primarily exists in the API interfaces of 1Panel, particularly the
/api/v1/hosts/command/search
endpoint. Attackers can trigger SQL injection by carefully crafting request parameters2.A typical proof-of-concept (PoC) request is as follows:
This attempts to create a database file to confirm whether the injection is successful.
Limitations and Considerations
psession=you-session
cookie, the attacker must first obtain valid authentication credentials.