CVE-2025-13344

7.3 HIGH

📋 TL;DR

This vulnerability allows remote attackers to execute arbitrary SQL commands via the Username parameter in the /ajax.php?action=login endpoint of SourceCodester Train Station Ticketing System 1.0. This can lead to authentication bypass, data theft, or database manipulation. Organizations using this specific software version are affected.

💻 Affected Systems

Products:
  • SourceCodester Train Station Ticketing System
Versions: 1.0
Operating Systems: All
Default Config Vulnerable: ⚠️ Yes
Notes: Affects the web application component specifically at /ajax.php?action=login endpoint.

📦 What is this software?

⚠️ Risk & Real-World Impact

🔴

Worst Case

Complete database compromise including credential theft, data deletion, and potential remote code execution if database permissions allow.

🟠

Likely Case

Authentication bypass leading to unauthorized access, data exfiltration of user information and ticketing data.

🟢

If Mitigated

Limited impact with proper input validation and database permission restrictions in place.

🌐 Internet-Facing: HIGH
🏢 Internal Only: MEDIUM

🎯 Exploit Status

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

Exploit details are publicly available on GitHub, making this easily exploitable by attackers with basic SQL injection knowledge.

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: Unknown

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

Restart Required: No

Instructions:

No official patch available. Consider implementing input validation and parameterized queries in the source code.

🔧 Temporary Workarounds

Web Application Firewall (WAF) Rules

all

Implement WAF rules to block SQL injection patterns targeting the /ajax.php endpoint.

Input Validation Filter

all

Add server-side input validation to reject SQL special characters in the Username parameter.

🧯 If You Can't Patch

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

🔍 How to Verify

Check if Vulnerable:

Test the /ajax.php?action=login endpoint with SQL injection payloads in the Username parameter and observe database errors or unexpected responses.

Check Version:

Check the application version in the admin panel or source code files.

Verify Fix Applied:

Verify that SQL injection attempts no longer produce database errors or allow unauthorized access.

📡 Detection & Monitoring

Log Indicators:

  • SQL syntax errors in application logs
  • Multiple failed login attempts with SQL special characters
  • Unusual database queries from the application server

Network Indicators:

  • HTTP POST requests to /ajax.php containing SQL keywords like UNION, SELECT, OR 1=1

SIEM Query:

source="web_logs" AND uri="/ajax.php" AND (query="*UNION*" OR query="*SELECT*" OR query="*OR 1=1*")

🔗 References

📤 Share & Export