CVE-2024-33998
NoneCVSS
—
EPSS
0.4%
Published
May 31, 2024
CISA due date
—
Cloudanix analysis
A flaw in the way user names are shown on a course participants screen could let someone slip in hidden code that runs when others view the page, potentially exposing private information.
- Exploitation
- Requires User Interaction
- Attacker needs
- Low Privilege
- Complexity
- Low
- Impact
- Data Exposure
- Component
- Application
- Class
- XSS
- Remediation
- Upgrade
- Effort
- Low
- Patch risk
- Low
What it actually does
Insufficient escaping of participant names in the participants page table allows injection and persistent execution of arbitrary JavaScript in other users' browsers when certain page features are interacted with.
Why it matters to the business
Attackers can hijack educator or student sessions, steal sensitive course or personal data, or perform unauthorized actions inside the learning platform, increasing risk of data breaches and compliance violations in educational environments.
How an attack unfolds
An attacker with the ability to set or modify a participant's name supplies a crafted string containing malicious script tags; when an authorized user later views the participants table and triggers interactive features, the script executes in that user's session context with their privileges.
How to fix it
Upgrade Moodle to the commit e8d03fdae4ec30a40cdc535c8e9e95f30604ec10 or a later release containing the escaping fix; apply vendor patches promptly and verify the participants page no longer renders unescaped name data.
How to confirm the fix worked
Confirm the installed codebase contains the escaping change from commit e8d03fdae4ec30a40cdc535c8e9e95f30604ec10; retest the participants page with name values containing HTML/script characters to ensure they are encoded before rendering.
Typical attack path
- Obtain an account or enrollment that permits editing participant display names
- Insert a payload containing executable script code into a participant name field
- Wait for or lure a privileged user to load the participants page and engage interactive elements
- Script executes to exfiltrate session tokens, perform actions, or pivot within the application
How to detect it
Inspect web server and application logs for requests that include HTML or script tags in name-related parameters; monitor for unexpected JavaScript execution or unusual outbound requests originating from the participants page.
What your security team should do
- Prioritize upgrade of all Moodle instances to the fixed commit within the next maintenance window
- Review participant name input validation and escaping controls across similar list views
- Enable web application firewall rules that sanitize or block common XSS patterns in user-generated content
- Audit recent participant name changes for signs of prior tampering
The record
Insufficient escaping of participants' names in the participants page table resulted in a stored XSS risk when interacting with some features.
Affected packages
| Ecosystem | Package | Introduced | Fixed |
|---|---|---|---|
| Packagist | moodle/moodle | 0 | 4.1.10 |
| Packagist | moodle/moodle | 4.2.0 | 4.2.7 |
| Packagist | moodle/moodle | 4.3.0 | 4.3.4 |
| Bitnami | moodle | 0 | 4.1.10 |
| Ubuntu:16.04:LTS | moodle | 0 | No fix |
| Ubuntu:18.04:LTS | moodle | 0 | No fix |
| Ubuntu:Pro:16.04:LTS | moodle | 0 | No fix |
| Ubuntu:Pro:18.04:LTS | moodle | 0 | No fix |
| packagist | moodle/moodle | 4.2.0 | 4.2.7 |
| packagist | moodle/moodle | 4.3.0 | 4.3.4 |
Related vulnerabilities
- GHSA-ggxq-2mg9-8966 Moodle has a Remote Code Execution risk via file restore Also affects moodle/moodle
- GHSA-cg8j-5cr2-568q Moodle TeX formula editor is vulnerable to DoS through lack of execution time limits Also affects moodle/moodle
- CVE-2026-26047 A denial-of-service vulnerability was identified in Moodle’s TeX formula editor. Also affects moodle/moodle
- CVE-2026-26045 A flaw was identified in Moodle’s backup restore functionality where specially crafted… Also affects moodle/moodle
- GHSA-5cx4-w4fh-fr57 Moodle Affected by Improper Restriction of Excessive Authentication Attempts Also affects moodle/moodle
- GHSA-8jrv-wx83-w3xj Moodle Inserts Sensitive Information Into Sent Data Also affects moodle/moodle
- GHSA-hcm6-q6pc-xfhm Moodle has an authorization logic flaw Also affects moodle/moodle
- GHSA-qv78-6gpp-hm68 Moodle Open Redirect vulnerability Also affects moodle/moodle