# CVE-2021-32478: Moodle - XSS

> Live exploitation tracking for CVE-2021-32478 by the CrowdSec Live Exploit Tracker, built from real-world attack data crowdsourced from CrowdSec's global network.

Page: https://tracker.crowdsec.net/cves/CVE-2021-32478

## Key facts

- **Exploitation phase:** Limited Exploitation. The vulnerability is known but shows very limited attacker interest or exploitation activity.
- **CVSS score:** 6.1
- **Public exploit available:** Yes
- **Affected products:** Moodle
- **Weaknesses:** CWE-79 (Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')); CWE-601 (URL Redirection to Untrusted Site ('Open Redirect'))
- **Tags:** web_application

## Description

The redirect URI in the LTI authorization endpoint required extra sanitizing to prevent reflected XSS and open redirect risks. Moodle versions 3.10 to 3.10.3, 3.9 to 3.9.6, 3.8 to 3.8.8 and earlier unsupported versions are affected.

## CrowdSec analysis

[CVE-2021-32478](https://euvd.enisa.europa.eu/vulnerability/CVE-2021-32478) is a vulnerability in Moodle's LTI authorization endpoint that exposes users to reflected cross-site scripting (XSS) and open redirect attacks due to insufficient sanitization of the redirect URI. Attackers could exploit this flaw to execute malicious scripts or redirect users to malicious sites, potentially leading to credential theft or phishing.

CrowdSec has been tracking this vulnerability and its exploits since 29th of October 2025.

According to CrowdSec data, while opportunistic exploitation dominates, a portion of threat actors trying to exploit CVE-2021-32478 apply basic targeting methods such as port or service detection. This indicates emerging patterns of selective targeting.
In addition, according to the CrowdSec network, attack volume against CVE-2021-32478 has dipped slightly compared to the previous week. Although still commonly targeted, the decline suggests a cooling-off period. Long-term relevance remains, but attention is waning.

Attackers exploit the `/mod/lti/auth.php` endpoint by supplying a malicious `redirect_uri` parameter, enabling reflected XSS or open redirect attacks through crafted URLs.

## Timeline

- 2022-03-11: CVE Published. CVE-2021-32478 is published to NVD.
- 2025-10-29: Rule Released. CrowdSec releases a rule to detect CVE-2021-32478 exploitation attempts against the CrowdSec Network.
- 2025-11-05: CrowdSec First Seen. CrowdSec observes in-the-wild exploitation of CVE-2021-32478 for the first time.

## References

- https://github.com/projectdiscovery/nuclei-templates/blob/main/http/cves/2021/CVE-2021-32478.yaml

## Live exploitation data

The [Live Exploit Tracker page](https://tracker.crowdsec.net/cves/CVE-2021-32478) follows observed exploitation activity for CVE-2021-32478. [Request an API key](https://tracker.crowdsec.net/request-api-key) for full access to its exploitation timeline, attacking IP addresses and blocklists.
