Skip to content

Interface

Nicholas Renner edited this page Jun 16, 2021 · 10 revisions

SafePOSIX - Rust Interface

One element of our security model is to contain our kernel calls to the "popular paths". To ensure this, SafePOSIX-Rust must only call to libraries (via the Rust standard libraries, and any crates) via paths that limit kernel calls to these popular paths.

The SafePOSIX-Rust interface exposes SafePOSIX to these libraries in four files:

  1. file.rs - filesystem related calls
  2. comm.rs - network related calls
  3. timer.rs - time related calls
  4. misc.rs - locks, serialization, etc.

These files make up our interface module, and are the only place libraries are imported via use. This allows us to fuzz this slimmer interface for kernel access to ensure the broader SafePOSIX code can only access the popular paths.

SafePOSIX is then built using this interface. No library imports via use are allowed in any of the files that implement SafePOSIX. Any attempts to import outside libraries will be rejected via code review.

Clone this wiki locally