Create module hash for each module in SGX lib-rats (#1745)
Current SGX lib-rats wasm module hash is stored in a global buffer, which may be overwritten if there are multiple wasm module loadings. We move the module hash into the enclave module to resolve the issue. And rename the SGX_IPFS macro/variable in Makefile and Enclave.edl to make the code more consistent. And refine the sgx-ra sample document.
This commit is contained in:
@ -103,7 +103,7 @@ enclave_init(sgx_enclave_id_t *p_eid)
|
||||
<= MAX_PATH - 1 - sizeof(TOKEN_FILENAME) - strlen("/")) {
|
||||
/* compose the token path */
|
||||
strncpy(token_path, home_dir, MAX_PATH);
|
||||
strncat(token_path, "/", strlen("/"));
|
||||
strncat(token_path, "/", strlen("/") + 1);
|
||||
strncat(token_path, TOKEN_FILENAME, sizeof(TOKEN_FILENAME) + 1);
|
||||
}
|
||||
else {
|
||||
|
||||
Reference in New Issue
Block a user