CVE-2021-36401: Moodle vulnerable to Stored Cross-site Scripting
4.8
CVSS Score
3.1
Basic Information
CVE ID
GHSA ID
EPSS Score
0.33437%
CWE
Published
3/7/2023
Updated
3/13/2023
KEV Status
No
Technology
PHP
Technical Details
CVSS Vector
CVSS:3.1/AV:A/AC:L/PR:L/UI:R/S:C/C:L/I:L/A:N
Package Name | Ecosystem | Vulnerable Versions | First Patched Version |
---|---|---|---|
moodle/moodle | composer | >= 3.11.0-beta, < 3.11.1 | 3.11.1 |
moodle/moodle | composer | >= 3.10.0-beta, < 3.10.5 | 3.10.5 |
moodle/moodle | composer | < 3.9.8 | 3.9.8 |
Vulnerability Intelligence
Miggo AI
Root Cause Analysis
The vulnerability stems from insufficient output encoding when exporting ID numbers to HTML data formats. Based on: 1) The advisory specifically mentions HTML export handlers 2) XSS occurs in downloaded files rather than web UI 3) Moodle's dataformat architecture uses format-specific writers 4) The CWE-79 classification indicates missing output encoding. While exact patch details are unavailable, Moodle's dataformat components handling HTML table generation (particularly ID number fields) would logically require sanitization that was missing in vulnerable versions.