Skip to content
This repository has been archived by the owner on May 9, 2022. It is now read-only.

Add a new crate for the AuthorizationEnclave #33

Closed
4 tasks done
longtomjr opened this issue May 3, 2021 · 2 comments · Fixed by #48
Closed
4 tasks done

Add a new crate for the AuthorizationEnclave #33

longtomjr opened this issue May 3, 2021 · 2 comments · Fixed by #48
Assignees
Labels
feat New feature or request

Comments

@longtomjr
Copy link
Collaborator

longtomjr commented May 3, 2021

  • Setup compile environment to mimic the rtc_data_enclave setup. Include:
    • Enclave.edl
    • Enclave.lds
    • Enclave_private.pem
    • Enclave.config.xml
    • rust-toolchain
    • x86_64-unknown-linux-sgx.json
  • Add a build script with cbindgen to generate the bindings (see rtc_data_enclave/build.rs)
  • Add Makefile based on the Makefile in rtc_data_enclave
  • Add the following attributes to the lib.rs
    • #![no_std] -> Sets no_std (so rust does not add std prelude to the top of every file)
    • #![feature(unsafe_block_in_unsafe_fn)] -> Require unsafe blocks for unsafe code, even if the function is marked as unsafe
    • #![deny(unsafe_op_in_unsafe_fn)] -> Sets the lint enabled by the above feature to error if the conditions are not met
    • #![deny(clippy::mem_forget)] -> Disallows (via clippy) the use of mem_forget. (This should not come up at all, but it is good to prevent obvious memory leaks)
@PiDelport
Copy link
Collaborator

For the crate name, rtc_auth_enclave?

@PiDelport
Copy link
Collaborator

Should we copy the Makefile, or try to factor out a common base Makefile again?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
feat New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants