/

CVE-2026-10036

Severity:

HIGH RISK

(8.8)

Unsafe YAML Deserialization (CWE-502) in SpeechBrain

CVE-2026-10036

Deferred

Vulnerability type

Category:

Unsafe Deserialization

CWE:

CWE-502

Impact:

Arbitrary Code Execution

Severity:

HIGH RISK

(8.8)

CVSS version:

3.1

Catch this CVE while code is being written

Detect vulnerable code directly in pull requests, so CVEs are fixed before merge.

Summary

SpeechBrain before 1.1.1 contains an unsafe YAML deserialization flaw in checkpoint metadata processing. An attacker who can place a crafted CKPT.yaml file in a configured checkpoint path may achieve arbitrary code execution during checkpoint candidate discovery, even when that checkpoint is not selected for recovery.

Affected context

The vulnerability occurs in SpeechBrain deployments that use Checkpointer.recover_if_possible() to discover available checkpoints and parse CKPT.yaml metadata with an unsafe PyYAML loader. The risk is present when an attacker can add or modify checkpoint metadata within a path that the application scans, and parsing occurs before the checkpoint is selected for recovery.

Exploit preconditions

  • Attack surface: Checkpoint discovery and metadata parsing
  • Required access: Ability to place or modify a CKPT.yaml file within the configured checkpoint path
  • Trigger point: Candidate enumeration performed by Checkpointer.recover_if_possible()
  • Why exploitation is possible: Unsafe deserialization may instantiate attacker-controlled Python objects while scanning metadata, regardless of whether the associated checkpoint is ultimately selected

Why this happens

The underlying bug is the use of a permissive YAML deserialization mechanism for checkpoint metadata that may not be fully trusted. Such loaders can interpret special YAML type information as instructions for constructing Python objects rather than treating the file as ordinary data. This behavior maps to CWE-502: Deserialization of Untrusted Data, because attacker-controlled serialized content can cause unintended code execution during parsing.

Potential impact

  • Attackers may execute arbitrary code with the privileges of the SpeechBrain process
  • The application environment could be compromised
  • Accessible credentials, datasets, or model artifacts may be exposed or altered
  • Checkpoint and machine-learning workflows could be manipulated
  • A compromised process could support lateral movement when network or filesystem permissions allow it

General mitigation guidance

Mitigation generally centers on removing executable behavior from checkpoint metadata parsing and reducing trust in checkpoint directories.

Common defensive patterns include:

  • Using safe, restricted YAML parsers that permit only expected scalar and collection types
  • Applying strict schemas and rejecting unknown metadata fields before use
  • Treating downloaded, shared, and generated checkpoints as untrusted inputs
  • Restricting write access to configured checkpoint paths
  • Separating checkpoint processing workloads and running them with least-privilege identities
  • Limiting filesystem, network, and credential access available to the SpeechBrain process
  • Using integrity verification and controlled artifact repositories for checkpoint files

How teams detect issues like this

Detection approaches may include:

  • Static analysis rules identifying permissive PyYAML loaders and generic deserialization calls
  • Code review checks for parsing checkpoint or model metadata before schema validation
  • Repository policies that prohibit executable YAML object tags in application-managed files
  • Monitoring for unexpected CKPT.yaml creation or modification in configured checkpoint directories
  • Runtime alerts for unusual child processes, filesystem changes, or outbound connections from SpeechBrain workers
  • Automated security review tools that flag unsafe deserialization patterns during development

Sources

SourceLink
github.comgithub.com/SaiTeja-Erukude/CVE-2026-10036-speechbrain-rce
github.comgithub.com/speechbrain/speechbrain/commit/22a616646a493871401461f80b2d5cf564cb2850
github.comgithub.com/speechbrain/speechbrain/pull/3067
github.comgithub.com/speechbrain/speechbrain/releases/tag/v1.1.1
vulncheck.comvulncheck.com/advisories/speechbrain-arbitrary-code-execution-via-ckpt-yaml-parsing

Frequently asked

questions

It is not inherently a direct network vulnerability. Exploitation may be possible remotely when an attacker can upload, replace, or otherwise influence checkpoint metadata through an exposed service, shared storage system, artifact repository, or similar workflow.

The attacker generally needs write access or another trusted delivery path for a CKPT.yaml file located under a checkpoint directory that SpeechBrain scans.

The safest pattern is to parse checkpoint metadata with a safe, restricted YAML loader and enforce a strict schema that permits data only, never executable object construction.

Treat model and checkpoint artifacts as untrusted, restrict artifact write permissions, verify provenance and integrity, run processing with least privilege, and continuously scan code for unsafe deserialization APIs.

Find out what's already
exploitable in your codebase.