Mandatory Access Control in Linux



Similar documents
CSE543 - Introduction to Computer and Network Security. Module: Access Control

How To Model Access Control Models In Cse543

Advanced Systems Security: Retrofitting Commercial Systems

CSE543 - Introduction to Computer and Network Security. Module: Operating System Security

Security Enhanced Linux and the Path Forward

Access Control Fundamentals

Mandatory Access Control

Access Control. ITS335: IT Security. Sirindhorn International Institute of Technology Thammasat University ITS335. Access Control.

Common Criteria Evaluation Challenges for SELinux. Doc Shankar IBM Linux Technology Center

NSA Security-Enhanced Linux (SELinux)

Virtual Machine Security

CSE543 - Introduction to Computer and Network Security. Module: Reference Monitor

Linux OS-Level Security Nikitas Angelinas MSST 2015

Secure computing: SELinux

WHITEPAPER INTRODUCTION TO CONTAINER SECURITY. Introduction to Container Security

Using Likewise Enterprise to Boost Compliance with Sarbanes-Oxley

The Case for SE Android. Stephen Smalley Trust Mechanisms (R2X) National Security Agency

Database Security Part 7

Security Management Practices. Keith A. Watson, CISSP CERIAS

Confining the Apache Web Server with Security-Enhanced Linux

Protecting the Cloud from Inside

Access Control Intro, DAC and MAC. System Security

Safety measures in Linux

Operating System Security

Host Hardening. OS Vulnerability test. CERT Report on systems vulnerabilities. (March 21, 2011)

Design Principles for Protection Mechanisms. Security Principles. Economy of Mechanism. Least Privilege. Complete Mediation. Economy of Mechanism (2)

Establishing and Sustaining System Integrity via Root of Trust Installation

CS 356 Lecture 25 and 26 Operating System Security. Spring 2013

Secure to the Core: The Next Generation Secure Operating System from CyberGuard

A Firewall Model of File System Security

Securing Data in a RHEL SELinux Multi-Level Secure Environment

A Survey of Access Control Policies

How To Achieve Pca Compliance With Redhat Enterprise Linux

Securing Your System: Security Hardening Techniques for SUSE Linux Enterprise Server 12

Threat Modeling. Frank Piessens ) KATHOLIEKE UNIVERSITEIT LEUVEN

8 Steps For Network Security Protection

Host Hardening. Presented by. Douglas Couch & Nathan Heck Security Analysts for ITaP 1

Secure Virtual Machine Systems

Bypassing Firewalls: Tools and Techniques

Analysis of the Linux Audit System 1

Operating System Security Hardening for SAP HANA

Penetration Testing LAB Setup Guide

Server Security. Contents. Is Rumpus Secure? 2. Use Care When Creating User Accounts 2. Managing Passwords 3. Watch Out For Aliases 4

Hardened Hosting. Quintin Russ. OWASP New Zealand Chapter th December 2011

Thanks for choosing sentora-paranoid for your sentora hosting environment security solution

Hardening the Soft Middle: Securing your IT Infrastructure through Configuration Baselining

VEA-bility Security Metric: A Network Security Analysis Tool

Linux Security on HP Servers: Security Enhanced Linux. Abstract. Intended Audience. Technical introduction

System Assurance C H A P T E R 12

CIS433/533 - Computer and Network Security Operating System Security

Containers, Docker, and Security: State of the Union

Arnab Roy Fujitsu Laboratories of America and CSA Big Data WG

Adjusting Prevention Policy Options Based on Prevention Events. Version 1.0 July 2006

KVM Security - Where Are We At, Where Are We Going

A Simple Implementation and Performance Evaluation Extended-Role Based Access Control

X05. An Overview of Source Code Scanning Tools. Loulwa Salem. Las Vegas, NV. IBM Corporation IBM System p, AIX 5L & Linux Technical University

NSA/DHS CAE in IA/CD 2014 Mandatory Knowledge Unit Checklist 4 Year + Programs

BM482E Introduction to Computer Security

Example of Standard API

Lecture VII : Public Key Infrastructure (PKI)

Access Control Models Part I. Murat Kantarcioglu UT Dallas

Oracle Solaris Security: Mitigate Risk by Isolating Users, Applications, and Data

Trusted RUBIX TM. Version 6. Multilevel Security in Trusted RUBIX White Paper. Revision 2 RELATIONAL DATABASE MANAGEMENT SYSTEM TEL

With Great Power comes Great Responsibility: Managing Privileged Users

7. Public Key Cryptosystems and Digital Signatures, 8. Firewalls, 9. Intrusion detection systems, 10. Biometric Security Systems, 11.

ANNEXURE-1 TO THE TENDER ENQUIRY NO.: DPS/AMPU/MIC/1896. Network Security Software Nessus- Technical Details

8 Steps for Network Security Protection

Access Control Lists in Linux & Windows

Likewise Security Benefits

J-202. IT 4823 Information Security Administration. Linux Security Model. Linux Security. In Room. Linux Security April 23

Meeting Cyber Security Challenges

ArcGIS Server Security Threats & Best Practices David Cordes Michael Young

CEN 559 Selected Topics in Computer Engineering. Dr. Mostafa H. Dahshan KSU CCIS

CloudPassage Halo Technical Overview

Kernel Intrusion Detection System

Computer Security: Principles and Practice

Security within a development lifecycle. Enhancing product security through development process improvement

UNCLASSIFIED Version 1.0 May 2012

Rule Set Based Access Control (RSBAC)

Architecture. The DMZ is a portion of a network that separates a purely internal network from an external network.

NETWORK AND CERTIFICATE SYSTEM SECURITY REQUIREMENTS

Information Security Measures and Monitoring System at BARC. - R.S.Mundada Computer Division B.A.R.C., Mumbai-85

Introduction to IT Security

Role Based Access Control: Adoption and Implementation in the Developing World

DMZ Gateways: Secret Weapons for Data Security

CIS 551 / TCOM 401 Computer and Network Security

? Resource. Outline. Access Control and Operating System Security. Access control. Access control matrix. Capabilities. Two implementation concepts

Lecture 17 - Network Security

Nixu SNS Security White Paper May 2007 Version 1.2

Transcription:

Mandatory Access Control in Linux CMPSC 443 - Spring 2012 Introduction Computer and Network Security Professor Jaeger www.cse.psu.edu/~tjaeger/cse443-s12/

In the early 2000s Root and administrator Many programs needed privilege, so they ran will full system permissions Consider a network-facing daemon Services requests at a well-known port Low-numbered, so needs root access But, also accessible to adversaries A bad combination... What should we do? 2

Confining Network-Facing Daemons Limit permissions of network-facing daemons Confine them Keep them confined Cannot change their permissions How do we do that? Short answer & a long story... 3

Mandatory Access Control System-Defined Policy Fixed Set of Subject and Object Labels Fixed Permission Assignments Fixed Label Assignments: (e.g., file to object label) Fixed Transitions (e.g., setuid) O 1 O 2 O 3 J R R W R W S 2 N R R W S 3 N R R W 4

Multi-Level Security is MAC Access is allowed if subject clearance level >= object access class and object categories subset-of subject categories (read down) Q: What would write-up be? Hence, Bob: CONF., {INTEL}) Trent: TS, {CRYPTO, NUC, INTEL}) Alice: (SEC., {CRYTPO, NUC}) DocB: (SECRET, {CRYPTO}) DocA: (CONFIDENTIAL, {INTEL}) DocC: (UNCLASSIFIED, {NUC}) 5

Why MLS Won t Work Lots of information flows that violate MLS For secrecy And integrity Have to manage manually No way... So, what do we do? LOMAC MIC Others Type Enforcement 6

MAC in Linux In 2001, Linus Torvalds authorized the development of a reference monitor for Linux So, he didn t have to choose a single security approach Linux Security Modules framework was born LSM defines an interface for reference monitoring modules Anybody could build an LSM! Introduced in Linux 2.6 Version built for FreeBSD Underway for MAC OS X Also, implemented in a variety of user-space programs (X) MAC has been in Trusted Solaris for years... But, only one MLS approach (now includes more) 7

Linux Security Modules Approach Reference monitor interface, module, policy Entry Points Access Hook System Interface Authorize Request? Access Hook Security-sensitive Operation Access Hook Monitor Policy Security-sensitive Operation Security-sensitive Operation Yes/No 8

Where Do Hooks Go? What property must an authorization hook placement satisfy? Think reference monitor How do you know when you have satisfied this property? Not easy Several missing placements were later identified Still looking for an automated method to place authorization hooks in legacy code 9

MAC and Systems What is necessary to be a system that enforces MAC policies? Specify: Mandatory Protection System Enforce: Reference Monitor Plus, others Management: Policy development tools Services: MAC-aware services Applications: Work with MAC limitations What do these systems look like? We ll examine SELinux 10

SELinux LSM + much more SELinux Bootstrap SELinux-aware Services System Processes (1) Load Policy (2) Authenticate SELinuxfs (3) Syscalls Linux Kernel SELinux LSM 11

SELinux uses Type Enforcement MAC Policy Subjects and Objects Labeled Access Matrix Policy Processes with subject label Can access object of object label If operations in matrix cell allow Focus: Least Privilege Just permissions necessary O 1 O 2 O 3 S 1 Y Y N S 2 N Y N S 3 N Y Y 12

SELinux Protection State The permissions in an SELinux system are produced by a runtime analysis (same with AppArmor) Step 1: Run programs In a controlled (no attacker) environment No enforcement is on Step 2: Audit all permissions used Step 3: Generate policy file Give the subject label associated with that program All the permissions in the audit file Why does this satisfy confidentiality or integrity? 13

SELinux Labeling State Files and users known to the system at boot-time must be associated with their MAC policy labels Map file paths to labels (regular expressions) Map users to labels (by name) These labels are assigned to their initial processes How are new files/processes labeled? How does setuid work? 14

SELinux Transition State Run the privileged passwd program Simplified view -- takes 4 policy rules to do this User Proc user_t Fork User Proc user_t Exec passwd_t Root Proc passwd_t 15

SELinux Mandatory Protection System How many rules are necessary for a Linux distribution? Labeling State - every file and process Protection State - every subject, object, operation Transition State - every process and file transition on access 16

Configuring Secure Systems How do administrators manage MAC systems? Step 1: Choose an OS distribution Has a MAC policy already Step 2: Configure a firewall policy Connects MAC processes with network access to network Most processes are given network access Step 3: Track vulnerabilities Pick your favorite site - CERT, CVE, BugTraq, SANS,... Step 4: Run vulnerability scanners on your system See if you are vulnerable If so, remove/update that program or change network NOTE: Do not change the MAC policy 17

MAC Upsides Security Limits access of root processes Controls network-facing daemons Protects system processes Protects kernel Usability Default configuration with OS Distros Mostly enables system to run Does not require any effort for admins Bottom line: MAC is here, but in a more limited way than people expected 18

(Commodity) MAC Myths Security MAC protects one of your processes from another MAC protects one of your processes from another user s processes MAC controls processes use of network MAC ensures that system processes only receive trusted data MAC makes the adversary compromise several processes to access the kernel MAC enforces confidentiality and integrity 19

Take Away In the early part of the last decade adversaries were taking advantage of weak access protections MAC was introduced into commodity systems to prevent this MAC threat model is network attacks Network-facing daemons MAC and code hardening of these daemons have improved the situation but now escalation from untrusted clients through local exploits is common Could SELinux prevent Stuxnet? 20