Efficient Sealable Protection Keys for RISC-V

12/04/2020
by   Leila Delshadtehrani, et al.
0

With the continuous increase in the number of software-based attacks, there has been a growing effort towards isolating sensitive data and trusted software components from untrusted third-party components. A hardware-assisted intra-process isolation mechanism enables software developers to partition a process into isolated components and in turn secure sensitive data from untrusted components. However, most of the existing hardware-assisted intra-process isolation mechanisms in modern processors, such as ARM and IBM Power, rely on costly kernel operations for switching between trusted and untrusted domains. Recently, Intel introduced a new hardware feature for intra-process memory isolation, called Memory Protection Keys (MPK), which enables a user-space process to switch the domains in an efficient way. While the efficiency of Intel MPK enables developers to leverage it for common use cases such as Code-Pointer Integrity, the limited number of unique domains (16) prohibits its use in cases such as OpenSSL where a large number of domains are required. Moreover, Intel MPK suffers from the protection key use-after-free vulnerability. To address these shortcomings, in this paper, we propose an efficient intra-process isolation technique for the RISC-V open ISA, called SealPK, which supports up to 1024 unique domains. SealPK prevents the protection key use-after-free problem by leveraging a lazy de-allocation approach. To further strengthen SealPK, we devise three novel sealing features to protect the allocated domains, their associated pages, and their permissions from modifications or tampering by an attacker. To demonstrate the feasibility of our design, we implement SealPK on a RISC-V Rocket processor, provide the OS support for it, and prototype our design on an FPGA. We demonstrate the efficiency of SealPK by leveraging it to implement an isolated shadow stack on our FPGA prototype.

READ FULL TEXT

page 1

page 6

research
09/20/2023

Capacity: Cryptographically-Enforced In-Process Capabilities for Modern ARM Architectures (Extended Version)

In-process compartmentalization and access control have been actively ex...
research
11/18/2018

libmpk: Software Abstraction for Intel Memory Protection Keys

Intel memory protection keys (MPK) is a new hardware feature to support ...
research
07/30/2019

EnclaveDom: Privilege Separation for Large-TCB Applications in Trusted Execution Environments

Trusted executions environments (TEEs) such as Intel(R) SGX provide hard...
research
01/21/2020

Occlum: Secure and Efficient Multitasking Inside a Single Enclave of Intel SGX

Intel Software Guard Extensions (SGX) enables user-level code to create ...
research
12/13/2021

FlexOS: Towards Flexible OS Isolation

At design time, modern operating systems are locked in a specific safety...
research
05/30/2018

Lord of the x86 Rings: A Portable User Mode Privilege Separation Architecture on x86

Modern applications are increasingly advanced and complex, and inevitabl...
research
09/20/2023

Software Compartmentalization Trade-Offs with Hardware Capabilities

Compartmentalization is a form of defensive software design in which an ...

Please sign up or login with your details

Forgot password? Click here to reset