Asynchronous multi-vendor library for interacting with network devices
Inspired by netmiko
Requires:
asyncio
AsyncSSH
Python >=3.5
pyYAML
Supports:
Cisco IOS
Cisco IOS XE
Cisco IOS XR
Cisco ASA
Cisco NX-OS
HP Comware (like V1910 too)
Fujitsu Blade Switches
Mikrotik RouterOS
Arista EOS
Juniper JunOS
Aruba AOS 6.X
Aruba AOS 8.X
Terminal
Examples:
Example of interacting with Cisco IOS devices:
import asyncio
import netdev
async def task(param):
async with netdev.create(**param) as ios:
# Testing sending simple command
out = await ios.send_command("show ver")
print(out)
# Testing sending configuration set
commands = ["line console 0", "exit"]
out = await ios.send_config_set(commands)
print(out)
# Testing sending simple command with long output
out = await ios.send_command("show run")
print(out)
# Testing interactive dialog
out = await ios.send_command("conf", pattern=r'\[terminal\]\?', strip_command=False)
out += await ios.send_command("term", strip_command=False)
out += await ios.send_command("exit", strip_command=False, strip_prompt=False)
print(out)
async def run():
dev1 = { 'username' : 'user',
'password' : 'pass',
'device_type': 'cisco_ios',
'host': 'ip address',
}
dev2 = { 'username' : 'user',
'password' : 'pass',
'device_type': 'cisco_ios',
'host': 'ip address',
}
devices = [dev1, dev2]
tasks = [task(dev) for dev in devices]
await asyncio.wait(tasks)
loop = asyncio.get_event_loop()
loop.run_until_complete(run())
Metadata
Release files for netdev 0.9.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| netdev-0.9.3.tar.gz | 22.0 kB | Without provenance | Details for netdev-0.9.3.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| netdev-0.9.3-py3-none-any.whl | Python 3 | none | any | Details for netdev-0.9.3-py3-none-any.whl |
Total release size: 59.1 kB
Release files / netdev-0.9.3.tar.gz
| Download URL | netdev-0.9.3.tar.gz |
|---|---|
| Size | 22.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
b15a011e865450445427df5ea36b7a791d7e30fa4f3656b42548e47726961da8
|
|
BLAKE2b-256 checksum How to use checksums |
a6ec79a95a59f8b101250f0c98a265dc3a862b3afd7ff750ae58b1a5ec18f0fd
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/0.12.15 CPython/3.7.3 Linux/4.4.0-17134-Microsoft
|
Release files / netdev-0.9.3-py3-none-any.whl
| Download URL | netdev-0.9.3-py3-none-any.whl |
|---|---|
| Size | 37.1 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
c7508fde9ffbb5bb181d84ce20f9c66c2da7ed99fdccf6b59129bcca1365e675
|
|
BLAKE2b-256 checksum How to use checksums |
150a4313e30381e6c9dfd7988de62b0b6b392af4bfe993afaef9c4c8c2507eda
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/0.12.15 CPython/3.7.3 Linux/4.4.0-17134-Microsoft
|
Security for netdev 0.9.3
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.