intel / intel/confidential-computing.sgx

sgx-driver/sgx-gdb: Crash when debugging large enclaves

Open
#444 7 comments 2 reactions 0 assignees View on GitHub
Dominant language
C++
Stars
1.5k
Forks
565
PR merge metrics
No merged PRs in 30d

Description

The debugger crashes when debugging large enclaves.

To reproduce, in SampleCode/SampleEnclave/Enclave/Enclave.config.xml change
TCSNum to 20
StackMaxSize to 0x3E8000 (which is 4K * 1000)

```bash
$ make clean
$ make
$ sgx-gdb --args ./app ./enclave.signed.so
(gdb) r
...
/opt/intel/sgxsdk/bin/sgx-gdb: line 49: 47288 Killed LD_PRELOAD=$SGX_LIBRARY_PATH/libsgx_ptrace.so $GDB -iex "directory $GDB_SGX_PLUGIN_PATH" -iex "source $GDB_SGX_PLUGIN_PATH/gdb_sgx_plugin.py" -iex "set environment LD_PRELOAD" -iex "add-auto-load-safe-path /usr/lib" "$@"

```

This is the same issue as https://github.com/openenclave/openenclave/issues/2134

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.