CVE-2025-4716

7.3 HIGH

📋 TL;DR

Campcodes Sales and Inventory System 1.0 contains a critical SQL injection vulnerability in the /pages/credit_transaction_add.php file via the prod_name parameter. This allows remote attackers to execute arbitrary SQL commands on the database. All users running this software are affected.

💻 Affected Systems

Products:
  • Campcodes Sales and Inventory System
Versions: 1.0
Operating Systems: Any OS running PHP and MySQL
Default Config Vulnerable: ⚠️ Yes
Notes: The vulnerability exists in the default installation. No special configuration is required for exploitation.

📦 What is this software?

⚠️ Risk & Real-World Impact

🔴

Worst Case

Complete database compromise including data theft, data manipulation, and potential remote code execution via database functions.

🟠

Likely Case

Unauthorized data access, data exfiltration, and potential privilege escalation within the application.

🟢

If Mitigated

Limited impact with proper input validation and parameterized queries in place.

🌐 Internet-Facing: HIGH - The vulnerability is remotely exploitable and public exploit details are available.
🏢 Internal Only: MEDIUM - Internal attackers could still exploit this, but external threat is higher.

🎯 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.campcodes.com/

Restart Required: No

Instructions:

No official patch available. Consider implementing workarounds or replacing the software.

🔧 Temporary Workarounds

Input Validation Filter

all

Add input validation to sanitize the prod_name parameter before processing

Modify /pages/credit_transaction_add.php to include: $prod_name = mysqli_real_escape_string($conn, $_POST['prod_name']);

Web Application Firewall

all

Deploy WAF rules to block SQL injection patterns

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

🧯 If You Can't Patch

  • Isolate the system from internet access and restrict to internal network only
  • Implement strict network segmentation and monitor all database queries

🔍 How to Verify

Check if Vulnerable:

Test the /pages/credit_transaction_add.php endpoint with SQL injection payloads in prod_name parameter

Check Version:

Check system documentation or configuration files for version information

Verify Fix Applied:

Test with same payloads after implementing fixes to confirm they are blocked

📡 Detection & Monitoring

Log Indicators:

  • Unusual SQL queries in database logs
  • Multiple failed login attempts from credit_transaction_add.php

Network Indicators:

  • HTTP POST requests to /pages/credit_transaction_add.php with SQL keywords in parameters

SIEM Query:

source="web_logs" AND uri="/pages/credit_transaction_add.php" AND (param="prod_name" AND value MATCHES "(?i)(union|select|insert|update|delete|drop|--|#|/*)")

🔗 References

📤 Share & Export