CVE-2024-6801

6.3 MEDIUM

📋 TL;DR

This critical vulnerability in SourceCodester Online Student Management System 1.0 allows attackers to upload arbitrary files via the /add-students.php endpoint. This can lead to remote code execution or server compromise. All deployments of this specific software version are affected.

💻 Affected Systems

Products:
  • SourceCodester Online Student Management System
Versions: 1.0
Operating Systems: Any OS running PHP web server
Default Config Vulnerable: ⚠️ Yes
Notes: Affects all installations of version 1.0 regardless of configuration

📦 What is this software?

⚠️ Risk & Real-World Impact

🔴

Worst Case

Complete server takeover via webshell upload leading to data theft, ransomware deployment, or use as attack platform

🟠

Likely Case

Webshell upload enabling persistent backdoor access, data exfiltration, and lateral movement

🟢

If Mitigated

File upload attempts blocked or quarantined with no execution capability

🌐 Internet-Facing: HIGH - Attack can be launched remotely without authentication
🏢 Internal Only: MEDIUM - Still vulnerable but requires internal network access

🎯 Exploit Status

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

Public exploit available on GitHub, trivial to weaponize due to simple file upload bypass

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: Unknown

Vendor Advisory: None available

Restart Required: No

Instructions:

No official patch available. Consider migrating to alternative software or implementing workarounds.

🔧 Temporary Workarounds

Web Application Firewall Rule

all

Block requests to /add-students.php or restrict file uploads to specific extensions

WAF specific - configure rule to block: POST /add-students.php with file upload content

File Upload Restriction

linux

Implement server-side file type validation and store uploaded files outside web root

Modify PHP configuration: file_uploads = Off (if not needed)
Add .htaccess: <Files "add-students.php"> Order Allow,Deny Deny from all </Files>

🧯 If You Can't Patch

  • Remove or disable the /add-students.php file entirely
  • Implement strict network segmentation and isolate the vulnerable system

🔍 How to Verify

Check if Vulnerable:

Attempt to upload a file with malicious extension (e.g., .php) to /add-students.php endpoint

Check Version:

Check software version in admin panel or readme files

Verify Fix Applied:

Test that file uploads are properly validated and malicious files cannot be uploaded/executed

📡 Detection & Monitoring

Log Indicators:

  • Multiple POST requests to /add-students.php
  • File uploads with suspicious extensions (.php, .jsp, .asp)
  • Large file uploads to unexpected paths

Network Indicators:

  • Unusual outbound connections from web server
  • POST requests to /add-students.php from unexpected sources

SIEM Query:

source="web_logs" AND (uri="/add-students.php" OR file_extension IN ("php", "jsp", "asp"))

🔗 References

📤 Share & Export