CVE-2025-39506
Executive Summary
CVE-2025-39506 is a critical PHP Local File Inclusion (LFI) vulnerability discovered in the Nasa Core WordPress plugin, developed by NasaTheme. The vulnerability stems from improper control of a filename used in a PHP include or require statement, allowing an unauthenticated attacker to include arbitrary local files from the server. This can lead to sensitive information disclosure, such as reading the wp-config.php file containing database credentials, or potentially achieving remote code execution if combined with file upload capabilities. The vulnerability affects all versions of Nasa Core up to and including 6.3.2. No official patch has been released at the time of analysis.
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 through the official WordPress plugin repository and potentially via third-party marketplaces. The plugin is a core component for NasaTheme products, meaning any site using a NasaTheme product with this plugin is at risk. The lack of a patch increases the supply chain risk, as site administrators must rely on manual mitigation or disabling the plugin entirely.
CVSS Breakdown & Threat Level
- CVSS Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N
- Base Score: 8.1 (High)
- Attack Vector: Network (AV:N) – The vulnerability can be exploited remotely.
- Attack Complexity: Low (AC:L) – No special conditions are required.
- Privileges Required: None (PR:N) – No authentication is needed.
- User Interaction: None (UI:N) – No user action is required.
- Scope: Unchanged (S:U) – The vulnerable component and the impacted component are the same.
- Confidentiality Impact: High (C:H) – Sensitive files can be read.
- Integrity Impact: None (I:N) – No file modification is possible.
- Availability Impact: None (A:N) – No denial of service.
Threat Level: High. The low attack complexity and lack of authentication make this a prime target for automated scanning and exploitation.
Deep Dive & Mechanics
The vulnerability exists in the Nasa Core plugin's handling of file inclusion. The plugin likely uses a parameter (e.g., file, template, include) to dynamically load PHP files. Due to insufficient sanitization, an attacker can manipulate this parameter to include arbitrary files from the server's filesystem.
Root Cause: The plugin fails to properly validate or sanitize the filename before passing it to a PHP function like include(), require(), include_once(), or require_once(). This allows path traversal sequences (e.g., ../../) to escape the intended directory.
Attack Vector: An unauthenticated attacker sends a crafted HTTP request to a vulnerable endpoint, such as:
GET /wp-content/plugins/nasa-core/?file=../../../../wp-config.php
Impact:
- Information Disclosure: Reading sensitive files like
wp-config.php,/etc/passwd, or log files. - Potential RCE: If the attacker can upload a malicious file (e.g., via another plugin or feature), they can include it to execute arbitrary PHP code.
Vulnerable vs. Patched Code
Since no official patch is available, the vulnerable code is presumed to be similar to:
Vulnerable Code (PHP):
<?php
$file = $_GET['file'];
include($file . '.php');
?>
Patched Code (Hypothetical):
<?php
$allowed_files = array('template1', 'template2');
$file = $_GET['file'];
if (in_array($file, $allowed_files)) {
include($file . '.php');
} else {
// Handle error
}
?>
The patched version would implement a whitelist of allowed files or use realpath() to resolve the path and ensure it stays within the intended directory.
Exploitation & Lab Setup
Red Team (Offensive)
Prerequisites:
- A WordPress site with Nasa Core plugin version <= 6.3.2.
- Knowledge of the vulnerable endpoint (e.g.,
/wp-content/plugins/nasa-core/).
Exploitation Steps:
Identify the vulnerable parameter: Use a web browser or tool like Burp Suite to intercept requests and look for parameters like
file,include,template, orpage.Craft a path traversal payload: Use
../sequences to navigate to sensitive files.GET /wp-content/plugins/nasa-core/?file=../../../../wp-configRead sensitive files: The server will return the contents of
wp-config.php(without the.phpextension if the code appends it).
Example cURL command:
curl -v "http://target.com/wp-content/plugins/nasa-core/?file=../../../../wp-config"
Advanced Exploitation:
- Combine with file upload to achieve RCE.
- Use PHP wrappers like
php://filterto read files without extension issues:GET /wp-content/plugins/nasa-core/?file=php://filter/convert.base64-encode/resource=../../../../wp-config
Blue Team (Defensive)
Detection:
- Monitor web server logs for path traversal patterns (e.g.,
../,..\\,%2e%2e%2f). - Look for requests to
/wp-content/plugins/nasa-core/with suspicious parameters.
Mitigation:
- Disable the Nasa Core plugin until a patch is released.
- Implement a Web Application Firewall (WAF) rule to block path traversal attempts.
- Restrict file permissions on the server to limit the impact of LFI.
Indicators of Compromise (IOCs)
Network IOCs:
- HTTP requests containing
../or..\\in the query string targeting/wp-content/plugins/nasa-core/. - Requests with parameters like
file,include,template, orpagecontaining path traversal sequences. - Unusual base64-encoded strings in requests (indicating use of PHP wrappers).
File System IOCs:
- Unexpected access to
/etc/passwd,wp-config.php, or other sensitive files. - Presence of webshells in the uploads directory (if combined with file upload).
Log IOCs:
- Web server logs showing 200 responses to path traversal requests.
- PHP error logs indicating failed includes or file not found errors.
Detection Engineering
YARA Rule
rule CVE_2025_39506_LFI_Detection {
meta:
description = "Detects path traversal attempts targeting Nasa Core plugin"
author = "Valters IT"
date = "2025-04-10"
reference = "CVE-2025-39506"
strings:
$path_traversal = /(\.\.\/|\.\.\\){2,}/
$plugin_path = "/wp-content/plugins/nasa-core/"
$param_file = /[?&](file|include|template|page)=/
condition:
$plugin_path and $param_file and $path_traversal
}
Sigma Rule
title: CVE-2025-39506 Nasa Core LFI Attempt
id: 8a9b7c6d-5e4f-3a2b-1c0d-9e8f7a6b5c4d
status: experimental
description: Detects HTTP requests with path traversal patterns targeting Nasa Core plugin
author: Valters IT
date: 2025/04/10
logsource:
category: webserver
product: apache
detection:
selection:
cs-uri-query|contains:
- '/wp-content/plugins/nasa-core/'
- 'file='
- 'include='
- 'template='
- 'page='
cs-uri-query|re: '(\.\.\/|\.\.\\){2,}'
condition: selection
falsepositives:
- Legitimate use of path traversal in other contexts (rare)
level: high
Suricata Rule
alert http any any -> any any (
msg:"CVE-2025-39506 Nasa Core LFI Attempt";
flow:to_server,established;
content:"/wp-content/plugins/nasa-core/"; http_uri;
content:"file="; http_uri;
pcre:"/(\.\.\/|\.\.\\){2,}/";
classtype:attempted-recon;
sid:1000001;
rev:1;
)
Remediation & Mitigation
Immediate Actions:
- Disable the Nasa Core plugin until a patch is available.
- Implement a WAF rule to block path traversal patterns in requests to the plugin's directory.
- Review server logs for signs of exploitation.
Long-term Fix:
- Monitor the vendor's website for an official patch.
- If the plugin is critical, consider forking and patching the code yourself by implementing a whitelist of allowed files or using
realpath()validation.
General Best Practices:
- Keep all WordPress plugins and themes updated.
- Use a security plugin like Wordfence to detect and block LFI attempts.
- Restrict file permissions on the server to prevent reading sensitive files.
Valters IT
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.