CVE-2026-31251: FunAudioLLM CosyVoice insecure deserialization in gRPC server

CVE-2026-31251 · Severity: high · CVSS 7.3 · Published 2026-05-11

CosyVoice, a large-scale voice generation and speech synthesis model, is vulnerable to a security flaw that allows for the execution of unauthorized commands. This occurs when the system loads a specially crafted AI model file from a directory specified by the user. If an attacker provides a malicious model file and a user attempts to start the voice server using that directory, the attacker can take full control of the victim's computer.

Technologies: FunAudioLLM CosyVoice. Vendors: FunAudioLLM.

Quick answers

Is CVE-2026-31251 exploited in the wild?
No. Junglewise Threat Intelligence has no report of CVE-2026-31251 being exploited in the wild.
How severe is CVE-2026-31251?
High severity, with a CVSS score of 7.3, published 11 May 2026.
Which products and versions are affected?
FunAudioLLM CosyVoice thru commit 6e01309e01bc93bbeb83bdd996b1182a81aaf11e, up to commit 6e01309e01bc93bbeb83bdd996b1182a81aaf11e.
Is there a fix for CVE-2026-31251?
No fixed version is recorded yet. Check the vendor's advisory in the references below. If you run it, Junglewise drafts a mitigation that fits your setup and applies it once you approve, with senior security engineers behind it.
How is CVE-2026-31251 attacked?
It is attacked with local access, in a software library.
Am I affected by CVE-2026-31251?
Check whether you run FunAudioLLM CosyVoice at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

Technical details

An insecure deserialization vulnerability (CWE-502) exists in the gRPC server component of CosyVoice. The root cause is the use of the `torch.load()` function without the `weights_only=True` parameter when loading speech synthesis models from a user-specified directory. Because `torch.load()` utilizes the Python `pickle` module by default, it can be coerced into deserializing arbitrary Python objects. An attacker can exploit this by placing a malicious model file in a directory that the victim then points the gRPC server to during initialization. Successful exploitation results in arbitrary code execution with the privileges of the user running the server.

Affected products

  • FunAudioLLM CosyVoice thru commit 6e01309e01bc93bbeb83bdd996b1182a81aaf11e

Timeline

  • 2026-05-11: advisory: NVD publication date

References

This page as Markdown. Free to reuse under CC BY 4.0 with a link back.