> I recently upgraded to sdk 1.1.2, and I'm getting this error with a TLS
> client similar to the example provided.
>
> ```
> thread '<unnamed>' panicked at 'Can not access a Thread Local Storage value:
> AccessError { msg: "If TLS data needs to be destructed, TCS policy must be
> Bound." }',
> /root/.cargo/git/checkouts/teaclave-sgx-sdk-be25c2ad2f03718d/253b3ac/sgx_tstd/src/thread/local.rs:148:9
> note: Call backtrace::enable_backtrace with 'PrintFormat::Short/Full' for a
> backtrace.
> fatal runtime error: failed to initiate panic, error 5
> ```
>
> Any clues on how to investigate would be appreciated.
The reason is that something is relying on thread local storage, while your
enclave is configured as `TCSPOLICY = UNBOUND` which means your enclave does
not support thread local storage.
The most frequent case is using `rand::thread_rng`, which depends on thread
local storage.
--
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/apache/incubator-teaclave-sgx-sdk/issues/240#issuecomment-633824518