Intel Confidential Computing
Discussion board focused on Intel Confidential Computing technologies and how they can protect data and AI security, privacy, and sovereignty.
1559 Discussions

Core dump caused by calling ecall multiple times

LowEntropyBody
Beginner
4,292 Views

 

I repeatedly call an ecall function. No operation was performed in the function, just return. At the beginning, it went smoothly, but after a while, a core dump occurred. After setting the HeapMaxSize in the configuration to be large, the error time is pushed back. Is there something left in sgx after ecall ends, causing memory overflow? Or is there any way I can solve this problem.

 

PS:

<EnclaveConfiguration>
<ProdID>0</ProdID>
<ISVSVN>0</ISVSVN>
<!-- 64M -->
<StackMaxSize>0x4000000</StackMaxSize>
<HeapMaxSize>0x4000000</HeapMaxSize>
<TCSNum>20</TCSNum>
<TCSPolicy>1</TCSPolicy>
<!-- Recommend changing 'DisableDebug' to 1 to make the enclave undebuggable for enclave release -->
<DisableDebug>0</DisableDebug>
<MiscSelect>0</MiscSelect>
<MiscMask>0xFFFFFFFF</MiscMask>
</EnclaveConfiguration>

 

Update:

When I set TCSPolicy = 0, this core dump issue will not occur

Labels (1)
0 Kudos
4 Replies
JesusG_Intel
Moderator
4,270 Views

Hello LowEntropyBody,


We are looking into your issue. Please stay tuned.


0 Kudos
JesusG_Intel
Moderator
4,265 Views

Hello LowEntropyBody,


Since you solved your problem by setting TCSPolicy to 0, do you still need help with this issue?


If you still need help, please send your source code so we can reproduce your issue.


0 Kudos
LowEntropyBody
Beginner
4,263 Views

I did a test, but I just found the error after calling ecall repeatedly.

I have a question. What are the effects of setting TCSpolicy to 0 and what are the security risks?

ecall like:

void ecall_srd_increase(const char *path)
{
    return;
}
 
trusted {
public void ecall_srd_increase([in, string] const char* path);
}
0 Kudos
JesusG_Intel
Moderator
4,257 Views

Hello Yang, please read page 49 of the SGX Developer Guide for more info on the Thread Binding Policy: https://software.intel.com/sites/default/files/managed/33/70/intel-sgx-developer-guide.pdf.


Regards,


0 Kudos
Reply