Export policies from Palo Alto firewall

One or two years ago I had to migrate and document the policies of an firewall appliance from Palo Alto Networks, but there was no way to export the information in a human-readable format. So wrote a small Python script to export the policies as HTML file.

To run the script the following requirements have to be met.

The script has been tested with PAN-OS 6.1.x. It uses a file called running-config.xml as input and creates a file called output.html to export the policies as HTML.

::: {.code-include lexer="Python"} ../../file/article/2017/02/27/export-policies-from-palo-alto-firewall/tohtml.py :::

You can download the file as tohtml.py.

Links

Verwandte Artikel