=============================================
Moodle CMS version 2.5.0-1 is prone to Object Injection vulnerability passing not properly sanitized user-supplied input to the unserialize() PHP function.
Attacker could inject ad-hoc serialized object into the application scope, reusing internal PHP code snippets maliciously. In this application the attacker could delete files and perform a XSS attacks.
Affected file badges/external.php unserialize user input in line 35
$json = required_param('badge', PARAM_RAW);
…
$badge = new external_badge(unserialize($json));
Moodle CMS version 2.5.0 and 2.5.1. Fixed in 2.5.2.
Do not unserialize() user-supplied input, use standard data format as json instead. Moodle users must upgrade to 2.5.2.
The Common Vulnerabilities and Exposures project (cve.mitre.org) has assigned the name CVE-2013-5674 to the vulnerability
Emilio Pinna: emilio # pinn # gmail
https://tracker.moodle.org/browse/MDL-40924
http://disse.cting.org/2013/09/16/moodle-2_5_0_1-badges-external-object-injection/
29/Jul/2013: Vendor alerted with MDL-40924 ticket
02/Sep/2013: Released fix commit 2d3c0faef by Yuliya Bozhko
07/Sep/2013: Moodle release 2.5.2
15/Sep/2013: Public disclosure
The information contained within this advisory is supplied "as-is" with no warranties or guarantees of fitness of use or otherwise.