ctipilot.ch

Microsoft Semantic Kernel Python SDK — prompt-injection-to-RCE via InMemoryVectorStore filter (CVSS 9.9, PoC public)

cve · CVE-2026-26030

Coverage timeline
3
first 2026-05-04 → last 2026-05-10
Peak priority
high
1 high · 2 notable
Sources cited
8
3 hosts
Sections touched
3
deep-dive, trending-vulnerabilities, weekly-vuln-rollup
Co-occurring entities
1
see Related entities below
ATT&CK techniques
7
pinned v19.1 · see below

ATT&CK techniques

7 techniques observed across 2 entries — derived from entry metadata and body evidence, never asserted without a published entry behind it · pinned to MITRE ATT&CK v19.1 · compare on the matrix · Navigator layer (JSON)

Initial Access TA0001

T1190Exploit Public-Facing Application×1

Adversaries may attempt to exploit a weakness in an Internet-facing host or system to initially access a network. The weakness in the system can be a software bug, a temporary glitch, or a misconfiguration.

Evidence: 2026-05-10/microsoft-semantic-kernel-cve-2026-26030-cve-2026-25592-prom · ATT&CK page ↗

Execution TA0002

T1059Command and Scripting Interpreter×2

Adversaries may abuse command and script interpreters to execute commands, scripts, or binaries. These interfaces and languages provide ways of interacting with computer systems and are a common feature across many different platforms. Most systems come with some built-in command-line interface and scripting capabilities, for example, macOS and Linux distributions include some flavor of Unix Shell while Windows installations include the Windows Command Shell and PowerShell.

Evidence: 2026-05-10/microsoft-semantic-kernel-cve-2026-26030-cve-2026-25592-prom · 2026-05-04/cve-2026-26030-cve-2026-25592-microsoft-semantic-kernel-pyth · ATT&CK page ↗

T1059.006Command and Scripting Interpreter: Python×2

Adversaries may abuse Python commands and scripts for execution. Python is a very popular scripting/programming language, with capabilities to perform many functions. Python can be executed interactively from the command-line (via the <code>python.exe</code> interpreter) or via scripts (.py) that can be written and distributed to different systems. Python code can also be compiled into binary executables.

Evidence: 2026-05-10/microsoft-semantic-kernel-cve-2026-26030-cve-2026-25592-prom · 2026-05-04/cve-2026-26030-cve-2026-25592-microsoft-semantic-kernel-pyth · ATT&CK page ↗

Privilege Escalation TA0004

T1611Escape to Host×2

Adversaries may break out of a container or virtualized environment to gain access to the underlying host. This can allow an adversary access to other containerized or virtualized resources from the host level or to the host itself. In principle, containerized / virtualized resources should provide a clear separation of application functionality and be isolated from the host environment.

Evidence: 2026-05-10/microsoft-semantic-kernel-cve-2026-26030-cve-2026-25592-prom · 2026-05-04/cve-2026-26030-cve-2026-25592-microsoft-semantic-kernel-pyth · ATT&CK page ↗

Collection TA0009

T1005Data from Local System×2

Adversaries may search local system sources, such as file systems, configuration files, local databases, virtual machine files, or process memory, to find files of interest and sensitive data prior to Exfiltration.

Evidence: 2026-05-10/microsoft-semantic-kernel-cve-2026-26030-cve-2026-25592-prom · 2026-05-04/cve-2026-26030-cve-2026-25592-microsoft-semantic-kernel-pyth · ATT&CK page ↗

Impact TA0040

T1565Data Manipulation×2

Adversaries may insert, delete, or manipulate data in order to influence external outcomes or hide activity, thus threatening the integrity of the data. By manipulating data, adversaries may attempt to affect a business process, organizational understanding, or decision making.

Evidence: 2026-05-10/microsoft-semantic-kernel-cve-2026-26030-cve-2026-25592-prom · 2026-05-04/cve-2026-26030-cve-2026-25592-microsoft-semantic-kernel-pyth · ATT&CK page ↗

T1565.001Data Manipulation: Stored Data Manipulation×2

Adversaries may insert, delete, or manipulate data at rest in order to influence external outcomes or hide activity, thus threatening the integrity of the data. By manipulating stored data, adversaries may attempt to affect a business process, organizational understanding, and decision making.

Evidence: 2026-05-10/microsoft-semantic-kernel-cve-2026-26030-cve-2026-25592-prom · 2026-05-04/cve-2026-26030-cve-2026-25592-microsoft-semantic-kernel-pyth · ATT&CK page ↗

Story timeline

  1. 2026-05-10Microsoft Semantic Kernel CVE-2026-26030 / CVE-2026-25592: Prompt-Injection-to-RCE in an AI Agent Orchestration Framework
    deep-dive
  2. 2026-05-10CVE-2026-26030 / CVE-2026-25592 — Microsoft Semantic Kernel: prompt-injection-to-RCE in the Python and .NET SDKs of Microsoft's AI agent orchestration framework (CVSS 9.9 each)
    trending-vulnerabilitiesCVE-2026-26030 / CVE-2026-25592 — Microsoft Semantic Kernel: prompt-injection-to-RCE in the Python and .NET SDKs of Microsoft's AI agent orchestration
  3. 2026-05-04CVE-2026-26030 + CVE-2026-25592 — Microsoft Semantic Kernel Python and .NET SDKs: a class-of-bug for agentic-AI frameworks
    weekly-vuln-rollup

Where this entity is cited

  • weekly-vuln-rollup1
  • trending-vulnerabilities1
  • deep-dive1

Source distribution

  • attack.mitre.org5 (62%)
  • github.com2 (25%)
  • microsoft.com1 (12%)

Co-occurring entities

Derived — referenced by the same focused operational entries (weekly summaries and report roundups don't count); ×N counts the shared entries.

Entries about Microsoft Semantic Kernel Python SDK — prompt-injection-to-RCE via InMemoryVectorStore filter (CVSS 9.9, PoC public) (3)

2026-05-10 · view entry permalink →

Microsoft Semantic Kernel CVE-2026-26030 / CVE-2026-25592: Prompt-Injection-to-RCE in an AI Agent Orchestration Framework

Primary CVEs: CVE-2026-26030 (Python SDK, CVSS 9.9; patched in 1.39.4) and CVE-2026-25592 (.NET SDK, CVSS 9.9; patched in 1.71.0; also assigned a Python patch in 1.39.3 per the GitHub advisory, superseded by 1.39.4) | Status: Patch available; public PoC for CVE-2026-26030; no in-the-wild exploitation reported | Primary advisory: Microsoft Security Blog, 2026-05-07 · GitHub GHSA-xjw9-4gw8-4rqx · GitHub GHSA-2ww3-72rp-wpp4


Why this matters for a Swiss/EU public-sector SOC

Semantic Kernel is the open-source orchestration SDK behind Azure AI Foundry, Copilot Studio, and a growing fraction of self-hosted enterprise AI agents in EU government modernisation pilots. Where prompt injection has previously been treated as a content problem (LLM produces wrong text), CVE-2026-26030 and CVE-2026-25592 promote it to a host problem: an attacker who can inject text the agent reads — via user input, RAG-retrieved documents, tool outputs, or email indexed by an automation — escapes the agent's logical boundary and runs code on the agent process's host. The deployment surface inside an EU public-sector tenant is exactly the place where an LLM-driven workflow has access to sensitive data sources (case-management systems, HR repositories, classified-by-policy documents). The two CVEs together demonstrate that agentic-AI tool authorisation is a security boundary, not a convenience abstraction.


CVE-2026-26030 — Python SDK: code injection via InMemoryVectorStore filter

Affected: Microsoft Semantic Kernel Python SDK < 1.39.4. Class: CWE-94 Improper Control of Generation of Code ('Code Injection'). CVSS: 9.9.

The Python SDK's InMemoryVectorStore filter function composes its LINQ-like filter expression by f-string interpolation of an LLM-controlled parameter rather than parameterising the value into the filter AST. The SDK applies a string-blocklist validator to reject obvious dangerous tokens (e.g. eval, exec, os.system), but the validator is a denylist on the literal text, not a sandboxed evaluation. The attacker bypasses it via the standard Python class-hierarchy traversal pattern:

"".__class__.__bases__[0].__subclasses__()[<index>]("...")

— walking object's subclass list to reach an arbitrary class that exposes a method capable of running shell commands (typically subprocess.Popen or a os reference reached via reflection). Once the validator is fooled, the f-string interpolation completes and Python evaluates the resulting expression in the agent process's context.

Exploitation prerequisites. The agent must (a) use the in-memory vector store backing for a Search Plugin or analogous component (default for self-hosted Semantic Kernel agents until a customer wires in a different vector backend), and (b) the attacker must have an injection vector into the prompt context. In practice, indirect prompt injection via retrieved documents or tool output is sufficient; a direct user-input vector is not required.

MITRE ATT&CK mapping: T1059.006 Command and Scripting Interpreter: Python (the resulting RCE primitive); T1190 Exploit Public-Facing Application where the agent ingests externally-sourced content.

Public PoC. Microsoft's research post references the public proof-of-concept in the amiteliahu/AIAgentCTF GitHub repository.


CVE-2026-25592 — .NET SDK: arbitrary file write via misapplied [KernelFunction] attribute on Sessions Python plugin

Affected: Microsoft Semantic Kernel .NET SDK < 1.71.0. Class: CWE-22 Path Traversal (effectively, an unintended sandbox-escape path). CVSS: 9.9.

The SessionsPythonPlugin integrates Azure Container Apps Python sessions as an agent-callable code-execution sandbox. Two of its methods — DownloadFileAsync and UploadFileAsync — were mistakenly annotated with [KernelFunction]. The decoration tells the kernel that the method is callable by the LLM as a tool. Combined, the LLM can therefore (a) call UploadFileAsync to write attacker-chosen bytes to an attacker-chosen path on the host running the agent process, escaping the Container Apps Python session entirely; and (b) call DownloadFileAsync symmetrically to read host-side files back into the agent context. The intended design exposed only sandboxed file operations against the Container Apps session filesystem; the attribute application broke containment.

The attack surface is any Semantic Kernel .NET agent that loads SessionsPythonPlugin. As with the Python flaw, the LLM can be steered into invoking these methods through indirect prompt injection — no explicit tool-call permission grant from the user is required at runtime if the agent has been configured to allow plugin invocation autonomously.

MITRE ATT&CK mapping: T1611 Escape to Host (sandbox escape from Container Apps Python session into the host); T1565.001 Stored Data Manipulation (write primitive); T1005 Data from Local System (read primitive).


Why this is a class, not just two CVEs

Both flaws stem from a shared design weakness: an agent framework that treats LLM-controlled values as input to executable abstractions without explicit validation at the boundary. The Python flaw uses string interpolation (the LLM's value is interpolated into code); the .NET flaw uses attribute application (LLM-callable surface is over-broad because of mis-tagged methods). Both bypass any of the existing prompt-side mitigations (output filtering, response classifiers, "let the LLM judge" patterns) because the dangerous operation occurs inside the SDK, not in the model's text.

Microsoft's research framing — "prompts become shells" — is the correct mental model for defenders: any place an agent framework converts an LLM-supplied value into a code-execution-adjacent operation (filter expression, tool dispatch, plugin parameter, file path, SQL, shell command) requires the same defensive treatment as a user-supplied parameter on a public-facing web endpoint. The same class of bug is highly likely to exist in LangChain, CrewAI, AutoGen, Haystack, LlamaIndex, and other agent frameworks; defenders should not assume Microsoft Semantic Kernel is uniquely affected.


Detection concepts

  • Process ancestry anomalies for AI agent frameworks. Sysmon EID 1 with parent-image filters covering python.exe / dotnet.exe invocations from python virtualenv paths or .NET app-host paths under typical Semantic Kernel deployment directories — alert when those processes spawn shells (bash, cmd.exe, powershell.exe), file utilities (mv, cp, tar), or network tools (curl, wget, ssh, nc).
  • EDR detections for unexpected shell-spawning by python / dotnet agent processes. EDR vendors classify this under hunt-pack categories such as "interpreter spawning shell" and "agent framework lateral move".
  • File-creation events outside the expected sandbox path. For .NET agents using SessionsPythonPlugin, alert on file creation by the agent process anywhere outside the Container Apps Python sessions mount; for Python agents, alert on file creation outside the configured agent working directory.
  • Agent-side telemetry: log and audit every tool / plugin invocation with parameters. Many self-hosted agent deployments do not log plugin-method calls because the LLM provider's API logs the prompt and response but not the agent-side dispatcher's tool-call traffic. Add structured logging at the dispatcher layer.

Hardening / mitigation

  • Patch first. Upgrade Python SDK to ≥ 1.39.4 and .NET SDK to ≥ 1.71.0. The patched releases also include the upstream test additions covering the bypass patterns.
  • If immediate upgrade is blocked, implement a Function Invocation Filter (the SDK-supported hook documented in the Microsoft research post) to allowlist the methods and parameters that may be called. This neutralises the unintended-[KernelFunction] exposure on the .NET side and reduces the Python-side blast radius even if the validator is bypassed.
  • Audit every [KernelFunction]-decorated method in your codebase for parameter types that are paths, file handles, raw strings later interpolated into code, SQL fragments, or URLs; remove the decorator from anything that does not need to be LLM-callable.
  • Treat LLM-supplied inputs to filter / templating / dispatch as untrusted at the SDK boundary — the same bar as request-body validation on a REST endpoint. Allowlist parameter types, validate paths against canonicalised roots, parameterise filter expressions instead of interpolating them.
  • Network segmentation around agent hosts. A Semantic Kernel agent host with read access to internal systems and outbound internet access is an obvious post-RCE pivot point; the agent process should run with the same network and credential constraints as any internet-exposed application server.
vulnerability10 May 05:00Zmulti-sourceOpen finding ↗

2026-05-10 · view entry permalink →

CVE-2026-26030 / CVE-2026-25592 — Microsoft Semantic Kernel: prompt-injection-to-RCE in the Python and .NET SDKs of Microsoft's AI agent orchestration framework (CVSS 9.9 each)

CVE-2026-26030 (CWE-94, CVSS 9.9) is a code-injection flaw in the Python SDK's InMemoryVectorStore filter function. An f-string composes the LINQ-like filter expression directly from an LLM-controlled parameter rather than parameterising it; the SDK applies a blocklist validator that an attacker bypasses with the well-known __class__.__bases__[0].__subclasses__() class-hierarchy traversal pattern, escaping the validator and yielding os.system-equivalent execution on the host running the agent. Affected versions: Python SDK < 1.39.4. CVE-2026-25592 (CWE-22, CVSS 9.9) is a class-design flaw in the .NET SDK: SessionsPythonPlugin.DownloadFileAsync and SessionsPythonPlugin.UploadFileAsync carry a [KernelFunction] attribute that should not have been applied — the LLM can therefore call those methods directly with attacker-chosen path arguments, yielding an arbitrary file-write primitive that breaks containment from the Azure Container Apps Python sessions sandbox into the host filesystem of the agent process. Affected versions: .NET SDK < 1.71.0. Both issues require only that an attacker can inject prompt content the agent consumes (user input, retrieved RAG documents, tool outputs) and that the agent is using a default-configured Search Plugin or Sessions Python plugin (Microsoft Security Blog, 2026-05-07 · GitHub Security Advisory GHSA-xjw9-4gw8-4rqx, 2026-05-07 · GitHub Security Advisory GHSA-2ww3-72rp-wpp4, 2026-05-07).

A working PoC for CVE-2026-26030 is public in the amiteliahu/AIAgentCTF GitHub repository per Microsoft's research post; no in-the-wild exploitation has been reported. Patches: Python SDK ≥ 1.39.4 and .NET SDK ≥ 1.71.0 — note that the GitHub Security Advisory for CVE-2026-25592 records 1.39.3 as its minimum patched Python version, and 1.39.4 (the patched version for CVE-2026-26030) supersedes 1.39.3 and closes both CVEs. Microsoft characterises both flaws as systemic of agentic-AI patterns that "trust LLM-controlled parameters without explicit validation" — readers should expect analogous flaws in LangChain, CrewAI, AutoGen and other agent frameworks. Full deep dive in § 5.

vulnerability10 May 05:00Zmulti-sourceOpen finding ↗

2026-05-04 · view entry permalink →

CVE-2026-26030 + CVE-2026-25592 — Microsoft Semantic Kernel Python and .NET SDKs: a class-of-bug for agentic-AI frameworks

The two Semantic Kernel CVEs are the highest-signal new CVE pair of the week even without confirmed in-the-wild exploitation: both flaws stem from a shared design weakness that an agent framework treats LLM-controlled values as input to executable abstractions without explicit validation at the boundary. The Python SDK flaw (CVE-2026-26030, CWE-94) interpolates an LLM-controlled parameter into the InMemoryVectorStore filter expression via f-string composition; a string-blocklist validator is bypassed by the canonical "".__class__.__bases__[0].__subclasses__() class-hierarchy traversal pattern, yielding subprocess.Popen-equivalent execution on the agent process's host. A public PoC exists in the amiteliahu/AIAgentCTF GitHub repository per Microsoft's research post. The .NET SDK flaw (CVE-2026-25592, CWE-22 effectively a sandbox-escape) ships a stray [KernelFunction] attribute on SessionsPythonPlugin.DownloadFileAsync and SessionsPythonPlugin.UploadFileAsync; the LLM can therefore invoke those methods with attacker-chosen path arguments, yielding an arbitrary file write that breaks containment from the Azure Container Apps Python sessions sandbox onto the agent process's host filesystem (Microsoft Security Blog, 2026-05-07 · GitHub GHSA-xjw9-4gw8-4rqx · GitHub GHSA-2ww3-72rp-wpp4 · daily 2026-05-10 deep dive).

Both flaws bypass prompt-side mitigations (output filtering, response classifiers, "let the LLM judge") because the dangerous operation occurs inside the SDK. The same class of bug is highly likely to exist in LangChain, CrewAI, AutoGen, Haystack, and LlamaIndex; defenders should not assume Semantic Kernel is uniquely affected. Patch path: Python SDK ≥ 1.39.4, .NET SDK ≥ 1.71.0; audit every [KernelFunction]-decorated method for parameter types that are paths, file handles, raw strings later interpolated into code, SQL fragments, or URLs, and remove the decorator from anything that does not need to be LLM-callable. ATT&CK: T1059.006 Python, T1611 Escape to Host, T1565.001, T1005 Data from Local System.

vulnerability04 May 05:00Zmulti-sourceOpen finding ↗