code wiki / (root) / nx_container_rootless_test.nx

nx_container_rootless_test.nx

buildroot/runtime/nx_container_rootless_test.nx

2076 B50 linesdepth 4pulls 4 transitivereach 0 importersview sourcekind gate/prooftopic container
docsdependenciesstructsconstsfunctions

about

nx_container_rootless_test.nx -- proof that nx_container runs a process in a FULLY ROOTLESS container: CLONE_NEWUSER + uid/gid map (host id -> 0 inside) THEN unshare(mount|pid|uts|ipc), NO sudo, NO CAP_SYS_ADMIN. This is the oracle-container lane (bench/racing_crew/vendor/ORACLES.md v2): the racing suites run in sovereign nx_container jails that spin up/down as any user. The entrypoint (nx_exit42) returns 42; a rootless container that captures 42 proves the whole unprivileged namespace stack + the sovereign fork/exec/wait path (clone/execve/wait4 rv64-number fix). expect_exit: 0. license_tier: ORIGINAL No hw writes (Rule 26).

dependencies 2 imports · 0 importers

nx_syscalls_x86_64.nx nx_container.nx nx_container_rootless_test.nx

imports: nx_syscalls_x86_64.nxnx_container.nx

imported by: nobody (leaf or entry point)

call flow from main pre-order; caps 40 nodes / depth 6 declared; ↻ = already shown

main nx_container_run sys_fork _child_setup_and_exec sys_unshare sys_chroot _path_proc_abs _str_proc _str_none sys_mount sys_execve sys_wait4

structs

none

consts

13const CLONE_NEWNS: i64 = 0x00020000
14const CLONE_NEWUTS: i64 = 0x04000000
15const CLONE_NEWIPC: i64 = 0x08000000

functions

17func main() -> i64