Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

redis example doesn't work on sgx hardware #76

Open
matti opened this issue Apr 23, 2022 · 0 comments
Open

redis example doesn't work on sgx hardware #76

matti opened this issue Apr 23, 2022 · 0 comments

Comments

@matti
Copy link

matti commented Apr 23, 2022

root@usva-2:/home/usva/asylo-redis# docker run -it --rm \
>     --device=/dev/isgx \
>     -v ${PWD}:/opt/my-project \
>     -v /var/run/aesmd/aesm.socket:/var/run/aesmd/aesm.socket \
>     --tmpfs /root/.cache/bazel:exec \
>     -w /opt/my-project \
>     --network host \
>     gcr.io/asylo-framework/asylo:buildenv-v0.6.0
Unable to find image 'gcr.io/asylo-framework/asylo:buildenv-v0.6.0' locally
buildenv-v0.6.0: Pulling from asylo-framework/asylo
f15005b0235f: Pull complete
3e2b4e291830: Pull complete
8dd19680d64a: Pull complete
1e9a16500e01: Pull complete
888804c0efb8: Pull complete
1ab2738fb3ed: Pull complete
Digest: sha256:a49749fdb5da76314a3a4cd51ee81938a305d86cc3948f0155539c6eadced2b4
Status: Downloaded newer image for gcr.io/asylo-framework/asylo:buildenv-v0.6.0

root@usva-2:/opt/my-project# bazel build :asylo_redis_sgx_hw
Extracting Bazel installation...
Starting local Bazel server and connecting to it...
INFO: Analyzed target //:asylo_redis_sgx_hw (90 packages loaded, 5027 targets configured).
INFO: Found 1 target...
Target //:asylo_redis_sgx_hw up-to-date:
  bazel-bin/asylo_redis_sgx_hw
INFO: Elapsed time: 183.530s, Critical Path: 40.15s
INFO: 2177 processes: 2177 processwrapper-sandbox.
INFO: Build completed successfully, 2219 total actions

root@usva-2:/opt/my-project# ./bazel-bin/asylo_redis_sgx_hw
2022-04-23 20:44:48  FATAL  application_wrapper_driver.cc : 50 : Failed to run the whole-application wrapper: ::asylo::error::SgxErrorSpace::Cannot open SGX device: Failed to create an enclave
2022-04-23 20:44:48  FATAL  application_wrapper_driver.cc : 50 : Failed to run the whole-application wrapper: ::asylo::error::SgxErrorSpace::Cannot open SGX device: Failed to create an enclave
Aborted (core dumped)

machine is sgx enabled, testing with: https://raw.githubusercontent.com/ayeks/SGX-hardware/master/test-sgx.c

root@usva-2:~# wget https://raw.githubusercontent.com/ayeks/SGX-hardware/master/test-sgx.c
root@usva-2:~# gcc test-sgx.c
root@usva-2:~# ./a.out
eax: a0653 ebx: 100800 ecx: 7ffafbbf edx: bfebfbff
stepping 3
model 5
family 6
processor type 0
extended model 10
extended family 0
smx: 0

Extended feature bits (EAX=07H, ECX=0H)
eax: 0 ebx: 29c67af ecx: 40000000 edx: bc000400
sgx available: 1
sgx launch control: 1

CPUID Leaf 12H, Sub-Leaf 0 of Intel SGX Capabilities (EAX=12H,ECX=0)
eax: 1 ebx: 0 ecx: 0 edx: 241f
sgx 1 supported: 1
sgx 2 supported: 0
MaxEnclaveSize_Not64: 1f
MaxEnclaveSize_64: 24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant