VYPR
Moderate severityOSV Advisory· Published Feb 3, 2026· Updated Feb 3, 2026

Mooodle: mooodle: information disclosure and script execution via reflected cross-site scripting

CVE-2025-67855

Description

A flaw was found in mooodle. A remote attacker could exploit a reflected Cross-Site Scripting (XSS) vulnerability in the policy tool return URL. This vulnerability arises from insufficient sanitization of URL parameters, allowing attackers to inject malicious scripts through specially crafted links. Successful exploitation could lead to information disclosure or arbitrary client-side script execution within the user's browser.

AI Insight

LLM-synthesized narrative grounded in this CVE's description and references.

A reflected Cross-Site Scripting (XSS) in Moodle's policy tool return URL allows script injection via unsanitized URL parameters, leading to information disclosure or arbitrary execution.

The vulnerability is a reflected Cross-Site Scripting (XSS) flaw found in Moodle's policy tool return URL. The root cause is insufficient sanitization of URL parameters, specifically in the clean_param_value_localurl function. As shown in a recent commit [4], the check for javascript URIs was enhanced to block more variants, indicating that previous filtering could be bypassed. This aligns with the official description [1][2] which states that insufficient sanitization allows malicious script injection.

Exploitation occurs remotely by convincing a user to click a crafted link containing a malicious payload in the return URL parameter. The attacker does not require authentication to craft the link, making it a classic reflected XSS attack. When the victim clicks the link and interacts with the policy tool, the injected script executes in their browser context, as described in the security advisory [1][2].

Successful exploitation can lead to information disclosure or arbitrary client-side script execution. An attacker could potentially steal session cookies, perform actions on behalf of the victim, or deface pages within the Moodle instance. The impact is limited by the attacker's ability to craft a convincing phishing link, but the consequences could be severe if a user with administrative privileges falls for the attack [1][2].

A fix has been implemented in Moodle's development repository [4] and likely included in a subsequent release. Users are advised to update to the latest patched version. The open-source nature of Moodle [3] allows administrators to review the commit and apply it if an update is not immediately possible. Red Hat's advisory [1] also acknowledges the vulnerability.

AI Insight generated on May 19, 2026. Synthesized from this CVE's description and the cited reference URLs; citations are validated against the source bundle.

Affected packages

Versions sourced from the GitHub Security Advisory.

PackageAffected versionsPatched versions
moodle/moodlePackagist
< 4.1.224.1.22
moodle/moodlePackagist
>= 4.4.0-beta, < 4.4.124.4.12
moodle/moodlePackagist
>= 4.5.0-beta, < 4.5.84.5.8
moodle/moodlePackagist
>= 5.0.0-beta, < 5.0.45.0.4
moodle/moodlePackagist
>= 5.1.0-beta, < 5.1.15.1.1

Affected products

2
  • Moodle/MoodleOSV2 versions
    v1.0.0, v1.0.1, v1.0.2, …+ 1 more
    • (no CPE)range: v1.0.0, v1.0.1, v1.0.2, …
    • (no CPE)

Patches

1
0c146aa2612f

MDL-86544 lib: Adjust checks on local URL params

https://github.com/moodle/moodleDavid WoloszynOct 22, 2025via ghsa
1 file changed · +4 2
  • public/lib/classes/param.php+4 2 modified
    @@ -1067,8 +1067,10 @@ protected function clean_param_value_localurl(mixed $param): string {
                     // Absolute, and matches our wwwroot.
                 } else {
                     // Relative - let's make sure there are no tricks.
    -                if (validateUrlSyntax('/' . $param, 's-u-P-a-p-f+q?r?') &&
    -                        !preg_match('/javascript(?:.*\/{2,})?:/i', rawurldecode($param))) {
    +                if (
    +                    validateUrlSyntax('/' . $param, 's-u-P-a-p-f+q?r?') &&
    +                    !preg_match('/\bjavascript\b[\s\S]*?(?:\:|\/)/i', rawurldecode($param))
    +                ) {
                         // Valid relative local URL.
                     } else {
                         $param = '';
    

Vulnerability mechanics

Generated on May 9, 2026. Inputs: CWE entries + fix-commit diffs from this CVE's patches. Citations validated against bundle.

References

6

News mentions

0

No linked articles in our index yet.