CVE-2020-37112

7.1 HIGH

📋 TL;DR

CVE-2020-37112 is an SQL injection vulnerability in GUnet OpenEclass 1.7.3 that allows authenticated attackers to manipulate database queries through unvalidated parameters like 'month' in the agenda module. Attackers can extract sensitive database information using error-based or time-based injection techniques. This affects all OpenEclass 1.7.3 installations with authenticated user access.

💻 Affected Systems

Products:
  • GUnet OpenEclass
Versions: 1.7.3
Operating Systems: Linux, Windows
Default Config Vulnerable: ⚠️ Yes
Notes: Requires authenticated user access; affects all installations of version 1.7.3 regardless of configuration.

📦 What is this software?

⚠️ Risk & Real-World Impact

🔴

Worst Case

Complete database compromise including user credentials, personal data, course materials, and administrative information leading to data theft, system takeover, or data destruction.

🟠

Likely Case

Extraction of sensitive user data (passwords, personal information), course content, and system configuration details that could enable further attacks.

🟢

If Mitigated

Limited information disclosure if proper input validation and parameterized queries are implemented, with minimal impact on system availability.

🌐 Internet-Facing: HIGH
🏢 Internal Only: MEDIUM

🎯 Exploit Status

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

Exploit code is publicly available on Exploit-DB (ID 48163); requires authenticated access but injection techniques are straightforward.

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: 1.7.4 and later

Vendor Advisory: https://download.openeclass.org/files/docs/1.7/CHANGES.txt

Restart Required: No

Instructions:

1. Backup your OpenEclass installation and database. 2. Download OpenEclass 1.7.4 or later from the official website. 3. Replace vulnerable files with patched versions. 4. Verify all SQL queries use parameterized statements. 5. Test functionality before production use.

🔧 Temporary Workarounds

Input Validation Filter

all

Add server-side validation to sanitize 'month' parameter and other user inputs before processing SQL queries.

Modify agenda module PHP files to validate month parameter: if(!is_numeric($_GET['month']) || $_GET['month'] < 1 || $_GET['month'] > 12) { die('Invalid month parameter'); }

Web Application Firewall Rules

all

Implement WAF rules to block SQL injection patterns in HTTP requests.

Add WAF rule: SecRule ARGS "(?i)(union.*select|sleep\(|benchmark\(|'\s+or\s+'") "id:1001,phase:2,deny,status:403,msg:'SQL Injection Attempt'"
Modify .htaccess: RewriteCond %{QUERY_STRING} (union.*select|sleep\(|benchmark\(|'\s+or\s+') [NC]\nRewriteRule .* - [F,L]

🧯 If You Can't Patch

  • Implement strict input validation for all user-controlled parameters in the agenda module and other endpoints
  • Deploy a web application firewall (WAF) with SQL injection detection rules

🔍 How to Verify

Check if Vulnerable:

Test the agenda module with SQL injection payloads: access /modules/agenda/index.php?month=1' AND SLEEP(5)-- and check for delayed response

Check Version:

Check OpenEclass version in admin panel or examine CHANGES.txt file in installation directory

Verify Fix Applied:

Attempt SQL injection tests after patching; verify all user inputs are properly validated and SQL queries use parameterized statements

📡 Detection & Monitoring

Log Indicators:

  • Unusual SQL error messages in application logs
  • Multiple failed login attempts followed by agenda module access
  • Requests with SQL keywords in parameters (UNION, SELECT, SLEEP, BENCHMARK)

Network Indicators:

  • HTTP requests containing SQL injection payloads in query parameters
  • Unusual database query patterns from web application server

SIEM Query:

source="web_logs" AND ("union select" OR "sleep(" OR "benchmark(" OR "' or '") AND uri_path="/modules/agenda/"

🔗 References

📤 Share & Export