Description
The main function in tools/wasm2js.cpp in Binaryen 1.38.22 has a heap-based buffer overflow because Emscripten is misused, triggering an error in cashew::JSPrinter::printAst() in emscripten-optimizer/simple_ast.h. A crafted input can cause segmentation faults, leading to denial-of-service, as demonstrated by wasm2js.
Fixed in Linux distributions
Distributions backport fixes, so the version that fixes this vulnerability differs per release — upgrade to at least the version shown. From the distributions' security trackers and advisories.
Debian
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Debian 14 | binaryen | 66-1 | — |
| Debian 13 | binaryen | 66-1 | — |
| Debian 12 | binaryen | 66-1 | — |
Ubuntu
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Ubuntu 26.10 | binaryen | No fix yet | — |
| Ubuntu 26.04 LTS | binaryen | No fix yet | — |
| Ubuntu 25.10 | binaryen | No fix yet | — |
| Ubuntu 24.04 LTS | binaryen | No fix yet | — |
| Ubuntu 22.04 LTS | binaryen | No fix yet | — |
Show 1 more (older releases, extended support, other products)Fewer releases
| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Ubuntu 20.04 LTS | binaryen | No fix yet | — |