Skip to main content

Project to scan and gather connectivity information on small networks

Project description

network_scanner_kbk

Project to impliment a network scanner for comparing subnets

Example Usage

Example of using the network_scanner utility to scan 2 given subnets and look for devices that can only be accessed through exactly one of the subnets.

# Import the NetworkScanner class
from network_scanner_kbk import NetworkScanner

# Create an instance of the NetworkScanner class
ns = NetworkScanner()

# Provide 2 subnet addresses in CIDR /24 notation
subnet1 = "192.168.0.0/24"
subnet2 = "192.168.1.0/24"

# Call find_singularly_reachable_devices() to obtain the list of devices (ips)
devices = ns.find_singularly_reachable_devices(subnet1, subnet2)

print("List of devices accessible on exactly one subnet:")
for d in devices:
    print(d)

This package comes with unit tests. They can be run as follows:

cd network_scanner_kbk/tests
python test_network_scanner.py

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

network_scanner_kbk-0.0.23.tar.gz (7.0 kB view hashes)

Uploaded Source

Built Distribution

network_scanner_kbk-0.0.23-py3-none-any.whl (8.3 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page