Enclave.edl 1007 B

12345678910111213141516171819202122232425262728293031323334
  1. /*
  2. * Copyright (C) 2019 Intel Corporation. All rights reserved.
  3. * SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
  4. */
  5. #define WASM_ENABLE_SGX_IPFS 0
  6. #define WASM_ENABLE_LIB_RATS 0
  7. enclave {
  8. from "sgx_tstdc.edl" import *;
  9. from "sgx_pthread.edl" import *;
  10. from "sgx_wamr.edl" import *;
  11. #if WASM_ENABLE_LIB_RATS != 0
  12. from "rats.edl" import *;
  13. from "sgx_tsgxssl.edl" import *;
  14. #endif
  15. #if WASM_ENABLE_SGX_IPFS != 0
  16. from "sgx_tprotected_fs.edl" import *;
  17. #endif
  18. trusted {
  19. /* define ECALLs here. */
  20. public void ecall_handle_command(unsigned cmd,
  21. [in, out, size=cmd_buf_size]uint8_t *cmd_buf,
  22. unsigned cmd_buf_size);
  23. public void ecall_iwasm_main([user_check]uint8_t *wasm_file_buf,
  24. uint32_t wasm_file_size);
  25. };
  26. untrusted {
  27. /* define OCALLs here. */
  28. int ocall_print([in, string]const char* str);
  29. };
  30. };