- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello,
SGX API works fine if it's called from a process. I can create an enclave successfully.
But when sgx_create_enclave() is called from dllmain(), it never returns. It eventually calls WaitForSingleObject() and wait there.
No matter the dll is injected into a process or load by a process.
Thanks :)
uty
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I believe this is due to:
Dynamic-Link Library Best Practices https://msdn.microsoft.com/en-us/library/windows/desktop/dn633971(v=vs.85).aspx
"You should never perform the following tasks from within DllMain:
* Call LoadLibrary or LoadLibraryEx (either directly or indirectly). This can cause a deadlock or a crash."
(edited to fix link)
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I installed the latest version of SDK, still got the same problem.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I believe this is due to:
Dynamic-Link Library Best Practices https://msdn.microsoft.com/en-us/library/windows/desktop/dn633971(v=vs.85).aspx
"You should never perform the following tasks from within DllMain:
* Call LoadLibrary or LoadLibraryEx (either directly or indirectly). This can cause a deadlock or a crash."
(edited to fix link)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
FRANCISCO C. (Intel) wrote:
I believe this is due to:
Dynamic-Link Library Best Practices https://msdn.microsoft.com/en-us/library/windows/desktop/dn633971(v=vs.85).aspx
"You should never perform the following tasks from within DllMain:
* Call LoadLibrary or LoadLibraryEx (either directly or indirectly). This can cause a deadlock or a crash."(edited to fix link)
Thanks for the reply and link :)
I know sgx_create_enclave() will load xxx.signed.dll at some point. I want use sgx in some processes which I don't have source code. I guess I have to use sgx_create_enclave() lazily (The first time I need to use enclave).
Thanks :)
![](/skins/images/45C6C2D737ED71F4C51F0145C8CB1E9C/responsive_peak/images/icon_anonymous_message.png)
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page