Skip to content

Back to the catalog

When AI infrastructure becomes the target: Securing gateways and control points | Microsoft Security Blog
microsoft.comarticle

When AI infrastructure becomes the target: Securing gateways and control points | Microsoft Security Blog

Microsoft documents three observed compromises of AI infrastructure: a LiteLLM gateway (CVE-2026-42271 chained with CVE-2026-48710), a RAGFlow deployment (SSRF probing then runtime hook stealing LLM credentials), and a Kestra workflow engine (CVE-2026-49869 auth bypass). Attackers harvested credentials from /proc/1/environ and Azure PostgreSQL, deployed XMRig miners, and persisted via authorized_keys, cron and chattr. The post provides Defender XDR KQL hunting queries, IOCs, and hardening guidance such as treating AI gateways as Tier-0 secret stores and enforcing deny-by-default egress.

TL;DR Microsoft details real attacks on LiteLLM, RAGFlow and Kestra for credential theft and cryptomining, with KQL hunting queries and mitigations.
Document

What it is

A Microsoft Security investigation into three intrusions against AI infrastructure "control points": a LiteLLM gateway, a RAGFlow deployment, and a Kestra workflow environment. The detailed case is the LiteLLM gateway, compromised via CVE-2026-42271 (authenticated command execution in LiteLLM's MCP stdio test endpoints) chained with CVE-2026-48710 (a Starlette host-header validation bypass) to reach unauthenticated RCE. The other two workloads are named but not detailed in the fetched text.

How it works

CVE-2026-42271 supplies command execution through the MCP stdio test path; CVE-2026-48710 weakens the authentication boundary in affected configurations, making that execution reachable without valid credentials. Execution originates in the gateway process itself, not an unrelated system process. In containerized deployments where the gateway runs as PID 1, /proc/1/environ exposes the gateway's environment block. The payload read that file, filtered for keywords (master, API key, token, password, and UI fields), and exfiltrated model-provider keys, the LiteLLM master key, DB connection strings, and UI credentials.

Two behaviors the summary understates: exfiltration and payload retrieval were both redundant. Exfil cycled through Python urllib, curl, and wget as fallbacks against egress controls. Payload delivery used two paths — an inline Python command that fetched a masqueraded ELF (service-style naming/args posing as a Linux daemon), and a shell-stage downloader using multiple download methods with short timeouts and randomized temp paths. Host discovery then ran a silent passwordless-sudo check, listening-port inspection, and process sweeps for competing miners and remote-access tools, before XMRig cryptomining deployment.

Preconditions / Affected

  • An exposed LiteLLM gateway running a version vulnerable to CVE-2026-42271, in a configuration where CVE-2026-48710 can bypass host-header validation.
  • Containerized gateway running as PID 1, so provider keys and the master key live in the process environment reachable via /proc/1/environ.
  • Applies by analogy to any AI control plane (RAGFlow, Kestra) that concentrates model keys, virtual keys, DB strings, tenant config, or execution privilege.

What to do

The page gives guidance rather than commands:

  • Inventory exposed AI management surfaces; restrict administrative access to gateways/orchestrators.
  • Monitor for gateway-originated process execution — the gateway process spawning shells, python -c, curl/wget, or ELF binaries is the key signal.
  • Alert on reads of /proc/1/environ and secret-access patterns from the gateway runtime.
  • Patch LiteLLM for CVE-2026-42271 and update Starlette for CVE-2026-48710 to break the unauthenticated-RCE chain.

Caveats

Microsoft assesses initial access "with high confidence" as likely through the exposed gateway surface and references the CVE chain via public research — it is attribution of the entry path, not confirmed exploitation of each specific CVE in every case. The fetched text also cuts off mid-Stage 4, so cryptomining/persistence details beyond XMRig staging are incomplete here.

Organisations named here

  • /proc/1/environ
  • RandomX
  • XMRig

CVEs named here

  • CVE-2026-42271
  • CVE-2026-48710
  • CVE-2026-45312
  • CVE-2026-28797
  • CVE-2026-24770
  • CVE-2025-68700
  • CVE-2025-69286
  • CVE-2026-49869

Technologies named here

  • LiteLLM gateway/proxy
  • Microsoft Defender for Endpoint on Linux
  • Starlette
  • Microsoft Defender for Cloud
  • RAGFlow
  • Kestra workflow orchestration
  • Microsoft Security Copilot in Microsoft Defender
  • Burp Collaborator / OASTify relay
  • Azure Database for PostgreSQL
  • Containerized Linux workloads
  • LiteLLM
  • Kestra
  • XMRig
  • Docker
  • Burp Collaborator / OASTify
  • MinerU parser
  • Canvas CodeExec
  • Microsoft Defender for Endpoint
  • Microsoft Defender XDR
  • Microsoft Security Copilot
  • psycopg2 / PostgreSQL client libraries
  • Azure
  • PostgreSQL

Techniques named here

  • Host discovery
  • Cryptomining preparation
  • Database credential use
  • SSRF-style probing with out-of-band callback preceding RCE
  • Possible AI-assisted payload development characteristics
  • Credential harvesting via /proc/1/environ
  • Masqueraded payload delivery and execution
  • Host and privilege discovery
  • Competing-miner removal and cryptomining preparation
  • Database credential abuse for data exfiltration
  • Persistence via SSH authorized_keys modification
  • SSRF probing
  • Runtime hook injection for credential interception
  • Workflow-based remote code execution
  • Docker socket abuse for container discovery
  • Curl-pipe-shell data collection
  • SSRF

Threat actors named here

  • XMRig / XMRig-like cryptominer
  • Masqueraded ELF payload imitating a Linux service process
  • Unattributed cryptomining/credential-theft actor
  • XMRig