CHERI: a Research Platform Deconflating Hardware Virtualization

CHERI: a Research Platform Deconflating Hardware Virtualization

Robert N. M. Watson, Peter G. Neumann, Jonathan Woodruff, Jonathan Anderson, Ross Anderson, Nirav Dave, Ben Laurie, Simon W. Moore, Steven J. Murdoch, Philip Paeps, Michael Roe, and Hassen Saidi. CHERI: a research platform deconflating hardware virtualization and protection. Runtime Environments, Systems, Layering and Virtualized Environments (RESoLVE), March, 2012. CHERI: a research platform deconflating hardware virtualization and protection Robert N.M. Watson Peter G. Neumann Jonathan Woodruff University of Cambridge SRI International University of Cambridge [email protected] [email protected] jonathan.woodruff@cl.cam.ac.uk Jonathan Anderson Ross Anderson Nirav Dave University of Cambridge University of Cambridge SRI International [email protected] [email protected] [email protected] Ben Laurie Simon W. Moore Steven J. Murdoch Google UK Ltd University of Cambridge University of Cambridge [email protected] [email protected] [email protected] Philip Paeps Michael Roe Hassen Saidi NixSys BVB University of Cambridge SRI International [email protected] [email protected] [email protected] Abstract Adoption of software compartmentalisation has historically Contemporary CPU architectures conflate virtualization and pro- been resisted due to its impacts on performance, programmabil- tection, imposing virtualization-related performance, programma- ity, and debuggability. Many of these problems result from the bility, and debuggability penalties on software requiring fine- use of virtual memory techniques, which were developed to solve grained protection. First observed in micro-kernel research, these quite different problems in coarse-grained memory management problems are increasingly apparent in recent attempts to mitigate and paging rather than to provide fine-grained protection. Virtual software vulnerabilities through application compartmentalisation. addressing also causes programmability and debugging issues in Capability Hardware Enhanced RISC Instructions (CHERI) ex- this context, as programmers are unnecessarily exposed to dis- tend RISC ISAs to support greater software compartmentalisation. tributed system programming problems even in local application CHERI’s hybrid capability model provides fine-grained compart- development. Despite these limitations, hostile computing environ- mentalisation within address spaces while maintaining software ments have motivated increasing deployment of compartmentalisa- backward compatibility, which will allow the incremental deploy- tion in operating systems and applications [15, 16]. However, such ment of fine-grained compartmentalisation in both our most trusted efforts are plagued by problems of inefficiency, lack of scalability, and least trustworthy C-language software stacks. We have im- and difficulty in programming and debugging—as we experienced plemented a 64-bit MIPS research soft core, BERI, as well as a first-hand during our work on Capsicum [22]. capability coprocessor, and begun adapting commodity software CHERI offers an alternative path by introducing new hardware packages (FreeBSD and Chromium) to execute on the platform. protection features that are divorced from virtual memory features. CHERI systems retain an MMU, which can still be used for full- system and process virtualization, as well as paging and swapping. 1. Introduction However, CHERI also offers a non-hierarchical, in-address-space This workshop paper describes Capability Hardware Enhanced protection model, grounded in capabilities, that can be managed RISC Instructions (CHERI), an extension to the commodity 64-bit without recourse to privileged CPU instructions. The CHERI ca- MIPS1 instruction set architecture (ISA) to efficiently implement pability model allows efficient implementation of in-address-space memory capabilities and the object-capability security model [14]. software compartmentalisation by providing fine-grained mem- Using CHERI, we hope to provide enhanced hardware support ory protection and trustworthy security domain transitions [6, 24]. for software compartmentalisation—the granular decomposition The model is a hybrid capability model, which allows capability- of software into isolated components in order to improve robust- enhanced software components to be tightly integrated with con- ness, enforce security policies, and mitigate security vulnerabili- ventional software designs. The hybrid capability philosophy, first ties. Compartmentalisation combines abstraction, modularity, en- developed in the Capsicum operating system (but constrained by capsulation, privilege, and separation, whose effects are not gener- conventional CPU architectures), provides an incremental software ally directly exposed to contemporary hardware. adoption path, allowing capability system approaches to be de- ployed in our most trusted TCBs (OS kernels, system libraries, 1 We hope also to investigate this approach with the new ARMv8 ISA. language run-times), as well as our least trustworthy software (im- 1 2017/6/19 age decompression and video CODECs), all invisibly to other code While virtual-machine- and language-derived protection mod- in the system [22]. For example, CHERI is able to transparently els (such as those in Java) have proven effective for some purposes, execute capability-hardened libraries within unmodified applica- the continuing lack of scalable protection techniques for low-level, tions, as well as the converse: sandboxing legacy software libraries C-language software trusted computing bases (TCBs)—such as op- within capability-aware software. erating system kernels and language run-times—is concerning. In This workshop paper presents our early work in order to seek single-user computer systems, even web browsers and office suites feedback from the research community, and so adopts a didactic become part of the TCB, and have resisted migration to safer lan- style investigating our motivations, methodology, and future plans. guages. Performance concerns are often cited as the primary objec- We begin by considering in greater detail the historic conflation tions to migrating from C and C++, but multi-million LoC legacy of virtualization with protection in hardware, and how this inter- code bases are also an important factor. acts with protection goals in software. We then describe our re- We believe that the need for fine-grained compartmentalisation search approach, which is concerned with whether protection fea- is clear: lack of robustness and resilience to attacks causes our tures are better placed in hardware or software. We explore our most trusted software components (operating system kernels, lan- current prototype implementation, including development of a gen- guage run-times, web browsers) to be seriously untrustworthy. Pro- eralised platform for research into the hardware-software interface viding fine-grained compartmentalisation technology that is imme- and its specific adaptation to security research, as well as a demon- diately accessible and incrementally deployable—i.e., compatible stration of a hybrid operating system combining capability-aware with current legacy C-language code bases—in the system soft- and legacy code. Finally, we consider possible techniques for eval- ware space is critical, even if we believe that type-safe, managed uating this research, future directions, and related work. languages and formal methods will provide a longer-term solution. 2. Background 3. Approach Extensive research in operating systems, virtual machines, and pro- Capability Hardware Enhanced RISC Instructions (CHERI) extend gramming languages over the last four decades reflects an increas- conventional RISC instruction set architectures (ISAs) with fine- ing desire for fine-grained, high-performance protection in soft- grained protection independent of virtualization—i.e., from mem- ware, ranging from the Berkeley Packet Filter (BPF) to the Java ory management units (MMUs). We draw on over forty years of programming language [7, 11]. Motivations for granular decompo- architecture and security research into capability systems, starting sition of software include the desire to improve robustness against with Multics [17] and CAP [24], and including PSOS [13], Hy- dra [26], Mach [1], Java [7], Joe-E [12], Eros [19], seL4 [8], and software bugs, mitigation of software vulnerabilities, and imple- 2 mentation of fine-grained security policies—approaches whose Capsicum [22]. success derives from the principle of least privilege [18]. Experi- CHERI adopts Capsicum’s hybrid capability system approach ence from 1990s micro-kernel research (e.g., Mach), and more re- in order to blend conventional ISA compatibility with capability cently in application software compartmentalisation, suggests that system functionality. This provides an incremental adoption path, current hardware-based protection techniques impose significant allowing capability-oblivious conventional code to run both around obstacles to successful mapping of software compartmentalisa- and within capability-aware code. CHERI is deeply influenced by tion into virtual-memory-based process models [1, 3, 15, 22]. This ideas from the programming language community, with obvious has led to increased interest in software-based static and dynamic parallels between notions of hardware-supported typed objects and enforcement techniques, such as SFI and Google NativeClient, programming language-level versions of the same. The key design which side-step hardware primitives, supporting continuous en-

View Full Text

Details

  • File Type
    pdf
  • Upload Time
    -
  • Content Languages
    English
  • Upload User
    Anonymous/Not logged-in
  • File Pages
    8 Page
  • File Size
    -

Download

Channel Download Status
Express Download Enable

Copyright

We respect the copyrights and intellectual property rights of all users. All uploaded documents are either original works of the uploader or authorized works of the rightful owners.

  • Not to be reproduced or distributed without explicit permission.
  • Not used for commercial purposes outside of approved use cases.
  • Not used to infringe on the rights of the original creators.
  • If you believe any content infringes your copyright, please contact us immediately.

Support

For help with questions, suggestions, or problems, please contact us