Miggo Logo

CVE-2011-4301:
Moodle Allows Modification of Constants

5

CVSS Score

Basic Information

EPSS Score
0.5058%
Published
5/13/2022
Updated
1/17/2024
KEV Status
No
Technology
TechnologyPHP

Technical Details

CVSS Vector
AV:N/AC:L/Au:N/C:N/I:P/A:N
Package NameEcosystemVulnerable VersionsFirst Patched Version
moodle/moodlecomposer< 1.9.141.9.14
moodle/moodlecomposer>= 2.0, < 2.0.52.0.5
moodle/moodlecomposer>= 2.1, < 2.1.22.1.2

Vulnerability Intelligence
Miggo AIMiggo AI

Miggo AIRoot Cause Analysis

The vulnerability stems from the MoodleQuickForm class not properly handling 'setConstant' operations. The patch adds a critical check for _constantValues in exportValues() and merges them into the form data. This indicates the original implementation lacked this merge step, allowing constant fields to be modified by clients. The function exportValues() is directly modified in the fix, confirming its role in the vulnerability. The CWE-471 (MAID) classification further supports this, as the flaw involved modifying assumed-immutable data via missing constant enforcement.

Vulnerable functions

Only Mi**o us*rs **n s** t*is s**tion

WAF Protection Rules

WAF Rule

T** `Moo*l*Qui*k*orm` *l*ss in t** *orms Li*r*ry in `li*/*ormsli*.p*p` in Moo*l* *.*.x ***or* *.*.**, *.*.x ***or* *.*.*, *n* *.*.x ***or* *.*.* *o*s not r**o*niz* *orms *PI `s*t*onst*nt` op*r*tions, w*i** *llows r*mot* *tt**k*rs to su*mit un*xp**t**

Reasoning

T** vuln*r**ility st*ms *rom t** `Moo*l*Qui*k*orm` *l*ss not prop*rly **n*lin* 's*t*onst*nt' op*r*tions. T** p*t** ***s * *riti**l ****k *or `_*onst*ntV*lu*s` in `*xportV*lu*s()` *n* m*r**s t**m into t** *orm **t*. T*is in*i**t*s t** ori*in*l impl*m*