CVE-2025-6740

6.1 MEDIUM

📋 TL;DR

The Contact Form 7 Database Addon plugin for WordPress has a stored cross-site scripting vulnerability that allows unauthenticated attackers to inject malicious scripts via the 'tmpD' parameter. These scripts execute when users view compromised pages, potentially affecting all WordPress sites using vulnerable plugin versions. This vulnerability exists due to insufficient input sanitization and output escaping.

💻 Affected Systems

Products:
  • Contact Form 7 Database Addon (CFDB7) WordPress plugin
Versions: All versions up to and including 1.3.1
Operating Systems: Any OS running WordPress
Default Config Vulnerable: ⚠️ Yes
Notes: All WordPress installations using the vulnerable plugin are affected regardless of configuration.

📦 What is this software?

⚠️ Risk & Real-World Impact

🔴

Worst Case

Attackers could steal session cookies, redirect users to malicious sites, deface websites, or perform actions on behalf of authenticated users, potentially leading to complete site compromise.

🟠

Likely Case

Attackers inject malicious scripts that steal user session cookies or redirect users to phishing sites, compromising user accounts and data.

🟢

If Mitigated

With proper web application firewalls and security headers, script execution could be blocked, limiting impact to failed injection attempts.

🌐 Internet-Facing: HIGH
🏢 Internal Only: MEDIUM

🎯 Exploit Status

Public PoC: ✅ No
Weaponized: LIKELY
Unauthenticated Exploit: ⚠️ Yes
Complexity: LOW

The vulnerability is simple to exploit as it requires no authentication and involves basic web parameter manipulation.

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: 1.3.2 or later

Vendor Advisory: https://wordpress.org/plugins/contact-form-cfdb7/#developers

Restart Required: No

Instructions:

1. Log into WordPress admin panel. 2. Navigate to Plugins → Installed Plugins. 3. Find 'Contact Form 7 Database Addon'. 4. Click 'Update Now' if available. 5. Alternatively, download version 1.3.2+ from WordPress repository and replace plugin files.

🔧 Temporary Workarounds

Temporary Plugin Deactivation

all

Disable the vulnerable plugin until patched

wp plugin deactivate contact-form-cfdb7

Web Application Firewall Rule

all

Block requests containing malicious tmpD parameter patterns

🧯 If You Can't Patch

  • Implement Content Security Policy headers to restrict script execution
  • Deploy web application firewall with XSS protection rules

🔍 How to Verify

Check if Vulnerable:

Check WordPress admin → Plugins → Installed Plugins for Contact Form 7 Database Addon version

Check Version:

wp plugin get contact-form-cfdb7 --field=version

Verify Fix Applied:

Verify plugin version is 1.3.2 or higher in WordPress admin panel

📡 Detection & Monitoring

Log Indicators:

  • Unusual POST requests to WordPress with tmpD parameter containing script tags
  • Multiple failed injection attempts in web server logs

Network Indicators:

  • HTTP requests with JavaScript payloads in tmpD parameter
  • Unusual traffic patterns to contact form submission endpoints

SIEM Query:

source="web_logs" AND (tmpD CONTAINS "<script>" OR tmpD CONTAINS "javascript:")

🔗 References

📤 Share & Export