|
The access service security paradigm presented in this guide uses the authentication, authorization, and accounting (AAA) facility:
This chapter describes how to configure security using a local database resident on the access server or using a remote security database for Terminal Access Controller Access Control System (TACACS+) and Remote Authentication Dial-In User Service (RADIUS). To understand the concept of local versus remote authentication, refer to the section "Local Versus Remote Server Authentication" later in this chapter.
This chapter describes the following specific topics:
This chapter assumes the following:
This section describes the differences between local and remote security databases and the basic authentication process for each. Remote security databases described in this chapter include TACACS+ and RADIUS.
Generally the size of the network and type of corporate security policies and control determines whether you use a local or remote security database.
If you have one or two access servers providing access to your network, you should store username and password security information on the Cisco access server. This is referred to as local authentication. See Figure 4-1.
A local security database is useful if you have very few access servers providing network access. A local security database does not require a separate (and costly) security server.
As your network expands, you need a centralized security database that provides username and password information to each of the access servers on the network. This centralized security database resides in a security server. See Figure 4-2.
An example of a security server is the CiscoSecure product from Cisco Systems. CiscoSecure is a UNIX security daemon, which enables administrators to create databases that define network users and their privileges. CiscoSecure uses a central database that stores user and group profiles with authentication and authorization information.
The Cisco AS5200 exchanges user authentication information with a TACACS+ or RADIUS database on the security server by transmitting encrypted TACACS+ or RADIUS packets across the network.
For specific information about the interaction between security servers and access servers, refer to the Security Configuration Guide. This document is available on the World Wide Web from Cisco's home page, or Documentation CD-ROM that accompanied your access server, or you can order a printed copy.
A remote, centralized security database is useful when you have a large number of access servers providing network access. It prevents having to update each access server with new or changed authentication and authorization information for potentially hundreds of thousands of dial-in network users. A centralized security database also helps establish consistent remote access policies throughout a corporation.
You can use the AAA facility to authenticate users with either a local or a remote security database. Whether you maintain a local or remote security database, or use TACACS+ or RADIUS authentication and authorization, the process of configuring the access server for these different databases and protocols is similar. The basic process of configuring the Cisco IOS software for authentication requires the following tasks:
1. Securing Access to Privileged EXEC and Configuration Mode
2. Communicating Between the Access Server and the Security Server
3. Configuring Authentication on a TACACS+ Server
4. Enabling AAA Globally on the Access Server
5. Defining Authentication Method Lists
6. Applying Authentication Method Lists
The first step is to secure access to privileged EXEC (enable) mode. Enable mode provides access to configuration mode, which enables any type of configuration change to the access server. To secure Privileged EXEC mode, use one of the commands listed in Table 4-1.
For more information about the enable password and enable secret commands and their complete syntax, refer to the Security Command Reference. This document is available on the World Wide Web from Cisco's home page, the Documentation CD-ROM that accompanied your access server, or you can order a printed copy.
To enter an encryption type with the enable secret command, follow the steps listed in Table 4-2.
You can also specify additional protection for privileged EXEC mode, including the following:
For more information about these security tools, refer to the Security Configuration Guide. This document is available on the World Wide Web from Cisco's home page, or Documentation CD-ROM that accompanied your access server, or you can order a printed copy.
This section describes the Cisco IOS software commands that enable the access server to communicate with a security server. This process is similar for communicating with TACACS+ and RADIUS servers.
If you are using local authentication, refer to the section "Enabling AAA Globally on the Access Server," later in this chapter.
If you are using a remote security server for authentication and authorization, you must configure the security server before performing the tasks described in this chapter. The section "Security Examples" at the end of this chapter shows some typical TACACS+ and RADIUS server entries corresponding to the access server security configurations.
To enable communication between the TACACS+ security (database) server and the access server, enter the commands listed in Table 4-3.
For more information about these commands, refer to the Security Command Reference. This document is available on the World Wide Web from Cisco's home page, or the Documentation CD-ROM that accompanied your access server, or you can order a printed copy.
To enable communication between the RADIUS security (database) server and the access server, enter the commands listed in Table 4-4 in global configuration mode.
You can use any of the following optional commands to interact with the RADIUS server host:
This command specifies the number of times that the access server transmits each RADIUS request to the server before the access server gives up.
This command specifies the number of seconds that the access server waits for a reply to a RADIUS request before the access server retransmits the request. The default is 5 seconds. If the RADIUS server's response is slow (because of support for a large number of users or large network latency), increase the timeout value.
For more information about these commands, refer to the Security Command Reference. This document is available on the World Wide Web from Cisco's home page, or Documentation CD-ROM that accompanied your access server, or you can order a printed copy.
On most TACACS+ security servers, there are three ways to authenticate a user for login:
The following is the configuration for global authentication:
To assign different passwords for ARAP, CHAP, and a normal login, you must enter a string for each user. Each string must specify the security protocols, state whether the password is cleartext, and specify if the authentication is performed via a DES card. The following example shows a user aaaa, who has authentication configured for ARAP, CHAP, and login. Her ARAP and CHAP passwords, "arap password" and "chap password," are shown in cleartext. Her login password has been encrypted.
The default authentication is to deny authentication. You can change this at the top level of the configuration file to have the default use password (5) file, by issuing the following command:
On the access server, configure authentication on all lines including the VTY and console lines by entering the following commands, beginning in privileged EXEC mode:
To use the AAA security facility in the Cisco IOS software, you must enter the aaa new-model command from global configuration mode.
When you enter the aaa new-model command, all lines on the access server receive the implicit login authentication default method list, and all interfaces with PPP enabled have an implicit ppp authentication pap default method list applied.
Note Cisco recommends that you use CHAP authentication with PPP, rather than PAP. CHAP passwords are encrypted when they cross the network, whereas PAP passwords are cleartext when they cross the network. The Cisco IOS software selects PAP as the default, so you must manually select CHAP. The process for specifying CHAP is described in the "Applying Authentication Method Lists" section, later in this chapter.
For example, enter the following commands to enable AAA in the Cisco IOS software:
After you enable AAA globally on the access server, you need to define authentication method lists, which you then apply to lines and interfaces. These authentication method lists are security profiles that indicate the protocol (ARAP or PPP) or login and authentication method (TACACS+, RADIUS, or local authentication).
To define an authentication method list, follow these steps:
Step 2 Specify protocol (ARAP or PPP) or login authentication.
Step 3 Identify a list name or default. A list name is any alphanumeric string you choose. You assign different authentication methods to different named lists.
Step 4 Specify the authentication method. You can specify multiple methods, such as tacacs+, followed by local in case a TACACS+ server is not available on the network.
Step 5 Populate the local username database if you specified local as the authentication method (or one of the authentication methods). To use a local username database, you must enter the username global configuration command. Refer to the section "Populate the Local Username Database if Necessary," later in this chapter.
After defining these authentication method lists, apply them to one of the following:
The section "Applying Authentication Method Lists" later in this chapter describes how to apply these lists.
To define an authentication method list, start by entering the aaa authentication global configuration command, as shown in the following example:
After you enter aaa authentication, you must specify one of the following dial-in protocols as applicable for your network:
You can specify only one dial-in protocol per authentication method list. However, you can create multiple authentication method lists with each of these options. You must give each list a different name, as described in the next section "Identify a List Name."
If you specify the ppp option, the default authentication method for PPP is PAP. For greater security, specify CHAP. The full command is aaa authentication ppp chap. If you specify the arap option, the authentication method built into ARA is used. The full command is aaa authentication arap.
For example, if you specify PPP authentication, the configuration looks like this:
A list name identifies each authentication list. You can choose either to use the keyword default, or choose any other name that describes the authentication list. For example, you might give it the name ppp-radius if you intend to apply it to interfaces configured for PPP and RADIUS authentication. The list name can be any alphanumeric string. Use default as the list name for most lines and interfaces, and use different names on an exception basis.
You can create different authentication method lists and apply them to lines and interfaces selectively. You can even create a named authentication method list that you do not apply to a line or interface, but which you intend to apply at some later point, such as when you deploy a new login method for users.
After you define a list name, you must identify additional security attributes (such as local authentication versus TACACS+ or RADIUS).
In the following example, the default authentication method list for PPP dial-in clients uses the local security database:
In the following example, the PPP authentication method list name is insecure:
In the following example, the ARA authentication method list name is callback (because asynchronous callback is used on the access server):
In the following example, the login authentication method list name is cpatino:
After you identify a list name, you must specify an authentication method. An authentication method identifies how users are authenticated. For example, will users be authenticated by a local security database resident on the access server (local method)? Will they be authenticated by a remote security database, such as by a TACACS+ or RADIUS daemon? Will guest access to an AppleTalk network be permitted?
Authentication methods are defined with optional keywords in the aaa authentication command. The available authentication methods for PPP are described in Table 4-5. The available authentication methods for ARA are described in Table 4-6.
Note RADIUS does not support ARA. If you want to authenticate Macintosh users with RADIUS, you must configure AppleTalk to run over PPP, which is referred to as ATCP.
You can specify multiple authentication methods for each authentication list. The following example authentication method list for PPP first queries a TACACS+ server, then a RADIUS server, then the local security database. Multiple authentication methods can be useful if you have multiple types of security servers on the network and one or more types of security servers do not respond:
If you specify more than one authentication method and the first method (TACACS+ in the previous example) is not available, the Cisco IOS software attempts to authenticate using the next method (such as RADIUS). If in the previous example the RADIUS server has no information about the user, or if no RADIUS server can be found, the user is authenticated using the local username database that was populated with the username command.
However, if authentication fails using the first method listed, the Cisco IOS software does not permit access. It does not attempt to authenticate using the subsequent security methods if the user entered the incorrect password.
If you specify local as the security method, you must specify username profiles for each user who might log in. An example of specifying local authentication is as follows:
This command specifies that any time a user attempts to log in to a line on an access server, the Cisco IOS software checks the username database. To create a local username database, define username profiles using the username global configuration command.
The following example shows how to use the username command for a user cpatino with password pwright:
The show running-config command shows the encrypted version of the password, as follows:
Note The Cisco IOS software adds the encryption type of 7 automatically for passwords. If you were to manually enter the number 7 to represent an encryption type, you must follow the 7 with the encrypted version of the password. If you specify the number 7, then enter a cleartext password, the user will not have access to the line, interface, or the network the user is trying to access, and you must reconfigure the user's authentication profile.
This section shows some examples of authentication lists.
The following example creates a local authentication list for users logging in to any line on the access server:
The following example specifies login authentication using RADIUS (the RADIUS daemon is polled for authentication profiles):
The following example specifies login authentication using TACACS+ (the TACACS+ daemon is polled for authentication profiles):
The following example creates a local authentication list for Macintosh users dialing in to an AppleTalk network through the access server:
The following example specifies that Macintosh users dialing in to an AppleTalk network through the access server be authenticated by a TACACS+ daemon:
The following example creates an authentication method list that does the following:
The following example creates a TACACS+ authentication list for users connecting to interfaces configured for dialin using PPP. The name of the list is marketing. This example specifies that a remote TACACS+ daemon be used as the security database. If this security database is not available, the Cisco IOS software then polls the RADIUS daemon. Users are not authenticated if they are already authenticated on a TTY line.
In this example, default can be substituted for marketing if the administrator wants this list to be the default list.
As described in the "Defining Authentication Method Lists" section, the aaa authentication global configuration command creates authentication method lists or profiles. You apply these authentication method lists to lines or interfaces by issuing the login authentication, arap authentication, or ppp authentication command, as described in Table 4-7.
Interface and Line Command | Action | Port to which List is Applied | Corresponding Global Configuration Command |
---|---|---|---|
1If you entered the ppp authentication command, you must specify either CHAP or PAP authentication. PAP is enabled by default, but Cisco recommends that you use CHAP because CHAP is more secure. For more information, refer to the Security Configuration Guide. |
You can create more than one authentication list or profile for login and protocol authentication and apply them to different lines or interfaces. The following examples show the line or interface authentication commands that correspond to the aaa authentication global configuration command.
The following example shows the default login authentication list applied to the console port and the default virtual terminal (VTY) lines on the access server:
In the following example, the login authentication list named rtp2-office, which uses RADIUS authentication, is created. It is applied to all 54 lines on a Cisco AS5200 access server configured with a dual T1 PRI card, including the console (CTY) port, the 48 physical asynchronous (TTY) lines, the auxiliary (AUX) port, and 5 virtual terminal (VTY) lines:
The following sample output shows lines and their status on the access server:
In the following example, the ARA authentication list bldg-d-list is created, then applied to lines 1 through 48 (the physical asynchronous lines) on an access server:
The following example creates the PPP authentication list marketing, which uses TACACS+, then RADIUS authentication. The list marketing requires authentication only if the user has not already been authenticated on another line. It is then applied to asynchronous lines 1 through 48 on an access server and uses CHAP authentication, instead of the default of PAP:
You can configure the access server to restrict user access to the network so that users can only perform certain functions after successful authentication. As with authentication, authorization can be used with either a local or remote security database. This guide describes only remote security server authorization.
A typical configuration most likely uses the EXEC facility and network authorization. EXEC authorization restricts access to the EXEC, and network authorization restricts access to network services, including PPP and ARA.
Authorization must be configured on both the access server and the security daemon. The default authorization is different on the access server and the security server:
You typically have three methods for configuring default authorization on the security server:
1. To override the default denial or authorization from a non-existent user, specify authorization at the top level of the configuration file:
2. At the user level, inside the braces of the user declaration, the default for a user who does not have a service or command explicitly authorized is to deny that service or command. To permit it:
3. At the service authorization level, arguments are processed according to the following algorithm: For each attribute-value (AV) pair sent from the access server, the following process occurs:
(a). If the AV pair from the access server is mandatory, look for an exact match in the daemon's mandatory list. If found, add the AV pair to the output.
(b). If an exact match does not exist, look in the daemon's optional list for the first attribute match. If found, add the access server AV pair to the output.
(c). If no attribute match exists, deny the command if the default is to deny, or if the default is permit, add the access server AV pair to the output.
(d). If the AV pair from the access server is optional, look for an exact AV match in the mandatory list. If found, add the daemon's AV pair to the output.
(e). If not found, look for the first attribute match in the mandatory list. If found, add the daemon's AV pair to the output.
(f). If no mandatory match exists, look for an exact attribute, value pair match among the daemon's optional AV pairs. If found, add the daemon's matching AV pair to the output.
(g). If no exact match exists, locate the first attribute match among the daemon's optional AV pairs. If found, add the daemon's matching AV pair to the output.
(h). If no match is found, delete the AV pair if default is deny, or if the default is permit, add the access server AV pair to the output.
(i). If there is no attribute match already in the output list after all AV pairs have been processed for each mandatory daemon AV pair, add the AV pair (add only one AV pair for each mandatory attribute).
To specify network authorization (preventing unauthorized users from accessing network resources) enter the aaa authorization network command. To restrict users from logging into the EXEC facility, enter the aaa authorization exec command. For example:
Note You can also require authorization before a user can enter specific commands by using the aaa authorization command. For more information, refer to the Security Configuration Guide, which is part of the Cisco IOS configuration guides and command references.
Authorization methods are defined as optional keywords in the aaa authorization command. You can specify any of the authorization methods listed in Table 4-8 for both network and EXEC authorization.
When you configure authorization, you must ensure that the parameters established on the access server correspond with those set on the TACACS+ server.
The following example uses a TACACS+ server to authorize the use of network services, including PPP and ARA. If the TACACS+ server is not available or has no information about a user, no authorization is performed and the user can use all network services:
The following example permits the user to run the EXEC process if the user is already authenticated. If the user is not already authenticated, the Cisco IOS software defers to a RADIUS server for authorization information:
The following example configures network authorization. If the TACACS+ server does not respond or has no information about the username being authorized, the RADIUS server is polled for authorization information for the user. If the RADIUS server does not respond, the user still can access all network resources without authorization requirements.
This series of examples shows complete security configuration components of a configuration file on an access server. Each of these examples shows authentication and authorization.
This sample configuration uses AAA to configure default authentication using a local security database on an access server. All lines and interfaces have the default authentication lists applied. Users aaaa, bbbb, and cccc have been assigned privilege level 7, which prevents them from issuing the ppp, arap, and slip commands, because these commands have been assigned to privilege level 8.
With this configuration, the sign-on dialog from a remote PC appears as follows:
The following example shows how to create and apply authentication lists:
Note The authentication method lists used in this example use names other than default. However, you generally specify default as the list name for most lines and interfaces, and apply different named lists on an exception basis. These names are used only for illustrative purposes.
The following example shows how to create authentication lists:
Posted: Sat Jan 18 23:39:40 PST 2003
All contents are Copyright © 1992--2002 Cisco Systems, Inc. All rights reserved.
Important Notices and Privacy Statement.