# GHSA-HJ27-MPW9-FF4C: Panic in Caller::get\_module\_export when a host function isn't called from WebAssembly

- Database: GitHub
- Severity: CVSS 2.2 (Low)
- Published: 2026-11-16
- Modified: 2026-11-16

## Affected versions

- wasmtime (crates.io): fixed in 36.0.21
- wasmtime (crates.io): from 37.0.0, fixed in 48.0.9
- wasmtime (crates.io): from 49.0.0, fixed in 49.0.6
- wasmtime (crates.io): from 50.0.0, fixed in 50.0.2

## Description

### Summary

`Caller::get_module_export` panics when the host function that calls it was not invoked by WebAssembly, for example when the embedder calls a guest export that is a re-export of the host function. A WebAssembly module can use this to make an embedder whose host functions use `Caller::get_module_export` panic.

### Details

Host functions in Wasmtime can receive a `Caller` that refers to the instance that called it. When the host function is invoked directly by the embedder instead of from WebAssembly, `Caller` refers to an internal placeholder instance that has no module. The `Caller::get_module_export` API provided would panic when called instead of correctly returning `None` in this situation.

### Impact

This affects embedders that call `Caller::get_module_export` from a host function. If that function is called from the embedder, for example by a module which imports the function and reexports it back to the host, then the method will panic. This requires that the import matches the export's signature for most embeddings. This bug only affects core WebAssembly and does not affect components in Wasmtime.

## References

- https://github.com/bytecodealliance/wasmtime/security/advisories/GHSA-hj27-mpw9-ff4c

Page: https://cve.now/GHSA-HJ27-MPW9-FF4C

Wrong or missing data? Send feedback: POST https://cve.now/api/v1/feedback (see https://cve.now/agents#feedback).
