- Access exclusive content
- Connect with peers
- Share your expertise
- Find support resources
02-14-2024 04:46 AM
Hi,
for some time i have been using and testing, the different APIs available, and im actually doing some
tests with the python-os module, to get some data from some of out panorama templates.
I have been succesfull on getting Physycal interfaces data, zones, and generaly almost every config item
available but im failing to get the Layer3Subinterfaces.
I have even tried to get the s/n assigned to that templates, and add them to query the fw
through the panorama but everytime i ended up getting nothing. Part of the script.
scope=panorama.DeviceGroup(template)
pano.add(scope)
print("[*] Using template "+str(template))
templates = panorama.TemplateStack.refreshall(scope)
for item in templates:
if item.name == template:
print(" [*] Found following devices associated "+str(item.devices))
serial=item.devices[0]
fw = firewall.Firewall(serial=serial)
pano.add(fw)
print()
for i in network.Layer3Subinterface.refreshall(fw):
print(i.about())
Does anybody has any specific example or tip that could please share ? I have been hitting my head
against the wall for quite few hours already :-$
Regards
Click Accept as Solution to acknowledge that the answer to your question has been provided.
The button appears next to the replies on topics you’ve started. The member who gave the solution and all future visitors to this topic will appreciate it!
These simple actions take just seconds of your time, but go a long way in showing appreciation for community members and the LIVEcommunity as a whole!
The LIVEcommunity thanks you for your participation!