Script for exporting Prisma Cloud policies and their associated RQL into a CSV output file.

RedLock policy export

Version: 1.0 Author: Eddie Beuerlein


This script will create a csv file that contains the policy data from the RedLock UI.

Requirements and Dependencies

  1. Python 2.7.10 or newer

  2. OpenSSL 1.0.2 or newer

(if using on Mac OS, additional items may be nessessary.)

  1. Pip

sudo easy_install pip

  1. Requests (Python library)

sudo pip install requests

  1. YAML (Python library)

sudo pip install pyyaml


  1. Navigate to export_policies_csv/config/configs.yml

  2. Fill out your RedLock username, password, and customer name - if you are the only customer in your account then leave this blank.


python runner.py

This template/solution is released under an as-is, best effort, support policy. These scripts should be seen as community supported and Palo Alto Networks will contribute our expertise as and when possible. We do not provide technical support or help in using or troubleshooting the components of the project through our normal support options such as Palo Alto Networks support teams, or ASC (Authorized Support Centers) partners and backline support options. The underlying product used (the VM-Series firewall) by the scripts or templates are still supported, but the support is only for the product functionality and not for help in deploying or using the template or script itself. Unless explicitly tagged, all projects or work posted in our GitHub repository (at https://github.com/PaloAltoNetworks) or sites other than our official Downloads page on https://support.paloaltonetworks.com are provided under the best effort policy.

Developer Sites


Copyright © 2024 Palo Alto Networks, Inc. All rights reserved.