Skip to main content

Shortcut functions for coding and working with PAN devices

Retrieve PAN API key from file in user home directory

Get API key from .panconfkeystore file in user home directory. Input file format has one entry per line.

<apikey>:<ip>

Code example

import retrievepankey
apikey = retrievepankey.read_key_file("192.168.1.1")    

Retrieve device info from file in user home directory

Use shortcut name in scripts to retrieve info about device.

Will return device 'ip' field by default

Input file format for 'fetch_deviceinfo_file()' is below. The function reads in a YAML format from .pandevice file, in user home directory, by default. All sub fields (serial, ip, type, etc) can be customized and returned. If there is no match, the input string to the function is returned.

DEMOFW1:
  serial: 09870100089
  ip: 192.168.50.100
  type: panos
  panorama: 192.168.100.100
  panorama2: 192.168.100.101
  hapair: 192.168.50.101
DEMOFW2:
  serial: 098001000597
  ip: 192.168.50.101
  type: panos
  panorama: 192.168.100.100
  panorama2: 192.168.100.101
  hapair: 192.168.50.101

Code example

import retrievepankey

firewallip = retrievepankey.fetch_deviceinfo_file("DEMO-FW")
panoip = retrievepankey.fetch_deviceinfo_file("DEMO-FW", field='panorama')

Metadata

Release files for retrievepankey 0.1.11

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for retrievepankey 0.1.11
File Size Uploaded Provenance Actions
retrievepankey-0.1.11.tar.gz 2.1 kB Without provenance Details for retrievepankey-0.1.11.tar.gz

Release files / retrievepankey-0.1.11.tar.gz

Download URL retrievepankey-0.1.11.tar.gz
Size 2.1 kB
Tags Source
SHA-256 checksum
How to use checksums
8458047b65d18aeb57fb8163534cd0a2a600e7d3613330e8dcab9f48ba9f7826
BLAKE2b-256 checksum
How to use checksums
5b60465460cd4e13ecc472bfab75e2a1e28840ae3e9bb4a82858bb4ea5608a5e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.13.0 pkginfo/1.5.0.1 requests/2.19.1 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/3.7.3

Security for retrievepankey 0.1.11

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page