CVE-2024-7753

5.3 MEDIUM

📋 TL;DR

This vulnerability in SourceCodester Clinics Patient Management System 1.0 allows attackers to directly access files in the /user_images/ directory without proper authorization. It affects all installations of this specific healthcare management software. The vulnerability enables unauthorized file retrieval through direct requests to the vulnerable endpoint.

💻 Affected Systems

Products:
  • SourceCodester Clinics Patient Management System
Versions: 1.0
Operating Systems: Any OS running the web application
Default Config Vulnerable: ⚠️ Yes
Notes: Affects all default installations of version 1.0. The vulnerability is in the web application code, not OS-specific.

📦 What is this software?

⚠️ Risk & Real-World Impact

🔴

Worst Case

Attackers could retrieve sensitive patient images, medical documents, or other files stored in the user_images directory, potentially exposing protected health information (PHI) and violating privacy regulations.

🟠

Likely Case

Unauthorized access to user-uploaded images and files, potentially including patient photos, medical documentation, or system files inadvertently stored in this directory.

🟢

If Mitigated

If proper access controls and directory restrictions are implemented, impact is limited to non-sensitive files or empty directories.

🌐 Internet-Facing: HIGH
🏢 Internal Only: MEDIUM

🎯 Exploit Status

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

Exploit requires only direct HTTP requests to the vulnerable endpoint. No authentication or special tools needed.

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: Unknown

Vendor Advisory: None available

Restart Required: No

Instructions:

No official patch available. Check SourceCodester website for updates or consider alternative software.

🔧 Temporary Workarounds

Restrict /user_images/ Directory Access

all

Implement access controls to prevent direct requests to the /user_images/ directory

# Apache: Add to .htaccess
<Directory /path/to/user_images>
    Order Deny,Allow
    Deny from all
</Directory>
# Nginx: Add to server block
location /user_images/ {
    deny all;
    return 403;
}

Move Sensitive Files

linux

Relocate sensitive files outside web-accessible directories

mv /var/www/html/user_images/* /secure/storage/
ln -s /secure/storage/ /var/www/html/user_images

🧯 If You Can't Patch

  • Implement web application firewall (WAF) rules to block direct requests to /user_images/
  • Monitor and alert on unusual access patterns to the /user_images/ directory

🔍 How to Verify

Check if Vulnerable:

Attempt to access http://[target]/user_images/ or specific files within that directory without authentication. If files are accessible, system is vulnerable.

Check Version:

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

Verify Fix Applied:

After implementing controls, attempt the same access. Should receive 403 Forbidden or similar access denied response.

📡 Detection & Monitoring

Log Indicators:

  • Multiple 200 OK responses to /user_images/ requests from single IP
  • Unusual file access patterns to image directories

Network Indicators:

  • HTTP GET requests to /user_images/ with directory traversal attempts
  • Unusual volume of requests to image directories

SIEM Query:

source="web_server" AND (uri_path="/user_images/*" OR uri_path CONTAINS "/user_images/") AND response_code=200

🔗 References

📤 Share & Export