Courtesy of Professors Chris Clifton & Matt Bishop INFSCI 2935: Introduction of Computer Security1 November 13, 2003 Malicious Code Vulnerability Analysis.

Slides:



Advertisements
Similar presentations
Intrusion Detection Systems (I) CS 6262 Fall 02. Definitions Intrusion Intrusion A set of actions aimed to compromise the security goals, namely A set.
Advertisements

Dr. Kalpakis CMSC 421, Operating Systems. Fall 2008 URL: Security.
Communications of the ACM (CACM), Vol. 32, No. 6, June 1989
Chapter 3 (Part 1) Network Security
CS526: Information Security Chris Clifton November 25, 2003 Malicious Code.
Malicious Logic What is malicious logic Types of malicious logic Defenses Computer Security: Art and Science © Matt Bishop.
Silberschatz, Galvin and Gagne  Operating System Concepts The Security Problem A system is secure iff its resources are used and accessed as.
19.1 Silberschatz, Galvin and Gagne ©2003 Operating System Concepts with Java Chapter 19: Security The Security Problem Authentication Program Threats.
1 Vulnerability Analysis CSSE 490 Computer Security Mark Ardis, Rose-Hulman Institute April 26, 2004.
________________ CS3235, Nov 2002 Viruses Adapted from Pfleeger[Chap 5]. A virus is a program [fragment] that can pass on malicious code [usually itself]
Intrusion Detection Systems and Practices
1 Intrusion Detection CSSE 490 Computer Security Mark Ardis, Rose-Hulman Institute May 4, 2004.
1 Building with Assurance CSSE 490 Computer Security Mark Ardis, Rose-Hulman Institute May 10, 2004.
Lesson 13-Intrusion Detection. Overview Define the types of Intrusion Detection Systems (IDS). Set up an IDS. Manage an IDS. Understand intrusion prevention.
Intrusion detection Anomaly detection models: compare a user’s normal behavior statistically to parameters of the current session, in order to find significant.
Silberschatz, Galvin and Gagne  Operating System Concepts Module 19: Security The Security Problem Authentication Program Threats System Threats.
Lecture 15 Overview. Kinds of Malicious Codes Virus: a program that attaches copies of itself into other programs. – Propagates and performs some unwanted.
1 Malicious Logic CSSE 490 Computer Security Mark Ardis, Rose-Hulman Institute March 25, 2004.
Guide to Operating System Security Chapter 2 Viruses, Worms, and Malicious Software.
Lecture 11 Intrusion Detection (cont)
Department Of Computer Engineering
Henric Johnson1 Chapter 10 Malicious Software Henric Johnson Blekinge Institute of Technology, Sweden
1 Chap 10 Malicious Software. 2 Viruses and ”Malicious Programs ” Computer “Viruses” and related programs have the ability to replicate themselves on.
Chapter 15: Security (Part 1). The Security Problem Security must consider external environment of the system, and protect the system resources Intruders.
Information Systems Security Computer System Life Cycle Security.
IIT Indore © Neminah Hubballi
BLENDED ATTACKS EXPLOITS, VULNERABILITIES AND BUFFER-OVERFLOW TECHNIQUES IN COMPUTER VIRUSES By: Eric Chien and Peter Szor Presented by: Jesus Morales.
Lecture 14 Overview. Program Flaws Taxonomy of flaws: – how (genesis) – when (time) – where (location) the flaw was introduced into the system 2 CS 450/650.
1 Higher Computing Topic 8: Supporting Software Updated
1 Chap 10 Virus. 2 Viruses and ”Malicious Programs ” Computer “Viruses” and related programs have the ability to replicate themselves on an ever increasing.
CSCE 522 Lecture 12 Program Security Malicious Code.
Chapter 10 Malicious software. Viruses and ” Malicious Programs Computer “ Viruses ” and related programs have the ability to replicate themselves on.
Operating system Security By Murtaza K. Madraswala.
1 IS 2150 / TEL 2810 Information Security & Privacy James Joshi Associate Professor, SIS Lecture 9 Oct 30, 2013 Authentication, Identity Vulnerability.
Malicious Logic and Defenses. Malicious Logic Trojan Horse – A Trojan horse is a program with an overt (documented or known) effect and covert (undocumented.
Intrusion Detection System (IDS). What Is Intrusion Detection Intrusion Detection is the process of identifying and responding to malicious activity targeted.
1 IS 2150 / TEL 2810 Introduction to Security James Joshi Associate Professor, SIS Lecture 9 Nov 25, 2008 Authentication, Identity Malicious Code, Vulnerability.
1 IS 2150 / TEL 2810 Introduction to Security James Joshi Assistant Professor, SIS Lecture 12 Nov 29, 2007 Malicious Code, Vulnerability Analysis, Intrusion.
Unix Security Assessing vulnerabilities. Classifying vulnerability types Several models have been proposed to classify vulnerabilities in UNIX-type Oses.
Cryptography and Network Security Sixth Edition by William Stallings.
Computer Systems Viruses. Virus A virus is a program which can destroy or cause damage to data stored on a computer. It’s a program that must be run in.
Intrusion Detection Systems Paper written detailing importance of audit data in detecting misuse + user behavior 1984-SRI int’l develop method of.
1 Assurance, Malicious Code Vulnerability Analysis Nov 30, 2006 Lecture 9 IS 2150 / TEL 2810 Introduction to Security.
CS526: Information Security Chris Clifton November 25, 2003 Intrusion Detection.
Vulnerability Analysis
14.1 Silberschatz, Galvin and Gagne ©2009 Operating System Concepts with Java – 8 th Edition Protection.
Design Principles and Common Security Related Programming Problems
Chapter 23: Vulnerability Analysis Dr. Wayne Summers Department of Computer Science Columbus State University
I NTRUSION P REVENTION S YSTEM (IPS). O UTLINE Introduction Objectives IPS’s Detection methods Classifications IPS vs. IDS IPS vs. Firewall.
Role Of Network IDS in Network Perimeter Defense.
Page 1 Viruses. Page 2 What Is a Virus A virus is basically a computer program that has been written to perform a specific set of tasks. Unfortunately,
1 IS 2150 / TEL 2810 Introduction to Security James Joshi Associate Professor, SIS Lecture 12 April 10, 2013 Intrusion Detection, Firewalls & VPN Auditing.
Chapter 29: Program Security Dr. Wayne Summers Department of Computer Science Columbus State University
Vulnerability Analysis
Ch.22 INTRUSION DETECTION
Chap 20. Vulnerability Analysis
Chap 10 Malicious Software.
Chapter 23: Vulnerability Analysis
VA/PT.
Chapter 22: Malicious Logic
Intrusion Detection system
Chapter 29: Program Security
Chap 10 Malicious Software.
IS 2150 / TEL 2810 Information Security & Privacy
Intrusion Detection.
Operating System Concepts
Malicious Program and Protection
Chapter 14: Protection.
IS 2150 / TEL 2810 Introduction to Security
Presentation transcript:

Courtesy of Professors Chris Clifton & Matt Bishop INFSCI 2935: Introduction of Computer Security1 November 13, 2003 Malicious Code Vulnerability Analysis Intrusion Detection Lecture 11

INFSCI 2935: Introduction to Computer Security2 What is Malicious Code? Set of instructions that causes a security policy to be violated Set of instructions that causes a security policy to be violated  Is an unintentional mistake that violates policy malicious code? (Tricked into doing that?)  What about “unwanted” code that doesn’t cause a security breach? Generally relies on “legal” operations Generally relies on “legal” operations  Authorized user could perform operations without violating policy  Malicious code “mimics” authorized user

INFSCI 2935: Introduction to Computer Security3 Types of Malicious Code Trojan Horse Trojan Horse  Trick user into executing malicious code Virus Virus  Replicates and inserts itself into fixed set of files Worm Worm  Copies itself from computer to computer

INFSCI 2935: Introduction to Computer Security4 Trojan Horse Program with an overt (expected) and covert (unexpected) effect Program with an overt (expected) and covert (unexpected) effect  Appears normal/expected  Covert effect violates security policy User tricked into executing Trojan horse User tricked into executing Trojan horse  Expects (and sees) overt behavior  Covert effect performed with user’s authorization Trojan horse may replicate Trojan horse may replicate  Create copy on execution  Spread to other users/systems

INFSCI 2935: Introduction to Computer Security5 Propagation  Perpetrator cat >/homes/victim/ls /homes/victim/ls <<eof cp /bin/sh /tmp/.xxsh chmod u+s,o+x /tmp/.xxsh rm./ls ls $* eof  Victimls It is a violation to trick someone into creating a shell that is setuid to themselves It is a violation to trick someone into creating a shell that is setuid to themselves How to replicate this? How to replicate this?

INFSCI 2935: Introduction to Computer Security6 Virus Self-replicating code Self-replicating code  A freely propagating Trojan horse some disagree that it is a Trojan horse  Inserts itself into another file Alters normal code with “infected” version Operates when infected code executed Operates when infected code executed If spread condition then For target files if not infected then alter to include virus Perform malicious action Execute normal program

INFSCI 2935: Introduction to Computer Security7 Virus Types Boot Sector Infectors (The Brain Virus) Boot Sector Infectors (The Brain Virus)  Problem: How to ensure virus “carrier” executed?  Solution: Place in boot sector of disk Run on any boot  Propagate by altering boot disk creation Less common with few boots off floppies Executable infector (The Jerusalem Virus, Friday 13 th, not 1987 ) Executable infector (The Jerusalem Virus, Friday 13 th, not 1987 )  Malicious code placed at beginning of legitimate program (.COM.EXE files)  Runs when application run  Application then runs normally Multipartite virus : boot sector + executable infector Multipartite virus : boot sector + executable infector

INFSCI 2935: Introduction to Computer Security8 Virus Types/Properties Terminate and Stay Resident Terminate and Stay Resident  Stays active in memory after application complete  Allows infection of previously unknown files Trap calls that execute a program  Can be boot sector infectors or executable infectors (Brain and Jerusalem) Stealth (an executable infector) Stealth (an executable infector)  Conceal Infection Trap read to provide disinfected file Let execute call infected file Encrypted virus Encrypted virus Prevents “signature” to detect virus [Deciphering routine, Enciphered virus code, Deciphering Key] Polymorphism Polymorphism Change virus code to something equivalent each time it propagates

INFSCI 2935: Introduction to Computer Security9 Virus Types/Properties Macro Virus Macro Virus  Composed of a sequence of instructions that is interpreted rather than executed directly  Infected “executable” isn’t machine code Relies on something “executed” inside application data Example: Melissa virus infected Word 97/98 docs Otherwise similar properties to other viruses Otherwise similar properties to other viruses  Architecture-independent  Application-dependent

INFSCI 2935: Introduction to Computer Security10 Worms Replicates from one computer to another Replicates from one computer to another  Self-replicating: No user action required  Virus: User performs “normal” action  Trojan horse: User tricked into performing action Communicates/spreads using standard protocols Communicates/spreads using standard protocols

INFSCI 2935: Introduction to Computer Security11 Other forms of malicious logic We’ve discussed how they propagate We’ve discussed how they propagate  But what do they do? Rabbits/Bacteria Rabbits/Bacteria  Exhaust system resources of some class  Denial of service ; e.g., While (1) {mkdir x; chdir x} Logic Bomb Logic Bomb  Triggers on external event Date, action  Performs system-damaging action Often related to event Others? Others?

INFSCI 2935: Introduction to Computer Security12 What do we Do? Turing machine definition of a virus Turing machine definition of a virus  Makes copies on parts of tape not including v Is it decidable if an arbitrary program does this? Is it decidable if an arbitrary program does this?  No! v’v

INFSCI 2935: Introduction to Computer Security13 We can’t detect it: Now what? Detection Signature-based antivirus Signature-based antivirus  Look for known patterns in malicious code  Always a battle with the attacker  Great business model! Checksum (file integrity, e.g. Tripwire) Checksum (file integrity, e.g. Tripwire)  Maintain record of “good” version of file Compute signature blocks  Check to see if changed Validate action against specification Validate action against specification  Including intermediate results/actions  N-version programming: independent programs A fault-tolerance approach (diversity)

INFSCI 2935: Introduction to Computer Security14 Detection Proof-carrying code Proof-carrying code  Code includes proof of correctness  At execution, verify proof against code If code modified, proof will fail Statistical Methods Statistical Methods  High/low number of files read/written  Unusual amount of data transferred  Abnormal usage of CPU time

INFSCI 2935: Introduction to Computer Security15 Defense Clear distinction between data and executable Clear distinction between data and executable  Virus must write to program Write only allowed to data  Must execute to spread/act Data not allowed to execute  Auditable action required to change data to executable

INFSCI 2935: Introduction to Computer Security16 Defense Information Flow Information Flow  Malicious code usurps authority of user  Limit information flow between users If A talks to B, B can no longer talk to C  Limits spread of virus  Problem: Tracking information flow Least Privilege Least Privilege  Programs run with minimal needed privilege  Example: Limit file types accessible by a program

INFSCI 2935: Introduction to Computer Security17 Defense Sandbox / Virtual Machine Sandbox / Virtual Machine  Run in protected area  Libraries / system calls replaced with limited privilege set Use Multi-Level Security Mechanisms Use Multi-Level Security Mechanisms  Place programs at lowest level  Don’t allow users to operate at that level  Prevents writes by malicious code

Courtesy of Professors Chris Clifton & Matt Bishop INFSCI 2935: Introduction of Computer Security18 Vulnerability Analysis

INFSCI 2935: Introduction to Computer Security19 Vulnerability Analysis Vulnerability or security flaw: specific failures of security controls (procedures, technology or management) Vulnerability or security flaw: specific failures of security controls (procedures, technology or management)  Errors in code  Human violators  Mismatch between assumptions Exploit: Use of vulnerability to violate policy Exploit: Use of vulnerability to violate policy Attacker: Attempts to exploit the vulnerability Attacker: Attempts to exploit the vulnerability

INFSCI 2935: Introduction to Computer Security20 Techniques for Detecting Vulnerabilities System Verification System Verification  Determine preconditions, post-conditions  Validate that system ensures post-conditions given preconditions Can prove the absence of vulnerabilities Penetration testing Penetration testing  Start with system/environment characteristics  Try to find vulnerabilities Can not prove the absence of vulnerabilities

INFSCI 2935: Introduction to Computer Security21 System Verification What are the problems? What are the problems?  Invalid assumptions  Limited view of system  Still an inexact science  External environmental factors  Incorrect configuration, maintenance and operation of the program or system

INFSCI 2935: Introduction to Computer Security22 Penetration Testing Test strengths of security controls of the complete system Test strengths of security controls of the complete system  Attempt to violate stated policy  Works on in-place system  Framework for evaluating results  Examines procedural, operational and technological controls Typical approach: Red Team, Blue Team Typical approach: Red Team, Blue Team  Red team attempts to discover vulnerabilities  Blue team simulates normal administration Detect attack, respond  White team injects workload, captures results

INFSCI 2935: Introduction to Computer Security23 Types/layers of Penetration Testing Black Box (External Attacker) Black Box (External Attacker)  External attacker has no knowledge of target system  Attacks often build on human element – Social Engineering System access provided (External Attacker) System access provided (External Attacker)  Red team provided with limited access to system Models external attack  Goal is to gain normal or elevated access Then violate policy Internal attacker Internal attacker  Red team provided with authorized user access  Goal is to elevate privilege / violate policy

INFSCI 2935: Introduction to Computer Security24 Red Team Approach Flaw Hypothesis Methodology: Information gathering Information gathering  Examine design, environment, system functionality Flaw hypothesis Flaw hypothesis  Predict likely vulnerabilities Flaw testing Flaw testing  Determine where vulnerabilities exist Flaw generalization Flaw generalization  Attempt to broaden discovered flaws Flaw elimination (often not included) Flaw elimination (often not included)  Suggest means to eliminate flaw Flaw does Not exist Refine with new understanding

INFSCI 2935: Introduction to Computer Security25 Problems with Penetration Testing Nonrigorous Nonrigorous  Dependent on insight (and whim) of testers  No good way of evaluating when “complete” How do we make it systematic? How do we make it systematic?  Try all classes of likely flaws  But what are these? Vulnerability Classification! Vulnerability Classification!

INFSCI 2935: Introduction to Computer Security26 Vulnerability Classification Goal: describe spectrum of possible flaws Goal: describe spectrum of possible flaws  Enables design to avoid flaws  Improves coverage of penetration testing  Helps design/develop intrusion detection How do we classify? How do we classify?  By how they are exploited?  By where they are found?  By the nature of the vulnerability?

INFSCI 2935: Introduction to Computer Security27 Example flaw: xterm log xterm runs as root xterm runs as root  Generates a log file  Appends to log file if file exists Problem: ln /etc/passwd log_file Problem: ln /etc/passwd log_file Solution Solution if (access(“log_file”, W_OK) == 0) fd = open(“log_file”, O_WRONLY|O_APPEND) What can go wrong? What can go wrong?

INFSCI 2935: Introduction to Computer Security28 Example: Finger Daemon (exploited by Morris worm) finger sends name to fingerd finger sends name to fingerd  fingerd allocates 512 byte buffer on stack  Places name in buffer  Retrieves information (local finger) and returns Problem: If name > 512 bytes, overwrites return address Problem: If name > 512 bytes, overwrites return address Exploit: Put code in “name”, pointer to code in bytes 513+ Exploit: Put code in “name”, pointer to code in bytes 513+  Overwrites return address

INFSCI 2935: Introduction to Computer Security29 Vulnerability Classification: Generalize xterm: race condition between validation and use xterm: race condition between validation and use fingerd: buffer overflow on the stack fingerd: buffer overflow on the stack Can we generalize to cover all possible vulnerabilities? Can we generalize to cover all possible vulnerabilities?

INFSCI 2935: Introduction to Computer Security30 RISOS:Research Into Secure Operating Systems (Seven Classes) 1.Incomplete parameter validation –Check parameter before use –E.g., buffer overflow – 2.Inconsistent parameter validation –Different routines with different formats for same data 3.Implicit sharing of privileged / confidential data –OS fails to isolate processes and users 4.Asynchronous validation / inadequate serialization –Race conditions and TOCTTOU flaws 5.Inadequate identification /authentication / authorization –Trojan horse; accounts without passwords 6.Violable prohibition / limit –Improper handling of bounds conditions (e.g., in memory allocation) 7.Exploitable logic error –Incorrect error handling, incorrect resource allocations etc.

INFSCI 2935: Introduction to Computer Security31 Protection Analysis Model Classes Pattern-directed protection evaluation Pattern-directed protection evaluation  Methodology for finding vulnerabilities Applied to several operating systems Applied to several operating systems  Discovered previously unknown vulnerabilities Resulted in two-level hierarchy of vulnerability classes Resulted in two-level hierarchy of vulnerability classes  Ten classes in all

INFSCI 2935: Introduction to Computer Security32 PA flaw classes 1.Improper protection domain initialization and enforcement a.domain: Improper choice of initial protection domain b.exposed representations: Improper isolation of implementation detail (Covert channels) c.consistency of data over time: Improper change d.naming: Improper naming (two objects with same name) e.residuals: Improper deallocation or deletion 2.Improper validation validation of operands, queue management dependencies: 3. Improper synchronization a.interrupted atomic operations: Improper indivisibility b.serialization: Improper sequencing 4. critical operator selection errors: Improper choice of operand or operation

INFSCI 2935: Introduction to Computer Security33 PA analysis procedure A pattern-directed protection evaluation approach A pattern-directed protection evaluation approach  Collect known protection problems  Convert these problems to a more formalized notation (set of conditions)  Eliminate irrelevant features and abstract system- specific components into system-independent components (generalize raw patterns)  Determine relevant features of OS Code  Compare features with generic error patterns

INFSCI 2935: Introduction to Computer Security34 NRL Taxonomy Three classification schemes Three classification schemes  How did it enter  When was it “created”  Where is itGenesis Intentional Malicious TrapdoorTrojan horse NonreplicatingReplicating Logic/time bomb Nonmalicious Covert channel TimingStorage Other

INFSCI 2935: Introduction to Computer Security35 NRL Taxonomy (Genesis) Inadvertent Validation error (Incomplete/Inconsistent) Domain error (including object re-use, residuals, and exposed representation errors Serialization/aliasing (including TCTTOU errors) Boundary conditions violation (including resource exhaustion and violable constraint errors) Other exploitable logic error

INFSCI 2935: Introduction to Computer Security36 NRL Taxonomy: Time Time of introduction Development Requirement specification design Source codeObject code MaintenanceOperation

INFSCI 2935: Introduction to Computer Security37 NRL Taxonomy: Location Location Software Operating System initialization Memory Management Process management / scheduling Device management File Management Identification / Authentication Other / Unknown ApplicationSupport Privileged Utilities Unprivileged Utilities Hardware

INFSCI 2935: Introduction to Computer Security38 Aslam’s Model Attempts to classify faults unambiguously Attempts to classify faults unambiguously  Decision procedure to classify faults Coding Faults Coding Faults  Synchronization errors Timing window Improper serialization  Condition validation errors Bounds not checked Access rights ignored Input not validated Authentication / Identification failure Emergent Faults Emergent Faults  Configuration errors Wrong install location Wrong configuration information Wrong permissions  Environment Faults

INFSCI 2935: Introduction to Computer Security39 Common Vulnerabilities and Exposures (cve.mitre.org) cve.mitre.org Captures specific vulnerabilities Captures specific vulnerabilities  Standard name  Cross-reference to CERT, etc. Entry has three parts Entry has three parts  Unique ID  Description  References Name CVE Description Race condition in xterm allows local users to modify arbitrary files via the logging option. References CERT:CA XF:xterm

INFSCI 2935: Introduction to Computer Security40 Buffer Overflow As much as 50% of today’s widely exploited vulnerability As much as 50% of today’s widely exploited vulnerability Why do we have them Why do we have them  Bad language design usually C, C++ : note they are good from other reasons Hence good programming practice is needed Java is a safer language  Poor programming

INFSCI 2935: Introduction to Computer Security41 Buffer Overflow Some culprits Some culprits  String operations that do no argument checking strcpy() (most risky) gets() (very risky) scanf () (very risky) void main(int argc, char **argv) { char buf[256]; sscanf(argv[0],”%s”, &buf) } Buffer overflow if the input is more than 256 characters Better design dst = (char *)malloc(strlen(src) +1); strcpy(dst, src);

Courtesy of Professors Chris Clifton & Matt Bishop INFSCI 2935: Introduction of Computer Security42 Intrusion Detection

INFSCI 2935: Introduction to Computer Security43 Intrusion Detection/Response Characteristics of systems not under attack: Characteristics of systems not under attack: Denning: Systems under attack fail to meet one or more of the following characteristics Denning: Systems under attack fail to meet one or more of the following characteristics 1.Actions of users/processes conform to statistically predictable patterns 2.Actions of users/processes do not include sequences of commands to subvert security policy 3.Actions of processes conform to specifications describing allowable actions –Denning: Systems under attack fail to meet one or more of these characteristics

INFSCI 2935: Introduction to Computer Security44 Intrusion Detection Idea: Attack can be discovered by one of the above being violated Idea: Attack can be discovered by one of the above being violated  Problem: Definitions hard to make precise  Automated attack tools Designed to violate security policy Example: rootkits: sniff passwords and stay hidden Practical goals of intrusion detection systems: Practical goals of intrusion detection systems:  Detect a wide variety of intrusions (known + unknown)  Detect in a timely fashion  Present analysis in a useful manner Need to monitor many components; proper interfaces needed  Be (sufficiently) accurate Minimize false positives and false negatives

INFSCI 2935: Introduction to Computer Security45 IDS Types: Anomaly Detection Compare characteristics of system with expected values Compare characteristics of system with expected values  report when statistics do not match Threshold metric: when statistics deviate from normal by threshold, sound alarm Threshold metric: when statistics deviate from normal by threshold, sound alarm  E.g., Number of failed logins Statistical moments: based on mean/standard deviation of observations Statistical moments: based on mean/standard deviation of observations  Number of user events in a system  Time periods of user activity  Resource usages profiles Markov model: based on state, expected likelihood of transition to new states Markov model: based on state, expected likelihood of transition to new states  If a low probability event occurs then it is considered suspicious

INFSCI 2935: Introduction to Computer Security46 Anomaly Detection: How do we determine normal? Capture average over time Capture average over time  But system behavior isn’t always average Correlated events Correlated events  Events may have dependencies Machine learning approaches Machine learning approaches  Training data obtained experimentally  Data should relate to as accurate normal operation as possible

INFSCI 2935: Introduction to Computer Security47 IDS Types: Misuse Modeling Does sequence of instructions violate security policy? Does sequence of instructions violate security policy?  Problem: How do we know all violating sequences? Solution: capture known violating sequences Solution: capture known violating sequences  Generate a rule set for an intrusion signature But won’t the attacker just do something different? Often, no: kiddie scripts, Rootkit, … Alternate solution: State-transition approach Alternate solution: State-transition approach  Known “bad” state transition from attack (e.g. use petri-nets)  Capture when transition has occurred (user  root)

INFSCI 2935: Introduction to Computer Security48 Specification Modeling Does sequence of instructions violate system specification? Does sequence of instructions violate system specification?  What is the system specification? Need to formally specify operations of potentially critical code Need to formally specify operations of potentially critical code  trusted code Verify post-conditions met Verify post-conditions met

INFSCI 2935: Introduction to Computer Security49 IDS Systems Anomaly Detection Anomaly Detection  Intrusion Detection Expert System (IDES) – successor is NIDES  Network Security MonitorNSM Misuse Detection Misuse Detection  Intrusion Detection In Our Time- IDIOT (colored Petri-nets)  USTAT?  ASAX (Rule-based) Hybrid Hybrid  NADIR (Los Alamos)  Haystack (Air force, adaptive)  Hyperview (uses neural network)  Distributed IDS (Haystack + NSM)

INFSCI 2935: Introduction to Computer Security50 IDS Architecture Similar to Audit system Similar to Audit system  Log events  Analyze log Difference: Difference:  happens real-time - timely fashion (Distributed) IDS idea: (Distributed) IDS idea:  Agent generates log  Director analyzes logs May be adaptive  Notifier decides how to handle result GrIDS displays attacks in progress Host 1 Agent Host 1 Agent Host 1 Agent Notifier Director

INFSCI 2935: Introduction to Computer Security51 Where is the Agent? Host based IDS Host based IDS  watches events on the host  Often uses existing audit logs Network-based IDS Network-based IDS  Packet sniffing  Firewall logs

INFSCI 2935: Introduction to Computer Security52 IDS Problem IDS useless unless accurate IDS useless unless accurate  Significant fraction of intrusions detected  Significant number of alarms correspond to intrusions Goal is Goal is  Reduce false positives Reports an attack, but no attack underway  Reduce false negatives An attack occurs but IDS fails to report

INFSCI 2935: Introduction to Computer Security53 Intrusion Response Incident Prevention Incident Prevention  Stop attack before it succeeds  Measures to detect attacker  Example: Jailing (als0 Honepots) Make attacker think they are succeeding and confine to an area Intrusion handling Intrusion handling  Preparation for detecting attacks  Identification of an attack  Contain attack  Eradicate attack  Recover to secure state  Follow-up to the attack - Punish attacker

INFSCI 2935: Introduction to Computer Security54 Containment Passive monitoring Passive monitoring  Track intruder actions  Eases recovery and punishment Constraining access Constraining access  Downgrade attacker privileges  Protect sensitive information  Why not just pull the plug?  Example: Honepots

INFSCI 2935: Introduction to Computer Security55 Eradication Terminate network connection Terminate network connection Terminate processes Terminate processes Block future attacks Block future attacks  Close ports  Disallow specific IP addresses  Wrappers around attacked applications

INFSCI 2935: Introduction to Computer Security56 Follow-Up Legal action Legal action  Trace through network Cut off resources Cut off resources  Notify ISP of action Counterattack Counterattack  Is this a good idea?