(SRX) How To Configure TACACS+ Authentication On SRX Platforms
(SRX) How To Configure TACACS+ Authentication On SRX Platforms
Description
This article provides information on how to set up the SRX platforms to use TACACS+ authentication.
Symptoms
Assuming that the TACACS+ authentication server is already deployed, the process is divided into three steps:
I. Configure the TACACS+ authentication on the SRX device.
II. Create a local user template for TACACS+ authenticated users to inherit the privileges from.
III. Map the local user template to the TACACS+ user accounts (optional).
Solution
Note: For more options, such as specifying port number, source address, and so on, refer to Configuring
TACACS+ Authentication
2. Change the authentication order of the SRX device to use TACACS+ first:
Step II: Create a local user template for the TACACS+ authenticated users to inherit the privileges from :
When you are using TACACS+ authentication, you can create single accounts for authorization purposes,
which are shared by a set of users. You can create these accounts by using the remote and local user template
accounts. When a user is using a template account, the command-line interface (CLI) username is the login
name; however, the privileges, file ownership, and effective user ID are inherited from the template account.
A remote user template is defined by the remote user name under [system login] . A local user template can be
https://supportportal.juniper.net/s/article/SRX-How-to-configure-TACACS-authentication-on-SRX-platforms?language=en_US 1/5
8/16/22, 10:24 AM [SRX] How to configure TACACS+ authentication on SRX platforms
of any name. The difference between a normal user account and a user template on the SRX device is that the
user template does not have a password specified. By default, Junos OS uses remote template accounts for user
authorization when:
The authenticated user does not exist locally on the router or switch.
The authenticated user’s record in the authentication server specifies local user; but it does not exist
locally on the router or switch.
To configure the remote template account, include the user remote statement at the [edit system login]
hierarchy level and specify the privileges, which you want to grant to remote users:
user remote {
For example, to create the default remote account that maps to TACACS+ authenticated users and assign them
to the operator class, type the following line in the configuration:
set system login user remote full-name "All remote users" uid 2012 class
operator
Step III: Map the local user template to the TACACS+ user accounts (optional) :
If you want to have more granularity for the privileges allowed for different subsets of TACACS+ users, you can
define different local user templates on the SRX device and configure the TACACS+ server to return the
vendor-specific attribute ( local-user-name ) with the matching user template name. For example, you want to
have two user templates, one for super-use privileges and the other for view-only, you can specify this in the
configuration:
set system login user remote-super-users full-name "User template for remote
super-users" uid 2013 class super-user
set system login user remote-read-only full-name "User template for remote read-
only" uid 2014 class read-only
On the TACACS+ side, for example, you want to give User1 super-user privileges and User2 read-only
privileges, the TACACS+ configuration would look similar to the following one:
https://supportportal.juniper.net/s/article/SRX-How-to-configure-TACACS-authentication-on-SRX-platforms?language=en_US 2/5
8/16/22, 10:24 AM [SRX] How to configure TACACS+ authentication on SRX platforms
user = User1 {
user = User2 {
Example :
The following snipped is from the TACACS+ authentication configuration on both the SRX device and the
TACACS+ server. It highlights the differences between the remote and local user template and how they relate
to each other:
SRX Configuration :
set system login user remote full-name "Default remote user template"
set system login user remote-su full-name "Remote users with super-user
privileges"
TACACS+ Configuration :
https://supportportal.juniper.net/s/article/SRX-How-to-configure-TACACS-authentication-on-SRX-platforms?language=en_US 3/5
8/16/22, 10:24 AM [SRX] How to configure TACACS+ authentication on SRX platforms
key = <password>
user = User1 {
# User2 is set to inherit super-user privileges on the SRX device and is therefor
user = User2 {
service = junos-exec {
local-user-name = remote-su
Permissions:
Permissions:
https://supportportal.juniper.net/s/article/SRX-How-to-configure-TACACS-authentication-on-SRX-platforms?language=en_US 4/5
8/16/22, 10:24 AM [SRX] How to configure TACACS+ authentication on SRX platforms
Configuring TACACS+ Authentication
Configuring Remote Template Accounts for User Authentication
Configuring Local User Template Accounts for User Authentication
Modification History
2020-02-20: Removed EOS J-series references
Related Information
Configuring TACACS+ Authentication
https://supportportal.juniper.net/s/article/SRX-How-to-configure-TACACS-authentication-on-SRX-platforms?language=en_US 5/5