CVE-2024-6847

9.8 CRITICAL

📋 TL;DR

This SQL injection vulnerability in the Chatbot with ChatGPT WordPress plugin allows unauthenticated attackers to execute arbitrary SQL commands by submitting specially crafted messages to the chatbot. All WordPress sites running vulnerable versions of this plugin are affected, potentially leading to complete database compromise.

💻 Affected Systems

Products:
  • Chatbot with ChatGPT WordPress plugin
Versions: All versions before 2.4.5
Operating Systems: Any OS running WordPress
Default Config Vulnerable: ⚠️ Yes
Notes: Only affects WordPress installations with the vulnerable plugin enabled. The chatbot functionality must be accessible to users.

📦 What is this software?

⚠️ Risk & Real-World Impact

🔴

Worst Case

Complete database compromise including data theft, data manipulation, privilege escalation to administrator, and potential remote code execution via database functions.

🟠

Likely Case

Attackers extract sensitive data (user credentials, personal information), modify content, or disrupt website functionality.

🟢

If Mitigated

With proper input validation and parameterized queries, the vulnerability would be prevented entirely.

🌐 Internet-Facing: HIGH - Exploitable by unauthenticated users from the internet via normal chatbot functionality.
🏢 Internal Only: LOW - The vulnerability is equally exploitable from internal networks but the primary risk is internet-facing.

🎯 Exploit Status

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

SQL injection via unauthenticated POST requests to chatbot endpoints. Exploitation requires minimal technical skill.

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: 2.4.5

Vendor Advisory: https://wpscan.com/vulnerability/baa860bb-3b7d-438a-ad54-92bf8e21e851/

Restart Required: No

Instructions:

1. Log into WordPress admin panel. 2. Navigate to Plugins → Installed Plugins. 3. Find 'Chatbot with ChatGPT' and click 'Update Now'. 4. Verify version is 2.4.5 or later.

🔧 Temporary Workarounds

Disable vulnerable plugin

all

Temporarily disable the Chatbot with ChatGPT plugin until patched

wp plugin deactivate chatbot-with-chatgpt

Restrict chatbot access

linux

Use web application firewall or .htaccess to block access to chatbot endpoints

# Add to .htaccess:
<Files "chatbot-*">
Order Allow,Deny
Deny from all
</Files>

🧯 If You Can't Patch

  • Disable the Chatbot with ChatGPT plugin immediately
  • Implement strict WAF rules to block SQL injection patterns targeting chatbot endpoints

🔍 How to Verify

Check if Vulnerable:

Check WordPress admin → Plugins → Installed Plugins for Chatbot with ChatGPT version. If version is below 2.4.5, you are vulnerable.

Check Version:

wp plugin get chatbot-with-chatgpt --field=version

Verify Fix Applied:

After updating, verify plugin version shows 2.4.5 or higher in WordPress admin panel.

📡 Detection & Monitoring

Log Indicators:

  • Unusual SQL errors in WordPress debug logs
  • Multiple POST requests to /wp-admin/admin-ajax.php with 'action' parameter containing 'chatbot'
  • SQL syntax in chatbot message parameters

Network Indicators:

  • POST requests to chatbot endpoints containing SQL keywords (UNION, SELECT, INSERT, etc.)
  • Unusually large or malformed chatbot submissions

SIEM Query:

source="wordpress.log" AND ("SQL syntax" OR "chatbot" AND ("UNION" OR "SELECT" OR "INSERT"))

🔗 References

📤 Share & Export