Authentication, Authorization, and Accounting
AAA network security services provide the primary framework through which you set up access control on your router. Authentication provides the method of identifying users, including login and password dialog, challenge and response, messaging support, and, depending on the security protocol you choose, encryption. Authorization provides the method for remote access control, including one-time authorization or authorization for each service, per-user account list and profile, user group support, and support of IP, Internetwork Packet Exchange (IPX), AppleTalk Remote Access (ARA), and Telnet. Accounting provides the method for collecting and sending security server information used for billing, auditing, and reporting, such as user identities, start and stop times, executed commands (such as PPP), number of packets, and number of bytes.
AAA uses protocols such as RADIUS, TACACS+, or Kerberos to administer its security functions. If your router is acting as a network access server, AAA is the means through which you establish communication between your network access server and your RADIUS, TACACS+, or Kerberos security server.
For information about configuring AAA services and supported security protocols, see Securing User Services Configuration Guide Library, Cisco IOS Release 12.4T.
Configuring Cisco IOS Firewall
The Cisco IOS Firewall lets you configure a stateful firewall where packets are inspected internally and the state of network connections is monitored. Stateful firewall is superior to static access lists because access lists can only permit or deny traffic based on individual packets, not based on streams of packets. Also, because Cisco IOS Firewall inspects the packets, decisions to permit or deny traffic can be made by examining application layer data, which static access lists cannot examine.
To configure a Cisco IOS Firewall, specify which protocols to examine by using the following command in interface configuration mode:
ip inspect name inspection-name protocol timeout seconds
When inspection detects that the specified protocol is passing through the firewall, a dynamic access list is created to allow the passage of return traffic. The timeout parameter specifies the length of time the dynamic access list remains active without return traffic passing through the router. When the timeout value is reached, the dynamic access list is removed, and subsequent packets (possibly valid ones) are not permitted.
Use the same inspection name in multiple statements to group them into one set of rules. This set of rules can be activated elsewhere in the configuration by using the ip inspect inspection-name in | out command when you configure an interface at the firewall.
For additional information about configuring a Cisco IOS Firewall, see Securing the Data Plane Configuration Guide Library, Cisco IOS Release 12.4.
The Cisco IOS Firewall may also be configured to provide voice security in Session Initiated Protocol (SIP) applications. SIP inspection provides basic inspect functionality (SIP packet inspection and detection of pin-hole openings), as well as protocol conformance and application security. For more information, see Cisco IOS Firewall: SIP Enhancements: ALG and AIC.
Configuring VPN
A virtual private network (VPN) connection provides a secure connection between two networks over a public network such as the Internet. Cisco 819 ISRs support two types of VPNs-site-to-site and remote access. Site-to-site VPNs are used to connect branch offices to corporate offices, for example. Remote access VPNs are used by remote clients to log in to a corporate network. Two examples are given in this section: remote access VPN and site-to-site VPN.
Remote Access VPN
The configuration of a remote access VPN uses Cisco Easy VPN and an IP Security (IPSec) tunnel to configure and secure the connection between the remote client and the corporate network. Figure 9-1 shows a typical deployment scenario.
Figure 9-1 Remote Access VPN Using IPSec Tunnel
|
Remote networked users |
|
VPN client—Cisco 819 access router |
|
Router—Providing the corporate office network access |
|
VPN server—Easy VPN server; for example, a Cisco VPN 3000 concentrator with outside interface address 210.110.101.1 |
|
Corporate office with a network address of 10.1.1.1 |
|
IPSec tunnel |
The Cisco Easy VPN client feature eliminates much of the tedious configuration work by implementing the Cisco Unity Client protocol. This protocol allows most VPN parameters, such as internal IP addresses, internal subnet masks, DHCP server addresses, Windows Internet Naming Service (WINS) server addresses, and split-tunneling flags, to be defined at a VPN server, such as a Cisco VPN 3000 concentrator that is acting as an IPSec server.
A Cisco Easy VPN server–enabled device can terminate VPN tunnels initiated by mobile and remote workers who are running Cisco Easy VPN Remote software on PCs. Cisco Easy VPN server-enabled devices allow remote routers to act as Cisco Easy VPN Remote nodes.
The Cisco Easy VPN client feature can be configured in one of two modes—client mode or network extension mode. Client mode is the default configuration and allows only devices at the client site to access resources at the central site. Resources at the client site are unavailable to the central site. Network extension mode allows users at the central site (where the VPN 3000 series concentrator is located) to access network resources on the client site.
After the IPSec server has been configured, a VPN connection can be created with minimal configuration on an IPSec client, such as a supported Cisco 819 ISR. When the IPSec client initiates the VPN tunnel connection, the IPSec server pushes the IPSec policies to the IPSec client and creates the corresponding VPN tunnel connection.
Note The Cisco Easy VPN client feature supports configuration of only one destination peer. If your application requires the creation of multiple VPN tunnels, you must manually configure the IPSec VPN and Network Address Translation/Peer Address Translation (NAT/PAT) parameters on both the client and the server.
Cisco 819 ISRs can be also configured to act as Cisco Easy VPN servers, letting authorized Cisco Easy VPN clients establish dynamic VPN tunnels to the connected network. For information on the configuration of Cisco Easy VPN servers, see the Easy VPN Server feature document.
Site-to-Site VPN
The configuration of a site-to-site VPN uses IPSec and the generic routing encapsulation (GRE) protocol to secure the connection between the branch office and the corporate network. Figure 9-2 shows a typical deployment scenario.
Figure 9-2 Site-to-Site VPN Using an IPSec Tunnel and GRE
|
Branch office containing multiple LANs and VLANs |
|
Fast Ethernet LAN interface—With address 192.165.0.0/16 (also the inside interface for NAT) |
|
VPN client—Cisco 819 ISR |
|
Fast Ethernet —With address 200.1.1.1 (also the outside interface for NAT) |
|
LAN interface—Connects to the Internet; with outside interface address of 210.110.101.1 |
|
VPN client—Another router, which controls access to the corporate network |
|
LAN interface—Connects to the corporate network, with inside interface address of 10.1.1.1 |
|
Corporate office network |
|
IPSec tunnel with GRE |
For more information about IPSec and GRE configuration, see Secure Connectivity Configuration Guide Library, Cisco IOS Release 12.4T.
Configuration Examples
Each example configures a VPN over an IPSec tunnel, using the procedure given in the “Configure a VPN over an IPSec Tunnel” section. Then, the specific procedure for a remote access configuration is given, followed by the specific procedure for a site-to-site configuration.
The examples shown in this chapter apply only to the endpoint configuration on the Cisco 819 ISRs. Any VPN connection requires both endpoints to be configured properly to function. See the software configuration documentation as needed to configure VPN for other router models.
VPN configuration information must be configured on both endpoints. You must specify parameters, such as internal IP addresses, internal subnet masks, DHCP server addresses, and Network Address Translation (NAT).
Configure a VPN over an IPSec Tunnel
Perform the following tasks to configure a VPN over an IPSec tunnel:
Configure the IKE Policy
To configure the Internet Key Exchange (IKE) policy, perform these steps, beginning in global configuration mode:
SUMMARY STEPS
1. crypto isakmp policy priority
2. encryption {des | 3des | aes | aes 192 | aes 256}
3. hash {md5 | sha}
4. authentication {rsa-sig | rsa-encr | pre-share}
5. group {1 | 2 | 5}
6. lifetime seconds
7. exit
DETAILED STEPS
|
|
|
Step 1 |
crypto isakmp policy priority Example: Router(config)# crypto isakmp policy 1 Router(config-isakmp)#
|
Creates an IKE policy that is used during IKE negotiation. The priority is a number from 1 to 10000, with 1 being the highest. Also enters the Internet Security Association Key and Management Protocol (ISAKMP) policy configuration mode. |
Step 2 |
encryption {des | 3des | aes | aes 192 | aes 256} Example: Router(config-isakmp)# encryption 3des Router(config-isakmp)#
|
Specifies the encryption algorithm used in the IKE policy. The example specifies 168-bit data encryption standard (DES). |
Step 3 |
hash {md5 | sha} Example: Router(config-isakmp)# hash md5 Router(config-isakmp)#
|
Specifies the hash algorithm used in the IKE policy. The example specifies the Message Digest 5 (MD5) algorithm. The default is Secure Hash standard (SHA-1). |
Step 4 |
authentication {rsa-sig | rsa-encr | pre-share} Example: Router(config-isakmp)# authentication pre-share Router(config-isakmp)#
|
Specifies the authentication method used in the IKE policy. The example specifies a pre-shared key. |
Step 5 |
group {1 | 2 | 5} Example: Router(config-isakmp)# group 2 Router(config-isakmp)#
|
Specifies the Diffie-Hellman group to be used in an IKE policy. |
Step 6 |
lifetime seconds Example:
Router(config-isakmp)# lifetime 480
|
Specifies the lifetime, from 60 to 86400 seconds, for an IKE security association (SA). |
Step 7 |
exit Example: Router(config-isakmp)# exit Router(config)#
|
Exits IKE policy configuration mode and enters global configuration mode. |
Configure Group Policy Information
To configure the group policy, perform these steps, beginning in global configuration mode:
SUMMARY STEPS
1. crypto isakmp client configuration group {group-name | default}
2. key name
3. dns primary-server
4. domain name
5. exit
6. ip local pool {default | poolname } [ low-ip-address [ high-ip-address ]]
DETAILED STEPS
|
|
|
Step 1 |
crypto isakmp client configuration group { group-name | default } Example:
Router(config)# crypto isakmp client configuration group rtr-remote
Router(config-isakmp-group)#
|
Creates an IKE policy group containing attributes to be downloaded to the remote client. Also enters the Internet Security Association Key and Management Protocol (ISAKMP) group policy configuration mode. |
Step 2 |
key name Example:
Router(config-isakmp-group)# key secret-password
Router(config-isakmp-group)#
|
Specifies the IKE pre-shared key for the group policy. |
Step 3 |
dns primary-server Example:
Router(config-isakmp-group)# dns 10.50.10.1
Router(config-isakmp-group)#
|
Specifies the primary Domain Name System (DNS) server for the group. You may also want to specify Windows Internet Naming Service (WINS) servers for the group by using the wins command. |
Step 4 |
domain name Example:
Router(config-isakmp-group)# domain company.com
Router(config-isakmp-group)#
|
Specifies group domain membership. |
Step 5 |
exit Example:
Router(config-isakmp-group)# exit
|
Exits IKE group policy configuration mode and enters global configuration mode. |
Step 6 |
ip local pool { default | pool name} [low-ip-address {high-ip-address]] Example:
Router(config)# ip local pool dynpool 30.30.30.20 30.30.30.30
|
Specifies a local address pool for the group. For details about this command and additional parameters that can be set, see Cisco IOS Dial Technologies Command Reference. |
Apply Mode Configuration to the Crypto Map
To apply mode configuration to the crypto map, perform these steps, beginning in global configuration mode:
SUMMARY STEPS
1. crypto map map-name isakmp authorization list list-name
2. crypto map tag client configuration address [initiate | respond]
DETAILED STEPS
|
|
|
Step 1 |
crypto map map-name isakmp authorization list list-name Example:
Router(config)# crypto map dynmap isakmp authorization list rtr-remote
|
Applies mode configuration to the crypto map and enables key lookup (IKE queries) for the group policy from an authentication, authorization, and accounting (AAA) server. |
Step 2 |
crypto map tag client configuration address [initiate | respond] Example:
Router(config)# crypto map dynmap client configuration address respond
|
Configures the router to reply to mode configuration requests from remote clients. |
Enable Policy Lookup
To enable policy lookup through AAA, perform these steps, beginning in global configuration mode:
SUMMARY STEPS
1. aaa new-model
2. aaa authentication login {default | list-name } method1 [ method2 ...]
3. aaa authorization {network | exec | commands level | reverse-access | configuration} {default | list-name } [ method1 [ method2 ...]]
4. username name {no password | password password | password encryption-type encrypted-password }
Configure IPSec Transforms and Protocols
A transform set represents a certain combination of security protocols and algorithms. During IKE negotiation, the peers agree to use a particular transform set for protecting data flow.
During IKE negotiations, the peers search in multiple transform sets for a transform that is the same at both peers. When a transform set that contains such a transform is found, it is selected and applied to the protected traffic as a part of both peers’ configurations.
To specify the IPSec transform set and protocols, perform these steps, beginning in global configuration mode:
SUMMARY STEPS
1. crypto ipsec profile profile-name
2. crypto ipsec transform-set transform-set-name transform1 [ transform2 ] [ transform3 ] [ transform4 ]
3. crypto ipsec security-association lifetime {seconds seconds | kilobytes kilobytes }
DETAILED STEPS
|
|
|
Step 1 |
crypto ipsec profile profile-name Example:
Router(config)# crypto ipsec profile pro1
|
Configures IPSec profile to apply protection on the tunnel for encryption. |
Step 2 |
crypto ipsec transform-set transform-set-name transform1 [transform2] [transform3] [transform4] Example:
Router(config)# crypto ipsec transform-set vpn1 esp-3des esp-sha-hmac
|
Defines a transform set—an acceptable combination of IPSec security protocols and algorithms. See Secure Connectivity Configuration Guide Library, Cisco IOS Release 12.4T for details about the valid transforms and combinations. |
Step 3 |
crypto ipsec security-association lifetime {seconds seconds | kilobytes kilobytes} Example:
Router(config)# crypto ipsec security-association lifetime seconds 86400
|
Specifies global lifetime values used when IPSec security associations are negotiated. |
Configure the IPSec Crypto Method and Parameters
A dynamic crypto map policy processes negotiation requests for new security associations from remote IPSec peers, even if the router does not know all the crypto map parameters (for example, IP address).
To configure the IPSec crypto method, perform these steps, beginning in global configuration mode:
SUMMARY STEPS
1. crypto dynamic-map dynamic-map-name dynamic-seq-num
2. set transform-set transform-set-name [ transform-set-name2...transform-set-name6 ]
3. reverse-route
4. exit
5. crypto map map-name seq-num [ipsec-isakmp] [dynamic dynamic-map-name] [discover] [profile profile-name]
DETAILED STEPS
|
|
|
Step 1 |
crypto dynamic-map dynamic-map-name dynamic-seq-num Example:
Router(config)# crypto dynamic-map dynmap 1
Router(config-crypto-map)#
|
Creates a dynamic crypto map entry and enters crypto map configuration mode. See Cisco IOS Security Command Reference for more details about this command. |
Step 2 |
set transform-set transform-set-name [transform-set-name2...transform-set-name6] Example:
Router(config-crypto-map)# set transform-set vpn1
Router(config-crypto-map)#
|
Specifies which transform sets can be used with the crypto map entry. |
Step 3 |
reverse-route Example:
Router(config-crypto-map)# reverse-route
Router(config-crypto-map)#
|
Creates source proxy information for the crypto map entry. See Cisco IOS Security Command Reference for details. |
Step 4 |
exit Example:
Router(config-crypto-map)# exit
|
Returns to global configuration mode. |
Step 5 |
crypto map map-name seq-num [ipsec-isakmp] [dynamic dynamic-map-name] [discover] [profile profile-name] Example:
Router(config)# crypto map static-map 1 ipsec-isakmp dynamic dynmap
|
Creates a crypto map profile. |
Apply the Crypto Map to the Physical Interface
The crypto maps must be applied to each interface through which IPSec traffic flows. Applying the crypto map to the physical interface instructs the router to evaluate all the traffic against the security associations database. With the default configurations, the router provides secure connectivity by encrypting the traffic sent between remote sites. However, the public interface still allows the rest of the traffic to pass and provides connectivity to the Internet.
To apply a crypto map to an interface, perform these steps, beginning in global configuration mode:
SUMMARY STEPS
1. interface type number
2. crypto map map-name
3. exit
DETAILED STEPS
|
|
|
Step 1 |
interface type number Example:
Router(config)# interface fastethernet 4
|
Enters the interface configuration mode for the interface to which you want the crypto map applied. |
Step 2 |
crypto map map-name Example:
Router(config-if)# crypto map static-map
|
Applies the crypto map to the interface. See Cisco IOS Security Command Reference for more details about this command. |
Step 3 |
exit Example:
Router(config-crypto-map)# exit
|
Returns to global configuration mode. |
Create a Cisco Easy VPN Remote Configuration
The router acting as the Cisco Easy VPN client must create a Cisco Easy VPN remote configuration and assign it to the outgoing interface.
To create the remote configuration, perform these steps, beginning in global configuration mode:
SUMMARY STEPS
1. crypto ipsec client ezvpn name
2. group group-name key group-key
3. peer { ip address | hostname }
4. mode {client | network-extension | network extension plus}
5. exit
6. crypto isakmp keepalive seconds
7. interface type number
8. crypto ipsec client ezvpn name [outside | inside]
9. exit
DETAILED STEPS
|
|
|
Step 1 |
crypto ipsec client ezvpn name Example:
Router(config)# crypto ipsec client ezvpn ezvpnclient
Router(config-crypto-ezvpn)#
|
Creates a Cisco Easy VPN remote configuration and enters Cisco Easy VPN remote configuration mode. |
Step 2 |
group group-name key group-key Example:
Router(config-crypto-ezvpn)# group ezvpnclient key secret-password
Router(config-crypto-ezvpn)#
|
Specifies the IPSec group and IPSec key value for the VPN connection. |
Step 3 |
peer {ip address | hostname} Example:
Router(config-crypto-ezvpn)# peer 192.168.100.1
Router(config-crypto-ezvpn)#
|
Specifies the peer IP address or hostname for the VPN connection. Note A hostname can be specified only when the router has a DNS server available for hostname resolution. Note Use this command to configure multiple peers for use as backup. If one peer goes down, the Easy VPN tunnel is established with the second available peer. When the primary peer comes up again, the tunnel is re-established with the primary peer. |
Step 4 |
mode {client | network-extension | network extension plus} Example:
Router(config-crypto-ezvpn)# mode client
Router(config-crypto-ezvpn)#
|
Specifies the VPN mode of operation. |
Step 5 |
exit Example:
Router(config-crypto-ezvpn)# exit
|
Returns to global configuration mode. |
Step 6 |
crypto isakmp keepalive seconds Example:
Router(config-crypto-ezvpn)# crypto isakmp keepalive 10
|
Enables dead peer detection messages. Time between messages is given in seconds, with a range of 10 to 3600. |
Step 7 |
interface type number Example:
Router(config)# interface fastethernet 4
|
Enters the interface configuration mode for the interface to which you want the Cisco Easy VPN remote configuration applied. Note For routers with an ATM WAN interface, this command would be interface atm 0. |
Step 8 |
crypto ipsec client ezvpn name [outside | inside] Example:
Router(config-if)# crypto ipsec client ezvpn ezvpnclient outside
|
Assigns the Cisco Easy VPN remote configuration to the WAN interface, causing the router to automatically create the NAT or port address translation (PAT) and access list configuration needed for the VPN connection. |
Step 9 |
exit Example:
Router(config-crypto-ezvpn)# exit
|
Returns to global configuration mode. |
Configuration Example
The following configuration example shows a portion of the configuration file for the VPN and IPSec tunnel described in this chapter:
aaa authentication login rtr-remote local
aaa authorization network rtr-remote local
username Cisco password 0 Cisco
crypto isakmp client configuration group rtr-remote
dns 10.50.10.1 10.60.10.1
crypto ipsec transform-set vpn1 esp-3des esp-sha-hmac
crypto ipsec security-association lifetime seconds 86400
crypto dynamic-map dynmap 1
crypto map static-map 1 ipsec-isakmp dynamic dynmap
crypto map dynmap isakmp authorization list rtr-remote
crypto map dynmap client configuration address respond
crypto ipsec client ezvpn ezvpnclient
group 2 key secret-password
crypto ipsec client ezvpn ezvpnclient outside
crypto ipsec client ezvpn ezvpnclient inside
Configure a Site-to-Site GRE Tunnel
To configure a GRE tunnel, perform these steps, beginning in global configuration mode:
SUMMARY STEPS
1. interface type number
2. ip address ip-address mask
3. tunnel source interface-type number
4. tunnel destination default-gateway-ip-address
5. crypto map map-name
6. exit
7. ip access-list {standard | extended} access-list-name
8. permit protocol source source-wildcard destination destination-wildcard
9. exit
DETAILED STEPS
|
|
|
Step 1 |
interface type number Example:
Router(config)# interface tunnel 1
|
Creates a tunnel interface and enters interface configuration mode. |
Step 2 |
ip address ip-address mask Example:
Router(config-if)# 10.62.1.193 255.255.255.252
|
Assigns an address to the tunnel. |
Step 3 |
tunnel source interface-type number Example:
Router(config-if)# tunnel source fastethernet 0
|
Specifies the source endpoint of the router for the GRE tunnel. |
Step 4 |
tunnel destination default-gateway-ip-address Example:
Router(config-if)# tunnel destination 192.168.101.1
|
Specifies the destination endpoint of the router for the GRE tunnel. |
Step 5 |
crypto map map-name Example:
Router(config-if)# crypto map static-map
|
Assigns a crypto map to the tunnel. Note Dynamic routing or static routes to the tunnel interface must be configured to establish connectivity between the sites. |
Step 6 |
exit Example:
|
Exits interface configuration mode and returns to global configuration mode. |
Step 7 |
ip access-list {standard | extended} access-list-name Example:
Router(config)# ip access-list extended vpnstatic1
|
Enters ACL configuration mode for the named ACL that is used by the crypto map. |
Step 8 |
permit protocol source source-wildcard destination destination-wildcard Example:
Router(config-acl)# permit gre host 192.168.100.1 host 192.168.101.1
|
Specifies that only GRE traffic is permitted on the outbound interface. |
Step 9 |
exit Example:
|
Returns to global configuration mode. |
Configuration Example
The following configuration example shows a portion of the configuration file for a VPN using a GRE tunnel scenario described in the preceding sections:
aaa authentication login rtr-remote local
aaa authorization network rtr-remote local
username cisco password 0 cisco
ip address 10.62.1.193 255.255.255.252
tunnel source fastethernet 0
tunnel destination interface 192.168.101.1
ip route 20.20.20.0 255.255.255.0 tunnel 1
crypto isakmp client configuration group rtr-remote
dns 10.50.10.1 10.60.10.1
crypto ipsec transform-set vpn1 esp-3des esp-sha-hmac
crypto ipsec security-association lifetime seconds 86400
crypto dynamic-map dynmap 1
crypto map static-map 1 ipsec-isakmp dynamic dynmap
crypto map dynmap isakmp authorization list rtr-remote
crypto map dynmap client configuration address respond
! Defines the key association and authentication for IPsec tunnel.
crypto isakmp key cisco123 address 200.1.1.1
! Defines encryption and transform set for the IPsec tunnel.
crypto ipsec transform-set set1 esp-3des esp-md5-hmac
! Associates all crypto values and peering address for the IPsec tunnel.
crypto map to_corporate 1 ipsec-isakmp
! VLAN 1 is the internal home network.
ip address 10.1.1.1 255.255.255.0
ip inspect firewall in ! Inspection examines outbound traffic.
! FE4 is the outside or Internet-exposed interface
ip address 210.110.101.21 255.255.255.0
! acl 103 permits IPsec traffic from the corp. router as well as
! denies Internet-initiated traffic inbound.
crypto map to_corporate ! Applies the IPsec tunnel to the outside interface.
! Utilize NAT overload in order to make best use of the
! single address provided by the ISP.
ip nat inside source list 102 interface Ethernet1 overload
ip route 0.0.0.0 0.0.0.0 210.110.101.1
! acl 102 associated addresses used for NAT.
access-list 102 permit ip 10.1.1.0 0.0.0.255 any
! acl 103 defines traffic allowed from the peer for the IPsec tunnel.
access-list 103 permit udp host 200.1.1.1 any eq isakmp
access-list 103 permit udp host 200.1.1.1 eq isakmp any
access-list 103 permit esp host 200.1.1.1 any
! Allow ICMP for debugging but should be disabled because of security implications.
access-list 103 permit icmp any any
access-list 103 deny ip any any ! Prevents Internet-initiated traffic inbound.
! acl 105 matches addresses for the IPsec tunnel to or from the corporate network.
access-list 105 permit ip 10.1.1.0 0.0.0.255 192.168.0.0 0.0.255.255