CVE-2023-45387
📋 TL;DR
This vulnerability allows unauthenticated attackers to perform SQL injection attacks on PrestaShop websites using the 'Product Catalog Export PRO' module. Attackers can potentially extract, modify, or delete database content, affecting all PrestaShop installations with this vulnerable module installed.
💻 Affected Systems
- Product Catalog (CSV, Excel, XML) Export PRO module for PrestaShop
📦 What is this software?
Exportproducts by Myprestamodules
⚠️ Risk & Real-World Impact
Worst Case
Complete database compromise leading to data theft, data destruction, or remote code execution via database functions.
Likely Case
Data exfiltration of sensitive information including customer data, order history, and administrative credentials.
If Mitigated
Limited impact if proper input validation and parameterized queries are implemented at application layer.
🎯 Exploit Status
SQL injection via exportProduct::_addDataToDb() function requires minimal technical skill to exploit.
🛠️ Fix & Mitigation
✅ Official Fix
Patch Version: Version 5.0.1 or later
Vendor Advisory: https://security.friendsofpresta.org/modules/2023/11/16/exportproducts.html
Restart Required: No
Instructions:
1. Log into PrestaShop admin panel. 2. Navigate to Modules > Module Manager. 3. Find 'Product Catalog Export PRO' module. 4. Update to version 5.0.1 or later. 5. Clear PrestaShop cache.
🔧 Temporary Workarounds
Disable vulnerable module
allTemporarily disable the exportproducts module until patching is possible.
UPDATE ps_module SET active = 0 WHERE name = 'exportproducts';
Web Application Firewall rule
allBlock SQL injection patterns targeting exportProduct endpoints.
ModSecurity rule: SecRule ARGS "@detectSQLi" "id:1001,phase:2,deny,status:403,msg:'SQLi attempt detected'"
🧯 If You Can't Patch
- Implement network-level restrictions to limit access to PrestaShop admin and export functions
- Enable database query logging and monitoring for suspicious SQL patterns
🔍 How to Verify
Check if Vulnerable:
Check module version in PrestaShop admin panel under Modules > Module Manager > Product Catalog Export PRO.
Check Version:
SELECT version FROM ps_module WHERE name = 'exportproducts';
Verify Fix Applied:
Confirm module version is 5.0.1 or higher and test export functionality works without errors.
📡 Detection & Monitoring
Log Indicators:
- Unusual SQL queries in database logs
- Multiple failed export attempts from single IP
- Long parameter values in web server logs for export endpoints
Network Indicators:
- HTTP POST requests to export-related endpoints with SQL keywords in parameters
- Unusual database connection patterns from web server
SIEM Query:
source="web_server" AND (uri="/module/exportproducts/*" OR uri LIKE "%/export%") AND (param CONTAINS "UNION" OR param CONTAINS "SELECT" OR param CONTAINS "--" OR param CONTAINS "' OR '")
🔗 References
- https://addons.prestashop.com/en/data-import-export/18662-product-catalog-csv-excel-xml-export-pro.html
- https://security.friendsofpresta.org/modules/2023/11/16/exportproducts.html
- https://addons.prestashop.com/en/data-import-export/18662-product-catalog-csv-excel-xml-export-pro.html
- https://security.friendsofpresta.org/modules/2023/11/16/exportproducts.html