Skip to main content

Crate rvf_kernel

Crate rvf_kernel 

Source
Expand description

Real Linux microkernel builder for RVF computational containers.

This crate provides the tools to build, verify, and embed real Linux kernel images inside RVF files. It supports:

  • Prebuilt kernels: Load a bzImage/ELF from disk and embed it
  • Docker builds: Reproducible kernel compilation from source
  • Initramfs: Build valid cpio/newc archives with real /init scripts
  • Verification: SHA3-256 hash verification of extracted kernels

§Architecture

KernelBuilder
  ├── from_prebuilt(path)  → reads bzImage/ELF from disk
  ├── build_docker()       → builds kernel in Docker container
  ├── build_initramfs()    → creates gzipped cpio archive
  └── embed(store, kernel) → writes KERNEL_SEG to RVF file

KernelVerifier
  └── verify(header, image) → checks SHA3-256 hash

Modules§

config
Real Linux kernel configuration for microVM boot.
docker
Docker-based kernel build support.
error
Error types for the rvf-kernel crate.
initramfs
Real initramfs builder producing valid cpio archives (newc format).

Structs§

BuiltKernel
A built kernel ready to be embedded into an RVF store.
KernelBuilder
Builder for creating kernel images to embed in RVF files.
KernelConfig
Configuration for building or loading a kernel.
KernelVerifier
Verifier for kernel images extracted from RVF stores.
VerifiedKernel
A kernel that has passed hash verification.

Functions§

build_kernel_header
Build a KernelHeader for embedding into an RVF KERNEL_SEG.
sha3_256
Compute SHA3-256 hash of data.