Gu Jinyu
Gu Jinyu

Reputation: 21

With Intel SGX, can an enclave directly access outside space with a virtual address?

I have seen some opposite opinions. Thanks in advance!

One opinion is that the if the CPU is in enclave mode, it cannot reach a none-EPC page. That's to say, the code in an enclave cannot directly access outside virtual space.

The other opinion is that the enclave can see all the virtual space of this process.

Here's a link!

Upvotes: 1

Views: 561

Answers (2)

Gu Jinyu
Gu Jinyu

Reputation: 21

I checked the Intel manual about SGX again and also asked some Intel guys. Finally, I got the answer.

The code within an enclave can directly write outside memory and directly read outside memory under previous system policy. However, it cannot fetch outside code.

Upvotes: 1

Sergey
Sergey

Reputation: 1

Yes, an enclave can access the complete address space of the process. Otherwise, communication between enclave and non-enclave would not be possible.

Upvotes: 0

Related Questions