capos 0.1.0

Front-door SDK for the capOS capability operating system: typed Cap'n Proto capability clients over a transport seam. The default `ring` feature targets in-system applications running over the per-process capability ring; the reserved `remote` feature is for a future host-side transport.
Documentation
  • Coverage
  • 100%
    2 out of 2 items documented0 out of 0 items with examples
  • Size
  • Source code size: 12.11 kB This is the summed size of all the files inside the crates.io package for this release.
  • Documentation size: 157.74 MB This is the summed size of all files generated by rustdoc for all configured targets
  • Ø build duration
  • this release: 25s Average build duration of successful builds.
  • all releases: 25s Average build duration of successful builds in releases after 2024-10-23.
  • Links
  • Repository
  • crates.io
  • Dependencies
  • Versions
  • Owners
  • ei-grad

capos

Front-door SDK for capOS, a research capability operating system where every resource is a typed Cap'n Proto capability.

Depend on this single crate to write a capOS application against typed capability clients (Console, Timer, EntropySource, VirtualMemory, and the rest). The clients are written once and run over a Transport seam:

  • The default ring feature provides the in-system transport. An application running inside capOS reaches the kernel through its per-process capability ring (RingTransport), re-exporting the capos-rt runtime, the typed clients, and the entry_point! macro. no_std.
  • The reserved remote feature is for a future host-side transport that reaches a capOS instance over the remote session connection. It is not implemented yet (see docs/backlog/capos-sdk-dual-transport.md); enabling it without ring is a compile error.

Prefer this facade over reaching into capos-rt internals, so client code stays transport-agnostic as the remote backend lands.

use capos::prelude::*;

fn main(mut runtime: Runtime) -> i64 {
    let console: ConsoleClient = match runtime.capset().get_client(b"console") {
        Ok(console) => console,
        Err(_) => return 1,
    };
    let mut ring = match runtime.ring_client() {
        Ok(ring) => ring,
        Err(_) => return 2,
    };
    let _ = console.write_line_wait(&mut ring, "hello from capos", u64::MAX);
    0
}

capos::entry_point!(main);

Status

The remote transport is transitional and not yet shipped; the in-system ring transport carries current behavior. The crate is published from the capOS monorepo; the project's publication and versioning policy lives in docs/backlog/capos-sdk-dual-transport.md.

License

Licensed under either of

at your option.