-
Notifications
You must be signed in to change notification settings - Fork 585
Add dedicated windows-enclaves
crate
#3788
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
crates/libs/windows/src/Windows/Win32/System/Environment/mod.rs
Outdated
Show resolved
Hide resolved
I have excluded all Enclave functions exported by
It seems these should all just be loaded from |
Not all those APIs are implemented in |
Sigh, it looks like various Enclave APIs intended to be called from outside of the Enclave are not exclusively exported from |
It should only be that Is the metadata not what the microsoft learn pages are generated from? Is there somewhere else I should just get the metadata updated so that the |
Sadly not yet. Hopefully we get to the point of having canonical metadata in future. https://github.com/microsoft/windows-rs/tree/master/crates/libs/bindgen/default https://kennykerr.ca/rust-getting-started/how-are-crates-built.html |
The Win32 metadata includes some support for Windows virtualization-based security enclaves but these APIs are a little tricky because you need to import the APIs from a different system library depending on whether you are inside or outside of the enclave. This update thus does the following:
kernel32.dll
for crates likewindows
andwindows-sys
.windows-enclaves
crate that provides dedicated bindings for use within an enclave where all of the functions provided by this crate are specifically imported fromvertdll.dll
.I'm opening this PR for testing and validation as I am not too familiar with enclaves. Hopefully this will help make using enclaves easier from Rust.