Design and Implementation of a Resource-Secure System Matthieu Lemerre, Vincent David, Guy Vidal-Naquet

Design and Implementation of a Resource-Secure System Matthieu Lemerre, Vincent David, Guy Vidal-Naquet

Design and implementation of a resource-secure system Matthieu Lemerre, Vincent David, Guy Vidal-Naquet To cite this version: Matthieu Lemerre, Vincent David, Guy Vidal-Naquet. Design and implementation of a resource-secure system. 2010. cea-01113096 HAL Id: cea-01113096 https://hal-cea.archives-ouvertes.fr/cea-01113096 Preprint submitted on 4 Feb 2015 HAL is a multi-disciplinary open access L’archive ouverte pluridisciplinaire HAL, est archive for the deposit and dissemination of sci- destinée au dépôt et à la diffusion de documents entific research documents, whether they are pub- scientifiques de niveau recherche, publiés ou non, lished or not. The documents may come from émanant des établissements d’enseignement et de teaching and research institutions in France or recherche français ou étrangers, des laboratoires abroad, or from public or private research centers. publics ou privés. Design and implementation of a resource-secure system Matthieu Lemerre Vincent David Guy Vidal-Naquet CEA LIST CEA LIST SUPELEC Abstract eral different functions in a single system, that were previously segregated into several systems [53]. Often This paper describes an operating system for safe execu- these functions are of different importance, or criticality. tion of hard real-time and non real-time tasks on a sin- They must be isolated from one another (and in partic- gle computer. Achieving this goal requires not only to ular the most critical ones must be protected), but at the follow the traditional behavioral security principles, but same time the functions have to share the same set of re- also new resource security principles throughout the sys- sources: CPU time, memory, communication links, dis- tem. Even if these principles put heavy constraints on the play... Stronger resource security would allow less con- system, they make allocation predictable, immune from servative resource allocation and more resource sharing, denial of service attacks, and allows ensuring a task will increasing the system efficiency. have enough resource to complete its execution. We prove that building resource-secure systems is pos- sible by describing the design and implementation of our prototype, Anaxagoros. The main issue for writing the system is synchronization, and we propose several novel Contributions and plan Our first contribution is iden- ways to solve synchronization problems. tification of the resource-security principles for efficient and secure support of hard real-time tasks with general- purpose tasks. These principles bring a highly secure 1 Introduction system, yet dynamic and with flexible and precise re- source management. Section 2 details these principles A system that allows safe execution of hard real-time along with general design techniques to implement them. tasks is difficult to build. These tasks need prediction of the amount of CPU time and other resources necessary Our main interrogation when we began designing the to complete their execution, and the only known way to system was: “is it feasible to build a system that strictly achieve this is to strip down the system, removing most follows these design principles?” Indeed building a se- dynamic capabilities: no task creation, no dynamic ex- cure system is known to be a hard work, and resource- tension of address space... Static allocation of resources security puts even heavier constraints: no unpredictable is often the paradigm, because resource sharing is done blocking, bounded synchronization time, no dynamic al- using locks which makes schedulability analysis com- location of kernel/service memory, constant-time opera- plex and pessimistic [56]. tions... Hence our second contribution is proving that building such a system is indeed feasible, and has a po- We believe that the fundamental reason why general tential to be highly efficient. Section 3 details the de- purpose operating systems cannot safely execute hard sign and implementation of Anaxagoros, a system built real-time tasks is lack of resource security: it is difficult to strictly comply with those principles. to guarantee that the system will give to a task the amount of resources that was planned. We think that strong re- The main issue for building the system was synchro- source security, combined with flexible allocation poli- nization, and our third contribution is a set of techniques cies, would reconcile hard real-time with dynamic shar- for efficient solutions of synchronization problems that ing, general purpose behavior. arise when building a resource-secure system, detailed This problem is especially important as the current in section 4. Section 5,6,7 provides an evaluation of the trend in industrial control systems is to integrate sev- system so far, present related works and concludes. 1 2 Principles and global structure 2.2 General behavioral security Fault containment (i.e. protection from interference) and Our goal is to build a system that safely and efficiently traditional security have much in common [13, 53]: in- integrates hard real-time and non real-time tasks on the deed, a breach in confidentiality also indicates that a task same system. This section first defines what would be a can affect another one. Therefore, spatial and behavioral satisfactory integration, before giving the principles and security should be enforced through the systematic use general design rules to implement it. of traditional security principles, as stated by Saltzer and Schroeder [55]. 2.1 Requirements and goal Separation of privilege States that the system should The ideal system we want to build has the following char- be divided into small parts, each with restricted privi- acteristics: leges. To support this principle, our system defines three independent entities: address space (separates memory 1. It can safely share resources between the different rights), threads (separates CPU access rights), and do- tasks; for instance it allows tasks to share a network mains (separates all other kinds of rights). The usual task link or a graphical display. It allows “rich” OS op- concept is obtained by juxtaposition of one thread, one erations such that dynamic task creation or dynamic domain, and one address space. extension or address space. Least common mechanism System services are 2. It makes impossible for a task to interfere with the special-purpose code and data necessary to securely correct execution of another task. In particular, a share resources between several tasks. Least common task being able to delay another is considered a se- mechanism states that these services should be mini- curity breach, as this could lead to a deadline miss. mized, because they can cause more damage to the sys- tem (and also restricts its flexibility). There are two pos- 3. It is simple for the system integrator to put the func- sible interpretations of this principle. Microkernel sys- tions together. Adding a new task, resource or ser- tems (e.g. [32, 57, 35]) minimize common mechanism vice does not need to reconsider the previous de- by making tasks depend only on the services they use. sign. Assigning resources to tasks (and CPU time Exokernel and hypervisor systems [17, 52, 5] do it by in particular) is simple, and not constrained by the minimizing the size of these services. We chose to fol- particular system implementation. low both interpretations in our system, by structuring the OS into small, simple, low-level and separated services. Existing systems do not fulfill one or several of these characteristics. General purpose OS or hypervisors gen- Access control principles The principles state that erally can block unexpectingly (e.g. when encountering each access to each resource should be systematically a kernel semaphore or because of single-threaded ser- checked (complete mediation), that tasks should have no vices (e.g. [28, 62, 58]), and it is difficult to know the more privilege than required (least privilege), that access memory required for the operating system. control should be based on list of permissions rather than Hard real-time OS systems allow prediction of the list of bans (fail-safe defaults, also called closed-system number of resources to be used, and secure real-time OS design by Denning [13]), that the overall security mech- use timing budgets to prevent delay by other tasks. But anism should be simple (economy of mechanism), and they often do not allow operations like dynamic task cre- that security of the system should not rely on secrecy ation. Resource allocation is often static and sharing is (open design). We solve these issues by using capabil- rare, and done using locks that constrain to use a schedul- ity [42] as the sole mechanism of access control: a do- ing algorithm for which a schedulability analysis exists main can access an object only if it contains a capability that can take them into account (in practice, the non- to it. System capabilities implement all these principles, optimal fixed-priority algorithm). as they naturally implement a closed system, favor least To sum up, the system should provide facilities to privilege, are unforgeable and of simple design. safely share resources between tasks, i.e. using shared services. It should have strong security so as to prevent 2.3 Real-time and resource security undesirable task interference, and security should cover protection of the hard real-time requirements of the tasks. The previous security principles provide a sound basis to The use of shared services by hard real-time tasks should deal with “behavioral” security (integrity, confidentiality, be secured and easy. and spatial fault containment). But they are not sufficient 2 to protect from denial of service issues and temporal fault Resource allocation is simply done by moving resources containment, especially in the case of real-time systems. between partitions, and it is easy to account for the num- The main issue in hard real-time systems is “how to ber of resources used in each partition. ensure that each job will have enough resources to ex- Resource sharing is achieved by allowing several tasks ecute before their deadlines ?”.

View Full Text

Details

  • File Type
    pdf
  • Upload Time
    -
  • Content Languages
    English
  • Upload User
    Anonymous/Not logged-in
  • File Pages
    15 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