Thanks to visit codestin.com
Credit goes to github.com

Skip to content

brianbaldock/SimpleIPScanner

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Simple IP Scanner

A lightweight, cross-platform GUI application for discovering devices on your local network. Built with Python and Tkinter, it requires only the standard library to run.

Features

  • Automatic detection of local network interfaces and subnets
  • Concurrent scanning using thread pools for fast results
  • Ping-based host discovery
  • ARP table lookup for MAC address resolution
  • Cross-platform support (Windows, Linux, macOS)
  • Simple graphical interface with real-time progress updates

How It Works

Network Discovery

The scanner automatically detects your local network interfaces using multiple methods:

  1. psutil (if installed) - Cross-platform Python library
  2. ip command - Linux systems
  3. ifconfig - macOS and older Linux systems
  4. ipconfig - Windows systems

The first method that succeeds is used, providing broad compatibility.

Host Scanning

For each IP address in the selected network range:

  1. Ping probe - Sends an ICMP echo request to determine if the host is online
  2. ARP lookup - Queries the system ARP table to retrieve the MAC address

Scanning is performed concurrently using a thread pool (up to 64 workers) to maximize speed while remaining responsive.

Results

Discovered hosts are displayed with:

  • IP address
  • Status (up for ping response, arp-only for ARP-only detection)
  • MAC address (if available)

Requirements

  • Python 3.8 or higher
  • Tkinter (included with Python on Windows and macOS)

Optional

  • psutil - Improves network interface detection reliability

Installation

Clone the Repository

git clone https://github.com/yourusername/SimpleIPScanner.git
cd SimpleIPScanner

Install Optional Dependencies

pip install -r requirements.txt

Platform-Specific Notes

Windows

Tkinter is included with the standard Python installer. No additional steps required.

macOS

Tkinter is included with Python from python.org. If using pyenv, you may need to install Tk support:

brew install tcl-tk
export LDFLAGS="-L$(brew --prefix tcl-tk)/lib"
export CPPFLAGS="-I$(brew --prefix tcl-tk)/include"
export PKG_CONFIG_PATH="$(brew --prefix tcl-tk)/lib/pkgconfig"
pyenv install 3.x.x

Linux (Debian/Ubuntu)

Install Tkinter if not already present:

sudo apt update
sudo apt install python3-tk

Linux (Fedora/RHEL)

sudo dnf install python3-tkinter

Linux (Arch)

sudo pacman -S tk

Quick Start

1. Run the Application

python scanner.py

2. Select a Network

The application automatically detects available network interfaces. Select the desired network from the dropdown menu.

3. Start Scanning

Click Start Scan to begin discovering devices on the selected network.

4. View Results

Discovered hosts appear in the output area as they are found. The status bar shows scan progress.

5. Stop Scanning (Optional)

Click Stop to halt an in-progress scan.

Usage Notes

  • Large networks (greater than 4096 hosts) are automatically truncated to maintain responsiveness
  • Scanning requires appropriate network permissions; some systems may require elevated privileges for full ARP table access
  • Firewall rules on target hosts may block ping responses, but devices may still appear via ARP lookup

Troubleshooting

Issue Solution
No networks detected Ensure you have an active network connection and try clicking Refresh
ModuleNotFoundError: _tkinter Install Tkinter for your platform (see Installation section)
Hosts not appearing Target hosts may have firewalls blocking ICMP; try running with elevated privileges
Slow scanning Reduce network size or check network connectivity

License

This project is provided as-is for educational and personal use.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages