K. Salah1 Firewalls. 2 Firewalls Trusted hosts and networks Firewall Router Intranet DMZ Demilitarized Zone: publicly accessible servers and networks.

Slides:



Advertisements
Similar presentations
Computer Science CSC 474Dr. Peng Ning1 CSC 474 Information Systems Security Topic 4.1 Firewalls.
Advertisements

IUT– Network Security Course 1 Network Security Firewalls.
FIREWALLS Chapter 11.
1 Topic 2 – Lesson 4 Packet Filtering Part I. 2 Basic Questions What is packet filtering? What is packet filtering? What elements are inside an IP header?
FIREWALLS. What is a Firewall? A firewall is hardware or software (or a combination of hardware and software) that monitors the transmission of packets.
FIREWALLS The function of a strong position is to make the forces holding it practically unassailable —On War, Carl Von Clausewitz On the day that you.
Firewalls.
CSCI 530 Lab Firewalls. Overview Firewalls Capabilities Limitations What are we limiting with a firewall? General Network Security Strategies Packet Filtering.
Access Control for Networks Problems: –Enforce an access control policy Allow trust relationships among machines –Protect local internet from outsiders.
Security Presented by : Qing Ma. Introduction Security overview security threats password security, encryption and network security as specific.
Firewalls and Intrusion Detection Systems
J. Wang. Computer Network Security Theory and Practice. Springer 2008 Chapter 7 Network Perimeter Security.
5/4/01EMTM 5531 EMTM 553: E-commerce Systems Lecture 7b: Firewalls Insup Lee Department of Computer and Information Science University of Pennsylvania.
Firewalls Screen packets coming into the Privet Networks from external, Untrusted Networks (Internet) Ingress Packet Filtering  Firewall examine incoming.
Firewalls K. Salah.
FIREWALLS & NETWORK SECURITY with Intrusion Detection and VPNs, 2 nd ed. 6 Packet Filtering By Whitman, Mattord, & Austin© 2008 Course Technology.
1 Lecture 20: Firewalls motivation ingredients –packet filters –application gateways –bastion hosts and DMZ example firewall design using firewalls – virtual.
Firewalls: General Principles & Configuration (in Linux)
FIREWALL TECHNOLOGIES Tahani al jehani. Firewall benefits  A firewall functions as a choke point – all traffic in and out must pass through this single.
Firewalls CS432. Overview  What are firewalls?  Types of firewalls Packet filtering firewalls Packet filtering firewalls Sateful firewalls Sateful firewalls.
CS426Fall 2010/Lecture 361 Computer Security CS 426 Lecture 36 Perimeter Defense and Firewalls.
1 Figure 5-4: Drivers of Performance Requirements: Traffic Volume and Complexity of Filtering Performance Requirements Traffic Volume (Packets per Second)
Packet Filtering. 2 Objectives Describe packets and packet filtering Explain the approaches to packet filtering Recommend specific filtering rules.
Chapter 5 Copyright Prentice-Hall 2003
Why do we need Firewalls? Internet connectivity is a must for most people and organizations  especially for me But a convenient Internet connectivity.
FIREWALL Mạng máy tính nâng cao-V1.
January 2009Prof. Reuven Aviv: Firewalls1 Firewalls.
Chapter 6: Packet Filtering
Chapter 11 Firewalls.
Firewalls, etc.. Network Security2 Outline Intro Various firewall technologies: –Static Packet Filtering (or nonstateful packet filter) –Dynamic Packet.
FIREWALLS Vivek Srinivasan. Contents Introduction Need for firewalls Different types of firewalls Conclusion.
Defense Techniques Sepehr Sadra Tehran Co. Ltd. Ali Shayan November 2008.
11 SECURING YOUR NETWORK PERIMETER Chapter 10. Chapter 10: SECURING YOUR NETWORK PERIMETER2 CHAPTER OBJECTIVES  Establish secure topologies.  Secure.
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.
Packet Filtering Chapter 4. Learning Objectives Understand packets and packet filtering Understand approaches to packet filtering Set specific filtering.
Access Control List (ACL)
1 Firewalls G53ACC Chris Greenhalgh. 2 Contents l Attacks l Principles l Simple filters l Full firewall l Books: Comer ch
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.
 network appliances to filter network traffic  filter on header (largely based on layers 3-5) Internet Intranet.
Network Security. 2 SECURITY REQUIREMENTS Privacy (Confidentiality) Data only be accessible by authorized parties Authenticity A host or service be able.
© 2006 Cisco Systems, Inc. All rights reserved. Cisco IOS Threat Defense Features.
1 Firewalls Types of Firewalls Inspection Methods  Static Packet Inspection  Stateful Packet Inspection  NAT  Application Firewalls Firewall Architecture.
Karlstad University Firewall Ge Zhang. Karlstad University A typical network topology Threats example –Back door –Port scanning –…–…
Security fundamentals Topic 10 Securing the network perimeter.
Chapter 8 Network Security Thanks and enjoy! JFK/KWR All material copyright J.F Kurose and K.W. Ross, All Rights Reserved Computer Networking:
1 An Introduction to Internet Firewalls Dr. Rocky K. C. Chang 12 April 2007.
Access Control List (ACL) W.lilakiatsakun. Transport Layer Review (1) TCP (Transmission Control Protocol) – HTTP (Web) – SMTP (Mail) UDP (User Datagram.
SYSTEM ADMINISTRATION Chapter 10 Public vs. Private Networks.
1 CNLab/University of Ulsan Chapter 19 Firewalls  Packet Filtering Firewall  Application Gateway Firewall  Firewall Architecture.
Firewalls. Overview of Firewalls As the name implies, a firewall acts to provide secured access between two networks A firewall may be implemented as.
Chapter 8.  Upon completion of this chapter, you should be able to:  Understand the purpose of a firewall  Name two types of firewalls  Identify common.
Polytechnic University Firewall and Trusted Systems Presented by, Lekshmi. V. S cos
Defining Network Infrastructure and Network Security Lesson 8.
Security fundamentals
Firewalls.
Firewall – Survey Purpose of a Firewall Characteristic of a firewall
Introduction to Networking
Firewalls.
Firewalls Chapter 5 Revised March 2004 Panko, Corporate Computer and Network Security Copyright 2004 Prentice-Hall.
Firewalls (March 2, 2016) © Abdou Illia – Spring 2016.
Firewalls Routers, Switches, Hubs VPNs
POOJA Programmer, CSE Department
Firewalls By conventional definition, a firewall is a partition made
دیواره ی آتش.
Firewalls.
Firewalls Chapter 8.
Session 20 INST 346 Technologies, Infrastructure and Architecture
CSCD 434 Spring 2019 Lecture 16 Firewalls.
Presentation transcript:

K. Salah1 Firewalls

2 Firewalls Trusted hosts and networks Firewall Router Intranet DMZ Demilitarized Zone: publicly accessible servers and networks DMZ never initiates traffic to inside or outside – holds harmless equipment. Idea: separate local network from the Internet Idea: separate local network from the Internet

K. Salah3 Castle and Moat Analogy More like the moat around a castle than a firewall More like the moat around a castle than a firewall  Restricts access from the outside  Restricts outbound connections, too (!!) Important: filter out undesirable activity from internal hosts!

K. Salah4 Firewall Locations in the Network Between internal LAN and external network Between internal LAN and external network At the gateways of sensitive subnetworks within the organizational LAN At the gateways of sensitive subnetworks within the organizational LAN  Payroll’s network must be protected separately within the corporate network On end-user machines On end-user machines  “Personal firewall”  Microsoft’s Internet Connection Firewall (ICF) comes standard with Windows XP

K. Salah5 Packet Filtering For each packet, firewall decides whether to allow it to proceed For each packet, firewall decides whether to allow it to proceed  Decision must be made on per-packet basis Stateless; cannot examine packet’s context (TCP connection, application to which it belongs, etc.) To decide, use information available in the packet To decide, use information available in the packet  IP source and destination addresses, ports  Protocol identifier (TCP, UDP, ICMP, etc.)  TCP flags (SYN, ACK, RST, PSH, FIN)  ICMP message type Filtering rules are based on pattern-matching Filtering rules are based on pattern-matching Filtering is performed sequentially (in order from first to last) according to the Rulebase (or ACL). Filtering is performed sequentially (in order from first to last) according to the Rulebase (or ACL).  Go for the first hit, not the best hit Rule form: (Condition-matching) + (action) Rule form: (Condition-matching) + (action)

K. Salah6 ACL for Ingress Filtering 1. If source IP address = 10.*.*.*, DENY [private IP address range] 2. If source IP address = *.* to *.*, DENY [private IP address range] 3. If source IP address = *.*, DENY [private IP address range] 4. If source IP address = , DENY [invalid IP address range] 5. If source IP address = *.*, DENY [invalid IP address range] 6. If source IP address = *.*, DENY [internal address range] 7. If source IP address = , DENY [black-holed address of attacker, act as a black hole.] 8. If TCP SYN=1 AND FIN=1, DENY [crafted attack packet] 9. If destination IP address = AND TCP destination port=80 OR 443, PASS [connection to a public webserver] 10. If TCP SYN=1 AND ACK=0, DENY [attempt to open a connection from the outside] 11. If TCP destination port = 20, DENY [FTP data connection] 12. If TCP destination port = 21, DENY [FTP supervisory control connection] 13. If TCP destination port = 23, DENY [Telnet data connection] 14. If TCP destination port = 135 through 139, DENY [NetBIOS connection for clients, and RPC port in Windoz] 15. If TCP destination port = 513, DENY [UNIX rlogin without password] 16. If TCP destination port = 514, DENY [UNIX rsh launch shell without login] 17. If TCP destination port = 22, DENY [SSH for secure login, but some versions are insecure] 18. If UDP destination port=69, DENY [Trivial File Transfer Protocol; no login necessary] 19. If ICMP Type = 0, PASS [allow incoming echo reply messages] 20. DENY ALL Courtesy of Dr. Ehab El-Shaer

K. Salah7 ACL for Egress Filtering 1. If source IP address = 10.*.*.*, DENY [private IP address range] 2. If source IP address = *.* to *.*, DENY [private IP address range] 3. If source IP address = *.*, DENY [private IP address range] 4. If source IP address NOT = *.*, DENY [not in internal address range] 5. If ICMP Type = 8, PASS [allow outgoing echo messages] 6. If Protocol=ICMP, DENY [drop all other outgoing ICMP messages] 7. If TCP RST=1, DENY [do not allow outgoing resets; used for scanning if port is closed as a reply to SYN] 8. If source IP address = and TCP source port = 80 OR 443, PERMIT [public webserver] 9. If TCP source port=0 through 49151, DENY [well-known and registered ports] 10. If UDP source port=0 through 49151, DENY [well-known and registered ports] 11. If TCP source port =49152 through 65,536, PASS [allow outgoing client connections] 12. If UDP source port = through 65,536, PERMIT [allow outgoing client connections] 13. DENY ALL Courtesy of Dr. Ehab El-Shaer  Beware of misconfiguration  Rules of subset, superset, overlapping, shadowing (one rule never gets triggered).

K. Salah8 Firewall Performance Knowing this how intruders can maximize their DOS attacks? Is there a way to know the depth of the FW?

K. Salah9 Weaknesses of Packet Filters Do not prevent application-specific attacks Do not prevent application-specific attacks  For example, if there is a buffer overflow in URL decoding routine, firewall will not block an attack string No user authentication mechanisms No user authentication mechanisms  … except address-based authentication Very weak as it can be spoofed!  Firewalls don’t have any upper-level functionality Vulnerable to TCP/IP attacks such as spoofing Vulnerable to TCP/IP attacks such as spoofing  Solution: list of addresses for each interface (packets with internal addresses shouldn’t come from outside) Does not know how to deal with returning traffic, usually has ephemeral ports! Does not know how to deal with returning traffic, usually has ephemeral ports!

K. Salah10 Stateless Filtering Is Not Enough In TCP connections, ports with numbers less than 1024 are permanently assigned to servers In TCP connections, ports with numbers less than 1024 are permanently assigned to servers  20,21 for FTP, 23 for telnet, 25 for SMTP, 80 for HTTP… Clients use ports numbered from 1024 to Clients use ports numbered from 1024 to  They must be available for clients to receive responses What should a firewall do if it sees, say, an incoming request to some client’s port 5612? What should a firewall do if it sees, say, an incoming request to some client’s port 5612?  It must allow it: this could be a server’s response in a previously established connection…  …OR it could be malicious traffic  Can’t tell without keeping state for each connection

K. Salah11 Ephemeral (random) Ports Inbound SMTPOutbound SMTP

K. Salah12 HTTP Ports

K. Salah13 Example: FTP “PORT 5151”   “OK”  DATA CHANNEL  TCP ACK FTP clientFTP server 20 Data 21 Command  Client opens command channel to server; tells server second port number  Server acknowledges  Server opens data channel to client’s second port  Client acknowledges Connection from a random port on an external host

K. Salah14 Session Filtering Decision is still made separately for each packet, but in the context of a connection Decision is still made separately for each packet, but in the context of a connection  If new connection, then check against security policy  If existing connection, then look it up in the table and update the table, if necessary Only allow incoming traffic to a high-numbered port if there is an established connection to that port  FASTER  FASTER than packet Filtering – does not check the Rulebase if Established/Related! Hard to filter stateless protocols (UDP) and ICMP Hard to filter stateless protocols (UDP) and ICMP  Stateful is not faster for UDP traffic!!  That is why better to have two FWs back-to-back. Stateless FW to filter noisy traffic (UDP traffic) Followed by a Stateful FW to deal with TCP filtering Typical filter: deny everything that’s not allowed Typical filter: deny everything that’s not allowed  Must be careful filtering out service traffic such as ICMP Filters can be bypassed with IP tunneling Filters can be bypassed with IP tunneling

K. Salah15 Example: Connection State Table

K. Salah16 IPTables Stateful Inspection Associate all the packets of a particular connection with each other. Associate all the packets of a particular connection with each other. Tries to make sense out of the higher level protocols: NFS, HTTP, FTP… Tries to make sense out of the higher level protocols: NFS, HTTP, FTP… Can be used to block port scans or malicious hack attempt. Can be used to block port scans or malicious hack attempt. Dynamic allocation of arbitrary ports used by many protocols for data exchange. Dynamic allocation of arbitrary ports used by many protocols for data exchange.

K. Salah17 IPTables Stateful Inspection States States  NEW  RELATED  INVALID  ESTABLISHED  RELATED+REPLY

K. Salah18 Available Firewalls Buy a solution Buy a solution  Hardware -- PIX, Sonicwall, WatchGuard…  Software -- CheckPoint, ISA, Boarder Manager Build a solution Build a solution  Linux – IPTables, Netfilter  BSD -- IPFW, IPFilter, pf

K. Salah19 Types of Firewalls Packet Filter Packet Filter Proxy Firewalls Proxy Firewalls  Circuit Level Gateways Works at the transport layer E.g., SOCKS  Application Level Gateways Works at the application layer  must understand and implement application protocol Called Application-level gateway or proxy server Stateful Multilayer Inspection Stateful Multilayer Inspection  Checkpoint patented this technology in 1997