CVE-2023-51298
📋 TL;DR
PHPJabbers Event Booking Calendar v4.0 has a CSV injection vulnerability that allows attackers to inject malicious formulas into exported CSV files. When victims open these files in spreadsheet applications like Excel, the formulas can execute commands or access external resources. This affects any organization using the vulnerable version of this event booking software.
💻 Affected Systems
- PHPJabbers Event Booking Calendar
📦 What is this software?
⚠️ Risk & Real-World Impact
Worst Case
Remote code execution on victim machines when malicious CSV files are opened in vulnerable spreadsheet applications, potentially leading to full system compromise.
Likely Case
Data exfiltration, command execution on client machines, or denial of service through malicious formulas in CSV files.
If Mitigated
Limited impact if users open CSV files in text editors instead of spreadsheet applications or have security controls blocking external connections.
🎯 Exploit Status
Exploit requires authenticated access to the admin panel to modify language labels, but CSV injection payloads are simple to craft.
🛠️ Fix & Mitigation
✅ Official Fix
Patch Version: Unknown
Vendor Advisory: Not available
Restart Required: No
Instructions:
No official patch available. Check vendor website for updates or consider alternative software.
🔧 Temporary Workarounds
Input Sanitization
allImplement server-side validation to sanitize language label inputs, removing or escaping special characters like =, +, -, @ that trigger formula execution.
Modify PHP code to filter: preg_replace('/[=+\-@]/', '', $input)
CSV Output Encoding
allPrepend formula characters with apostrophe or encode CSV output to prevent spreadsheet interpretation.
Modify CSV generation: $value = "'" . $value; or htmlspecialchars($value, ENT_QUOTES)
🧯 If You Can't Patch
- Restrict admin access to language settings to trusted users only
- Educate users to open CSV files in text editors, not spreadsheet applications
🔍 How to Verify
Check if Vulnerable:
Check if you can inject formulas like =cmd|' /C calc'!A0 into language labels and export CSV that executes when opened in Excel.
Check Version:
Check PHPJabbers version in admin panel or read software documentation files
Verify Fix Applied:
Test that injected formulas no longer execute when CSV files are opened in spreadsheet applications.
📡 Detection & Monitoring
Log Indicators:
- Unusual modifications to language labels in admin logs
- CSV export requests with suspicious parameters
Network Indicators:
- Outbound connections from spreadsheet applications after opening CSV files
SIEM Query:
source="web_logs" AND (uri="/admin/languages" OR uri="/export/csv") AND (param CONTAINS "=" OR param CONTAINS "+")