Remote code execution via calculated-formula validation bypass
Published Nov 7, 2024 · Updated Nov 7, 2024
Code injection in Moodle LMS calculated questions allows remote authenticated users with question-editing capability to execute PHP code. The qtype_calculated_find_formula_errors validator accepts crafted formula expressions that calculate() passes directly to PHP eval(). Question-creation or update capability is required, after which injected functions run with the Moodle server process's permissions.
Summary
What happened
Code injection in Moodle LMS calculated questions allows remote authenticated users with question-editing capability to execute PHP code. The qtype_calculated_find_formula_errors validator accepts crafted formula expressions that calculate() passes directly to PHP eval(). Question-creation or update capability is required, after which injected functions run with the Moodle server process's permissions.
The record
- CVE
- CVE-2024-43425
- Published
- Nov 7, 2024
- Updated
- Nov 7, 2024
- Vendor
- Moodle
- Product
- Moodle LMS
- Classifications
- CWE-94, T1190
- Attack vector
- network
- Privileges
- authenticated
Timeline
How it unfolded
- Nov 7, 2024CVE publishedPublication date reported by the CVE source.
- Nov 7, 2024Record updatedLatest update available in the CVE record.
Exploitability
Present is not the same as exploitable
Compare your product and version with the public record. A matching version still requires validation against your environment.
Is a vulnerable build present?
Compare these published version ranges with your installed build and any vendor patches.
- Affected versionversion=0 <4.1.12
- Affected versionversion=4.2 <4.2.9
- Affected versionversion=4.3 <4.3.6
- Affected versionversion=4.4 <4.4.2
What conditions does exploitation require?
What is affected?
Published CVSS scores
CVSS describes severity. EPSS estimates exploitation probability.
Attacks
What attackers are doing with it
Daily unique IPs observed by Shadowserver honeypots for known exploited vulnerabilities (KEVs). Missing observations do not establish an absence of attacks.
Weakness, pattern, technique
Public exploit references
- moodle-rce-calculatedquestions companion scriptsproof of concept · demonstrated
Labels summarize the accepted research assessment. They do not indicate a test against your environment.
Technologies
Your stack
See the directory against your own environment.
Your stack
Check the software in your environment
Book a demo to see how Hinoki identifies affected software and validates exploitability in your environment.
Book a demo