Description
The vulnerability was found in Moodle, occurs due to input validation error when importing lesson questions. This insufficient path checks results in arbitrary file read risk. This vulnerability allows a remote attacker to perform directory traversal attacks. The capability to access this feature is only available to teachers, managers and admins by default.
Affected products
| Vendor | Product | Affected | Fixed |
|---|---|---|---|
| — | Moodle | Fixed in moodle 4.0.2, moodle 3.11.8, moodle 3.9.15 | — |
Fixed in Linux distributions
Distributions backport fixes, so the version that fixes this vulnerability differs per release — upgrade to at least the version shown. From the distributions' security trackers and advisories.
Ubuntu
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Ubuntu Pro 18.04 LTS | moodle | No fix yet | — |
| Ubuntu Pro 16.04 LTS | moodle | No fix yet | — |
Public exploits
Exploit or proof-of-concept code for this vulnerability is publicly available, which lowers the bar for attackers. Treat it as a reason to patch sooner.
GitHub 1 repository
-
Gr4y-r0se/CVE-2022-35650 ★ 1 · Apr 15, 2026
Exploit for CVE-2022-35650, a Moodle Arbitrary File Read.
Sources: PoC-in-GitHub, Metasploit Framework, Exploit-DB — updated daily. Only links are listed; no exploit code is hosted here.
Affected packages
| Ecosystem | Package | Affected | Fixed | Record |
|---|---|---|---|---|
| Packagist | moodle/moodle | >= 3.9, < 3.9.15 | 3.9.15 | GHSA-pgm5-cr62-prxq |
| Packagist | moodle/moodle | >= 3.11, < 3.11.8 | 3.11.8 | GHSA-pgm5-cr62-prxq |
| Packagist | moodle/moodle | >= 4.0, < 4.0.2 | 4.0.2 | GHSA-pgm5-cr62-prxq |