TACACS+ Commands
Use these M4500 CLI commands to configure TACACS+ servers, keys, ports, priorities, timeouts, and source interface, and display TACACS+ settings.
TACACS+ provides access control for networked devices via one or more centralized servers. Similar to RADIUS, this protocol simplifies authentication by making use of a single database that can be shared by many clients on a large network. TACACS+ is based on the TACACS protocol (described in RFC1492) but additionally provides for separate authentication, authorization, and accounting services. The original protocol was UDP based with messages passed in clear text over the network; TACACS+ uses TCP to ensure reliable delivery and a shared key configured on the client and daemon server to encrypt all messages.
show tacacs
This command displays configured information and statistics of a TACACS+ server.
| Format | show tacacs [<ip-address | hostname>] |
| Mode | Privileged EXEC |
Display Message
| Parameter | Definition |
|---|---|
| Host address | The IP address or hostname of the configured TACACS+ server. |
| Port | Shows the configured TACACS+ server port number. |
| Timeout | Shows the timeout in seconds for establishing a TCP connection. |
| Priority | Shows the preference order in which TACACS+ servers are contacted. If a server connection fails, the next highest priority server is contacted. |
| Link Local Interface | Shows the outgoing interface used by the link-local address |
Example: The following shows an example of the command.
(M4500-32C) (Config)#show tacacs
Global Timeout: 10
Host address Port Timeout Priority
--------------------- ------ ------- --------
10.0.0.1 49 Global 0
show tacacs source-interface
Use the show tacacs source-interface command in Global Config mode to display the configured global source interface details used for a TACACS+ client. The IP address of the selected interface is used as source IP for all communications with the server.
| Format | show tacacs source-interface |
| Mode | Privileged EXEC |
Display Message
| Parameter | Definition |
|---|---|
| TACACS Client Source Interface | The interface to use as the source interface for TACACS client. |
| TACACS Client Source IPv4 Address | The IP address of the interface configured as the TACACS client source interface. |
| TACACS Client Source IPv6 Address | The IPv6 address of the interface configured as the TACACS client source interface. |
tacacs-server host
Use the tacacs-server host command in Global Configuration mode to configure a TACACS+ server. This command enters into the TACACS+ configuration mode. The ipaddr|hostname parameter is the IPv4 or IPv6 address or hostname of the TACACS+ server. To specify multiple hosts, multiple tacacs-server host commands can be used.
| Format | tacacs-server host <ipaddress | ipv6-address | hostname> |
| Mode | Global Config |
no tacacs-server host
This command deletes the specified hostname or IP address.
| Format | no tacacs-server host <ip-address | ipv6-address | hostname> |
| Mode | Global Config |
tacacs-server host link-local
Use the tacacs-server host link-local command in Global Configuration mode to configure the link-local-address of the TACACS+ server and the outgoing interface to be used by the TACACS+ client to communicate with the TACACS+ server. The outgoing interface can be any physical interface or the service port.
| Format | tacacs-server host link-local <link-local-address> interface {serviceport | <slot/port>} |
| Mode | Global Config |
no tacacs-server host link-local
This command revmoes the configured TACACS+ server link-local address.
| Format | no tacacs-server host link-local <link-local-address> |
| Mode | Global Config |
tacacs-server key
This command is used to configure the TACACS+ authentication and encryption key. You can configure the format of the key in two ways:
- Type the key keyword to configure the key in plain text. The key is displayed with * for each character that you type. The key must be in alphanumeric characters with a maximum length of 128 characters.
- Type the key encrypted keyword to configure the key in encrypted form. The <key-string> argument must be in hexadecimal digits with a length of 256 characters.
| Format | tacacs-server key [encrypted <key-string>] |
| Mode | Global Config |
no tacacs-server key
This command removes the TACACS+ server secret key.
| Format | no tacacs-server key |
| Mode | Global Config |
tacacs-server keystring
This command is used to set the global authentication encryption key used for all TACACS+ communications between the TACACS+ server and the client.
| Format | tacacs-server keysting |
| Mode | Global Config |
Example: The following shows an example of the command.
(M4500-32C) # tacacs-server keystring
Enter key:**********
Re-enter key:**********
tacacs-server timeout
This command is used to configure the timeout value for communication with the TACACS+ servers. The timeout parameter has a range of 1 to 30 seconds. If you do not specify a timeout value, the command sets the global timeout to the default value. TACACS+ servers that do not use the global timeout will retain their configured timeout values.
| Default | 10 |
| Format | tacacs-server timeout [<timeout>] |
| Mode | Global Config |
no tacacs-server timeout
This command restores the default timeout value for all TACACS+ servers.
| Format | no tacacs-server timeout |
| Mode | Global Config |
key
This command is used to configure the TACACS+ authentication and encryption key. You can configure the format of the key in two ways:
- Type the key keyword to configure the key in plain text. The key is displayed with * for each character that you type. The key must be in alphanumeric characters with a maximum length of 128 characters.
- Type the key encrypted keyword to configure the key in encrypted form. The <key-string> argument must be in hexadecimal digits with a length of 256 characters.
| Format | key [encrypted <key-string>] |
| Mode | TACACS server Config |
no key
This command removes the TACACS+ server secret key.
| Format | no key |
| Mode | TACACS server Config |
keystring
This command is used to set the TACACS+ server-specific authentication encryption key used for all TACACS+ communications between the TACACS+ server and the client.
| Format | keysting |
| Mode | TACACS server Config |
port
This command is used to set the TACACS+ server-specific port number. The server port-number range is 0 to 65535.
| Default | 49 |
| Format | port [<port-number>] |
| Mode | TACACS server Config |
no port
This command set the TACACS+ server-specific port to default.
| Format | no port |
| Mode | TACACS server Config |
priority
This command is used to set the TACACS+ server-specific authentication host priority. The server priority range is 0 to 65535.
| Default | 0 |
| Format | priority [<priority>] |
| Mode | TACACS server Config |
no priority
This command set the TACACS+ server-specific authentication host priority to default.
| Format | no priority |
| Mode | TACACS server Config |
timeout
This command is used to configure the timeout value for communication with the TACACS+ servers. The timeout parameter has a range of 1 to 30 seconds.
| Default | 10 |
| Format | timeout [<timeout>] |
| Mode | TACACS server Config |
no timeout
This command set the timeout value for communication with the TACACS+ servers to default.
| Format | no timeout |
| Mode | TACACS server Config |
tacacs-server source-interface
Use this command in Global config mode to configure the source interface (Source IP address) for TACACS+ server configuration. The selected source-interface IP address is used for filling the IP header of management protocol packets. This allows security devices (firewalls) to identify the source packets coming from the specific switch.
If a source-interface is not specified, the primary IP address of the originating (outbound) interface is used as the source address.
| Format | tacacs-server source-interface {<slot/port> | loopback <loopback-id> | serviceport | tunnel <tunnel- |
id> | vlan <vlan-id>}
| Parameter | Definition |
|---|---|
| slot/port | Specifies the interface to use as the source interface. |
| loopback-id | Specifies the loopback interface to use as the source interface. The range of the loopback ID is 0 to 63. |
| tunnel-id | Specifies the tunnel interface to use as the source interface. The range of the tunnel ID is 0 to 7. |
| vlan-id | Specifies the VLAN interface to use as the source interface. The range of VLAN ID is 1 to 4093. |
| Default | None |
| Mode | Global Config |
no tacacs-server source-interface
Use this command in Global Configuration mode to remove the global source interface (Source IP selection) for all TACACS+ communications between the TACACS+ client and the server.
| Format | no tacacs-server source-interface |
| Mode | Global Config |
clear tacacs
This command clears the TACACS configuration.
| Format | clear tacacs |
| Mode | Privileged Exec |
Example:
(M4500-32C) # clear tacacs
Are you sure you want to clear TACACS information? (y/n)y
No TACACS servers configured.