occlum/demos/remote_attestation
Junxian Xiao e8e14350a5 Support access key in remote attestaion demo
1. add access key configuration and code
2. Upgrade libcurl to support https
3. Support debug compile mode

Signed-off-by: Junxian Xiao <junxian.xjx@antfin.com>
2020-06-05 14:52:31 +08:00
..
app Support access key in remote attestaion demo 2020-06-05 14:52:31 +08:00
conf Support access key in remote attestaion demo 2020-06-05 14:52:31 +08:00
lib Support access key in remote attestaion demo 2020-06-05 14:52:31 +08:00
.gitignore Add SGX remote attestaion demo 2019-12-13 11:56:21 +00:00
CMakeLists.txt Support access key in remote attestaion demo 2020-06-05 14:52:31 +08:00
download_and_build.sh Support access key in remote attestaion demo 2020-06-05 14:52:31 +08:00
README.md Support access key in remote attestaion demo 2020-06-05 14:52:31 +08:00
run_on_occlum.sh Support access key in remote attestaion demo 2020-06-05 14:52:31 +08:00

SGX Remote Attestation Demo

This project demonstrates how to do remote attestation on Occlum.

In a nutshell, Occlum provides SGX capabilities to user apps through ioctls on a special device (/dev/sgx). To hide the low-level details of ioctls from user apps, a user-friendly, remote attestation library is provided in this demo.

Prerequisites. This demo needs to access Intel Attestation Service (IAS). To do this, a developer needs to contact Intel to obtain a Service Provider ID (SPID) and the associated Access Key from here. After obtaining the SPID and Access Key, fill them in the config file conf/ra_config.json as shown below:

{
      "ias_url": "https://api.trustedservices.intel.com/sgx/dev/attestation/v4",
      "ias_access_key": "<YourAccessKey>",
      "enclave_spid": "<YourSPID>"
}

NOTE: The URL, SPID and Access Key above vary depending whether it is for development or production

Step 1. Build this demo

Build the code in debug mode with "--debug", otherwise it's in Relese mode by default.

./download_and_build.sh [--debug]

Step 2. Run this demo on Occlum

Build the occlum image and run the RA test application.

./run_on_occlum.sh