Lecture Notes in Computer Science Edited by G. Goos, J. Hartmanis and J. van Leeuwen
1485
Jean-Jacques Quisquater Yves Deswarte Catherine Meadows Dieter Gollmann (Eds.)
Computer Security ESORICS 98 5th European Symposium on Research in Computer Security Louvain-la-Neuve, Belgium September 16-18, 1998 Proceedings
~ Springer
Series Editors Gerhard Goos, Karlsruhe University, Germany Juris Hartmanis, Cornell University, NY, USA Jan van Leeuwen, Utrecht University, The Netherlands Volume Editors Jean-Jacques Quisquater UCL, Microelectronic Laboratory Place du Levant 3, B-1348 Louvain-la-Neuve, Belgium E-mail: quisquater@ dice.ucl.ac.be Yves Deswarte LAAS-CNRS & INRIA 7, avenue du Colonel Roche, F-31077 Toulouse cedex 4, France E-mail: yves.deswarte @laas.fr Catherine Meadows Naval Research Laboratory 4555 Overlook Ave., S.W., Washington, DC, 20375, USA E-mail: meadows @itd.nrl.navy.mil Dieter Gollmann Microsoft Research Limited St. George House, 1 Guildhall Street, Cambridge CB2 3NH, UK E-mail:
[email protected] Cataloging-in-Publication data applied for Die Deutsche Bibliothek - C1P-Einheilsaufnahme C o m p u t e r security : proceedings / ESORICS 98, 5th European Symposium on Research in Computer Secnrily, Louvain-la-Neuve, Begiam, September 16 - 18, 199~. Jean-Jacques Ouisquater ... (ed.). Berlin ; Heidelberg ; New York ; Barcelona ; Budapest ; Hong Kong ; London ; Milan ; Paris ; Singapore ; Tokyo : Springer, 1998 (Lecture notes in computer science ; Vol. 1485) ISBN 3-540-65004-0
CR Subject Classification (1991): D.4.6, E.3, C.2.0, H.2.0, K.6.5 ISSN 0302-9743 ISBN 3-540-65004-0 Springer-Verlag Berlin Heidelberg New York This work is subject to copyright. All rights are reserved, whether the whole or part of the material is concerned, specifically the rights of translation, reprinting, re-use of illustrations, recitation, broadcasting, reproduction on microfilms or in any other way, and storage in data banks. Duplication of this pubhcation or parts thereof is permitted only under the provisions of the German Copyright Law of September 9, 1965, in its current version, and permission for use must always be obtained from Sprmger-Verlag. Violations are liable for prosecution under the German Copyright Law. 9 Springer-Verlag Berlin Heidelberg 1998 Printed in Germany Typesetting: Camera-ready by author SPIN 10638805 06/3142 - 5 4 3 2 1 0
Printed on acid-free paper
Preface
Since 1990, ESORICS has established its reputation as the main event in research on computer security in Europe. Every two years, ESORICS gathers researchers and practitioners of computer security and gives researchers the opportunity to present the most recent advances in security theory as well as the risks related to simplistic implementations of security mechanisms. Despite possible concurrence with other international events, ESORICS 98 received 57 submissions, coming from 19 countries and 4 continents. All these papers were reviewed by at least three program committee members or other experts at their institutions. Most of the submitted papers were considered as very good, and the program committee quickly agreed on 23 papers that could be organised into consistent sessions. Unfortunately, some high quality papers had to be rejected either because they did not correspond to ESORICS scope or because they did not fit with other papers to constitute a homogeneous session. As in previous ESORICS, some ESORICS 98 sessions are dedicated to fundamental issues such as the design and specification of security policies, access control modelling and protocol analysis. But these sessions mix both theoretical papers and very practical concerns. Since mobility is a topic of increasing importance, its two main aspects will be discussed in two sessions: one on mobile systems and anonymity, the other on Java and mobile code. A session and a panel are devoted to watermarking, an important technique for the protection of intellectual rights. Finally, two sessions are dedicated to practical issues, one on intrusion detection and prevention, the other dealing with specific threats. In this session, two papers on cryptography have been included for the first time in ESORICS. While previously, we had considered that cryptography papers should be submitted to conferences dedicated to cryptography, these two papers have been accepted because security people can learn from them the risks that can be raised by naive implementation of good cryptographic algorithms. In summary, we hope that this mix between practical and theoretical issues will satisfy the practitioner's curiosity and encourage researchers to pursue their work for the progress of a secure information society.
Yves Deswarte Programme Chair
Catherine Meadows Programme Vice-Chair
VI
Organization Conference Chairs General Chair: Program Chair: Program Vice-Chair:
Jean-Jacques Quisquater (UCL, Belgium) Yves Deswarte (LAAS-CNRS & INRIA, France) Catherine Meadows (NRL, USA)
Proceedings Editor Dieter Gollmann
Microsoft Research, UK
Program Commitee Elisa Bertino Joachim Biskup Yves Deswarte G6rard Eizenberg Simon Foley Dieter Gollmann Franz-Peter Heider Jeremy Jacob Sokratis Katsikas Helmut Kurth Peter Landrock Carl Landwehr Guy Leduc Teresa Lunt Beno~t Macq Ueli Maurer Catherine Meadows Refik Molva Emilio Montolivo Roger Needham Pierre Paradinas Jean-Jacques Quisquater Pierre Rolin Peter Ryan Pierangela Samarati Einar Snekkenes Gene Spafford Stuart Stubblebine Michael Waidner
University of Milan, Italy University of Dortmund, Germany LAAS-CNRS & INRIA, France CERT-ONERA, France) Cambridge University CCSR, UK & University College Cork, Ireland Microsoft Research, UK debis, Germany University of York, UK University of the Aegean, Greece IABG, Germany Arhus University, Denmark NRL, USA University of Liege, Belgium DARPA, USA UCL, Belgium ETH Ziirich, Switzerland NRL, USA Eurecom, France Fondazione Ugo Bordoni, Italy Microsoft Research, UK Gemplus, France UCL, Belgium France Telecom, France DERA, UK University of Milan, Italy FFI, Norway Purdue University, USA AT&T, USA IBM, Switzerland
vIf
Additional
Referees
N. Asokan Marco Bucci Jan Camenisch Cecilia Catalano Bruno Crispo Francesco Gentile Irfan Ghauri Pierre Girard Luigi Giuri Martin Hirt G/inter Karjoth Jean-Louis Lanet Sergio Loureiro Renato Menicocci Markus Michels Jon Millen Alain Pannetrat Local Organisation Benolt Macq Bart Preneel Catherine Rouyer Joos Vandewalle
IBM Zfirich Research Laboratory, Switzerland Fondazione Ugo Bordoni, Italy ETH Zurich, Switzerland Fondazione Ugo Bordoni, Italy University of Cambridge, UK Fondazione Ugo Bordoni, Italy Institut Eurecom, France Gemplus, France Fondazione Ugo Bordoni, Italy ETH Ziirich, Switzerland IBM Z/irich Research Laboratory, Switzerland Gemplus, France Institut Eurecom, France Fondazione Ugo Bordoni, Italy Ubilab, UBS, Switzerland SRI International, USA Institut Eurecom, France Committee Universit@ catholique de Louvain, Belgium Katholieke Universiteit Leuven, Belgium Universit@ catholique de Louvain, Belgium Katholieke Universiteit Leuven, Belgium
Table of Contents
Fixed vs. Variable-Length Patterns for Detecting Suspicious Process Behavior . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
1
H. Debar, M. Dacier, M. Nassehi, and A. Wespi A Tool for Pro-active Defense Against the Buffer Overrun Attack . . . . . . . .
17
D. Bruschi, E. Rosti, and R. Banff A Kernelized Architecture for Multilevel Secure Application Policies . . . . . .
33
S.N. Foley Dealing with Multi-policy Security in Large Open Distributed Systems . . .
51
C. Bidan and V. Issarny A Flexible Method for Information System Security Policy Specification ..
67
R. Ortalo On the Security of Some Variants of the RSA Signature Scheme . . . . . . . . .
85
M. Michels, M. Stadler, and H.-M. Sun Side Channel Cryptanalysis of Product Ciphers . . . . . . . . . . . . . . . . . . . . . . . .
97
J. Kelsey, B. Schneier, D. Wagner, and C. Hall On the Security of Digital Tachographs
..............................
111
R. Anderson An Authorization Model and Its Formal Semantics . . . . . . . . . . . . . . . . . . . . .
127
E. Be~ino, F. Buccafurri, E. Ferrari, and P. Rullo Authorization in CORBA Security . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
143
G. Karjoth Rules for Designing Multilevel Object-Oriented Databases . . . . . . . . . . . . . . .
159
F. Cuppens and A. Gabillon Byte Code Verification for Java Smart Cards Based on Model C h e c k i n g . . . 175
J. Posegga and H. Vogt Towards Formalizing the Java Security Architecture of JDK 1.2 . . . . . . . . . .
191
L. L. Kassab and S. J. Greenwald EUROMED-JAVA: Trusted Third Party Services for Securing Medical Java Applets . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
A. Varvitsiotis, D. Polemi, and A. Marsh
209
MPEG PTY-Marks: Cheap Detection of Embedded Copyright Data in DVD-Video . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
221
J. P. M. G. Linnartz, and J. C. Talstra DHWM: A Scheme for Managing Watermarking Keys in the Aquarelle Multimedia Distributed System . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
241
D. Augot, J.-F. Delaigle, and C. Fontaine The "Ticket" Concept for Copy Control Based on Embedded Signalling... 257
J.P.M.G. Linnartz Panel Session: Watermarking . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
275
G. Eizenberg and J.-J. Quisquater Authentication and Payment in Future Mobile Systems . . . . . . . . . . . . . . . . .
277
G. Horn and B. Preneel Distributed Temporary Pseudonyms: A New Approach for Protecting Location Information in Mobile Communication Networks . . . . . . . . . . . . . .
295
D. Kesdogan, P. Reichl, and K. Junghiirtchen A Mix-Mediated Anonymity Service and Its Payment . . . . . . . . . . . . . . . . . . .
313
E. Franz and A. Jeriehow A Subjective Metric of Authentication . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
329
A. J~sang A Sound Logic for Analysing Electronic Commerce Protocols . . . . . . . . . . . .
345
V. Kessler and H. Neumann Kerberos Version IV: Inductive Analysis of the Secrecy Goals . . . . . . . . . . . .
361
G. Bella and L. C. Paulson Author
Index
.................................................
377
Fixed vs. Variable-Length Patterns for D e t e c t i n g Suspicious Process Behavior Hervd Debar, Marc Dacier, Mehdi Nassehi, and Andreas Wespi IBM Research Division, Zurich Research Laboratory, CH-8803 Riischlikon, Switzerland {deb, dac ,mmn, anw}Ozurich, ibm. com
A b s t r a c t . This paper addresses the problem of creating patterns that can be used to model the normal behavior of a given process. These models can be used for intrusion detection purposes. In a previous work, we presented a novel method to generate input data sets that enable us to observe the normal behavior of a process in a secure environment. Using this method, we propose various techniques to generate either fixed-length or variable-length patterns. We show the advantages and drawbacks of each technique, based on the results of the experiments we have run on our testbed.
1
Introduction
In [1] Forrest et al. introduced a change-detection algorithm for detecting computer viruses t h a t is based on the way t h a t natural immune systems distinguish "self" from "nonself". In [2] they reported preliminary results extending this approach in the intrusion-detection area by establishing such a definition of self for Unix processes. This technique models the way an application or service running on a machine normally behaves by registering the sequences of system calls invoked. An intrusion is assumed to exercise abnormal paths in the executable code, and is detected when new sequences are observed (see also [3], [4], [5]). Like every behavior-based technique, an intrusion-detection system needs to be trained to learn what the "normal" behavior of a process is. This is usually done by recording the activity of the process running in a real environment during a given period. This procedure has a number of drawbacks: - It leaves open the possibility of obtaining false negatives [6] if not all possible behaviors have been exercised during the recording period, because new users, new applications or configuration changes introduce new usage
patterns. - It leaves open the possibility of obtaining false positives [6] if the application has been hacked during the recording period. - The observed behavior is a function of the environment in which it is running and thus prevents the distribution of an "initialized" intrusion-detection system that could immediately be plugged in and activated.
2
Herv@ Debar et al.
Another approach consists of artificially creating input data sets that exercise all normal modes of operation of the process. For example, Forrest et al. [2] use a set of 112 messages to study the behavior of the sendmail daemon. This method eliminates the risk of obtaining a false positive but not that of obtaining a false negative. Furthermore, it is an extremely complex and time-consuming task to come up with a good input d a t a set. In [7] we have shown how to use the functionality verification test (FVT) suites provided by application developers to observe all the specified behaviors of an application. Not only are we able to eliminate the risk of obtaining a false positive with this approach, but we also dramatically reduce the risk of obtaining a false negative because, by design, our input data set exercises all the normal (in the sense of having been specified by the designer of the application) modes of operation of the application under study. In this paper, we present the results of experiments we have been running with this technique. Besides the use of the F V T suites, our work differs from that of Forrest et al. in three main ways: - The algorithm used to create fixed-length patterns is slightly different and results in shorter tables of patterns. We consider in addition the opportunity of using variable-length patterns [8] and various ways of doing this. The decision to raise an alarm is based on a new paradigm that is simpler than the Hamming distance described in [2], thus allowing possible real-time countermeasure. -
-
The structure of the paper is as follows. Section 2 presents the principles of the intrusion-detection techniques we are working with. It explains how patterns are generated and used to cover sequences. Section 3 presents the experimental results obtained when applying a fixed-length pattern-generation algorithm. Section 4 does the same for a variable-length pattern-generation algorithm. These two sections also highlight advantages and disadvantages of each technique. Section 5 concludes the paper by offering a comparison of the results as well as ideas for future work. 2
Principles
of the
Approach
In our approach, UNIX processes are described by the sequence of audit events 1 that they generate, from start (fork) to finish (exit). Their normal behavior is modeled by a table of patterns which are subsequences extracted from these sequences. The detection process relies on the assumption that when an attack exploits vulnerabilities in the code, new (i.e., not included in the model) subsequences of audit events will appear. Fig. 1 describes the complete chain used to configure the detecting tool. 1 Note that Forrest et al. [1], [2] use the sequences of system calls instead of audit events. Obtaining system calls constitutes a more intrusive technique than the one we present here.
Fixed vs. Variable-Length Patterns for Suspicious Behavior Detection
3
TRAINING SYSTEM
Translation[
[Filtering
v
PROC_cre$te FILE_close FILE_close
I Pattern
i || i
?
9 . .D A A B G E A B C D D A E F G
......
DABGEABCDAEFG...
FILE_open
OFF-LINE ON-LINE
.
.
.
.
.
.
1
Exgaction
MODEL: Table of known patterns .
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
INTRUSION DETECTION SYSTEM
.
.
.
.
.
~t T
[.~ ' T;anilati'onI
Filtering
]
]
Pattern
~lAwegaa~ I
-- [ Matching
V
PROCcrea$e FILE_close
riLE ol .
9 . .AABBGGEABCDDADECFG
......
ABGEABCDAECFG...
ABGE ABCD
.
.
.
:~'.~"
-> matched -> matched
~!~.'..
FILE_open SPASSWORDREAD TCPIP_eonnect
Fig. 1. Intrusion-detection system
2.1
Off-Line Treatment
The upper part of Fig. 1 represents how the model of normal behavior is created off-line. Audit events are recorded from the ftp daemon, which has been triggered by an experiment process, and translated as letters for easier handling. Such a letter in our system actually represents the combination of the audit event and the name of the process generating it, both pieces of information being provided by the Unix C2 audit trail. This recording runs through a filtering and reduction process whose purpose is explained later. When the experiment has been completed, the entire audit information is used to generate the table of patterns that constitute our model of the normal behavior of the system. The purpose of the filtering/reduction/aggregationbox is threefold (explained in more detail in the remainder of the section):
filtering to eliminate irrelevant events (processes that are not related to the services we monitor) and to sort the remaining ones by process number;
reduction to remove duplicate sequences due to processes generating exactly the same stream of audit events from start
(fork)
to finish
(exit), 2
and
aggregation to remove consecutive occurrences of the same system calls.
2 This is not used in the on-line version, because of the memory cost and algorithmic complexity of keeping all known process images.
4
Herv@ Debar et al.
Sorting prevents the introduction of arbitrary context switches into the audit stream by the operating system. Processes are sorted so that the intrusiondetection process is applied to each process individually. The events inside the process remain in the order in which they have been written to the audit trail. The reduction keeps only unique process images for model extraction. We use test suites to record the normal behavior of the ftp daemon. These test suites carry many repetitive actions and therefore result in many instances of the same process image (see [7] for a complete explanation of this issue). We remove these duplicates as they are not used by the current algorithm extracting the patterns from the reference audit data. The aggregation comes from the observation that strings of N consecutive audit events (N > 20) are quite frequent for certain events, with N exhibiting small variations. A good example is the "ftp login" session, where the ftp daemon closes several file handles inherited from inetd, the number of these closes changing without obvious cause. Therefore, we decided to simplify the audit trail in order to obtain a model containing fewer and shorter patterns. We did not observe any difference in either the false positive or false negative rates between those experiments in which the aggregation was used and those in which it was not. There is no claim of equivalence between the reduced (simplified) audit trail and the original one; the new one possibly has less semantic content. This is an experimental choice, and we would remove the aggregation part if the true/false alarm performance of the intrusion-detection system were not satisfactory. This aggregation phase would also be skipped if the intrusion-detection technique requires redundancy, e.g. neural networks. The most obvious aggregation consists of replacing identical consecutive audit events with an extra "virtual" audit event. However, doing so enriches the vocabulary (the number of registered audit events) and possibly the number of patterns, which we want to keep small. Our solution simply aggregates these identical consecutive audit events. Therefore, any audit event represents "one or more" such events (i.e., A = A+ in regular expression formalism) at the output of the aggregation box. 2.2
R e a l - T i m e Detection
The lower part of Fig. 1 shows the real-time intrusion-detection process. Audit events are again generated by the ftp daemon, and go through the same sorting and reduction mechanism in real time. Then, we apply a pattern-matching algorithm (Section 2.3) to cover the sequences on the fly. When no known pattern appropriately matches the current stream of audit events, a decision has to be taken whether to raise an alarm (see Section 2.4).
2.3
Pattern-Matching Algorithm
The pattern-matching algorithm is quite critical for the performance of the intrusion-detection system. We wish to maximize both speed and detection capabilities. Therefore, we require that patterns match exactly, i.e., they cannot be
Fixed vs. Variable-Length Patterns for Suspicious Behavior Detection
5
matched as regular expressions using wildcards. We use a two-step algorithm: the first step looks for an exact match, and the second step looks for the best partial match possible. These two steps are illustrated with the examples presented in Figs. 2 and 3.
Table
ABCD XYZD ABC GHI XYZ HF
String:
ABCABCDXYZGHI
ABC Selectable
ABCD XYZD ABC
Reminder of string:
ABCDXYZGHI
Reminder of string:
XYZGHI
ABCD ABCD XYZD ~
Reminder of string:
Gill XYZ
GHI ABCD XYZD ~
ABC Validated GHI
A B C validated: 3 consecutive patterns yield exact match
Fig. 2. Exact pattern-matching sequence
Table
ABCD XYZD ABC GHI XYZ HF
String:
ABCABCDKMWHF AP,~CD XYZD ABC
Reminder of String:
ABCDKMWHF ABC ~ length6 ABCD ~ length 7 ~ K M W
SELECTED
= Shifted ~ Shifted ~- Shifted
Uncovered sequence K M W Fig. 3. Approximate pattern-matching sequence The first step of the algorithm is illustrated in Fig. 2. A pattern that matches the beginning of the string is selected from the p a t t e r n table. If no pattern matches the beginning of the string, then the first event is counted as uncovered and removed. The algorithm is subsequently applied to the remainder of the string. Once a selectable p a t t e r n has been found, the algorithm will recursively look for other patterns t h a t exactly cover the continuation of the string up to a given depth D or to the end of the string, whichever comes first (D = 3 in Fig. 2). This means that, for a selectable pattern to be chosen, we must find D other patterns that also completely m a t c h the events following t h a t p a t t e r n in the sequence. If such a sequence of D patterns does not exist, step 2 of the algorithm is used. The rationale behind this is t h a t we want to know whether the selected pattern has
6
Herv@ Debar et al.
a positive influence on the coverage of the audit events t h a t are in its vicinity. When such a D - p a t t e r n sequence has been found, the algorithm pops the head p a t t e r n out of the sequence and goes on with the remainder of the string. If we cannot find three other patterns t h a t m a t c h the sequence after the selected pattern, we deselect it and try the next selectable p a t t e r n in the table. The fact t h a t there were selectable patterns, but none t h a t fulfill the depth requirement, triggers the second phase of the algorithm. The second step of the algorithm deals with failure cases and is illustrated in Fig. 3. The algorithm looks for the sequence of N patterns t h a t covers the largest number of audit events. This sequence is removed from the string and the algorithm goes back to its first part, looking again for a selectable pattern, and shortening the string as long as one is not found. 2.4
Intrusion
Detection
For each string, the algorithm extracts b o t h the number of groups of audit events t h a t were not covered and the length of each of these groups. The decision whether to raise an alarm is based on the length of the uncovered sequences. It is worth noting t h a t this is different from the measures used for the same purpose by Forrest et al., namely the n u m b e r and the percentage of uncovered events in a string [2]. There are three reasons for this. Processes can generate a large number of events. An attack can be hidden in the midst of a set of normal actions. Using the percentage of uncovered characters would fail to detect the attack in this case. - Small processes could be falsely flagged as anomalous because of a few uncovered events if we use the percentage of uncovered characters. - Long processes could be falsely flagged as anomalous because of m a n y isolated uncovered events if we use the amount of uncovered characters. -
During our experiments we observed t h a t the trace of the attacks was represented by a number of consecutive uncovered characters. This is consistent with the findings of Kosoresow and Hofmeyr [5], who note t h a t mismatches due to intrusions occur in fairly distinct bursts in the sequences of system calls they monitored. This means t h a t an attack cannot be carried out in fewer t h a n T consecutive characters. Our experiments led us to choose the value 7 for T. In other words, each group of more t h a n six consecutive uncovered events is considered anomalous and flagged as an attack. This amounts to defining an intrusion as any event t h a t generates a sequence of at least T consecutive events not covered by the algorithm defined above. To validate the concepts presented here, we have developed an intrusiondetection testbed [9]. We have used it to compare various strategies to build the table of patterns used in the detector. The results of these experiments are reported in the next two sections. T h e y focus on the ]tp service, which is widely used, is known to contain m a n y vulnerabilities, and provides rich possibilities for user interaction.
Fixed vs. Variable-Length Patterns for Suspicious Behavior Detection
3 3.1
7
Generating Fixed-Length Patterns Pattern Generation
Fixed-length patterns are the most immediate approach to generate the table of patterns. We have evolved four ways of obtaining these patterns. For each of them, we use a parameter L, the length of the patterns. Technique 1 is an exhaustive generation of all possible patterns by sliding a window of size L across the sequence and recording each unique L-event sequence. This technique is easy to implement, but has obvious drawbacks. First, a large number of patterns in the reference table will not be used by the matching algorithm on the reference data set. Moreover, the covering algorithm generates boundary mismatches when the length of the process image is not a multiple of L, because it uses a juxtaposing window instead of a sliding one (which would not make sense in this context). It is worth noting that this is the technique used to run the experiments described in [2], [4], and [5]. To solve the first problem, technique 2 is introduced, which shifts the string by L events, thus creating juxtaposed patterns instead of overlapping ones. In other words, the events in positions 1 to L constitute the first pattern, events in the positions L + 1 to 2L constitute the second one, and so on ... The table we obtain is thus much shorter than the table generated by technique 1, which makes the pattern-matching algorithm faster. Technique 2 drops the remainder of the sequence of events when its length is not a multiple of L, therefore the second problem mentioned remains. To solve it, we have introduced techniques 3 and 4. They are similar to technique 2 but keep the events remaining at the end of the string as a stand-alone pattern or concatenated to the last generated pattern, respectively. Techniques 3 and 4 both result in 100% coverage of the test sets. As they are the ones that were most promising during the experiments, we focus on them in the remainder of this paper. Note that some of the patterns are smaller or larger than the specified size, and these can only match at the end of the process execution, as they necessarily contain the end-of-process event.
3.2
Experimental Results
We have used three test sets in our experiments. The first test is solely based on the FVT. The second test set includes additional information on tools that are used by ftp users, but are not in the testing of the ftp daemon p e r se. The third data set is based on the recording of several hundred real user sessions. The experimental results are presented for the second test set. The reference table generated from the first set does not contain patterns for commands like tar, which are used by normal users. Using the third set breaks the rule fixed in the introduction of the paper (no user recording for training), thus this set has only been used to evaluate the false negative rates obtained with our approach. The output of the intrusion-detection system is shown in Fig. 4. Each line reports the analysis for one process related to the ftp service.
8
Herv~ Debar et al. INumber of INumber of IPercentage INumber of IAverage INumber of ILength of laudit
luncovered
levents
levents
569 97 928 735
6 878 839
8 963 168 476 366
I o f covered Ipatterns
events 99.30 100.00 99.68 99.59 100.00 99.09 99.52 25.00 99.79 93.81 99.79 99,18
188 32 308 244 2 290 278 1 320 58 158 121
Isize of Igroups Ipattern 3.01 3.03 3.00 3.00 3.00 3.00 3.00 2.00 3.00 3.02 3.01 3.00
leach group 1111 111 111 IIiiiiii iiii 6 2 II 1 IIi
Fig. 4. Output of the intrusion-detection system
Table 1 shows the results of the experiments to monitor our ftp server under various conditions, using the intrusion-detection system loaded with several reference tables. The first column identifies the experiment. The second column gives the number of audit events in the experiment. The third column indicates the two parameters corresponding to the reference table used in the intrusiondetection system, t denotes the generation technique (3 or 4) and s the size of the patterns (2, 3 and 4). The fourth column gives the overall number of uncovered characters. The fifth column gives the number of patterns used for the coverage. The sixth column gives the average size of patterns, 3 and the seventh column indicates the number of false alarms triggered by the intrusion-detection system. Table 1 shows that our intrusion-detection system has the potential to perform well without generating false alarms. Indeed, for patterns of length 2, independent of the technique used (3 or 4), the intrusion-detection system does not generate false alarms. For patterns of length 4, independent of the technique used, the intrusion-detection system generates false alarms. For patterns of length 3, the generation of false alarms is dependent on the technique used for the generation. With technique 3, which introduces more patterns but also more freedom (some patterns can be smaller than the required length of 3), the intrusion-detection system does not generate false alarms, whereas it will generate false alarms if technique 4 is used. It is also worth mentioning that if we use the third test set, which is closely based on user-behavior observations, instead of the second one, we observe no false alarms for any of the combinations (pattern size, technique). However, using user-generated data to train the intrusion-detection system breaches the requirements expressed in the introduction.
3 This value is truncated after the second decimal.
F i x e d vs. Variable-Length P a t t e r n s for Suspicious Behavior D e t e c t i o n
9
T a b l e 1. E x p e r i m e n t a l results for normal user sessions Simulation description A n o n y m o u s user sessions
N u m b e r Technique N u m b e r of N u m b e r of A v e r a g e Number of audit and uncovered p a t t e r n s size of of false events size events required p a t t e r n s alarms 6067
t--3, s=2
t=3, s=3 t = 3, s -- 4
t=4, s=2
N o r m a l user sessions not using "site exec"
19439
Normal user sessions
20135
Sequence of all available user simulations
26094
Simulation of user activity on loaded ftp server
26148
t -- 4, s = 3 t -- 4, s -- 4 t=3, s=2 t -- 3, s = 3 t = 3, s = 4 t = 4, s = 2 t -- 4, s -- 3 t -- 4, s ----4 t--3, s--2 t = 3, s -- 3 t = 3, s = 4! t = 4, s = 21 t = 4, s = 3 t = 4, s = 41 t=3, s=2 t 3, s ----3 t ----3, s = 4 t -----4, s = 2i t ----4, s = 3 t---- 4, s = 41 t----3, s = 2 1 t = 3, s -= 3 t ----3, s = 4 t = 4, s ---- 2 t = 4, s = 3 i t = 4, s = 4
2 79 180
2 82 186 9 108 257 10 116 264 9 108 257 10 116 264 11 199 444 12 213 511 11 185 437 12 196 450
3028 1994 1477 3013 1983 1455 9705 6443 4802 9685 6416 4769 10052 6675 4978 10025 6643 4936 13029 8621 6431 12985 8586 6362 13053 8652 6440 13015 8611 6380
2.00 3.00 3.99 2.01 3.02 4.04 2.00 3.00 3.99 2.01 3.01 4.02 2.00 3.00 3.99 2.01 3.01 4.03 2.00 3.00 3.99 2.01 3.01 4.02 2.00 3.00 3.99 2.01 3.01 4.03
0 0 3 0 0 3 0 0 1 0 0 1 0 0 1 0 0 1 0 0 4 0 0 4 0 0 4 0 0 4
T o e v a l u a t e t h e risk o f n o t d e t e c t i n g a n a t t a c k , 4 T a b l e 2 s h o w s t h e n u m b e r o f v a l i d s e q u e n c e s o f six a u d i t e v e n t s t h a t c a n b e c r e a t e d o u t o f t h e t a b l e (six is t h e r e b e c a u s e o u r T = 7). T h i s is t h e m o s t o b v i o u s m e a s u r e , b u t it d o e s n o t a c c o u n t for t h e full risk, as a n a t t a c k c o u l d b e t h e c o m b i n a t i o n o f l e g i t i m a t e s e q u e n c e s w i t h s h o r t illegal ones. T h e t a b l e c l e a r l y s h o w s t h a t a s m a l l i n c r e a s e in t h e l e n g t h o f t h e p a t t e r n d r a m a t i c a l l y r e d u c e s t h e d e g r e e s o f f r e e d o m in t h e t a b l e , a n d we c o n s i d e r t h i s a v e r y i m p o r t a n t r e s u l t . Also, t h e t e c h n i q u e u s e d t o 4 B y this, we denote the possibility of r u n n i n g an attack t h a t would create a new sequence of audit events w i t h o u t being detected. This is possible if t h e new sequence consists of subsequences t h a t are valid, i.e. t h a t are present in the reference table.
10
Hervd Debar et al. T a b l e 2. Statistics on fixed-length tables Technique Size of Size of and size table patterns t--3, s=2 87 {1,2}
it.- 3, s = 3
114
t=3, s=4
152
it=4,s=2
86
t-----4, s = 3 113 t----4, s----4 147
Number oflegitimate combinations oflength < T(6) 1142100 {1,2,3} 11559 {1, 2, 3, 4} 59O {2, 3} 456456 {3, 4, 5} 9905
{4, 5, 6, 7}
143
generate the patterns has a dramatic impact on the number of combinations, as small p a t t e r n s (typically of length 1, potentially generated by the use of technique 3) significantly increase the probability of covering attacks, i.e., of not detecting them. We have also carried out a number of attacks against our ftp server to validate our approach. Table 3 shows our experimentation results for nine attacks. An X in the column indicates t h a t the attack has been detected. Table 3 reveals t h a t three attacks pose a problem to the intrusion-detection system, but for very different reasons. The "put rhosts" attack consists of putting a .rhosts file in the home directory of the ftp user. This vulnerability results from a misconfiguration of the ftp service because this directory should obviously not be world writable. Actually, the "put forward" and the "put rhosts" attacks use the same vulnerability, except t h a t one of t h e m puts a .forward file, and the other one a .rhosts. The first one is detected because our attack script activates the attack by sending a mail to the ftp user, thus triggering the execution of the .forward file by the sendmail daemon. T h e second attack is not triggered, because our attack script does not log on to the attacked machine. Any login a t t e m p t would immediately
T a b l e 3. Experimental results for attack detection Attack description [t=3, s=2[t=3, s=3[t----3, s=4]t=4, s=21t--4 , s=3[t=4, s=41 put forward X X X X X X put rhost site copy X X X X X X site exec copy ftpd X X X X X X site exec copy ls X X X X X X site exec ftpbug ftpd X X X X X X tar exec copy ffpd X tar exec copy ls X X X X tar exec ftpbug ftpd X X X X X X tar exec ftpbug ls X X X X X X
Fixed vs. Variable-Length Patterns for Suspicious Behavior Detection
11
be detected, as a shell would be spawned for the ftp user, and this behavior does not belong to the reference data set. The two "tar exec copy" attacks use the option of G N U tar to specify a compression program that will be used by tar to uncompress the data before extracting it. In our case, we have developed a Trojan horse that does no decompression, but c o p i e s / b i n / s h t o / t m p / . s h as a setuid executable. This attack exploits the fact that some ftp daemons do not release their root privileges quickly enough before forking other processes. Therefore the tar and the Trojan horse both run as root and t h e / t m p / . s h is created suid root. Our Trojan horse is compiled and saved under the name of either ls or ]tpd (hence the code name of the attacks). The attacks are only detected by the more restrictive table of patterns of length 4. We observe that the patterns modeling the normal behavior of an ls process in our reference table are more restrictive than those modeling #pd, as the masquerading of our attack program under the process name "Is" is detected by (t = 4, s = 3) but not the masquerading under the process name "ftpd" with the same pair (t = 4, s = 3). This second case also highlights one of the difficulties of this intrusiondetection technique: the reference data set must be truly restrictive and exhaustive, so that the patterns can faithfully represent the information. In our case, tar is not a command that is tested by the test suites we use to generate the reference data set, as it is not considered to be strictly related to ftpd. We have added some examples of usage of the tar command to our reference data set, but forking commands is a legitimate behavior of the tar command, and both the ftpd and ls patterns cover the execution of our Trojan horse. Lowering the threshold L would improve detection using the smaller reference tables, but it would also increase the false alarm rate.
4
4.1
Generating
Variable-Length
Patterns
Rationale for Variable-Length Patterns
The fixed-length patterns approach yields interesting results, but a careful look at the sequence of audit events shows that there are very long subsequences which repeat themselves frequently. For example, more than 50% of the process images we have obtained start with the same string. This string contains 40 audit events. Therefore, having these very long sequences would better represent our data. This is intuitively correlated by the fact that the ftp daemon answers to commands given by the user, and that each command can probably be represented by a (set of) long sequence(s) of audit events. Therefore, having the capability to extract variable-length patterns from our d a t a makes sense [8]. However, we also are looking for an automated approach. Manual pattern extraction might be feasible for small-scale experiments, but is very time consuming. Therefore, we have looked for a method that will allow us to generate variable-length patterns.
12
Herv6 Debar et al.
4.2
Description of the Pattern-Generation
Technique
A block diagram of the variable-length pattern generator is shown in Fig. 5. It consists of a suffix-tree constructor, a pattern pruner, and a pattern selector. The suffix-tree constructor processes the sample of user behavior as a sequence of symbols, i.e., a string to generate its suffix tree. The well-known suffix-tree structure is a dictionary of all substrings in the string [10]. An example of a string and its corresponding suffix tree are given in Fig. 6.
SUFFIX TREE CONSTRUCTOR
] ]
- ] PATTERN Suffix - I . , PR UNER Tree
] -I I Pattern-I Tree
PATTERN SELECTOR
I [ Reduced Tree
Fig. 5. Variable-length pattern generation
Sample of normal behavior:ACABACBDBABD$ ACBDBABD$
~ACBDBABD$
B
2
B
2
C
2
C
2
~---~BDBABD$ .~ ^ 2 f BD$ 12~CBDBABD$
~
12
12
ABDS
(a) Suffix tree
(b) Pattern tree
(c) Reduced tree
Fig. 6. Pattern extraction
The suffix tree initially consists of only a root. Then all suffixes of the sample string are added one by one until the complete suffix tree is obtained. Note that a "$", representing an end delimiter, is added to the end of the string to ensure that the suffix tree contains one leaf corresponding to each suffix. Every
Fixed vs. Variable-Length Patterns for Suspicious Behavior Detection
13
node corresponds to the substring represented by the symbols on the path from the root to that node. The number next to the node represents the number of occurrences of the substring in the sample string. The pattern pruner prunes the suffix tree in order to generate a tree, referred to as a pattern tree. The pruning is done based on the pruning factor, which is a real number between 0 and 1. This factor is multiplied by the length of the sample of user behavior to obtain a lower limit on the occurrences of patterns. Every pattern with a number of occurrences less than this minimum is clipped, i.e., all its outgoing branches are removed. Fig. 6b shows the pattern tree when the suffix tree is pruned with a pruning factor of 3/12. The number of occurrences of each pattern in the sample string is indicated next to the node corresponding to that pattern. As the branching factor is increased, the suffix tree is pruned more and, hence, the pattern tree contains fewer and shorter patterns. We can use this flexibility to try different sets of patterns and choose the one that results in the most satisfactory detector performance. From the set of pruned patterns the selector removes those patterns that are not required for covering the sample of user behavior. In our example, patterns AB, AC, BA, B D in the pattern tree in Fig. 6c are sufficient to cover the sample of user behavior; patterns C, D are not needed. The selector identifies the needed patterns by processing the sample with a pattern matcher identical to that of the detector. First, it loads the matcher with the set of the pruned-pattern tree and sets all the nodes to not marked. It then performs matching on the sample. For every matched-pattern event generated by the matcher, it marks the corresponding pattern in the pruned-pattern tree. After the entire sample has been processed, the marked patterns are selected as the set of patterns to be used by the detector. Note that currently the matcher used here is different from and much simpler than the matcher of the intrusion-detection system.
4.3
Experimental Results
Using the second test set, we have built three reference tables of patterns. The first reference table contains all the possible sequences extracted from the pattern tree, 5 denoted all patterns in Table 4. The second reference table contains only the sequences going from the root to the leaf in the pattern tree, 6 denoted leaf patterns in Table 4. The last one contains only the sequences going from the root to the leaf in the reduced tree 7 (see Fig. 6c). The statistics for the reference tables are given in Table 4, according to both the kind of reference table and the pruning factor used in the tree generation. The information still has to be compared with the complete number of combinations that we can derive from all the registered pairs (application, audit event) in our intrusion-detection system, which gives 562 9 554 combinations s.
s A, AB, AC, B, BA, BD, C~D in the example in Fig. 6. 6 AB, AC, BA, BD, C, D in the example in Fig. 6. 7 AB, AC, BA, BD in the example in Fig. 6 s In our experiments, we have observed 55 different pairs (audit event, process name); two fictitious events have been added to represent the beginning and end of a process.
14
Herr@ Debar et al. Table 4. Statistics on variable-length tables Reference table pize of table Pruning factor All patterns Leaf patterns Seiected patterns Leaf patterns Selected patterns Leaf patterns Selected patterns
87 82 51 146 74 2i5 80
0.1 0.1 0.1 0.05 0.05 0.02 0.02
Number of legitimate combinations of length < T(6) > 24 * 22 ~ > 21 * 19~ > 13 * 12~
I
> > > >
17 * 165 12 9 115 16 * 14~ 12 9 115
These reference tables actually contain patterns of length 1 to 50. This approach identifies the long sequences we found by browsing the data sets. However, they are actually less restrictive that the ones obtained with fixed-length patterns, owing to the presence of very small patterns. This unexpected result is a consequence of the presence of numerous patterns of length one, along with much longer patterns, in the table. This is the reason we are now working to improve the variable-length pattern tables by introducing a lower limit for the size of the patterns. Lowering the pruning factor results in longer patterns, but the very small ones are still required to obtain a good match, thus the number of legitimate combinations is still very large. We have experimented with these three tables on the normal user behavior, and found that they also do not generate false alarms. Concerning the attacks, we obtain the same results as in the previous section, i.e., the ".rhosts" and "tar exec copy" attacks are not detected.
5
Conclusion
and
Future
Work
In this paper, we have proposed two different families of methods, fixed- vs. variable-length pattern generation, to generate tables of patterns that model the normal behavior of a process. We have also proposed a new paradigm to detect intrusions based on the length of uncovered sequences and relying on a specific pattern-matching algorithm. Based on the results of the experiments run on our testbed, we have shown that the appeal of the new paradigm for both families of patterns (fixed length and variable length) is that it minimizes the false negative alarm rate. We have explained the limitation of the fixed-length pattern approach, namely its inability to represent long meaningful substrings. We have defined a new family of methods based on a suffix-tree representation to obtain variable-length patterns. Preliminary results exhibit their ability to detect real intrusions, but a detailed analysis indicates that they are also more prone to issue false alarms. Further work will concentrate on enhancing the algorithm for variable-length generation of patterns in order to reduce the risk of obtaining false positive
Fixed vs. Variable-Length Patterns for Suspicious Behavior Detection
15
alarms while keeping the good results regarding the true positive rate. Another proposed enhancement is to associate frequencies with the patterns, to customize the intrusion-detection patterns locally by flagging the infrequent use of registered patterns.
References 1. Forrest, S., Perelson, A.S., Allen, L., Cherukuri, R.: Self-Nonself Discrimination. In: Proceedings of the 1994 IEEE Symposium on Research in SeCurity and Privacy. IEEE Computer Society Press, Los Alamitos, CA (1994) 202-212. 2. Forrest, S., Hofmeyr, S.A., Somayaji, A., Longsta.ff, T.A.: A Sense of Self for Unix Processes. In: Proceedings of the 1996 IEEE Symposium on Research in Security and Privacy. IEEE Computer Society Press, Los Alamitos, CA (1996) 120-128. 3. D'haeseleer, P., Forrest, S., Helman, P.: An Immunological Approach to Change Detection: Algorithms, Analysis, and Implications. In: Proceedings of the 1996 IEEE Symposium on Research in Security and Privacy. IEEE Computer Society Press, Los Alamitos, CA (1996) 110-119. 4. Forrest, S., Hofmeyr, S.A., Somayaji. A.: Computer Immunology. Commun. ACM 40 (1997) 88-96. 5. Kosoresow, A.P., Hofmeyr. S.A.: Intrusion Detection via System Call Traces. IEEE Software 14(5) (1997) 35-42. 6. Esmalli, M., Safavi-Naini, R., Pieprzyk, J.: Computer Intrusion Detection: A Comparative Survey. Technical Report 95-07, Center for Computer Security Research, University of Wollongong, Wollongong, NSW 2522, Australia (May 1995). 7. Debar, H., Dacier, M., Wespi, A.: Reference Audit Information Generation for Intrusion Detection Systems. In: Posch, R., Papp, G. (eds).: Information Systems Security, Proceedings of the 14th International Information Security Conference (IFIP SEC'98), Vienna, Austria, and Budapest, Hungary, Aug. 31-Sept. 4, 1998 (in press). 8. Teng, H.S., Chen, K., Lu, S. C-Y: Adaptive Real-Time Anomaly Detection Using Inductively Generated Sequential Patterns. In: Proceedings of the IEEE Symposium on Research in Security and Privacy. IEEE Computer Society Press, Los Alamitos, CA (1990) 278-284. 9. Debar, H., Dacier, M., Wespi, A., Lampart. S.: A Workbench for Intrusion Detection Systems. IBM Research Report RZ 2998, IBM Research Division, Zurich Research Laboratory, 8803 Rfischlikon, Switzerland (1998). 10. Stephen. G.A.: String Searching Algorithms. World Scientific, Singapore (1994).
A Tool for Pro-active Defense Against the Buffer Overrun Attack D. Bruschi, E. Rosti, R. Banff Dipartimento di Scienze dell'Informazione Universit~ degli Studi di Milano Via Comelico 39/41, 20135 Milano - Italy {bruschi, rose}@dsi, unimi, it, roby~psycho, usr. dsi. unirai, it
A b s t r a c t . The problem of buffer overruns, i.e., writing past the end of
an array, in C programs has been known since the early seventies as one of the possible consequences of the C language data integrity philosophy. Since the late eighties, when computer security incidents started affecting the Internet, it has been clear that buffer overruns are a powerful threat to system security as they allow ordinary users to gain superuser privileges on Unix systems. Nowadays, buffer overruns are one of the most popular exploits in the hacker scene. In this paper we present a tool for the automatic detection of buffer overrun vulnerabilities in object code. It can be applied to operating system components as well as ordinary programs. The tool is aimed at helping system administrators eliminate vulnerable programs before they are exploited. A fully working prototype for HP-UX and Linux systems is currently available. Extensions are planned for other Unix versions.
1
Introduction
C o m p u t e r security problems either derive from security unconscious design, such as the vulnerability to eavesdropping or the lack of strong authentication in the T C P / I P communication protocols suite, or from p r o g r a m m i n g and system configuration errors, which, again, m a y depend upon poor design from a security point of view. Attack techniques exploit b o t h security flaw designs and insecure p r o g r a m m i n g practice and errors. Buffer overruns are p r o g r a m m i n g errors t h a t can be exploited in order to gain superuser privileges on a system, leading to what is usually called "root compromise" [6]. Buffer overrun is the effect of writing past the end of an array, or buffer, in C jargon. It is also known as "buffer overflow," because a buffer is stuffed with more d a t a t h a n it can contain. Another popular term used for buffer overrun based attacks is "stack smashing," since p a r t of the process stack segment is overwritten. The problem of buffer overruns in C programs has been known since the definition of the C language itself. In order to improve upon the language flexibility and efficiency, d a t a integrity checks such as bounds checks on array or
18
D. Bruschi et al.
checks on pointer arithmetic are left to the programmer. Neither static nor dynamic checks are enforced at language level thus favoring insecure programming practice. A historical case of buffer overrun is the l o g i n program, whose vulnerability has been known since the late 70's. It was, however, with the Internet Worm in November 1988 that buffer overruns started being exploited for security purposes [17]. Of the three techniques the Worm used to spread to new hosts, one was overflowing the f i n g e r command line argument with an input string of 536 characters instead of 512, which was the size of the input parameter buffer. Since 1988 buffer overruns have become more and more popular on the hacker scene. In 1997, 15 out of 28 advisories 1 of the Computer Emergency Response Team Coordination Center (CERT-CC) of Carnegie Mellon University concerned buffer overrun vulnerabilities identified in commonly used programs and facilities in Unix systems [3]. Many research efforts have been spent in recent years in order to devise solutions to the buffer overrun problem [4, 8,16, 15, 9]. In general, such solutions aim at providing tools for writing programs where buffer overruns are not possible. Yet, they do not offer a solution to the problem of vulnerable existing legacy code and commercial distributions installed world wide. In this case the only defense against possible attacks is the prompt update of the software with new releases or patches. In spite of the increasing computer security awareness, it is not common to find promptly updated systems where new releases or patches are installed as soon as they become available. Being able to automatically detect programs that are vulnerable to buffer overrun attack before they become known to the hacker world would greatly improve system security. This is the perspective from which we have addressed the buffer overrun problem in this work. Specifically targeting executable programs, we have developed a tool that automatically detects buffer overrun vulnerabilities in object code. The tool searches the file system for critical programs and tests them individually against buffer overruns. For the vulnerable ones the exploit is built and executed against the program. A notice is then sent to the system administrator, reporting the found vulnerability. Our tool can be applied to operating system components as well as system utilities and ordinary programs. A fully working prototype for HP-UX and Linux systems is currently available. Extensions are planned for other Unix versions. This paper is organized as follows. Section 1 illustrates the factors that make buffer overrun attacks possible. Section 3 sketches how to craft an attack. Section 4 presents the tool we developed. In Section 6 solutions proposed in the literature are presented and discussed. Section 7 summarizes our contribution and concludes the paper.
1 Buffer overrun related advisories in 1997 only are numbers 2, 4, 5, 6, 9, 10, 11, 13, 17, 18, 19, 21, 23, 24, and 26.
A tool for pro-active defense against the buffer overrun attack 2
General
19
Background
In this section we provide an overview of the factors that make a language issue such as buffer overruns a security issue, i.e., Unix access control scheme, C language data integrity philosophy, and function execution model. We assume a 4.4 BSD system as reference. However, we keep our description general enough to apply to other Unix versions. For further details, see [11, 1, 10].
2.1
U n i x Access Control S y s t e m
The Unix operating system implements a discretionary access control system. Users are allowed to grant and revoke access rights on the objects they own. Such objects are typically files (or directories) and processes. File protection is implemented by a three-level access control mechanism. Access rights are specified for the owner of the file, for the group the owner of the file belongs to, and everyone else, i.e., the rest of the world. For each of the three categories, read, write, and execute permissions are specified. Three additional bits, called suid (set user identifier), sgid (set group identifier), and sticky bit, apply to executable files and specify processes run time privileges. In particular, the suid and sgid bits allow a process to be granted additional privileges during execution. A process privileges are those of the user and group owning the process and are inherited from the parent process at process creation time. Both the user and the group identifiers associated with a process are actually double, as Unix distinguishes between the real and the effective uid and gid. The real uid of a process, known as ruid, is the uid of the user executing the program (i.e., the owner of the process). The effective uid, known as euid, is the uid of the owner of the program. The same applies to the gid. A confined environment is created where privileged programs have their scope limited to that of the user executing them. However, it may be necessary for a process to access objects for which it has no privileges while the program owner does. A mechanism for granting temporary privileges is implemented with the suid (sgid) bit and the s e t u i d ( ) ( s e t g i d ( ) ) system call. When a setuid program (i.e., a program with the suid bit on) executes the s e t u i d ( ) system call, the process ruid changes to euid. The program owner's file system privileges are granted to the executing process for the time the ruid remains set to that of the program owner. The setuid (setgid) mechanism is particularly dangerous when the program owner is root, as the process is granted all the superuser privileges [2].
2.2
Function Call E x e c u t i o n M o d e l
When a program is executed, its process image is allocated an address space organized in three parts, text, data, and stack segments, as illustrated in Figure 1.
20
D. Bruschi et al.
A read-only static m e m o r y area starting at low addresses 2 is allocated for the text segment, which might be shared by multiple users executing the program. Immediately above the text segment, the d a t a segment is divided into initialized data (i.e., the statically allocated data) and uninitialized d a t a (i.e., pointers to dynamically allocated data, bss in Figure 1). T h e d a t a segment can be modified by and is private to each process. D a t a allocated at run time using variables in bss occupy the space above the d a t a segment, called heap. The heap grows towards bigger addresses. Starting at high addresses and growing towards lower ones, the user stack segment occupies a contiguous set of m e m o r y locations organized in Last-In-FirstOut order. The stack organization is used as it matches the natural sequence of function call activation records. W h e n a function is called, a new stack frame process in memory high addresses per-process kernel stack red zone user
area
ps string structure signal code ~x
env strings
x
argv strings env pointers
x
shell environment variables command line arguments
argv pointers J
argo
s
user stack program in secondary storage
linke~header heap
I magic number symbol table
bss
initialized data low addresses
text
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
f
__~
Fig. 1. The user memory address space.
is pushed onto the stack and d a t a saved in fixed locations by the function prologue, an operating system component that prepares the function environment 2 The allocation depicted in the figures, although common to many modern architectures, is an implementation convention. The same is true for the specific values at which each segment starts. Therefore we do not indicate any value, as it is irrelevant to our description.
A tool for pro-active defense against the buffer overrun attack
21
for execution. At function return, the previously saved environment is restored by the function epilogue. The return address is loaded in the program counter, the saved stack pointer is loaded in the stack pointer register, and the saved frame pointer is loaded in the frame pointer register. The rest of the frame is then popped and the freed area used for future calls. 2.3
C Language
The C programming language is often considered a high level assembly language because of its flexibility and efficiency [10]. These characteristics derive from lack of type checking on data structures, no boundary checking on arrays, pointer arithmetic, automatic type conversion, and unstructured control statements such as goto or break/continue for interrupting loops. By minimizing type checking and allowing type conversion, variables can be assigned any values, as long as they fit in the allocated space, and flexibility achieved. Lack of bounds checking at run time when dealing with arrays or buffers improves upon execution time as array accesses are faster. Data integrity checks are intentionally left to the programmer. Therefore, when no program level bound checks apply, it is possible to write past the end of an array without causing errors unless private areas are accessed. Furthermore, standard C libraries implementing string manipulation functions, such as s t r c p y ( ) , and i n p u t / o u t p u t operations involving strings, such as g e t s (), do not check the array size they manipulate 3. Most of the buffer overrun attacks are based on such a well known yet overlooked flaw.
3
The Attack
The setuid mechanism adopted in Unix in order to temporarily enhance the privileges granted to an executing process together with the C programming language data integrity features become critical from a security point of view when combined with the process memory execution model. Detailed descriptions of how to write an attack have appeared to which the interested reader can refer [13, 12, 14]. The general scheme of an attack is the following. A string containing the object code of the system call execve ( "/bin/sh", NULL)4,which executes the shell command interpreter/bin/sh, is passed to the program instead of one of its input parameters. The malicious string has been crafted so as to overwrite the return address of the function that operates on it, which is saved on the 3 For some of the functions in these libraries, safe replacements exist, such as strncpy(), that control the number of bytes written into arrays. However, the good programming practice that suggests the use of such replacements cannot be enforced, thus leaving chances for continuous new exploits. 4 The object code of the execveO system call can be obtained by disassembling the code of a program executing such a system call with the proper parameters.
22
D. Bruschi et al.
stack, with the string starting address. When the function terminates, it will execute the shell code instead of returning to the calling environment. The critical aspect of this scenario is" the set of privileges the process is executing with when the buffer is overwritten. 'If'the process is setuid to root and is executing with root privileges when~the buffer overrun occurs, the shell is a root shell and the machine may suffer a~root._eompromise. In case the program is setuid to a different user than root, it is still dangerous as the spawned shell may operate on the user's files. 4
Buffer
Overrun
Detector
As shown before, the risks of buffer overruns are so serious to justify pro-active defenses. Two strategies are possible. On the one side, compiler patches that aim at producing safe code where the problem may not occur can be developed. The problem is solved by removing it "ab origine," i.e., from the source code. However, the problem of buffer overruns in programs for which no source code is available is not addressed. Several solutions have been proposed that follow such an approach. They will be discussed in Section 6. On the other side, various types of operating system or library patches that aim at making the buffer overrun harmless can be developed. Ad hoc operating system patches that prevent the exploitation of the overrun at system level are a suitable solution only if the operating system source code is available. When this is not the case, there is no other solution than to identify and fix vulnerable programs individually. In this section, we present a solution along this direction. We developed a tool, Buffer Overrun Detector, for the automatic pro-active detection of buffer overrun vulnerable programs. It is a pro-active tool as vulnerable programs are searched for before their vulnerability is exploited. The tool identifies critical programs in a system (i.e., setuid programs owned by the superuser) and systematically tests them for buffer overrun. When all the conditions are met, the tool keeps trying until the program is exploited and a root shell is spawned. A list of vulnerable programs is obtained. Appropriate actions such as local development of patches, disabling programs or stripping the suid bit, can then be taken by the system administrator. The tool consists of a set of shell scripts and C programs. It can be executed as a background process after the system has been installed. The tool operates in three phases: search for critical programs, search for segmentation violation, and construction of the exploit. Portability to different architectures is limited by the characteristics of the architecture vulnerable programs are executed on. Depending upon the stack frame layout and variable allocation convention, the tool must be adapted to take such variants into consideration. The final version of the tool is planned to incorporate system specific variants, extending the baseline prototype currently available for HP-UX and Linux to Sun Solaris and SGI Irix platforms. We describe each phase in what follows.
A tool for pro-active defense against the buffer overrun attack
4.1
23
Finding Critical Programs
For the buffer overrun attack to be really effective, it should be performed against setuid to root programs. In the first phase, the list of setuid to root programs is compiled. The file system is searched for all files owned by root and for which the permission scheme indicates that the setuid bit is on. Of all the found programs, those that accept input parameters or access environment variables in an uncontrolled mannered are then identified. Command line arguments separated by distinct options are a typical way of passing input parameters to programs. For each entry of the list of setuid programs, command line options are analyzed. Information is gathered by parsing the corresponding manual page, if there is one. When manual pages are not available, e.g., for locally developed programs, the option list must be constructed manually by direct inspection. The same applies to environment variables programs might use. When the command line argument buffers are too small to contain the shell object code, environment variables are the alternative destination to inject it. A configuration file is under construction that contains all the options and relative arguments for each setuid program found on a particular system. Introducing such a file, although some adjustments may be necessary depending upon the specific system configurations, would eliminate the overhead of repeated manual page parsing.
4.2
Searching for Segmentation Violation
The second phase identifies candidates for buffer overrun attacks among the programs selected in the first phase. The program characteristic that the attack exploits is the lack of controls on the size of the input parameters or of the environment variables. Programs that do not control the size of their input cause a segmentation fault when exceedingly large values are given to input parameters or environment variables. In order to understand how segmentation violation errors caused by writing past an array can be exploited, consider the example in Figure 2(a). It depicts the user memory map for the simple program shown in the figure, when executing on a Unix like system, before the instruction ",b = a; " is executed. The program counter contains the address of the next instruction to be executed, namely the address of "*b = a; " . The frame pointer points to the beginning of the local variable area for my_function in the user stack and the stack pointer points to the top of the stack. The frame (stack) pointer saved on the stack contains the previous frame (stack) pointer value. The return address contains the address of the instruction to be executed after returning from my. f u n c t i o n ( i , &j, s t r i n g ) , i.e., instruction j = i. Note that, for alignment reasons, the array bur 1 actually occupies eight bytes instead of six. The actual parameters have also been assigned the respective values, which are shown on the right hand side of the corresponding locations. By executing the function s t r c p y (bur 1, buf), the string "buffer overflow!!!!" will be copied into bur 1. Since the function s t r c p y ()
24
D. Bruschi et al.
keeps copying characters until a null character is found, without checking the number of characters being copied, copying "buffer overflow!!!!" into b u l l will overwrite the saved frame and stack pointers and the return address, as shown in Figure 2 (b). The stack locations bur i through the return address included define what we call the "exploitable area", i.e., the area where the exploit code must be loaded. W h e n my_funct• returns, instead of the correct instruction "j = • ;",
user process in m e m o r y
high addresses
high addresses env pointers
env pointers argv pointers argc
.r
P!\O low ! verf er o buff
4 stung
*buf a
\
argc Itl\O
}
low!
void main() { char string = "buffer overflow! ! !t"; int i, j;
,
i=5; j=8; imY-functl~ i;
" J t /
*b
i t
4i
= a; strcpy(bufl, buf);
5
f
argv pointers
void my_function(int a, int *b, char *buD{ char bufl [6];
&j' string);
i ! i i
5
j *buf
,,
stack pointer frame pointer
a
/"
,,-"
/'t
fraine pointer
[
~\,
---.~ prngr~cou.ter [
remm address
.............
~
stack pointer
5
!!!\0
stack pointer
low!
frame pointer
veff er o buff
buff
bufl
8 " ~t; " rJ
*b
5
return address
ero
buff
i
,4~}
verf
stung
]
/ heap
heap
bs$
bss
initialized data
initialized data text at function call
(a)
low addresses
low addresses
text after strcpyO, at function retrun
(b)
Fig. 2. The user process execution stack before executing the instruction ,b = a (a) and after the execution of s t r c p y ( b u f l , buf) (b) that overwrites the array bull. Variable content appears on the right hand side of the corresponding memory location.
the system will try to execute the instruction pointed to by the current return address, i.e., 0x21212100, the hexadecimal value of the null terminated string "!]!". Since such an address is out of the process instruction address space, a segmentation violation occurs and execution is aborted. However, if the value were a legal address, execution would proceed, possibly terminating with an "illegal instruction" error message if the content of that address is not a legal instruction. If the return address could be modified so as to point to an executable piece of code, that code would be executed with the process current privileges.
A tool for pro-active defense against the buffer overrun attack
25
A legitimate value for the return address is the address of the array that will be overwritten. The program will jump to the array and, if the array has been overwritten with a piece of object code, the process will execute that code instead of the original program. However, when the source code is not available, the address of the buffer and the size of the exploitable area on the stack are not known and only guesses are possible. Based on the scheme just illustrated, the tool tries to overflow the command line argument buffers. For each program in the list produced in the first phase, large input parameters are tried for each option and environment variable. When a segmentation violation message is obtained, there are good chances that the program be vulnerable. Programs that cause a segmentation fault are passed to the third phase. We currently adopt a brute force approach to test all options. This way we are guaranteed not to discard vulnerable ones. Such a brute force approach is susceptible of improvement, based on heuristics for parsing the option list and their description. Non-exploitable options could be safely trimmed without risking to overlook chances of attack. Although performance is not an issue for our tool, as programs are tested off-line, analyzing the list of setuid programs of a system can be a lengthy process. Optimizing the analysis phase while guaranteeing that no vulnerable cases are discarded is desirable.
4.3
Exploiting Segmentation Violations
A segmentation violation is a necessary but not sufficient condition for successful buffer overrun attacks. The reason is that the buffer to be overwritten must be large enough to contain the malicious executable code. Furthermore, the address of the stack location of the return address of the function writing the buffer and the new value to write in it are critical for the successful completion of the attack. Determining such values for the programs selected in the second phase and exploiting them is the objective of the third phase. Since our tool operates exclusively on object code, guessing strategies have been devised. The size of the exploitable area (the buffer to be overwritten and the contiguous locations up to the return address), the location of the return address, and the new value to load in it depend upon the program being exploited and the system on which it is executed. T h e y can be easily obtained if the source code is available. Details about the system architecture the code is executed on are also necessary, e.g., the user stack start address, the stack layout (i.e., relative positions of function actual parameters, return address, stack and frame pointers, and local variables), the maximum per process stack size (i.e., the smallest memory address feasible as a stack location), memory addressing scheme, alignment convention, and system call details. Most of the above parameters are strictly implementation dependent and hardly, if not at all, available as written documentation. Some were gathered by examining other programs, namely the stack start address, the amount of information pushed onto it when a program is loaded. A test program was used to derive the exact layout of a function
26
D. Bruschi et al.
stack frame, as it is the same for all programs on a given system. Based on such information, we derive the most critical parameters we need to exploit the code. F i n d i n g t h e stack l o c a t i o n c o n t a i n i n g t h e r e t u r n a d d r e s s For each critical option or environment variable identified in the second phase, the object program is executed under the tool control. Child processes are forked by the tool, which execute the program with increasingly bigger arguments, until a segmentation violation signal is received. By handling the child signals, the parent process knows what the object program execution status is. A default buffer size (or equivalently argument size) of 1000 bytes is initially assumed (user defined values passed as command line arguments of the tool are also possible). The first time a segmentation violation signal is received, an upper bound on the size of the buffer to be overflown is found. The range determined by such an upper bound and the largest buffer size that did not cause any signal (possibly the default buffer size) is explored. The minimum argument size that causes a segmentation fault signal, min is found in a dichotomic fashion. For the exploitable area to be complete, the location of the return address must be determined. A new sequence of executions is started with argument size equal to min, increasing it by one word at a time. The return address is eventually overwritten. When this happens, the system attempts to execute the instruction pointed to by the modified return address. An "illegal instruction" signal is generated if the value written in the return address is out of the program scope. This is easily obtained by appropriately crafting the program argument value (e.g., a string of A's would be sufficient). Thus an "illegal instruction" signal means that the return address has been found. At this point the exploit can be crafted as the size of the area to be overwritten, the exploitable area, is known. The executable code for the execution of a shell command interpreter is injected at the end of a buffer of such a size, padding the initial part with NOP instructions. F i n d i n g t h e n e w v a l u e f o r t h e r e t u r n address The last piece of information for the exploit to work properly is the value to load into the return address. The critical observation that allows us to derive the initial guess for the value to toad into the return address is that all of the programs on a given system are executed within the same memory address space, as the one depicted in Figure 1. Since in many Unix systems the highest stack address is 0 x T f f f f f f f , with a simple brute force approach all the legal addresses 5 smaller than 0 x T f f f f ~ f f become potential candidates for the value of the return address. T h e object program is executed by child processes under the tool control, trying the sequence of return address value candidates. Experimental results have shown t h a t an initial guess that optimizes the search is represented by the address of the a r g v variable of the We simplify here the discussion, assuming the entire address space starting at the highest address is accessible to the user. The fact that this is not true in reality is simply an implementation detail. Test programs can be used to determine the first, i.e., highest, user accessible address.
A tool for pro-active defense against the buffer overrun attack
27
tool itself. Such a value is obtained with the simple instruction aargv. Note that, among the command line arguments of the object program, which are placed at the top of the stack when the program is executed by a child process under the tool control, is the exploit code crafted before. Since the overall size of the tool arguments and the overall size of the object program arguments is usually different, two threads of execution are spawned that search the addresses below and above the address of argv, respectively. Either one will eventually find a correct value. Such a value is appended at the end of the exploit buffer, after the executable code, so as to overwrite the return address of the function operating on the exploited buffer.
5
A Case Study
In this section we illustrate a successful execution trace of our tool on a program available in the HP-UX operating system 6. The program was found by executing phases 1 and 2 on the set of programs comprised in the standard distribution. As mentioned in the previous section, we have to determine the location of the return address of the function operating on a buffer without controlling its size, and the value to be written in the return address. The object program is executed using the default buffer size (i.e., 1000 bytes) and specifying the option to be exploited. The following command line is executed: rose 9 The c o m m a n d
it [~/tmp] >./BOD /usr/bin/XXX/YYYY
-o -ZZZZZ
n a m e and its option are sanitized for obvious reasons. -o is the
tool option that indicates that the program/usr/bin/XXX/YYYY uses the option -ZZZZZ.
After 9 executions, trying the sequence of buffer sizes 1000, 1500, 1250, 1125, 1063, 1094, 1079, 1072, 1075, a S e g m e n t a t i o n V i o l a t i o n signal is received by the tool for the value 1075, i.e., the minimum buffer size that causes the segmentation fault. The argument size is now increased by one at a time, until an I l l e g a l I n s t r u c t i o n signal is received. This occurs after 5 steps, for buffer size equal to 1080 bytes. At this point, the buffer argument is crafted such that a sequence of NOP's is terminated by the executable code for a shell command interpreter. We use the code for the system call e x e c v e ( " / b i n / s h " , NULL). The buffer argument obtained is the following: NOP NOP . . .
NOP \ x 3 4 \ x 1 6 \ x O 5 \ x O 6 \ x 9 6 \ x d 6 \ x O 5 \ x 3 4 \ x 2 0 \ x 2 0 \ x O 8 \ x O 1
\xe4\x20\xeO\xO8\xOb\x5a\xO2\x9a\xe8\x3f \xlf \xfd\xO8\x21\xO2\x80 \x34\xO2\xO l\xO2\xO8\x41kxO4\xO2kx6Okx40\xOl \x62\xb4\x5akxO I\x54 \xObkx39\xO2\x99\xOb\x18\xO2\x98\x34\x16\xO4\xbe\x20\x20\xO8\xOl \xe4\x20\xeO\xO8\x96\xd6\xO5\x34\xde\xad\xcakxf e/bin/sh 6 W e omit here all the details relative to the O.S. release, the architecture, and the
vulnerable program, for obvious reasons.
28
D. Bruschi et al.
Now the program is executed in oder to find the value to load in the return address. The return address is added at the end of the buffer, starting from the value 0x7b03a4b0, i.e., the default argv address. After 30 steps, when the return address is 0x7b03a528, a super user shell is spawned (the # sign in the output below). During the execution, the following sequence of messages is obtained: ILLEGAL INSTRUCT. addr: 0xYb03a4b4 length: 1080 WIFSIGNALED(foo) 1 ILLEGAL INSTRUCT. addr: 0xTb03a4b8 length: 1080 WlFSIGNALED(foo) 1 ILLEGAL INSTRUCT. addr: OxTbO3a4bc length: 1080 WIFSIGNALED(foo) i ILLEGAL INSTRUCT. addr: OxTbO3a528 length: 1080 WIFSIGNALED(foo) I #
The execution time of the third phase as described is 7.2s. We then reran it by specifying the tool option for the return address as 0x7b03a528 and the value 2000 as buffer size. Both the buffer size search and the return address value are significantly accelerated. The total execution time of phase three in this case is 2s. Measurements of the third phase execution times for other programs confirm that it usually requires in the order of tens of seconds.
6
Existing Solutions
Several solutions have appeared since the buffer overrun problem has become a security issue. However, none of them has completely succeeded in removing the problem from the computer scene, as the only definitive solution is writing safe code that performs all the necessary data integrity checks on input arguments and data and uses safe library functions. Unfortunately, such a practice cannot be enforced. Alternatively, strongly typed languages could be used as they do not allow liberal variable manipulation. Adopting a type safe language represents a pro-active solution whose cost is reduced flexibility and efficiency of the generated code and applicability limited to new programs, as existing one should be rewritten. Language implementation problems may, however, affect a security consciously designed language, as is the case with Java [7, 5]. An overview of the approaches followed by the various solutions is presented in the next sections. Potential drawbacks in terms of security, performance, compatibility and portability are considered.
6.1
Compiler Patches
Compiler patches are meant to add compile time bounds checks for array operations and, where possible, run time checks on pointer manipulation to ensure that legitimate storage regions only are accessed. This approach guarantees that new and old programs, for which source code is available, will generate safe code when compiled. Two major issues relative to performance and compatibility are raised by this approach. Static checks performed at compilation time may slow down compilation time of a factor of two to three times. Performance penalties
A tool for pro-active defense against the buffer overrun attack
29
introduced by run time checks are usually much more severe as they can be of the order of few tens or more, depending on the memory access characteristics of the programs. Compatibility issues derive from possible modifications of the representation of pointers needed to perform the run time checks. A patch for the gcc compiler has been developed at Imperial College [9] that performs full static checks on arrays and run time checks on pointers. The authors report twofold to threefold increase in compilation time, depending on the type of source code, and up to a thirty times increase in execution time. Another set of compiler oriented solutions introduce integrity checks on memory accesses a n d / o r function return [8, 4]. Because of the slow down imposed on execution time, software oriented solutions can be used as debugging tools. Only hardware oriented solutions such as ElectricFence can be used in production code as they introduce negligible overhead. In [8], memory accesses are instrumented to perform integrity checks on the accessed area. Execution time slow downs of up to a factor of 5 times that of optimized code were measured. Two compiler extensions are proposed in [4]: StackGuard, for efficient protection of the return address with limited security guarantee, and MemGuard, for secure protection of all critical memory accesses at the expenses of performance. StackGuard prevents buffer overruns by introducing an extra word before the return address, whose value is checked at function return with minimum overhead. If the value is modified, a buffer overrun attempt is detected and execution stops. MemGuard implements an API for protecting memory accesses. The return address cannot be modified by overwriting a nearby array as it can only be accessed via such an API. Unfortunately, because the granularity of the protection is at memory page level, the authors report that writes to unprotected words in protected pages can cost up to 1800 times the cost of unprotected words in unprotected pages. 6.2
L i b r a r y Patches
A set of architecture specific library patches have been proposed for FreeBSD [15]. Assembly coded integrity checks on the user stack of dangerous C library functions such as s t r c p y ( ) are implemented. The performance impact is less serious than with compiler oriented solutions, as the changes only impact library functions execution. On the other hand, since user defined functions are not subject to integrity checks, this solution does not guarantee program absolute safeness. Because it is coded in assembly language, its portability is limited. 6.3
O p e r a t i n g System Patches
Based on the observation that one of the conditions for buffer overrun exploits to be effective is that the stack be executable, a different approach was taken in [16]. A patch for the Linux operating system was developed to make the stack non-executable. This way, overwriting arrays with object code to which the
30
D. Bruschi et al.
program is forced to jump becomes ineffective, as such code cannot be executed 7. The main advantage of such a solution is program protection at no cost either in execution time (no overhead is introduced) or at compilation time (no recompilation is needed for the programs to execute safely). However, the kernel has to be patched as signal handling in Linux relies on executable stack, gcc relies on executable stack for trampoline functions, and functional languages need executable stack for run-time code generation. Furthermore, the solution is not portable and can be applied only if the operating system source code is available.
7
Conclusions
In this paper, we presented a tool for the automatic detection of programs vulnerable to the buffer overrun attack. Target of our tool is all the existing object code for which sources are not available, like commercial distributions of operating systems and applications. The tool is pro-active as it assists the system administrator in verifying the system security before vulnerabilities are found and exploited by hackers. It comprises a set of shell scripts and C programs which can be executed as a background process, after completing the system installation. Portability to various systems is limited only by the specific architecture features based on which the buffer overrun is exploited. A fully operational prototype is available for HP-UX and Linux platforms. Details relative to other major Unix versions are being added.
Acknowledgments The authors are grateful to Roberto Banff, who implemented the tool.
References 1. Bach, M.J.: The design of the Unix operating system. Prentice-Hall International Series, 1986. 2. Bunch, S.: The setuid feature in Unix and security. Proceedings of the lOth National Security Conference, 1987. 3. Computer Emergency Response Team Coordination Center: ftp://ftp.cert.org/pub/advisories, Carnegie Mellon University. 4. Cowan, C., Pu, C., Maier, D., Hinton, D., Walpole, J., Bakke, P., Beattie, S., Grier, A., Wagle, P., Ziang, Q.: StackGuard: automatic adaptive detection and prevention of buffer-overflow attacks. Proc. of the 7th USENIX Security Symposium, 1998. 5. Dean, D., Felten, E.W., Wallach, D.S.: Java security: from Hot Java to Netscape and beyond, Proc. of the IEEE Symposium on Security and Privacy, Oakland, 1996. 6. Garfinkel, S., Spafford, E.: Practical UNIX and Internet Security. O'Reilly and Associates, 1996. 7 This does not protect against attacks that use heap allocated or statically allocated memory to inject the executable code.
A tool for pro-active defense against the buffer overrun attack
31
7. Gosling, J., Joy, B., Steele, J.: The Java language specification. Addison-Wesley, 1996. 8. Hastings, R., Joyce, B.: Purify: fast detection of memory leaks and access errors. Proc. of the Winter USENIX Conference, 1992. 9. Jones, R., Kelly, P.: Bounds checking for C. http://www-ala.doc.ic.ac.uk/phjk/BoundsChecking.html, July 1995. 10. Kernighan, B.W., Ritchie, D.M.: The C programming language. 2nd Ed. PrenticeHall Software Series, 1988. 11. McKusick, M.K., Bostic, K., Karles, M.J., Quarterman, J.S.: The Design and Implementation of the 4.4BSD Operating System. Addison Wesley, 1996. 12. Mudge: How to write buffer overflows. http://www.10pht.com/advisories/bufero.html 1997. 13. One, A.: Smashing the stack for fun and profit. Phrack Magazine 49, Fall 1997. 14. Smith, N.P.: Stack smashing vulnerabilities in the UNIX operating system. http://millcomm.com/nate/machines/security/stack-smashing/1997. 15. Snarskii, A.: FreeBSD Stack integrity patch. ftp: / /ftp.lucky.net /pub /unix/local /libc-letter, 1997. 16. Solar Designer: Non-Executable user stack, http://www.false.com/security/linuxstack/. 17. Spafford, E.: The Internet Worm incident. Proc. of the European Software Eng. Conference, pp 203-227, 1989.
A Kernelized A r c h i t e c t u r e for Multilevel Secure A p p l i c a t i o n Policies Simon N. Foley 1,2 1 University of Cambridge CCSR, Cambridge CB2 3DS, UK. 2 Department of Computer Science, University College, Cork, Ireland. s. f o l e y @ c s , ucc. ie
A b s t r a c t . Mandatory label-based policies may be used to support a wide-range of application security requirements. Labels encode the security state of system entities and the security policy specifies how these labels may change. Building on previous results, this paper develops a model for a kernelized framework for supporting these policies. The framework provides the basis for, what is essentially, an interpreter of multilevel programs: programs that manipulate multilevel label datastructures. This enables application functionality and security concerns to be developed separately, bringing with it the advantages of a separation of concerns paradigm.
1
Introduction
Conventional multilevel secure systems place all trust in the underlying trusted computing base (TCB), regarding most of the operating system and applications software as untrusted [20]. Clark and Wilson [3] argue that security should be defined across both the operating system and applications. Under their model, a secure system may be viewed as a certified application running on top of a trusted computing base (TCB). Certifying an application is analogous to arguing (to a degree) it's correctness according to the application's security requirements; the T C B is expected to have undergone some sort of security evaluation. A problem with this approach is that it encourages an intertwining of the functional and security-critical code that makes up an application. For example, interpreting the original Clark-Wilson model, the TCB is expected to support (enforce) static segregation of duties. However it appears that dynamic segregation of duty must be implemented/intertwined within the application itself [4, 12]. Intertwining makes the application complex and reasoning more difficult since both security and functionality concerns have to be dealt with at the same level of abstraction. We argue that when developing an application the security and functionality concerns of the application must be separated, both at the conceptual level and at the implementation level. At the conceptual level, a loose coupling between concerns facilitates the verification of security, while at the implementation level we want an architecture and programming environment that will support the concerns securely.
34
Simon N. Foley
As a software engineering paradigm, techniques that support separation of concerns for synchronisation, real-time constraints, failures and others have been studied. The reader is referred to [7] for an introduction. One could view policy neutral architectures such as [13, 17] as a step in the direction of providing support for the separation of (security) concerns paradigm. We are interested in supporting separation for multilevel security concerns. In this case, an application developer designs and implements an application in terms of separate security and functionality components. Once the security concerns meet certain verification conditions, an underlying TCB is expected to ensure multilevel security. The dynamic label-based policies proposed in [4, 5] can be used to support this separation. From an object-oriented perspective, labels are used to encode security relevant characteristics of objects and provide relabel functions that specify how the labels may change. Given some functional object, we then argue that it also has an associated security object whose state corresponds to its label and has methods that define how its state (label) may change. This security label object is like a meta-object, providing security details about the information in the associated object. These label-based policies use the Bell-LaPadula model as their underlying access control model and require a special trusted label manager which mediates and interprets requests to update labels. A variety of application security policies can be encoded in terms of label-based policies, including Chinese walls, dynamic segregation of duties and group access policies [4, 5]. It is desirable to have a framework that can support a wide range of labelbased policies. In [5] a model is described that allows any subject to relabel any object label, where the relabel functions meet certain security non-interference style requirements. These secure canonical upgrade policies (SCUP) are supported securely so long as high-level changes may not be detected by low-level subjects. A framework that supports such policies in a message-filter [8] based multilevel secure object store is described in [5]. However, the framework in [5] does not consider how the label manager might be developed in practice. This paper develops a kernelized-based model of the label manager. The paper is organised as follows. Sections 2 and 3 describe the basic model for relabel policies. They are based on [5], but with some minor modifications that make kernelization possible. Sections 4, 5 and 6 give the noninterference analysis, kernelization, and correctness, respectively, of the label manager. A number of state-invariants for the kernelized manager are explored in Section 7; these would contribute towards an efficient implementation. Section 8 discusses the results and contributions of the paper. The Z notation [16] is used to provide a consistent syntax for structuring and presenting the mathematics in this paper. In using Z, it has been possible to check the mathematics using the Z/EVES tool [15]. Appendix A gives a brief overview of the Z notation used in the paper.
A Kernelized Architecture
2
35
D y n a m i c Label Policies
An information flow policy is defined in terms of a partial ordering (_ < _) of security levels (C) which have the usual multilevel interpretation.
_ FlowPolicy[ C] _<_:C++C Vu, v,w : C 9 (u < u) ^ (u<_vAv<_u~u=v) (u<_vAv<_w~u<_w)
A
Security labels (L) are datatypes that are used to encode security relevant characteristics of objects. For example, a purchase order object could have a label indicating that it has been requested, but not yet authorised. In [5] the security label is also used to specify the desired security level of an object. An object's label may change according to relabel functions which form part of the policy. _
RelabelPolicy[C, L, F] FlowPoIicy[ C] 5ca : ( F x C x L ) - - + L
Given a set of relabel function identifiers F, then ~'n(f, s, a) -- b means that an entity at level s may use function f E F to change label a to b. E x a m p l e 1 A simple mark-for-upgrade policy uses security labels to encode details about future upgrade levels for an object. An object label has a format u : - A , where u indicates it's current level and A gives a list of future upgrade levels. For example, the label (u:-[11, t]) of an unclassified (u) object indicates that it should be upgraded to top-secret ( t :-[t]) when an upgrade is requested. A requester at level r invokes the function mark to tag the label with its level (r). Function up upgrades the object's label u : - A to the next level in A. For example, the label ( u : - [ u , t ] ) becomes ( t : - [ t ] ) , when up(u, ( u : - [ u , t ] ) ) is invoked. For the purpose of illustration, Figure 1 gives a fragment of a (Haskell) functional-style prototype of this relabel policy ( p r o j e c t and I n v i s i b l e will be described later) 1. Functions are specified in an equational-style and expression [ v l v < - t a g s , w<=v] is the list of all v that are members of list t a g s and that dominate w. A To determine whether the relabel functions mark and up are secure it is necessary to first define, as part of the policy, how users at different levels view labels. This is defined in terms of label projection, where a user at level v, inspecting label a, actually sees the label b = (a r v). A canonical policy may be 1 This policy is valid only for flow policies that are total orders. A specification of a more general policy can be found in [5].
36
Simon N. Foley ) level:-[level]
data Label level = Invisible
--datatype
for label
mark(req,(u:-tags)) I (u<req) I otherwise
--level req request marks label (u:-tags) = u:-(req:tags) --hi may mark io label = u:-tags --no change in label
up(req,(u:-tags)) # req
= (u:-tags)
i otherwise where newtags
--level req request upgrades (u:-tags) = (minimum newtags):-newtags = Iv #v<-tags,u
p r o j e c t ((u : - t a g s ) , v)
- - l a b e l ( u : - t a g s ) , as seen from level v
(u:-[wIw<-tags, w<=v])
lu<=v
=
I otherwise
= Invisible
Fig. 1. Sample Relabel Policy Prototype
thought of as a relabel policy that has a view-equivalence relation a r v = b r v (in the non-interference sense) defined over its labels. By default, there is a special label that is used to represent label projections that are invisible.
_ CanonicalPolicy[C, L, F] RelabelPolicy[ C, L, F] _t_:L• C-~ L invisible : L V u : C 9 invisible r u = invisible Vu : C; f : F 9 f74(], u, invisible) = invisible E x a m p l e 2 Continuing Example 1, Figure 1 defines the projection operator for the policy. A user may view only those tags on a label that the user's level dominates. Thus, p r o j e c t ( s , u: -[u, t]) returns label (u: -[u]). If the label is not visible to the viewer, then it is invisible. For example, p r o j e c t ( u , s : - [ s , t]) returns (by label equivalence) the label I n v • /', There are a number of conditions that a canonical policy must uphold in order to be secure. These ensure that a high-level user cannot interfere, in a visible way, with low-level labels. Sections 3 and 5 describe a subsystem for managing labels that is multilevel secure if the canonical policies that it supports uphold these conditions.
i CP_CView[C, L, F] CanonicalPolicy[ C, L, F] Vv, w : C ; a : L e w
A Kernelized Architecture
37
This condition (consistent view) specifies t h a t a user may not test for differences between two labels that are viewed as the same from the projection of the user.
I CP_NWD[C, L, F] CanonicaIPolicy[ C, L, F]
Vf :F; s~v: C; a : L . s _
v ~
a r v = .r~(f,s,a)
r v
This corresponds to the unwound non-interference requirement that a high-level user may not interfere with a low-level view of a label (no write down).
CP_NR U[ C, L, F] CanonicaIPolicy[ C , L, F] VI :F; s,v: C; a : L . 9~n(I, s, a) [ v = .Tn(], s, a [ v) This corresponds to the unwound non-interference requirement that a change in a low-level view of a label may not depend on any high-level information in the label (no read up). This requirement is slightly stronger than that originally specified in [5], but was found to be necessary for the kernelization of the label manager. We have, t h e o r e m CP_NRUprev [C, L, F] V CP_NRU[C, L, F]; f : F; s, v : C; a, b : L *
a [ v = b [ v =~.T've(],s,a) [ v =.Tn(I,s, b) r v A policy that upholds these three conditions is called a secure canonical upgrade policy (SCUP).
SCUP[C, L, F] I CP_CView[C, L, F] CP_NWD [C, L, F] CP_NRU[ C, L, F] E x a m p l e 3 The policy in Figure 1 is overly simplistic and is for illustrative purposes only. The policy described in [5] is an example of a more detailed relabel policy that was designed for the message-filter based model [8]. The scheme supports the relabelling of objects such that, when upgrades are requested, objects are migrated from one (single-level) object store to another. Object migration ensuring referential integrity may be achieved by viewing migration as a multilevel garbage collection [2] problem, or by encoding proxy information [10] in security labels. See [5] for a more detailed explanation. /k 3
Label
Manager
The label manager [5] provides a trusted interface to a SCUP policy. Its trusted operations make up the TCB extension required for standard multilevel secure
38
Simon N. Foley
systems. While it was intended specifically for message-filter based multilevel OODBMS, we believe it to be sufficiently general to be applicable to other systems. Object identifiers are used to uniquely identify objects within an objectoriented database. An object identifier is given as a tuple (u, i), where identifier i uniquely identifies an object at a security level u. Thus, given ID, the set of all identifiers, define OW[C] = = ( 0 • JD)
LabelStore defines the state of the label manager. It is accessed via the operations that make up its programming interface. Each object o : OlD has an associated security label 6(o). C, L] : OID[C] -~ L ~ 6LabelStore[ The label of an object may be changed according to the relabel functions defined in a SCUP policy. This is done by invoking the Relabel operation, where a request is made at level req? to apply the relabel function rfun? to the label of object oid?. _
Relabel[C, L, F] SCUP[C, L, F] A LabelStore[ C, L] req? : C old? : OID rfun? : F if ( o l d ? E dom 6) t h e n 6' = 6 @ {oid? ~ Jrn(rfun?, req?, 6(oid?))} else 61 = 6
The Operation ViewLabel returns, as lab!, the appropriate projection of the label of object oid? when requested at level req?. Note that if the object does not exist then the label invisible is returned; this prevents a low-level user testing the existence of high-level objects.
_ ViewLabel[C, L, F] SCUP[C, L, F] ~ LabeIStore[ C, L] req? : C oid? : Oil) lab! : L i f (oid? E dom 5 A first(oid?) < req?) t h e n lab! -~ (6 oid?) r req? else lab! = invisible
A Kernelized Architecture 4
Security
39
Analysis
Since the actions of the label manager are not mediated by the security kernel we must prove that it is multilevel secure. This is done by using an unwound version of non-interference [6,14] to prove that no series of high-level requests to the manager can interfere with what a low-level, or disjoint-level, user can view. State LabelStore looks the same as state LabeIStore ~, when viewed from security level vl, if the label projections of the objects, whose levels are dominated by vl, are equal. This is formally specified as follows.
_ VEquiv[C, L, F] LabelStore[ C, L] LabelStore'[ C , L] SCUPiC, L, f ] vl: C v o: o w [ c ] I j rst(o) < vl 9 (o e dom(5) ~=~ o E dom(6')) A (o e domSN domS' ~ (f(o) [ vl = 5'(0) [ vl) The first unwinding condition requires that each operation, when requested at a high-level, cannot interfere with a low-level view of the state (No Write Down). We have t h e o r e m Relabel_NWD [C, L, F]
V Relabel[C,L,F]; vl : C 9 -~ (req? < vl) ~ VEquiv[C, L, F] t h e o r e m ViewLabel_NWD [C, L, F] V ViewLabel[C, L, F]; vl : C 9
-1 (req? <_ vl) =~ YEquiv[C, L, F] The second unwinding condition requires that the outcome of an operation, requested at a low-level, cannot be based in any way on the high-level part of the state (No Read Up). We have t h e o r e m Relabel_NRU [C, L, F] V Relabel[C, L, F]; Relabel[C, L, F][5"/5, 5'"/5']; vl : C 9 VEquiv[C, L, F][5"/5'] ~ VEquiv[C, L, F][5"'/5] t h e o r e m ViewLabel_NRU [C, L, F] V ViewLabel[C, L, F];
Viewnabel[C, L, F][~"/5, 5'"/5', lab!"/lab!]; vl : C 9 (VEquiv[C, L, F][5"/5'] A (req? <_ vl)) labl = lab!"
40
5
Simon N. Foley
A K e r n e l i z e d Label M a n a g e r
The message-filter model [8] supports multilevel security in object-oriented database systems according to the Bell and LaPadula (BLP) model [1]. A message filter mediates all message passing between objects such that information may flow according to the information flow relation. These database objects are viewed both as objects and subjects in the Bell-LaPadula model. As objects, they have state, and as subjects, they execute actions by sending messages. Implementation of the message-filter model does not rely on the construction of a special trusted OODBMS: if the message-filter lies within the TCB of a multilevel system, then the remainder of the application can be based on existing and untrusted OODBMSs. The (multilevel) persistent object store is partitioned into a collection of single-level stores (see Figure 2). The underlying security kernel, upholding the usual BLP axioms, ensures that it is not possible for an (untrusted) OODBMS to violate the multilevel policy.
~ I Message Filter
Object Stores ~ '1tOpsecret secret
]unclassified
Fig. 2. Message Filter & Single Level Stores In [5], the label manager runs as a separate trusted-subject servicing requests from objects in the the multilevel object store. Under this approach the entire label store (5) forms part of the state of the manager, and since it is multilevel, it must be protected from direct access by any untrusted object. While its high-level specification (above) has been proven to be secure, an implementation should be constructed in terms of untrusted components (kernelized), if at all possible. A refinement of the label manager is now specified which, given a suitable message filter, can be kernelized in its entirety. The basic strategy is to replicate each label for every level. A relabel broadcasts the request to every replicated label at levels that dominate the level of the request. A request to view returns the value of the label, at the level of the requester. The scheme works so long as broadcasts are implemented in a serializable and secure manner. Section 7 will outline an optimisation to the scheme: in practice it is not actually necessary to replicate at every level. Figure 2 illustrates this replication. In the abstract state the object o : OID has label 5(0) = (u:-[u, t]). In the concrete state (implementation), the label is replicated at every level whereby the replicated value gives that level's view of the label.
A Kernelized Architecture
41
Each replicated label is regarded as a single-level object (of type object label class) contained in a single-level object store. These objects, in turn, provide relabel and view-label methods.
~
LabelStoreO[ C , L] 50 : C x OID[C] -+ L CurrOIDs : ~ OID[C]
For the purposes of modelling this implementation approach, the concrete state is specified in terms of a function 50 whereby 50(u, o) gives the level u copy of o's label. The set CurrOIDs defines the current set of objects Any state may serve as an initial state as long as replicated views are consistent. _
InitialLabelStoreO[ C, L, F] SCUP[C, L, F] LabelStoreO[ C , L] V o : CurrOIDs; u, w : C l u < w .
50(u, o) = 50(w, o) I It turns out that InitiaILabelStoreO also defines a state invariant that is maintained by the concrete relabel and view-label operations. To relabel the label of object oid? a relabel request message should be sent to the replicated copy of the label (represented as 50(req?, old?)) at the level of the requester req?. The relabel function r]un? is applied to this label and the request is also broadcast to every replicated copy of the label whose level dominates req?. This is specified by concrete operation RelabelO. If these label objects are maintained in a multilevel object store then the effect of the relabelling broadcast must be atomic across the single level stores. Thomas and Sandhu [18,19] describe a message-filter based architecture that support write-up in a secure and serializable manner. This means that the broadcast (a write-up) specified in RelabelO can be supported, in theory. The SINTRA replicated database [9] also supports both replication and write-ups and therefore should be capable of supporting the relabelling manager.
_RelabelO[ C, L, F] SCUP[C, L, F] A LabeIStoreO[ C , L] req? : C old? : OID rfun? : F if (oid? e CurrOIDs) thenS~=50@(u: C I req? ~ u
* (u, oid?) ~-+ Jrn(riun?, req?,50(u, oid?)) ) e l s e 5~ = 50
CurrOIDs' = CurrOIDs
42
Simon N. Foley
r Relabel(maxk, s, o)
I~
I topsecret
[
[secret
Relabel(up, u, o)
Fig. 3. Applying Relabel Functions E x a m p l e 4 Figure 3 illustrates the effect of a secret request to mark the label of object o in Figure 2, followed by an unclassified request to upgrade the object. In this figure the migration of o from unclassified to secret, as a result of the upgrade, is also illustrated. How this migration is achieved in practice is considered in [5]. /k At any moment, the value 5o(u, o) gives the view of label o from level u. Therefore, the concrete version of ViewLabel is specified as follows.
_ ViewLabelO[C, L, F] SCUP[C, L, f] ~ LabelStoreO[ C, L] req? : C old? : OID lab!: L if (oid? E CurrOIDs A first(oid?) ~ req?) t h e n lab! = 5o(req?, oid?) else lab! = invisible Thus, to determine the label of an object oid?, the requester simply makes the request to the replicated copy of the object's label at the level of the requester. Note that LabeIStoreO specifies that an object's label is replicated at every level and not just at those levels that dominate the object's level. This may seem surprising, but it is desirable if further restrictions on SCUP policies are to be avoided. Maintaining a low-level version of a high-level object's label means that a low-level user can view :the low-level effects that low relabel requests may have on the high-level object. If this flexibility is not required then low-level views of high-level object labels could, for example, be assumed to be invisible, that is, 5(0) [ v = invsible, where first(o) ~ u. Thus, we always have 5o(u, o) = invisible for first(o) ~ u and it becomes necessary to replicate only the label of o at levels that dominate first (o). In [5], a create label operation is specified which is used to enter a label for a new object in the label store. Its specification and refinement is straightforward;
A Kernelized Architecture
43
we do not include it here for reasons of space. However, we must address, at least in broad terms, the issue of entering new object label details into the replicated label store. Recording a new object label [5] is effectively a m a t t e r of adding tuple ((req?, newid?) ~-~ lab) to 5: a requester at level req? has created a new object with identifier newid? (in the object store at level req?) and wishes to assign it label lab. With the concrete state implementation this is achieved by adding replicated entries {u : C I tea? < u 9 (u,(req?,oid?)) ~+ lab r u } that correspond to a broadcast write-up from level req?. If lab ~ u = invisible for all other levels (req? ~ u) then we are done. However, consider the case where the relabel policy permits low-level information to be encoded in what are, ostensibly, high-level labels. The message-filter will not permit a request at level req? to create a label object at a disjoint or lower level. This problem is easily solved by adapting the RelabelO implementation such that the broadcast upwards will replicate missing labels, assigning them default values that can be specified as part of the policy. 6
Correctness
of Refinement
Since the kernelized label manager is designed to be implemented in terms of untrusted components, with multilevel security enforced by the underlying TCB, it is not strictly necessary to prove that it is secure. However, it is necessary to prove that it is correct. This corresponds to proving that the behaviour of the concrete label manager is consistent with its abstract specification, that is, it is a refinement in the sense of [16]. D a t a R e f i n e m e n t In the kernelized label manger, (f0(u, o) gives the view of label o from level u. In the abstract specification this corresponds to 8(o) r u. Therefore, given any concrete state we can retrieve its abstract equivalent. The abstraction (retrieve) relation relates the concrete and abstract states.
_ Abs[C, L, F] SCUP[C, L, F]
LabeIStore[ C, L] LabelStoreO[ C, L] dom 5 -- CurrOIDs
V o : CurrOIDs; u : C * 6(0) r = 60(u, o) Initial States Theorem. Any state of LabeIStore may serve as a suitable initial abstract state. We can retrieve from any initial concrete state a valid abstract state, that is, t h e o r e m InitialStates [C, L, F]
V InitialLabeIStoreO[C, L, F] 9 3 LabeIStore[C, L] * Abs[C, L, F]
44
Simon N. Foley
Operation Refinement All operations, both abstract and concrete are total, in the sense that they are defined for all possible input values. Thus it is safe to apply a concrete operation whenever it would be safe to apply the same request to its corresponding abstract form. If the label manager is in some concrete state, related to an abstract state by Abs, and the manager moves to a new concrete state as a result of a concrete relabel, then this new concrete state must be related (by Abs) to an abstract that can be reached by an abstract relabel from the original abstract state. This is illustrated in Figure 4, where schema AbsAfter is used to retrieve the abstract after state. Operation ViewLabel has a similar correctness requirement. LabelStore
Relabel
LabelStore ' AbsAfter
LabeIStoreO
RelabelO
~* LabelStoreO'
Fig. 4. Correctness of RelabelO.
AbsA~er[C, L, F] ~ Abs[C, L, F][(i'/(f, ~ / 5 0 , CurrOIDs'/CurrOIDs]
theorem RelabelCorrect [C, L, F] V RelabelO[C, L, F]; Abs[C, L, F] 9 S 5' : OID[C] -~ L 9 AbsAfter[C, L, F] A Relabel[C, L, F]
theorem ViewLabelCorrect [C, L, F] Y ViewLabelO[C, L, F]; Abs[C, L, F] 9 35': OID[C] -~ L 9 AbsAfter[C, L, F] A ViewLabel[C, L, F]
7
Optimisation
We outline an optimisation to the realization of the concrete label manager which, wherever possible, avoids replicating labels. First, we extend the definition of SCUP with the addition of a label join operator (_ | _), where a | b gives a label representing the join of labels a and b. For consistency we assume that joining a lower-level view to a label's higher-level view makes no difference, that is, u < v ~ a r v = (a t v) | (a r u). Assuming a generalised form of the join operator, Q) A, which joins the set of labels A, then the state invariant
V LabeIStoreO[C,L]; v: C; o: OID[C] * ~o(v, o) = Q { u: c I u <_, 9 ~o(u, o) }
A Kernelized Architecture
45
follows, t h a t is, we have a consistency between a view of a label and its lower views. Under certain circumstances it may be possible to compute the view, at level vl, of object vo's label by simply joining those views that are strictly dominated by vl. Define this view-invariant property as
_ Viewlnv[C, L, F] SCUP[C, L, F] LabelStoreO[ C, L] vl: C vo : OID[C]
If this property holds for some vl and vo, the result is that it is not necessary to store a replicated version of object vo's label at level vl, as it can be computed by joining its lower-level views. Thus, when a requester at level req? stores a new label for a new object with id (req?, id?), just one entry (req?, (req?, id?)) ~+ lab) is stored (assuming that lab = lab t req?). Relabelling maintains this view-invariant for views that cannot be altered by the request, that is,
Y RelabelO[ C, L, F]; ViewInv[ C, L, F] 9 -, (req? <_ vl) ~ ViewInv[C, L, F][5~15o] Thus, if vo's label is not replicated at level vl (req? 2~ vl) before the relabelling, it is not necessary to replicate it after the operation (this trivially follows from the definition of RelabelO). However, vo must be replicated at all levels that dominate req?: this allows the relabel to be broadcast correctly. If vo is not currently replicated at level req? then its value is computed from the joins of lower-level views (that exist) and the relabel function applied. Since write-ups are allowed by the relabel policy, a relabelling may modify higher-level views differently to lower-level views. Therefore, the label computed for vo at level req? must be broadcast (with the relabel function) to all levels that dominate
req?. E x a m p l e 5 Consider the policy from Example 1. An unclassified object o has label (u: - [u] ), which is stored in the unclassified object store (no replication). When a top-secret user requests a mark, its top-secret view is computed as ( u : - [ u ] ) , function mark is applied, giving ( u : - [ u , t ] ) , which is saved in the top-secret store. A secret mark request to object o results in the computation of a secret view of the label (u: - [u] ), which is relabelled as (u: - [u, s] ) and stored. This relabel is also broadcast to the top-secret replicated label, changing it to ( u : - [ u , s , t ] ) . ~, The drawback of this scheme is that even with a modest number of relabel requests, it is likely that an object's label will end up being fully replicated. If
46
Simon N. Foley
we limit the relabel policy such that write-ups are not permitted then it is not necessary to replicate when the broadcast is complete.
_ SCUP_NWU[C, L, F] SCUP[C, L, F] s,v:C; a:L. s # v =-~ a I v = Y ~ ( f , s , a ) ~ v
Vf:F;
In our opinion, this does not seem to be overly restrictive and we have,
V SCUP_NWU[C, L, F]; RelabelO[C, L, F]; Viewlnv[C, L, F] * ( req? ~ vl) =~ Viewlnv[ C, L, F][5~/50] In this case, if a label is not replicated at level vl (req? ~ vl) before the relabelling, it is not necessary to replicate it after the operation. A relabelling operation must, if necessary, replicate the label at level req?, and then broadcast the relabel function onto those existing replicated copies. With this scheme, if a object label is not replicated at level req? then the ViewLabelO operation must compute it by joining the object's replicated labels from lower views. If the flow policy forms a lattice then it is possible to define the policy so that the label can be computed by joining labels whose lowest upper bound equals that of the label being calculated (req?).
8
Discussion and Conclusion
The label-based framework may be used to support the separation of concerns paradigm. An application may be developed, at a conceptual level, in terms of functional and security components. The security concerns are modelled in terms of objects or abstract data types: relabel functions (methods) which define how labels (state) may change. These security and functionality concerns may also be separately implemented. In addition to ensuring multilevel security of the functionality concerns, the framework ensures multilevel security and integrity of the security concerns. This framework is based on the Message-Filter model for secure multilevel secure OODBMSs, extended to incorporate a trusted label manager. Section 5 gave a model for its kernelization, relying on a secure and consistent write-up mechanism such as those described in [9, 18]. But our results are not limited to the Message-Filter model, we believe that they could be used in any multilevel secure architecture that supports write-up. The label-manager provides the basis for a multilevel program interpreter. While the policy in Figure 1 is a very simple example of a multilevel program, the framework could be used to support more elaborate security concerns such as those in [4, 5]. An interesting area for future study is to consider how this framework could be combined with recent work on compile-time information
A Kernelized Architecture
47
flow analysis of programs [21,11] so that multilevel data-structures could be supported. These are topics for future study. In one sense, the label manager is like a 'universal' trusted subject: an interpreter of trusted programs (relabel policies). A result of Section 4 is that if the relabel policy is SCUP then multilevel security (confidentiality) is ensured. However, an implication of Section 6 is that any relabel policy can be securely supported by the kernelized manger, but to maintain integrity, it is necessary to prove that the policy is SCUP. We make two interesting observations about this relationship. Firstly, to prove integrity for this system it is necessary to perform what is effectively a non-interference analysis of the policy program. Secondly, if integrity is as critical a requirement as confidentiality then, whether we kernelize or not, we must nevertheless perform the non-interference analysis. We believe that similar observations can be made about any 'trusted' subject.
Acknowledgement This work was done while I was a member of the Centre for Communications Systems Research, on leave from University College, Cork. I'd like to express my gratitude to Stewart Lee for inviting me and thank him, and the members of the Cambridge Computer Security Group, for a most enjoyable visit. Thanks also to the anonymous reviewers for their useful comments. This work was supported, in part, by a basic research grant from Forbairt (Ireland).
References 1. D. E. Bell and L. J. La Padula. Secure computer system: unified exposition and MULTICS interpretation. Report ESD-TR-75-306, The MITRE Corporation, March 1976. 2. E. Bertino, L.V. Mancini, and S. Jajodia. Collecting garbage in multilevel secure object stores. In Proceedings of the Symposium on Security and Privacy, pages 106-120, Oakland, CA, May 1994. IEEE Computer Society Press. 3. D.D. Clark and D. R. Wilson. A comparison of commercial and military computer security models. In Proceedings Symposium on Security and Privacy, pages 184194. IEEE Computer Society Press, April 1987. 4. S.N. Foley. The specification and implementation of commercial security requirements including dynamic segregation of duties. In 4th ACM Conference on Computer and Communications Security, 1997. 5. S.N. Foley. Supporting secure cannonical upgrade policies in multilevel secure object stores. In Proceedings of the 13th. Annual Computer Security Applications Conference, pages 69-80, San Diego, CA, December 1997. 6. J. A. Goguen and J. Meseguer. Unwinding and inference control. In Proceedings 1984 IEEE Symposium on Security and Privacy, pages 75-86, 1984. 7. W.L. Hursch and C.V. Lopes. Separation of concerns. Technical Report NU-CCS95-03, College of Computer Science, Northeastern University, Boston, MA 02115, USA., 1995.
48
Simon N. Foley
8. S. Jajodia and B. Kogan. Integrating an object-oriented data model with multilevel security. In IEEE Symposium on Security and Privacy, Oakland, CA, 1990. 9. M. Kang et al. Achieving database security through data replication: The SINTRA prototype. In Proceedings of the 17th National Computer Security Conference, pages 77-87, Baltimore, MD, USA, 1994. 10. M. Makpangou and M. Shapiro. The SOS object-oriented communication service. In 9th International Conference on Computer Communications, Israel, 1988. 11. A.C. Myers and B. Liskov. A decentralized model for information flow control. In 16th Annual Symposium on Operating Systems Principles. ACM, 1997. 12. M.J. Nash and K.R. Poland. Some conundrums concerning separation of duty. In Proceedings of the Symposium on Security and Privacy, pages 201-207, Oakland, CA, May 1990. IEEE Computer Society Press. 13. D. Olawsky, T. Fine, E. Schneider, and R. Spencer. Developing and using a policy neutral access control policy. In Proceedings of the New Security Paradigms Workshop. IEEE Computer Society Press, 1996. 14. J. Rushby. Noninterference, transitivity and channel-control security policies. Technical Report SRI-CSL-92-02, SRI International, Menlo Park, CA., December 1992. 15. M. Saaltink. The Z/EVES system. In ZUM'97 (lOth International Conference of Z Users), pages 72-85. Springer Verlag LNCS 1212, 1997. 16. J. M. Spivey. The Z Notation: A Reference Manual. Series in Computer Science. Prentice Hall International, second edition, 1992. 17. D.F. Sterne, G.S. Benson, and H Tajalli. Redrawing the security perimeter of a trusted system. In Proceedings of the IEEE Computer Security Foundations Workshop, pages 162-174, Franconia, NH, 1994. 18. R.K. Thomas and R.S. Sandhu. A kernelized architecture for multilevel secure object-oriented databases supporting write-up. Journal of Computer Security, 2(3):231-275, 1993. 19. R.K. Thomas and R.S. Sandhu. Supporting object-based high assurance write-up in multilevel databases for the replicated architecture. In Proceedings of European Symposium on Research in Computer Security, pages 403-428, UK, 1994. 20. U. S. Department of Defense. Trusted computer system criteria. Technical Report CSC-STD-001-83, U. S. National Computer Security Center, August 1983. 21. D. Volpano, C. Irvine, and G. Smith. A sound type system for secure flow analysis. Journal of Computer Security, 4(2/3), 1995.
A
The Z Notation
A set m a y be defined in Z using set specification in comprehension. This is of the form { D I P " E }, where D represents declarations, P is a predicate and E an expression. T h e components of { D I P 9 E } are the values taken by expression E when the variables introduced by D take all possible values t h a t make the predicate P true. For example, the set of squares of all even natural numbers is defined as { n : N I (n rood 2) = 0 9 n 2 }. W h e n there is only one variable in the declaration and the expression consists of just t h a t variable, then the expression m a y be dropped if desired. For example, the set of all even numbers m a y be written as { n : N [ (n rood 2) = 0 }. An equivalent way to define this set is as { n : N 9 (2 9 n) } - - t h e predicate m a y be dropped if it equals true.
A Kernelized Architecture
49
In Z, relations and functions are represented as sets of pairs. A (binary) relation R, declared as having type A ~ B, is a component of ?(A x B). For a 6 A and b 6 B, then the pair (a, b) is written as a ~-~ b, and a ~-+ b E R means that a is related to b under relation R. Functions are treated as special forms of relations. The Schema notation is used to structure specifications in Z. A schema such as FlowPolicy defines a collection of variables (limited to the scope of the schema), and specifies how they are related. Schema FlowPolicy[C, L, F] is defined in terms of generic types [C, L, F], which must be instantiated when the schema is used. Schemas may be defined in terms of other schemas. For example, the inclusion of FlowPolicy within RelabelPolicy is equivalent to the syntactic inclusion of the variables and predicates of FlowPolicy within RelabelPolicy. Schema predicates are useful for writing theorems: in Section 6 the Initial States Theorem is a universal quantification over all the variables of InitialLabelStoreO such that it's predicate part implies the existence a 6 such that the predicate part of Abs holds. The decorated schema LabelStore'[C, L] is LabelStore[C, L] with all variables primed. Schema variables may be renamed in the usual way: LabelStore[C, L][6'/6] an alternative way of writing LabelStore'[C, L]. The schema ALabelStore is a syntactic sugar for LabelStore A LabelStore'. It is typically used for specifying state transitions, with undecorated variables representing 'before values' and decorated (primed) variables representing 'after values'. Schema SSCUP is the schema ASCUP, but with the constraint that variable values are unchanged.
first(a, b)
Component a of ordered pair (a, b) PA The power set of A A~ B Relations between A and B A --+ B Total functions from A to B A~ B Partial functions in A --r B dom R, ran R Domain and Range of relation R f @g The functional override of f by g Fig. 5. Some Operators from the Z Toolkit
B
Theorem Proving with Z/EVES
This paper was typeset using LaTeX with the z-eves style. Thus, the LaTeX source of the paper acts as the input specification to the Z / E V E S system [15]. In addition to using the system to syntax-, type- and domain- check the specifications in this paper, Z / E V E S was used to verify the security and correctness of the label manager. The specification source, along with the Z / E V E S proof scripts for all theorems are available from the author or under the author's W W W page at
.
Dealing with Multi-policy Security in Large Open Distributed Systems Christophe Bidan 1 and Val~rie Issarny2 1 Distributed Software Engineering Section, Department of Computing, Imperial College, London SW7 2BZ, UK, c. bidan~doc, ic. ac .uk 2 IRISA / INRIA Rennes, Campus Universitairede Beaulieu, 35042 Rennes Cedex, France, Valerie. Issarny@irisa. fr
A b s t r a c t . From the security point of view, one challenge for today's distributed architectures is to support interoperation between applications relying on different possibly inconsistent security policies. This paper proposes a practical solution for dealing with the coexistence of different security policies in distributed architectures. We introduce a model for specifying security policies in terms of security domains, access control and information flow rules. Then, we identify the set of operators for combining the specifications of sub-policies and we address the validity of the resulting policy according to the security properties of the sub-policies.
1
Introduction
Object-based distributed computing architectures 1 like CORBA (Common Object Request Broker Architecture) defined by the Object Management Group (OMG) [24], and the Telecommunication Intelligent Network Architecture proposed by the TINA consortium [26] are promising approaches to support large open distributed systems. Goals of these architectures include interoperability between software components in heterogeneous distributed environments, where components may appear and disappear dynamically, as the result of individual and autonomous actions. From the security point of view, the interoperability promoted by the above architectures stresses the complexity of security policies which have to be implemented [15,10], as well as the necessity to cope with the coexistence of multiple security policies. This coexistence results from the interoperation between systems (or software components) having different security requirements, possibly at different granularity levels. For evaluating the security of open distributed systems, security oj~icers should be able to reason about the composition of the interoperating systems' 1 From the security point of view, an object-based distributed computing architecture is viewed as multiple interconnected systems [23].
52
Christophe Bidan and Val@rie Issarny
security policies. We identify two different approaches for the composition of security policies: policy interoperation and policy combination. Using policy interoperation, the composed policy should not violate the security of the subpolicies, and should guarantee their autonomy [14]. On the other hand, with policy combination, the composed policy may be inconsistent with both subpolicies, but must be secure in the given context. Hence, security combination allows to compose conflicting policies in a secure and controlled manner [3]. In the context of large open distributed architectures, we assert that policy combination is better suited than policy interoperation. In this paper, we introduce a model that forms the basis for dealing with security in heterogeneous distributed architectures, allowing to specify and to combine a wide variety of security policies. In particular, the proposed model is useful to security officers by supplying a practical set of combination operators. This paper is structured as follows: the next section presents related work and gives our standpoint concerning policy composition. Section 3 presents our model for the specification and combination of access control policies 2. In particular, it gives the notion of complete and sound combination. Section 4 extends this model so as to deal with combination of information flow policies. Finally, we draw some conclusions in section 5 and present current status and future work. 2
Topics
for Policy
Combination
Various models have been proposed in order to reason about security policies (e.g., see an overview of security models by Landwehr [18], the Bell-LaPadula model [4], the information flow model from Bieber [8], the Clark-Wilson model for commercial security constraints [9], and the McLean model [20]). These models are introduced to check whether a policy verifies given security properties like the nondeducibility property [25] or the noninterference property [13]. However, these models do not deal with the composition of policies. Concerning the definition of a security policy resulting from the composition of policies, we identify two different approaches: - policy interoperation which infers the composed policy based on the security properties of the sub-policies, and - policy combination which specifies the composed policy based on the specifications of the sub-policies. The former approach relies on the principles of autonomy and of security of sub-policies [14]: during the interoperation of two different security policies, any access authorized within an individual policy must also be authorized within the composed policy; and dually, any access denied within an individual policy must also be denied within the composed policy. Abadi et al. [1] propose a general 2 In this paper, an access control policy is defined as a security policy that only checks the accesses between entities, without verifying the information flow resulting from access operations.
Dealing with Multi-Policy Security in Large Open Distributed Systems
53
solution to the inference of execution properties of interoperating components from the components' specification, which can be adapted to security policies. More recently, McLean [21] has presented an approach which allows to reason about security properties of composed information flow policies. Finally, Gong et al. discuss computational issues concerning the general secure interoperation problem [14]. The above proposals allow to verify that interoperation preserves the subpolicies' security properties under certain conditions. However, the undertaken approach to the definition of policy composition is restrictive; the security properties of the composed policy must be the same as those of the sub-policies (the principles of autonomy and security must be guaranteed). In consequence, the sub-policies have to be compatible. In large open distributed system, this is not always the case, since the properties of a policy resulting from the composition of two incompatible sub-policies can be an extension or a restriction of those sub-policies. We illustrate this through two examples. In both example, we consider a file system where we have two sets of users, A and C, and two sets of files, B and D. We say that an user u is authorized to access the file f if and only if u is authorized to access f ' s data. We specify only authorized accesses, and all accesses that are not specifically authorized, are denied. We define the security policy P l (resp. P2) managing A users and B files (resp. C users and D files): P l (resp. 7~2) authorizes users in A (resp. in C) to access files in B (resp. in D). First, let us combine 7~1 with P2 to build the following composed policy: the users belonging to both sets A and C (denoted as AAC) are authorized to access the files in B N D, users in A but not in C (denoted as A - C) are authorized to access the files in B - D, and finally, users in C - A are authorized to access the files in D - B. As a second example, we combine P l and P2 so as to obtain the following policy: all the users belonging to sets A or C (denoted as A U C) are authorized to access all the files in B U D. Notice that this policy may be viewed as the federation of the sub-policies. The composed policy of the first example is a restriction of the participating sub-policies, whereas the composed policy in the second example is an extension of the participating sub-policies (for instance, A users are authorized to access D files). However, these two composed policies are secure in the context in which they are specified, nevertheless they cannot be obtained by policy interoperation. The specification of a policy based on the specifications of its sub-policies allows to combine possibly inconsistent policies. In particular, a combined policy does not necessarily guarantee all the properties of the sub-policies. However, notice that the combined policy may keep the principles of autonomy and secrecy of the sub-policies. McLean [19] seems to be the first to propose a formal approach including combination operators: he introduces an algebra of security which enables to reason
54
Christophe Bidan and Valdrie Issarny
about the problem of policy conflict. However, even though this approach permits to detect conflicts between policies, it does not propose a method to resolve the conflicts and to construct a security policy from inconsistent sub-policies. Hosmer [16] has introduced the notion of metapolicies, or "policies about policies", an informal framework for combining security policies. Following Hosmer's work, Bell formalizes the combination of two sub-policies with a function (policy combiner), and introduces the notion of policy attenuation to allow the composition of conflicting security policies [3]. Our work is placed in the framework of policy combination, and it is close to Bell's approach. More specifically, our model is a practical alternative solution to Bell's proposal: we clearly identify the set of combination operators enabling security officers to combine security policies in a controlled and secure way. Briefly, our model allows to specify the general behavior of sub-policies. Based on these specifications, we introduce combination operators for combining policy specifications. Finally, we verify that the behavior of the composed policy is secure and conforms with sub-policies specifications. The following sections introduce our model to deal with access control policies and flow policies.
3
Specifying Access Control Policies
In this section, we concentrate on the following type of access control: is an entity el authorized to access an entity e2 in the context of a given policy, regardless of the information flow that is implied by this access ? Our solution to policy composition relies on the definition of a set of combination operators. A policy is specified either as an elementary policy or a combined policy built from existing sub-policies through the use of combination operators. The next sub-section addresses the specification of access control policies and is followed by the definition of the operators allowing to combine policy specifications. Finally, we address the completeness and soundness of policy specifications. 3.1
Elementary
access control policy
An access control policy defines a set of rules that specify for each pair of object and subject, whether the subject is allowed to access the object's state or not 3. Since in an open distributed architecture, an access control policy cannot be defined for the whole set of the system's entities, we take an approach which allows to specify the sensitive entities for each policy. In other words, an access control policy is defined not solely in terms of its access control rules but also in terms of its access control domain [22], that determines the system's objects and subjects to which the policy applies. The access control domain of a policy is subdivided into the set of the system's entities called object domain, that contains sensitive information for this policy, 3 We define the subjects as active entities, and the objects as passive or active entities [11].
Dealing with Multi-Policy Security in Large Open Distributed Systems
55
and the set of the system's entities called subject domain, that gives the subjects belonging to the policy domain. These two sets are defined formally in terms of security classifications 4. Given a security property P (i.e. a predicate) defined on the set $ of the system's entities, the set of entities verifying this property is termed the P classification, noted Clp:
CIp = {r e C I P(c) ~ true} = {~ e ~ [ P} Given the definition of classification, an access control domain is defined as a set of classifications: Dora = {CI,}~=I, where, for each i = 1, ..., n, Cli is the classification defined by a security property 9
n
P~. Each access control rule A of a given policy defines the set of subject and object couples that verify a given security property Px (called access control predicate), and an access control operator. The access control operator is noted ,-~> for authorization, ~> for denial, and the 4-> operator will be used to denote ,~> or ~>5. Formally, an access control rule )~ takes the form: = {(s e Cll),(o e Cl2) [ Px(s,o) ;s+>o}. In other words, we say that a pair (s, o) belongs to )~ if the access control predicate Px(s, o) holds ; then, the access control operator of )~ define whether s is authorized or not to access o. In the remainder, f o r / ) being an access control policy, its domain is noted DomT~, the notation Dome, (resp. Dome,) is used to designate the sub-domain of DomT) that defines 7)'s objects (resp. subjects). Finally, R~, is the set of access control rules of the policy 7~. E x a m p l e . We now illustrate our model for policy specification with the example of a file system expressed as a distributed architecture. Let ~'8 be the set of software components accessing files. Let further R E A D C :F$ and W R I T E C ,%'8 be respectively the set of software components allowed to read and to write files. We also consider two sets of users, A and C, and two sets of files, B and D. We introduce the predicate Owner(sc, U) which, given a software component sc, holds if the owner of sc (i.e. the user executing sc) belongs to the set U of users (i.e. A or C). In the following, we do not specify reflexive accesses. Given the above definitions, we define the/)1 and 7)2 access control policies introduced in w as follows: -
The subject domain of the policy Pl is the set of components R E A D (Dom~ = R E A D ) , and :Pl's object domain is the set of files B (Dom~ = B). The policy :Pl has a single access control rule: )h = {(s E READ), (0 E B) I Owner(s,A);s,,~>o}, that authorizes subjects of A to access objects of B.
4 We use the term classification for both object classification and subject clearance. 5 We consider that an access corresponds to the execution of an operation (e.g. read access corresponds read method). This enables us to use a single access operator.
56
Christophe Bidan and Val~rie Issarny
- The subject domain of the policy P2 is the set of components W R I T E (Dom~ = W R I T E ) , and :P2's object domain is the set of files D (Dom~ = D). The policy P2 has a single access control rule: )~2 = {(s E W R I T E ) , (o e D) I Owner(s, C); s,,~>o}, that authorizes subjects of C to access objects of D. 3.2
C o m b i n i n g access c o n t r o l policies
A combined access control policy is built by combining two sub-policies. The domain and rules of the combined policy are defined in terms of the combination of its sub-policies' domains and rules. C o m b i n i n g access c o n t r o l d o m a i n s Given two classifications, four types of combination can be implemented: the union, intersection, product of classifications, and the denial of classification combination. Let Cll = {~ E E I P1} and C12 = {E E E I P2} be two classifications. We formally define their union and intersection as: Cll U Cl2 = {~ E ~ I P1 V P2} and Cll A Cl2 = {~ E E I P1 A P2} respectively. Concerning the product of Cll and el2 (noted Cll t~ Cl2), three separate classifications are computed: the classifications defined by the access control predicates P1 A -~P2, -~P1 A P2 and P1 A P2 respectively. Finally, to forbid the combination of two classifications, we introduce the operator /2 defined by: Cll )5 Cl2 = 0. The U operator allows to extend the sub-classifications. On the other hand, the classification obtained by A operator is a restriction of the sub-classifications. Finally, the +~ operator permits to distinguish the entities belonging to a single sub-classification from the entities belonging to both sub-classifications. The formal definition for combining domains directly follows: it amounts to specifying the type of combination for each pair of classifications of the subpolicies' domains. Let Dotal = (Cl~}'~=1 and Dora2 = (Clj}~= 1 be two access control domains. Let A = {Si,j E {U, N, ~, ~ ) , i = 1, ..., n, j = 1, ..., m} be the set specifying the operator for combining the classifications Cli of Dotal and Clj of Dora2. The combined access control domain D a m resulting from the combination of Dotal with Dora2 with respect to A is given by: Dora = {V i = 1,...,n,V j = 1,...,m, Clij = Cli ~i,j Clj}. We bring to the reader's attention that a combined domain can itself be combined with another domain. C o m b i n i n g access c o n t r o l rules. Because both ,~> and ~> access operators exist, the combination of access control rules raises the problem of conflicts among rules. Thus, we distinguish between combination of non-conflicting rules and combination of conflicting rules.
Combination of non-conflicting rules. Let us first consider the combination of non-conflicting rules. Given two non-conflicting access control rules, their combination results from the combination of their classifications and of their access control predicate.
Dealing with Multi-Policy Security in Large Open Distributed Systems Let A1 and both or denim ~1 = {(S 9 A2 = {(s 9
57
)~2 be two access control rules specifying either authorization for of access for both: Cll),(O 9 Cl'l) ] Pl(s,o) ; s+>o} and C12),(o 9 Cl~2) I P2(s,o) ;s+>o}.
Let us first suppose that Cll = Cl2 and Cl'1 = Cl'2. Then, combining A1 and )~2 consists of combining the access control predicates P1 and P2. With respect
to existing work (e.g. [2]), we identify two types of combination: the logical and (A) and the logical or (V) between P1 and P2. Then, the A access control rule resulting from the combination of A1 and As takes one of the following forms: A = {(s 9 Cll),(o 9 Cl~) I (Pl(s,o) YP2(s,o)) ; s+>o}, or A = {(s 9 C l l ) , ( o 9 Cl'~)l(P~(s,o)/\P2(s,o)); s+>o}. Informally, the logical or operator allows to combine two access control rules in such a way that the resulting access control rule preserves the authorized accesses of the sub-rules (principle of autonomy). On the other hand, the access control rule resulting from the logical and operator authorizes (resp. denies) access if both sub-rules authorize (resp. deny) the access. Let us now suppose that Cll ~ Cl2 and Cl~ ~ Cl~. Then, the set of access control rules resulting from the combination of )h and )~2 depends not only on the operator for combining access control predicates, but also on the operators for combining classifications. Let 61,2 (resp. 5~,2) be the operator defined for the combination of the Cll and C12 (resp. Cl~ and Cl~) classifications. Then, the set A of access control rules takes one of the following forms, depending on the operators used for combining classifications: if 51, 2 ---~ /2 or 5~,2 = /J, then A = 0 (the empty set), i.e. the combination is forbidden. if 61,2 E {U, M} and 5~,2 E {U, M}, then A consists of a single access control rule: )~ = {(s E ell 51,2 el2), (0 E Cl[ 5'1,2 Cl~2) I (Pl(S,O) op P2(s,o)) ; s+>o}, where o~ E {V, A}. - if 51,2 = t~, we only combine the access control predicates for subjects belonging to Cll MCl2, and we keep unchanged the rules for the other entities. In other words, A consists of three separate access control rules: = {(8 E ( e l l - Cl2)),(o e (Cl i 5'1,2 Cl~))lPl(S,O ) ;8+>0}, )r = {(s E (el2 - Cll)),(o E (Cl~ 5~,2 elL) ) I P2(s,o) ; s+>o}, and )~H = {(8 9 (CllNel2)) , (0 9 (Vi i 6'1,2 Cl~)) I (P1 (8, o) op P2(s, o)) ; s+>o}, where o~ 9 {V, A}. If 5 ~ ~ = ~, the set A of access control 1,2 = t~ or 51,2 = 5 1,2 rules is equivalent to the one computed for 51,2 = ~. -
-
Coupling the operators for combining classifications and the ones for combining access control predicates, allows either to restrict or to extend the access control rules of the sub-policies. In particular, using 51,2 = 5[,2 = M and the A operator for combining access control predicates, the access control rule )~ resulting from the composition of A1 and )~2, verifies that: (s,o) E )~ ~ (s,o) E A1
58
Christophe Bidan and Val~rie Issarny
and (s, o) E As, i.e. the access is authorized (resp. denied) if and only if it is authorized (resp. denied) by both A1 and As (A is more specialized than A1 and A2 in the sense that it provides finest classifications). In this case, the composed policy keeps the principles of autonomy and secrecy of the sub-policies [14]: the combined policy is identical to the one obtained with policy interoperation.
Combination of conflicting rules. Let us now examine the combination of conflicting rules. Let A1 and A2 be two access control rules specifying respectively access authorization and access denial: )~1 ---- {(8 e Cll),(o E Cl~) [ Pl(8,0) ;8,,~>0} and As = {(s e Cl2), (0 e Cl~) [ P2(s,o) ;sr Let 51,2 (resp. 5~,2) be the operator defined for the combination of the classifications Cll and Cl2 (resp. Cl~ and Cl~). Let further C11,2 = Cll 51,2 Cl2 and Cl~, 2 = Cl[ 5'1,2 Cl~. The A+ and A - operators allow to combine two conflicting rules: A1 A+ As and A1 A- A2. T h e result of the combination of A1 and A2 consists of three separate rules A, AI and A" defined by: -- {(s e vii,s), (o e cll,s) I (fl(s,o)A-nPs(s,o)) ;s ,'-) o} = {(s e Cll,s),(o e ell,s) I (-,Pl(s,o) APs(s,o)) ;s o} )~1! ---- { ( 8 E ell,2), (o ~ Clll,2) I (Pl(s,o) A Ps(s,o)) ;sac o} with (ac = ,~>) for the operator A+, and (ac = ~>) for the operator A - . The A and A~ rules are coherent with both sub-rules. On the other hand, the A" rule is clearly inconsistent with either A1 or As. The A+ operator favors access authorization whereas the A- operator favors access denial. Notice that the A+ and A - operators are close to the notion of strong and weak authorizations introduced in database systems to support multiple access control policies [5]. As with the composition of non-conflicting rules, coupling the operators for combining classifications and the ones for combining access control rules allows either to restrict or to extend the sub-rules. Finally, the combination of two sets of access control rules R1 -- {A1}i= i n 1 and J m 1 amounts to specifying, for each pair of rules ()~1, R2 = {As}~= i A2), J the operators for combining their classifications and their access control predicate. Let us remark that the proposed combination model applies recursively: a combined policy can be combined with another policy. E x a m p l e . We now illustrate the use of combination operators with the example of the file system given in w Given the component classifications R E A D and W R I T E , the two sets of users A and C, and the file classifications B and D, we define the following access control policy P: the (A - C) users are authorized to read files in (B - D), (A Cl C) users can read and write files in (B Cl D), and (C - A) users are authorized to write files in (D - B). Using the bJ operator for combining classifications, we are able to differentiate components that only allow to read files (R_ONLY = (READ - W R I T E ) ) , components that only allow to write files ( W _ O N L Y = ( W R I T E - READ)), and components that allow to read and to write files (R_and_W = ( R E A D gl
Dealing with Multi-Policy Security in Large Open Distributed Systems
59
W R I T E ) ) . The operator t~ further allows to differentiate the following sets of files: B - D, B M D and D - B. Finally, using the operator A for combining access control rules, we are able to get the specifications of 7): = {(s E R _ O N L Y ) , (o e B - D) I Owner(s, A) ; s,~>o), ~' = ((s E W _ O N L Y ) , (o E D - B) I Owner(s, C) ; s,,~>o}, and )~" = ((s e R_and_W), (o E (BMD)) I (Owner(s, A) A O w n e r ( s , C)) ;s,~>o}. 3.3
Complete and sound access control policy
We have proposed a model for the specification of access control policies as well as a set of combination operators allowing to compose these specifications. Now, we define the notion of secure access control policy in the context of our model: the policy is secure if and only if its specification is complete and sound. Let us precisely define the completeness and soundness of policy specifications. D e f i n i t i o n 1. ( C o m p l e t e policy) An (access control) policy 7) is complete (from the standpoint of its specification) if and only if: (1) there exists an access control rule for every object and subject of 7~ 's domain, and (2) in the case that 7) is a combined (access control) policy, its sub-policies are also complete. In an open distributed architecture, an access control policy cannot be defined for the whole set of the system's entities. The above definition states that a complete access control policy ensures access control for any entity belonging to the policy's object domain, and for entity belonging to the policy's subject domain 6. D e f i n i t i o n 2. ( S o u n d p o l i c y ) An (access control) policy 7) is sound (from the standpoint of its specification) if and only if: (1) given a subject s and an object o belonging to the policy's domains, all the access control rules specifying whether s can access o or not, have the same access control operator, and (2) in the case that 7) is a combined (access control) policy, its sub-policies are sound. Given two sound sub-policies, if both specify only access authorization (or only denial) then for all combination operators, the combined policy is sound. On the opposite, when at least one of them specifies both authorized and denied accesses, the soundness of the combined policy may not be guaranteed. However, given two complete and sound access control policies, we have the following result which guarantees that there exists a secure policy resulting from the combination of these policies. 1. E x i s t e n c e o f s e c u r e c o m b i n e d a c c e s s c o n t r o l p o l i c y Let 7)1 and 7)2 be two secure access control policies. There exists a set of operators for combining classifications and for combining access control rules such that, if 7) is the policy resulting from the combination of 7)1 and 7)2 according to these sets, then 7) is secure.
Theorem
6 In general, the completeness of a given policy can be guaranteed by specifying default access control rules.
60
Christophe Bidan and Val~rie Issarny
Proof: Let Dotal = {Cli}~.=l (resp. Dom2 = {Clj}~=l) be 791's (resp. 792's) access control domains. Let A = {Ji,j = N,i = 1, ...,n,j = 1, ...,m} be the set of operator for combining classifications. Let R1 = {A~}n=l (resp. R2 = {A~}~=I) be 791's (resp. 792's) sets of access control rules. Let ~ = {ai,j E { V, A+, A- }, 1, ..., n, j = 1, ..., m} be the set of operator for combining access control predicates, with: (1) c~i,j = V if A~ and A~ are non-conflicting rules; (2) ai,j = A+ if A~ and A~ are conflicting rules and A~ is an access authorization rule; and (3) c~i,j = A- if A~ and AS are conflicting rules and A] is an access denial rule. It is trivial to show that the policy 79 resulting from the composition of 791 and 792 according to the sets A and ~ is a complete and sound policy (i.e. 79 is secure). [] E x a m p l e . Let us now address the completeness and soundness of policies specified in the file system example. The policies 791 and 792 are not complete. For instance, there are not access control rules concerning software components not belonging to subject's classifications and which require to access B or D files. If we specify default rules which deny all accesses between entities in 791 (resp. 792) security domain and the other entities, 791 (resp. 792) becomes complete. By giving priority to the access control rules over the default rules, the soundness of the policies 791 and 792 is also verified. Finally, by using the same default rules, the combined policy 79 is secure.
4
Extension for Information Flow Policies
In this section, we extend the proposed model for specifying and combining access control policies to introduce the notion of information flow. Then, we address completeness and soundness of the resulting specifications, hence defining secure information flow policy according to our model. 4.1
Information flow p o l i c y
The previous model allows to describe access control policies but does not integrate any notion of information flow. Therefore, it does not meet the specification of information flow. In order to deal with flow policies, we extend the previous model as follows: (1) the specifications of access control rules are enriched with the notion of information flow, and (2) rules that control the transitive information flow (by denying some information flows) are introduced. I n p u t a n d o u t p u t flows. For specifying the information flow that is associated to an access control rule, let us distinguish the access control rules for input flow (e.g. the read accesses) from the access control rules with output flow (e.g. the write accesses). We extend our definition of access control rules given in w by specifying the flow associated to the access operation thanks to the operators <--, and ,-~>.
Dealing with Multi-Policy Security in Large Open Distributed Systems
61
Definition 3. ( R u l e s f o r input and o u t p u t flow) An access control rule for input flow takes the form: ~ = {(s e Cl), (0 E Cl') I P(s, o) ;s<--~o). An access control rule for output flow takes the form: ~ = {(s e C1), (o e
Cl') l P(s ,o) ;s,~>o}. Given two entities el and e2, the expression el <,--e2 specifies that el is authorized to access e2, and this access produce a flow from el to e2. Dually, the expression el-,,>e2 specifies that el is authorized to access e2, and this access produce a flow from e2 to el. Note that we only specify the information flow for the authorized accesses.
Information flow r u l e s . The information flow resulting to accesses is transitive: let el, e2 and e3 be system entities, if e l ~ > e 2 and e2,-.~>e3 then el r,~>s3. In order to specify information flow policies, we specify the information flows which are denied, i.e. the information flow rules. Definition 4. ( I n f o r m a t i o n flow r u l e ) An information flow rule is defined as r : {(el e e l ) , (e2 E Cl') I P ( Q , e 2 ) ;el ~ e2}. The rule r specifies that the information flow from C! entities to Cl' entities verifying the predicate P is denied. Then, an information flow policy is defined as follows:
Definition 5. ( I n f o r m a t i o n flow p o l i c y ) An information flow policy is an
access control policy for which the access control rules are enriched according to the definition 3, and which defines a set of information flow rules. E x a m p l e . In order to illustrate our model, we describe a simple multilevel security policy [4], called ~ s - We consider a distributed military system consisting of a set of software components (i.e. programs representing users), and a set of files that the components manipulate. Suppose that we have two security levels for both files and components: Secret and Unclassified 7 such that Secret > Unclassified (i.e. the Secret information is more sensible than the Unclassified information). A software component can use a set of methods (e.g. read, write, execute, etc) to access files. In the following, we only consider the read and write methods. We define the R E A D (resp. W R I T E ) classification to be the set of software components allowed to read (resp. write) files. We introduce the predicate (cl > e2) which, given two entities el and c2, holds if and only if the security level of el dominates, i.e. is greater than or equal to the security level of e2. We define the following information flow policy ~s: - The subject domain consists of the R E A D and W R I T E classifications, and the object domain consists of files belonging to Secret or Unclassified classifications. 7 The Secret and Unclassified terms are used for denoting both the security level, the classifications and the predicate.
62
Christophe Bidan and Val~rie Issarny
- A component belonging to R E A D is authorized to access a file if and only if its security level dominates the one of the file, and the flow resulting to such access is an input flow: A1 = {(s E R E A D ) , (0 E (Secret U Unclassified)) [ s > 0 ;s<~,o}. - A component belonging to W R I T E is authorized to access an file if and only if the file security level dominates the one of the component, and the flow resulting to such access is an output flow: A2 = {(s E W R I T E ) , (0 e (Secret [J Unclassified)) [ s >_ 0 ;s,~>o}. - All the accesses not authorized previously are denied through a default rule. - Unclassified entities are not authorized to access Secret information: r = {(el E R E A D ) , (e2 E (SecretUUnclassified)) [ (~2 _> el) ;el ~/+ e2}. 4.2
Combined
information
flow policy
Let us now address the combination of information flow policies. Given two information flow policies, we distinguish three steps for the combination of these policies: (1) the combination of these policies according to the operators for combining access control policies (see w (2) the combination of the <~, and ,~> operators in order to specify the information flow of each combined access control rule, and (3) the combination of information flow rules. The first step allows to obtain the access control rules of the combined flow policy. During this step, the information flow sub-policies are viewed as access control policies, and the combination is carried out from the standpoint of combination of access control policies. The second step permits to specify the information flow within the combined access control policy obtained at the first step. Informally, the combination of two rules for input flow (resp. rules with output flow) is a rule for input flow (resp. rule with output flow). In the other case, the combined rule is a rule for both input and output flow (<~> operator). Finally, we compute the combined information flow rules by composing the information flow rules of the sub-policies, in a way similar to the combination of non-conflicting rules (see w Informally, the logical or operator allows to combine two information flow rules so as to generate a unique rule that provides the information flow control of the sub-policies. On the other hand, the information flow rule resulting from the logical and operator denies the information flow if and only if both sub-rules deny the flow. E x a m p l e . Let us combine the information flow policy 5us introduced in w with another policy having different classifications. Suppose that we have two classifications in terms of military domains for both files and software components (e.g. users): Nuclear and Conventional classifications such as Nuclear > Conventional. Similarly, we define the information flow policy 3rD, except for the set of information flow rules that we define as an empty set. By using the M operator for combining classifications, and the A operator for combining access control predicates, we obtain the policy 9r depicted in figure 1. For simplifying the figure, we do not distinguish components and files, and
Dealing with Multi-Policy Security in Large Open Distributed Systems
63
we do not show neither the denial accesses nor the implied transitive accesses. The specification of the information flow in the combined access control rules are immediate according to the sub-policies' specifications (i.e. the read access produces input flow whereas the write access generates output flow). The information flow rule of the combined policy is the one of the policy :Fs: r = {(Cl e READ), (e2 e (Secret U Unclassified)) I (e2 > el) ;cl ~-~ c2}.
t'Z, ~
Secret r Nuclear
[~
Unclas~ified n Nuclear Read access
~,r rt ]] - - -I~
Secret n Conventional Unclass~fied ~ Conventlonal Write access
Fig. 1. Combined multilevel policies
4.3
Complete and sound information flow policy
Given the specifications of information flow policies in our model, we now focus on the notion of secure information flow policy by addressing the completeness and soundness properties. In our model, we only specify the information flows which are denied. In other words, any information flows that are not denied are authorized, and the problem of conflicts among information flow rules does not exists. Based on this remark, an information flow policy /F is complete (from the standpoint of its specification) if and only if ~ is complete as an access control policy (see definition 1). In the same way, an information flow policy ~- is sound (from the standpoint of its specification) if and only if 9~ is sound as an access control policy (see definition 2). A secure information flow policy is a policy for which the specifications in our model are complete and sound. In the case of a combined policy, the secure property implies that the policy's specifications are coherent with the specifications of the sub-policies according to the combination operators that are used. Like in w given two information flow policies, there exists operators for combining classifications and rules such that the combined policy is secure. Notice that a policy being secure according to our model does not imply that the policy have no covert channels. For example, the write access is an access having output flow, but, when the file does not exist, the information flow induced by the write method is an input flow: after the operation, the user
64
Christophe Bidan and Val@rie Issarny
have information concerning the file's existence. Such covert channels do not invalidate the secure property. However, our secure property ensure that the policy's specifications are defined without ambiguity for any entity belonging to the policy's domain. E x a m p l e . Let us address the completeness and the soundness of the multilevel policies iTs and ~-D. Let us consider that the classifications in terms of security level or in terms of military domains are both complete classifications, i.e. any entity of the system has a (unique) security level and belongs to a (unique) military domains. Then the flow policies iTs and ,~FD becomes complete and sound access control policies. In the same way, the combined flow policy iT is complete and sound as an access control policy. Finally, the soundness of the policy iT is trivial, and iT is a secure flow policy.
5
Conclusion
In this paper, we have proposed a practical solution for reasoning about the coexistence of different security policies. Our approach relies on the specification of security policies and on the definition of operators for combining these specification. We have also addressed the completeness and the soundness of the (combined) security policy according to its specification. Our model can be viewed as an implementation design of the Bell's model. We have introduced a set of combination operators enabling security officers to specify and to combine security policies in a controlled and secure manner. In addition, we assert that the dissociation between the combination domains and the combination rules permits to get a simplified and growing vision of security policies in open distributed systems. Finally, the distinction between access operations and the generated information flows gives to our model a useful approach, information flow policies being considered as an extension of access control policies. We have illustrated our approach through two different examples of file systems in an distributed architecture. In particular, the multilevel security policy example enables us to demonstrate the strength for specifying security policies and the ease for combining security policies. Current and future work
In open distributed systems, the coexistence of applications which have different security constraints results from rich and complex interactions among software components [15]. Integrating our model in the software architecture paradigm provides an appealing solution to the sound development of applications with security requirements [7]. More specifically, such a solution allows to specify the security requirements, and to build systematically, from existing components, the reference monitor that meet these requirements. One application area for our results can be the World-Wide-Web (Www): we are currently examining
Dealing with Multi-Policy Security in Large Open Distributed Systems
65
the automatic selection of the components for ensuring information exchanges in a secure way. We also consider the use of this solution for reasoning about Java-applets, in order to customize the Java Virtual Machine in a controlled and secure way. From the implementation standpoint, we are currently integrating our model in the Aster configuration-based distributed programming environment [6, 17]. The resulting framework allows the easy development of applications consisting of heterogeneous software components, running on heterogeneous hardware platforms, and having multiple security requirements. From the theoretical perspective, we are interested with the extension of our model in order to specify security policies with dynamic relabeling [12].
References 1. M. Abadi and L. Lamport. Composing Specification. Technical Report 66, Digital Systems Research Center, Oct. 1990. 2. M. Abrams, L. LaPadula, K. Eggers, and I. Olson. A Generalized Framework for Access Control: an Informal Description. In Proceedings of the 13th National Computer Security Conference, pages 134-143, Oct. 1990. 3. D. E. Bell. Modeling the Multipolicy Machine. In Proceedings of the New Security Paradigm Workshop, pages 2-9, Aug. 1994. 4. D. E. Bell and L. J. LaPadula. Secure Computer Systems: Unified Exposition and Multics Interpretation. Technical Report MTR-2997 Rev. 1, MITRE Corporation, Bedford, Mass, 1976. 5. E. Bertino, S. Jajodia, and P. Samarati. Supporting Multiple Access Control Policies in Database Systems. In Proceedings of the IEEE Symposium on Security and Privacy, pages 94-107, May 1996. 6. C. Bidan and V. Issarny. A Configuration-based Environment for Dealing with Multiple Security Policies in Open Distributed Systems. In Proceedings of the 2nd European Research Seminar on Advances in Distributed Systems, Mar. 1997. URL: htZp ://www. irisa, fr/solidor/work/aster. 7. C. Bidan and V. Issarny. Security Benefits from Software Architecture. In Proceed-
8. 9. 10. 11. 12. 13.
ings 2rid International Conference on Coordination Models and Languages, pages 64-80, Sept. 1997. URL: http://w~w, i r i s a , f r / s o l i d o r / w o r k / a s t e r . P. Bieber and F. Cuppens. A logical view of secure dependencies. Journal of Computer Security, 1(1):99-129, 1992. D. Clark and D. Wilson. A Comparison of Commercial and Military Computer Security Policies. In I. C. Society, editor, Proceedings of the IEEE Symposium on Security and Privacy, 1987. R. Deng, S. Bhonsle, W. Wang, and A. Lazar. Integrating Security in CORBA Based Object Architectures. In Proceedings of the IEEE Symposium on Security and Privacy, pages 50-61, May 1995. Department of Defense Standard. Trusted Computer System Evaluation Criteria. Technical Report DoD 5200.28-STD, Dec. 1985. S. Foley, L. Gong, and X. Qian. A Security Model of Dynamic Labeling Providing a Tiered Approach to Verification. In Proceedings of the IEEE Symposium on Security and Privacy, pages 142-153, May 1996. J. Goguen and J. Meseguer. Security Policies and Security Models. In Proceedings of the IEEE Symposium on Security and Privacy, pages 11-20, May 1982.
66
Christophe Bidan and Val~rie Issarny
14. L. Gong and X. Qian. Computational issue in secure interoperation. IEEE Transactions on Software Engineering, 22(1):43-52, Jan. 1996. 15. OMG Security Working Group. White Paper on Security. TC Document 94.4.16, OMG, Apr. 1994. Available by ftp at ftp.omg.org:/pub/docs. 16. H. Hosmer. Metapolicies II. In Proceedings of the 15th National Computer Security Conference, pages 369-378, 1992. 17. V. Issarny, C. Bidan, and T. Saridakis. Achieving Midleware Customization in a Configuration-Based Development Evironment: Experience with the Aster Prototype. In Proceedings of the 4th International Conference on Configurable Distributed Systems, 1998. URL: http ://www. irisa, fr/solidor/work/aster. 18. C. E. Landwehr. Formal models for computer security. ACM Computing Surveys, 13(3):247-278, Nov. 1981. 19. J. McLean. The Algebra of Security. In Proceedings of the 1988 IEEE Computer Society Symposium on Security and Privacy, pages 2-7, Apr. 1988. 20. J. McLean. Security Models and Information Flow. In Proceedings of the IEEE Symposium on Security and Privacy, pages 180-187, May 1990. 21. J. McLean. A general theory of composition for a class of possibilistic properties. IEEE Transactions on Software Engineering, 22(1):53-67, Jan. 1996. 22. J. D. Moffett, M. D. Sloman, and K. Twidle. Specifying Discretionary Access Control Policy for Distributed Systems. Computer Communications, 13(9):571580, Nov. 1990. 23. National Computer Security Center. Trusted Network Interpretation of the TCSEC. Technical Report NCSC-TG-005, July 1987. 24. OMG. The Common Object Request Broker: Architecture and Specification Revision 2.0. Technical report, OMG Document, 1995. 25. D. Sutherland. A Model of Information. In Proceedings of the 9th National Computer Security Conference, pages 2-12, Sept. 1986. 26. TINA-C. TINA Object Definition Language (TINA-ODL) Manual - Version 1.3. Technical Report TR_NM.002_l.3_95, TINA-C Document, 1995.
A Flexible Method for Information System Security Policy Specification Rodolphe Ortalo LAAS-CNRS 7, avenue du Colonel Roche, 31077 Toulouse cedex 4, France [email protected]
Abstract. This paper presents a method for the specification of the security of information systems. The proposed approach provides a flexible and expressive specification method, corresponding to the specific needs of organizations. First, we outline the overall guidelines of the security policy definition process, and the different consistency issues associated to the description of the security requirements of an organization information system. The specification language used is based on a convenient extension of deontic logic. The formalism and its extensions are defined briefly. To illustrate the use of this formalism, the paper presents how the method applies to the description of the security requirements of a real organization : a medium-size bank agency. Keywords: security policy specification, information systems, deontic logic.
1
Introduction
This paper presents a practical framework for the specification of the security policy of an organization such as an industrial company or a public service. These organizations exhibit security needs, but they also have other requirements that induce several specificities with respect to security management. First, the information system may exist prior to the explicit definition of its security policy. Furthermore, it is important to provide an adaptable and structured methodology corresponding to the need for abstraction and progressive refinement in the security policy specification process. Finally, the information system may be imperfect, in the sense that the desired security properties may differ from the actual observed properties. From the security point of view, these contradictions appear intolerable, but they often result from a trade-off between the main requirements of the organization and the enforcement of security measures. In fact, the study of practical regulations often reveals discrepancies between the actual situation and the desired behavior, and the security policy would probably better cope with them rather than ignore them. Consequently, in the context of an organization, most of the classical security models are often unusable. The problem is that they impose constraints on the design and the behavior of the system that may not be acceptable in a situation J.-J. Quisquater et al. (Eds.): ESORICS’98, LNCS 1485, pp. 67–85, 1998. c Springer-Verlag Berlin Heidelberg 1998
68
Rodolphe Ortalo
where security is not a primary requirement. For example, the mandatory rules of a multi-level security policy [1] imply to design the information system accordingly, and assume permanent application of the rules. Moreover, in the case where the system already exists, the security policy could not be applied until it has been re-designed. To face such situations, the specification of a security policy must provide more flexibility and expressiveness. In this paper, we use an extended deontic logic language to specify security policies. Several authors already outlined the main features of deontic logic for specifying security properties [9,12,4], and this formalism seems to be more adequate for the specification of the security policy of an organization than usual security models. The specification method we propose is based on an original syntactical extension of the standard deontic logic language that allows a structured and convenient representation of the elements of the policy. Given the imperfections of real information system policies, several types of security policy inconsistencies may be encountered, corresponding to the elements of the security policy that conflict with each other. By detailing these cases, we identify some inconsistencies corresponding to a trade-off between functionality and security in the organization, that may be tolerated in the specification. Furthermore, we argue that the formalism also offers the opportunity to complement the security policy with a description of the vulnerabilities of the information system. However, it is highly desirable to completely describe the insecure states corresponding to inconsistencies in order to have a chance to trust the system. The structure of the paper is the following : Section 2 presents the various elements of an organization security policy and the potential conflicts that it may contain. Section 3 provides the definition of the specification language used in this paper. Section 4 details the application of the method to an information system. Section 5 presents a practical application example, addressing the security needs of a bank agency. Finally, we conclude in Section 6.
2 2.1
Presentation of the Approach Security Policy Components
The security policy of the system corresponds to the description of its security needs. According to [10, Section 2.9], the security policy is “the set of laws, rules and practices that regulate how sensitive information and other resources are managed, protected and distributed within a specific system”. In this paper, we consider that a security policy defines : – the security objectives, i.e. the confidentiality, integrity and availability properties expected of the system ; – and the security rules which are imposed on the mechanisms which can modify the security state of the system, in order to guarantee the security properties.
A Flexible Method for Information System Security Policy Specification
69
The components of the security policy refer to specific entities of the system (e.g. specific subjects or objects, available operations, or an organization chart). First, these description elements are added to the policy. In an organization for instance, the names of the various individuals are mentioned. Additional description rules may also be added to the specification in order to reflect the functional behavior of the system when this behavior may impose constraints on the security-related aspects of the system. In an organization, such functional rules represent the various information flows existing in the organization and the way they interact with each other. The description of these operational rules brings information that help the security administrator to adapt the security policy to the actual operation of the organization. The description of the system operation is limited to the basic elements needed to formulate the security mechanisms and objectives, and to the operational rules that describe the portions of the information system relevant to security. Therefore, this description should remain minimal, and additional elements or rules should be introduced only when needed. Second, the security policy contains the security rules to be enforced by the system. These rules reflect the way in which the security state of the system evolves. In an organization, such rules define, for example, who can assign a new position to an individual, or on which condition someone may delegate some of his privileges to another person. Finally, the security policy defines several security objectives that specify the desired security properties for this system. The set of all these properties defines the states of the system that are acceptable with respect to security. A security state of the system that satisfies all the security objectives of the system security policy is a secure state. An insecure state is a state where these properties are not satisfied. 2.2
Refinement
The first version of the security objectives introduced in the security policy will probably be rather generic. Therefore, it is very probable that these objectives will be too restrictive and easily invalidated by the operation of the organization. To resolve this problem, the introduction of new elements may be necessary to limit the scope of an objective. Similarly, it may be necessary to introduce new description rules, or accurately detail the various steps of a given task in order to focus on a desired security property. Therefore, the description of the organization will undergo several refinement steps, enabling to clarify the security objectives and to improve the whole policy. Furthermore, the verification of the policy can benefit from an incremental approach, as we will see in Sect. 4.2. 2.3
Security Policy Consistency
The security policy is consistent if, starting from a secure state one cannot reach an insecure state without violating the security rules. Given the different security policy components, we can distinguish several types of potential inconsistency :
70
Rodolphe Ortalo
– First, the description of the system may be inconsistent due to conflicting functional rules. However, this is not a security-related specification problem. – Several security objectives may be contradictive. In this case, no secure state exists and it is impossible to enforce the policy, therefore the security objectives should be updated (e.g. by reducing their scope, or adding priorities). – Some of the security rules of the specification may contradict each other. For example, an individual may be able to reach a situation in which an obligation and an interdiction hold simultaneously with respect to the same action (e.g. due to conflicting roles). The modification of the security mechanisms may prevent such conflicts. However, it is also possible that the behavior of the system eliminates the situations in which these conflicts can occur. If so, description rules could be added to the system description to describe the functioning more accurately. – The verification of each security objective, starting with the system security rules, may reveal an inconsistency. In this case, security rules fail to enforce the objectives. Such inconsistency means that either security objectives should be revised, or it is needed to introduce new security rules to enforce the expected properties. – Finally, it is possible that the functional rules conflict with the security objectives. This case identifies weaknesses in the organization operation showing that it is possible to bypass the security rules. To face this problem, two directions are possible : it is possible to modify the organization operation (and therefore decide to adapt the organization to the envisaged security mechanisms), or to consider new security mechanisms which are compatible with the actual operation (i.e. adapt the security policy to the information system). We can identify the mandatory consistency requirements of a security policy specification. First, it seems necessary that the consistency of the system description be obtained. If the description of the system functioning is incorrect, adding security requirements to the policy is a nonsense. Second, if several security objectives are contradictive, i.e. if the enforcement of one objective implies the failure of another, the information system is always in an insecure state. Therefore, consistency of the set of all security objectives is necessary : if two security objectives contradict, a choice must be made. Other inconsistency types reflect problems such as incomplete security mechanisms that fail to enforce the security objectives, over restrictive security rules that may lead to opposed permissions and interdictions in specific situations, or dangerous functioning of the system that may allow to bypass the security mechanisms. In practice, some of the security policies defined in organizations exhibit such inconsistencies [5]. Furthermore, a situation in which such problems occur may be acceptable if it corresponds to a legitimate trade-off in the organization. Exhaustive description of the insecure states is necessary to trust the system, but security issues may not need to be totally reconsidered. The purpose of the introduction of a description of the system behavior in our approach to security policy specification is precisely to allow such precise insecure states
A Flexible Method for Information System Security Policy Specification
71
identification for some classes of inconsistent policies. Of course, improvements may also be proposed, but the corresponding mechanisms may not be possible to be enforced in the organization if they perturb its normal operation, and we think that the security policy specification should take this fact into account and cope with some inconsistencies. This point of view can be extended. We can envisage to complement the system security policy by a description of the potential vulnerabilities of the system. Vulnerabilities may be due to intrinsic weaknesses of the used security mechanisms (such as cryptographic keys length), or to flaws identified after the system has started its operational life [10, Para. 3.25-28], [11, Sect. 6.C]. Such vulnerabilities compromise theoretically the security of the system, but may be very difficult or very long to exploit. The identification of the insecure states due to vulnerabilities allows to assess their impact on the security objectives. This assessment should help the information system security administrator to propose relevant changes given the known vulnerabilities of the system.
3
Specification Language
In order to handle such cases, we need a security policy specification formalism flexible enough to separate the functional description of the system and the security needs description, and which furnishes methods for exploiting inconsistent specifications due to the integration of vulnerabilities in the description. Modal logic, or more precisely deontic logic, is a formal framework that seems to be expressive and adaptable enough to specify security policies of organizations [9,12,4]. Deontic logic is a branch of modal logic to reason about normative versus non-normative behavior by means of modal operators such as ought, permitted and forbidden [15, Preface]. Furthermore, by using these special operators, deontic logic provides a mean to specify that some behaviors of the system are non-normative (illegal) but nevertheless possible. We present briefly in this section the deontic logic language that we selected. A general presentation of modal logic can be found in [3]. 3.1
Deontic Logic Language
Like any modal logic, deontic logic is an extension of usual propositional logic by one or several deontic operators. More precisely, if Φ is a set of atomic propositions a, b, c, ..., if ¬, ∨, ∧, ⇒ and ⇔ are the usual boolean operators, and if O, P and F are the three modal operators of deontic logic, the deontic language denoted LO (Φ), or simply LO when it raises no ambiguity, is the set of formulas (or sentences) built with the following rules : – if p ∈ Φ, p is a formula ; – if p and q are formulas, ¬p, p ∨ q, p ∧ q, p ⇒ q, and p ⇔ q are formulas ; – if p is a formula, Op, Pp and Fp are formulas.
72
Rodolphe Ortalo
A modal formula is a formula of LO which contains at least one operator O, P or F. A non-modal formula is a formula which contains none. In natural language, formulas Op, Pp and Fp are read, respectively, “It is obligatory that p”, “It is permitted that p”, and “It is forbidden that p”. Therefore, operFp = O¬p (1) ators O, P and F denote respectively the noPp = ¬O¬p (2) tions of obligation, permission and interdiction. Op ⇒ Pp D Conforming to the definitions of necessity (operator ✷) and possibility (operator ✸) in classi- O (p ⇒ q) ⇒ (Op ⇒ Oq) K p cal modal logic, one can state relations between RN Op these various operators. First, F can be defined from O by (1). P is the operator dual of O. Therefore, one can also consider the relation (2) between operators O and P, similar to the relation between necessity and possibility in classical modal logic. Finally, standard deontic logic [3, Chap. 5], also contains axiom D which relates obligation and permission. A modal logic system is an extension of propositional logic, therefore it contains all the axioms and inference rules of propositional logic. Thus, LO contains all tautologies and is closed under modus ponens. We consider in this work a normal modal logic system, i.e. a system that contains axiom K and the inference rule RN (“Rule of Necessitation”). In this paper, we want to use deontic logic for the practical representation of security properties. Even though it may have a direct impact on our work, studying deontic logic in itself, or as a formal language for reasoning about legal issues and normative systems (or security), is out of the scope of this presentation. Therefore, we use standard deontic logic, i.e. the KD system of classical modal logic. Especially we accept (2) as a suitable definition of permission. However, these simplifications are done in order to clarify the security policy specification method, and they do not prevent further extensions of the logical language used, such as suggested in [3, Chap. 10]. Finally, we recall the semantics associated to a normal modal logic language like LO . It is a Kripke’s semantics, or possible world semantics [13]. A Kripke model M for a modal logic system is defined by a triple W, R, V where W is a set of possible worlds w, R is a binary relation over W called the accessibility relation, and V : W × Φ → {true, false} is a function furnishing in each world w ∈ W the truth value V (w, p) of the atomic proposition p. The fact that proposition p is true in a world w of model M is noted |=M w p. This truth value is defined in the following way1 , which extends usual propositional calculus : if p ∈ Φ, |=M w p if and only if V (w, p) = true |=M ¬p if and only if we do not have |=M w w p M M |=w (p ∧ q) if and only if |=M w p or |=w q M |=M w Op if and only if ∀w ∈ M/wRw , |=w p
– – – –
The first three statements conform to the classical truth value definition of a formula in propositional logic. From the last definition, we see that in the 1
Using ¬ and ∨ as the fundamental boolean operators.
A Flexible Method for Information System Security Policy Specification
73
Kripke’s semantics the formula “It is obligatory that p” is true in a world w if and only if p is true in every world w which w is in relation with. When w is in relation with w , we say that w is directly accessible from w, or equivalently that w is a possible world for w . The definition of the truth value of Pp is easily deduced from the one of Op using (2) : M – |=M w Pp if and only if ∃w ∈ W/wRw , |=w p
3.2
Language Extensions
The language LO , or LO (Φ), is based on a set of atomic propositions Φ. In order to ease the specification task, it is desirable to introduce constructs allowing a structured and hierarchical description of the various formulas of LO . Therefore, we propose to use a syntactical extension of this language, denoted LO . Let Π be a set of sets A, B, C, . . . , ordered by the partial order relation of inclusion ⊆. The language LO (Π), or simply LO when it raises no ambiguity, is syntactically identical to the language LO defined in Sect. 3.1. This extension is purely syntactical. Its interest resides in the possibility of structuring the atomic propositions of the language through a hierarchical description of a set by its subsets. In order to ease the construction of the various sets E elements of Π, we allow the use of the operator × (set product) to define the elements of Π, with the natural extension of the relation of inclusion.2 The deontic language LO (ΦΠ ) associated to the extended language LO (Π) is built considering the set ΦΠ defined as ΦΠ = {E ∈ Π/ (∀E ∈ Π, E ⊂ E)}. Therefore, ΦΠ is the set of all the terminal sets of Π, i.e. the sets that do not contain any other sets and form the basis of the hierarchy defined by relation ⊆. A sentence f of LO (Π) is associated to a set Σf of formulas of LO (ΦΠ ) defined recursively by (3), Σf |E←E (3) Σf = where f |x←y is the formula built by substituting E ⊆E for all the occurrences of symbol x the symbol y in formula f . Therefore, a formula f of LO (Π) is a short notation for several formulas of LO (ΦΠ ). These formulas are those obtained by replacing, in f , every occurrence of a non-terminal set of Π by its content until we obtain formulas mentioning only elements of ΦΠ . Using Set Constructors. Similar notations allowing the direct use of sets within formulas have already been applied to logical languages developed for database systems [14]. These extensions aim at facilitating the specification task. Sets allow for a progressive and hierarchical description of the basic elements of the security policy, and these sets can be used directly in the formulas of the extended language. To illustrate the use of this notation, we consider now several formulas written in LO (Π) and the equivalent set of formulas in LO (ΦΠ ).3 E × E = {(e, e ) /e ∈ E, e ∈ E }, and E × E ⊆ F × F ⇔ E ⊆ F ∧ E ⊆ F . In these examples, sets A, B, ‘Administrators’, ‘Software types’ and ‘Departments’ refer to sets containing atomic propositions only. ‘Install’ is itself an atomic proposition, i.e. an empty set. 2 3
74
Rodolphe Ortalo
A simple equation of the extended language LO , e.g. P (A ∨ B), should be represented by a whole set of formulas in LO , here : {∀p ∈ A, ∀q ∈ B, P (p ∨ q)}. The set product operator × of LO (Π) allows the definition of structured sets as elements of the language. This eases the description of various items starting with some of their typical features. Hence, formula (4) states directly a set of permissions associated to software installation tasks. These tasks are described by the action symbol ‘Install’, the various people allowed to perform the installation gathered in the set of the system administrators, and the various target software. Pieces of software are themselves described through two characteristics: their type (word processor, spreadsheet, etc.), and the organization department that owns them. The description of all these elements in the original language LO would necessitate the definition of many elements, sharing common typical characteristics. Formula (5) shows such a set. As can be seen, in a conventional notation, set product corresponds to several indices. P (Install × Administrators × (Software types × Departments)) P Installa,Softwaret,d a∈Administrators,t∈Software types,d∈Departments
(4) (5)
Graphical Representation. These extensions also make the specification language suitable for a graphical presentation that can be manipulated with classical user interaction techniques (drag and drop, etc.). This graphical representation represents the sets hierarchy leading to the definition of the atoms of the language using hierarchical lists. The operators of the language are also represented using graphical artifacts called slot-boxes. The purpose of this representation is to provide a simple and convenient method to define and manipulate the security policy specification elements. Figure 1 presents an example of this representation for defining the content of the sets mentioned in (4). Departments Management Production Sales
Software types Word processors LATEX, . . . Compilers Spreadsheets
Administrators A1 A2 A3
Fig. 1. Example of sets graphical representation
This graphical approach has been implemented within a tool enabling to define and modify easily a security policy. This editor is based on the Amulet graphical library [16] which was very convenient for this realization. In the remaining of this paper, we will adopt this graphical representation for sets, but for space reasons, we will use a conventional linear notation for formulas involving operators.
4
Application to Information Systems
Security needs justifying the elaboration of a security policy appear in many organizations. For example, we can mention banks (transactions integrity),
A Flexible Method for Information System Security Policy Specification
75
telecommunication companies (system availability), or medical and public-health services (legal confidentiality obligations). However, all these organizations also have other priorities distinct from security. In this section, we present how the deontic logic language presented previously can be applied to the specification of the security policies of such organizations, and the various possible situations associated to the specification verification. 4.1
Guidelines
In the context of an organization, a security administrator would be in charge of the security policy definition. While this administrator would probably have a good knowledge of the target organization, it is probable that he would not be familiar with a modal logic language. Therefore, we detail several steps of this formalization process. Reuse of available information. Most of the description elements of the specification appear in documents describing the organization and its operation. These elements are related to physical entities, individuals, or a functional decomposition of the organization. They refer also to specific attributes (such as confidentiality levels). Many of these items appear in description documents already available in the organization, such as an organization chart, some tasks definition documentation, handbooks, norms if applicable, etc. With respect to security issues, other documents help the system administrator. For instance, organization charts also mention the individuals situation in the hierarchy and their privileges. The policy can also be based on existing regulations, documents supporting the evaluation of the organization according to a set of security criteria [10], a previous risk analysis, laws if applicable to the organization, etc. When the security policy specification target is a system to be designed (and not a system in operation), the security designer should look for equivalent information existing in the design documents. System description. In the deontic logic language presented previously, the description of the organization is performed through the introduction of atomic propositions representing the basic elements, and non-modal formulas (built with the operators of usual propositional logic) representing the aspects of the functioning that are relevant for security. For example, consider the process of internal purchase in an organization : an employee formulates a purchasing demand, which must probably be validated by a manager before going to a specialized department that performs the operation. In order to describe these different steps, first one needs to introduce several atoms such as ‘demand’, ‘manager authorization’, ‘order’ and ‘delivery’. Then, one can state the causal dependencies between these steps and the condition for an order to be actually sent by the purchase department. This is represented by logical formulas like : demand ∧ manager authorization ⇒ order and order ⇒ delivery. Security rules. The security mechanisms existing in the system are added to the description of its operation. A security mechanism describes the link between the permissions (or interdictions) and the state of the system (or, more precisely, only a subset of the whole state of the system : its security state,
76
Rodolphe Ortalo
made of security attributes). Therefore, it may be represented by a modal formula stating a permission conditioned by some non-modal formula, such as : directory writable ⇒ P (rename the file). Integration of roles. The main asset of role-based policies resides in the opportunity that they offer to specify constraints on abstract elements (the roles) instead of enumerating several analogous constraints for all the concerned subjects [19]. Formula (4) presented previously shows that the possibility to use sets directly in a formula in LO allows to define and use easily user groups. To support roles, we enumerate not only the various roles, users and permissions, but also the desired pairs (role, user), and use modified authorization rules that constrain users permissions according to user roles. For example, we may modify (4) to : P(Install × Agent × Software) ⇒ Administrator × System administrator. In this approach, roles appear as intermediate abstract entities between the permissions in the system and the actual users. This extra level improves the flexibility of the specification, as roles are defined independently of the elements they relate. This flexibility is achieved at the cost of an extra specification work to associate users to roles. As shown in [17], several variants of this method can be used to introduce roles in a deontic logic specification. Security objectives. Finally, we use the basic elements defined previously to describe the security objectives of the information system. If a regulation exists in the organization, it will be transposed in the security policy specification. The deontic logic language allows an easy definition of the security objectives, through the use of the obligation, permission and interdiction operators that allows a natural wording of the desired security properties. Therefore, a security objective is usually represented by one modal formula, such as Op or F (p ∧ ¬q). 4.2
Exploiting the Specification
An asset of a formal language resides of course in the availability of formal calculus methods, useful to reason about the security policy. Several directions may be followed to address this issue. See [8,6] for a general presentation of modal logic proof theory, and [4] for an application to the verification of security properties. Provided that this calculus exists, several verifications can be performed on the specification corresponding to the various inconsistency types identified in Sect. 2.3. With respect to validation problems, the incremental process presented in Sect. 2.2 exhibits new advantages. Non-modal formulas, such as p, p∨q, p∧q ⇒ r, corresponds to the description of the system components and functioning. Such formulas must form a consistent basis for the security policy. Therefore, validation of all the non-modal formulas should be done separately, prior to further verification of the security-related formulas. As these formulas only form a partial description of the system and are propositional logic formulas, their number is limited and we do not expect their validation to be prohibitive. When inconsistency comes from the combination of two security objectives (this can be checked directly by verifying the conjunction of the two corresponding modal formulas in the chosen modal system), a choice must be made. This
A Flexible Method for Information System Security Policy Specification
77
situation may be difficult to manage if it is attempted to verify the whole security policy directly in one step. However, if the specification process follows the incremental method suggested, the verification of the security objectives compatibility should be done separately4 . We can also check that the security policy specification exhibit some properties, such as the fact that there are no conflicting obligation and interdiction. This is represented by ¬ (Op ∧ Fp), which must be true in the specification. Inconsistency types potentially related to an organization trade-off appears mainly when considering the Kripke’s semantics of the deontic logic security policy specification. An inconsistency appearing between formulas describing security rules, such as p ∧ q ⇒ Fr or p ⇒ Pq, means that the semantic model M of the specification contains a world w (corresponding to a system state) in which M several permissions or obligations conflict (e.g. both |=M w Pp and |=w Fp hold for some p and w). Similarly, an inconsistency appearing after the addition of a security objective to the specification shows that there exists worlds in the model where the modal property corresponding to the objective is not true. In each case, a model M invalidating the specification identifies the various intermediary states leading to an insecure state as well as the possible transitions between them, as it provides the truth values V (w, p) of the atomic propositions in each world, as well as the relation R between the worlds. The verification process may exhibit a counter-model M invalidating the specification. In this case, the counter-model may be used to identify the various rules (either functional rules or security rules) involved, as well as the conditions on the state of the system that allow this failure. With this information, modifications may be proposed. If the functioning of the system never allows such situations (e.g. one person simultaneously associated to all the roles in the system), additional formulas may be incorporated to the security policy to rule out such states. If a succession of applications of security rules allows to defeat the proposed objective, either the rules may be updated or the objective revised. Finally, if the behavior of the system allows to bypass several security rules and defeat the security objective, modifications of the operation of the system may be proposed in order to improve its security. In each case, the trade off between security issues and operational issues may be difficult to manage, but the information extracted from the counter-model M helps the system administrator to determine the appropriate solution. The interest of the information that can be extracted from such a counter-model may favor the use of a semantics-based deduction method for the verification of a deontic logic security policy specification, such as those presented in [7,2]. 4
It should be noted that, with the language presented in Sect. 3, it is also possible that global inconsistencies, similar to those corresponding to conflicting objectives, result from a combination of propositional formulas (describing the functioning) and formulas describing security rules. This specific case corresponds to the fact that in a specific system state some security rules lead to a contradiction, and, simultaneously, the functioning of the system always leads to this state. This case should be treated like conflicting objectives and be eliminated.
78
Rodolphe Ortalo
We see that the specification, even when inconsistent, can be exploited usefully. In fact, we argue that the ability to analyze precisely and exhaustively the various possible evolutions of the state of the system that contradict a security objective is very important in the context of an organization information system. In this context, the verification of the whole specification is very likely to fail due to contradictory objectives, or incomplete or inadequate security rules. Furthermore, it may be acceptable to tolerate inconsistencies, if all the evolutions of the information system that may lead to an insecure state are very improbable or very difficult to exploit. This assessment can rely, for example, on an evaluation method [18]. However, such situations cannot be understood if a precise description of the security needs does not provide the information needed to qualify the insecure states. 4.3
Description of Vulnerabilities
The approach finally offers the opportunity to include in the security specification additional components potentially leading to inconsistencies, representing the dp = Pp (6) vulnerabilities of the information system. In (6), we dep ∧ dq ⇒ ✸dr (7) fine a right dp with respect to a proposition p as the p ∧ Pq ⇒ ✸Pr (8) permission of p. We propose to define a vulnerability as the fact that, given a right and a specific state of the system, it is possible to obtain a new right (possibly not legitimate). We describe this as the property that “if a non-modal (propositional) property p and a right dq are true in a world w, then there exist another world w in relation with w such that another right dr is true in w .” Therefore, we represent a vulnerability by a rule like (7). Given the definition of a right, a vulnerability is of the form of (8). This definition allows the description of general vulnerabilities and, on the contrary of [18], makes a clear distinction between the normative aspects of the specification (captured by the deontic operator P) and the opportunities offered to a potential attacker (captured by the ontic operator ✸).
5
Example
To illustrate the security policy specification method, we present an example of its application. The target organization is a bank agency, counting 35 employees, and located in a rural area. The security policy presented in this section was built on the basis of several internal documents describing the organization. The analysis of these documents has been completed by a study in the field which lasted several days. The bank help manual identifies more than a hundred different operations potentially performed in the organization, from foreign currency deposit to account freezing following a legal injunction. Among all these operations, only a limited number are integrated in the following specification. We chose to consider operations involving loan agreement, and bearer bonds. These tasks are interesting as the first relies on a delegation mechanism, and the other is considered security-critical due to anonymity.
A Flexible Method for Information System Security Policy Specification
5.1
79
Formalization of the Organization Description Documents
The initial elements of the specification are presented in Fig. 2. We note the various individuals mentioned in the policy, several actions, and also a set of roles. The set ‘Individuals’ is further split into two subsets : ‘Customers’ is left unspecified and designates any potential customer of the bank, ‘Agents’ enumerates all the employees of the organization (they are identified by numbers from 1 to 35 in this paper). The roles used in this specification are related to the functions existing in the organization. All the official functions mentioned in the organigram are gathered in the set ‘Employment’ (defined later) which is therefore a subset of all roles. However, our practical study allowed us to identify a separate unofficial role, ‘Cashier’, necessary to formulate the security rules of the organization. Astonishingly, it is not explicitly associated to a function in the organigram. Finally, the set ‘Actions’ contains the various tasks included in the specification. Only three general types of action are considered in this example : common operation performance, loan agreement, and physical access. Agents A1 A2 ··· A35
Actions Do × Operations Grant a loan × Loans Access × Physical elements Individuals Customers Agents
Miscellaneous Amount Balance Physical elements Movements Folders Movement types Account Complaint
Roles Employment Cashier
Roles mapping Agents mapping A16 × Cashier
Fig. 2. Security policy specification root
The various organization description elements are given in Fig. 3. The set ‘Employment’ describes the employee functions (corresponding to roles). It corresponds to a position description document available in the bank. This document identifies several abstract positions that gather different positions actually held by the employees (e.g. ‘Leader’ groups positions such as agency leader, office manager, etc.). The roles introduced in Fig. 2 allow to define generic description and security rules independently of the actual agents of the organization. To obtain the actual description we need to specify also a mapping between individuals and roles. The mapping of agents to roles, ‘Agents mapping’, obtained using an organigram of the organization, is defined in Fig. 3. We note in this figure that one agent may be associated to several roles, e.g. A7 is a manager as well as a service agent. A16, the agent playing the role of the cashier is identified directly in Fig. 2. The various operations performed in the organization, presented in the set ‘Operations’, are also organized in several subsets. The description is limited to the higher levels and the detailed list of all operations has not been included. In this figure, we also introduce several secondary elements. Finally, we include in these description elements a simple representation of the data associated to a bank account. In order to describe the functioning of the organization, we also need to include description rules. As an example, we show in Fig. 3 how accounts and money movements can be represented. These rules state for example that an usual operation necessitates physical access to one of the bank terminals, and
80
Rodolphe Ortalo
that such an operation results either in a debit or credit money movement on an account. Of course, this is a simplification of the real functioning. A specific description rule represents the fact that a debit operation, when performed on a negative balance account, follows an exceptional path. The proposition ‘Freezing’ is a label identifying the exception. Here, this label does not mean that the operation cannot be performed.5 Employment Agency chief executives Agency manager Agency manager assistant Leader Market leader Position leader Office manager Agency leader Position manager Service agent Private cust. service agent Farmer service agent Professional service agent Collection assistant Highly skilled clerk All market comm. assistant Clientele adviser Customer clerk Skilled clerk Secretary
Operations Usual operations Loan operations Stocks and shares Bearer bonds Non-banking operations Insurance Flows management Main cash desk ATM Foreign currencies Internal operations Forcing control Litigations Customer incidents Cash desk incidents Agency management Staff management Movement types To Credit To Debit
Position Positive balance Negative balance Accounts ⊆ Customers × Position
A1 × Agency manager A2 × Agency manager assistant A3 × Secretary A4 × Secretary A5 × Agency leader A5 × Private cust. service agent A6 × Agency leader A6 × Professional service agent A6 × Farmer service agent A7 × Position manager A7 × Professional service agent A8 × All markets comm. assistant A9 × Professional service agent A10 × Professional service agent
A11 A12 A13 A14 A15 A16 A17 A18 A19 A20 A21 A22 A23 A24
× × × × × × × × × × × × × ×
Folders Loans folders Private cust. loans Consumer loans Professional loans Farmer loans Agency manager delegation auth. for A5 auth. for A7 ··· Amounts < $250, 000 ··· < $20, 000 < $8, 000 Physical elements Main safe Terminal ATM
Movements ⊆ Movement types × Account × Amount Agents mapping Professional service agent Farmer service agent Farmer service agent Farmer service agent Skilled clerk Skilled clerk Skilled clerk Skilled clerk Private cust. service agent Private cust. service agent Clientele adviser Skilled clerk Clientele adviser Clientele adviser
A25 A26 A27 A28 A29 A29 A30 A31 A32 A33 A34 A35
× × × × × × × × × × × ×
Skilled clerk Private cust. service Private cust. service Private cust. service Private cust. service Position manager Private cust. service Private cust. service Private cust. service Private cust. service Private cust. service Clientele adviser
agent agent agent agent agent agent agent agent agent
Description rules Agents × Actions ⇒ Actions Agents × (Do × Operations) ⇐ Agents × (Access × Terminal) Do × Loan operations ⇒ Loan folders Do × Usual operations ⇒ To Debit × Account × Amount ∨ To Credit × Account × Amount Customers × Negative balance ⇒ Freezing × (To Debit × Account × Amount) Grant a loan × Loans ⇒ To Credit × Account × Amount
Fig. 3. Security policy description elements 5 Debit operations on a negative balance account can be eliminated by a formula such as : Customers × Negative balance ⇒ ¬ (To Debit × Account × Amount). We do not include such a rule in our specification because it does not correspond to the actual functioning of the bank. Agents treat such money movements with specific care, but they can perform them.
A Flexible Method for Information System Security Policy Specification
5.2
81
Description of the Security Needs Security rules P(Agents × (Do × Usual operations)) ⇒ (Agents × Employment) P(Agents × (Do × Loan operations)) ⇒ (Agents × Service agent) P(Agents × (Access × Main safe)) ⇒ (Agents × Cashier) ∨ (Agents × Agency manager) Agents × Actions ∧ Freezing × Actions ⇒ O(Forcing × Agents × Actions) P(Agency manager delegation) Delegation rule Delegation rule Agency manager delegation ∧ (Agents × Employment) ∧ Loan authorizations ⇒ P( P(Agents × (Grant a loan × Loan)) ) Loan authorizations Professional market Service agent × (Professional loans× < $70, 000) Leader × (Professional loans× < $90, 000) Agency chief executives × (Professional loans× < $110, 000) Farmer market Service agent × (Farmer loans× < $70, 000) Leader × (Farmer loans× < $90, 000) Agency chief executives × (Farmer loans× < $110, 000) Private cust. market Service agent × (Private cust. loans× < $40, 000) Leader × (Private cust. loans× < $90, 000) Agency chief executives × (Private cust. loans× < $140, 000) Consumer projects Service agent × (Consumer loans× < $8, 000) Leader × (Consumer loans× < $18, 000) Agency chief executives × (Consumer loans× < $28, 000) Company market Leader × (Consumer loans× < $120, 000) Agency chief executives × (Consumer loans× < $240, 000) Security objectives F(Customers × (Do × Usual operations)) F(Agent × Grant a loan × Loans ∧ Agents × Employment ∧¬Loan authorizations ∧ Loans × ¬( < $100, 000)) F(Customers × Complaint)
Fig. 4. Security requirements description
The rules describing the security needs of the organization are shown in Fig. 4. Among these rules, we focus on a specific aspect involving delegation of privileges : loan agreement delegation. Chief executives are allowed, in this organization, to delegate some of their privileges to other employees, in the limit fixed by several conditions. The rule itself is shown in the table entitled ‘Delegation rule’, and the second table ‘Loan authorizations’ enumerates the loans categories and maximal amounts that may restrict the delegation rights of the agency manager. Note that the abstract positions identified formerly in Fig. 3 (e.g. ‘Leader’) are used to define the various authorizations, illustrating the interest to describe hierarchically the set ‘Employment’. The mechanism of loan agreement delegation that exists in this bank is a typical example of a situation in which a deontic logic specification language may be most useful. The general bank rules state that an agency manager can delegate some of his privileges (with respect to loan decisions) to other employees. These rules define several limits that the agency manager must respect in his delegation decisions, but nothing more. Therefore, the manager defines the actual permissions of the agents. We represent this functioning in the specification using two nested P operators meaning that permission is granted (to the agency manager) to grant permission to one of his
82
Rodolphe Ortalo
agents to accept a loan. However, even if it is authorized, the manager may not delegate full permissions to an agent, e.g. if the latter does not need them as he works on a specific market. Finally, Fig. 4 presents three simple security objectives. The first one is related to customers, but the other two apply to the agents of the organization. The second one aims at enforcing the delegation authorizations with respect to loan agreement, and the last one at protecting customers from abuses perpetrated by employees. 5.3 Integration of Vulnerabilities As an example, we consider now two vulnerabilities of the bank agency. These vulnerabilities are presented in Fig. 5. The first one is related to trust relationships between the various agents of the organization. We also consider that a customer may trust the agent in charge of his business. Such trust may allow a malicious agent of the organization to misappropriate funds of this customer. However, in our case, we think that this vulnerability arise only for specific operations, more precisely anonymous stocks and shares operations. Vulnerabilities Agents × Trusts × Other agent ∧ P (Agents × Actions) ⇒ ✸P (Other agent × Actions) Customers × Trusts × Agents ∧ (Agents × Bearer bonds) ⇒ ✸ (¬ (Customers × Complaint))
Fig. 5. Vulnerabilities
The first vulnerability shown in Fig. 5 conflicts with the second security objective shown in Fig. 4. A study in the field allowed us to check in the real organization the various conditions under which a given vulnerability may appear (i.e. to obtain all the true propositions of the form Agents × Trusts × Other agent). Given this information, we identified all the possible scenarios allowing an agent of the organization to defeat the second or third security objective. We observed that trust relationships were numerous in this organization between the employees (174 trust relationships are very strong), and several agents indeed could defeat the loan agreement authorization limits. As it is surely impossible (and probably ill-fated) to regulate the everyday life and the trust relationships existing among the agents, these results do not allow one to influence directly the operation of the organization. However, comparison of these results with the situation of each agent (with respect to his seniority, position or skills) could reveal anomalies in privileges distribution in the organization. In our case, no abnormal tendency arose from the results analysis. In the specification considered in this example, the second vulnerability conflicts directly with the third security objective. We studied an alternate functioning of the target organization involving validation of all bearer bonds operations by one specific employee before completion. In this case, only a malicious agent who abuses one of his customer’s trust and the agent in charge of the validation is able to infringe the objective. This means that, given the revised functioning, both vulnerabilities shown in Fig. 5 may conflict with the third security objective of the organization. However, detailed analysis of the possible insecure states shows that they are much less numerous given the revised functioning than with the original one. Therefore, such functioning appears acceptable.
A Flexible Method for Information System Security Policy Specification
6
83
Conclusion
The information systems addressed in our study are commonly found in organizations such as banks, industrial companies, etc. Our approach focuses on organizations where security is not the only requirement even though security issues are important. For these organizations, the definition of a security policy necessitates a pragmatic approach, taking into account the functioning of the target information system. Most of the classical security policies define security properties expected of the system independently of a description of the system itself. But such policies also impose strong constraints on the operation of the target system or organization, which may not be acceptable in the context of a conventional information system. In our case, on the contrary, the security policy definition integrates a partial description of the information system. This allows to reuse available information, and to adapt the definition of the security objectives and rules to the target organization structure and behavior. In practice, security rules and objectives may be more detailed and fit better the actual operation of the organization. Based on a formal language, deontic logic, the method offers the opportunity to perform the verification of the policy. But we identified several types of inconsistency, and some of them correspond to admissible trade-off between security and other requirements of the organization, such as flexibility or efficiency. In these cases, the policy fails to be consistent. However, the verification of the security policy should provide a mean to identify exhaustively all the potential insecure states of the information system and could be a valuable help to the security administrator who manages such trade-off. Furthermore, a suitable description of the information system vulnerabilities can be proposed using the proposed specification language. This description fruitfully complements the security policy as the formalism offers the opportunity to identify precisely the impact of the vulnerabilities considered on the security of the organization, using verification mechanisms similar to those associated to consistency checking. This information will facilitate the task of the administrator to evaluate the gravity of the organization vulnerabilities, and to propose modifications of the functioning or of security rules in order to improve security.
Acknowledgments The author is grateful to the Cr´edit Agricole, and more especially to the CRCAM Quercy-Rouergue for their collaboration, as well as to all of the staff of the agency of Villefranche de Rouergue for their pleasant welcome. This work has been partially supported by UAP Assurances, and European ESPRIT Project 20072 “Design for Validation” (DeVa). Finally, I would like to thank Claudia Almeida, Marie Borrel, Fr´ed´eric Cuppens, Yves Deswarte and the anonymous referees for their help on this work.
84
Rodolphe Ortalo
References 1. D. E. Bell, L. J. LaPadula, Secure Computer Systems: Unified Exposition and Multics Interpretation, The MITRE Corporation, Report ESD-TR-73-306, 1975. 68 2. L. Catach, “TABLEAUX: A General Theorem Prover for Modal Logics”, Journal of Automated Reasoning, vol. 7, pp. 489-510, 1991. 77 3. B. F. Chellas, Modal Logic: An Introduction, 295 p., ISBN 0-521-29515-7, Cambridge University Press, 1980. 71, 72 4. L. Cholvy, F. Cuppens, “Analyzing Consistency of Security Policies”, in IEEE Symposium on Security and Privacy, Oakland, California, May 4-7, pp. 103-112, ISBN 0-8186-7828-3, IEEE Computer Society Press, 1997. 68, 71, 76 5. F. Cuppens, C. Saurel, “Specifying a Security Policy: A Case Study”, in 9th IEEE Computer Security Foundations Workshop, Kenmare, Ireland, June 10-12, pp. 123134, ISBN 0-8186-7522-5, IEEE Computer Society Press, 1996. 70 6. L. Fari˜ nas del Cerro, A. Herzig, “Modal Deduction with Applications in Epistemic and Temporal Logic”, in Handbook of Logic in Artificial Intelligence and Logic Programming, Epistemic and Temporal Reasoning (D. M. Gabbay, C. J. Hogger, J. A. Robinson, Eds.), vol. 4/5, pp. 499-594, ISBN 0-19-853791-3, Oxford Science Publications, 1995. 76 7. M. Fitting, “First-Order Modal Tableaux”, Journal of Automated Reasoning, vol. 4, no. 2, pp. 191-213, 1988. 77 8. M. Fitting, “Basic Modal Logic”, in Handbook of Logic in Artificial Intelligence and Logic Programming, Logical Foundations (D. M. Gabbay, C. J. Hogger, J. A. Robinson, Eds.), vol. 1/5, pp. 365-448, ISBN 0-19-853745-X, Oxford Science Publications, 1993. 76 9. J. Glasgow, G. McEwen, P. Panangaden, “A Logic for Reasoning About Security”, in Computer Security Foundations Workshop, Franconia, pp. 2-13, IEEE Computer Society Press, 1990. 68, 71 10. ITSEC, Information Technology Security Evaluation Criteria, v1.2, 163 p., ISBN 92-826-3004-8, Office for Official Publications of the European Communities, Luxembourg, 1991. 68, 71, 75 11. ITSEM, Information Technology Security Evaluation Manual , v1.0, 262 p., ISBN 92-826-7087-2, Office for Official Publications of the European Communities, Luxembourg, 1993. 71 12. A. J. I. Jones, M. Sergot, “Formal Specification of Security Requirements using the Theory of Normative Positions”, in Second European Symposium On Research In Computer Security (ESORICS 92), (Y. Deswarte, G. Eizenberg, J.-J. Quisquater, Eds.), Toulouse, France, November 23-25, LNCS, 648, pp. 103-121, ISBN 3-540-56246-X & 0-387-56246-X, Springer-Verlag, 1992. 68, 71 13. S. A. Kripke, “Semantical Considerations in Modal Logic”, Acta Philosophica Fennica, vol. 16, pp. 83-94, 1963. 72 14. G. Kuper, “Logic Programming with Sets”, in 6th ACM Conference on Principles of Database Systems (PODS), San Diego, California, USA, March 23-25, pp. 11-20, ISBN 0-89791-223-3, ACM Press, 1987. 73 15. J.-J. C. Meyer, R. J. Wieringa (Eds.), Deontic Logic in Computer Science, 317 p., ISBN 0-471-93743-6, Jon Wiley & Sons, 1993. 71 16. B. A. Myers, R. G. McDaniel, R. C. Miller, A. S. Ferrency, A. Faulring, B. D. Kyle, A. Mickish, A. Klimovitski, P. Doane, “The Amulet Environment: New Models for Effective User Interface Software Development”, IEEE Transations on Software Engineering, vol. 23, no. 6, pp. 347-365, June, 1997. 74
A Flexible Method for Information System Security Policy Specification
85
17. R. Ortalo, Using Role-Based Abstractions for Security Policy Specification with Deontic Logic, 20 p., LAAS-CNRS, Report 97216, June, 1997. 76 18. R. Ortalo, Y. Deswarte, “Quantitative Evaluation of Information System Security”, in 14th IFIP International Information Security Conference (IFIP/SEC’98), August 31-September 4, Vienna-Budapest, Austria-Hungary, Chapman & Hall, 1998. (to appear) 78 19. R. S. Sandhu, E. J. Coyne, H. L. Feinstein, C. E. Youman, “Role-Based Access Control Models”, IEEE Computer , vol. 29, no. 2, pp. 38-47, February, 1996. 76
A Flexible Method for Information System Security Policy Specification Rodolphe Ortalo ortalo@laas, fr
LAAS-CNRS 7, avenue du Colonel Roche 31077 Toulouse cedex 4 France
A b s t r a c t . This paper presents a method for the specification of the security of information systems. The proposed approach provides a flexible and expressive specification method, corresponding to the specific needs of organizations. First, we outline the overall guidelines of the security policy definition process, and the different consistency issues associated to the description of the security requirements of an organization information system. The specification language used is based on a convenient extension of deontic logic. The formalism and its extensions are defined briefly. To illustrate the use of this formalism, the paper presents how the method applies to the description of the security requirements of a real organization : a medium-size bank agency. Keywords: security policy specification, information systems, deontic logic.
1
Introduction
This paper presents a practical framework for the specification of the security policy of an organization such as an industrial company or a public service. These organizations exhibit security needs, but they also have other requirements that induce several specificities with respect to security management. First, the information system may exist prior to the explicit definition of its security policy. Furthermore, it is important to provide an adaptable and structured methodology corresponding to the need for abstraction and progressive refinement in the security policy specification process. Finally, the information system may be imperfect, in the sense that the desired security properties may differ from the actual observed properties. From the security point of view, these contradictions appear intolerable, but they often result from a trade-off between the main requirements of the organization and the enforcement of security measures. In fact, the study of practical regulations often reveals discrepancies between the actual situation and the desired behavior, and the security policy would probably better cope with them rather t h a n ignore them. Consequently, in the context of an organization, most of the classical security models are often unusable. The problem is that they impose constraints on the design and the behavior of the system that may not be acceptable in a situation where security is not a primary requirement. For example, the mandatory rules
68
Rodolphe Ortalo
of a multi-level security policy [1] imply to design the information system accordingly, and assume permanent application of the rules. Moreover, in the case where the system already exists, the security policy could not be applied until it has been re-designed. To face such situations, the specification of a security policy must provide more flexibility and expressiveness. In this paper, we use an extended deontic logic language to specify security policies. Several authors already outlined the main features of deontic logic for specifying security properties [9, 12, 4], and this formalism seems to be more adequate for the specification of the security policy of an organization than usual security models. The specification method we propose is based on an original syntactical extension of the standard deontic logic language that allows a structured and convenient representation of the elements of the policy. Given the imperfections of real information system policies, several types of security policy inconsistencies may be encountered, corresponding to the elements of the security policy that conflict with each other. By detailing these cases, we identify some inconsistencies corresponding to a trade-off between functionality and security in the organization, that may be tolerated in the specification. Furthermore, we argue that the formalism also offers the opportunity to complement the security policy with a description of the vulnerabilities of the information system. However, it is highly desirable to completely describe the insecure states corresponding to inconsistencies in order to have a chance to trust the system. The structure of the paper is the following: Section 2 presents the various elements of an organization security policy and the potential conflicts that it may contain. Section 3 provides the definition of the specification language used in this paper. Section 4 details the application of the method to an information system. Section 5 presents a practical application example, addressing the security needs of a bank agency. Finally, we conclude in Section 6. 2
Presentation
2.1
of
the
Approach
S e c u r i t y Policy C o m p o n e n t s
The security policy of the system corresponds to the description of its security needs. According to [10, Section 2.9], the s e c u r i t y policy is "the set o/laws, ~ules and practices that regulate how sensitive in/ormation and other resources are managed, protected and distributed within a specific system". In this paper, we consider that a security policy defines : -
-
the s e c u r i t y objectives, i.e. the confidentiality, integrity and availability properties expected of the system ; and the s e c u r i t y rules which are imposed on the mechanisms which can modify the security state of the system, in order to guarantee the security properties.
The components of the security policy refer to specific entities of the system (e.g. specific subjects or objects, available operations, or an organization chart).
A Flexible Method for Information System Security Policy Specification
69
First, these description elements are added to the policy. In an organization for instance, the names of the various individuals are mentioned. Additional description rules may also be added to the specification in order to reflect the functional behavior of the system when this behavior may impose constraints on the security-related aspects of the system. In an organization, such functional rules represent the various information flows existing in the organization and the way they interact with each other. The description of these operational rules brings information that help the security administrator to adapt the security policy to the actual operation of the organization. The description of the system operation is limited to the basic elements needed to formulate the security mechanisms and objectives, and to the operational rules that describe the portions of the information system relevant to security. Therefore, this description should remain minimal, and additional elements or rules should be introduced only when needed. Second, the security policy contains the security rules to be enforced by the system. These rules reflect the way in which the security state of the system evolves. In an organization, such rules define, for example, who can assign a new position to an individual, or on which condition someone may delegate some of his privileges to another person. Finally, the security policy defines several security objectives that specify the desired security properties for this system. The set of all these properties defines the states of the system that are acceptable with respect to security. A security state of the system that satisfies all the security objectives of the system security policy is a secure state. An insecure state is a state where these properties are not satisfied. 2.2
Refinement
The first version of the security objectives introduced in the security policy will probably be rather generic. Therefore, it is very probable that these objectives will be too restrictive and easily invalidated by the operation of the organization. To resolve this problem, the introduction of new elements may be necessary to limit the scope of an objective. Similarly, it may be necessary to introduce new description rules, or accurately detail the various steps of a given task in order to focus on a desired security property. Therefore, the description of the organization will undergo several refinement steps, enabling to clarify the security objectives and to improve the whole policy. Furthermore, the verification of the policy can benefit from an incremental approach, as we will see in Sect. 4.2.
2.3
Security Policy Consistency
The security policy is c o n s i s t e n t if, starting from a secure state one cannot reach an insecure state without violating the security rules. Given the different security policy components, we can distinguish several types of potential inconsistency : - First, the description of the system may be inconsistent due to conflicting functional rules. However, this is not a security-related specification problem.
70
Rodolphe Ortalo
- Several security objectives may be contradictive. In this case, no secure state exists and it is impossible to enforce the policy, therefore the security objectives should be updated (e.g. by reducing their scope, or adding priorities). - Some of the security rules of the specification may contradict each other. For example, an individual may be able to reach a situation in which an obligation and an interdiction hold simultaneously with respect to the same action (e.g. due to conflicting roles). The modification of the security mechanisms may prevent such conflicts. However, it is also possible that the behavior of the system eliminates the situations in which these conflicts can occur. If so, description rules could be added to the system description to describe the functioning more accurately. The verification of each security objective, starting with the system security rules, may reveal an inconsistency. In this case, security rules fail to enforce the objectives. Such inconsistency means that either security objectives should be revised, or it is needed to introduce new security rules to enforce the expected properties. - Finally, it is possible that the functional rules conflict with the security objectives. This case identifies weaknesses in the organization operation showing that it is possible to bypass the security rules. To face this problem, two directions are possible: it is possible to modify the organization operation (and therefore decide to adapt the organization to the envisaged security mechanisms), or to consider new security mechanisms which are compatible with the actual operation (i.e. adapt the security policy to the information system). -
We can identify the mandatory consistency requirements of a security policy specification. First, it seems necessary that the consistency of the system description be obtained. If the description of the system functioning is incorrect, adding security requirements to the policy is a nonsense. Second, if several security objectives are contradictive, i.e. if the enforcement of one objective implies the failure of another, the information system is always in an insecure state. Therefore, consistency of the set of all security objectives is necessary: if two security objectives contradict, a choice must be made. Other inconsistency types reflect problems such as incomplete security mechanisms that fail to enforce the security objectives, over restrictive security rules that may lead to opposed permissions and interdictions in specific situations, or dangerous functioning of the system that may allow to bypass the security mechanisms. In practice, some of the security policies defined in organizations exhibit such inconsistencies [5]. Furthermore, a situation in which such problems occur may be acceptable if it corresponds to a legitimate trade-off in the organization. Exhaustive description of the insecure states is necessary to trust the system, but security issues may not need to be totally reconsidered. The purpose of the introduction of a description of the system behavior in our approach to security policy specification is precisely to allow such precise insecure states identification for some classes of inconsistent policies. Of course, improvements may also be proposed, but the corresponding mechanisms may not be possible
A Flexible Method for Information System Security Policy Specification
71
to be enforced in the organization if they perturb its normal operation, and we think that the security policy specification should take this fact into account and cope with some inconsistencies. This point of view can be extended. We can envisage to complement the system security policy by a description of the potential vulnerabilities of the system. Vulnerabilities may be due to intrinsic weaknesses of the used security mechanisms (such as cryptographic keys length), or to flaws identified after the system has started its operational life [10, Para. 3.25-28], [11, Sect. 6.C]. Such vulnerabilities compromise theoretically the security of the system, but may be very difficult or very long to exploit. The identification of the insecure states due to vulnerabilities allows to assess their impact on the security objectives. This assessment should help the information system security administrator to propose relevant changes given the known vulnerabilities of the system. 3
Specification
Language
In order to handle such cases, we need a security policy specification formalism flexible enough to separate the functional description of the system and the security needs description, and which furnishes methods for exploiting inconsistent specifications due to the integration of vulnerabilities in the description. Modal logic, or more precisely deontic logic, is a formal framework that seems to be expressive and adaptable enough to specify security policies of organizations [9, 12, 4]. Deontic logic is a branch of modal logic to reason about normative versus non-normative behavior by means of modal operators such as ought, permitted and forbidden [15, Preface]. Furthermore, by using these special operators, deontic logic provides a mean to specify that some behaviors of the system are non-normative (illegal) but nevertheless possible. We present briefly in this section the deontic logic language that we selected. A general presentation of modal logic can be found in [3].
3.1
Deontic Logic Language
Like any modal logic, deontic logic is an extension of usual propositional logic by one or several deontic operators. More precisely, if (I) is a set of atomic propositions a, b, c, ..., if --, V, A, ~ and r are the usual boolean operators, and if O, P and F are the three modal operators of deontic logic, the deontic language denoted Lo ((I,), or simply Lo when it raises no ambiguity, is the set of formulas (or sentences) built with the following rules : - i f p E (I), p is a formula; - if p and q are formulas, -,p, p V q, p A q, p :=~ q, and p r q are formulas ; - if p is a formula, Op, P p and Fp are formulas. A modal formula is a formula of L o which contains at least one operator O, P or F. A non-modal formula is a formula which contains none. In natural language, formulas Op, P p and Fp are read, respectively, "It is
72
Rodolphe Ortalo
obligatory that p", "It is permitted that p", and "It is forbidden that p". Therefore, operators O, Fp = O~p (1) P and F denote respectively the notions of obliP p = -,O-~p (2) gation, permission and interdiction. Conforming Op ~ Pp D to the definitions of necessity (operator O) and possibility (operator <~) in classical modal logic, O (p =~ q) =~ COp =~ Oq) K one can state relations between these various opP-PRN Op erators. First, F can be defined from O by (1). P is the operator dual of O. Therefore, one can also consider the relation (2) between operators O and P, similar to the relation between necessity and possibility in classical modal logic. Finally, standard deontic logic [3, Chap. 5], also contains axiom D which relates obligation and permission. A modal logic system is an extension of propositional logic, therefore it contains all the axioms and inference rules of propositional logic. Thus, Lo contains all tautologies and is closed under modus ponens. We consider in this work a normal modal logic system, i.e. a system that contains axiom K and the inference rule RN ("Rule of Necessitation"). In this paper, we want to use deontic logic for the practical representation of security properties. Even though it may have a direct impact on our work, studying deontic logic in itself, or as a formal language for reasoning about legal issues and normative systems (or security), is out of the scope of this presentation. Therefore, we use standard deontic logic, i.e. the KD system of classical modal logic. Especially we accept (2) as a suitable definition of permission. However, these simplifications are done in order to clarify the security policy specification method, and they do not prevent further extensions of the logical language used, such as suggested in [3, Chap. 10]. Finally, we recall the semantics associated to a normal modal logic language like Lo. It is a Kripke's semantics, or possible world semantics [13]. A Kripke model M for a modal logic system is defined by a triple (W, R, V) where W is set of possible worlds w, R is a binary relation over W called the accessibility relation, and V : W x ~ --+ {true, false} is a function furnishing in each world w E W the truth value V (w,p) of the atomic proposition p. The fact that proposition p is true in a world w of model M is noted ~M p. This truth value is defined in the following way 1, which extends usual propositional calculus: _ _ _
if p E @, ~M p if and only if V (w, p) -- true ~M _,p if and only if we do not have ~M p ~ M ( p A q ) if and only if ~M p or ~M q ~M Op if and only if Vw' E M / w R w ' , ~wM p
The first three statements conform to the classical truth value definition of a formula in propositional logic. From the last definition, we see that in the Kripke's semantics the formula "It is obligatory that p" is true in a world w if and only if p is true in every world w ~ which w is in relation with. When w is 1Using -, and V as the fundamental boolean operators.
A Flexible Method for Information System Security Policy Specification
73
in relation with w ~, we say that w ~ is directly accessible from w, or equivalently that w ~is a possible world for w . The definition of the truth value of Pp is easily deduced from the one of Op using (2) : _ ~M p p if and only if 3w' E W / w R w ' , ~ wM p
3.2
Language Extensions
The language Lo, or Lo (~), is based on a set of atomic propositions (b. In order to ease the specification task, it is desirable to introduce constructs allowing a structured and hierarchical description of the various formulas of Lo. Therefore, we propose to use a syntactical extension of this language, denoted ~oLet 11 be a set of sets A, B, C , . . . , ordered by the partial order relation of inclusion _. The language 1:o (II), or simply s when it raises no ambiguity, is syntactically identical to the language Lo defined in Sect. 3.1. This extension is purely syntactical. Its interest resides in the possibility of structuring the atomic propositions of the language through a hierarchical description of a set by its subsets. In order to ease the construction of the various sets E elements of II, we allow the use of the operator x (set product) to define the elements of II, with the natural extension of the relation of inclusion.2 The deontic language Lo (~II) associated to the extended language ~ o (II) is built considering the set ~n defined as ~n = {E E I I / (rE ~ E H, E' g: E)}. Therefore, ~l~ is the set of all the terminal sets of H, i.e. the sets that do not contain any other sets and form the basis of the hierarchy defined by relation C_. A sentence f of ~ o (H) is associated to a set Zf of formulas of Lo (r defined recursively by (3), ~ f = U ~fl~_~, (3) where f I*~-v is the formula built by substituting E'CE for all the occurrences of symbol x the symbol y in formula.f. Therefore, a formula f of s (H) is a short notation for several formulas of Lo (~n). These formulas are those obtained by replacing, in f, every occurrence of a non-terminal set of II by its content until we obtain formulas mentioning only elements of ~n. U s i n g Set C o n s t r u c t o r s . Similar notations allowing the direct use of sets within formulas have already been applied to logical languages developed for database systems [14]. These extensions aim at facilitating the specification task. Sets allow for a progressive and hierarchical description of the basic elements of the security policy, and these sets can be used directly in the formulas of the extended language. To illustrate the use of this notation, we consider now several formulas written in s (l-I) and the equivalent set of formulas in Lo (~ii). 3 A simple equation of the extended language L:o, e.g. P (A V B), should be represented by a whole set of formulas in Lo, here: {Vp E A, Vq E B, P (p V q)}. 2E x E' = {(e,e') /e E E,e' E E'}, and E x E' C F x F' r E C_F A E' C_ F'. 3In these examples, sets A, B, 'Administrators', 'Software types' and 'Departments' refer to sets containing atomic propositions only. 'Install' is itself an atomic proposition, i.e. an empty set.
74
Rodolphe Ortalo
The set product operator • of/~o (H) allows the definition of structured sets as elements of the language. This eases the description of various items starting with some of their typical features. Hence, formula (4) states directly a set of permissions associated to software installation tasks. These tasks are described by the action symbol 'Install', the various people allowed to perform the installation gathered in the set of the system administrators, and the various target software. Pieces of software are themselves described through two characteristics: their type (word processor, spreadsheet, etc.), and the organization department that owns them. The description of all these elements in the original language Lo would necessitate the definition of many elements, sharing common typical characteristics. Formula (5) shows such a set. As can be seen, in a conventional notation, set product corresponds to several indices.
P (Install • Administrators
• (Software types • Departments))
{P (Installa,software,.d) }aEAdministrators,tESoftware types,dEDepartments
(4) (5)
G r a p h i c a l R e p r e s e n t a t i o n . These extensions also make the specification language suitable for a graphical presentation that can be manipulated with classical user interaction techniques (drag and drop, etc.). This graphical representation represents the sets hierarchy leading to the definition of the atoms of the language using hierarchical lists. The operators of the language are also represented using graphical artifacts called slot-boxes. The purpose of this representation is to provide a simple and convenient method to define and manipulate the security policy specification elements. Figure 1 presents an example of this representation for defining the content of the sets mentioned in (4). Departments[ Management[ Production Sales
Software types Word processors I$TEx, ... Compilers Spreadsheets
[Administrators [ A1 [A2 A3
Fig. 1. Example of sets graphical representation This graphical approach has been implemented within a tool enabling to define and modify easily a security policy. This editor is based on the Amulet graphical library [16] which was very convenient for this realization. In the remaining of this paper, we will adopt this graphical representation for sets, but for space reasons, we will use a conventional linear notation for formulas involving operators. 4
Application
to Information
Systems
Security needs justifying the elaboration of a security policy appear in many organizations. For example, we can mention banks (transactions integrity), telecommunication companies (system availability), or medical and public-health services (legal confidentiality obligations). However, all these organizations also have other priorities distinct from security. In this section, we present how the
A Flexible Method for Information System Security Policy Specification
75
deontic logic language presented previously can be applied to the specification of the security policies of such organizations, and the various possible situations associated to the specification verification. 4.1
Guidelines
In the context of an organization, a security administrator would be in charge of the security policy definition. While this administrator would probably have a good knowledge of the target organization, it is probable that he would not be familiar with a modal logic language. Therefore, we detail several steps of this formalization process. R e u s e of available i n f o r m a t i o n . Most of the description elements of the specification appear in documents describing the organization and its operation. These elements are related to physical entities, individuals, or a functional decomposition of the organization. They refer also to specific attributes (such as confidentiality levels). Many of these items appear in description documents already available in the organization, such as an organization chart, some tasks definition documentation, handbooks, norms if applicable, etc. With respect to security issues, other documents help the system administrator. For instance, organization charts also mention the individuals situation in the hierarchy and their privileges. The policy can also be based on existing regulations, documents supporting the evaluation of the organization according to a set of security criteria [10], a previous risk analysis, laws if applicable to the organization, etc. When the security policy specification target is a system to be designed (and not a system in operation), the security designer should look for equivalent information existing in the design documents. S y s t e m d e s c r i p t i o n . In the deontic logic language presented previously, the description of the organization is performed through the introduction of atomic propositions representing the basic elements, and non-modal formulas (built with the operators of usual propositional logic) representing the aspects of the functioning that are relevant for security. For example, consider the process of internal purchase in an organization: an employee formulates a purchasing demand, which must probably be validated by a manager before going to a specialized department that performs the operation. In order to describe these different steps, first one needs to introduce several atoms such as 'demand', 'manager authorization', 'order' and 'delivery'. Then, one can state the causal dependencies between these steps and the condition for an order to be actually sent by the purchase department. This is represented by logical formulas like: demand A manager authorization ~ order and order ~ delivery. S e c u r i t y rules. The security mechanisms existing in the system are added to the description of its operation. A security mechanism describes the link between the permissions (or interdictions) and the state of the system (or, more precisely, only a subset of the whole state of the system: its security state, made of security attributes). Therefore, it may be represented by a modal formula stating a permission conditioned by some non-modal formula, such as: directory writable =~ P (rename the file).
76
Rodolphe Ortalo
Integration of roles. The main asset of role-based policies resides in the opportunity that they offer to specify constraints on abstract elements (the roles) instead of enumerating several analogous constraints for all the concerned subjects [19]. Formula (4) presented previously shows that the possibility to use sets directly in a formula i n / : o allows to define and use easily user groups. To support roles, we enumerate not only the various roles, users and permissions, but also the desired pairs (role, user), and use modified authorization rules that constrain users permissions according to user roles. For example, we may modify (4) to: P(Install x Agent • Software) =~ Administrator x System administrator. In this approach, roles appear as intermediate abstract entities between the permissions in the system and the actual users. This extra level improves the flexibility of the specification, as roles are defined independently of the elements they relate. This flexibility is achieved at the cost of an extra specification work to associate users to roles. As shown in [17], several variants of this method can be used to introduce roles in a deontic logic specification. S e c u r i t y objectives. Finally, we use the basic elements defined previously to describe the security objectives of the information system. If a regulation exists in the organization, it will be transposed in the security policy specification. The deontic logic language allows an easy definition of the security objectives, through the use of the obligation, permission and interdiction operators that allows a natural wording of the desired security properties. Therefore, a security objective is usually represented by one modal formula, such as Op or F (p A -~q).
4.2
Exploiting the Specification
An asset of a formal language resides of course in the availability of formal calculus methods, useful to reason about the security policy. Several directions may be followed to address this issue. See [8, 6] for a general presentation of modal logic proof theory, and [4] for an application to the verification of security properties. Provided that this calculus exists, several verifications can be performed on the specification corresponding to the various inconsistency types identified in Sect. 2.3. With respect to validation problems, the incremental process presented in Sect. 2.2 exhibits new advantages. Non-modal formulas, such as p, pVq, pAq :*z r, corresponds to the description of the system components and functioning. Such formulas must form a consistent basis for the security policy. Therefore, validation of all the non-modal formulas should be done separately, prior to further verification of the security-related formulas. As these formulas only form a partial description of the system and are propositional logic formulas, their number is limited and we do not expect their validation to be prohibitive. When inconsistency comes from the combination of two security objectives (this can be checked directly by verifying the conjunction of the two corresponding modal formulas in the chosen modal system), a choice must be made. This situation may be difficult to manage if it is attempted to verify the whole security policy directly in one step. However, if the specification process follows the
A Flexible Method for Information System Security Policy Specification
77
incremental method suggested, the verification of the security objectives compatibility should be done separately 4. We can also check that the security policy specification exhibit some properties, such as the fact that there are no conflicting obligation and interdiction. This is represented by -- (Op A Fp), which must be true in the specification. Inconsistency types potentially related to an organization trade-off appears mainly when considering the Kripke's semantics of the deontic logic security policy specification. An inconsistency appearing between formulas describing security rules, such as p A q =~ F r or p =~ Pq, means that the semantic model M of the specification contains a world w (corresponding to a system state) in which several permissions or obligations conflict (e.g. both ~M p p and ~M F p hold for some p and w). Similarly, an inconsistency appearing after the addition of a security objective to the specification shows that there exists worlds in the model where the modal property corresponding to the objective is not true. In each case, a model M invalidating the specification identifies the various intermediary states leading to an insecure state as well as the possible transitions between them, as it provides the t r u t h values V (w, p) of the atomic propositions in each world, as well as the relation R between the worlds. The verification process may exhibit a counter-model M invalidating the specification. In this case, the counter-model may be used to identify the various rules (either functional rules or security rules) involved, as well as the conditions on the state of the system that allow this failure. With this information, modifications may be proposed. If the functioning of the system never allows such situations (e.g. one person simultaneously associated to all the roles in the system), additional formulas may be incorporated to the security policy to rule out such states. If a succession of applications of security rules allows to defeat the proposed objective, either the rules may be updated or the objective revised. Finally, if the behavior of the system allows to bypass several security rules and defeat the security objective, modifications of the operation of the system may be proposed in order to improve its security. In each case, the trade off between security issues and operational issues may be difficult to manage, but the information extracted from the counter-model M helps the system administrator to determine the appropriate solution. The interest of the information that can be extracted from such a counter-model may favor the use of a semantics-based deduction m e t h o d for the verification of a deontic logic security policy specification, such as those presented in [7, 2]. We see t h a t the specification, even when inconsistent, can be exploited usefully. In fact, we argue that the ability to analyze precisely and exhaustively the various possible evolutions of the state of the system that contradict a security 4It should be noted that, with the language presented in Sect. 3, it is also possible that global inconsistencies, similar to those corresponding to conflicting objectives, result from a combination of propositional formulas (describing the functioning) and formulas describing security rules. This specific case corresponds to the fact that in a specific system state some security rules lead to a contradiction, and, simultaneously, the functioning of the system always leads to this state. This case should be treated like conflicting objectives and be eliminated.
78
Rodolphe Ortalo
objective is very important in the context of an organization information system. In this context, the verification of the whole specification is very likely to fail due to contradictory objectives, or incomplete or inadequate security rules. Furthermore, it may be acceptable to tolerate inconsistencies, if all the evolutions of the information system that may lead to an insecure state are very improbable or very difficult to exploit. This assessment can rely, for example, on an evaluation method [18]. However, such situations cannot be understood if a precise description of the security needs does not provide the information needed to qualify the insecure states. 4.3
Description of Vulnerabilities
The approach finally offers the opportunity to include in the security specification additional components podp = Pp (6) tentially leading to inconsistencies, representing the vulnerabilities of the information system. In (6), we dep A dq ::~ Odr (7) fine a right dp with respect to a proposition p as the p A Pq ~ O P r (8) permission of p. We propose to define a vulnerability as the fact that, given a right and a specific state of the system, it is possible to obtain a new right (possibly not legitimate). We describe this as the property that "if a non-modal (propositional) property p and a right dq are true in a world w, then there exist another world w ~ in relation with w such that another right dr is true in wl. '' Therefore, we represent a vulnerability by a rule like (7). Given the definition of a right, a vulnerability is of the form of (8). This definition allows the description of general vulnerabilities and, on the contrary of [18], makes a clear distinction between the normative aspects of the specification (captured by the deontic operator P) and the opportunities offered to a potential attacker (captured by the ontic operator (>).
5
Example
To illustrate the security policy specification method, we present an example of its application. The target organization is a bank agency, counting 35 employees, and located in a rural area. The security policy presented in this section was built on the basis of several internal documents describing the organization. The analysis of these documents has been completed by a study in the field which lasted several days. The bank help manual identifies more than a hundred different operations potentially performed in the organization, from foreign currency deposit to account freezing following a legal injunction. Among all these operations, only a limited number are integrated in the following specification. We chose to consider operations involving loan agreement, and bearer bonds. These tasks are interesting as the first relies on a delegation mechanism, and the other is considered security-critical due to anonymity.
A Flexible Method for Information System Security Policy Specification
5.1
79
Formalization of the Organization Description Documents
The initial elements of the specification are presented in Fig. 2. We note the various individuals mentioned in the policy, several actions, and also a set of roles. The set 'Individuals' is further split into two subsets: 'Customers' is left unspecified and designates any potential customer of the bank, 'Agents' enumerates all the employees of the organization (they are identified by numbers from 1 to 35 in this paper). The roles used in this specification are related to the functions existing in the organization. All the official functions mentioned in the organigram are gathered in the set 'Employment' (defined later) which is therefore a subset of all roles. However, our practical study allowed us to identify a separate unofficial role, 'Cashier', necessary to formulate the security rules of the organization. Astonishingly, it is not explicitly associated to a function in the organigram. Finally, the set 'Actions' contains the various tasks included in the specification. Only three general types of action are considered in this example : common operation performance, loan agreement, and physical access. Actions Do • Operations Grant a loan • Loans Access x Physical elements
A m o u n t Miscellaneous I Balance I Physical elements Movements I IF~ Movement types [Account Complaint [ Roles mapping I
Individuals[
Roles
Customers Agents
Employment Cashier
Agents mapping A16 • Cashier
Fig. 2. Security policy specification root The various organization description elements are given in Fig. 3. The set 'Employment' describes the employee functions (corresponding to roles). It corresponds to a position description document available in the bank. This document identifies several abstract positions that gather different positions actually held by the employees (e.g. 'Leader' groups positions such as agency leader, office manager, etc.). The roles introduced in Fig. 2 allow to define generic description and security rules independently of the actual agents of the organization. To obtain the actual description we need to specify also a mapping between individuals and roles. The mapping of agents to roles, 'Agents mapping', obtained using an organigram of the organization, is defined in Fig. 3. We note in this figure that one agent may be associated to several roles, e.g. A7 is a manager as well as a service agent. A16, the agent playing the role of the cashier is identified directly in Fig. 2. The various operations performed in the organization, presented in the set 'Operations', are also organized in several subsets. The description is limited to the higher levels and the detailed list of all operations has not been included. In this figure, we also introduce several secondary elements. Finally, we include in these description elements a simple representation of the data associated to a bank account. In order to describe the functioning of the organization, we also need to include description rules. As an example, we show in Fig. 3 how accounts and money movements can be represented. These rules state for example that an usual operation necessitates physical access to one of the bank terminals, and
80
Rodolphe Ortalo
t h a t such an operation results either in a debit or credit m o n e y movement on an account. Of course, this is a simplification of the real functioning. A specific description rule represents the fact t h a t a debit operation, when performed on a negative balance account, follows an exceptional path. The proposition 'Freezing' is a label identifying the exception. Here, this label does not mean t h a t the operation cannot be performed. 5 Employment Agency chief executives Agency manager Agency manager assistant Leader Market leader Position leader Office m a n a g e r Agency leader Position manager Service agent P r i v a t e cust. service agent F a r m e r service a g e n t Professional service a g e n t Collection assistant H i g h l y skilled c l e r k All m a r k e t c o m m . a s s i s t a n t Clientele adviser Customer clerk Skilled c l e r k Secretary Position ] Positive balance Negative balance [Accounts C Customers x Position t
A1 x A g e n c y m a n a g e r A2 x A g e n c y m a n a g e r a s s i s t a n t A3 x S e c r e t a r y A4 x S e c r e t a r y A5 x A g e n c y l e a d e r A5 x P r i v a t e cust. service agent A6 x A g e n c y l e a d e r A6 x Professional service agent A6 x F a r m e r service a g e n t A7 x Position manager A 7 x Professional service a g e n t A 8 x All m a r k e t s comm. assistant A 9 x Professional service a g e n t A 1 0 x Professional service agent
All A12 A13 A14 A15 A16 A17 A18 A19 A20 A21 A22 A23 A24
Operations Usual operations Loan operations Stocks and shares Bearer bonds Non-banking operations Insurance Flows management Main cash desk ATM Foreign currencies Internal operations Forcing control Litigations Customer incidents Cash desk incidents Agency management Staff management Movement types] To C r e d i t To D e b i t
Folders Loans folders P r i v a t e c u s t . loans Consumer loans Professional loans Farmer loans Agency manager delegation a u t h . for A 5 a u t h . for A 7 Amounts < $250,000 < $20,000 < $8,000 Physical elements Main safe Terminal ATM
M o v e m e n t s C_ M o v e m e n t t y p e s x A c c o u n t x A m o u n t
I • x x x x x x x x x x x x x
Agents mapping Professional service agent Farmer service agent Farmer service agent Farmer service agent Skilled c l e r k Skilled c l e r k Skilled c l e r k Skilled c l e r k P r i v a t e cust. service agent P r i v a t e cust. service agent Clientele adviser Skilled c l e r k Clientele adviser Clientele adviser Description rules
A25 A26 A27 A28 A29 A29 A30 A31 A32 A33 A34 A35
x • x x • x x x x x x x
Skilled c l e r k P r i v a t e cust. service P r i v a t e cust. service P r i v a t e cust. service P r i v a t e cust. service Position manager P r i v a t e cust. service P r i v a t e cust. service P r i v a t e cust. service P r i v a t e cust. service P r i v a t e cust. service Clientele adviser
agent agent agent agent agent agent agent agent agent
A g e n t s x A c t i o n s ::~ A c t i o n s A g e n t s x (Do x O p e r a t i o n s ) ~= A g e n t s x ( A c c e s s x T e r m i n a l ) Do • L o a n o p e r a t i o n s =~ L o a n f o l d e r s Do • U s u a l o p e r a t i o n s =~ To D e b i t x A c c o u n t x A m o u n t V To C r e d i t x A c c o u n t x A m o u n t C u s t o m e r s x N e g a t i v e b a l a n c e =~ F r e e z i n g x (To D e b i t x A c c o u n t x A m o u n t ) G r a n t a l o a n • L o a n s :=~ To C r e d i t x A c c o u n t x A m o u n t
F i g . 3. Security p o l i c y description e l e m e n t s
~Debit operations on a negative balance account can be eliminated by a formula such as: Customers x Negative balance ~ -~ (To Debit x Account x Amount). We do not include such a rule in our specification because it does not correspond to the actual functioning of the bank. Agents treat such money movements with specific care, but they can perform them.
A Flexible Method for Information System Security Policy Specification 5.2
81
D e s c r i p t i o n of the Security N e e d s Security rules [ P ( A g e n t s x (Do x Usual operations)) =~ (Agents • Employment) P ( A g e n t s • (Do • Loan operations)) ==~ (Agents • Service agent) P ( A g e n t s x (Access x Main safe)) =:~ (Agents x Cashier) V (Agents x A g e n c y manager) Agents • Actions A Freezing • Actions =*- O(Forcing x Agents x Actions) P ( A g e n c y manager delegation) Delegation rule Agency
Delegation rule I manager delegation A (Agents • E m p l o y m e n t ) A Loan authorizations I
=*- P( P(hgents x (Grant a loan x Loan)) ) Loan authorizations
[
Professional market Service agent • (Professional l o a n s • <~ $70,000) Leader x (Professional l o a n s x < $90, 000) A g e n c y chief executives x (Professional loans• <2 $110,000) Farmer market Service agent • (Farmer loans• <: $70,000) Leader x (Farmer l o a n s x < $90,000) A g e n c y chief executives • (Farmer loans• < $110,000) Private cust. market Service agent x (Private cust. l o a n s • < $40,000) Leader x (Private cust. l o a n s x < $90,000) A g e n c y chief executives • (Private cust. loans• < $140,000) Consumer projects Service agent x (Consumer l o a n s x < $8,000) Leader • (Consumer loans• < $18,000) A g e n c y chief executives x (Consumer l o a n s • <~ $28,000) Company market Leader • (Consumer loans)< < $120,000) A g e n c y chief executives x (Consumer loans• < $240,000) objectives • Employment F(Customers x (Do Security • Usual operations)) F ( A g e n t x Grant a loan x Loans A Agents "( < $100,000)) A~Loan authorizations A Loans x F(Customers x Complaint)
Fig. 4. Security requirements description The rules describing the security needs of the organization are shown in Fig. 4. Among these rules, we focus on a specific aspect involving delegation of privileges: loan agreement delegation. Chief executives are allowed, in this organization, to delegate some of their privileges to other employees, in the limit fixed by several conditions. The rule itself is shown in the table entitled 'Delegation rule', and the second table 'Loan authorizations' enumerates the loans categories and maximal amounts that may restrict the delegation rights of the agency manager. Note that the abstract positions identified formerly in Fig. 3 (e.g. 'Leader') are used to define the various authorizations, illustrating the interest to describe hierarchically the set 'Employment'. The mechanism of loan agreement delegation that exists in this bank is a typical example of a situation in which a deontic logic specification language may be most useful. The general bank rules state that an agency manager can delegate some of his privileges (with respect to loan decisions) to other employees. These rules define several limits that the agency manager must respect in his delegation decisions, but nothing more. Therefore, the manager defines the actual permissions of the agents. We represent this functioning in the specification using two nested P operators meaning that permission is granted (to the agency manager) to grant permission to one of his agents to accept a loan. However, even if it is authorized, the manager may not
82
Rodolphe Ortalo
delegate full permissions to an agent, e.g. if the latter does not need them as he works on a specific market. Finally, Fig. 4 presents three simple security objectives. The first one is related to customers, but the other two apply to the agents of the organization. The second one aims at enforcing the delegation authorizations with respect to loan agreement, and the last one at protecting customers from abuses perpetrated by employees.
5.3
Integration o f Vulnerabilities
As an example, we consider now two vulnerabilities of the bank agency. These vulnerabilities are presented in Fig. 5. The first one is related to trust relationships between the various agents of the organization. We also consider that a customer may trust the agent in charge of his business. Such trust may allow a malicious agent of the organization to misappropriate funds of this customer. However, in our case, we think that this vulnerability arise only for specific operations, more precisely anonymous stocks and shares operations. Vulnerabilities I Agents x Trusts x Other agent A P (Agents x Actions) ::~ O1~ (Other agent x Actions) Customers x T r u s t s x Agents A (Agents x Bearer bonds) ::~ O (9 (Customers x Complaint))
Fig. 5. Vulnerabilities The first vulnerability shown in Fig. 5 conflicts with the second security objective shown in Fig. 4. A study in the field allowed us to check in the real organization the various conditions under which a given vulnerability may appear (i.e. to obtain all the true propositions of the form Agents x Trusts x Other agent). Given this information, we identified all the possible scenarios allowing an agent of the organization to defeat the second or third security objective. We observed that trust relationships were numerous in this organization between the employees (174 trust relationships are very strong), and several agents indeed could defeat the loan agreement authorization limits. As it is surely impossible (and probably ill-fated) to regulate the everyday life and the trust relationships existing among the agents, these results do not allow one to influence directly the operation of the organization. However, comparison of these results with the situation of each agent (with respect to his seniority, position or skills) could reveal anomalies in privileges distribution in the organization. In our case, no abnormal tendency arose from the results analysis. In the specification considered in this example, the second vulnerability conflicts directly with the third security objective. We studied an alternate functioning of the target organization involving validation of all bearer bonds operations by one specific employee before completion. In this case, only a malicious agent who abuses one of his customer's trust and the agent in charge of the validation is able to infringe the objective. This means that, given the revised functioning, both vulnerabilities shown in Fig. 5 may conflict with the third security objective of the organization. However, detailed analysis of the possible insecure states shows that they are much less numerous given the revised functioning than with the original one. Therefore, such functioning appears acceptable.
A Flexible Method for Information System Security Policy Specification
6
83
Conclusion
The information systems addressed in our study are commonly found in organizations such as banks, industrial companies, etc. Our approach focuses on organizations where security is not the only requirement even though security issues are important. For these organizations, the definition of a security policy necessitates a pragmatic approach, taking into account the functioning of the target information system. Most of the classical security policies define security properties expected of the system independently of a description of the system itself. But such policies also impose strong constraints on the operation of the target system or organization, which may not be acceptable in the context of a conventional information system. In our case, on the contrary, the security policy definition integrates a partial description of the information system. This allows to reuse available information, and to adapt the definition of the security objectives and rules to the target organization structure and behavior. In practice, security rules and objectives may be more detailed and fit better the actual operation of the organization. Based on a formal language, deontic logic, the method offers the opportunity to perform the verification of the policy. But we identified several types of inconsistency, and some of them correspond to admissible trade-off between security and other requirements of the organization, such as flexibility or efficiency. In these cases, the policy fails to be consistent. However, the verification of the security policy should provide a mean to identify exhaustively all the potential insecure states of the information system and could be a valuable help to the security administrator who manages such trade-off. Furthermore, a suitable description of the information system vulnerabilities can be proposed using the proposed specification language. This description fruitfully complements the security policy as the formalism offers the opportunity to identify precisely the impact of the vulnerabilities considered on the security of the organization, using verification mechanisms similar to those associated to consistency checking. This information will facilitate the task of the administrator to evaluate the gravity of the organization vulnerabilities, and to propose modifications of the functioning or of security rules in order to improve security.
Acknowledgments The author is grateful to the Credit Agricole, and more especially to the CRCAM Quercy-Rouergue for their collaboration, as well as to all of the staff of the agency of Villefranche de Rouergue for their pleasant welcome. This work has been partially supported by UAP Assurances, and European ESPRIT Project 20072 "Design for Validation" (DeVa). Finally, I would like to thank Claudia Almeida, Marie Borrel, Frederic Cuppens, Yves Deswarte and the anonymous referees for their help on this work.
84
Rodolphe Ortalo
References 1. D.E. Bell, L. J. LaPadula, Secure Computer Systems: Unified Exposition and Multics Interpretation, The MITRE Corporation, Report ESD-TR-73-306, 1975. 2. L. Catach, "TABLEAUX: A General Theorem Prover for Modal Logics", Journal of Automated Reasoning, vol. 7, pp. 489-510, 1991. 3. B.F. Chellas, Modal Logic: An Introduction, 295p., ISBN 0-521-29515-7, Cambridge University Press, 1980. 4. L. Cholvy, F. Cuppens, "Analyzing Consistency of Security Policies", in IEEE Symposium on Security and Privacy, Oakland, California, May 4-7, pp. 103-112, ISBN 0-8186-7828-3, IEEE Computer Society Press, 1997. 5. F. Cuppens, C. Sanrel, "Specifying a Security Policy: A Case Study", in 9th IEEE Computer Security Foundations Workshop, Kenmare, Ireland, June 10-12, pp. 123134, ISBN 0-8186-7522-5, IEEE Computer Society Press, 1996. 6. L. Farifias del Cerro, A. Herzig, "Modal Deduction with Applications in Epistemic and Temporal Logic", in Handbook of Logic in Artificial Intelligence and Logic Programming, Epistemic and Temporal Reasoning (D. M. Gabbay, C.J. Hogger, J.A. Robinson, Eds.), vol. 4/5, pp. 499-594, ISBN 0-19-853791-3, Oxford Science Publications, 1995. 7. M. Fitting, "First-Order Modal Tableaux", Journal of Automated Reasoning, vol. 4, no. 2, pp. 191-213, 1988. 8. M. Fitting, "Basic Modal Logic", in Handbook of Logic in Artificial Intelligence and Logic Programming, Logical Foundations (D. M. Gabbay, C.J. Hogger, J.A. Robinson, Eds.), vol. 1/5, pp. 365-448, ISBN 0-19-853745-X, Oxford Science Publications, 1993. 9. J. Glasgow, G. McEwen, P. Panangaden, "A Logic for Reasoning About Security", in Computer Security Foundations Workshop, Franconia, pp. 2-13, IEEE Computer Society Press, 1990. 10. ITSEC, Information Technology Security Evaluation Criteria, vl.2, 163p., ISBN 92-826-3004-8, Office for Official Publications of the European Communities, Luxembourg, 1991. 11. ITSEM, Information Technology Security Evaluation Manual, vl.0, 262p., ISBN 92-826-7087-2, Office for Official Publications of the European Communities, Luxembourg, 1993. 12. A.J.I. Jones, M. Sergot, "Formal Specification of Security Requirements using the Theory of Normative Positions", in Second European Symposium On Research In Computer Security (ESORICS 92), (Y. Deswarte, G. Eizenberg, J.-J. Quisquater, Eds.), Toulouse, France, November 23-25, LNCS, 648, pp. 103-121, ISBN 3-540-56246-X & 0-387-56246-X, Springer-Verlag, 1992. 13. S.A. Kripke, "Semantical Considerations in Modal Logic", Acta Philosophica Fennica, vol. 16, pp. 83-94, 1963. 14. G. Kuper, "Logic Programming with Sets", in 6th ACM Conference on Principles of Database Systems (PODS), San Diego, California, USA, March 23-25, pp. 11-20, ISBN 0-89791-223-3, ACM Press, 1987. 15. J.-J. C. Meyer, R.J. Wieringa (Eds.), Deontic Logic in Computer Science, 317p., ISBN 0-471-93743-6, Jon Wiley & Sons, 1993. 16. B.A. Myers, R. G. McDaniel, R. C. Miller, A. S. Ferrency, A. Faulring, B. D. Kyle, A. Mickish, A. Klimovitski, P. Doane, "The Amulet Environment: New Models for Effective User Interface Software Development", IEEE Transations on Software Engineering, vol. 23, no. 6, pp. 347-365, June, 1997. 17. R. Ortalo, Using Role-Based Abstractions for Security Policy Specification with Deontic Logic, 20p., LAAS-CNRS, Report 97216, June, 1997. 18. R. Ortalo, Y. Deswarte, "Quantitative Evaluation of Information System Security", in 14th IFIP International Information Security Conference (IFIP/SEC'98), August 31-September 4, Vienna-Budapest, Austria-Hungary, Chapman&Hall, 1998. (to appear) 19. R.S. Sandhu, E. J. Coyne, H. L. Feinstein, C. E. Youman, "Role-Based Access Control Models", IEEE Computer, vol. 29, no. 2, pp. 38-47, February, 1996.
On the Security of Some Variants of the RSA Signature Scheme Markus Michels 1, Markus Stadler 1, and Hung-Min Sun 2 1 Ubilab, UBS Bahnhofstr. 45 8021 Zurich, Switzerland {Markus. Michels, Markus. Stadler}@ubs. c o m 2 Department of Information Management ChaoYang University of Technology Wufeng, Taichung County Taiwan 413 hmsun@dscs, csie. nctu. edu. tw
Abstract. We describe adaptive attacks on several variants of the RSA signature scheme by de Jonge and Chaum. Moreover, we show how to break Boyd's scheme with an adaptive, a directed and a known signature attack. The feasibility of the adaptive attack on Boyd's scheme is illustrated by a concrete example. Keywords: cryptanalysis, digital signature schemes, RSA variants.
1
Introduction
Since the invention of the RSA signature scheme [20] in 1978, many variants have been proposed in order to improve the security and the efficiency of the scheme. However, these attempts have not always been successful. For instance, Rabin [19] and Williams [22] suggested schemes whose security can be proved equivalent to factoring the modulus as long as the attacker is assumed to be passive, but which are vulnerable to so-called adaptive attacks (see [11] for a formal description of attacker models on signature schemes)