CVE-2020-13664
📋 TL;DR
This CVE describes an arbitrary PHP code execution vulnerability in Drupal Core that allows attackers to create specially named directories on the file system. When combined with brute force techniques, this can lead to remote code execution. Drupal sites running affected versions on Windows servers are most vulnerable.
💻 Affected Systems
- Drupal Core
📦 What is this software?
Drupal by Drupal
Drupal by Drupal
Drupal by Drupal
⚠️ Risk & Real-World Impact
Worst Case
Full server compromise allowing attackers to execute arbitrary PHP code, steal data, install malware, or pivot to other systems.
Likely Case
Attackers gain limited code execution capabilities, potentially compromising the Drupal site and accessing sensitive data.
If Mitigated
Attack is prevented through proper patching, resulting in no impact to the system.
🎯 Exploit Status
Requires social engineering to trick an administrator into visiting a malicious site, followed by directory creation and brute force attempts.
🛠️ Fix & Mitigation
✅ Official Fix
Patch Version: 8.8.8, 8.9.1, or 9.0.1
Vendor Advisory: https://www.drupal.org/sa-core-2020-005
Restart Required: No
Instructions:
1. Backup your Drupal site and database. 2. Update Drupal Core to the patched version using Composer: 'composer update drupal/core --with-dependencies'. 3. Run update.php via browser or drush: 'drush updatedb'. 4. Clear caches: 'drush cache-rebuild'.
🔧 Temporary Workarounds
Restrict Administrator Access
allLimit administrator access to trusted networks and implement strict access controls.
File System Permissions
linuxSet strict file system permissions to prevent directory creation in vulnerable locations.
chmod 755 /path/to/drupal/sites
chown www-data:www-data /path/to/drupal -R
🧯 If You Can't Patch
- Implement web application firewall (WAF) rules to block suspicious directory creation attempts.
- Monitor file system for unusual directory names and implement real-time alerting.
🔍 How to Verify
Check if Vulnerable:
Check Drupal version via admin interface at /admin/reports/status or using drush: 'drush status'.
Check Version:
drush status | grep 'Drupal version'
Verify Fix Applied:
Confirm version is 8.8.8, 8.9.1, 9.0.1 or higher using 'drush status' or checking /admin/reports/status.
📡 Detection & Monitoring
Log Indicators:
- Unusual directory creation in Drupal sites folder
- Failed PHP execution attempts in web server logs
- Administrator account accessing suspicious external URLs
Network Indicators:
- Outbound connections from Drupal server to unknown IPs
- Unusual spikes in traffic to admin pages
SIEM Query:
source="web_server_logs" AND ("POST /admin" OR "GET /admin") AND (referer="*malicious*" OR user_agent="*suspicious*")