CVE-2024-7198

6.3 MEDIUM

📋 TL;DR

This critical SQL injection vulnerability in SourceCodester Complaints Report Management System 1.0 allows attackers to manipulate database queries through the 'id' parameter in /admin/manage_station.php. Attackers can potentially read, modify, or delete sensitive data, and in some cases gain administrative access. All deployments of this specific software version are affected.

💻 Affected Systems

Products:
  • SourceCodester Complaints Report Management System
Versions: 1.0
Operating Systems: All
Default Config Vulnerable: ⚠️ Yes
Notes: Only affects the specific version 1.0 of this software. The vulnerability exists in the default installation.

📦 What is this software?

⚠️ Risk & Real-World Impact

🔴

Worst Case

Complete database compromise leading to data theft, data destruction, or full system takeover via privilege escalation.

🟠

Likely Case

Unauthorized data access, credential theft, and potential administrative account takeover.

🟢

If Mitigated

Limited data exposure if proper input validation and database permissions are enforced.

🌐 Internet-Facing: HIGH - Remote exploitation possible with public exploit available.
🏢 Internal Only: HIGH - SQL injection can be exploited from any network location with access to the application.

🎯 Exploit Status

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

Exploit requires access to admin interface but SQL injection is straightforward once authenticated. Public proof-of-concept available on GitHub gist.

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: Unknown

Vendor Advisory: None available

Restart Required: No

Instructions:

No official patch available. Consider upgrading to a newer version if available, or implement input validation and parameterized queries in the source code.

🔧 Temporary Workarounds

Web Application Firewall (WAF)

all

Deploy a WAF with SQL injection protection rules to block malicious requests.

Input Validation

all

Implement server-side validation to ensure 'id' parameter contains only numeric values.

🧯 If You Can't Patch

  • Isolate the application behind a reverse proxy with strict input filtering
  • Implement network segmentation to limit database access from application servers

🔍 How to Verify

Check if Vulnerable:

Test the /admin/manage_station.php endpoint with SQL injection payloads in the 'id' parameter (e.g., id=1' OR '1'='1).

Check Version:

Check the software version in the application interface or configuration files.

Verify Fix Applied:

Verify that SQL injection attempts no longer succeed and that input validation is properly implemented.

📡 Detection & Monitoring

Log Indicators:

  • Unusual SQL queries in database logs
  • Multiple failed login attempts followed by SQL injection patterns
  • Requests to /admin/manage_station.php with suspicious 'id' parameters

Network Indicators:

  • HTTP requests containing SQL keywords (SELECT, UNION, etc.) in URL parameters
  • Unusual database connection patterns from application servers

SIEM Query:

source="web_logs" AND url="/admin/manage_station.php" AND (id="*'*" OR id="*SELECT*" OR id="*UNION*")

🔗 References

📤 Share & Export