CVE-2026-31232: CosyVoice - Remote Code Execution
- Cve: CVE-2026-31232
- Name: CosyVoice - Remote Code Execution
- Description: The CosyVoice project thru commit 6e01309e01bc93bbeb83bdd996b1182a81aaf11e (2025-30-21) contains an insecure deserialization vulnerability (CWE-502) in its model loading process. When loading model files (.pt) from a user-specified directory (via the --model_dir argument), the code uses torch.load() without the security-restrictive weights_only=True parameter. This allows the deserialization of arbitrary Python objects via the Pickle module. An attacker can exploit this by providing a maliciously crafted model directory containing .pt files with embedded pickle payloads. When a victim loads this directory using CosyVoice's web interface, the malicious payload is executed, leading to remote code execution on the victim's system.
- Impact: Attackers can execute arbitrary code remotely on victim's system, potentially leading to full system compromise.
- Remediation: Update to a version that uses torch.load() with weights_only=True or apply security patches to restrict deserialization.
- Vulnerability type: insecure_deserialization
- Vulnerability impact: remote_code_execution
- Requirement type: user_interaction
- Requirements: Victim must load a malicious model directory via the web interface
- Labels source: projectdiscovery
- Severity: high
- Cvss score: 8.8
- Cvss vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H
- Epss score: 0.00458
- Epss percentile: 0.40178
- Assignee: [email protected]
- Published at: 2026-05-12T18:16:51Z
- Age in days: 196
- Modified at: 2026-06-17T10:33:28Z
- References total: 2
- Advisory url: https://nvd.nist.gov/vuln/detail/CVE-2026-31232
- Nvd status: awaiting_analysis
- Checked, none or zero: patch available, known exploited entries, nuclei templates, public exploits total, public exploits capped, public exploits, products total, products, oss, projects total, projects, rejected by nvd
- Not known: hackerone
Cwe
| Id | Name |
|---|---|
| CWE-502 | Deserialization of Untrusted Data |
References
| Url | Source | Tags |
|---|---|---|
| https://github.com/FunAudioLLM/CosyVoice | nvd | |
| https://www.notion.so/CVE-2026-31232-35d1e1393188817f869cdcfce13402a8 | nvd |
Index
- Checked, none or zero: repositories, repositories high signal, packages
Exploitation
- Remote: yes
- Checked, none or zero: known exploited, known exploited by, exploitation seen, public exploit, public exploit count, initial access, authentication required
- Not known: known exploited since, vulncheck known exploited since, public exploit first date, nuclei template, initial access since, hackerone reports, exposed hosts