CVE-2021-27131
JSON

5.4medium

Moodle vulnerable to stored Cross-site Scripting

Severity
5.4medium CVSS:3.1 by NVD
Exploit likelihood
0.69% (higher than 53% of CVEs; EPSS, by FIRST)
Published
Last changed
Assigned by
mitre
Also known as
GHSA-w2pm-fr62-jgv4BIT-MOODLE-2021-27131

Description

Moodle 3.10.1 is vulnerable to persistent/stored cross-site scripting (XSS) due to the improper input sanitization on the "Additional HTML Section" via "Header and Footer" parameter in /admin/settings.php. This vulnerability is leading an attacker to steal admin and all user account cookies by storing the malicious XSS payload in Header and Footer. NOTE: this is disputed by the vendor because the "Additional HTML Section" for "Header and Footer" can only be supplied by an administrator, who is intentionally allowed to enter unsanitized input (e.g., site-specific JavaScript).

Affected

Product or packageVersionsReported by
Unspecified productn/aCVE List
moodle/moodle (Packagist)up to 3.10.1GitHub Advisory Database
moodle moodle3.10.1NVD
moodle (Bitnami)from 3.10.1 before 3.10.2Bitnami Vulnerability Database

All scores

GitHub5.4medium CVSS:3.1CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:L/I:L/A:N
NVD5.4medium CVSS:3.1CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:L/I:L/A:N
Bitnami Vulnerability Databasemedium rating

Classification

What each source says

CVE List

Moodle 3.10.1 is vulnerable to persistent/stored cross-site scripting (XSS) due to the improper input sanitization on the "Additional HTML Section" via "Header and Footer" parameter in /admin/settings.php. This vulnerability is leading an attacker to steal admin and all user account cookies by storing the malicious XSS payload in Header and Footer. NOTE: this is disputed by the vendor because the "Additional HTML Section" for "Header and Footer" can only be supplied by an administrator, who is intentionally allowed to enter unsanitized input (e.g., site-specific JavaScript).

GitHub Advisory Database

Moodle 3.10.1 is vulnerable to persistent/stored cross-site scripting (XSS) due to the improper input sanitization on the "Additional HTML Section" via "Header and Footer" parameter in /admin/settings.php. This vulnerability may lead an attacker to steal admin and all user account cookies by storing the malicious XSS payload in Header and Footer.

References

Sources

SourceRecordLicence
CVE ListCVE-2021-27131 changed 2024-08-03CVE Terms of Use
GitHub Advisory DatabaseGHSA-w2pm-fr62-jgv4 changed 2024-02-16CC-BY-4.0
NVDCVE-2021-27131 changed 2026-06-17Public domain
Bitnami Vulnerability DatabaseBIT-MOODLE-2021-27131 changed 2026-09-08Apache-2.0