<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Python Script For Interface ACL's, feedback in General Topics</title>
    <link>https://live.paloaltonetworks.com/t5/general-topics/python-script-for-interface-acl-s-feedback/m-p/560612#M113632</link>
    <description>&lt;P&gt;Thanks, I'm reading the panos read the docs right now, seems like it has a lot of power. I thinkI'm going to keep pushing with creating a lightweight program,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I think the next, and relatively easy and practical script, would be do get all device ACL's and compare it to existing ACL's in a SQL (Swinds) database, and give the user the option to push changes or delete the ACL's. I may add that next and integrate with the code I have.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Question for anyone:&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;does the PAN-OS SDK for Python make its API calls&amp;nbsp; Panorama/ the GUI?&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://pan-os-python.readthedocs.io/en/latest/getting-started.html" target="_blank"&gt;https://pan-os-python.readthedocs.io/en/latest/getting-started.html&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Thu, 05 Oct 2023 01:36:43 GMT</pubDate>
    <dc:creator>hfakoor2</dc:creator>
    <dc:date>2023-10-05T01:36:43Z</dc:date>
    <item>
      <title>Python Script For Interface ACL's, feedback</title>
      <link>https://live.paloaltonetworks.com/t5/general-topics/python-script-for-interface-acl-s-feedback/m-p/560606#M113630</link>
      <description>&lt;P&gt;Wrote script to update interface ACL's in batch. User logs in to multiple firewalls, SSH conenctions saved in background, interface profiles are updated in a customized way per user input per firewall.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Here's the Github link to the program:&lt;/P&gt;
&lt;P&gt;&lt;A href="https://github.com/hfakoor222/Palo_Alto_Scripting" target="_blank" rel="noopener"&gt;https://github.com/hfakoor222/Palo_Alto_Scripting&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;There's a 2 minute video on multiple firewalls being updated at once, 10.0.4&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;My question is how useful would a script like this be? I'm not used to panOS devices, so I don't know if the GUI/Panorama has features suc as batch updates.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;My second question is what other features would you recommend to add: example what issues does a firewall engineer face that could save time being scripted.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I had some ideas for features which include:&lt;/P&gt;
&lt;P&gt;service-policy automation&lt;/P&gt;
&lt;P&gt;object-group automation&lt;/P&gt;
&lt;P&gt;connectivity test: using Python packets to test connectivity before and after ACL changes (ex: pings and tcp conenctions)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;What are your thoughts on this? And what are your suggestions to improve on features.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;PS:&lt;/P&gt;
&lt;P&gt;you can also follow/watch the Github link to stay updated with the fetures I'll be adding. I may at some point try to develop this into a full program hosted on an internal web page.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 04 Oct 2023 23:12:10 GMT</pubDate>
      <guid>https://live.paloaltonetworks.com/t5/general-topics/python-script-for-interface-acl-s-feedback/m-p/560606#M113630</guid>
      <dc:creator>hfakoor2</dc:creator>
      <dc:date>2023-10-04T23:12:10Z</dc:date>
    </item>
    <item>
      <title>Re: Python Script For Interface ACL's, feedback</title>
      <link>https://live.paloaltonetworks.com/t5/general-topics/python-script-for-interface-acl-s-feedback/m-p/560609#M113631</link>
      <description>&lt;P&gt;Hi &lt;a href="https://live.paloaltonetworks.com/t5/user/viewprofilepage/user-id/318102"&gt;@hfakoor2&lt;/a&gt; ,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I like it!&amp;nbsp; It's short and sweet and gets the job done.&amp;nbsp; The script is mostly Pythonic which means it is easy to follow and self-documenting.&amp;nbsp; I have 1 minor recommendation:&amp;nbsp; Consider adding the operational mode command "set cli config-output-format set" so that your configuration mode commands show in the set format instead of JSON.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;How useful will it be?&amp;nbsp; That is always hard to answer.&amp;nbsp; If people like it and find it easy to use, then yes.&amp;nbsp; However, there are a plethora of automation products out there.&amp;nbsp; The Live Community has pages dedicated for 3.&amp;nbsp; Check out the pic below.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="TomYoung_0-1696466957503.png" style="width: 400px;"&gt;&lt;img src="https://live.paloaltonetworks.com/t5/image/serverpage/image-id/54162i1D35170B2E037EE4/image-size/medium?v=v2&amp;amp;px=400" role="button" title="TomYoung_0-1696466957503.png" alt="TomYoung_0-1696466957503.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The Ansible module has an Interface Management Profile playbook.&amp;nbsp;&amp;nbsp; The PAN-OS Python page has 2 main Pythons tools, both on GitHub, and lots of community input.&amp;nbsp; There is also a 3rd Python panapi on GitHub.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Panorama and the NGFWs also have an API interface.&amp;nbsp; &lt;A href="https://docs.paloaltonetworks.com/pan-os/9-1/pan-os-panorama-api/get-started-with-the-pan-os-xml-api/explore-the-api/use-the-api-browser" target="_blank" rel="noopener"&gt;https://docs.paloaltonetworks.com/pan-os/9-1/pan-os-panorama-api/get-started-with-the-pan-os-xml-api/explore-the-api/use-the-api-browser&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I don't do much automation now.&amp;nbsp; I use Panorama to manage multiple NGFWs.&amp;nbsp; For automation n00bs, I think Ansible would be the easiest to setup and begin making changes.&amp;nbsp; If I were to write an SDK, I would probably use the REST API because the URLs and actions would be consistent throughout.&amp;nbsp; This would allow the script to be very modular.&amp;nbsp; API keys also save time over username/passwords.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Tom&lt;/P&gt;</description>
      <pubDate>Thu, 05 Oct 2023 01:15:37 GMT</pubDate>
      <guid>https://live.paloaltonetworks.com/t5/general-topics/python-script-for-interface-acl-s-feedback/m-p/560609#M113631</guid>
      <dc:creator>TomYoung</dc:creator>
      <dc:date>2023-10-05T01:15:37Z</dc:date>
    </item>
    <item>
      <title>Re: Python Script For Interface ACL's, feedback</title>
      <link>https://live.paloaltonetworks.com/t5/general-topics/python-script-for-interface-acl-s-feedback/m-p/560612#M113632</link>
      <description>&lt;P&gt;Thanks, I'm reading the panos read the docs right now, seems like it has a lot of power. I thinkI'm going to keep pushing with creating a lightweight program,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I think the next, and relatively easy and practical script, would be do get all device ACL's and compare it to existing ACL's in a SQL (Swinds) database, and give the user the option to push changes or delete the ACL's. I may add that next and integrate with the code I have.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Question for anyone:&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;does the PAN-OS SDK for Python make its API calls&amp;nbsp; Panorama/ the GUI?&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://pan-os-python.readthedocs.io/en/latest/getting-started.html" target="_blank"&gt;https://pan-os-python.readthedocs.io/en/latest/getting-started.html&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 05 Oct 2023 01:36:43 GMT</pubDate>
      <guid>https://live.paloaltonetworks.com/t5/general-topics/python-script-for-interface-acl-s-feedback/m-p/560612#M113632</guid>
      <dc:creator>hfakoor2</dc:creator>
      <dc:date>2023-10-05T01:36:43Z</dc:date>
    </item>
    <item>
      <title>Re: Python Script For Interface ACL's, feedback</title>
      <link>https://live.paloaltonetworks.com/t5/general-topics/python-script-for-interface-acl-s-feedback/m-p/560614#M113633</link>
      <description>&lt;P&gt;Hi &lt;a href="https://live.paloaltonetworks.com/t5/user/viewprofilepage/user-id/318102"&gt;@hfakoor2&lt;/a&gt; ,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I am pretty sure it is based upon pan-python which uses the PAN-OS and Panorama XML API.&amp;nbsp; See the API Browser URL I posted above.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Tom&lt;/P&gt;</description>
      <pubDate>Thu, 05 Oct 2023 02:00:33 GMT</pubDate>
      <guid>https://live.paloaltonetworks.com/t5/general-topics/python-script-for-interface-acl-s-feedback/m-p/560614#M113633</guid>
      <dc:creator>TomYoung</dc:creator>
      <dc:date>2023-10-05T02:00:33Z</dc:date>
    </item>
    <item>
      <title>Re: Python Script For Interface ACL's, feedback</title>
      <link>https://live.paloaltonetworks.com/t5/general-topics/python-script-for-interface-acl-s-feedback/m-p/560619#M113634</link>
      <description>&lt;P&gt;&lt;a href="https://live.paloaltonetworks.com/t5/user/viewprofilepage/user-id/77347"&gt;@TomYoung&lt;/a&gt;&amp;nbsp;what is PAN-OS,&amp;nbsp; a centralized GUI?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Also would I be able to practice these API calls in a lab environment? I'm not sure if the GUI would have some sort of subscription feature?&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;Thanks for the reply.&lt;/P&gt;</description>
      <pubDate>Thu, 05 Oct 2023 03:53:12 GMT</pubDate>
      <guid>https://live.paloaltonetworks.com/t5/general-topics/python-script-for-interface-acl-s-feedback/m-p/560619#M113634</guid>
      <dc:creator>hfakoor2</dc:creator>
      <dc:date>2023-10-05T03:53:12Z</dc:date>
    </item>
    <item>
      <title>Re: Python Script For Interface ACL's, feedback</title>
      <link>https://live.paloaltonetworks.com/t5/general-topics/python-script-for-interface-acl-s-feedback/m-p/560687#M113642</link>
      <description>&lt;P&gt;Hi &lt;a href="https://live.paloaltonetworks.com/t5/user/viewprofilepage/user-id/318102"&gt;@hfakoor2&lt;/a&gt; ,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;PAN-OS is the Palo Alto Networks - Operating System for their NGFWs.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Yes, you can practice the API calls in a lab.&amp;nbsp; The API does not require a license.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Tom&lt;/P&gt;</description>
      <pubDate>Thu, 05 Oct 2023 13:11:49 GMT</pubDate>
      <guid>https://live.paloaltonetworks.com/t5/general-topics/python-script-for-interface-acl-s-feedback/m-p/560687#M113642</guid>
      <dc:creator>TomYoung</dc:creator>
      <dc:date>2023-10-05T13:11:49Z</dc:date>
    </item>
  </channel>
</rss>

