mirror of
https://github.com/clearlinux/graphene.git
synced 2026-04-28 19:23:39 +00:00
Change log (most important only):
- unify CPU context structures - now we have only one version -
`PAL_CONTEXT` - which is shared between LibOS and PALs and it should
depend only on the host architecture (not OS),
- syscalls emulation changed:
- dedicated LibOS stack is now used for syscalls emulation,
- removed one indirection level in syscalls table - now it stores
`shim_do_*` functions directly,
- signal handling - completely rewritten:
- all signal queues use proper locking schemes now,
- signals are handled *only* when returning to the user app from LibOS
or PAL,
- nested signals are now possible,
- the app is allowed to jump out of signal handler with the same
sematics as on normal Linux,
- signal altstack is now fully supported,
- syscall restarting is now supported,
- doing a backtrace from the signal handler works properly,
- disallow injecting host-level signals, with one exception, see
`sys.enable_sigterm_injection` manifest option for more details.
Running Node.js express server with Graphene SGX
This is a Node.js application, runs an express server, listening on a given port.
Environment
This application was tested with Node.js version 8.
Prerequisites
This project requires Node.js to be installed. See https://nodejs.org/ for more details on how to install Node.js.
Run npm install, which installs all dependencies and modules needed for this application. See
package.json for more details on Node.js dependencies needed for this project. At this point, the
application itself can be executed without Graphene by running node helloworld.js.
Steps to run without SGX
- Run
make. - Run
./pal_loader nodejs helloworld.js 3000. - The expected output should be the following:
Example app listening on port 3000!
Steps to run with SGX
- Run
make SGX=1in order to build the application using SGX. - Run
./pal_loader SGX nodejs helloworld.js 3000 - The expected output should be the following:
Example app listening on port 3000!