CVE-2025-39473
Executive Summary
CVE-2025-39473 is a critical Path Traversal vulnerability (CWE-22) in the Seofy Core WordPress plugin, developed by WebGeniusLab. The vulnerability allows an unauthenticated attacker to perform PHP Local File Inclusion (LFI) by manipulating pathnames to include arbitrary PHP files from the server. This can lead to remote code execution if the attacker can upload a malicious file (e.g., via another plugin or log poisoning) and then include it. The plugin is widely used in WordPress sites for SEO and core functionality, making this a high-impact threat for the WordPress ecosystem.
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
This vulnerability affects a WordPress plugin distributed via the official WordPress plugin repository and third-party marketplaces. The plugin is not an NPM, PyPI, Go, or Ruby package, but it is part of the WordPress ecosystem. Users should verify the integrity of their plugin files and monitor for any unauthorized modifications.
CVSS Breakdown & Threat Level
- CVSS Score: 8.1 (High)
- Attack Vector: Network (AV:N)
- Attack Complexity: Low (AC:L)
- Privileges Required: None (PR:N)
- User Interaction: None (UI:N)
- Scope: Unchanged (S:U)
- Confidentiality Impact: High (C:H)
- Integrity Impact: None (I:N)
- Availability Impact: None (A:N)
The high confidentiality impact stems from the ability to read sensitive files (e.g., wp-config.php), while the lack of integrity/availability impact limits direct system compromise. However, LFI can be chained with other vulnerabilities for full RCE.
Deep Dive & Mechanics
The vulnerability resides in the seofy-core plugin, specifically in a function that handles file inclusion without proper sanitization of user-supplied path parameters. The plugin likely uses a parameter like file or template to include PHP files for rendering. An attacker can inject path traversal sequences (e.g., ../../../) to escape the intended directory and include arbitrary files.
Root Cause: The plugin fails to validate or sanitize the path input, allowing directory traversal. The vulnerable code may look like:
include($_GET['file'] . '.php');
This allows an attacker to include files like /etc/passwd (though PHP will append .php, so the attacker must use a null byte or other technique to bypass, or include files that already have .php extension).
Attack Scenario:
- Attacker sends a crafted HTTP request to a vulnerable endpoint.
- The request includes a path traversal payload, e.g.,
?file=../../../wp-config. - The plugin includes the file, exposing database credentials and other sensitive data.
Vulnerable vs. Patched Code
Vulnerable Code (seofy-core <= 1.6.8):
// In some template loader function
$template = $_GET['template'];
include(plugin_dir_path(__FILE__) . 'templates/' . $template . '.php');
This code directly concatenates user input into the path without validation.
Patched Code (Hypothetical):
$allowed_templates = ['default', 'custom', 'full-width'];
$template = $_GET['template'];
if (in_array($template, $allowed_templates)) {
include(plugin_dir_path(__FILE__) . 'templates/' . $template . '.php');
} else {
// Fallback to default
include(plugin_dir_path(__FILE__) . 'templates/default.php');
}
A proper patch would use a whitelist of allowed templates or sanitize the path using realpath() and ensure it stays within the allowed directory.
Exploitation & Lab Setup
Red Team (Offensive)
Lab Setup:
- Install WordPress with Seofy Core plugin version 1.6.8.
- Ensure the vulnerable endpoint is accessible (e.g.,
/wp-content/plugins/seofy-core/vulnerable-endpoint.php).
Exploitation Steps:
- Identify the vulnerable parameter (e.g.,
file,template,include). - Use a path traversal payload to read sensitive files:
GET /wp-content/plugins/seofy-core/vulnerable-endpoint.php?file=../../../wp-config - If the file is included, the response will contain the contents of
wp-config.php. - For LFI to RCE, upload a malicious PHP file (e.g., via media upload or another plugin) and include it:
GET /wp-content/plugins/seofy-core/vulnerable-endpoint.php?file=../../../wp-content/uploads/2025/04/shell
Example Payloads:
- Read
/etc/passwd:?file=../../../../../../etc/passwd%00 - Read
wp-config.php:?file=../../../wp-config
Blue Team (Defensive)
Detection:
- Monitor for path traversal patterns in HTTP requests (e.g.,
../,%2e%2e/). - Alert on attempts to include files outside the plugin's directory.
- Use WAF rules to block traversal sequences.
Hunting:
- Search logs for requests to the vulnerable endpoint with suspicious parameters.
- Check for unexpected file inclusions in PHP error logs.
Indicators of Compromise (IOCs)
- File Paths:
/wp-content/plugins/seofy-core/(any file modified after exploitation) - Network Patterns: HTTP requests containing
../or%2e%2ein parameters likefile,template,include. - Log Entries: PHP warnings about failed includes or file not found errors.
- System Files: Unauthorized access to
/etc/passwd,wp-config.php, or other sensitive files.
Detection Engineering
YARA Rule
rule CVE_2025_39473_Seofy_Core_LFI {
meta:
description = "Detects path traversal attempts against Seofy Core plugin"
author = "Valters IT"
date = "2025-04-10"
reference = "CVE-2025-39473"
strings:
$traversal1 = "../"
$traversal2 = "..\\"
$traversal3 = "%2e%2e/"
$traversal4 = "%2e%2e\\"
$param1 = "file="
$param2 = "template="
$param3 = "include="
condition:
any of ($param*) and any of ($traversal*)
}
Sigma Rule
title: Seofy Core LFI Attempt
id: 7a8b9c0d-1e2f-3a4b-5c6d-7e8f9a0b1c2d
status: experimental
description: Detects path traversal attempts against Seofy Core WordPress plugin
author: Valters IT
date: 2025/04/10
logsource:
category: webserver
product: apache
detection:
selection:
c-uri|contains:
- '/wp-content/plugins/seofy-core/'
c-uri|contains:
- '../'
- '..\\'
- '%2e%2e/'
- '%2e%2e\\'
condition: selection
falsepositives:
- Legitimate use of relative paths in other plugins
level: high
Suricata Rule
alert http any any -> any any (msg:"CVE-2025-39473 Seofy Core LFI Attempt"; flow:to_server,established; content:"/wp-content/plugins/seofy-core/"; http_uri; content:"../"; http_uri; distance:0; within:100; classtype:attempted-recon; sid:1000001; rev:1;)
Remediation & Mitigation
- Immediate Action: Disable the Seofy Core plugin until a patch is available.
- Workaround: Implement a Web Application Firewall (WAF) rule to block path traversal patterns.
- Patch: Apply the official patch from WebGeniusLab when released. If not available, manually fix the code by adding input validation and whitelisting.
- Monitoring: Enable detailed logging for the vulnerable endpoint and review logs for suspicious activity.
- Hardening: Ensure WordPress and all plugins are updated. Use security plugins like Wordfence to add an extra layer of protection.
Valters IT
Senior DevSecOps & Cyber Threat Intelligence Expert
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.