CVE-2025-31040
📋 TL;DR
This vulnerability allows attackers to include local files on the server through improper filename control in PHP include/require statements. It affects WordPress sites running the WP Food ordering and Restaurant Menu plugin version 1.1 and earlier. Attackers can potentially read sensitive files or execute arbitrary code.
💻 Affected Systems
- WP Food ordering and Restaurant Menu WordPress plugin
⚠️ Manual Verification Required
This CVE does not have specific version information in our database, so automatic vulnerability detection cannot determine if your system is affected.
Why? The CVE database entry doesn't specify which versions are vulnerable (no version ranges provided by the vendor/NVD).
🔒 Custom verification scripts are available for registered users. Sign up free to download automated test scripts.
- Review the CVE details at NVD
- Check vendor security advisories for your specific version
- Test if the vulnerability is exploitable in your environment
- Consider updating to the latest version as a precaution
⚠️ Risk & Real-World Impact
Worst Case
Full server compromise through local file inclusion leading to remote code execution, data theft, and complete site takeover.
Likely Case
Sensitive file disclosure (configuration files, database credentials), limited code execution, and potential privilege escalation.
If Mitigated
Limited impact if proper file permissions and web server configurations restrict access to sensitive directories.
🎯 Exploit Status
Exploitation requires no authentication and uses simple HTTP requests with path traversal payloads.
🛠️ Fix & Mitigation
✅ Official Fix
Patch Version: 1.2 or later
Restart Required: No
Instructions:
1. Log into WordPress admin panel. 2. Navigate to Plugins > Installed Plugins. 3. Find 'WP Food ordering and Restaurant Menu'. 4. Click 'Update Now' if available. 5. If no update available, deactivate and delete plugin, then install fresh version 1.2+ from WordPress repository.
🔧 Temporary Workarounds
Disable vulnerable plugin
allTemporarily disable the plugin until patched version is available
wp plugin deactivate wp-food
Restrict PHP include paths
linuxConfigure PHP to restrict include paths to safe directories
php_admin_value open_basedir "/var/www/html:/tmp"
🧯 If You Can't Patch
- Implement web application firewall (WAF) rules to block path traversal patterns
- Restrict file system permissions and implement strict access controls on sensitive directories
🔍 How to Verify
Check if Vulnerable:
Check WordPress admin panel > Plugins for WP Food ordering and Restaurant Menu version 1.1 or earlier
Check Version:
wp plugin get wp-food --field=version
Verify Fix Applied:
Verify plugin version is 1.2 or later in WordPress admin panel
📡 Detection & Monitoring
Log Indicators:
- HTTP requests with ../ patterns in parameters
- PHP include/require errors in web server logs
- Access to unexpected files like /etc/passwd
Network Indicators:
- HTTP requests with path traversal payloads (../../etc/passwd)
- Unusual file access patterns from single IP
SIEM Query:
source="web_server_logs" AND ("../" OR "..\" OR "/etc/" OR "/proc/") AND uri_path="*wp-food*"