Professional Network Discovery & Security Monitoring Tool
NetMapper is a real-time network device discovery and monitoring system built with Python. It provides passive and active network scanning capabilities with an intuitive web-based dashboard for visualizing network topology and detecting unauthorized devices.
- π Active Network Scanning - ARP-based device discovery across your local network
- π‘ Passive Traffic Monitoring - Real-time packet sniffing for automatic device detection
- π― Device Tracking - Persistent device identification via MAC addresses
- π¨ Alert System - Automatic alerts for new or suspicious devices
- π Web Dashboard - Beautiful, responsive interface for network visualization
- πΎ SQLite Database - Lightweight, serverless data persistence
- Python 3.8 or higher
- Windows, Linux, or macOS
- Administrator/root privileges (for network scanning)
-
Clone or download the repository
cd Net-Mapper -
Create a virtual environment
python -m venv .venv .venv\Scripts\activate # Windows source .venv/bin/activate # Linux/Mac
-
Install dependencies
pip install -r requirements.txt
-
Start the application
python run.py
-
Open your browser
http://localhost:5000
Net-Mapper/
βββ π core/ # Core functionality
β βββ discovery.py # Active network scanning (ARP)
β βββ passive_sniffer.py # Passive traffic monitoring
β βββ correlation_engine.py # Device tracking & DB sync
β βββ __init__.py
β
βββ π db/ # Database layer
β βββ database.py # SQLAlchemy models
β βββ __init__.py
β
βββ π web/ # Web interface
β βββ app.py # Flask application
β βββ routes.py # API routes
β βββ __init__.py
β βββ templates/ # HTML templates
β β βββ dashboard.html
β βββ static/ # Static assets
β βββ css/
β βββ js/
β βββ img/
β
βββ π scripts/ # Utility scripts
β βββ quick_scan.py # Quick network scan tool
β βββ start_monitor.py # Start passive monitoring
β
βββ π docs/ # Documentation
β βββ INSTALLATION.md # Installation guide
β βββ API.md # API documentation
β
βββ π data/ # Database storage (auto-generated)
β βββ netmapper.db
β
βββ π run.py # Application entry point
βββ π config.py # Configuration settings
βββ π setup.py # Package installation script
βββ π requirements.txt # Python dependencies
βββ π LICENSE # MIT License
βββ π .gitignore # Git ignore rules
βββ π README.md # This file
python run.pyAccess the dashboard at: http://localhost:5000
Windows:
# Run PowerShell as Administrator
python scripts\quick_scan.pyLinux/Mac:
sudo python scripts/quick_scan.pyWindows:
# Run PowerShell as Administrator
python scripts\start_monitor.pyLinux/Mac:
sudo python scripts/start_monitor.pySee API Documentation for programmatic usage and Installation Guide for detailed setup instructions.
- NetMapper requires administrator/root privileges for raw packet access
- Only use on networks you own or have permission to monitor
- This tool is for educational and authorized security auditing only
- Unauthorized network scanning may be illegal in your jurisdiction
The SQLite database is stored in data/netmapper.db. To change the location, edit web/app.py:
db_path = os.path.join(basedir, '..', 'data', 'netmapper.db')Default port is 5000. To change it, edit run.py:
app.run(debug=True, port=5000, host='0.0.0.0')The web dashboard provides:
- Device Overview - Total device count and active alerts
- Alert Feed - Real-time notifications for new devices
- Device Table - Comprehensive list with:
- IP Address
- MAC Address
- Trust Level (NEW/KNOWN/SUSPICIOUS)
- First & Last Seen timestamps
- Backend: Python 3.8+, Flask 3.1
- Database: SQLite with SQLAlchemy ORM
- Network: Scapy for packet manipulation
- Frontend: HTML5, CSS3 (no external frameworks)
id- Primary keymac_address- Unique device identifierip_address- Current IP (may change)hostname- Device name (if available)vendor- MAC vendor lookuptrust_level- new/known/suspiciousis_active- Current statusfirst_seen- Initial detection timestamplast_seen- Most recent activity
id- Primary keydevice_id- Foreign key to devicesalert_type- Alert categorymessage- Alert descriptiontimestamp- When alert was generatedresolved- Resolution status
This is an educational project. Feel free to fork and modify for your needs.
This project is for educational purposes. Use responsibly and ethically.
- Solution: Run as Administrator (Windows) or use
sudo(Linux/Mac)
- Solution: Ensure you're running with admin privileges and firewall isn't blocking
- Solution: Make sure
run.pyis executed from the project root directory
- Solution: Activate virtual environment and reinstall dependencies
For issues or questions, please check the troubleshooting section above.
Built with π for network security education