8.8high
Fugue is Vulnerable to Remote Code Execution by Pickle Deserialization via FlaskRPCServer
- Severity
- 8.8high CVSS:3.1 by GitHub_M
- Exploit likelihood
- 0.78% (higher than 57% of CVEs; EPSS, by FIRST)
- Published
- Last changed
- Assigned by
- GitHub_M
- Also known as
- GHSA-xv5p-fjw5-vrj6PYSEC-2026-1399
Description
Fugue is a unified interface for distributed computing that lets users execute Python, Pandas, and SQL code on Spark, Dask, and Ray with minimal rewrites. In version 0.9.2 and prior, there is a remote code execution vulnerability by pickle deserialization via FlaskRPCServer. The Fugue framework implements an RPC server system for distributed computing operations. In the core functionality of the RPC server implementation, I found that the _decode() function in fugue/rpc/flask.py directly uses cloudpickle.loads() to deserialize data without any sanitization. This creates a remote code execution vulnerability when malicious pickle data is processed by the RPC server. The vulnerability exists in the RPC communication mechanism where the client can send arbitrary serialized Python objects that will be deserialized on the server side, allowing attackers to execute arbitrary code on the victim's machine. This issue has been patched via commit 6f25326.
Affected
| Product or package | Versions | Reported by |
|---|---|---|
| fugue-project fugue | <= 0.9.2, up to 0.9.1 | CVE List, NVD |
| fugue (PyPI) | up to 0.9.2 | GitHub Advisory Database, PyPA Advisory Database |
All scores
| GitHub_M | 8.8high CVSS:3.1 | CVSS:3.1/AV:A/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H |
| GitHub | 8.8high CVSS:3.1 | CVSS:3.1/AV:A/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H |
| PyPA Advisory Database | 8.8high CVSS:3.1 | CVSS:3.1/AV:A/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H |
Classification
What each source says
CVE List
Fugue is a unified interface for distributed computing that lets users execute Python, Pandas, and SQL code on Spark, Dask, and Ray with minimal rewrites. In version 0.9.2 and prior, there is a remote code execution vulnerability by pickle deserialization via FlaskRPCServer. The Fugue framework implements an RPC server system for distributed computing operations. In the core functionality of the RPC server implementation, I found that the _decode() function in fugue/rpc/flask.py directly uses cloudpickle.loads() to deserialize data without any sanitization. This creates a remote code execution vulnerability when malicious pickle data is processed by the RPC server. The vulnerability exists in the RPC communication mechanism where the client can send arbitrary serialized Python objects that will be deserialized on the server side, allowing attackers to execute arbitrary code on the victim's machine. This issue has been patched via commit 6f25326.
GitHub Advisory Database
Summary
The Fugue framework implements an RPC server system for distributed computing operations. In the core functionality of the RPC server implementation, I found that the _decode() function in fugue/rpc/flask.py directly uses cloudpickle.loads() to deserialize data without any sanitization. This creates a remote code execution vulnerability when malicious pickle data is processed by the RPC server.The vulnerability exists in the RPC communication mechanism where the client can send arbitrary serialized Python objects that will be deserialized on the server side, allowing attackers to execute arbitrary code on the victim's machine.
Details
_decode() function in fugue/rpc/flask.py directly uses cloudpickle.loads() to deserialize data without any sanitization.
PoC
-
Step1: The victim user starts an RPC server binding to open network using the Fugue framework. Here, I use the official RPC server code to initialize the server.
-
Step2: The attacker modifies the _encode() function in fugue/rpc/flask.py to inject malicious pickle data:
In this example, attacker modifies _encode to let the victim execute command “ls -l”
- Step 3: The attacker then uses the RPC client to send the malicious request
Fugue gives a demo video and the PoC in the attachment, along with modified flask.py. When users reproduce this issue, in the server side (as an victim), users can run python rpc_server.py. In the client side (as an attacker), users can first replace fugue/rpc/flask.py in pip site-packages with provided flask.py in the attachment and then run rpc_client.py.
Impact
Remote code execution in the victim's machine. Once the victim starts the RPCServer with network binding (especially 0.0.0.0), an attacker on the network can gain arbitrary code execution by connecting to the RPCServer and sending crafted pickle payloads. This vulnerability allows for:
- Complete system compromise
- Data exfiltration
- Lateral movement within the network
- Denial of service attacks
- Installation of persistent backdoors
Mitigation
-
Replace unsafe deserialization: Replace
pickle.loads()with safer alternatives such as:- JSON serialization for simple data structures
- Protocol Buffers or MessagePack for complex data
- If pickle must be used, implement a custom
Unpicklerwith a restrictedfind_class()method that only allows whitelisted classes
-
Network security:
- If the service is intended for internal use only, bind to localhost (
127.0.0.1) instead of0.0.0.0 - Implement authentication and authorization mechanisms
- If the service is intended for internal use only, bind to localhost (
-
Security warnings: When starting the service on public interfaces, display clear security warnings to inform users about the risks.
Attachment: https://drive.google.com/file/d/1y8bBBp7dnWoT_WHBtdB0Fts4NRUIfdWi/view?usp=sharing
NVD (es)
Fugue es una interfaz unificada para computación distribuida que permite a los usuarios ejecutar código Python, Pandas y SQL en Spark, Dask y Ray con mínimas reescrituras. En la versión 0.9.2 y anteriores, existe una vulnerabilidad de ejecución remota de código por deserialización de pickle a través de FlaskRPCServer. El framework de Fugue implementa un sistema de servidor RPC para operaciones de computación distribuida. En la funcionalidad central de la implementación del servidor RPC, encontré que la función _decode() en fugue/rpc/flask.py usa directamente cloudpickle.loads() para deserializar datos sin ninguna sanitización. Esto crea una vulnerabilidad de ejecución remota de código cuando datos pickle maliciosos son procesados por el servidor RPC. La vulnerabilidad existe en el mecanismo de comunicación RPC donde el cliente puede enviar objetos Python serializados arbitrarios que serán deserializados en el lado del servidor, permitiendo a los atacantes ejecutar código arbitrario en la máquina de la víctima. Este problema ha sido parcheado mediante el commit 6f25326.
References
Sources
| Source | Record | Licence |
|---|---|---|
| CVE List | CVE-2025-62703 changed 2025-11-26 | CVE Terms of Use |
| GitHub Advisory Database | GHSA-xv5p-fjw5-vrj6 changed 2026-07-07 | CC-BY-4.0 |
| NVD | CVE-2025-62703 changed 2026-10-19 | Public domain |
| PyPA Advisory Database | PYSEC-2026-1399 changed 2026-07-07 | CC-BY-4.0 |