Graphene / Graphene-SGX - a library OS for Linux multi-process applications, with Intel SGX support
graphene-direct
and graphene-sgx
instead of pal_loader
).graphene-manifest
).libos.check_invalid_pointers
to disable checks of invalid pointers on syscall invocations.sgx.preheat_enclave
to choose between fast startup and run-time performance.gettimeofday()
emulation on Linux-SGX.sgx.profile
is introduced.loader.pal_internal_mem_size
manifest option.rt_sigtimedwait
, msync
, madvise
, getrandom
, waitid
, sethostname
, setdomainname
and readlinkat
.info-image
command to GSC./proc/self/cmdline
.graphene-direct
and graphene-sgx
instead of pal_loader
).loader.exec
. Use loader.entrypoint
instead.loader.debug_type
. Use loader.log_level
instead.sgx.allow_file_creation
.msgget
and semget
families of syscalls).Starting from this release Graphene is available as .deb packages. To install them, follow the below commands:
sudo apt-key adv --fetch-keys https://packages.grapheneproject.io/graphene.asc
echo 'deb [arch=amd64 signed-by=EA3C2D624681AC968521587A5EE1171912234070] https://packages.grapheneproject.io/ unstable main' | sudo tee /etc/apt/sources.list.d/graphene-unstable.list
sudo apt update
sudo apt install graphene-inkernel # for 5.11+ driver
sudo apt install graphene-oot # for out-of-tree SDK driver
sudo apt install graphene-dcap # for out-of-tree DCAP driver
We plan to also support .rpm format in the future.
If you prefer to build the sources yourself, please follow the building instructions from our documentation.
Note that both EPID and ECDSA/DCAP implementations require the SGX PSW/DCAP software stack to be installed and running on the same platform as Graphene.
sgx.protected_files
allows to add protected files or whole directories.loader.argv_src_file
.loader.env_src_file
.sgx.rpc_thread_num
.gettimeofday()
system call by invoking RDTSC on systems supporting "Invariant TSC".memcpy()
in particular) with x86-64-specific assembly.sgx.zero_heap_on_demand
to choose between fast startup (without zeroing out the whole heap memory) and run-time performance (with zeroing out the heap).sgx.enable_stats
.TCS.FLAGS.DBGOPTIN
flag.sys.brk.size
renamed to sys.brk.max_size
.loader.argv_src_file
and loader.env_src_file
to read arguments and variables from trusted files or adding loader.insecure__use_cmdline_argv = 1
and loader.insecure__use_host_env = 1
to propagate values from the host.Rewrite and reorganization of application examples: Apache, Nginx, Lighttpd, Bash, OpenVino, TensorFlow, GCC, Python, R, CURL, NodeJS, LMBench 2.5.
Initial clean up of the documentation migrated from the GitHub wiki.
Code improvements and refactoring:
pal_handle.file.{pass,append}
fieldsmain
function of pal_loader
load_enclave()
implementationsgx-tokens
targets in Makefiles. Deprecate make SGX_RUN=1
commandinitialize_enclave()
and create_enclave()
assert()
usage and introduce static_assert()
for compile-time assertion__builtin_expect
usagesBugfixes for PAL in general:
\
removal in read_config()
malloc()
instead of _DkVirtualMemoryAlloc()
SO_LINGER
on socket during socket_close()
PAL_HANDLE
usageDKSystemTimeQuery()
EAFNOSUPPORT
from platforms without IPv6 supportBugfixes for SGX:
ocall_sock_recv()
and ocall_sock_recv_fd()
pal-sgx-get-token
, pal-sgx-sign
, link-intel-driver.py
to python3pal-sgx-get-token
and pal-sgx-sign
pal-sgx-get-token
sgx.static_address
in pal-sgx-sign
free_pages()
load_trusted_file()
sgx.file_check_policy
MAX_DBG_THREADS
constant from 64 to 1024clone()
syscalls for creating enclave threadssgx.trusted_files
RFLAGS
upon enclave entryENOEXEC
if loading non-ELF file_DkHandleExternalEvent()
_DkExceptionHandler()
Bugfixes for Library OS:
proc_match_name()
handle_copy()
listen()
on the same socketset_new_fd_handle()
to 0tcb.test_range.has_fault
in test_user_memory()
clone()
put_thread()
futex_waiter
ENOENT
on open_namei(path = empty string)
shim_do_pipe2()
and shim_do_socketpair()
SIGABRT
, SIGTERM
, SIGINT
from hostseventfd()
%gs
register for LibOS TCB (shim_tcb
)SIGKILL
and SIGSTOP
in set_signal_mask()
GLIBC_DISABLE_VDSO
in Makefilesexecve()
__attribute__((packed))
to eliminate warnings on gcc-9CLONE_CHILD_CLEARTID
__kernel_sigaction
in get_new_thread()
getdents()
Miscellaneous bugfixes:
clean
targets in Makefilesstrcmp_static
(renamed to strpartcmp_static
)ARRAY_SIZE
and IS_POWER_OF_2
macro and refactor alignment macrossyscall
instruction occuring in the user application itself and adding VDSO support.Fix compatibility issue for Linux kernel later than 3.5 and Ubuntu 10.10. More portable PAL with organized platform-generic code. PAL regression test to confirm completeness of implementation. Plenty of bugfixes in both PAL and Graphene More supported applications