WASI
also: WebAssembly System Interface
WASI (WebAssembly System Interface) is a standardized API that allows WebAssembly programs to safely access system resources like files, network, and environment variables without a web browser.
WASI is a modular system interface designed for WebAssembly, enabling portable binary programs to run on any operating system with a WASI runtime. Unlike traditional WebAssembly which runs only in browsers with limited host access, WASI provides secure, sandboxed access to OS features.
WASI follows a capability-based security model where programs must be explicitly granted permissions to access resources. For example, a WASI program cannot read arbitrary files unless the runtime grants it access to specific directories via file descriptors.
On Linux, you can run WASI programs using runtimes like wasmtime or wasmer. This allows compiled WebAssembly binaries to function as portable system utilities across different architectures and operating systems.