CVE-2025-10421

6.3 MEDIUM

📋 TL;DR

This SQL injection vulnerability in SourceCodester Student Grading System 1.0 allows attackers to manipulate database queries through the /update_account.php endpoint. Remote attackers can potentially access, modify, or delete sensitive student grading data. Organizations using this specific version of the software are affected.

💻 Affected Systems

Products:
  • SourceCodester Student Grading System
Versions: 1.0
Operating Systems: Any OS running PHP/MySQL
Default Config Vulnerable: ⚠️ Yes
Notes: Vulnerability exists in default installation of version 1.0

📦 What is this software?

⚠️ Risk & Real-World Impact

🔴

Worst Case

Complete database compromise leading to data theft, grade manipulation, or system takeover

🟠

Likely Case

Unauthorized access to student records and grading information

🟢

If Mitigated

Limited impact with proper input validation and database permissions

🌐 Internet-Facing: HIGH - Attack can be launched remotely without authentication
🏢 Internal Only: MEDIUM - Internal attackers could exploit if system is accessible

🎯 Exploit Status

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

Exploit details are publicly available on GitHub, making exploitation straightforward

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: Not available

Vendor Advisory: https://www.sourcecodester.com/

Restart Required: No

Instructions:

No official patch available. Consider upgrading to newer version if available or implementing workarounds.

🔧 Temporary Workarounds

Input Validation and Sanitization

PHP/MySQL

Implement proper input validation and parameterized queries for the ID parameter

Modify /update_account.php to use prepared statements: $stmt = $conn->prepare('UPDATE accounts SET ... WHERE id = ?'); $stmt->bind_param('i', $id);

Web Application Firewall

all

Deploy WAF rules to block SQL injection patterns

Add WAF rule: SecRule ARGS:id "@detectSQLi" "id:1001,phase:2,deny,status:403"

🧯 If You Can't Patch

  • Restrict network access to the grading system using firewall rules
  • Implement database user with minimal required permissions

🔍 How to Verify

Check if Vulnerable:

Test /update_account.php endpoint with SQL injection payloads like ' OR '1'='1

Check Version:

Check system version in admin panel or readme files

Verify Fix Applied:

Test with same payloads and verify they are rejected or sanitized

📡 Detection & Monitoring

Log Indicators:

  • Unusual SQL queries in database logs
  • Multiple failed login attempts or parameter manipulation in web logs

Network Indicators:

  • HTTP requests to /update_account.php with SQL keywords in parameters

SIEM Query:

web.url:*update_account.php* AND (web.param:*OR* OR web.param:*UNION* OR web.param:*SELECT*)

🔗 References

📤 Share & Export