Skip to main content
Vulnerability Database/CVE-2025-13198

CVE-2025-13198: DouPHP Unrestricted File Upload Vulnerability

CVE-2025-13198 is an unrestricted file upload vulnerability in DouPHP up to version 1.8 Release 20251022 that enables remote attackers to upload malicious files. This post explains its impact, affected versions, and mitigation steps.

Published:

Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.

Sources: National Vulnerability Database, CISA KEV, Exploit-DB

CVE-2025-13198 Overview

CVE-2025-13198 is an unrestricted file upload vulnerability affecting DouPHP up to version 1.8 Release 20251022. The flaw resides in an unspecified function within upload/include/file.class.php. Attackers can manipulate the File argument to upload arbitrary files to the server. The weakness maps to [CWE-284] Improper Access Control. Exploitation requires network access and high privileges, but no user interaction. The exploit has been publicly disclosed, increasing the likelihood of opportunistic abuse against unpatched DouPHP instances.

Critical Impact

Authenticated attackers with high-level privileges can upload unrestricted file types to a vulnerable DouPHP installation, potentially enabling webshell deployment and follow-on code execution.

Affected Products

  • DouPHP up to and including 1.8 Release 20251022
  • Component: upload/include/file.class.php
  • Deployments exposing the DouPHP upload endpoint over the network

Discovery Timeline

  • 2025-11-15 - CVE-2025-13198 published to NVD
  • 2026-06-17 - Last updated in NVD database

Technical Details for CVE-2025-13198

Vulnerability Analysis

The vulnerability exists in DouPHP's file handling class located at upload/include/file.class.php. The upload routine processes the File argument without enforcing adequate restrictions on file type, extension, or MIME content. An authenticated attacker can submit a crafted upload request to place arbitrary content on the server. Depending on the destination path and web server configuration, uploaded files may be interpreted as executable scripts.

The weakness is classified under [CWE-284] Improper Access Control. Although the attack requires high privileges, the public disclosure of exploitation details lowers the barrier for abuse by insiders or attackers who have compromised administrative credentials through separate means.

Root Cause

The root cause is missing or insufficient validation inside the file upload handler. The code accepts the File parameter and writes it to disk without enforcing an allowlist of safe extensions or verifying the actual content type. This permits attackers to bypass intended restrictions on uploaded file formats.

Attack Vector

Exploitation proceeds over the network against the DouPHP web interface. An attacker authenticates with privileged credentials, then issues an HTTP request to the vulnerable upload endpoint carrying a malicious File payload. A successful upload places attacker-controlled content inside the web root. If the file is a server-side script, subsequent requests to that file can trigger execution within the DouPHP application context.

No verified exploit code is provided by the vendor advisory. See the GitHub Issue Report and the VulDB CVE Analysis for additional technical context.

Detect Identity Attacks the Moment Authentication Fails

Singularity™ Identity surfaces credential misuse, lateral movement, and privilege escalation in real time, so you can contain the breach before it spreads.

Stop Identity Attacks

Detection Methods for CVE-2025-13198

Indicators of Compromise

  • New or unexpected files appearing under DouPHP upload directories, particularly files with executable extensions such as .php, .phtml, or .phar
  • HTTP POST requests to endpoints that invoke file.class.php with unusual File parameter values
  • Outbound connections initiated by the PHP worker process following an upload event
  • Modified timestamps on files inside the DouPHP web root that do not correlate with legitimate administrative activity

Detection Strategies

  • Inspect web server access logs for POST requests targeting DouPHP upload handlers from unexpected source addresses or user agents
  • Monitor file integrity on the DouPHP installation directory and alert on new executable scripts
  • Correlate authentication events for administrative accounts with upload activity to spot credential misuse
  • Deploy web application firewall rules that block requests containing script extensions in the File parameter

Monitoring Recommendations

  • Enable verbose logging on PHP execution and the web server to capture request bodies and response codes for upload endpoints
  • Track process creation events spawned by the web server, including shell interpreters and network utilities
  • Centralize web, authentication, and host logs for cross-source correlation and retention

How to Mitigate CVE-2025-13198

Immediate Actions Required

  • Restrict access to the DouPHP administrative interface using network controls, VPN, or source IP allowlists
  • Audit administrative accounts, rotate credentials, and enforce multi-factor authentication where supported
  • Review the DouPHP upload directories for unauthorized files and remove any suspicious artifacts
  • Disable PHP execution within upload directories through web server configuration

Patch Information

At the time of publication, no vendor patch is referenced in the NVD entry. Administrators should monitor the GitHub Issue Report and the VulDB Submission Details for vendor updates. Until a fix is released, treat all DouPHP 1.8 Release 20251022 and earlier installations as vulnerable.

Workarounds

  • Configure the web server to refuse execution of scripts within upload paths using directives such as php_flag engine off or an equivalent handler override
  • Apply strict extension and MIME allowlisting at a reverse proxy or WAF layer in front of DouPHP
  • Limit administrative account issuance and remove unused privileged accounts to reduce the exploitable surface
  • Consider taking the application offline if administrative access cannot be constrained to trusted operators
bash
# Example Apache configuration to disable PHP execution within upload directories
<Directory "/var/www/douphp/upload">
    php_flag engine off
    <FilesMatch "\.(php|phtml|phar|php5|pht)$">
        Require all denied
    </FilesMatch>
</Directory>

Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.

Sources: National Vulnerability Database, CISA KEV, Exploit-DB

Experience the Most Advanced Cybersecurity Platform

See how the world’s most intelligent, autonomous cybersecurity platform can protect your organization today and into the future.