Commodity operating system kernels, such as the Linux kernel, are considered vulnerable due to many bugs. Most commodity OSes are also based on monolithic kernels, which can be easily compromised, and attackers gain complete control over all kernel fu...
Commodity operating system kernels, such as the Linux kernel, are considered vulnerable due to many bugs. Most commodity OSes are also based on monolithic kernels, which can be easily compromised, and attackers gain complete control over all kernel functionalities. Therefore, when an application handles security sensitive
data, it is highly recommend to execute the application in a trusted execution environment. In response to this demand, hardware trusted execution environments such as Intel SGX and ARM TrustZone have been developed by major CPU vendors. However, these trusted execution environments have several limitations. In the case of Intel SGX, CPU update is essential to address design vulnerabilities or to reflect customer feedback. In the case of ARM TrustZone, the CPU provides only a single isolated execution environment called the secure
world. When ARM TrustZone is freely opened to third-party developers, the attack surface of ARM TrustZone is expanded.
In this paper, we propose a software framework called SofTEE to support a trusted execution environment (TEE) for user applications. Unlike conventional hardware-based TEEs, SofTEE has some advantages. 1) Architecture independence, 2) ease of update, 3) low overhead for memory isolation, 4) unrestricted use of memory isolation, and 5) commodity-machine support.
Designing and implementing SofTEE involves several challenges. First, SofTEE should support memory isolation and attestation. For memory isolation, SofTEE depends on kernel deprivileging which delegates the execution of privileged operations such as memory management, from a kernel to a special module called a security monitor. To reduce the overhead of switching between the deprivileged kernel and the security monitor, SofTEE proposes an ecient management mechanism of the address space identier. SofTEE supports attestation by assuming minimal hardware functionalities of random entropy and root of trust. Next, SofTEE should independently handle and manage trusted applications. Lastly, SofTEE should guarantee security properties like condentiality and integrity of trusted applications. For security analysis, we have identied security invariants that SofTEE should meet for condentiality and integrity guarantees. Based on the security invariants, we have designed and prototyped each component of SofTEE on a Raspberry Pi 3 board. To measure SofTEE performance, we executed several real-world benchmarks. SofTEE produces about 3% overhead in case of a trusted application with long execution time (called Notary) and at most 34% overhead in case of a trusted application with short execution time (called PassHash and one-time password (OTP)).