Exploit database

Vulnerability

CVE-2020-14321

Vulnerability details

Score
8.8
Severity
high

CVSS 3.1 · NVD

Vector string

CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H

Description

In Moodle before 3.9.1, 3.8.4, 3.7.7 and 3.5.13, teachers of a course were able to assign themselves the manager role within that course.

CVE Program

Showing saved CVE details. Refresh is temporarily unavailable.

Exploit source choices

6 sources
Moodle Teacher Enrollment Privilege Escalation to RCE
MSF-multi--http--moodle_teacher_enrollment_priv_esc_to_rceMetasploitPHP / remote

Moodle version 3.9, 3.8 to 3.8.3, 3.7 to 3.7.6, 3.5 to 3.5.12 and earlier unsupported versions allow for a teacher to exploit chain to RCE. A bug in the privileges system allows a teacher to add themselves as a manager to their own class. They can then add any other users, and thus look to add someone with manager privileges on the system (not just the class). After adding a system manager, a 'loginas' feature is used to access their account. Next the system is reconfigured to allow for all users to install an addon/plugin. Then a malicious theme is uploaded and creates an RCE. If all of that is a success, we revert permissions for managers to system default and remove our malicoius theme. Manual cleanup to remove students from the class is required. This module was tested against Moodle version 3.9

2020-07-20moodle_teacher_enrollment_priv_esc_to_rce.rb
hoangkien1020/cve-2020-14321
GH-0f1fc93b1fdefab1f74e225bdfe0aff2GitHubUnofficial GitHub source

Course enrolments allowed privilege escalation from teacher role into manager role to RCE

2020-07-262 files · 44 stars
lanzt/cve-2020-14321
GH-700c8c34e30cad3860f505d152d7d527GitHubUnofficial GitHub source

Python script to exploit CVE-2020-14321 - Moodle 3.9 - Course enrollments allowed privilege escalation from teacher role into manager role to RCE.

2021-04-282 files · 22 stars
3mrgnc3/moodle_3.9_rce_autopwn
GH-28477f6471c25a9de39d925863b33aa7GitHubUnofficial GitHub source

AutoPwn Script for Moodle 3.9 leveraging CVE-2020–20282, CVE-2020–14320,CVE-2020–14321

2021-05-313 files · 6 stars
f0ns1/cve-2020-14321-modified-exploit
GH-32c25c06362b683616493a26274b3e9eGitHubUnofficial GitHub source

Modified Moodle exploit for privilege escalation (Dorvack)

2022-02-014 files · 2 stars