CVE-2023-31753

9.8 CRITICAL

📋 TL;DR

This SQL injection vulnerability in eNdonesia 8.7 allows attackers to execute arbitrary SQL commands through the 'rid=' parameter in diskusi.php. Attackers can potentially read, modify, or delete database content, and in some cases achieve remote code execution. All systems running eNdonesia 8.7 with the vulnerable diskusi.php file are affected.

💻 Affected Systems

Products:
  • eNdonesia
Versions: 8.7
Operating Systems: Any OS running PHP and MySQL/MariaDB
Default Config Vulnerable: ⚠️ Yes
Notes: Requires the diskusi.php file to be present and accessible via web requests.

📦 What is this software?

⚠️ Risk & Real-World Impact

🔴

Worst Case

Complete database compromise leading to data theft, data destruction, and potential remote code execution on the underlying server.

🟠

Likely Case

Unauthorized data access, privilege escalation, and potential administrative account takeover.

🟢

If Mitigated

Limited impact with proper input validation and database permissions, potentially only allowing data viewing.

🌐 Internet-Facing: HIGH - The vulnerability is in a web application component accessible via HTTP requests.
🏢 Internal Only: MEDIUM - Internal systems are still vulnerable but have reduced attack surface compared to internet-facing systems.

🎯 Exploit Status

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

Public proof-of-concept code exists on GitHub, making exploitation straightforward for attackers with basic SQL injection knowledge.

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: Unknown

Vendor Advisory: Unknown

Restart Required: No

Instructions:

No official patch available. Consider upgrading to a newer version if available, or implement workarounds.

🔧 Temporary Workarounds

Input Validation and Sanitization

all

Add parameter validation and sanitization for the 'rid' parameter in diskusi.php

Edit diskusi.php to add: $rid = intval($_GET['rid']); // Convert to integer
Or implement prepared statements with parameterized queries

Web Application Firewall (WAF) Rules

all

Block SQL injection patterns targeting the rid parameter

Add WAF rule: Block requests with SQL keywords in rid parameter
Example pattern: rid=.*(SELECT|UNION|INSERT|DELETE|UPDATE|DROP|ALTER).*

🧯 If You Can't Patch

  • Restrict access to diskusi.php using IP whitelisting or authentication
  • Implement database user with minimal permissions (read-only if possible)

🔍 How to Verify

Check if Vulnerable:

Test by accessing diskusi.php with SQL injection payload in rid parameter: http://target/diskusi.php?rid=1' OR '1'='1

Check Version:

Check eNdonesia version in configuration files or admin panel

Verify Fix Applied:

Test with same payload after implementing fixes - should return error or no SQL injection behavior

📡 Detection & Monitoring

Log Indicators:

  • Unusual SQL errors in web server logs
  • Multiple requests to diskusi.php with suspicious rid parameter values
  • Database query errors containing SQL injection patterns

Network Indicators:

  • HTTP requests with SQL keywords in GET parameters
  • Unusual traffic patterns to diskusi.php endpoint

SIEM Query:

source="web_server_logs" AND uri="*diskusi.php*" AND (query="*SELECT*" OR query="*UNION*" OR query="*OR '1'='1*")

🔗 References

📤 Share & Export