CVE-2024-3136·PHP vulnerability
The MasterStudy LMS plugin for WordPress is vulnerable to Local File Inclusion in all versions up to, and including, 3.3.3 via the 'template' parameter. This makes it possible for unauthenticated attackers to include and execute arbitrary files on the server, allowing the execution of any PHP code in those files. This can be used to bypass access controls, obtain sensitive data, or achieve code execution in cases where images and other “safe” file types can be uploaded and included.
- Severity
- critical
- Software
- PHP
- Fixed in
- 3.3.4
- Published
- 2024-04-09
Affected versions
Until: 3.3.4
Fixed in: 3.3.4
How to fix this CVE
The MasterStudy LMS WordPress plugin versions up to 3.3.3 contain a critical Local File Inclusion (LFI) vulnerability in the template parameter that allows unauthenticated attackers to execute arbitrary PHP code. Immediately upgrade the MasterStudy LMS plugin to version 3.3.4 or later through your WordPress plugin dashboard or by downloading directly from the plugin repository. If you cannot update immediately, disable the plugin and remove it from your WordPress installation until the patch is deployed.
sudo dnf update php php-fpmDefensia detects this vulnerability
What an exploitation attempt looks like
Sample log line indicative of exploitation attempts:
GET|POST request containing 'template=' parameter with path traversal patterns: (\.\.[\\/]|\.\.%2[fF]|%2e%2e[\\/]|%2e%2e%2[fF]|\x2e\x2e[/\\]) followed by file paths like wp-config.php, /etc/passwd, or php shell payloadsWAF mitigation (if patching is not yet possible)
Add this rule to your WAF to block exploitation attempts while you schedule the patch.
Create a WAF rule to block any requests to WordPress plugin endpoints containing the 'template' parameter with path traversal sequences. Specifically, deny requests matching: template=([^\w/-]|\.\.[\\/]|%2e%2e|encoded variants) or template=.*(../|..\\). Whitelist only legitimate template values used by the plugin.How to check if you are affected
- Step 1: SSH into your WordPress server and run `wp plugin list --field=name,version | grep masterstudy` to identify the installed MasterStudy LMS version
- Step 2: Check your WordPress admin dashboard under Plugins to confirm the exact version of MasterStudy LMS and verify if it is version 3.3.3 or earlier
- Step 3: Search your web server logs (typically /var/log/apache2/access.log or /var/log/nginx/access.log) for requests containing 'template=' parameters with path traversal sequences like '../' or encoded variations such as '..%2f'
- Step 4: After updating to version 3.3.4, confirm the fix by running `wp plugin list --field=name,version | grep masterstudy` and verify the version number has changed
FAQ
What is CVE-2024-3136?
CVE-2024-3136 is a critical Local File Inclusion vulnerability in the MasterStudy LMS WordPress plugin that allows unauthenticated attackers to include and execute arbitrary PHP files from the server by manipulating the template parameter. This can lead to unauthorized code execution, data theft, and complete server compromise.
Is CVE-2024-3136 being actively exploited?
As of the latest available information, CVE-2024-3136 is not listed on the CISA Known Exploited Vulnerabilities (KEV) catalog and no public exploit code has been released. However, the critical severity rating (CVSS 9.8) and ease of exploitation mean threats are likely to emerge rapidly.
What versions of the MasterStudy LMS plugin are affected by CVE-2024-3136?
All versions of the MasterStudy LMS plugin up to and including version 3.3.3 are vulnerable. Version 3.3.4 and later contain the security fix.
How do I check if my WordPress site is vulnerable to CVE-2024-3136?
Connect to your server via SSH and run `wp plugin list` to view installed plugins and their versions. Look for 'masterstudy-lms' and confirm if the version is 3.3.3 or earlier. You can also check the plugin details in the WordPress admin dashboard under Plugins > Installed Plugins.
Does Defensia detect CVE-2024-3136?
Yes — Defensia's CVE advisory scanner compares installed package versions against the NVD database. If the MasterStudy LMS plugin is installed on a monitored WordPress server, CVE-2024-3136 will appear in your dashboard with remediation steps.
Related PHP CVEs
References
- https://plugins.trac.wordpress.org/changeset/3064337/masterstudy-lms-learning-management-system/trunk/_core/lms/classes/helpers.php
- https://plugins.trac.wordpress.org/changeset/3064337/masterstudy-lms-learning-management-system/trunk/_core/lms/classes/templates.php
- https://www.wordfence.com/threat-intel/vulnerabilities/id/9a573740-cdfe-4b58-b33b-5e50bcbc4779?source=cve
- https://plugins.trac.wordpress.org/changeset/3064337/masterstudy-lms-learning-management-system/trunk/_core/lms/classes/helpers.php
- https://plugins.trac.wordpress.org/changeset/3064337/masterstudy-lms-learning-management-system/trunk/_core/lms/classes/templates.php
Track CVEs across your fleet automatically
Defensia scans your Linux servers and tells you exactly which ones are running vulnerable versions — including CVE-2024-3136. Free for 1 server.
Get started free