Moodle uses predictable password-recovery tokens
Summary
CVE-2015-5267: Moodle uses predictable password-recovery tokens. Affects moodle/moodle across 3 version ranges.
< 2.7.10
>= 2.8.0, < 2.8.8
>= 2.9.0, < 2.9.2
Fixed in 2.7.10, 2.8.8 or 2.9.2, depending on the release line you run. How to fix ↓
Check if this vulnerability affects your application
Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.
No signup required · Results in about 60 seconds
lib/moodlelib.php in Moodle through 2.6.11, 2.7.x before 2.7.10, 2.8.x before 2.8.8, and 2.9.x before 2.9.2 relies on the PHP mt_rand function to implement the random_string and complex_random_string functions, which makes it easier for remote attackers to predict password-recovery tokens via a brute-force approach.
How To Fix
Fixed versions by release line
The minimum fixed version depends on the release line you run.
-
< 2.7.102.7.10composer require moodle/moodle:2.7.10 -
>= 2.8.0, < 2.8.82.8.8composer require moodle/moodle:2.8.8 -
>= 2.9.0, < 2.9.22.9.2composer require moodle/moodle:2.9.2
Tip — Not sure which release line you're on? Vulert can find the fix for the version you are using. Scan free →
References
Related vulnerabilities
Recent vulnerabilities recorded for moodle/moodle.