Intel® Software Guard Extensions (Intel® SGX)
Discussion board focused on hardware-based isolation and memory encryption to provide extended code protection in solutions.

Returns SGX_ERROR_MODE_INCOMPATIBLE

k__balaganapathy
1,561 Views

Hi,

 I'm trying out this example https://github.com/intel/sgx-ra-sample. I tried to build the client in simulation mode using the configure option --enable-sgx-simulation. 

./configure --with-openssldir=/opt/openssl/1.1.0i --enable-sgx-simulation

But when i run the client, i get the output as:

sgx_create_enclave: trusted_enclave_signed.so: 0000200e

I looked into the doc and found out that the error 0x200e means SGX_ERROR_MODE_INCOMPATIBLE which is caused when the target enclave 32/64 bit mode or sim/hw mode is incompatible with the mode of current uRTS. 

Can anyone help me resolve this?

0 Kudos
1 Solution
JesusG_Intel
Moderator
1,487 Views

Hello Bala,


We found a bug in the sample and a temporary workaround that will get you past the simulation mode issue. This is not a permanent fix so you will have to revert the file to the original when you are not running in simulation mode.


Make the following changes in sgx_stub.c


line 176: replace "libsgx_uae_service.so" with "libsgx_uae_service_sim.so"

line 190: replace ""libsgx_urts.so" with ""libsgx_urts_sim.so"


Then you can run:

source /opt/intel/sgxsdk/environment

make clean

make

./run-client


View solution in original post

5 Replies
JesusG_Intel
Moderator
1,526 Views

Hello Bala, we are looking into your issue.


Keep in mind that running the sample in simulation mode will fail the attestation, as explained on the webpage: "Note that Remote Attestation will fail for clients running in simulation mode, as this mode has no hardware protection."


0 Kudos
k__balaganapathy
1,512 Views

Hi JesusG, I'm aware that Remote Attestation will fail for clients running in simulation mode.

I just wanted to know why its returning this error SGX_ERROR_MODE_INCOMPATIBLE.  I've attached the generated make file below. I guess its linking again the right sim libs (sgx_trts_sim, sgx_tservice_sim, sgx_urts_sim, sgx_uae_service_sim). 

 

 

0 Kudos
JesusG_Intel
Moderator
1,488 Views

Hello Bala,


We found a bug in the sample and a temporary workaround that will get you past the simulation mode issue. This is not a permanent fix so you will have to revert the file to the original when you are not running in simulation mode.


Make the following changes in sgx_stub.c


line 176: replace "libsgx_uae_service.so" with "libsgx_uae_service_sim.so"

line 190: replace ""libsgx_urts.so" with ""libsgx_urts_sim.so"


Then you can run:

source /opt/intel/sgxsdk/environment

make clean

make

./run-client


k__balaganapathy
1,478 Views
0 Kudos
JesusG_Intel
Moderator
1,472 Views

This thread has been marked as answered and Intel will no longer monitor this thread. If you want a response from Intel in a follow-up question, please open a new thread.


0 Kudos
Reply