Rule-based Anomaly Detection on IP Flows

Slides:



Advertisements
Similar presentations
Loss-Sensitive Decision Rules for Intrusion Detection and Response Linda Zhao Statistics Department University of Pennsylvania Joint work with I. Lee,
Advertisements

Network and Application Attacks Contributed by- Chandra Prakash Suryawanshi CISSP, CEH, SANS-GSEC, CISA, ISO 27001LI, BS 25999LA, ERM (ISB) June 2006.
New Directions in Traffic Measurement and Accounting Cristian Estan – UCSD George Varghese - UCSD Reviewed by Michela Becchi Discussion Leaders Andrew.
Network Layer IPv6 Slides were original prepared by Dr. Tatsuya Suda.
Snort: Overview Chris Copeland What is an Intrusion Detection System (IDS)? An intrusion detection system is any system which can identify a network.
Centre de Comunicacions Avançades de Banda Ampla (CCABA) Universitat Politècnica de Catalunya (UPC) Identification of Network Applications based on Machine.
CSE551: Computer Network Review r Network Layers r TCP/UDP r IP.
FLAME: A Flow-level Anomaly Modeling Engine
Nick Duffield, Patrick Haffner, Balachander Krishnamurthy, Haakon Ringberg Rule-Based Anomaly Detection on IP Flows.
Snort: A Network Intrusion Detection Software Matt Gustafson Becky Smith CS691 Semester Project Spring 2003.
Student : Wilson Hidalgo Ramirez Supervisor: Udaya Tupakula Filtering Techniques for Counteracting DDoS Attacks.
 Firewalls and Application Level Gateways (ALGs)  Usually configured to protect from at least two types of attack ▪ Control sites which local users.
Intrusion Detection Systems and Practices
Internet Control Message Protocol (ICMP). Introduction The Internet Protocol (IP) is used for host-to-host datagram service in a system of interconnected.
Application Identification in information-poor environments Charalampos Rotsos 02/02/20101 What is application identification Current status My work Future.
1 Learning to Detect Objects in Images via a Sparse, Part-Based Representation S. Agarwal, A. Awan and D. Roth IEEE Transactions on Pattern Analysis and.
Wide-scale Botnet Detection and Characterization Anestis Karasaridis, Brian Rexroad, David Hoeflin.
Snort - an network intrusion prevention and detection system Student: Yue Jiang Professor: Dr. Bojan Cukic CS665 class presentation.
Martin Roesch Sourcefire Inc.
“On Scalable Attack Detection in the Network” Ramana Rao Kompella, Sumeet Singh, and George Varghese Presented by Nadine Sundquist.
ANOMALY DETECTION AND CHARACTERIZATION: LEARNING AND EXPERIANCE YAN CHEN – MATT MODAFF – AARON BEACH.
FIREWALLS & NETWORK SECURITY with Intrusion Detection and VPNs, 2 nd ed. 6 Packet Filtering By Whitman, Mattord, & Austin© 2008 Course Technology.
Chapter 9 Classification And Forwarding. Outline.
Testing Intrusion Detection Systems: A Critic for the 1998 and 1999 DARPA Intrusion Detection System Evaluations as Performed by Lincoln Laboratory By.
Gursharan Singh Tatla Transport Layer 16-May
Network-based and Attack-resilient Length Signature Generation for Zero-day Polymorphic Worms Zhichun Li 1, Lanjia Wang 2, Yan Chen 1 and Judy Fu 3 1 Lab.
Polytechnic University Introduction 1 Intrusion Detection Systems Examples of IDSs in real life r Car alarms r Fire detectors r House alarms r Surveillance.
4: Network Layer4a-1 IP datagram format ver length 32 bits data (variable length, typically a TCP or UDP segment) 16-bit identifier Internet checksum time.
Petrozavodsk State University, Alex Moschevikin, 2003NET TECHNOLOGIES Internet Control Message Protocol ICMP author -- J. Postel, September The purpose.
Packet Filtering. 2 Objectives Describe packets and packet filtering Explain the approaches to packet filtering Recommend specific filtering rules.
A Statistical Anomaly Detection Technique based on Three Different Network Features Yuji Waizumi Tohoku Univ.
Chapter 6: Packet Filtering
Network Flow-Based Anomaly Detection of DDoS Attacks Vassilis Chatzigiannakis National Technical University of Athens, Greece TNC.
COEN 252: Computer Forensics Network Analysis and Intrusion Detection with Snort.
Scalable and Efficient Data Streaming Algorithms for Detecting Common Content in Internet Traffic Minho Sung Networking & Telecommunications Group College.
CSCI 530 Lab Intrusion Detection Systems IDS. A collection of techniques and methodologies used to monitor suspicious activities both at the network and.
DoWitcher: Effective Worm Detection and Containment in the Internet Core S. Ranjan et. al in INFOCOM 2007 Presented by: Sailesh Kumar.
Vladimír Smotlacha CESNET Full Packet Monitoring Sensors: Hardware and Software Challenges.
Packet Filtering Chapter 4. Learning Objectives Understand packets and packet filtering Understand approaches to packet filtering Set specific filtering.
MonNet – a project for network and traffic monitoring Detection of malicious Traffic on Backbone Links via Packet Header Analysis Wolfgang John and Tomas.
© Jörg Liebeherr (modified by M. Veeraraghavan) 1 ICMP: A helper protocol to IP The Internet Control Message Protocol (ICMP) is the protocol used for error.
ACN: RED paper1 Random Early Detection Gateways for Congestion Avoidance Sally Floyd and Van Jacobson, IEEE Transactions on Networking, Vol.1, No. 4, (Aug.
Learning Rules for Anomaly Detection of Hostile Network Traffic Matthew V. Mahoney and Philip K. Chan Florida Institute of Technology.
MIS Week 4 Site:
Automatically Generating Models for Botnet Detection Presenter: 葉倚任 Authors: Peter Wurzinger, Leyla Bilge, Thorsten Holz, Jan Goebel, Christopher Kruegel,
Firewall Fingerprinting Amir R. Khakpour 1, Joshua W. Hulst 1, Zhihui Ge 2, Alex X. Liu 1, Dan Pei 2, Jia Wang 2 1 Michigan State University 2 AT&T Labs.
IEEE Communications Surveys & Tutorials 1st Quarter 2008.
Wide-scale Botnet Detection and Characterization Anestis Karasaridis, Brian Rexroad, David Hoeflin In First Workshop on Hot Topics in Understanding Botnets,
Scanning & Enumeration Lab 3 Once attacker knows who to attack, and knows some of what is there (e.g. DNS servers, mail servers, etc.) the next step is.
Open-Eye Georgios Androulidakis National Technical University of Athens.
COEN 252: Computer Forensics Network Analysis and Intrusion Detection with Snort.
Centre de Comunicacions Avançades de Banda Ampla (CCABA) Universitat Politècnica de Catalunya (UPC) Identification of Network Applications based on Machine.
Consensus Extraction from Heterogeneous Detectors to Improve Performance over Network Traffic Anomaly Detection Jing Gao 1, Wei Fan 2, Deepak Turaga 2,
Security System for KOREN/APII-Testbed
1 Figure 3-5: IP Packet Total Length (16 bits) Identification (16 bits) Header Checksum (16 bits) Time to Live (8 bits) Flags Protocol (8 bits) 1=ICMP,
Identifying “Best Bet” Web Search Results by Mining Past User Behavior Author: Eugene Agichtein, Zijian Zheng (Microsoft Research) Source: KDD2006 Reporter:
1 Transport Layer: Basics Outline Intro to transport UDP Congestion control basics.
Machine Learning for Network Anomaly Detection Matt Mahoney.
Network-based and Attack-resilient Length Signature Generation for Zero-day Polymorphic Worms Zhichun Li 1, Lanjia Wang 2, Yan Chen 1 and Judy Fu 3 1 Lab.
Network Anomaly Detection Using Autonomous System Flow Aggregates Thienne Johnson 1,2 and Loukas Lazos 1 1 Department of Electrical and Computer Engineering.
1 Minneapolis‘ IETF IPFIX Aggregation draft-dressler-ipfix-aggregation-00.txt.
Experience Report: System Log Analysis for Anomaly Detection
Snort – IDS / IPS.
Chapter 4 Network Layer Computer Networking: A Top Down Approach 6th edition Jim Kurose, Keith Ross Addison-Wesley March 2012 CPSC 335 Data Communication.
Damiano Bolzoni, Sandro Etalle, Pieter H. Hartel
DDoS Attack Detection under SDN Context
Session 20 INST 346 Technologies, Infrastructure and Architecture
Intrusion Detection Systems
32 bit destination IP address
Intrusion Detection Systems
Presentation transcript:

Rule-based Anomaly Detection on IP Flows Nick Duffield, Partick Haffner, Balachander Krishnamurthy (AT&T), Haakon Ringberg (Princeton Univ.) INFOCOM’09

Snort Snort is a powerful, flexible open source NIDS  Rule-based Anomaly Detection on Packets A Snort rule: alert udp $EXTERNAL_NET any -> $HOME_NET 1434 (msg:"MS-SQL version ove…"; dsize:>100; content:"|04|"; …) Rule actions protocol Source IP & port direction Destination IP & port Detail of rule Message text Packet size Patterns in packet’s payload 2009/4/9 Speaker: Li-Ming Chen

Challenge for deploying Snort over a Large Network (e. g Challenge for deploying Snort over a Large Network (e.g., a Tier-1 ISP) Deploy at the edge: Network scale is huge  Deployment issues Deploy at the core: Links capacity is high  Performance issues Hundreds of rules may need to be operated concurrently for each packet 2009/4/9 Speaker: Li-Ming Chen

Idea: Rules for IP Flows ! Does it possible to construct rules at the flow level that accurately reproduce the action of packet-level rules ? e.g., alerts should be raised for a flow, if some packets of this flow trigger packet-level rules Why? Easy to have IP flows ISPs already collect flow statistics ubiquitously (e.g., NetFlow) More scalable 2009/4/9 Speaker: Li-Ming Chen

Think about Rules for IP Flows… (1/2) If packet-level rule looks like: alert udp $EXTERNAL_NET any -> $HOME_NET 1434 (msg:"MS-SQL version ove…"; dsize:>100; content:"|04|"; …) In flow-level, maybe we can do: Alert UDP flows come from $EXTERNAL_NET to $HOME_NET at port 1434 with mean packet size larger than 100 Yes, we ignore the content !! Although we don’t know the exact packet size, we can measure mean packet size of each flow !? What’s the detection accuracy !? 2009/4/9 Speaker: Li-Ming Chen

Think about Rules for IP Flows… (2/2) What about packet-level rule is: alert icmp any any -> any any (msg:"ICMP Dest. Unreachable Comm. Administratively Prohibited"; icode:13; itype:3; …) In flow-level, what can do? ICMP destination unreachable is generated by the host or its inbound gateway to inform the client that the destination is unreachable for some reason e.g., every packet points to IP address A will trigger this event Can we LEARN this kind of events? 2009/4/9 Speaker: Li-Ming Chen

Motivation & Goal For NIDS, inspecting every packet would be ideal, but impractical Signature-based NIDS has scale and performance problems Goal: develop an architecture that can translate many existing packet signature to instead operate effectively on IP flows Premise: flow statistics are compact and collected within most ISPs’ network 2009/4/9 Speaker: Li-Ming Chen

Build Flow Rules via Learning Authors use machine learning (ML) approaches to learn the association between flow features and packet payload Problem: Flows: aggregate packet header information, while lose payload information  Flow rules: loss of accuracy !?  Does ML mitigate the impact of losing payload information !? 2009/4/9 Speaker: Li-Ming Chen

Outline Motivation & Goal Packet Rule Classification Packet Rules  Flow Rules Dataset & Evaluation Methodology Experimental Results Real Deployment Issues Conclusion & My Comments 2009/4/9 Speaker: Li-Ming Chen

Why to classify packet rules? Packet Rule Classification (1/3) Not all packet rules can be effectively learned… Using a taxonomy of packet rules to understand their impacts, and Evaluate the performance of proposed ML-method For example: ML-method can learn perfectly …? ML-method is likely to learn very well …? The accuracy of ML-method varies based on the nature of the rule…? 2009/4/9 Speaker: Li-Ming Chen

What kinds of predicates in a packet rule What kinds of predicates in a packet rule? Packet Rule Classification (2/3) 3 set of predicates consist a packet rule FH (flow header): packet fields exactly reported in the flow record PP (packet payload): content signature MI (meta information): other packet header information that is reported either inexactly or not at all in the flow record alert udp $EXTERNAL_NET any -> $HOME_NET 1434 (msg:"MS-SQL version ove…"; dsize:>100; content:"|04|"; …) (FH) (FH) (FH) (FH) (FH) (MI) (PP) 2009/4/9 Speaker: Li-Ming Chen

How to classify packet rules? Packet Rule Classification (3/3) Partition packet rules into disjoint classes Classify rules based on types of predicates present Other rules (no PP, do have MI, may include FH) Rules comprise only FH predicates rule Rules include at least one PP predicates 2009/4/9 Speaker: Li-Ming Chen

Outline Motivation & Goal Packet Rule Classification Packet Rules  Flow Rules Dataset & Evaluation Methodology Experimental Results Real Deployment Issues Conclusion & My Comments 2009/4/9 Speaker: Li-Ming Chen

Rules in Practice Snort rules: FH, MI & PP Snort rules: A Boolean formula composed of predicates that check for specific values of various fields present in the IP header, transport header, and payload Features used to construct flow rules in this paper: Src. port, Dst. port, Src. IP address, Dst. IP address, #packets, #bytes, mean packet size, duration, mean packet interarrival time, TCP flags, protocol, ToS. 2009/4/9 Speaker: Li-Ming Chen

Packet Rules  Flow Rules Packets … Snort Snort alerts e.g., NetFlow IP flows Build training data ML -method Flow rules (associate the packet alert with the corresponding flow) 2009/4/9 Speaker: Li-Ming Chen

Packet Rules  Flow Rules (detailed) For each Snort rule, training data  (xi, yi), flow i has flow features xi, and yi = {–1, 1} indicates where flow i triggered this snort rule. then we can run ML algo. by minimizing the classification error: Snort Snort alerts Assign each Snort rule a score Give each feature a weight. Learn these weights to minimize training error. Build training data (xi, yi) ML -method Flow rules 2009/4/9 Speaker: Li-Ming Chen

Learning Flow Rules Note that Machine learning algorithms A single packet may raise multiple Snort alerts  individual flows can be associated with many Snort alerts Machine learning algorithms Choose AdaBoost as the candidate algorithm Due to, actual number of features is large AdaBoost use incremental greedy training procedure to only adds features needed for finer discrimination Good generalization (than SVM) Low level of noise in the training data 2009/4/9 Speaker: Li-Ming Chen

Outline Motivation & Goal Packet Rule Classification Packet Rules  Flow Rules Dataset & Evaluation Methodology Experimental Results Real Deployment Issues Conclusion & My Comments 2009/4/9 Speaker: Li-Ming Chen

Dataset (during Aug ~ Sep 2005) OC-3 link 29 days (4 weeks) Total: >106 flows, >5 TBytes. Average rate: 2 MBytes/sec. Average: 14.5 pkt/flow. 55% of flows comprised 1 pkt ! For machine learning: Week 1: training Week 2: training & testing Week 3 & 4: testing border router (all) Packets unsampled NetFlow IP flows 2009/4/9 Speaker: Li-Ming Chen

Dataset (learning performance…!?) Number of flows (106) per week Normal flows: Anomalous flows: (Neg: True Negative, Pos: True Positive) Amount of unique examples is small ( speed up training) Further speedup: Remove deterministic features  reduce # of training data 1) remove flows whose source is part of local network 2) Snort rules only apply to a single protocol  train for specific protocol (TCP, UDP, ICMP) 2009/4/9 Speaker: Li-Ming Chen

Evaluation Criteria A detection is a boolean action (T or F ?) For each rule, we get a confidence score after testing by a classifier  require an threshold to determine T or F Use precision and recall as evaluation criteria Precision = TPk/(TPk + FPk) Average Precision =>  value closer to 1 is better ! 2009/4/9 Speaker: Li-Ming Chen

Evaluation Methodology Focus on 21 most triggered rules over wk 1 & 2 Refer to next slide! Compare the AP (Avg. Precisions) for: 1) Baseline behavior Training on one full week and testing on the subsequent week E.g., wk1-2  training on wk 1 and testing on wk 2. 2) Data drift Determine how often re-training should be applied (e.g., wk1-3) 3) Sampling of negative example Normal flows are the majority Reduce normal flows keep accuracy while reduce training time !? 2009/4/9 Speaker: Li-Ming Chen

See alert details (Snort alerts) Show the complexity of a unique flow 1 3 4 9 10 15 20 ICMP content? flag size flag See alert details 2009/4/9 Speaker: Li-Ming Chen

 Payload rules show great variability Header 1 3 4 9 10 15 20 Data Draft: 2-week drift is acceptable 3-week drift  loss of performance especially for Meta-Info & Payload Meta-Info Payload  Payload rules show great variability 2009/4/9 Speaker: Li-Ming Chen

Sampling of Negative (normal) Example: measurable loss in performance Header Sampling of Negative (normal) Example: measurable loss in performance while 6x faster in training 1 3 4 9 10 15 20 Meta-Info Payload 2009/4/9 Speaker: Li-Ming Chen

What features are more important than others? Feature is removed during detection Payload rules are hard to reproduced in a flow setting. some rules have several predicates (that could be learned) 2009/4/9 Speaker: Li-Ming Chen

Outline Motivation & Goal Packet Rule Classification Packet Rules  Flow Rules Dataset & Evaluation Methodology Experimental Results Real Deployment Issues Conclusion & My Comments 2009/4/9 Speaker: Li-Ming Chen

Architecture Other issues: Can rules learned from a site be used for other sites? Some flow features (e.g., duration) are link/network dependent… 2009/4/9 Speaker: Li-Ming Chen

Other issues Computational efficiency Initial correlation of Flows and Snort Alarms AdaBoost parameter setup, and learning time Run-time classification 2009/4/9 Speaker: Li-Ming Chen

Conclusion 2009/4/9 Speaker: Li-Ming Chen

My Comments 2009/4/9 Speaker: Li-Ming Chen

Appendix – 21 Snort Rules used in this paper Back to evaluation Appendix – 21 Snort Rules used in this paper From snort-rules-version

Header (1/2) Back to evaluation 1) alert icmp any any -> any any (msg:"ICMP Destination Unreachable Communication Administratively Prohibited"; icode:13; itype:3; classtype:misc-activity; sid:485; rev:4;) 2) alert icmp any any -> any any (msg:"ICMP Destination Unreachable Communication with Destination Host is Administratively Prohibited"; icode:10; itype:3; classtype:misc-activity; sid:486; rev:4;) 2009/4/9 Speaker: Li-Ming Chen

Header (2/2) 3) alert icmp $EXTERNAL_NET any -> $HOME_NET any (msg:"ICMP Source Quench"; icode:0; itype:4; classtype:bad-unknown; sid:477; rev:2;) 2009/4/9 Speaker: Li-Ming Chen

Meta-Information (1/3) 4) alert icmp $EXTERNAL_NET any -> $HOME_NET any (msg:"ICMP webtrends scanner"; icode:0; itype:8; content:"|00 00 00 00|EEEEEEEEEEEE"; reference:arachnids,307; classtype:attempted-recon; sid:476; rev:4;) 5) alert tcp $EXTERNAL_NET any -> $HOME_NET any (msg:"BAD-TRAFFIC data in TCP SYN packet"; flow:stateless; dsize:>6; flags:S,12; reference:url,www.cert.org/incident_notes/IN-99-07.html; classtype:misc-activity; sid:526; rev:11;) 2009/4/9 Speaker: Li-Ming Chen

Meta-Information (2/3) 6) alert icmp $EXTERNAL_NET any -> $HOME_NET any (msg:"ICMP Large ICMP Packet"; dsize:>800; reference:arachnids,246; classtype:bad-unknown; sid:499; rev:4;) 7) alert icmp $EXTERNAL_NET any -> $HOME_NET any (msg:"ICMP PING NMAP"; dsize:0; itype:8; reference:arachnids,162; classtype:attempted-recon; sid:469; rev:3;) 2009/4/9 Speaker: Li-Ming Chen

Meta-Information (3/3) 8) alert tcp $EXTERNAL_NET any -> $HOME_NET any (msg:"SCAN FIN"; flow:stateless; flags:F,12; reference:arachnids,27; classtype:attempted-recon; sid:621; rev:7;) 9) 111 || 8 || spp_stream4: FIN Stealth Scan gid: 111  Snort Pre-processor, 4th stream pre-processor alert id: 8 2009/4/9 Speaker: Li-Ming Chen

Payload (1/6) 10) alert udp $EXTERNAL_NET any -> $HOME_NET 1434 (msg:"MS-SQL version overflow attempt"; flowbits:isnotset,ms_sql_seen_dns; dsize:>100; content:"|04|"; depth:1; reference:bugtraq,5310; reference:cve,2002-0649; reference:nessus,10674; classtype:misc-activity; sid:2050; rev:8;) 11) alert tcp $AIM_SERVERS any -> $HOME_NET any (msg:"CHAT AIM receive message"; flow:to_client; content:"*|02|"; depth:2; content:"|00 04 00 07|"; depth:4; offset:6; classtype:policy-violation; sid:1633; rev:6;) 2009/4/9 Speaker: Li-Ming Chen

Payload (2/6) 12) 2376 || EXPLOIT ISAKMP first payload certificate request length overflow attempt || bugtraq,9582 || cve,2004-0040 13) 483 || ICMP PING CyberKit 2.2 Windows || arachnids,154 14) 480 || ICMP PING speedera 2009/4/9 Speaker: Li-Ming Chen

Payload (3/6) 2009/4/9 Speaker: Li-Ming Chen

Payload (4/6) 2009/4/9 Speaker: Li-Ming Chen

Payload (5/6) 2009/4/9 Speaker: Li-Ming Chen

Payload (6/6) 2009/4/9 Speaker: Li-Ming Chen