CVE-2025-6157

7.3 HIGH

📋 TL;DR

A critical SQL injection vulnerability exists in PHPGurukul Nipah Virus Testing Management System 1.0. Attackers can remotely exploit the /registered-user-testing.php file by manipulating the 'testtype' parameter to execute arbitrary SQL commands. This affects all deployments of version 1.0 of this healthcare management system.

💻 Affected Systems

Products:
  • PHPGurukul Nipah Virus Testing Management System
Versions: 1.0
Operating Systems: Any OS running PHP (typically Linux/Windows with Apache/Nginx)
Default Config Vulnerable: ⚠️ Yes
Notes: All installations of version 1.0 are vulnerable. The system requires PHP and MySQL/MariaDB.

📦 What is this software?

⚠️ Risk & Real-World Impact

🔴

Worst Case

Complete database compromise leading to data theft, data manipulation, or complete system takeover via SQL injection to RCE chaining.

🟠

Likely Case

Unauthorized access to sensitive patient testing data, administrative credentials theft, and database manipulation.

🟢

If Mitigated

Limited impact with proper input validation and WAF rules blocking SQL injection patterns.

🌐 Internet-Facing: HIGH - The vulnerability is remotely exploitable and affects a healthcare system that may be internet-facing for user access.
🏢 Internal Only: MEDIUM - Even internally, the system contains sensitive healthcare data that could be compromised.

🎯 Exploit Status

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

Exploit details are publicly available on GitHub. Attack requires access to registered user functionality but doesn't require admin privileges.

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: Unknown

Vendor Advisory: https://phpgurukul.com/

Restart Required: No

Instructions:

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

🔧 Temporary Workarounds

Input Validation and Sanitization

all

Add parameterized queries and input validation to /registered-user-testing.php

Modify PHP code to use prepared statements: $stmt = $conn->prepare('SELECT * FROM tests WHERE testtype = ?'); $stmt->bind_param('s', $testtype);

WAF Rule Implementation

linux

Deploy web application firewall rules to block SQL injection patterns

For ModSecurity: SecRule ARGS:testtype "@detectSQLi" "id:1001,phase:2,deny,status:403"

🧯 If You Can't Patch

  • Isolate the system behind a reverse proxy with strict WAF rules blocking SQL injection patterns
  • Implement network segmentation to limit database access only to necessary application servers

🔍 How to Verify

Check if Vulnerable:

Test the /registered-user-testing.php endpoint with SQL injection payloads in the testtype parameter (e.g., testtype=' OR '1'='1)

Check Version:

Check system documentation or about page; version may be displayed in footer or admin panel

Verify Fix Applied:

Verify that SQL injection payloads no longer execute and return proper error handling

📡 Detection & Monitoring

Log Indicators:

  • Unusual SQL queries in database logs
  • Multiple failed login attempts following SQL injection patterns
  • HTTP requests with SQL keywords in testtype parameter

Network Indicators:

  • HTTP POST requests to /registered-user-testing.php containing SQL injection payloads
  • Unusual database connection patterns from web server

SIEM Query:

source="web_logs" AND uri="/registered-user-testing.php" AND (testtype="*OR*" OR testtype="*UNION*" OR testtype="*SELECT*" OR testtype="*--*")

🔗 References

📤 Share & Export