CVE-2022-23336

9.8 CRITICAL

📋 TL;DR

S-CMS v5.0 contains a SQL injection vulnerability in the member_pay.php file through the O_id parameter. This allows attackers to execute arbitrary SQL commands on the database. Any organization using S-CMS v5.0 is affected.

💻 Affected Systems

Products:
  • S-CMS
Versions: v5.0
Operating Systems: All
Default Config Vulnerable: ⚠️ Yes
Notes: Only affects S-CMS v5.0 with member_pay.php accessible.

📦 What is this software?

⚠️ Risk & Real-World Impact

🔴

Worst Case

Complete database compromise leading to data theft, authentication bypass, remote code execution, and full system takeover.

🟠

Likely Case

Database information disclosure, authentication bypass, and potential privilege escalation.

🟢

If Mitigated

Limited impact with proper input validation and database permissions, but still a serious vulnerability.

🌐 Internet-Facing: HIGH
🏢 Internal Only: MEDIUM

🎯 Exploit Status

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

SQL injection via O_id parameter is straightforward to exploit.

🛠️ 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 implementing workarounds.

🔧 Temporary Workarounds

Input Validation and Sanitization

all

Implement strict input validation and parameterized queries for the O_id parameter in member_pay.php.

Modify member_pay.php to use prepared statements and validate O_id input

Web Application Firewall (WAF)

all

Deploy a WAF with SQL injection protection rules.

Configure WAF to block SQL injection patterns targeting member_pay.php

🧯 If You Can't Patch

  • Restrict access to member_pay.php using network controls or authentication.
  • Implement database user with minimal privileges for the application.

🔍 How to Verify

Check if Vulnerable:

Check if S-CMS version is 5.0 and member_pay.php exists. Test O_id parameter for SQL injection.

Check Version:

Check S-CMS configuration files or admin panel for version information.

Verify Fix Applied:

Verify that input validation is implemented and parameterized queries are used in member_pay.php.

📡 Detection & Monitoring

Log Indicators:

  • Unusual SQL queries in database logs
  • Multiple requests to member_pay.php with suspicious O_id values

Network Indicators:

  • HTTP requests to member_pay.php with SQL injection patterns in O_id parameter

SIEM Query:

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

🔗 References

📤 Share & Export