- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The Intel SGX SDK for Windows mentions that there is a simulation mode in page 65
"The simulation mode works in the same way as the debug mode except the fact that true hardware is not exercised, instead the Intel® SGX instructions are simulated in software."
But I cannot find any details in how to use this mode, only that in Project Settings section (p25,26), it mentions the dependencies are different. I used the simulation libraries instead of the original ones as it suggested and generated the example enclave and application ("hello world"). However, when I tried to run the application on my computer without SGX hardware, it says:
[sgx_create_enclavew ..\..\..\psw\urts\win\urts.cpp:83] Couldn't open file with
CreateFile()
App: error 0x200f, failed to create enclave.
And the error means
0x200F SGX_ERROR_ENCLAVE_FILE_ACCESS Can’t open enclave file
So what might be the problem? As I've already configure the projects to use the simulation libraries, it should run ok without SGX hardware.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Quizy,
I have checked your source code, you didn't change the "current working directory" pointing to $(OutDir) instead of $(ProjectDir) in simulation mode (Both Application and Enclave).
Please find the modified source code of yours from below link
https://drive.google.com/open?id=0B4N3YNdBPBe8RW03UVBCZnN2VUE ;
Thanks
Surenthar Selvaraj
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Quizy,
Did you run the application through command prompt or Local SGX Debugger?
If you are using the Local SGX Debugger, Please make sure change the "current working directory" pointing to $(OutDir) instead of $(ProjectDir).
Configuration Properties --> Debugging --> Working Directory --> $(OutDir).
Thanks.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I've already set the working directory to $(OutDir), but the error still exists. I write the enclave and the application according to the SGX SDK, the dll (enclave) file and exe (application) file both generated successfully, but it cannot run. This is my "hello world" source code, It would be nice if you can check it for me.
https://drive.google.com/open?id=0Bw1j4eporbRMZkh3WHFTOXpGNG8
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Quizy,
I have checked your source code, you didn't change the "current working directory" pointing to $(OutDir) instead of $(ProjectDir) in simulation mode (Both Application and Enclave).
Please find the modified source code of yours from below link
https://drive.google.com/open?id=0B4N3YNdBPBe8RW03UVBCZnN2VUE ;
Thanks
Surenthar Selvaraj
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thanks Surenthar,
I make the mistake to use the debug configuration to run the simulation enclave, and chosen the wrong project to run. It should be the app instead of the enclave.
Best wishes
Quizy
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
Will the simulation mode work on processors older than 6th gen? Or is there any way to simulate the SGX in 5th generation processor?
Regards,
Clindo
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
Simulation mode works processors older than 6th gen. Please read my blogs from below link
-Surenthar
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Surenthar,
I followed the blog and downloaded the sdk from https://software.intel.com/en-us/sgx-sdk. But I could not install it in i7- 5th Gen, it is exiting with error: ' The platform is not SGX-compatible. Please check your SGX BIOS settings. Install will cancel'.
How could I do the simulation if sdk is not getting installed? Please help.
Thanks and regards,
Clindo
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
It looks like you are trying to install the Platform SW, not the SDK. The SDK can build and run samples in simulation mode. The PSW requires an SGX-compatible system.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Ok, Let me try it.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Clindo, have you tried?
Could you please share your experience?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi ,
In the example code of SGX simulation mode,
I have changed the value of "secret" in "Enclave_Simulation.cpp",but the result of the program is always "Hello Encalve!" . Why?
Please help. Thank you for your kind!
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page