CVE-2024-5377

7.3 HIGH

📋 TL;DR

This vulnerability allows remote attackers to upload arbitrary files to the Vehicle Management System 1.0 via the /newvehicle.php endpoint. Attackers can potentially execute malicious code on the server, compromising the entire system. All users running the vulnerable version are affected.

💻 Affected Systems

Products:
  • SourceCodester Vehicle Management System
Versions: 1.0
Operating Systems: Any OS running PHP web server
Default Config Vulnerable: ⚠️ Yes
Notes: Affects the /newvehicle.php file specifically. No authentication required for exploitation.

📦 What is this software?

⚠️ Risk & Real-World Impact

🔴

Worst Case

Complete system compromise leading to data theft, ransomware deployment, or creation of persistent backdoors.

🟠

Likely Case

Webshell upload enabling remote command execution, data exfiltration, and lateral movement within the network.

🟢

If Mitigated

File upload attempts blocked or quarantined with no successful exploitation.

🌐 Internet-Facing: HIGH - Attack can be initiated remotely without authentication.
🏢 Internal Only: MEDIUM - Internal attackers could exploit, but external threat is more significant.

🎯 Exploit Status

Public PoC: ⚠️ Yes
Weaponized: LIKELY
Unauthenticated Exploit: ⚠️ Yes
Complexity: LOW

Exploit code is publicly available on GitHub. Simple file upload bypass techniques can be used.

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: Unknown

Vendor Advisory: None available

Restart Required: No

Instructions:

No official patch available. Consider workarounds or replacing with alternative software.

🔧 Temporary Workarounds

Web Application Firewall (WAF) Rules

all

Block malicious file uploads to /newvehicle.php

WAF specific - configure to block file uploads with dangerous extensions (.php, .jsp, .asp, etc.) to vulnerable endpoint

File Upload Restrictions

linux

Implement server-side file type validation and extension filtering

Modify PHP configuration: file_uploads = Off (if not needed) or implement strict validation in newvehicle.php

🧯 If You Can't Patch

  • Remove or rename /newvehicle.php file if functionality not required
  • Implement network segmentation to isolate the vulnerable system from critical assets

🔍 How to Verify

Check if Vulnerable:

Attempt to upload a test file (e.g., test.php with harmless content) to /newvehicle.php. If accepted without proper validation, system is vulnerable.

Check Version:

Check application version in admin panel or readme files. No standard command available.

Verify Fix Applied:

Attempt same upload test - should be rejected with proper error message or file type validation.

📡 Detection & Monitoring

Log Indicators:

  • Multiple failed/successful file upload attempts to /newvehicle.php
  • Uploads of files with suspicious extensions (.php, .jsp, .asp)

Network Indicators:

  • POST requests to /newvehicle.php with file upload content
  • Unusual outbound connections from web server

SIEM Query:

source="web_logs" AND uri="/newvehicle.php" AND (method="POST" OR file_extension IN ("php", "jsp", "asp", "aspx"))

🔗 References

📤 Share & Export