CVE-2024-4434
📋 TL;DR
This vulnerability allows unauthenticated attackers to perform time-based SQL injection attacks on WordPress sites using the LearnPress plugin. Attackers can extract sensitive database information like user credentials, payment details, or other confidential data. All WordPress installations with LearnPress version 4.2.6.5 or earlier are affected.
💻 Affected Systems
- LearnPress - WordPress LMS Plugin
📦 What is this software?
Learnpress by Thimpress
⚠️ Risk & Real-World Impact
Worst Case
Complete database compromise leading to credential theft, financial data exposure, site takeover, and potential lateral movement to other systems.
Likely Case
Extraction of user data, admin credentials, and sensitive plugin information leading to site compromise.
If Mitigated
Limited information disclosure if database permissions are properly restricted and WAF rules block injection attempts.
🎯 Exploit Status
Time-based SQL injection requires no authentication and has public proof-of-concept available.
🛠️ Fix & Mitigation
✅ Official Fix
Patch Version: 4.2.6.6 or later
Vendor Advisory: https://wordpress.org/plugins/learnpress/#developers
Restart Required: No
Instructions:
1. Log into WordPress admin panel. 2. Navigate to Plugins → Installed Plugins. 3. Find LearnPress and click 'Update Now'. 4. Verify update to version 4.2.6.6 or higher.
🔧 Temporary Workarounds
WAF Rule Implementation
allDeploy web application firewall rules to block SQL injection attempts targeting the term_id parameter.
Plugin Deactivation
linuxTemporarily disable LearnPress plugin until patched version can be installed.
wp plugin deactivate learnpress
🧯 If You Can't Patch
- Implement strict WAF rules to block SQL injection patterns
- Restrict database user permissions to read-only where possible
🔍 How to Verify
Check if Vulnerable:
Check WordPress admin panel → Plugins → LearnPress version. If version is 4.2.6.5 or lower, system is vulnerable.
Check Version:
wp plugin get learnpress --field=version
Verify Fix Applied:
Confirm LearnPress version is 4.2.6.6 or higher in WordPress admin panel.
📡 Detection & Monitoring
Log Indicators:
- Unusual SQL queries containing term_id parameter
- Multiple failed SQL injection attempts
- Long response times from LearnPress endpoints
Network Indicators:
- HTTP requests with SQL injection payloads in term_id parameter
- Unusual database query patterns from web server
SIEM Query:
source="web_logs" AND (term_id CONTAINS "SLEEP" OR term_id CONTAINS "BENCHMARK" OR term_id CONTAINS "WAITFOR")
🔗 References
- https://inky-knuckle-2c2.notion.site/Unauthenticated-SQLI-in-Learnpress-plugin-Latest-Version-4-2-6-5-a86fe63bcc7b4c9988802688211817fd?pvs=25
- https://plugins.trac.wordpress.org/browser/learnpress/tags/4.2.6.5/inc/Databases/class-lp-course-db.php#L508
- https://plugins.trac.wordpress.org/changeset/3082204/
- https://www.wordfence.com/threat-intel/vulnerabilities/id/2d64e1c6-1e25-4438-974d-b7da0979cc40?source=cve
- https://inky-knuckle-2c2.notion.site/Unauthenticated-SQLI-in-Learnpress-plugin-Latest-Version-4-2-6-5-a86fe63bcc7b4c9988802688211817fd?pvs=25
- https://plugins.trac.wordpress.org/browser/learnpress/tags/4.2.6.5/inc/Databases/class-lp-course-db.php#L508
- https://plugins.trac.wordpress.org/changeset/3082204/
- https://www.wordfence.com/threat-intel/vulnerabilities/id/2d64e1c6-1e25-4438-974d-b7da0979cc40?source=cve