Type Confusion in Wasmtime - CVE-2021-39219

 

Type Confusion in Wasmtime - CVE-2021-39219

Published: September 17, 2021 / Updated: April 23, 2026


Vulnerability identifier: #VU127032
CSH Severity: Low
CVSSv4.0: CVSS:4.0/AV:L/AC:L/AT:N/PR:L/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N/E:U/U:Clear
CVE-ID: CVE-2021-39219
CWE-ID: CWE-843
Exploitation vector: Local access
Exploit availability: No public exploit available
Vulnerable software:
Wasmtime
Software vendor:
Bytecode Alliance

Description

The vulnerability allows a local user to cause memory unsafety.

The vulnerability exists due to type confusion in Linker::func_* APIs when using a Linker created with one Engine to instantiate a module into a Store created with a different Engine. A local user can use mismatched Engine values across Linker and Store operations to cause memory unsafety.

Exploitation requires an embedding that uses at least two Engine instances and reuses a Linker across them.


Remediation

Install security update from vendor's website.

External links