Automation/API Discussions

Threads in this discussion area are now read-only. If you have a question about Automation/API products please visit our product discussions.

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Automation/API Discussions

Threads in this discussion area are now read-only. If you have a question about Automation/API products please visit our product discussions.

About Automation/API Discussions

Threads in this discussion area are now read-only. If you have a question about Automation/API products please visit our product discussions.

Discussions

Resolved! Python XML API Create policy issue

My PA3020 version is 7.0.3, when i use python xml api create a policy return(<response status="error" code="5"><msg>Could not copy parent object in set handler</msg></response>)can someone help me?I know version 9.0 can use json api,but now can not upgraud..lol.. Python code below:import requestsimport urllib3try: imp...

clipboard_image_0.png
xxddpac by L1 Bithead
  • 10008 Views
  • 4 replies
  • 0 Likes

Resolved! Is the API key included in the Configuration file?

I just successfully finished migrating a pair of PA-500 to a pair of PA-3020, exporting and loading the configuration file. I have checked the configuration file and I couldn't find the API key. Is someone able to confirm if the API key is included in the configuration file or if I have to generate a new API key and install the new key in the se...

Lesgall by L1 Bithead
  • 6408 Views
  • 4 replies
  • 0 Likes

panos_object

Hi, I'm trying to seach for an IP address with panos_object, I remember it was working, but for some reason it doesn't now.I'm using Role and ansible 2.4.3 with python 3.6.4, PA 8.0.8.Tested with ansible 2.5.0rc1 without role - same - name: PaloAlto Object checkpanos_object:ip_address: '{{ ip_address }}'username: '{{ username }}'password: '{{ pa...

Tag Color to API Color Value Mapping

When you retrieve the color of a tag using the API it returns a color number, not the pretty name of the color. The table below maps all of these color values in PanOS 9.0.Tag ColorAPI ValueAzure Bluecolor24Blackcolor14Bluecolor3Blue Graycolor12Blue Violetcolor30Browncolor16Burnt Siennacolor41Cerulean Bluecolor25Chestnutcolor42Cobalt Bluecolor2...

ntravis by L2 Linker
  • 5597 Views
  • 0 replies
  • 8 Likes

How to set av profile using XML API

Hi guys, I'm trying to change a created av profile. Everything was created as "alert" and I`d like to change it to "reset-both". Different from URL filtering, I don`t populate the members, I have to set based on some options from PA and I`m really lost about how to do this. Could anyone help me? I`ve tried set and override methods. Thanks

Help with script to manually uploading dynamic updates

Currently I have dynamic updates installing on one of our firewalls. I would like to get those files from the dynamic update and save them to a network drive, where I can access those files and move them to air gapped firewalls. I know I can do this manually by logging into paloalto but trying to automate this solution. Any help would be gr...

bshepos by L0 Member
  • 4117 Views
  • 2 replies
  • 0 Likes

API to create Address Group

I am trying to create a new address group using API but I always end up getting <response status="error" code="12"><msg><line>Invalid target object in set handler</line></msg></response> Can someone help me with the correct xpath to create a new shared address group empty or with a list of address objects.

Unable to get output of 'show rule-hit-count...' via panxapi.py or xapi.py

Hi All, Wondering if anyone has been able to successfully get the output of the following command via either the panxapi.py wrapper or via their own functions that make use of the xapi.py module: PS C:\Program Files (x86)\Python37-32\Scripts> python .\panxapi.py -Xjro 'show rule-hit-count vsys vsys-name vsys1 rule-base security rules all'op: ...

How to run post-connect script on each network flapp?

I have a script that is run after successful connection to my VPN network. This script sets up my routing accordingly. Unfortunately if I lock my screen and unlock VPN connection gets refreshed but without executing my script. The same thing happens when there is network flap, and VPN reconnects - my settings always get overwritten by those comi...

zygm0nt by L0 Member
  • 2553 Views
  • 0 replies
  • 0 Likes

Move a firewall from a device group to another using API

Hi, I have developed a script that provisions firewalls to activate and update when it connects to Panorama. I am now trying to get the script to move a firewall from a "Provisioning" to a "Provisioned" device group within Panorama. In the GUI I have to remove the device from a group and add it to the new group. Does anyone know what API command...

Ben101 by L0 Member
  • 3619 Views
  • 1 replies
  • 0 Likes

PA API, User not authorized

Hey,Well just like the subject says I am having issues making a device state backup. Every time I try to backup my device via the api, I get a 403 error response saying "User not authorized to perform this operation". What is strange and has me puzzled is I am able to use the same username and same password to make a running config backup. This ...

jmgarcia by L0 Member
  • 6199 Views
  • 1 replies
  • 0 Likes

XML/Rest API - Application filter and how to check if an application needs dependency apps

I would like to get the following information with the XML API and the Rest API: 1. read all application filters with their matching apps2. get the the dependency apps from the matching apps (matching the application filters) At first how can I get the application filters with their matching apps with the XML API and the Rest API? Second, based ...

mhagmann by L0 Member
  • 4425 Views
  • 1 replies
  • 0 Likes

OS Upgrade Script

Hiya! Does anybody have a script that automates PAN OS Upgrade on firewall pairs? If so, can you share one with me? I need to be able to run a script that can upgrade 4 firewall pairs. We are using Panorama as well.

Fr4nk4 by L2 Linker
  • 5369 Views
  • 1 replies
  • 0 Likes

Resolved! Use ansible or XML to create Securities profiles actions

Hello guys, does anybody know how to use ansible or other Palo alto automation tool to create a security profile? eg. a new URL filtering where I will decide what is deny and what is just alert to log? I saw that we can pass a profile as a parameter to create a rule, but I can't find how to define my own profiles.

  • 1031 Posts
  • 68 Subscriptions