CVE-2024-34006:
Moodle Unsanitized HTML in site log for config_log_created
4.3
CVSS Score
3.1
Basic Information
CVE ID
GHSA ID
EPSS Score
0.6938%
CWE
Published
5/31/2024
Updated
7/5/2024
KEV Status
No
Technology
PHP
Technical Details
CVSS Vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:N/I:L/A:N
Package Name | Ecosystem | Vulnerable Versions | First Patched Version |
---|---|---|---|
moodle/moodle | composer | >= 4.3.0, < 4.3.4 | 4.3.4 |
moodle/moodle | composer | >= 4.2.0, < 4.2.7 | 4.2.7 |
moodle/moodle | composer | < 4.1.10 | 4.1.10 |
Vulnerability Intelligence
Miggo AI
Root Cause Analysis
The vulnerability stems from unescaped HTML in site log event descriptions. Moodle's log table rendering uses column-specific methods like col_{columnname} to display data. The col_description method in the log table class (admin/tool/log/classes/table/log.php) is responsible for outputting event descriptions. Prior to patching, this method likely returned raw data without applying Moodle's output escaping (e.g., s() function or format_text with appropriate options), making it vulnerable to XSS via log entries. The CWE-838 classification confirms this is an output encoding issue, and the patch would have added escaping in this display layer function.