Skip to main content

LMDeploy CVE-2025-66455

| EUVDEUVD-2025-210969 CRITICAL
Deserialization of Untrusted Data (CWE-502)
2026-09-18 https://github.com/InternLM/lmdeploy GHSA-2vh9-42vm-xmv2
9.8
CVSS 3.1 · Vendor: https://github.com/InternLM/lmdeploy
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Recon
    Reach DistServe API server (no auth)
  2. Delivery
    POST /distserve/p2p_connect with malicious zmq_address
  3. Exploit
    Engine connects PULL socket to attacker endpoint
  4. Install
    Attacker peer sends crafted pickle payload
  5. C2
    recv_pyobj() runs pickle.loads()
  6. Execute
    Arbitrary code executes as serving process
  7. Impact
    Exfiltrate model weights/prompts/credentials or terminate service

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A08:2025 - Software or Data Integrity Failures
ASVS 5.0
V1 - Encoding and Sanitization Safe deserialization, type allowlists
MITRE ATT&CK

2 techniques across 2 tactics: Execution, Initial Access

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Exploitation Conditions

Requires the LMDeploy PyTorch backend with PD-disaggregation/DistServe enabled and the /distserve/p2p_connect HTTP endpoint reachable by the attacker; ordinary LMDeploy deployments that do not use the disaggregated-serving path do not expose this data flow. Exploitation is unauthenticated (PR:N) only in the default state where the operator has NOT configured API-key authentication - enabling API keys, or restricting the DistServe HTTP/ZeroMQ control planes to trusted cluster networks and blocking arbitrary outbound ZeroMQ connections, closes or narrows the attack path. Affected versions are lmdeploy >= 0.9.2 and < 0.16.0; fixed in 0.16.0.

Impact

This is a genuine high-priority issue where every signal aligns rather than conflicts. The vendor-supplied CVSS 3.1 vector (AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H = 9.8) is fully consistent with the described data flow: an unauthenticated attacker reaches the POST /distserve/p2p_connect HTTP endpoint, supplies an attacker-controlled ZeroMQ address, and the server then pickle-deserializes attacker bytes via recv_pyobj(), yielding arbitrary code execution. CWE-502 (deserialization of untrusted data) is accurate. No EPSS score, KEV listing, or public POC is present in the input - so this is NOT confirmed to be exploited in the wild, and absence of EPSS/KEV should not be read as low risk here. Rather, the technical barrier is low: pickle-RCE is a well-understood, trivially weaponizable pattern, so real risk is high the moment a DistServe deployment is internet- or LAN-reachable without API keys. The single strong mitigating factor is deployment scope: exploitation requires the PyTorch backend with PD-disaggregation/DistServe explicitly enabled - ordinary LMDeploy serving does not expose this path. So the effective at-risk population is a subset of an already-specialized product. No signals conflict; the main caveat is that the 9.8 assumes the vulnerable DistServe path is enabled and API-key auth is off (the default).

Exploit ScenarioDerived

An attacker who can reach the DistServe API server sends a POST /distserve/p2p_connect request whose remote_engine_endpoint_info.zmq_address points at an attacker-controlled ZeroMQ endpoint. The LMDeploy engine connects its PULL socket and calls recv_pyobj(); the attacker's peer sends a crafted pickle object that executes arbitrary Python during deserialization, before any validation runs, giving code execution as the serving process. No public exploit is identified at time of analysis, but the pickle-deserialization pattern is trivially weaponizable and the default lack of API-key auth means no credentials are needed.

Act Now Prioritize within 24-48h. Why: CRITICAL severity.
Patch available 0.7% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Sep 18, 2026

Unauthenticated remote code execution in LMDeploy 0.9.2 through 0.15.x lets any attacker who can reach a DistServe/PD-disaggregation deployment's POST /distserve/p2p_connect endpoint run arbitrary code with the privileges of the LMDeploy serving process. The endpoint accepts an attacker-supplied ZeroMQ peer address; the engine connects to it and deserializes the reply with PyZMQ's recv_pyobj(), which is backed by Python pickle and therefore executes code during object reconstruction, before any type or schema check can run. Rated CVSS 3.1 9.8 (AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H, CWE-502); exploitation is unauthenticated only in the default configuration where the operator has not enabled API-key authentication, and no public exploit code has been identified at time of analysis. A vendor patch is available in LMDeploy 0.16.0, which replaces the pickle-based ZeroMQ protocol with JSON plus Pydantic validation.

RemediationAI

Upgrade to LMDeploy 0.16.0 or later, which is the vendor-released fix for this issue and replaces the pickle wire format with JSON plus DistServeCacheFreeRequest Pydantic schema validation (fix commit: https://github.com/InternLM/lmdeploy/commit/f05b4ad8bf2e2d84101a1d63b3c44fadd99223b2; release: https://github.com/InternLM/lmdeploy/releases/tag/v0.16.0; advisory: https://github.com/InternLM/lmdeploy/security/advisories/GHSA-2vh9-42vm-xmv2). If an immediate upgrade is not possible, apply compensating controls knowing they narrow rather than eliminate the pickle deserialization path: enable API-key authentication on the LMDeploy server so that /distserve/* requires credentials (this restores authentication but does nothing if a key holder is malicious and does not fix the unsafe deserialization itself); restrict the DistServe HTTP endpoint and the ZeroMQ control plane to a trusted cluster network via firewall or reverse-proxy rules so untrusted clients cannot reach /distserve/p2p_connect (this may break legitimate cross-node disaggregated serving if peer ranges are not scoped correctly); and block arbitrary outbound ZeroMQ/TCP connections from serving nodes with egress policy, which limits the attacker's ability to redirect the PULL socket to their own endpoint but can disrupt legitimate peer-to-peer communication between prefill and decode engines if the allowed peer set is not enumerated. Operators who do not need PD-disaggregation should disable DistServe entirely, which removes the affected endpoint and receiver from the running service. Vendor guidance notes that upgrading remains the recommended remedy because workarounds do not make pickle deserialization safe.

Affected VersionsENISA

LMDeploy 0.9.2, < 0.16.0

Affected Packages

pypi lmdeploy fix: 0.16.0

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in pypi

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

The flaw is CWE-502 (Deserialization of Untrusted Data) rooted in the PD-disaggregation (prefill/decode separation, branded DistServe) control plane of LMDeploy's PyTorch backend. In that architecture, separate prefill and decode engine instances communicate over ZeroMQ PUSH/PULL sockets to coordinate cache-freeing between peers. The vulnerable receiver, EngineP2PConnection.handle_zmq_recv() in lmdeploy/pytorch/disagg/conn/engine_conn.py, used PyZMQ's recv_pyobj(), which internally calls pickle.loads() on peer-supplied bytes; pickle's object reconstruction invokes arbitrary callables via __reduce__, so code executes inside the deserialization step itself, defeating any isinstance() or field check written afterwards. The peer address was neither hard-coded nor authenticated: it was taken from DistServeConnectionRequest.remote_engine_endpoint_info.zmq_address submitted to the HTTP route in lmdeploy/serve/openai/endpoints/distserve.py, so an attacker simply points the server's PULL socket at their own ZeroMQ endpoint and sends a crafted pickle. The upstream fix (commit f05b4ad8bf2e2d84101a1d63b3c44fadd99223b2) swaps send_pyobj()/recv_pyobj() for send_json()/recv_json(), validates incoming objects against the DistServeCacheFreeRequest Pydantic schema with model_validate(), and catches ValueError/ValidationError so malformed messages are logged and skipped rather than terminating the receive loop. Affected package is the pip distribution pkg:pip/lmdeploy; the vulnerable receiver was introduced in commit b0b705f7.

Know when Python 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

Vendor (https://github.com/InternLM/lmdeploy) PRIMARY 9.8 CRITICAL
AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
vuln.today AI 9.8 CRITICAL

Network-reachable endpoint, default no auth (PR:N/UI:N), low-complexity pickle RCE granting full code execution as the serving process (C:H/I:H/A:H); scope unchanged as impact stays within the process privileges.

3.1 AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
4.0 AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N

Primary rating from Vendor (https://github.com/InternLM/lmdeploy).

CVSS VectorVendor: https://github.com/InternLM/lmdeploy

Attack Vector
Network
Attack Complexity
Low
Privileges Required
None
User Interaction
None
Scope
Unchanged
Confidentiality
High
Integrity
High
Availability
High

DescriptionCVE.org

Summary

LMDeploy's PyTorch DistServe/PD-disaggregation control plane used recv_pyobj() to deserialize messages received through a ZeroMQ PULL socket. PyZMQ implements recv_pyobj() using Python pickle deserialization, which can execute arbitrary code while reconstructing an object.

The peer address used by the receiver was supplied through the POST /distserve/p2p_connect HTTP endpoint. An attacker who could reach an affected DistServe API server could cause the server to connect to an attacker-controlled ZeroMQ endpoint and deserialize a crafted pickle payload.

API-key authentication is not enabled unless the operator explicitly configures it. As a result, affected DistServe deployments without API keys allowed unauthenticated remote code execution with the privileges of the LMDeploy serving process.

This issue affects the PyTorch backend when PD-disaggregation/DistServe is enabled. Ordinary deployments that do not use the affected disaggregated-serving path do not expose this data flow.

Affected components

  • HTTP entry point:

lmdeploy/serve/openai/endpoints/distserve.py, POST /distserve/p2p_connect

  • Attacker-controlled peer address:

DistServeConnectionRequest.remote_engine_endpoint_info.zmq_address

  • Vulnerable receiver:

lmdeploy/pytorch/disagg/conn/engine_conn.py, EngineP2PConnection.handle_zmq_recv()

  • Unsafe operation: recv_pyobj(), which performs pickle deserialization

Vulnerable data flow

  1. A caller submits a DistServe P2P connection request containing a

ZeroMQ address.

  1. The LMDeploy engine connects its ZeroMQ PULL socket to that address.
  2. handle_zmq_recv() receives messages using recv_pyobj().
  3. A malicious peer sends a crafted pickle object.
  4. Python code executes during deserialization, before LMDeploy can

perform any type or field validation.

A type check performed after recv_pyobj() cannot mitigate this issue because pickle payload execution occurs during deserialization.

Impact

Successful exploitation allows arbitrary code execution as the LMDeploy serving process. This can expose model weights, prompts, credentials, attached storage, cluster-network services, and host or GPU resources. An attacker may also modify or terminate the serving process.

Affected versions

Affected versions:

  • lmdeploy >= 0.9.2, < 0.16.0

The vulnerable P2P receiver was introduced in commit b0b705f7.

Remediation

The issue was fixed by replacing the pickle-based ZeroMQ protocol with JSON serialization:

  • send_pyobj() was replaced with send_json().
  • recv_pyobj() was replaced with recv_json().
  • Received objects are validated using the

DistServeCacheFreeRequest Pydantic schema before use.

  • Invalid or off-schema messages are rejected without terminating the

receive loop.

Fix commit:

https://github.com/InternLM/lmdeploy/commit/f05b4ad8bf2e2d84101a1d63b3c44fadd99223b2

The fix was released in LMDeploy 0.16.0.

Workarounds

Users who cannot upgrade immediately should:

  • Prevent untrusted clients from reaching /distserve/* endpoints.
  • Restrict the DistServe HTTP and ZeroMQ control planes to trusted

cluster networks.

  • Configure API-key authentication.
  • Block arbitrary outbound ZeroMQ connections from serving nodes.

These measures reduce exposure but do not make pickle deserialization safe. Upgrading to LMDeploy 0.16.0 or later is recommended.

Technical POC Analysis

CWE-502: Deserialization of Untrusted Data.

Full technical POC analysis - root cause, step-by-step exploitation and patch breakdown - is part of the Pro and Business plans.

Executive ViewAI

Why It Matters

LMDeploy versions 0.9.2 through 0.15.x are vulnerable to unauthenticated remote code execution, allowing attackers to compromise the serving process and potentially access sensitive data or disrupt AI services. Organizations using these versions in production, especially those with exposed DistServe endpoints, face severe risk. This critical vulnerability requires immediate remediation to prevent potential operational and reputational damage.

Business Impact: Severe
Compensating Controls

Apply vendor patch.

Threat Intelligence Overview

EPSS Score
0.7%
Top 48% exploitable
Prevalence
Low
specialized LLM inference server, and only its optional DistServe/PD-disaggregation path is affected
Threat Intel
1
1 source
Data Quality
6 sources
Confidence: High
EUVD NVD CVE.org EPSS Vulnrichment GHSA GitHub

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.

SignalValue
Severity CRITICAL
CISA KEV No
Public POC No
EPSS 0.7%
Patch available Yes
Active threat No
Deciding rule
CRITICAL severity
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision
Out-of-Cycle
Exploitation
None
System Exposure· derived
Open
Automatable
Yes
Human Impact
Very High
Technical Impact
Total

Priority Score

50
Low Medium High Critical
KEV: 0
EPSS: +1
CVSS: +49
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

Insecure deserialization occurs when an application converts serialized data (a stream of bytes representing an object's state) back into a living object without proper validation.

Remote Code Execution represents the critical moment when an attacker successfully runs arbitrary code on a target system without physical access.

More in Python

View all
CVE-2025-24016 CRITICAL POC
9.9 Feb 10

Wazuh SIEM platform versions 4.4.0 through 4.9.0 contain an unsafe deserialization vulnerability in the DistributedAPI t

CVE-2025-27520 CRITICAL POC
9.8 Apr 04

BentoML version 1.4.2 and earlier contains an unauthenticated remote code execution vulnerability through insecure deser

CVE-2025-2945 CRITICAL POC
9.9 Apr 03

pgAdmin 4 contains critical remote code execution vulnerabilities in the Query Tool download and Cloud Deployment endpoi

CVE-2013-5093 MEDIUM POC
6.8 Sep 27

The renderLocalView function in render/views.py in graphite-web in Graphite 0.9.5 through 0.9.10 uses the pickle Python

CVE-2025-32375 CRITICAL POC
9.8 Apr 09

BentoML is a Python library for building online serving systems optimized for AI apps and model inference. Rated critica

CVE-2014-0224 HIGH POC
7.4 Jun 05

OpenSSL before 0.9.8za, 1.0.0 before 1.0.0m, and 1.0.1 before 1.0.1h does not properly restrict processing of ChangeCiph

CVE-2024-21644 HIGH POC
7.5 Jan 08

pyLoad download manager version prior to 0.5.0b3.dev77 exposes the Flask SECRET_KEY through an unauthenticated endpoint.

CVE-2026-33017 CRITICAL POC
9.3 Mar 17

Langflow (a visual LLM pipeline builder) contains a critical unauthenticated code execution vulnerability (CVE-2026-3301

CVE-2017-9462 HIGH POC
8.8 Jun 06

In Mercurial before 4.1.3, "hg serve --stdio" allows remote authenticated users to launch the Python debugger, and conse

CVE-2026-49869 CRITICAL POC
10.0 Jun 26

Unauthenticated remote code execution affects Kestra OSS (the open-source event-driven orchestration platform) prior to

CVE-2026-39987 CRITICAL POC
9.3 Apr 08

Unauthenticated remote code execution in Marimo ≤0.20.4 allows attackers to execute arbitrary system commands via the `/

CVE-2024-21645 MEDIUM POC
5.3 Jan 08

pyLoad is the free and open-source Download Manager written in pure Python. Rated medium severity (CVSS 5.3), this vulne

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy