Skip to content

jotive/network-scanner

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Network Scanner

A lightweight CLI tool to scan your local network, identify connected devices, and alert you when unknown devices appear.

Works on Windows, Linux, and macOS. Uses only Python standard library — no extra dependencies.

Features

  • Discovers all active hosts on the /24 subnet
  • Resolves hostnames via reverse DNS
  • Identifies device manufacturers from MAC OUI prefixes
  • Detects open ports (SSH, HTTP, RDP, SMB, etc.)
  • Tracks known devices and flags new/unknown ones

Requirements

  • Python 3.8+
  • Run as administrator / root for full ARP table access

Usage

# Scan the network and list all devices
python main.py scan

# Show a summary: connected vs known vs unknown
python main.py status

# List your registered devices
python main.py list

# Register a device as known
python main.py add aa:bb:cc:dd:ee:ff "My Laptop" laptop

# Remove a known device
python main.py remove aa:bb:cc:dd:ee:ff

How it works

  1. Detects your local IP using a dummy UDP socket (no packets sent)
  2. Pings all 254 addresses on the /24 subnet in parallel
  3. Reads the ARP table to map IPs to MAC addresses
  4. Resolves hostnames via socket.gethostbyaddr
  5. Scans common ports on each active host
  6. Compares MACs against known_devices.json and reports unknowns

Notes

  • known_devices.json is created automatically on first use and is excluded from version control via .gitignore — it contains your network data
  • Scan time is roughly 30–60 seconds depending on network size and host responsiveness
  • Devices that do not respond to ICMP ping will not be detected

About

[Cross-Tools utility] Lightweight CLI to scan local network and detect unknown devices. Cross-platform, no dependencies.

Resources

License

Stars

0 stars

Watchers

0 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages