Skip to main content

CVE-2025-31913: CWE-98 Improper Control of Filename for Include/Require Statement in PHP Program ('PHP Remote File Inclusion') in ApusTheme Ogami

High
VulnerabilityCVE-2025-31913cvecve-2025-31913cwe-98
Published: Fri May 23 2025 (05/23/2025, 12:44:03 UTC)
Source: CVE
Vendor/Project: ApusTheme
Product: Ogami

Description

Improper Control of Filename for Include/Require Statement in PHP Program ('PHP Remote File Inclusion') vulnerability in ApusTheme Ogami allows PHP Local File Inclusion. This issue affects Ogami: from n/a through 1.53.

AI-Powered Analysis

AILast updated: 07/08/2025, 23:55:50 UTC

Technical Analysis

CVE-2025-31913 is a high-severity vulnerability classified under CWE-98, which pertains to improper control of filenames used in include or require statements within PHP programs. Specifically, this vulnerability affects the ApusTheme Ogami product, versions up to and including 1.53. The flaw allows for PHP Local File Inclusion (LFI), which means an attacker can manipulate the file path parameters used in PHP include or require functions to load unintended files from the local server. This can lead to the execution of arbitrary code, disclosure of sensitive information, or complete compromise of the affected web application. The vulnerability is remotely exploitable over the network without requiring authentication or user interaction, but it has a high attack complexity, indicating some conditions must be met for successful exploitation. The CVSS v3.1 base score is 8.1, reflecting high impact on confidentiality, integrity, and availability. Although no known exploits are currently reported in the wild, the nature of LFI vulnerabilities makes them attractive targets for attackers to escalate privileges or pivot within compromised environments. The vulnerability arises from insufficient validation or sanitization of user-supplied input that controls the filename in include/require statements, allowing attackers to traverse directories or specify arbitrary local files. This can lead to disclosure of configuration files, source code, or even execution of malicious payloads if combined with other vulnerabilities or misconfigurations.

Potential Impact

For European organizations using the ApusTheme Ogami theme, particularly those running vulnerable versions on their websites or web applications, this vulnerability poses a significant risk. Successful exploitation could lead to unauthorized disclosure of sensitive data such as credentials, customer information, or internal configuration files. It could also allow attackers to execute arbitrary code, potentially leading to full system compromise, defacement, or use of the affected systems as a foothold for further attacks within the network. Given the high confidentiality, integrity, and availability impacts, organizations may face regulatory consequences under GDPR if personal data is exposed. The risk is heightened for organizations in sectors with high web presence such as e-commerce, media, and public services. Additionally, the lack of authentication requirement means that any external attacker with network access to the vulnerable web application can attempt exploitation, increasing the threat surface. The absence of known exploits in the wild currently provides a window for proactive mitigation before widespread attacks occur.

Mitigation Recommendations

1. Immediate upgrade or patching: Organizations should verify if ApusTheme has released a patch or updated version beyond 1.53 that addresses this vulnerability and apply it promptly. 2. Input validation and sanitization: Implement strict validation on all user inputs that influence file inclusion paths, ensuring only expected and safe filenames or paths are accepted. 3. Disable remote file inclusion: Configure PHP settings to disable allow_url_include and allow_url_fopen to prevent remote file inclusion vectors. 4. Use whitelisting: Restrict include/require statements to a predefined set of allowed files or directories rather than dynamically including files based on user input. 5. Web application firewall (WAF): Deploy and tune WAF rules to detect and block suspicious requests attempting directory traversal or file inclusion patterns. 6. Monitoring and logging: Enable detailed logging of web server and application errors to detect attempts to exploit LFI and respond quickly. 7. Least privilege: Ensure the web server and PHP processes run with minimal privileges to limit the impact of any successful exploitation. 8. Conduct security assessments: Perform code reviews and penetration testing focused on file inclusion and input validation to identify and remediate similar issues.

Need more detailed analysis?Get Pro

Technical Details

Data Version
5.1
Assigner Short Name
Patchstack
Date Reserved
2025-04-01T13:21:47.737Z
Cisa Enriched
false
Cvss Version
3.1
State
PUBLISHED

Threat ID: 68306f8e0acd01a249272343

Added to database: 5/23/2025, 12:52:30 PM

Last enriched: 7/8/2025, 11:55:50 PM

Last updated: 7/30/2025, 4:09:32 PM

Views: 12

Actions

PRO

Updates to AI analysis are available only with a Pro account. Contact root@offseq.com for access.

Please log in to the Console to use AI analysis features.

Need enhanced features?

Contact root@offseq.com for Pro access with improved analysis and higher rate limits.

Latest Threats