Sandboxing with minimal effort
Inko adds a cross-platform sandbox API using Landlock, Seatbelt, pledge, and unveil.
Inko's author describes a standard-library sandbox API that lets an application restrict its own file and network access. Linux uses Landlock, macOS uses Seatbelt through sandbox_init, and OpenBSD uses pledge and unveil. FreeBSD Capsicum is intentionally a no-op because cap_enter prevents ordinary open calls and would require restructuring programs around openat. The static server shost is limited to reading its TLS and site directories and binding its TCP port. A Podman quadlet is shown as a separate container-level restriction.
- Inko's sandbox API wraps Landlock, Seatbelt, pledge, and unveil
- FreeBSD Capsicum support is a no-op because it requires redesign
- The shost example allows two read paths and one TCP bind
- Author argues ease of use decides whether sandboxing is adopted
From the original article
4 min read at yorickpeterse.cominteresting: the ability to sandbox an application with minimal effort. While memory safety is a goal of Inko (ignoring the usual escape hatches such as the FFI), memory safety only gets you so far. Most notably, the code is still
By yorickpeterse.com via fanf · yorickpeterse.com
A short excerpt; the article and its images belong to the publisher. Summary, key facts and assessment above are AI-written from the article and can be wrong.