Put Your Memory in Order: Efficient Domain-based Memory Isolation for WASM Applications
Hanwen Lei, Ziqi Zhang, Shaokun Zhang, Peng Jiang, Zhineng Zhong, Ningyu He, Ding Li, Yao Guo, Xiangqun Chen
Abstract
Memory corruption vulnerabilities can have more serious consequences in WebAssembly than in native applications. Therefore, we present PKUWA, the first WebAssembly runtime with memory isolation. Our insight is to use MPK hardware for efficient memory protection in WebAssembly. However, MPK and WebAssembly have different memory models: MPK protects virtual memory pages, while WebAssembly uses linear memory that has no pages. Mapping MPK APIs to WebAssembly causes memory bloating and low running efficiency. To solve this, we propose Domain Isolated Linear Memory (DILM), which protects linear memory at function-level granularity. We implemented DILM into the official WebAssembly runtime to build PKUWA. Our evaluation shows that PKUWA can prevent memory corruption in real projects with a 1.77% average overhead and negligible memory cost.
Ask about this paper
Your agent reads all of it.
Lune indexed this paper to the last equation, along with the top-tier papers that cite it. Ask a question and the answer quotes them.
Cited by top-tier papers4
- Wemby's Web: Hunting for Memory Corruption in WebAssemblyOussama Draissi, Tobias Cloosters, David Klein, Michael Rodler et al.ISSTA 2025 · 1 citation
- Building Bridges: Safe Interactions with Foreign Languages through OmniglotLeon Schuermann, Jack Toubes, Tyler Potyondy, Pat Pannuto et al.OSDI 2025
- WAVEN: WebAssembly Memory Virtualization for EnclavesWeili Wang, Honghan Ji, Peixuan He, Yao Zhang et al.NDSS 2025
- Exploring and Exploiting the Resource Isolation Attack Surface of WebAssembly ContainersZhaofeng Yu, Dongyang Zhan, Lin Ye, Haining Yu et al.USENIX Security 2025
Builds on14
- Spectre Attacks: Exploiting Speculative ExecutionPaul Kocher, Jann Horn, Anders Fogh, Daniel Genkin et al.S&P 2019 · 2,435 citations
- Plundervolt: Software-based Fault Injection Attacks against Intel SGXKit Murdock, David F. Oswald, Flavio D. Garcia, Jo Van Bulck et al.S&P 2020 · 369 citations
- ERIM: Secure, Efficient In-process Isolation with Protection Keys (MPK)Anjo Vahldiek-Oberwagner, Eslam Elnikety, Nuno O. Duarte, Michael Sammler et al.USENIX Security 2019 · 247 citations
- ScatterCache: Thwarting Cache Attacks via Cache Set RandomizationMario Werner, Thomas Unterluggauer, Lukas Giner, Michael Schwarz et al.USENIX Security 2019 · 221 citations
- An Empirical Study of Real-World WebAssembly Binaries: Security, Languages, Use CasesAaron Hilbig, Daniel Lehmann, Michael PradelWWW 2021 · 114 citations
Related papers
- WaVe: a verifiably secure WebAssembly sandboxing runtimeEvan Johnson, Evan Laufer, Zijie Zhao, Dan Gohman et al.S&P 2023
- VDom: Fast and Unlimited Virtual Domains on Multiple ArchitecturesZiqi Yuan, Siyu Hong, Rui Chang, Yajin Zhou et al.ASPLOS 2023 · 19 citations
- Everything Old is New Again: Binary Security of WebAssemblyDaniel Lehmann, Johannes Kinder, Michael PradelUSENIX Security 2020
- Donky: Domain Keys - Efficient In-Process Isolation for RISC-V and x86David Schrammel, Samuel Weiser, Stefan Steinegger, Martin Schwarzl et al.USENIX Security 2020
- Bento: Fine-Grained Memory Isolation for COTS WebAssembly BinariesOussama Draissi, Lucas DaviWWW 2026
