Every claim needs a runnable example.
The source tree pins Emilua and its plugins with mise. The plugins compile those components from their official release tags. Native prerequisites—especially Boost, Qt, and the compiler—come from your system or an isolated native package environment.
Verified tool combination
| Component | Version | Role |
|---|---|---|
| Emilua | 0.12.2 | Runtime, actor, process, and I/O APIs |
| Boost | 1.92.0 | Current Boost.Asio and support libraries |
| Easybox | 0.1.5 | Privilege dropping for subprocess actors |
| Emilua Qt binding | 1.2.3 | Qt Quick and sandbox-safe image result transfer |
| Qt | 6.5.3 | QML UI and native image decoding |
Verification targets Linux on x86-64. The image helpers are unavailable on Windows. Do not infer support for another platform or architecture merely from this table.
Native prerequisites
Install a current C++ toolchain and the development packages required by Emilua and the selected plugins. The important requirements include:
- GCC 13 or a similarly current C++ compiler, Meson, Ninja, and
pkg-config. - Boost 1.92, LuaJIT, fmt, OpenSSL, Serd, Sord, cereal, libcap, and libpsx.
- Qt 6.5 or newer with Qml and Quick for the image example.
- Kafel for Easybox’s seccomp policy generation on Linux.
- GnuPG (
gpg) for the subprocess example.
Use current operating-system headers as well as current libraries. Older distribution sysroots may lack declarations for newer Linux mount APIs; that is a toolchain issue, not something the examples should patch around.
Install the pinned Emilua tools
Run these commands from the website source root. The included mise.toml declares the plugin repositories and versions.
mise install
mise exec -- emilua --version
The version output should identify Emilua 0.12.2 and Boost 1.92.0.
Run the demonstrations
mise run demo:pipe
mise run demo:network
mise run demo:gpg
mise run build:image
mise run demo:image
demo:image opens the Qt file dialog. The network example binds the first available loopback port in 8080–8090. The GPG example creates and removes a temporary GPG home.
Run every noninteractive check
mise run verify
This task runs the pipe, network, and GPG examples, builds the image decoder, and invokes its Meson tests. The tests decode assets/emilua.png in a separate process and reject a Lua source file presented as an image.
The image tests use Qt’s offscreen platform, so no desktop session is needed.
Source map
| Example | Trusted host | Sandboxed or child code |
|---|---|---|
| Image decoder | image_decoder/src/init.lua | decoder.lua |
| Network policy | network_policy/init.lua | plugin.lua |
| Pipe plugin | pipe_plugin/init.lua | plugin.lua |
| GPG subprocess | gpg_subprocess/init.lua | |
Shared source loading and EOF handling live in examples/common/init.lua. The image demo’s native build is defined in meson.build.
Security boundary
These programs demonstrate mechanisms and policy structure. They are not a security audit of Emilua, Easybox, Kafel, Qt, or the example policies. Review the exact sandbox rules and current upstream limitations before adapting them to production.