mirror of
https://github.com/clearlinux/graphene.git
synced 2026-08-23 15:37:33 +00:00
d53729b201
This is a major refactor of the way manifests are loaded and handled, which will be followed by a complete rework of the loader code (which will include e.g. centralized config). Changes/fixes: - Huge part of manifest handling was refactored and untangled. - Starting without a manifest is now disallowed. This was actually accidentally broken for some time and no one complained. It also makes little sense in practice and in Graphene's overall design, e.g. it conflicts with protected argv. - Now we only allow starting by giving the executable, not manifest (the magic resolution logic was removed). - Now manifests are sent over pipes between parent and children, instead of children finding and loading them on their own. This is a preparation for the upcoming centralized manifests change. - Previously manifests were parsed 2 times on Linux and 3 times on Linux-SGX (by untrusted PAL, trusted PAL and LibOS). This is now fixed. - The common `pal_main()` now requires that the backend-specific PAL loader loads the manifest before calling it. SGX code already has to do it (for proper initialization), so let's unify this interface for all PALs. - Fix for a PAL crash when manifest size was divisible by page size (sic!). NULL termination was missing, but most of the time the padding to page size saved Graphene from crashing.
759 B
759 B
Busybox
This directory contains the Makefile and the template manifest for the most recent version of Busybox (as of this writing, commit ac78f2ac96). This was tested on a machine with SGX v1 and Ubuntu 16.04.
The Makefile and the template manifest contain extensive comments and are made self-explanatory. Please review them to gain understanding in Graphene-SGX and requirements for applications running under Graphene-SGX.
Quick Start
# build Busybox and the final manifest
make SGX=1
# run Busybox shell in non-SGX Graphene
./pal_loader busybox sh
# run Busybox shell in Graphene-SGX
SGX=1 ./pal_loader busybox sh
# now a shell session should be running e.g. typing:
ls
# should run program `ls` which lists current working directory