Security Part One: Attacks and Countermeasures Dejian Ye, Liu Xin 15-411: F08 security1.

Slides:



Advertisements
Similar presentations
Network and Application Attacks Contributed by- Chandra Prakash Suryawanshi CISSP, CEH, SANS-GSEC, CISA, ISO 27001LI, BS 25999LA, ERM (ISB) June 2006.
Advertisements

Lecture slides for “Computer Security: Principles and Practice”, 2/e, by William Stallings and Lawrie Brown, Chapter 9 “Firewalls and Intrusion Prevention.
Firewalls By Tahaei Fall What is a firewall? a choke point of control and monitoring interconnects networks with differing trust imposes restrictions.
Computer Security: Principles and Practice Chapter 9 – Firewalls and Intrusion Prevention Systems.
IUT– Network Security Course 1 Network Security Firewalls.
FIREWALLS Chapter 11.
Security Part Two: Attacks and Countermeasures. Flashback: Internet design goals 1.Interconnection 2.Failure resilience 3.Multiple types of service 4.Variety.
IP Spoofing Defense On the State of IP Spoofing Defense TOBY EHRENKRANZ and JUN LI University of Oregon 1 IP Spoofing Defense.
Intrusion Detection and Hackers Exploits IP Spoofing Attack Yousef Yahya & Ahmed Alkhamaisa Prepared for Arab Academy for Banking and Financial Sciences.
Computer Security Fundamentals by Chuck Easttom Chapter 4 Denial of Service Attacks.
Firewalls and Intrusion Detection Systems
Security With slides from: Debabrata Dash, Nick Feamster, Vyas Sekar, and others.
Intrusion Detection Systems and Practices
5/1/2006Sireesha/IDS1 Intrusion Detection Systems (A preliminary study) Sireesha Dasaraju CS526 - Advanced Internet Systems UCCS.
Security Awareness: Applying Practical Security in Your World
Beyond the perimeter: the need for early detection of Denial of Service Attacks John Haggerty,Qi Shi,Madjid Merabti Presented by Abhijit Pandey.
© 2006 Cisco Systems, Inc. All rights reserved. Implementing Secure Converged Wide Area Networks (ISCW) Module 6: Cisco IOS Threat Defense Features.
Security Part One: Network Attacks and Countermeasures Xin Zhang.
FIREWALLS & NETWORK SECURITY with Intrusion Detection and VPNs, 2 nd ed. 6 Packet Filtering By Whitman, Mattord, & Austin© 2008 Course Technology.
Introduction to Network Security
1 Lecture 20: Firewalls motivation ingredients –packet filters –application gateways –bastion hosts and DMZ example firewall design using firewalls – virtual.
FIREWALL TECHNOLOGIES Tahani al jehani. Firewall benefits  A firewall functions as a choke point – all traffic in and out must pass through this single.
Common forms and remedies Neeta Bhadane Raunaq Nilekani Sahasranshu.
Firewalls CS432. Overview  What are firewalls?  Types of firewalls Packet filtering firewalls Packet filtering firewalls Sateful firewalls Sateful firewalls.
BY- NIKHIL TRIPATHI 12MCMB10.  What is a FIREWALL?  Can & Can’t in Firewall perspective  Development of Firewalls  Firewall Architectures  Some Generalization.
Hafez Barghouthi. Model for Network Access Security (our concern) Patrick BoursAuthentication Course 2007/20082.
Intrusion Detection Systems Present by Ali Fanian In the Name of Allah.
CS426Fall 2010/Lecture 361 Computer Security CS 426 Lecture 36 Perimeter Defense and Firewalls.
1 Intrusion Detection Systems. 2 Intrusion Detection Intrusion is any use or attempted use of a system that exceeds authentication limits Intrusions are.
Packet Filtering. 2 Objectives Describe packets and packet filtering Explain the approaches to packet filtering Recommend specific filtering rules.
Why do we need Firewalls? Internet connectivity is a must for most people and organizations  especially for me But a convenient Internet connectivity.
TCP/IP Vulnerabilities. Outline Security Vulnerabilities Denial of Service Worms Countermeasures: Firewalls/IDS.
Chapter 6: Packet Filtering
Network security Further protocols and issues. Protocols: recap There are a few main protocols that govern the internet: – Internet Protocol: IP – Transmission.
By Anonymous Student. Outline  Security vulnerabilities  Denial-of-Service (DoS) and Distributed-Denial-of- Service (D-DoS)  Firewalls  Intrusion.
CS 640: Introduction to Computer Networks Aditya Akella Lecture 25 – Network Security.
OV Copyright © 2013 Logical Operations, Inc. All rights reserved. Network Security  Network Perimeter Security  Intrusion Detection and Prevention.
Principles of Computer Security: CompTIA Security + ® and Beyond, Third Edition © 2012 Principles of Computer Security: CompTIA Security+ ® and Beyond,
11 SECURING YOUR NETWORK PERIMETER Chapter 10. Chapter 10: SECURING YOUR NETWORK PERIMETER2 CHAPTER OBJECTIVES  Establish secure topologies.  Secure.
OV Copyright © 2011 Element K Content LLC. All rights reserved. Network Security  Network Perimeter Security  Intrusion Detection and Prevention.
Firewalls Nathan Long Computer Science 481. What is a firewall? A firewall is a system or group of systems that enforces an access control policy between.
1 CHAPTER 3 CLASSES OF ATTACK. 2 Denial of Service (DoS) Takes place when availability to resource is intentionally blocked or degraded Takes place when.
Packet Filtering Chapter 4. Learning Objectives Understand packets and packet filtering Understand approaches to packet filtering Set specific filtering.
IEEE Communications Surveys & Tutorials 1st Quarter 2008.
1 Topic 2: Lesson 3 Intro to Firewalls Summary. 2 Basic questions What is a firewall? What is a firewall? What can a firewall do? What can a firewall.
(c) University of Technology, Sydney Firewall Architectures.
Security fundamentals Topic 10 Securing the network perimeter.
TCP Security Vulnerabilities Phil Cayton CSE
Attacking on IPv6 W.lilakiatsakun Ref: ipv6-attack-defense-33904http://
DoS/DDoS attack and defense
An Analysis of Using Reflectors for Distributed Denial-of- Service Attacks Paper by Vern Paxson.
Denial of Service A comparison of DoS schemes Kevin LaMantia COSC 316.
IPv6 Security Issues Georgios Koutepas, NTUA IPv6 Technology and Advanced Services Oct.19, 2004.
Firewalls. Overview of Firewalls As the name implies, a firewall acts to provide secured access between two networks A firewall may be implemented as.
Presentation on ip spoofing BY
25/09/ Firewall, IDS & IPS basics. Summary Firewalls Intrusion detection system Intrusion prevention system.
Polytechnic University Firewall and Trusted Systems Presented by, Lekshmi. V. S cos
1 Lecture A.2: Security Problems in TCP/IP r Reference: Security Problems in the TCP/IP Protocol Suite : by Steve Bellovin r R-services r Source-routing.
Security fundamentals
Introduction to Network Security
Firewall – Survey Purpose of a Firewall Characteristic of a firewall
Firewalls.
Networked Systems Practicum
Firewalls Purpose of a Firewall Characteristic of a firewall
POOJA Programmer, CSE Department
دیواره ی آتش.
Firewalls.
Intrusion Detection and Hackers Exploits IP Spoofing Attack
Presentation transcript:

Security Part One: Attacks and Countermeasures Dejian Ye, Liu Xin : F08 security1

Flashback.. Internet design goals 1.Interconnection 2.Failure resilience 3.Multiple types of service 4.Variety of networks 5.Management of resources 6.Cost-effective 7.Low entry-cost 8.Accountability for resources Where is security? : F08 security2

Why did they leave it out? Designed for connectivity Network designed with implicit trust  No “bad” guys Can’t security be provided at the edge?  Encryption, Authentication etc  End-to-end arguments in system design : F08 security3

Security Vulnerabilities At every layer in the protocol stack! Network-layer attacks  IP-level vulnerabilities  Routing attacks Transport-layer attacks  TCP vulnerabilities Application-layer attacks : F08 security4

IP-level vulnerabilities IP addresses are provided by the source  Spoofing attacks Using IP address for authentication  e.g., login with.rhosts Some “features” that have been exploited  Fragmentation  Broadcast for traffic amplification : F08 security5

Security Flaws in IP The IP addresses are filled in by the originating host  Address spoofing Using source address for authentication  r-utilities (rlogin, rsh, rhosts etc..) Internet C A B S Can A claim it is B to the server S? ARP Spoofing Can C claim it is B to the server S? Source Routing : F08 security6

Smurf Attack Attacking System Internet Broadcast Enabled Network Victim System : F08 security7

ICMP Attacks No authentication ICMP redirect message  Can cause the host to switch gateways  Benefit of doing this?  Man in the middle attack, sniffing ICMP destination unreachable  Can cause the host to drop connection ICMP echo request/reply Many more…  : F08 security8

Routing attacks Divert traffic to malicious nodes  Black-hole  Eavesdropping How to implement routing attacks?  Distance-Vector:  Link-state: BGP vulnerabilities : F08 security9

Routing attacks Divert traffic to malicious nodes  Black-hole  Eavesdropping How to implement routing attacks?  Distance-Vector: Announce low-cost routes  Link-state: Dropping links from topology BGP vulnerabilities  Prefix-hijacking  Path alteration : F08 security10

TCP-level attacks SYN-Floods  Implementations create state at servers before connection is fully established Session hijack  Pretend to be a trusted host  Sequence number guessing Session resets  Close a legitimate connection : F08 security11

Session Hijack Trusted (T) Malicious (M) Server 1.SYN (ISN_X) SRC = X 2.SYN(ISN_S1), ACK(ISN_X) First send a legitimate SYN to server : F08 security12

Session Hijack Trusted (T) Malicious (M) Server 1.SYN (ISN_X) SRC = T 2.SYN(ISN_S2), ACK(ISN_X) 3.ACK(ISN_S2) SRC = T Using ISN_S1 from earlier connection guess ISN_S2! : F08 security13

TCP Layer Attacks TCP SYN Flooding  Exploit state allocated at server after initial SYN packet  Send a SYN and don’t reply with ACK  Server will wait for 511 seconds for ACK  Finite queue size for incomplete connections (1024)  Once the queue is full it doesn’t accept requests : F08 security14

TCP Layer Attacks TCP Session Poisoning  Send RST packet  Will tear down connection  Do you have to guess the exact sequence number?  Anywhere in window is fine  For 64k window it takes 64k packets to reset  About 15 seconds for a T : F08 security15

An Example Shimomura (S) Trusted (T) Mitnick Finger showmount –e Send 20 SYN packets to S Attack when no one is around What other systems it trusts? Determine ISN behavior Showmount -e SYN : F08 security16

Shimomura (S) Trusted (T) Mitnick An Example showmount –e Send 20 SYN packets to S SYN flood T Attack when no one is around What other systems it trusts? Determine ISN behavior T won’t respond to packets Syn flood X : F08 security17

Shimomura (S) Trusted (T) Mitnick An Example showmount –e Send 20 SYN packets to S SYN flood T Send SYN to S spoofing as T Send ACK to S with a guessed number Attack when no one is around What other systems it trusts? Determine ISN behavior T won’t respond to packets S assumes that it has a session with T X SYN SYN|ACK ACK : F08 security18

Shimomura (S) Trusted (T) Mitnick An Example showmount –e Send 20 SYN packets to S SYN flood T Send SYN to S spoofing as T Send ACK to S with a guessed number Send “echo + + > ~/.rhosts” Attack when no one is around What other systems it trusts? Determine ISN behavior T won’t respond to packets S assumes that it has a session with T Give permission to anyone from anywhere X ++ > rhosts : F08 security19

Where do the problems come from? Protocol-level vulnerabilities  Implicit trust assumptions in design Implementation vulnerabilities  Both on routers and end-hosts Incomplete specifications  Often left to the imagination of programmers : F08 security20

Outline Security Vulnerabilities Denial of Service Worms Countermeasures: Firewalls/IDS : F08 security21

Denial of Service Make a service unusable/unavailable Disrupt service by taking down hosts  E.g., ping-of-death Consume host-level resources  E.g., SYN-floods Consume network resources  E.g., UDP/ICMP floods : F08 security22

Simple DoS AttackerVictim Attacker usually spoofs source address to hide origin Aside: Backscatter Analysis When attack traffic results in replies from the victim E.g. TCP SYN, ICMP ECHO Lots of traffic : F08 security23

Backscatter Analysis Attacker sends spoofed TCP SYN packets to  With spoofed addresses chosen at random My network sees TCP SYN-ACKs from at rate R What is the rate of the attack?  Assuming addresses chosen are uniform  (2^32/ Network Address space) * R : F08 security24

Reflector Attack Attacker Agent Reflector Victim Src = Victim Destination = Reflector Src = Reflector Destination = Victim Unsolicited traffic at victim from legitimate hosts : F08 security25

Distributed DoS Attacker Handler Agent Victim : F08 security26

Distributed DoS Handlers are usually high volume servers  Easy to hide the attack packets Agents are usually home users with DSL/Cable  Already infected and the agent installed Very difficult to track down the attacker  Multiple levels of indirection! Aside: How to distinguish DDos from flash crowd? : F08 security27

Outline Security, Vulnerabilities Denial of Service Worms Countermeasures: Firewalls/IDS : F08 security28

Worm Overview Self-propagate through network Typical Steps in worm propagation  Probe host for vulnerable software  Exploit the vulnerability (e.g., buffer overflow)  Attacker gains privileges of the vulnerable program  Launch copy on compromised host Spread at exponential rate  10M hosts in < 5 minutes  Hard to deal with manual intervention : F08 security29

Scanning Techniques Random Local subnet Routing Worm Hitlist Topological : F08 security30

Random Scanning 32-bit randomly generated IP address  E.g., Slammer and Code Red I  What about IPv6? Hits black-holed IP space frequently  Only 28.6% of IP space is allocated  Detect worms by monitoring unused addresses  Honeypots/Honeynet : F08 security31

Subnet Scanning Generate last 1, 2, or 3 bytes of IP address randomly Code Red II and Blaster Some scans must be completely random to infect whole internet : F08 security32

Routing Worm BGP information can tell which IP address blocks are allocated This information is publicly available   : F08 security33

Hit List List of vulnerable hosts sent with payload  Determined before worm launch by scanning Boosts worm growth in the slow start phase Can evade common detection techniques : F08 security34

Topological Uses info on the infected host to find the next target  Morris Worm used /etc/hosts,.rhosts  address books  P2P software usually store info about peers that each host connects to : F08 security35

Some proposals for countermeasures Better software safeguards  Static analysis and array bounds checking (lint/e-fence)  Safe versions of library calls  gets(buf) -> fgets(buf, size,...)  sprintf(buf,...) -> snprintf(buf, size,...) Host-diversity  Avoid same exploit on multiple machines Network-level: IP address space randomization Host-level solutions  E.g., Memory randomization, Stack guard Rate-limiting: Contain the rate of spread Content-based filtering: signatures in packet payloads : F08 security36

Outline Security, Vulnerabilities Denial of Service Worms Countermeasures: Firewalls/IDS : F08 security37

Countermeasure Overview High level basic approaches  Prevention  Detection  Resilience Requirements  Security: soundness / completeness (false positive / negative  Overhead  Usability : F08 security38

Design questions.. Why is it so easy to send unwanted traffic?  Worm, DDoS, virus, spam, phishing etc Where to place functionality for stopping unwanted traffic?  Edge vs. Core  Routers vs. Middleboxes Redesign Internet architecture to detect and prevent unwanted traffic? : F08 security39

Firewalls Block/filter/modify traffic at network-level  Limit access to the network  Installed at perimeter of the network Why network-level?  Vulnerabilities on many hosts in network  Users don’t keep systems up to date  Lots of patches to keep track of  Zero-day exploits : F08 security40

Firewalls (contd…) Firewall inspects traffic through it Allows traffic specified in the policy Drops everything else Two Types  Packet Filters, Proxies Internet Internal Network Firewall : F08 security41

Packet Filters Selectively passes packets from one network interface to another Usually done within a router between external and internal network What/How to filter?  Packet Header Fields  IP source and destination addresses  Application port numbers  ICMP message types/ Protocol options etc.  Packet contents (payloads) : F08 security42

Packet Filters: Possible Actions Allow the packet to go through Drop the packet (Notify Sender/Drop Silently) Alter the packet (NAT?) Log information about the packet : F08 security43

Some examples Block all packets from outside except for SMTP servers Block all traffic to/from a list of domains Ingress filtering  Drop pkt from outside with addresses inside the network Egress filtering  Drop pkt from inside with addresses outside the network : F08 security44

Typical Firewall Configuration Internal hosts can access DMZ and Internet External hosts can access DMZ only, not Intranet DMZ hosts can access Internet only Advantages? If a service gets compromised in DMZ it cannot affect internal hosts Internet Intranet DMZ X X : F08 security45

Firewall implementation Stateless packet filtering firewall Rule  (Condition, Action) Rules are processed in top-down order  If a condition satisfied – action is taken : F08 security46

Sample Firewall Rule Dst Port Alow Allow Yes Any > TCP22 TCP> 1023 ExtIntOutSSH-2 IntExtInSSH-1 Dst Addr Proto Ack Set? Action Src Port Src Addr DirRule Allow SSH from external hosts to internal hosts Two rules Inbound and outbound How to know a packet is for SSH? Inbound: src-port>1023, dst-port=22 Outbound: src-port=22, dst-port>1023 Protocol=TCP Ack Set? Problems? SYN SYN/ACK ACK ClientServer : F08 security47

Default Firewall Rules Egress Filtering  Outbound traffic from external address  Drop  Benefits? Ingress Filtering  Inbound Traffic from internal address  Drop  Benefits? Default Deny  Why? Any Dst Port AnyDenyAny IntAnyIntInIngress DenyAny ExtAnyExtOutEgress AnyDenyAny Default Dst Addr Proto Ack Set? Action Src Port Src Addr DirRule : F08 security48

Packet Filters Advantages  Transparent to application/user  Simple packet filters can be efficient Disadvantages  Usually fail open  Very hard to configure the rules  May only have coarse-grained information?  Does port 22 always mean SSH?  Who is the user accessing the SSH? : F08 security49

Alternatives Stateful packet filters  Keep the connection states  Easier to specify rules  Problems?  State explosion  State for UDP/ICMP? Proxy Firewalls  Two connections instead of one  Either at transport level  SOCKS proxy  Or at application level  HTTP proxy : F08 security50

Proxy Firewall Data Available  Application level information  User information Advantages?  Better policy enforcement  Better logging  Fail closed Disadvantages?  Doesn’t perform as well  One proxy for each application  Client modification : F08 security51

Intrusion Detection Systems Firewalls allow traffic only to legitimate hosts and services Traffic to the legitimate hosts/services can have attacks Solution?  Intrusion Detection Systems  Monitor data and behavior  Report when identify attacks : F08 security52

Classes of IDS What type of analysis?  Signature-based  Anomaly-based Where is it operating?  Network-based  Host-based : F08 security53

Signature-based IDS Characteristics  Uses known pattern matching to signify attack Advantages?  Widely available  Fairly fast  Easy to implement  Easy to update Disadvantages?  Cannot detect attacks for which it has no signature : F08 security54

Anomaly-based IDS Characteristics  Uses statistical model or machine learning engine to characterize normal usage behaviors  Recognizes departures from normal as potential intrusions Advantages?  Can detect attempts to exploit new and unforeseen vulnerabilities  Can recognize authorized usage that falls outside the normal pattern Disadvantages?  Generally slower, more resource intensive compared to signature-based IDS  Greater complexity, difficult to configure  Higher percentages of false alerts : F08 security55

Network-based IDS Characteristics  NIDS examine raw packets in the network passively and triggers alerts Advantages?  Easy deployment  Unobtrusive  Difficult to evade if done at low level of network operation Disadvantages?  Fail Open  Different hosts process packets differently  NIDS needs to create traffic seen at the end host  Need to have the complete network topology and complete host behavior : F08 security56

Host-based IDS Characteristics  Runs on single host  Can analyze audit-trails, logs, integrity of files and directories, etc. Advantages  More accurate than NIDS  Less volume of traffic so less overhead Disadvantages  Deployment is expensive  What happens when host get compromised? : F08 security57

Summary Security vulnerabilities are real!  Protocol or implementation or bad specs  Poor programming practices  At all layers in protocol stack DoS/DDoS  Resource utilization attacks Worm/Malware  Exploit vulnerable services  Exponential spread Countermeasures: Firewall/IDS : F08 security58