Palo Alto Networks Management Access through TACACS

Palo Alto Networks Management Access through TACACS

81761
Created On 09/25/18 17:36 PM - Last Modified 04/21/20 00:46 AM


Symptom


Prior to PAN-OS 8.0, TACACS was limited to Authentication Only. If you wanted to authenticate against a TACACS server to log in to the web interface or CLI, you had to create the same admin accounts on the Palo Alto Networks device. This doesn't scale well and it's additional overhead, especially in large or dynamic environments. Hence, with the launch of PAN-OS 8.0, TACACS has been enhanced to use the Authorization from the TACACS server.

Resolution


You no longer need to create admins locally, just the admin roles. Follow the below steps to achieve this.

STEP 1: Create a TACACS server profile and an Authentication profile. Then, add this profile in the Authentication settings.
Screenshot of a TACACS server profile

Screenshot of Auth profile


Screenshot of TAC auth

Call the previously created authentication profile in this section



STEP 2: Create admin roles as per your requirement.

Screenshot of admin roles

Custom role with limited access

Screenshot of my_custom_role

Sample permissions for this custom role



STEP 3: TACACS server side-configuration is next. I used Cisco ACS in this example.
Screenshot of Admins accounts on ACS

Two example users created an ACS.

NOTE: Customer Attributes for the firewall and Panorama are different. Below are some of the attributes you need to configure.
Service: paloalto (required)
Protocol: firewall (required)

Firewall: PaloAlto-Admin-Role
Panorama:  PaloAlto-Panorama-Admin-Role

Reference the following link for additional details:

https://docs.paloaltonetworks.com/pan-os/9-0/pan-os-admin/authentication/authentication-types/tacacs

Example shown in screenshots below are for firewalls. 

This attribute gives admin level privileges, as per the custom admin defined on PA, to a successfully authenticating admin user.

Screenshot of custom user shell profile

This gives ‘superuser’ privileges to the user. However, you can replace the value to be any of the pre-defined values (or even a custom value, as illustrated above).
Screenshot of superuser shell profile

Tailor the rules to match the users with their respective shell profiles.
Screenshot of rules


STEP 4: If everything is configured correctly, you should see successful logins.

Superuser has access to everything
Screenshot of TAC superuser log in

Notice the limited access for this custom user
Screenshot of TAC custom user log in

System logs showing logins for both admins

Screenshot of combined System log

Troubleshooting

The Palo Alto Networks firewall, by default, uses the management interface to communicate with the TACACS server. However, you can change this to any interface under Service route configuration (Device tab).
Screenshot of service route

– You can also check the connectivity, authentication and the attributes passed, with this test command:
admin@anuragFW> test authentication authentication-profile TACauth username TACsuperuser password
Enter password :

Target vsys is not specified, user "TACsuperuser" is assumed to be configured with a shared auth profile.

Do allow list check before sending out authentication request...
name "TACsuperuser" is in group "all"

Authentication to TACACS+ server at '10.21.56.103' for user 'TACsuperuser'
Server port: 49, timeout: 3, flag: 0
Egress: 10.21.56.125
Attempting PAP authentication ...
PAP authentication request is created
PAP authentication request is sent
Authorization request is created
Authorization request sent with priv_lvl=1 user=TACsuperuser service=PaloAlto protocol=firewall
Authorization succeeded
Number of VSA returned: 1
 VSA[0]: PaloAlto-Admin-Role=superuser
Authentication succeeded!

Authentication succeeded for user "TACsuperuser"



Sometimes the issue is on the server side, so check the logs on the TACACS server too. If you need to decrypt the TACACS packets to view the content, you can decrypt it on Wireshark.
Screenshot of decrypt

Enter the shared secret in the box

It's always a good idea to check the authd.log file (ideally in debug mode) when you are troubleshooting authentication related issues.

 



Additional Information


In the example above, I only used the attribute for granting admin access on the firewall. There are other attributes, however, available for you to implement different access on the firewall and Panorama.

Please refer to TACACS attributes.

RADIUS can also provide the same functionality, should you choose RADIUS over TACACS. Please refer to RADIUS with Windows NPS or RADIUS with ACS


Actions
  • Print
  • Copy Link

    https://knowledgebase.paloaltonetworks.com/KCSArticleDetail?id=kA10g000000ClH7CAK&refURL=http%3A%2F%2Fknowledgebase.paloaltonetworks.com%2FKCSArticleDetail

Choose Language