WASI: the portable system interface for server-side WASM. Without WASI: a WASM module has zero OS access. WASI Preview 1: stable, POSIX-inspired, synchronous. Interfaces: fd_read, fd_write, path_open, random_get, clock_time_get. WASI Preview 2 (wasi 0.2): based on component model. Adds: wasi:filesystem (object-oriented), wasi:sockets (TCP/UDP), wasi:http (incoming/outgoing), wasi:cli. Capability model: host preopens specific directories, passes capability tokens. Module can only access preopened paths. Runtimes: Wasmtime (Bytecode Alliance), Wasmer, WasmEdge (CNCF), WAMR (embedded).
2 / 5
What problem does the WASM component model solve?
Component model: core WASM modules can only share linear memory and function pointers — unsafe between modules from different languages. Component model adds: WIT (WebAssembly Interface Types IDL): defines typed interfaces with types: string, list, record, variant, tuple, option, result, resource. Component: WASM module + WIT-defined imports/exports. Composition: link component A's export to component B's import, runtime handles canonical ABI translation. Canonical ABI: standard binary encoding for WIT types. Enables: Rust image processor + Go HTTP server + Python ML model — all composed as WASM components. Used by WASI 0.2, Wasmtime, Fastly Compute.
3 / 5
What does wasm-bindgen do?
wasm-bindgen: WASM ABI only supports i32/i64/f32/f64. To pass a string: allocate memory in WASM linear memory, write UTF-8 bytes, pass pointer+length. wasm-bindgen generates this boilerplate automatically. Rust side: #[wasm_bindgen] pub fn process(input: &str) -> String. Generated JS: handles encoding/decoding, memory allocation/deallocation. Generated TypeScript: export function process(input: string): string. wasm-pack workflow: compile Rust → wasm-bindgen → wasm-opt → npm package (.wasm + .js + .d.ts + package.json). C/C++ equivalent: Emscripten — more mature for C/C++ (SQLite, ffmpeg ported to WASM).
4 / 5
What is WAT (WebAssembly Text Format)?
WAT: one-to-one mapping with WASM binary (conceptually). S-expression syntax: (module (func $add (export "add") (param i32 i32) (result i32) local.get 0 local.get 1 i32.add)). WASM is a stack machine: instructions push/pop values from a virtual stack. local.get pushes a local variable value. i32.add pops two i32s, pushes their sum. Tools: wat2wasm (compile WAT to .wasm), wasm2wat (decompile .wasm to WAT for inspection). Types: i32, i64, f32, f64, v128 (SIMD), funcref, externref. WAT is essential for debugging: when a .wasm crashes, decompile and read the WAT to understand what went wrong.
5 / 5
What makes the WASM sandbox a strong security boundary for running untrusted code?
WASM security model: no syscalls — all OS access through host-provided imports. No ambient authority — the module cannot call any function not explicitly provided in the import object. Linear memory isolation — each instance has its own buffer; accessing beyond it is a trap. Verifier — statically ensures no exploitable memory operations before any code runs. Instance isolation: running 1,000 concurrent WASM instances, each is isolated from others. No shared memory by default. Compare to containers: containers isolate at process level (OS boundary); WASM isolates at instruction level (language boundary). Combining both gives defense in depth. Escape vulnerabilities: Spectre-style side channels can cross WASM boundaries. JIT engine bugs have allowed sandbox escapes. Strong, not perfect — but far stronger than eval() or native plugins.
What does the "WebAssembly Components" vocabulary exercise cover?
This exercise tests real IT vocabulary related to webassembly components through 5 multiple-choice questions, each built from realistic workplace sentences rather than abstract definitions.
Is this vocabulary exercise free to use?
Yes. Every exercise on CoderSlingo, including this one, is completely free — no account, sign-up, or payment required.
How many questions does this exercise have?
This exercise has 5 questions. Each one shows a real-world sentence or scenario with multiple-choice options and an explanation once you answer.
What happens after I answer a question?
You'll see immediate feedback showing whether your answer was correct, along with a short explanation of why — then a button to move to the next question, and a full results screen at the end.
Can I retry the exercise if I get questions wrong?
Yes. Once you reach the results screen, click "Try again" to reset your answers and go through the exercise from the start as many times as you like.
Do I need to create an account to take this exercise?
No account is needed. Your answers are scored in your browser during the session — nothing is saved to a server, so you can jump straight in.
Is my progress saved if I leave the page?
No — progress within an exercise resets if you navigate away or reload. Each exercise is short enough to complete in a few minutes in one sitting.
Are these vocabulary exercises connected to other topics?
Yes — this module shares real-world context with 11 other vocabulary modules. See "Related vocabulary" below to keep building a connected skill set.
How is this different from reading a glossary or blog article?
Exercises like this one are active recall drills — you have to choose the correct term or phrasing yourself, which builds retention faster than passively reading a definition.
Where can I find more vocabulary exercises?
Browse the full Vocabulary exercises hub for hundreds of modules covering Agile, DevOps, security, databases, architecture, and more — organised by IT role and skill.