论文标题
有效地建立宿主应用和SGX飞地之间的相互不信任
Towards Efficiently Establishing Mutual Distrust Between Host Application and Enclave for SGX
论文作者
论文摘要
自首次亮相以来,SGX已用于许多应用程序,例如安全数据处理。但是,以前的系统通常假设一个受信任的飞地,而忽略了由未经信任的飞地引起的安全问题。例如,可以利用脆弱的(甚至是恶意的)第三方飞地来攻击主机应用程序和系统的其余部分。在本文中,我们提出了一种有效的机制来限制不受信任的飞地行为。不受信任的飞地的威胁来自飞地主持人的不对称。可以滥用他们以访问其主机应用程序的任意内存区域,离开飞地并伪造堆栈寄存器以操纵已保存的上下文后跳到任何代码位置。我们的解决方案破坏了不对称,并在主机应用和飞地之间建立了相互不信任。它利用Intel MPK进行有效的内存隔离和X86单步调试机制,以捕获Enclave存在时捕获事件。然后,它执行跳跃目标和堆栈指针的完整性检查。我们解决了两个实际挑战,并实施了原型系统。具有多个微基准和代表性现实世界应用的评估证明了我们系统的效率,其性能开销少于4%。
Since its debut, SGX has been used in many applications, e.g., secure data processing. However, previous systems usually assume a trusted enclave and ignore the security issues caused by an untrusted enclave. For instance, a vulnerable (or even malicious) third-party enclave can be exploited to attack the host application and the rest of the system. In this paper, we propose an efficient mechanism to confine an untrusted enclave's behaviors. The threats of an untrusted enclave come from the enclave-host asymmetries. They can be abused to access arbitrary memory regions of its host application, jump to any code location after leaving the enclave and forge the stack register to manipulate the saved context. Our solution breaks such asymmetries and establishes mutual distrust between the host application and the enclave. It leverages Intel MPK for efficient memory isolation and the x86 single-step debugging mechanism to capture the event when an enclave is existing. It then performs the integrity check for the jump target and the stack pointer. We have solved two practical challenges and implemented a prototype system. The evaluation with multiple micro-benchmarks and representative real-world applications demonstrated the efficiency of our system, with less than 4% performance overhead.