CSE 30341 Operating System Principles Security. CSE 30341 – Operating System Principles2 Security The Security Problem Program Threats System and Network.

Slides:



Advertisements
Similar presentations
Dr. Kalpakis CMSC 421, Operating Systems. Fall 2008 URL: Security.
Advertisements

Spring 2000CS 4611 Security Outline Encryption Algorithms Authentication Protocols Message Integrity Protocols Key Distribution Firewalls.
1 Network Security Outline Encryption Algorithms Authentication Protocols Message Integrity Protocols Key Distribution Firewalls.
Chapter 15 Security Bernard Chen Spring Protection vs. Security Protection (Ch.14) deals with internal problem Security (Ch. 15) Deals with external.
1 Computer Security Instructor: Dr. Bo Sun. 2 Course Objectives Understand basic issues, concepts, principles, and mechanisms in computer network security.
Security  The Security Problem  Authentication  Program Threats  System Threats  Securing Systems  Intrusion (unwanted involvement) Detection  Encryption.
Silberschatz, Galvin and Gagne  Operating System Concepts The Security Problem A system is secure iff its resources are used and accessed as.
1 Counter-measures Threat Monitoring Cryptography as a security tool Encryption Digital Signature Key distribution.
Chapter 15: Security. The Security Problem Security must consider external environment of the system, and protect the system resources Intruders (crackers)
19.1 Silberschatz, Galvin and Gagne ©2003 Operating System Concepts with Java Chapter 19: Security The Security Problem Authentication Program Threats.
Security A system is secure if its resources are used and accessed as intended under all circumstances. It is not generally possible to achieve total security.
Spring 2002CS 4611 Security Outline Encryption Algorithms Authentication Protocols Message Integrity Protocols Key Distribution Firewalls.
Security. The Security Problem Security must consider external environment of the system, and protect the system resources Intruders (crackers) attempt.
8-1 What is network security? Confidentiality: only sender, intended receiver should “understand” message contents m sender encrypts message m receiver.
Lecture 21 Chapter 14: Protection Chapter 15: Security
Spring 2003CS 4611 Security Outline Encryption Algorithms Authentication Protocols Message Integrity Protocols Key Distribution Firewalls.
Silberschatz, Galvin and Gagne  Operating System Concepts Module 19: Security The Security Problem Authentication Program Threats System Threats.
Chapter 15: Security Silberschatz, Galvin and Gagne ©2005 Operating System Concepts – 7 th Edition, Jan 10, 2005 Chapter 15: Security The Security.
Protection and Security CSCI 444/544 Operating Systems Fall 2008.
University of Calgary – CPSC 441.  The field of network security is about:  how bad guys can attack computer networks  how we can defend networks against.
Alter – Information Systems 4th ed. © 2002 Prentice Hall 1 E-Business Security.
Security.
CSE Computer Networks Prof. Aaron Striegel Department of Computer Science & Engineering University of Notre Dame Lecture 23 – April 6, 2010.
Chapter 15: Security (Part 1). The Security Problem Security must consider external environment of the system, and protect the system resources Intruders.
CS 149: Operating Systems April 30 Class Meeting Department of Computer Science San Jose State University Spring 2015 Instructor: Ron Mak
Operating Systems Protection & Security.
15.1 Silberschatz, Galvin and Gagne ©2005 Operating System Concepts – 7 th Edition, Jan 10, 2005 The Security Problem Security must consider external environment.
13.1 Silberschatz, Galvin and Gagne ©2011 Operating System Concepts Essentials – 8 th Edition Security.
Silberschatz and Galvin  Operating System Concepts Module 20: Security The Security Problem Authentication Program Threats System Threats Threat.
14.1 Silberschatz, Galvin and Gagne ©2009 Operating System Concepts with Java – 8 th Edition Chapter 14: Protection.
Silberschatz, Galvin and Gagne ©2009 Operating System Concepts – 8 th Edition, Chapter 14: Protection.
Network Security. Cryptography Cryptography functions Secret key (e.g., DES) Public key (e.g., RSA) Message digest (e.g., MD5) Security services Privacy:
Certificate-Based Operations. Module Objectives By the end of this module participants will be able to: Define how cryptography is used to secure information.
System Security. The Security Problem Security must consider external environment of the system, and protect the system resources Intruders (crackers)
4-Jun-164/598N: Computer Networks Differentiated Services Problem with IntServ: scalability Idea: segregate packets into a small number of classes –e.g.,
Chapter 15: Security. 15.2CSCI Operating Systems Chapter 15: Security The Security Problem Program Threats System and Network Threats Cryptography.
1 Lecture 11 protection and Security Operating System Fall 2005.
Introduction1-1 Data Communications and Computer Networks Chapter 6 CS 3830 Lecture 28 Omar Meqdadi Department of Computer Science and Software Engineering.
1 Network Security Basics. 2 Network Security Foundations: r what is security? r cryptography r authentication r message integrity r key distribution.
Security Many secure IT systems are like a house with a locked front door but with a side window open -somebody.
Silberschatz, Galvin and Gagne ©2009 Operating System Concepts – 8 th Edition, Security.
Network Security7-1 Today r Reminders m Ch6 Homework due Wed Nov 12 m 2 nd exams have been corrected; contact me to see them r Start Chapter 7 (Security)
Chapter 15: Security Silberschatz, Galvin and Gagne ©2005 Operating System Concepts Chapter 15: Security The Security Problem Program Threats System.
Silberschatz, Galvin and Gagne ©2009 Operating System Concepts – 8 th Edition, Chapter 15: System Security.
Network Security Continued. Digital Signature You want to sign a document. Three conditions. – 1. The receiver can verify the identity of the sender.
CS 6401 Security Outline Encryption Algorithms Authentication Protocols Message Integrity Protocols Key Distribution Firewalls.
Silberschatz, Galvin and Gagne ©2009 Operating System Concepts – 8 th Edition, Chapter 15: Security.
14.1 Silberschatz, Galvin and Gagne ©2009 Operating System Concepts with Java – 8 th Edition Protection.
Invitation to Computer Science 5 th Edition Chapter 8 Information Security.
1 Computer Security Instructor: Dr. Bo Sun. 2 Course Objectives Understand basic issues, concepts, principles, and mechanisms in computer network security.
@Yuan Xue Case Study (Mid-term question) Bob sells BatLab Software License Alice buys BatLab Credit card information Number of.
Silberschatz, Galvin and Gagne ©2013 Operating System Concepts Essentials – 2 nd Edition Chapter 14a: Security I.
Silberschatz, Galvin and Gagne ©2009 Operating System Concepts – 8 th Edition Chapter 15: Security.
Chapter 15: Security.
Security Outline Encryption Algorithms Authentication Protocols
Advanced Computer Networks
Chapter 15: Security Source & Copyright: Operating System Concepts, Silberschatz, Galvin and Gagne.
Chapter 15: Security Modified by Dr. Neerja Mhaskar for CS 3SH3.
Chapter 6: Protection & Security
Chapter 15: Security.
12: Security The Security Problem Authentication Program Threats
Message Digest Cryptographic checksum One-way function Relevance
Network Security Basics
Security.
Operating System Concepts
Advanced Computer Networks
Operating System Concepts
Chapter 14: Protection.
Presentation transcript:

CSE Operating System Principles Security

CSE – Operating System Principles2 Security The Security Problem Program Threats System and Network Threats Cryptography as a Security Tool User Authentication Implementing Security Defenses Firewalling to Protect Systems and Networks Computer-Security Classifications An Example: Windows

CSE – Operating System Principles3 Objectives To discuss security threats and attacks To explain the fundamentals of encryption, authentication, and hashing To examine the uses of cryptography in computing To describe the various countermeasures to security attacks

CSE – Operating System Principles4 The Security Problem System secure if resources used and accessed as intended under all circumstances – Unachievable Intruders (crackers) attempt to breach security Threat is potential security violation Attack is attempt to breach security Attack can be accidental or malicious Easier to protect against accidental than malicious misuse

CSE – Operating System Principles5 Security Violation Categories Breach of confidentiality – Unauthorized reading of data Breach of integrity – Unauthorized modification of data Breach of availability – Unauthorized destruction of data Theft of service – Unauthorized use of resources Denial of service (DOS) – Prevention of legitimate use

CSE – Operating System Principles6 Security Violation Methods Masquerading – Pretending to be an authorized user to escalate privileges Replay attack – As is or with message modification Man-in-the-middle attack – Intruder sits in data flow, masquerading as sender to receiver and vice versa Session hijacking – Intercept an already-established session to bypass authentication

CSE – Operating System Principles7 Security Measure Levels Impossible to have absolute security, but make cost to perpetrator sufficiently high to deter most intruders Security must occur at four levels to be effective: – Physical – Human – Operating System – Network

CSE – Operating System Principles8 Program Threats Many variations, many names Trojan Horse – Code segment that misuses its environment – Exploits mechanisms for allowing programs written by users to be executed by other users Trap Door – Specific user identifier or password that circumvents normal security procedures – Typically meant for benign purposes

CSE – Operating System Principles9 Program Threats (Cont.) Logic Bomb – Program that initiates a security incident under certain circumstances Stack and Buffer Overflow – Exploits a bug in a program (overflow either the stack or memory buffers) – Failure to check bounds on inputs, arguments – Write past arguments on the stack into the return address on stack – When routine returns from call, returns to hacked address Pointed to code loaded onto stack that executes malicious code – Unauthorized user or privilege escalation

CSE – Operating System Principles10 C Program with Buffer-overflow Condition #include #define BUFFER SIZE 256 int main(int argc, char *argv[]) { char buffer[BUFFER SIZE]; if (argc < 2) return -1; else { strcpy(buffer,argv[1]); return 0; }

CSE – Operating System Principles11 Layout of Typical Stack Frame

CSE – Operating System Principles12 Modified Shell Code #include int main(int argc, char *argv[]) { execvp(‘‘\bin\sh’’,‘‘\bin \sh’’, NULL); return 0; }

CSE – Operating System Principles13 Hypothetical Stack Frame Before attack After attack

CSE – Operating System Principles14 Program Threats (Cont.) Viruses – Code fragment embedded in legitimate program – Self-replicating, designed to infect other computers – Very specific to CPU architecture, operating system, applications – Usually borne via or as a macro Visual Basic Macro to reformat hard drive Sub AutoOpen() Dim oFS Set oFS = CreateObject(’’Scripting.FileSystemObject’’) vs = Shell(’’c:command.com /k format c:’’,vbHide) End Sub

CSE – Operating System Principles15 Program Threats (Cont.) Virus dropper inserts virus onto the system Many categories of viruses, literally many thousands of viruses – File / parasitic – Boot / memory – Macro – Source code – Polymorphic to avoid having a virus signature – Encrypted – Stealth – Tunneling – Multipartite – Armored

CSE – Operating System Principles16 A Boot-sector Computer Virus

CSE – Operating System Principles17 The Threat Continues Attacks still common, still occurring Attacks moved over time from science experiments to tools of organized crime – Targeting specific companies – Creating botnets to use as tool for spam and DDOS delivery – Keystroke logger to grab passwords, credit card numbers Why is Windows the target for most attacks? – Most common – Everyone is an administrator – Monoculture considered harmful

CSE – Operating System Principles18 System and Network Threats (Cont.) Worms – use spawn mechanism; standalone program Internet worm – Exploited UNIX networking features (remote access) and bugs in finger and sendmail programs – Exploited trust-relationship mechanism used by rsh to access friendly systems without use of password – Grappling hook program uploaded main worm program 99 lines of C code – Hooked system then uploaded main code, tried to attack connected systems – Also tried to break into other users accounts on local system via password guessing – If target system already infected, abort, except for every 7 th time

CSE – Operating System Principles19 System and Network Threats (Cont.) Port scanning – Automated attempt to connect to a range of ports on one or a range of IP addresses – Detection of answering service protocol – Detection of OS and version running on system – nmap scans all ports in a given IP range for a response – nessus has a database of protocols and bugs (and exploits) to apply against a system – Frequently launched from zombie systems To decrease traceability

CSE – Operating System Principles20 System and Network Threats (Cont.) Denial of Service – Overload the targeted computer preventing it from doing any useful work – Distributed denial-of-service (DDOS) come from multiple sites at once – Consider the start of the TCP/IP-connection handshake (SYN) How many started-connections can the OS handle? – Consider traffic to a web site How can you tell the difference between being a target and being really popular? – Accidental – CS students writing bad fork() code – Purposeful – extortion, punishment

CSE – Operating System Principles21 Friends and Enemies Bob, Alice want to communicate “securely” Trudy, the “intruder” may intercept, delete, add messages Figure 7.1 goes here

CSE – Operating System Principles22 Friends and Enemies

CSE – Operating System Principles23 Overview Cryptography functions – Secret key (e.g., DES) – Public key (e.g., RSA) – Message digest (e.g., MD5) Security services – Privacy: preventing unauthorized release of information – Authentication: verifying identity of the remote participant – Integrity: making sure message has not been altered

CSE – Operating System Principles24 Secret Key (DES)

CSE – Operating System Principles25 Symmetric Key Substitution cipher: substituting one thing for another – monoalphabetic cipher: substitute one letter for another plaintext: abcdefghijklmnopqrstuvwxyz ciphertext: mnbvcxzasdfghjklpoiuytrewq Plaintext: bob. i love you. alice ciphertext: nkn. s gktc wky. mgsbc E.g.:

CSE – Operating System Principles26 64-bit key (56-bits + 8-bit parity) 16 rounds Each Round + F L i─ 1 R i─ 1 R i K i L i Data Encryption Standard

CSE – Operating System Principles27 Repeat for larger messages Data Encryption Standard

CSE – Operating System Principles28 Public Key (RSA) Encryption & Decryption c = m e mod n m = c d mod n

CSE – Operating System Principles29 RSA (cont) Choose two large prime numbers p and q (each 256 bits) Multiply p and q together to get n Choose the encryption key e, such that e and (p - 1) x (q - 1) are relatively prime. Two numbers are relatively prime if they have no common factor greater than one Compute decryption key d such that d*e = 1 mod ((p - 1) x (q - 1)) Construct public key as (e, n) Construct private key as (d, n) Discard (do not disclose) original primes p and q

CSE – Operating System Principles30 RSA Example Bob chooses p=5, q=7. Then n=35, z=24. e=5 (so e, z relatively prime). d=29 (so ed-1 exactly divisible by z). letter m m e c = m mod n e l c m = c mod n d c d letter l encrypt: decrypt:

CSE – Operating System Principles31 Message Digest Cryptographic checksum – just as a regular checksum protects the receiver from accidental changes to the message, a cryptographic checksum protects the receiver from malicious changes to the message. One-way function – given a cryptographic checksum for a message, it is virtually impossible to figure out what message produced that checksum; it is not computationally feasible to find two messages that hash to the same cryptographic checksum. Relevance – if you are given a checksum for a message and you are able to compute exactly the same checksum for that message, then it is highly likely this message produced the checksum you were given.

CSE – Operating System Principles32 Authentication Protocols Three-way handshake ClientServer ClientId, E (, CHK) E( y +, CHK) E(SK, SHK) Y

CSE – Operating System Principles33 Trusted third party (Kerberos)

CSE – Operating System Principles34 Public key authentication AB E ( x, Public B ) x

CSE – Operating System Principles35 Message Integrity Protocols Digital signature using RSA – special case of a message integrity where the code can only have been generated by one participant – compute signature with private key and verify with public key Keyed MD5 – sender: m + MD5(m + k) + E(E(k,rcv_public), snd_private) – receiver recovers random key using the sender ’ s public key applies MD5 to the concatenation of this random key message MD5 with RSA signature – sender: m + E(MD5(m), private) – receiver decrypts signature with sender ’ s public key compares result with MD5 checksum sent with message

CSE – Operating System Principles36 Public Key Distribution Certificate – special type of digitally signed document: “ I certify that the public key in this document belongs to the entity named in this document, signed X. ” – the name of the entity being certified – the public key of the entity – the name of the certification authority – a digital signature Certification Authority (CA) – administrative entity that issues certificates – useful only to someone that already holds the CA ’ s public key.

CSE – Operating System Principles37 Key Distribution (cont) Chain of Trust – if X certifies that a certain public key belongs to Y, and Y certifies that another public key belongs to Z, then there exists a chain of certificates from X to Z – someone that wants to verify Z ’ s public key has to know X ’ s public key and follow the chain Certificate Revocation List

CSE – Operating System Principles38 Certificate Serial number (unique to issuer) info about certificate owner, including algorithm and key value itself (not shown)  info about certificate issuer  valid dates  digital signature by issuer

CSE – Operating System Principles39 User Authentication Crucial to identify user correctly, as protection systems depend on user ID User identity most often established through passwords, can be considered a special case of either keys or capabilities Passwords must be kept secret – Frequent change of passwords – History to avoid repeats – Use of “non-guessable” passwords – Log all invalid access attempts (but not the passwords themselves)

CSE – Operating System Principles40 Secure Shell (SSH) Remote login service (replaces telnet and rlogin). Provides authentication, integrity, and confidentiality. SSH version 2: SSH-TRANS, SSH-AUTH, SSH-CONN.

CSE – Operating System Principles41 Transport Layer Security (TLS) Secure Socket Layer (SSL). Secure HTTP (HTTPS). Handshake protocol and record protocol.

CSE – Operating System Principles42 Firewalls Filter-Based Solution – example ( , 1234, , 80 ) (*,*, , 80 ) – default: forward or not forward? – how dynamic?

CSE – Operating System Principles43 Proxy-Based Firewalls Problem: complex policy Example: web server Solution: proxy Design: transparent vs. classical Limitations: attacks from within