cbcvebase.
CVE-2024-8522
published 2024-09-12

CVE-2024-8522: The LearnPress – WordPress LMS Plugin plugin for WordPress is vulnerable to SQL Injection via the 'c_only_fields' parameter of the…

PriorityP184high7.5CVSS 3.1
AVNACLPRNUINSUCHINAN
ITWEXPLOITVulnCheck KEV
Exploited in the wild
EPSS
61.36%
99.1th percentile
The LearnPress – WordPress LMS Plugin plugin for WordPress is vulnerable to SQL Injection via the 'c_only_fields' parameter of the /wp-json/learnpress/v1/courses REST API endpoint in all versions up to, and including, 4.2.7 due to insufficient escaping on the user supplied parameter and lack of sufficient preparation on the existing SQL query. This makes it possible for unauthenticated attackers to append additional SQL queries into already existing queries that can be used to extract sensitive information from the database.

Affected

2 ranges
VendorProductVersion rangeFixed in
thimpresslearnpress< 4.2.7.14.2.7.1
thimpresslearnpress_wordpress_lms_plugin_for_create_and_sell_online_courses<= 4.2.7

Detection & IOCsextracted from sources · hover to see the quote

url/wp-json/learnpress/v1/courses
commandGET /wp-json/learnpress/v1/courses?c_only_fields=IF(COUNT(*)!=-2,(SLEEP(10)),0) HTTP/1.1
path/wp-json/learnpress/v1/
  • Monitor for unauthenticated GET requests to /wp-json/learnpress/v1/courses containing SQL keywords (e.g., SLEEP, IF, COUNT) in the 'c_only_fields' or 'c_fields' query parameters — indicative of blind time-based SQLi exploitation.
  • Alert on HTTP responses with anomalously high latency (>10 seconds) from /wp-json/learnpress/v1/courses, which may indicate successful time-based blind SQL injection via SLEEP() payloads.
  • The Metasploit module targets both CVE-2024-8522 (c_only_fields) and CVE-2024-8529 (c_fields); detection logic should cover both parameter names in REST API requests.
  • The exploit uses User-Agent 'curl/7.81.0' in the PoC HTTP request; consider flagging this UA in combination with requests to the LearnPress REST API endpoint.
  • ·The vulnerability affects all versions up to and including 4.2.7; exploitation requires no authentication, meaning no session or privilege context is needed to trigger the SQLi.
  • ·The injection is blind (time-based), not error-based; detection rules relying solely on SQL error messages in responses will miss this attack vector.

CVSS provenance

nvdv3.17.5HIGHCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N
vulncheck10.0CRITICAL
CVEs like this are exactly what “Exploited This Week” covers.

Every Monday: what got weaponized or added to CISA KEV in the last seven days — each CVE cross-linked to its PoC, Nuclei template, and detection rule. Free, one email a week, unsubscribe in one click.