Enable remote attestation by librats in SGX mode (#1445)
Add library librats, update SGX build scripts, add sample and update document.
This commit is contained in:
@ -53,6 +53,9 @@ get_lib_pthread_export_apis(NativeSymbol **p_lib_pthread_apis);
|
||||
uint32
|
||||
get_libc_emcc_export_apis(NativeSymbol **p_libc_emcc_apis);
|
||||
|
||||
uint32
|
||||
get_lib_rats_export_apis(NativeSymbol **p_lib_rats_apis);
|
||||
|
||||
static bool
|
||||
compare_type_with_signautre(uint8 type, const char signature)
|
||||
{
|
||||
@ -414,6 +417,14 @@ wasm_native_init()
|
||||
return false;
|
||||
#endif /* WASM_ENABLE_LIBC_EMCC */
|
||||
|
||||
#if WASM_ENABLE_LIB_RATS != 0
|
||||
n_native_symbols = get_lib_rats_export_apis(&native_symbols);
|
||||
if (n_native_symbols > 0
|
||||
&& !wasm_native_register_natives("env", native_symbols,
|
||||
n_native_symbols))
|
||||
return false;
|
||||
#endif /* WASM_ENABLE_LIB_RATS */
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user