Skip to content
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

Any doc/wiki or paper introducing the zero-copy memory transferring mechanism? #3

Open
clover2024 opened this issue May 23, 2021 · 1 comment

Comments

@clover2024
Copy link

The readme file mentioned that "Penglai supports the synchronous and asynchronous cross-enclave communication using the zero-copy memory transferring mechanism". I tried to search about details about the "zero-copy memory transferring mechanism" but failed. I wonder if there are any doc/wiki or paper introducing the zero-copy memory transferring mechanism? Thanks.
P.S. I have tried the IPC demo in Penglai-Enclave-TVM and get the following result, but I could not fully understand the mechanism behind it. Many thanks if you can provide me with some introduction level docs.
image

@05lover
Copy link

05lover commented Jul 5, 2021

This may help.
https://penglai-doc.readthedocs.io/en/latest/Tutorials/Tutorial-Penglai-TVM-ipc.html#ownership-transferred-memory

Schrodinger page can only be mapped in either host or enclave. When schrodinger pages are allocated, they are first mapped in the host space. So host can read / write these pages as normal memory. When the enclave runs, monitor will guarantee that all the schrodinger pages is unmaped in the host, and remap to enclave. So enclave can read / write these pages. Schrodinger pages are used to defend against the Time-Of-Check-To-Time-Of-Use (TOCTTOU) attack, and can realize the zero-copy communication.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants