CVE-2022-27426

8.8 HIGH

📋 TL;DR

This Server-Side Request Forgery vulnerability in Chamilo LMS allows attackers to make the server send requests to internal network resources and execute arbitrary system commands via malicious Phar file uploads. It affects Chamilo LMS installations running vulnerable versions, potentially compromising the entire server and internal network.

💻 Affected Systems

Products:
  • Chamilo LMS
Versions: v1.11.13 and earlier versions
Operating Systems: All platforms running Chamilo LMS
Default Config Vulnerable: ⚠️ Yes
Notes: Requires file upload functionality to be accessible, which is typically enabled in default configurations.

📦 What is this software?

⚠️ Risk & Real-World Impact

🔴

Worst Case

Full server compromise leading to data exfiltration, lateral movement within internal networks, ransomware deployment, and complete system takeover.

🟠

Likely Case

Internal network reconnaissance, sensitive data exposure, and potential command execution on the vulnerable server.

🟢

If Mitigated

Limited to SSRF capabilities without command execution if Phar file uploads are blocked.

🌐 Internet-Facing: HIGH
🏢 Internal Only: MEDIUM

🎯 Exploit Status

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

Exploitation requires file upload access, which may require authentication depending on configuration.

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: v1.11.14 and later

Vendor Advisory: https://support.chamilo.org/projects/1/wiki/Security_issues

Restart Required: No

Instructions:

1. Backup your Chamilo installation and database. 2. Download the latest version from the official Chamilo website. 3. Replace the vulnerable files with patched versions. 4. Clear application cache. 5. Verify functionality.

🔧 Temporary Workarounds

Disable Phar file uploads

all

Block uploads of Phar files through web server configuration or application filtering

# Apache: Add to .htaccess
<FilesMatch "\.phar$">
    Require all denied
</FilesMatch>
# Nginx: Add to server block
location ~ \.phar$ {
    deny all;
}

Restrict file upload permissions

all

Limit file upload functionality to authenticated administrators only

🧯 If You Can't Patch

  • Implement strict network segmentation to isolate Chamilo server from sensitive internal resources
  • Deploy web application firewall with SSRF and file upload protection rules

🔍 How to Verify

Check if Vulnerable:

Check Chamilo version in administration panel or main.inc.php configuration file

Check Version:

grep -r "chamilo_version" /path/to/chamilo/ or check admin panel

Verify Fix Applied:

Verify version is 1.11.14 or later and test file upload functionality with Phar files

📡 Detection & Monitoring

Log Indicators:

  • Unusual file uploads with .phar extension
  • Outbound requests to internal IP ranges from Chamilo server
  • Suspicious system command execution in web server logs

Network Indicators:

  • Chamilo server making unexpected internal network requests
  • Outbound connections to unusual ports from web server

SIEM Query:

source="web_logs" AND (uri="*upload*" AND file_extension="phar") OR (src_ip="chamilo_server" AND dst_ip="internal_range")

🔗 References

📤 Share & Export