appium-mcp
CVE-2026-58500
HIGH
Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
AccessAttacker crafts app with XSS in element attributes
-
DeliveryVictim runs generate_locators against the app
-
ExploitUnescaped attributes interpolated into MCP UI HTML
-
ExecutionClient renders resource, injected script executes
-
PersistpostMessage invokes arbitrary MCP tools
-
ImpactScreenshots/page source exfiltrated
Vulnerability Assessment
| Weakness |
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V1 - Encoding and Sanitization Output encoding, context-aware escaping
MITRE ATT&CK
2 techniques across 2 tactics: Initial Access, Execution The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up. |
| Exploitation Conditions | Requires that the attacker control the UI attributes of the app under test (the text, content-desc, resource-id, or locator selector values Appium reads from the live session) AND that a victim runs the generate_locators tool against that app and renders the resulting MCP UI resource in an MCP client that honors window.parent.postMessage tool calls. Exploitation is limited by required user interaction (UI:R - the victim must invoke the tool and render the resource), by the need for attacker influence over the target app's element metadata, and by the client actually processing postMessage-driven tool invocations; it does not work against apps whose UI the attacker cannot influence, and it is fully remediated in appium-mcp 1.85.10. |
| Impact | The supplied CVSS 3.1 vector (AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:H/A:N, base 8.2) reflects a scope-changing XSS: no privileges on the server, but the victim must render the malicious MCP UI resource (UI:R), and success pivots into MCP tool execution on the client (S:C). Real-world risk is gated by a meaningful precondition not captured by AV:N alone - the attacker must control the UI of the app under test and get the victim to run generate_locators against it, which is a targeted/supply-chain-style scenario rather than mass-exploitable internet exposure. No EPSS score, KEV listing, or SSVC decision data was provided, so exploitation probability cannot be quantified from the input; there is no evidence of active exploitation and no standalone POC beyond the vendor's regression tests. Net: a legitimately high-impact issue for anyone running appium-mcp against untrusted apps, but with a limited victim population and required user interaction it is a prioritize-if-you-use-it rather than an emergency-for-everyone flaw. |
| Exploit ScenarioDerived | An attacker publishes or supplies a mobile app whose element text/content-desc/resource-id contains an XSS payload such as an img onerror that calls window.parent.postMessage. A tester using an AI assistant runs the generate_locators tool against that app; the returned MCP UI resource is rendered in the victim's MCP client, the script executes, and it silently invokes registered MCP tools (e.g., capture screenshots or dump page source). No standalone POC is published, but the fix commit includes tests demonstrating the injection strings. |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – Jul 13, 2026
Cross-site scripting in appium-mcp (the Appium MCP server) versions <= 1.85.9 lets an attacker who controls the mobile app under test inject arbitrary HTML/JavaScript into the MCP UI resource returned by the generate_locators tool, because createLocatorGeneratorUI interpolates element attributes (text, content-desc, resource-id, selector, strategy) into an HTML template without escaping. When a victim's MCP client renders the resource, the injected script runs and can call arbitrary registered MCP tools via window.parent.postMessage (screenshots, page-source reads, etc.). No public exploit identified at time of analysis, though the fix commit ships XSS test cases; fixed in 1.85.10.
RemediationAI
Vendor-released patch: upgrade appium-mcp to 1.85.10 or later, which HTML-escapes tagName, text, contentDesc, resourceId, selector and strategy via a new escapeHtml() helper and replaces the inline onclick handler with data-strategy/data-selector attributes plus a delegated click listener (see commit e222bbbd6fe2b656a320efcd143563f08061a83d and advisory GHSA-x975-rgx4-5fh4). If you cannot upgrade immediately, only run generate_locators against trusted apps whose UI content you control, since the exploit requires attacker-controlled element attributes in the app under test; avoid pointing the server at untrusted or third-party apps. As an additional control, harden or sandbox the MCP client's rendering of UI resources and restrict which MCP tools can be invoked via window.parent.postMessage so that a rogue resource cannot trigger sensitive capabilities - noting this reduces functionality of legitimate interactive UI resources.
Affected Packages
Source: OSV (Open Source Vulnerabilities)
Affects your stack
Affects 1 package in npm
Checking this CVE against your own stacks and servers is part of the Basic plan and up.
Technical ContextAI · show details
appium-mcp is a Node/TypeScript MCP (Model Context Protocol) server that exposes Appium mobile-automation capabilities as tools to AI assistants. The root cause is CWE-79 (improper neutralization of input during web page generation): in src/ui/mcp-ui-utils.ts (~lines 720-740) the createLocatorGeneratorUI function builds an HTML template literal, embedding element.text, element.contentDesc, element.resourceId, selector and strategy directly, and additionally embeds selector/strategy into an inline onclick JavaScript string using only a backtick escape that is insufficient against HTML event-attribute or single-quote breakout. The data flows from an attacker-controlled Appium session: getPageSource(driver) (locators.ts:57) reads the app's page-source XML, which is parsed in source-parsing.ts with only newline normalization, then rendered without HTML-context escaping. The sibling function createPageSourceInspectorUI already escapes its output, confirming the gap is an oversight. MCP UI resources are HTML rendered in the client and can message the parent frame, so injected script can drive the MCP tool bus.
Know when Appium Mcp gets its next vulnerability
- Watch products and get an email when something new is published
- Check this CVE against your own stack and servers
- Exploit and PoC references, threat intelligence from 22 sources
No credit card · 7-day full trial
Severity by source
AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:H/A:N
Remote unauthenticated injection but victim must render the resource (UI:R); script crosses into the MCP client to run tools (S:C), yielding high integrity and low confidentiality impact.
Primary rating from Vendor (GitHub_M).
CVSS VectorVendor: GitHub_M
DescriptionCVE.org
MCP Appium is an MCP server that provides AI assistants with tools to automate mobile app testing on Android and iOS. In versions prior to 1.85.10, the createLocatorGeneratorUI function interpolates attacker-controlled element attributes - text, content-desc, resource-id, and locator selector values - directly into an HTML template literal without any HTML or JavaScript context escaping. An attacker who controls the UI of the app under test can inject arbitrary HTML and JavaScript into the MCP UI resource returned by the generate_locators tool. When a victim's MCP client renders this resource, the injected script executes and can invoke arbitrary MCP tools via window.parent.postMessage, leading to unauthorized MCP tool execution such as taking screenshots, reading page source, or any other registered capability. This issue has been fixed in version 1.85.10.
Executive ViewAI
Appium-mcp testing server (versions through 1.85.9) contains an XSS vulnerability allowing malicious mobile applications to commandeer the testing infrastructure and exfiltrate test data and application intelligence. QA and security teams face data theft and espionage risks when analyzing third-party or supply-chain-compromised applications.
Apply vendor patch.
Threat Intelligence Overview
How this decision was reached
The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.
What every action level means
SSVC AssessmentENISA
Priority Score
Attack Technique
Cross-Site Scripting occurs when an application accepts untrusted data and sends it to a web browser without proper validation or encoding.
NVD
CVE.org
EPSS
Vulnrichment
GitHub
VulDB
Exploit-DB