# AI Engine – MCP Server & AI Chatbot for WordPress, with Claude, ChatGPT & Gemini <= 3.9.3 - Unauthenticated Stored Cross-Site Scripting via File Upload

- **ID:** WPSEC-2026-3047
- **Plugin:** AI Engine – MCP Server & AI Chatbot for WordPress, with Claude, ChatGPT & Gemini (`ai-engine`), https://wordpress.org/plugins/ai-engine/
- **Affected versions:** all versions before 3.9.4
- **Fixed in:** 3.9.4 (Update to 3.9.4 or later.)
- **Severity:** Medium 6.1 (CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N)
- **Weakness:** CWE-79
- **Usage among sites WPSec scans:** plugin Low, affected versions Low (as of 2026-11-13)
- **Attack surface analysis:** https://attacksurface.wpsec.com/plugin/ai-engine
- **Fix released:** 2026-11-12
- **Published:** 2026-11-13
- **URL:** https://wpsec.com/vuln/WPSEC-2026-3047/

## Description

The AI Engine plugin for WordPress is vulnerable to Stored Cross-Site Scripting via file uploads (the chatbot and AI Forms upload endpoint /mwai-ui/v1/files/upload) in all versions up to, and including, 3.9.3, due to insufficient validation of uploaded file types and contents. The endpoint is open to visitors through a publicly exposed nonce and accepts any file type WordPress allows, including text-based types such as .rtx (text/richtext) that many web servers send without a Content-Type, so a file starting with HTML markup is rendered as a web page by browsers. This makes it possible for unauthenticated attackers to store files in the public uploads folder that run arbitrary web scripts when a user opens them.

## References

- https://wpsec.com/vuln/WPSEC-2026-3047/
- https://plugins.svn.wordpress.org/ai-engine/tags/3.9.4/
- https://wordpress.org/plugins/ai-engine/

Source: WPSec, https://wpsec.com/vuln/WPSEC-2026-3047/

License: CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/). Free to use, share and adapt, also commercially, if you credit WPSec and link to this advisory.
