Python3 Module to interact with the SonicWall® SonicOS API.
Project description
sonicapi
Python3 Module to interact with the SonicWall® SonicOS API
This Module currently only contains basic functionality:
- Address Objects
- Address Groups
- Service Objects
- Service Groups
- Zones
- Access Rules
- NAT Policies
- Route Policies
- Restart
Installation:
pip3 install sonicapi
Usage:
from sonicapi import sonicapi
import json
def main():
# This example connects to the API, dumps out a JSON list of Address Objects, and logs out.
s = sonicapi('192.168.168.168', 443, 'admin', 'password')
print(json.dumps(s.auth(login=True), indent=2))
print(json.dumps(s.AddressObjects(type='ipv4'), indent=2))
print(json.dumps(s.AddressObjects(type='ipv6'), indent=2))
print(json.dumps(s.auth(logout=True), indent=2))
if __name__ == "__main__":
main()
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
sonicapi-0.2.1.tar.gz
(7.0 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file sonicapi-0.2.1.tar.gz.
File metadata
- Download URL: sonicapi-0.2.1.tar.gz
- Upload date:
- Size: 7.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/45.2.0 requests-toolbelt/0.8.0 tqdm/4.56.0 CPython/3.8.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
dd9eb78e2b10b9e614240b4023c64bde69842186349d2b75e1bcd92ca79f9919
|
|
| MD5 |
b60df0f9da3a0e83a9f3856757b45273
|
|
| BLAKE2b-256 |
7899b258bb41e4bd22929e3e038ebe84c9324486634228f2bee01e0a2ac1a44c
|
File details
Details for the file sonicapi-0.2.1-py3-none-any.whl.
File metadata
- Download URL: sonicapi-0.2.1-py3-none-any.whl
- Upload date:
- Size: 6.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/45.2.0 requests-toolbelt/0.8.0 tqdm/4.56.0 CPython/3.8.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
2650b4eb3827ef7a81de1231dab124398674b79db0ed1f705dc9905dede20e43
|
|
| MD5 |
fb888751fde3f53e54266728ec365011
|
|
| BLAKE2b-256 |
c948569712e4896ca8f4705c67c7ae958f06846c5e676b4ca83b4ebe10882cd9
|