CVE-2024-34001
📋 TL;DR
This CVE describes a Cross-Site Request Forgery (CSRF) vulnerability in Moodle's admin preset tool where actions lack anti-CSRF tokens. Attackers can trick authenticated administrators into performing unauthorized actions like changing settings or deleting data. All Moodle instances with vulnerable versions are affected.
💻 Affected Systems
- Moodle
📦 What is this software?
Moodle by Moodle
Moodle by Moodle
Moodle by Moodle
⚠️ Risk & Real-World Impact
Worst Case
Complete site compromise through administrative account takeover, data deletion, or configuration changes leading to service disruption.
Likely Case
Unauthorized changes to site settings, user management, or course configurations by tricking administrators.
If Mitigated
Limited impact with proper CSRF protections, session management, and administrator awareness training.
🎯 Exploit Status
Exploitation requires social engineering to trick authenticated administrators into clicking malicious links.
🛠️ Fix & Mitigation
✅ Official Fix
Patch Version: Check Moodle security releases for specific version
Vendor Advisory: https://moodle.org/mod/forum/discuss.php?d=458389
Restart Required: No
Instructions:
1. Check Moodle security advisory for patched version. 2. Backup your Moodle instance. 3. Update to the patched version via Moodle's update mechanism or manual upgrade. 4. Verify the fix by testing admin preset tool functionality.
🔧 Temporary Workarounds
Temporary CSRF Protection
allImplement additional CSRF protection at web server level or disable admin preset tool if not needed.
🧯 If You Can't Patch
- Restrict admin preset tool access to trusted networks only
- Implement strict session management and educate administrators about CSRF risks
🔍 How to Verify
Check if Vulnerable:
Check if your Moodle version matches affected versions in Moodle security advisory; test admin preset tool for missing CSRF tokens.
Check Version:
Check Moodle version via Site administration > Notifications or view version.php file
Verify Fix Applied:
After patching, verify that admin preset tool actions now include proper CSRF tokens and cannot be executed via forged requests.
📡 Detection & Monitoring
Log Indicators:
- Unusual admin preset tool activity from unexpected IPs or sessions
- Multiple failed CSRF token validations
Network Indicators:
- HTTP requests to admin preset endpoints without proper referer headers or tokens
SIEM Query:
Search for POST requests to */admin/preset/* endpoints without valid CSRF tokens or from unusual user agents