122
1 CCNA Security Chapter Four Implementing Firewall Technologies

1 CCNA Security Chapter Four Implementing Firewall Technologies

  • View
    243

  • Download
    2

Embed Size (px)

Citation preview

Page 1: 1 CCNA Security Chapter Four Implementing Firewall Technologies

1

CCNA Security

Chapter Four

Implementing Firewall Technologies

Page 2: 1 CCNA Security Chapter Four Implementing Firewall Technologies

222北京邮电大学思科网络技术学院

Lesson Planning

• This lesson should take 3-6 hours to present

• The lesson should include lecture, demonstrations, discussion and assessment

• The lesson can be taught in person or using remote instruction

Page 3: 1 CCNA Security Chapter Four Implementing Firewall Technologies

333北京邮电大学思科网络技术学院

Major Concepts

• Implement ACLs

• Describe the purpose and operation of firewall technologies

• Implement CBAC

• Zone-based Policy Firewall using SDM and CLI

Page 4: 1 CCNA Security Chapter Four Implementing Firewall Technologies

444北京邮电大学思科网络技术学院

Lesson Objectives

Upon completion of this lesson, the successful participant will be able to:

1. Describe standard and extended ACLs

2. Describe applications of standard and extended ACLs

3. Describe the relationship between topology and flow for ACLs and describe the proper selection of ACL types for particular topologies (ACL design methodology)

4. Describe how to implement ACLs with SDM

5. Describe the usage and syntax for complex ACLs

6. Describe the usage and syntax for dynamic ACLs

7. Interpret the output of the show and debug commands used to verify and troubleshoot complex ACL implementations

Page 5: 1 CCNA Security Chapter Four Implementing Firewall Technologies

555北京邮电大学思科网络技术学院

Lesson Objectives

8. Describe how to mitigate common network attacks with ACLs

9. Describe the purpose of firewalls and where they reside in a modern network

10. Describe the various types of firewalls

11. Describe design considerations for firewalls and the implications for the network security policy

12. Describe the role of CBAC in a modern network

13. Describe the underlying operation of CBAC

14. Describe the configuration of CBAC

15. Describe the verification and troubleshooting of CBAC

Page 6: 1 CCNA Security Chapter Four Implementing Firewall Technologies

666北京邮电大学思科网络技术学院

Lesson Objectives

16. Describe the role of Zone-Based Policy Firewall in a modern network

17. Describe the underlying operation of Zone-Based Policy Firewall

18. Describe the implementation of Zone-Based Policy Firewall with CLI

19. Describe the implementation of Zone-Based Policy Firewall with manual SDM

20. Describe the implementation of Zone-Based Policy Firewall with the SDM Wizard

21. Describe the verification and troubleshooting of Zone-Based Policy Firewall

Page 7: 1 CCNA Security Chapter Four Implementing Firewall Technologies

777北京邮电大学思科网络技术学院

Implementing Firewall Technologies

• 4.1 Access Control Lists

• 4.2 Firewall Technologies

• 4.3 Context-Based Access Control

• 4.4 Zone-Based Policy Firewall

Page 8: 1 CCNA Security Chapter Four Implementing Firewall Technologies

888北京邮电大学思科网络技术学院

4.1 Access Control Lists

• 4.1.1 Standard and Extended IP ACLs

• 4.1.2 Applications of Standard and Extended IP ACLs

• 4.1.3 Topology and Flow for Access Control Lists

• 4.1.4 ACLs with Security Device Manager

• 4.1.5 TCP Established and Reflexive ACLs

• 4.1.6 Dynamic ACLs

• 4.1.7 Time-Based ACLs

• 4.1.8 Validating Complex ACL Implementations

• 4.1.9 Mitigating Attacks with ACLs

Page 9: 1 CCNA Security Chapter Four Implementing Firewall Technologies

999北京邮电大学思科网络技术学院

4.1.1 Standard and Extended IP ACLs

• ACL Topology and Types

• Standard and Extended Numbered IP ACLs

• Named IP ACLs

• The log Parameter

• ACL Configuration Guidelines

Page 10: 1 CCNA Security Chapter Four Implementing Firewall Technologies

101010北京邮电大学思科网络技术学院

ACL Topology and Types

Page 11: 1 CCNA Security Chapter Four Implementing Firewall Technologies

111111北京邮电大学思科网络技术学院

Standard Numbered IP ACLs

• The first value specifies the ACL number

• The second value specifies whether to permit or deny the configured source IP address traffic

• The third value is the source IP address that must be matched

• The fourth value is the wildcard mask to be applied to the previously configured IP address to indicate the range

• All ACLs assume an implicit deny statement at the end of the ACL6+

• At least one permit statement should be included or all traffic will be dropped once that ACL is applied to an interface

Router(config)# access-list {1-99} {permit | deny} source-addr [source-mask]

Page 12: 1 CCNA Security Chapter Four Implementing Firewall Technologies

121212北京邮电大学思科网络技术学院

Extended Numbered IP ACLs

• The first value specifies the ACL number

• The second value specifies whether to permit or deny accordingly

• The third value indicates protocol type

• The source IP address and wildcard mask determine where traffic originates. The destination IP address and wildcard mask are used to indicate the final destination of the network traffic

• The command to apply the standard or extended numbered ACL:

Router(config)# access-list {100-199} {permit | deny} protocol source-addr [source-mask] [operator operand] destination-addr [destination-mask] [operator operand] [established]

Router(config-if)# ip access-group number {in | out}

Page 13: 1 CCNA Security Chapter Four Implementing Firewall Technologies

131313北京邮电大学思科网络技术学院

Named IP ACLs

Router(config)# ip access-list extended vachon1 Router(config-ext-nacl)# deny ip any 200.1.2.10 0.0.0.1Router(config-ext-nacl)# permit tcp any host 200.1.1.11 eq 80Router(config-ext-nacl)# permit tcp any host 200.1.1.10 eq 25Router(config-ext-nacl)# permit tcp any eq 25 host 200.1.1.10 any establishedRouter(config-ext-nacl)# permit tcp any 200.1.2.0 0.0.0.255 establishedRouter(config-ext-nacl)# permit udp any eq 53 200.1.2.0 0.0.0.255Router(config-ext-nacl)# deny ip any any Router(config-ext-nacl)# interface ethernet 1Router(config-if)# ip access-group vachon1 in Router(config-if)# exit

Standard

Extended

Page 14: 1 CCNA Security Chapter Four Implementing Firewall Technologies

141414北京邮电大学思科网络技术学院

The log Parameter

There are several pieces of information logged:

• The action—permit or deny

• The protocol—TCP, UDP, or ICMP

• The source and destination addresses

• For TCP and UDP—the source and destination port numbers

• For ICMP—the message types

*May 1 22:12:13.243: %SEC-6-IPACCESSLOGP: list ACL-IPv4-E0/0-IN permitted tcp 192.168.1.3(1024) -> 192.168.2.1(22), 1 packet

*May 1 22:17:16.647: %SEC-6-IPACCESSLOGP: list ACL-IPv4-E0/0-IN permitted tcp 192.168.1.3(1024) -> 192.168.2.1(22), 9 packets

*May 1 22:12:13.243: %SEC-6-IPACCESSLOGP: list ACL-IPv4-E0/0-IN permitted tcp 192.168.1.3(1024) -> 192.168.2.1(22), 1 packet

*May 1 22:17:16.647: %SEC-6-IPACCESSLOGP: list ACL-IPv4-E0/0-IN permitted tcp 192.168.1.3(1024) -> 192.168.2.1(22), 9 packets

R1(config)# access-list 101 permit tcp 192.168.1.0 0.0.0.255 192.168.2.0 0.0.0.255 eq 22 log

Page 15: 1 CCNA Security Chapter Four Implementing Firewall Technologies

151515北京邮电大学思科网络技术学院

ACL Configuration Guidelines

• ACLs are created globally and then applied to interfaces

• ACLs filter traffic going through the router, or traffic to and from the router, depending on how it is applied

• Only one ACL per interface, per protocol, per direction

• Standard or extended indicates the information that is used to filter packets

• ACLs are process top-down. The most specific statements must go at the top of the list

• All ACLs have an implicit “deny all” statement at the end, therefore every list must have at least one permit statement to allow any traffic to pass

Page 16: 1 CCNA Security Chapter Four Implementing Firewall Technologies

161616北京邮电大学思科网络技术学院

4.1.2 Applications of Standard and Extended IP ACLs

• Applying Standard ACLs

• Applying Extended ACLs

• Other CLI Commands

Page 17: 1 CCNA Security Chapter Four Implementing Firewall Technologies

171717北京邮电大学思科网络技术学院

r1

Use a standard ACL to block all traffic from 172.16.4.0/24 network, but allow all other traffic.

r1(config)# access-list 1 deny 172.16.4.0 0.0.0.255r1(config)# access-list 1 permit anyr1(config)# interface ethernet 0r1(config-if)# ip access-group 1 out

Applying Standard ACLs

Page 18: 1 CCNA Security Chapter Four Implementing Firewall Technologies

181818北京邮电大学思科网络技术学院

Applying Extended ACLs

r1

Use an extended ACL to block all FTP traffic from 172.16.4.0/24 network, but allow all other traffic.

access-list 101 deny tcp 172.16.4.0 0.0.0.255 172.16.3.0 0.0.0.255 eq 21access-list 101 deny tcp 172.16.4.0 0.0.0.255 172.16.3.0 0.0.0.255 eq 20access-list 101 permit ip any any

Page 19: 1 CCNA Security Chapter Four Implementing Firewall Technologies

191919北京邮电大学思科网络技术学院

Other CLI Commands

• To ensure that only traffic from a subnet is blocked and all other traffic is allowed:access-list 1 permit any

• To place an ACL on the inbound E1 interface:

interface ethernet 1ip access-group 101 in

• To check the intended effect of an ACL:

• show ip access-list

Page 20: 1 CCNA Security Chapter Four Implementing Firewall Technologies

202020北京邮电大学思科网络技术学院

4.1.3 Topology and Flow for Access Control Lists

• How ACLs Work

• ACL Placement

• Using Nmap for Planning

Page 21: 1 CCNA Security Chapter Four Implementing Firewall Technologies

212121北京邮电大学思科网络技术学院

Click to view examples

How ACLs Work

Inbound ACL Outbound ACL

Page 22: 1 CCNA Security Chapter Four Implementing Firewall Technologies

222222北京邮电大学思科网络技术学院

ACL Placement

Extended ACLs should be placed on routers as close as possible to the source that is being filtered. If placed too far from the source being filtered, there is inefficient use of network resources.

Standard ACLs should be placed as close to the destination as possible. Standard ACLs filter packets based on the source address only. If placed too close to the source, it can deny all traffic, including valid traffic.

Page 23: 1 CCNA Security Chapter Four Implementing Firewall Technologies

232323北京邮电大学思科网络技术学院

Using Nmap for Planning

Page 24: 1 CCNA Security Chapter Four Implementing Firewall Technologies

242424北京邮电大学思科网络技术学院

4.1.4 ACLs with Security Device Manager

• Using SDM

• Access Rules

• Configuring Standard Rules Using SDM

• Applying a Rule to an Interface

• Viewing Commands

Page 25: 1 CCNA Security Chapter Four Implementing Firewall Technologies

252525北京邮电大学思科网络技术学院

Using SDM

Choose the Configure optionfor configuring ACLs

Page 26: 1 CCNA Security Chapter Four Implementing Firewall Technologies

262626北京邮电大学思科网络技术学院

Access Rules

Choose Configure > Additional Tasks > ACL Editor

Rule types:• Access Rules• NAT Rules• Ipsec Rules• NAC Rules• Firewall Rules• QoS Rules• Unsupported Rules• Externally Defined Rules• Cisco SDM Default Rules

Page 27: 1 CCNA Security Chapter Four Implementing Firewall Technologies

272727北京邮电大学思科网络技术学院

Configuring Standard Rules Using SDM

1. Choose Configure > Additional Tasks > ACL Editor > Access Rules

5. Click Add

3. Enter a name or number

4. Choose Standard Rule Optionally, enter a description

2. Click Add

6. Choose Permit or Deny

7. Choose an address type

8. Complete this field based on the choice made in #7

9. Enter an optional description

10. Optional checkbox

11. Click OK

12. Continue adding or editing rules

Page 28: 1 CCNA Security Chapter Four Implementing Firewall Technologies

282828北京邮电大学思科网络技术学院

Applying a Rule to an Interface

1. Click Associate

2. Choose the interface

3. Choose a direction

4. An information box with options appears if a rule is already associated with that interface, that direction.

Page 29: 1 CCNA Security Chapter Four Implementing Firewall Technologies

292929北京邮电大学思科网络技术学院

Viewing Commands

R1# show running-config <output omitted>!hostname R1<output omitted>enable secret 5

$1$MJD8$.1LWYcJ6iUi133Yg7vGHG/<output omitted>crypto pki trustpoint TP-self-signed-

1789018390 enrollment selfsigned subject-name cn=IOS-Self-Signed-

Certificate-1789018390 revocation-check none rsakeypair TP-self-signed-1789018390!crypto pki certificate chain TP-self-

signed-1789018390 certificate self-signed 01 3082023A 308201A3 A0030201 02020101

300D0609 2A864886 F70D0101 04050030 <output omitted> 1BF29620 A084B701 5B92483D D934BE31

ECB7AB56 8FFDEA93 E2061F33 8356 quit

interface FastEthernet0/1 ip address 192.168.1.1 255.255.255.0 ip access-group Outbound in<output omitted>!interface Serial0/0/0 ip address 10.1.1.1 255.255.255.252 clock rate 128000!<output omitted>no ip http serverip http secure-server!ip access-list standard Outbound remark SDM_ACL Category=1 permit 192.168.1.3!access-list 100 remark SDM_ACL Category=16access-list 100 deny tcp any host

192.168.1.3 eq telnet logaccess-list 100 permit ip any any!<output omitted>!

Page 30: 1 CCNA Security Chapter Four Implementing Firewall Technologies

303030北京邮电大学思科网络技术学院

4.1.5 TCP Established and Reflexive ACLs

• Types of ACLs

• Syntax for TCP Established

• Example with TCP Established

• Reflexive ACLs

• Configuring a Router to Use Reflexive ACLs

Page 31: 1 CCNA Security Chapter Four Implementing Firewall Technologies

313131北京邮电大学思科网络技术学院

• Standard IP ACLs

• Extended IP ACLs

• Extended IP ACLs using TCP established

• Reflexive IP ACLs

• Dynamic ACLs

• Time-Based ACLs

• Context-based Access Control (CBAC) ACLs

Types of ACLs

Page 32: 1 CCNA Security Chapter Four Implementing Firewall Technologies

323232北京邮电大学思科网络技术学院

Syntax for TCP Established

The established keyword:

• Forces a check by the routers to see if the ACK, RST TCP control flags are set. If flag is set, the TCP traffic is allowed in.

• Does not implement a stateful firewall on a router

• Hackers can take advantage of the open hole

• Option does not apply to UDP or ICMP traffic

Router(config)# access-list access-list-number {permit | deny} protocol source source-wildcard [operator port] destination destination-wildcard [operator port] [established]

Page 33: 1 CCNA Security Chapter Four Implementing Firewall Technologies

333333北京邮电大学思科网络技术学院

access-list 100 permit tcp any eq 443 192.168.1.0 0.0.0.255 establishedaccess-list 100 permit tcp any 192.168.1.3 eq 22access-list 100 deny ip any any interface s0/0/0ip access-group 100 in

Example Using TCP Established

R1

Page 34: 1 CCNA Security Chapter Four Implementing Firewall Technologies

343434北京邮电大学思科网络技术学院

Reflexive ACLs

• Provide a truer form of session filtering

• Much harder to spoof

• Allow an administrator to perform actual session filtering for any type of IP traffic

• Work by using temporary access control entries (ACEs)

Page 35: 1 CCNA Security Chapter Four Implementing Firewall Technologies

353535北京邮电大学思科网络技术学院

Configuring a Router to Use Reflexive ACLs

1. Create an internal ACL that looks for new outbound sessions and creates temporary reflexive ACLs

2. Create an external ACL that uses the reflexive ACLs to examine return traffic

3. Activate the named ACLs on the appropriate interfaces

Page 36: 1 CCNA Security Chapter Four Implementing Firewall Technologies

363636北京邮电大学思科网络技术学院

4.1.6 Dynamic ACLs

• Overview

• Creating a Dynamic ACL

• Setting up a Dynamic ACL

• CLI Commands

Page 37: 1 CCNA Security Chapter Four Implementing Firewall Technologies

373737北京邮电大学思科网络技术学院

Dynamic ACL Overview

• Available for IP traffic only

• Dependent on Telnet connectivity, authentication, and extended ACLs

• Security benefits include:

- Use of a challenge mechanism to authenticate users

- Simplified management in large internetworks

- Reduction of the amount of router processing that is required for ACLs

- Reduction of the opportunity for network break-ins by network hackers

- Creation of dynamic user access through a firewall without compromising other configured security restrictions

Page 38: 1 CCNA Security Chapter Four Implementing Firewall Technologies

383838北京邮电大学思科网络技术学院

Implementing a Dynamic ACL

Page 39: 1 CCNA Security Chapter Four Implementing Firewall Technologies

393939北京邮电大学思科网络技术学院

Setting up a Dynamic ACL

Router(config)# access-list ACL_# dynamic dynamic_ACL_name [timeout minutes] {deny | permit} IP_protocol source_IP_address src_wildcard_mask destination_IP_address dst_wildcard_mask [established] [log]

Page 40: 1 CCNA Security Chapter Four Implementing Firewall Technologies

404040北京邮电大学思科网络技术学院

CLI Commands

Page 41: 1 CCNA Security Chapter Four Implementing Firewall Technologies

414141北京邮电大学思科网络技术学院

4.1.7 Time-based ACLs

• Overview

• CLI Commands

• Example Configuration

Page 42: 1 CCNA Security Chapter Four Implementing Firewall Technologies

424242北京邮电大学思科网络技术学院

Overview

Page 43: 1 CCNA Security Chapter Four Implementing Firewall Technologies

434343北京邮电大学思科网络技术学院

CLI Commands

Page 44: 1 CCNA Security Chapter Four Implementing Firewall Technologies

444444北京邮电大学思科网络技术学院

Example Configuration

R1(config)# time-range employee-time

R1(config-time-range)# periodic weekdays 12:00 to 13:00

R1(config-time-range)# periodic weekdays 17:00 to 19:00

R1(config-time-range)# exit

R1(config)# access-list 100 permit ip 192.168.1.0 0.0.0.255 any time-range employee-time

R1(config)# access-list 100 deny ip any any

R1(config)# interface FastEthernet 0/1

R1(config-if)# ip access-group 100 in

R1(config-if)# exit

Page 45: 1 CCNA Security Chapter Four Implementing Firewall Technologies

454545北京邮电大学思科网络技术学院

4.1.8 Validating Complex ACL Implementations

• Verifying ACL Configuration

• Confirmation

• Troubleshooting

Page 46: 1 CCNA Security Chapter Four Implementing Firewall Technologies

464646北京邮电大学思科网络技术学院

The ACLs are implemented.

Now it is time to verify that they

are working properly.

F0/1 F0/1

Serial 0/0/0

Serial0/0/0Serial0/0/1

Serial0/0/1

R1

R3

R2

PC C

R1

Router# show access-lists [access-list-number | access-list-name]

Verifying ACL Configuration

Page 47: 1 CCNA Security Chapter Four Implementing Firewall Technologies

474747北京邮电大学思科网络技术学院

Confirmation

Page 48: 1 CCNA Security Chapter Four Implementing Firewall Technologies

484848北京邮电大学思科网络技术学院

Troubleshooting

Page 49: 1 CCNA Security Chapter Four Implementing Firewall Technologies

494949北京邮电大学思科网络技术学院

4.1.9 Mitigating Attacks with ACLs

• Attacks Mitigated

• CLI Commands

• Allowing Command Services

• Controlling ICMP Messages

Page 50: 1 CCNA Security Chapter Four Implementing Firewall Technologies

505050北京邮电大学思科网络技术学院

Attacks Mitigated

• ACLs can be used to mitigate many network threats:

- IP address spoofing, inbound and outbound

- DoS TCP SYN attacks

- DoS smurf attacks

• ACLs can also filter the following traffic:

- ICMP messages, inbound and outbound

- traceroute

Page 51: 1 CCNA Security Chapter Four Implementing Firewall Technologies

515151北京邮电大学思科网络技术学院

CLI Commands

Page 52: 1 CCNA Security Chapter Four Implementing Firewall Technologies

525252北京邮电大学思科网络技术学院

Allowing Common Services

Page 53: 1 CCNA Security Chapter Four Implementing Firewall Technologies

535353北京邮电大学思科网络技术学院

Controlling ICMP Messages

Page 54: 1 CCNA Security Chapter Four Implementing Firewall Technologies

545454北京邮电大学思科网络技术学院

4.2 Firewall Technologies

• 4.2.1 Securing Networks with Firewalls

• 4.2.2 Types of Firewalls

• 4.2.3 Firewalls in Network Design

Page 55: 1 CCNA Security Chapter Four Implementing Firewall Technologies

555555北京邮电大学思科网络技术学院

4.2.1 Securing Networks with Firewalls

• Overview

• Benefits

Page 56: 1 CCNA Security Chapter Four Implementing Firewall Technologies

565656北京邮电大学思科网络技术学院

Overview

• A firewall is a system that enforces an access control policy between network

• Common properties of firewalls:

- The firewall is resistant to attacks

- The firewall is the only transit point between networks

- The firewall enforces the access control policy

Page 57: 1 CCNA Security Chapter Four Implementing Firewall Technologies

575757北京邮电大学思科网络技术学院

Benefits of Firewalls

• Exposure of sensitive hosts and applications to untrusted users can be prevented.

• The protocol flow can be sanitized, preventing the exploitation of protocol flaws.

• Malicious data can be blocked from servers and clients.

• Security policy enforcement can be made simple, scalable, and robust with a properly configured firewall.

• Offloading most of the network access control to a few points in the network can reduce the complexity of security management.

Page 58: 1 CCNA Security Chapter Four Implementing Firewall Technologies

585858北京邮电大学思科网络技术学院

Limitations of Firewalls

• If misconfigured, a firewall can have serious consequences (single point of failure).

• Many applications cannot be passed over firewalls securely.

• Users might proactively search for ways around the firewall to receive blocked material, exposing the network to potential attack.

• Network performance can slow down.

• Unauthorized traffic can be tunneled or hidden as legitimate traffic through the firewall.

Page 59: 1 CCNA Security Chapter Four Implementing Firewall Technologies

595959北京邮电大学思科网络技术学院

4.2.2 Types of Firewalls

• Filtering Firewalls

• Packet Filtering Firewall

• Stateful Firewall

• Cisco Systems Firewall Solutions

Page 60: 1 CCNA Security Chapter Four Implementing Firewall Technologies

606060北京邮电大学思科网络技术学院

Types of Filtering Firewalls

• Packet-filtering firewall—is typically a router that has the capability to filter on some of the contents of packets (examines Layer 3 and sometimes Layer 4 information)

• Stateful firewall—keeps track of the state of a connection: whether the connection is in an initiation, data transfer, or termination state

• Application gateway firewall (proxy firewall) —filters information at Layers 3, 4, 5, and 7. Firewall control and filtering done in software.

• Address-translation firewall—expands the number of IP addresses available and hides network addressing design.

• Host-based (server and personal) firewall—a PC or server with firewall software running on it.

• Transparent firewall—filters IP traffic between a pair of bridged interfaces.

• Hybrid firewalls—some combination of the above firewalls. For example, an application inspection firewall combines a stateful firewall with an application gateway firewall.

Page 61: 1 CCNA Security Chapter Four Implementing Firewall Technologies

616161北京邮电大学思科网络技术学院

Packet-Filtering Firewall

• Packet-filtering firewalls use a simple policy table lookup that permits or denies traffic based on specific criteria:

- Source IP address

- Destination IP address

- Protocol

- Source port number

- Destination port number

- Synchronize/start (SYN) packet receipt

Page 62: 1 CCNA Security Chapter Four Implementing Firewall Technologies

626262北京邮电大学思科网络技术学院

Packet-Filtering Firewall

Page 63: 1 CCNA Security Chapter Four Implementing Firewall Technologies

636363北京邮电大学思科网络技术学院

Stateful Firewall

Page 64: 1 CCNA Security Chapter Four Implementing Firewall Technologies

646464北京邮电大学思科网络技术学院

Stateful Firewall

10.1.1.1 200.3.3.3

Inside ACL

(Outgoing Traffic)

Outside ACL

(Incoming Traffic)

permit ip 10.0.0.0 0.0.0.255 any

Dynamic: permit tcp host 200.3.3.3 eq 80 host 10.1.1.1 eq 1500

permit tcp any host 10.1.1.2 eq 25

permit udp any host 10.1.1.2 eq 53

deny ip any any

source port 1500 destination port 80

Page 65: 1 CCNA Security Chapter Four Implementing Firewall Technologies

656565北京邮电大学思科网络技术学院

Stateful Firewalls Advantages/Disadvantages

Page 66: 1 CCNA Security Chapter Four Implementing Firewall Technologies

666666北京邮电大学思科网络技术学院

Cisco Systems Firewall Solutions

Page 67: 1 CCNA Security Chapter Four Implementing Firewall Technologies

676767北京邮电大学思科网络技术学院

4.2.3 Firewalls in Network Design

• DMZ Scenario

• Layered Defense Scenario

• Firewall Best Practices

• Design Example

Page 68: 1 CCNA Security Chapter Four Implementing Firewall Technologies

686868北京邮电大学思科网络技术学院

Design with DMZ

Page 69: 1 CCNA Security Chapter Four Implementing Firewall Technologies

696969北京邮电大学思科网络技术学院

Layered Defense Scenario

Page 70: 1 CCNA Security Chapter Four Implementing Firewall Technologies

707070北京邮电大学思科网络技术学院

Firewall Best Practices

• Position firewalls at security boundaries.

• Firewalls are the primary security device. It is unwise to rely exclusively on a firewall for security.

• Deny all traffic by default. Permit only services that are needed.

• Ensure that physical access to the firewall is controlled.

• Regularly monitor firewall logs.

• Practice change management for firewall configuration changes.

• Remember that firewalls primarily protect from technical attacks originating from the outside.

Page 71: 1 CCNA Security Chapter Four Implementing Firewall Technologies

717171北京邮电大学思科网络技术学院

Design Example

Page 72: 1 CCNA Security Chapter Four Implementing Firewall Technologies

727272北京邮电大学思科网络技术学院

4.3 Context-Based Access Control

• 4.3.1 CBAC Characteristics

• 4.3.2 CBAC Operation

• 4.3.3 Configuring CBAC

• 4.3.4 Troubleshooting CBAC

Page 73: 1 CCNA Security Chapter Four Implementing Firewall Technologies

737373北京邮电大学思科网络技术学院

4.3.1 CBAC Characteristics

• Overview

• CBAC Capabilities

Page 74: 1 CCNA Security Chapter Four Implementing Firewall Technologies

747474北京邮电大学思科网络技术学院

Overview

• Filters TCP and UDP packets based on application layer protocol session information

• Provides stateful application layer filtering

• Provides four main functions:

- Traffic Filtering

- Traffic Inspection

- Intrusion Detection

- Generation of Audits and Alerts

Page 75: 1 CCNA Security Chapter Four Implementing Firewall Technologies

757575北京邮电大学思科网络技术学院

CBAC Capabilities

Page 76: 1 CCNA Security Chapter Four Implementing Firewall Technologies

767676北京邮电大学思科网络技术学院

4.3.2 CBAC Operation

• Overview

• Step-by-Step

• CBAC TCP and UDP Handling

• CBAC Example

Page 77: 1 CCNA Security Chapter Four Implementing Firewall Technologies

777777北京邮电大学思科网络技术学院

Overview

• CBAC examines not only Network Layer and Transport Layer information but also examines Application Layer protocol information to learn about the state of the session.

• The state table tracks the sessions and inspects all packets that pass through the stateful packet filter firewall.

• CBAC then uses the state table to build dynamic ACL entries that permit returning traffic through the perimeter router or firewall.

Page 78: 1 CCNA Security Chapter Four Implementing Firewall Technologies

787878北京邮电大学思科网络技术学院

Step-by-Step

Page 79: 1 CCNA Security Chapter Four Implementing Firewall Technologies

797979北京邮电大学思科网络技术学院

CBAC TCP Handling

Page 80: 1 CCNA Security Chapter Four Implementing Firewall Technologies

808080北京邮电大学思科网络技术学院

CBAC UDP Handling

Page 81: 1 CCNA Security Chapter Four Implementing Firewall Technologies

818181北京邮电大学思科网络技术学院

CBAC Example

Page 82: 1 CCNA Security Chapter Four Implementing Firewall Technologies

828282北京邮电大学思科网络技术学院

4.3.3 Configuration of CBAC

Four Steps to Configure

• Step 1: Pick an Interface

• Step 2: Configure IP ACLs at the Interface

• Step 3: Define Inspection Rules

• Step 4: Apply an Inspection Rule to an Interface

Page 83: 1 CCNA Security Chapter Four Implementing Firewall Technologies

838383北京邮电大学思科网络技术学院

Step 1: Pick an Interface

Two-Interface

Three-Interface

Page 84: 1 CCNA Security Chapter Four Implementing Firewall Technologies

848484北京邮电大学思科网络技术学院

Step 2: Configure IP ACLs at the Interface

Page 85: 1 CCNA Security Chapter Four Implementing Firewall Technologies

858585北京邮电大学思科网络技术学院

Step 3: Define Inspection Rules

Page 86: 1 CCNA Security Chapter Four Implementing Firewall Technologies

868686北京邮电大学思科网络技术学院

Step 4: Apply an Inspection Rule to an Interface

Page 87: 1 CCNA Security Chapter Four Implementing Firewall Technologies

878787北京邮电大学思科网络技术学院

4.3.4 Troubleshooting CBAC

• Alerts and Audits

• show ip inspect Parameters

• debug ip inspect Parameters

Page 88: 1 CCNA Security Chapter Four Implementing Firewall Technologies

888888北京邮电大学思科网络技术学院

Alerts and Audits

Page 89: 1 CCNA Security Chapter Four Implementing Firewall Technologies

898989北京邮电大学思科网络技术学院

show ip inspect Parameters

Page 90: 1 CCNA Security Chapter Four Implementing Firewall Technologies

909090北京邮电大学思科网络技术学院

debug ip inspect Parameters

Page 91: 1 CCNA Security Chapter Four Implementing Firewall Technologies

919191北京邮电大学思科网络技术学院

4.4 Zone-Based Policy Firewall

• 4.4.1 Zone-Based Policy Firewall Characteristics

• 4.4.2 Zone-Based Policy Firewall Operation

• 4.4.3 Configuring Zone-Based Policy Firewall with CLI

• 4.4.4 Configuring Zone-Based Policy Firewall with Manually SDM

• 4.4.5 Configuring Zone-Based Policy Firewall with SDM Wizard

• 4.4.6 Troubleshooting Zone-Based Policy Firewall

Page 92: 1 CCNA Security Chapter Four Implementing Firewall Technologies

929292北京邮电大学思科网络技术学院

4.4.1 Zone-Based Policy Firewall Characteristics

• Topology

• Benefits

• The Design Process

• Common Designs

Page 93: 1 CCNA Security Chapter Four Implementing Firewall Technologies

939393北京邮电大学思科网络技术学院

Topology Example

Page 94: 1 CCNA Security Chapter Four Implementing Firewall Technologies

949494北京邮电大学思科网络技术学院

Benefits

• Zone-based policy firewall is not dependent on ACLs

• The router security posture is now “block unless explicitly allowed”

• C3PL makes policies easy to read and troubleshoot

• One policy affects any given traffic, instead of needing multiple ACLs and inspection actions.

Page 95: 1 CCNA Security Chapter Four Implementing Firewall Technologies

959595北京邮电大学思科网络技术学院

The Design Process

• Step 1. Determine the Zone 

• Step 2. Establish policies between zones

• Step 3. Design the physical infrastructure

• Step 4. Identify subset within zones and merge traffic

requirements

Page 96: 1 CCNA Security Chapter Four Implementing Firewall Technologies

969696北京邮电大学思科网络技术学院

Common Designs

LAN-to-Internet Public Servers

Redundant FirewallsComplex Firewall

Page 97: 1 CCNA Security Chapter Four Implementing Firewall Technologies

979797北京邮电大学思科网络技术学院

Zones Simplify Complex Firewall

Page 98: 1 CCNA Security Chapter Four Implementing Firewall Technologies

989898北京邮电大学思科网络技术学院

4.4.2 Zone-Based Policy Firewall Operation

• Actions

• Rules for Application Traffic

• Rules for Router Traffic

Page 99: 1 CCNA Security Chapter Four Implementing Firewall Technologies

999999北京邮电大学思科网络技术学院

Actions

Inspect – This action configures Cisco IOS stateful packet inspection

Drop – This action is analogous to deny in an ACL

Pass – This action is analogous to permit in an ACL

Page 100: 1 CCNA Security Chapter Four Implementing Firewall Technologies

100100100北京邮电大学思科网络技术学院

Source interface

member of zone?

Destination interface

member of zone?

Zone-pair exists?

Policy exists? RESULT

NO NO N/A N/ANo impact of zoning/policy

YES (zone 1) YES (zone 1) N/A* N/ANo policy

lookup (PASS)

YES NO N/A N/A DROP

NO YES N/A N/A DROP

YES (zone 1) YES (zone 2) NO N/A DROP

YES (zone 1) YES (zone 2) YES NO DROP

YES (zone 1) YES (zone 2) YES YES policy actions

*zone-pair must have different zone as source and destination

Rules for Application Traffic

Page 101: 1 CCNA Security Chapter Four Implementing Firewall Technologies

101101101北京邮电大学思科网络技术学院

Rules for Router Traffic

Source interface

member of zone?

Destination interface

member of zone?

Zone-pair

exists?

Policy exists?

RESULT

ROUTER YES NO - PASS

ROUTER YES YES NO PASS

ROUTER YES YES YESpolicy

actions

YES ROUTER NO - PASS

YES ROUTER YES NO PASS

YES ROUTER YES YESpolicy

actions

Page 102: 1 CCNA Security Chapter Four Implementing Firewall Technologies

102102102北京邮电大学思科网络技术学院

4.4.3 Configuring Zone-Based Policy Firewall with CLI

1. Create the zones for the firewall with the zone security command

3. Specify firewall policies with the policy-map type inspect command

2. Define traffic classes with the class-map type inspect command

4. Apply firewall policies to pairs of source and destination zones with zone-pair security

5. Assign router interfaces to zones using the zone-member security interface command

Page 103: 1 CCNA Security Chapter Four Implementing Firewall Technologies

103103103北京邮电大学思科网络技术学院

Step 1: Create the Zones

Page 104: 1 CCNA Security Chapter Four Implementing Firewall Technologies

104104104北京邮电大学思科网络技术学院

Step 2: Define Traffic Classes

FW(config)# class-map type inspect FOREXAMPLE FW(config-cmap)# match access-group 101FW(config-cmap)# match protocol tcpFW(config-cmap)# match protocol udpFW(config-cmap)# match protocol icmpFW(config-cmap)# exitFW(config)# access-list 101 permit ip 10.0.0.0 0.0.0.255 any

Page 105: 1 CCNA Security Chapter Four Implementing Firewall Technologies

105105105北京邮电大学思科网络技术学院

Step 3: Define Firewall Policies

FW(config)# policy-map type inspect InsideToOutside FW(config-pmap)# class type inspect FOREXAMPLEFW(config-pmap-c)# inspect

Page 106: 1 CCNA Security Chapter Four Implementing Firewall Technologies

106106106北京邮电大学思科网络技术学院

Step 4: Assign Policy Maps to Zone Pairsand Assign Router Interfaces to Zones

Page 107: 1 CCNA Security Chapter Four Implementing Firewall Technologies

107107107北京邮电大学思科网络技术学院

4.4.4 Manually Implementing Zone-basedPolicy Firewall with SDM

• Step 1: Define zones

• Step 2: Configure class maps to describe traffic between zones

• Step 3: Create policy maps to apply actions to the traffic of the class maps

• Step 4: Define zone pairs and assign policy maps to the zone pairs

Page 108: 1 CCNA Security Chapter Four Implementing Firewall Technologies

108108108北京邮电大学思科网络技术学院

Define Zones

1. Choose Configure > Additional Tasks > Zones

2. Click Add

3. Enter a zone name

4. Choose the interfaces for this zone

5. Click OK to create the zone and click OK atthe Commands Delivery Status window

Page 109: 1 CCNA Security Chapter Four Implementing Firewall Technologies

109109109北京邮电大学思科网络技术学院

Configure Class Maps

1. Choose Configure > Additional Tasks > C3PL > Class Map > Inspections

2. Review, create, and edit class maps. To edit a classmap, choose the class map from the list and click Edit

Page 110: 1 CCNA Security Chapter Four Implementing Firewall Technologies

110110110北京邮电大学思科网络技术学院

Create Policy Maps

1. Choose Configure > Additional Tasks > C3PL > Policy Map > Protocol Inspection

2. Click Add

3. Enter a policy name and description

4. Click Add to add a new class map

5. Enter the name of the class mapto apply. Click the down arrow for apop-up menu, if name unknown

6. Choose Pass, Drop, or Inspect

7. Click OK

8. To add another class map, click Add, to modify/delete the actionsof a class map, choose the class map and click Edit/Delete

9. Click OK. At the Command Delivery Status window, click OK

Page 111: 1 CCNA Security Chapter Four Implementing Firewall Technologies

111111111北京邮电大学思科网络技术学院

Define Zone Pairs

1. Choose Configure > Additional Tasks > Zone Pairs

2. Click Add

3. Enter a name for the zone pair. Choose a source zone, a destination zone and a policy

4. Click OK and click OK in the Command Delivery Status window

Page 112: 1 CCNA Security Chapter Four Implementing Firewall Technologies

112112112北京邮电大学思科网络技术学院

4.4.5 Implementing Zone-based PolicyFirewall with SDM Wizard

• Accessing the Basic Firewall Configuration

• Configuring a Firewall

• Basic Firewall Configuration Summary

• Firewall Configuration Summary

Page 113: 1 CCNA Security Chapter Four Implementing Firewall Technologies

113113113北京邮电大学思科网络技术学院

Accessing the Basic Firewall Configuration

1. Choose Configuration > Firewall and ACL

2. Click the Basic Firewall option andclick Launch the Selected Task button

3. Click Next to begin configuration

Page 114: 1 CCNA Security Chapter Four Implementing Firewall Technologies

114114114北京邮电大学思科网络技术学院

Configuring a Firewall

1. Check the outside (untrusted) check box and the inside (trusted) check box to identify each interface

2. (Optional) Check box if the intent is to allow users outside of the firewall to be able to access the router using SDM. After clicking Next, a screen displays that allows the admin to specify a host IP address or network address

3. Click Next. If the Allow Secure SDM Access check box is checked, the Configuring Firewall for Remote Access window appears

4. From the Configuring Firewall choose Network address, Host Ip address or any from the Type drop-down list

Page 115: 1 CCNA Security Chapter Four Implementing Firewall Technologies

115115115北京邮电大学思科网络技术学院

Basic Firewall Security Configuration

1. Select the security level

2. Click the Preview CommandsButton to view the IOS commands

Page 116: 1 CCNA Security Chapter Four Implementing Firewall Technologies

116116116北京邮电大学思科网络技术学院

Firewall Configuration Summary

Click Finish

Page 117: 1 CCNA Security Chapter Four Implementing Firewall Technologies

117117117北京邮电大学思科网络技术学院

4.4.6 Troubleshooting Zone-Based Policy Firewall

• Reviewing Policy

• CLI Generated Output

• Firewall Status Information

• Active Connection

Page 118: 1 CCNA Security Chapter Four Implementing Firewall Technologies

118118118北京邮电大学思科网络技术学院

Reviewing Policy

1. Choose Configure > Firewall and ACL

2. Click Edit Firewall Policy tab

Page 119: 1 CCNA Security Chapter Four Implementing Firewall Technologies

119119119北京邮电大学思科网络技术学院

CLI Generated Output

class-map type inspect match-any iinsprotocols match protocol http match protocol smtp match protocol ftp!policy-map type inspect iinspolicy class type inspect iinsprotocols inspect!zone security privatezone security internet!interface fastethernet 0/0 zone-member security private!interface serial 0/0/0 zone-member security internet!zone-pair security priv-to-internet source private destination internet service-policy type inspect iinspolicy!

List of services

defined in the firewall policy

Apply action (inspect = stateful inspection)

Zones created

Interfaces assigned to zones

Inspection applied from private to public zones

Page 120: 1 CCNA Security Chapter Four Implementing Firewall Technologies

120120120北京邮电大学思科网络技术学院

Firewall Status Information

1. Choose Monitor > Firewall Status

2. Choose one of the following options:•Real-time data every 10 sec•60 minutes of data polled every 1 minute•12 hours of data polled every 12 minutes

Page 121: 1 CCNA Security Chapter Four Implementing Firewall Technologies

121121121北京邮电大学思科网络技术学院

Display Active Connection

Router# show policy-map type inspect zone-pair session

• Shows zone-based policy firewall session statistics

Page 122: 1 CCNA Security Chapter Four Implementing Firewall Technologies

122122122北京邮电大学思科网络技术学院