Skip to content
Iyotee edited this page Aug 24, 2025 · 2 revisions

DHCP Monitor - Option 50 Tracker

🚀 Overview

DHCP Monitor is a modern DHCP monitoring application that instantly reveals which IP address a DHCP server assigns to a newly connected device on the network. The application specializes in detecting and analyzing DHCP Option 50, allowing identification of malicious clients using fixed IP addresses.

✨ Main Features

🔍 Real-time DHCP Monitoring

  • Automatic DHCP packet capture
  • Instant detection of new connections
  • Real-time network traffic analysis

🎯 Option 50 Detection

  • Analysis of specific IP requests
  • Detection of malicious clients using fixed IPs
  • Compliance audit of DHCP policies
  • Network optimization based on usage patterns

🖥️ Modern Interface

  • Responsive design with light/dark themes
  • React 18 components with TypeScript
  • Intuitive and professional interface
  • Real-time graphs and statistics

🔧 Multi-platform Support

  • Windows: NSIS installer and portable version
  • macOS: Native application and DMG
  • Linux: AppImage and executable

📦 Installation

⚡ Quick Installation

Windows

  1. Download the latest release
  2. Run DHCP Monitor Pro_1.1.37_x64-setup.exe
  3. Launch with administrator privileges

Linux

  1. Download the AppImage
  2. chmod +x DHCPMonitor-*.AppImage
  3. ./DHCPMonitor-*.AppImage

🛠️ Developer Installation

Prerequisites

  • Node.js (v18+)
  • Rust (v1.70+)
  • Git
  • Administrator/root privileges

Dependency Installation

# Clone the repository
git clone https://github.com/iyotee/DHCPMonitor.git
cd DHCPMonitor

# Automatic installation (recommended)
install.bat    # Windows
./install.sh   # Linux/macOS

# Or manually
npm install
cargo build

🛠️ Development

🚀 Quick Start

Windows

# Launch script with administrator privileges
start.bat

# Or manually
npm run dev
npx @tauri-apps/cli dev

Linux/macOS

# Launch script with root privileges
./start.sh

# Or manually
sudo npm run dev
sudo npx @tauri-apps/cli dev

🔧 Available Scripts

Script Description Platform
start.bat / start.sh Launch with privileges Windows/Linux
build.bat / build.sh Complete build with DLLs Windows/Linux
install.bat / install.sh Automatic installation Windows/Linux

📦 Build and Packaging

Windows

# Complete build with Npcap DLLs included
build.bat

# Installer generation
npx @tauri-apps/cli build --target msi

Linux

# Application build
./build.sh

# AppImage generation
npx @tauri-apps/cli build --target appimage

📊 Technical Architecture

🏗️ Technology Stack

Layer Technology Description
Frontend React 18 + TypeScript Modern user interface
Styling Tailwind CSS Responsive design system
Backend Rust + Tauri Native performance
Network libpcap Packet capture
Graphs Recharts Real-time visualizations
Icons Lucide React Modern icons

📁 Project Structure

DHCPMonitor/
├── 📁 src/                    # Frontend React/TypeScript
│   ├── 📁 components/         # React components
│   │   ├── LogsView.tsx      # Logs view
│   │   ├── NetworkView.tsx   # Network view
│   │   ├── Option50View.tsx  # Option 50 view
│   │   ├── PacketDetails.tsx # Packet details
│   │   └── SettingsView.tsx  # Settings
│   ├── 📁 assets/            # Assets (logos, images)
│   ├── 📁 types/             # TypeScript types
│   └── App.tsx               # Main application
├── 📁 src-tauri/             # Backend Rust/Tauri
│   ├── 📁 src/               # Rust code
│   │   ├── main.rs           # Entry point
│   │   ├── dhcp_capture.rs   # DHCP capture
│   │   └── network_interfaces.rs # Network interfaces
│   ├── 📁 icons/             # Application icons
│   ├── 📁 gen/               # Generated schemas
│   └── Cargo.toml            # Rust dependencies
├── 📁 dist/                  # Production build
├── 📄 package.json           # Node.js dependencies
├── 📄 tauri.conf.json        # Tauri configuration
└── 📄 README.md              # Documentation

🔧 Key Components

Frontend (React/TypeScript)

  • LogsView: Real-time log display
  • NetworkView: Network interface management
  • Option50View: Option 50 filtering and analysis
  • PacketDetails: Captured packet details
  • SettingsView: Application configuration

Backend (Rust/Tauri)

  • dhcp_capture.rs: DHCP capture and parsing
  • network_interfaces.rs: Interface detection
  • main.rs: Orchestration and communication

🐛 Troubleshooting

❗ Common Issues

1. Permission Error

# Windows
# Run as administrator
# Right-click → "Run as administrator"

# Linux/macOS
sudo ./DHCPMonitor

2. No Interface Detected

# Check privileges
# Windows: Run as administrator
# Linux: sudo

# Check interfaces
ipconfig  # Windows
ifconfig  # Linux/macOS

3. No Packets Captured

  • ✅ Check that interface is active
  • ✅ Ensure there is DHCP traffic
  • ✅ Check capture filters
  • ✅ Restart the application

4. DLL Error (Windows)

# Reinstall Npcap
# Download from https://npcap.com/
# Or use install.bat

🔍 Debug Logs

# Enable detailed logs
RUST_LOG=debug npm run tauri dev

# Specific logs
RUST_LOG=dhcp_capture=debug npm run tauri dev

📋 Diagnostic Checklist

  • Administrator/root privileges
  • Active network interface
  • DHCP traffic present
  • Correct capture filters
  • Npcap DLLs installed (Windows)
  • libpcap installed (Linux)

🤝 Contributing

We welcome all contributions! Here's how to participate:

🚀 First Contribution

  1. Fork the project
  2. Clone your fork
  3. Create a feature branch
  4. Commit your changes
  5. Push to your fork
  6. Open a Pull Request

📝 Guidelines

  • Code Style: Follow existing conventions
  • Tests: Add tests for new features
  • Documentation: Update documentation
  • Commits: Clear and descriptive messages

🐛 Report a Bug

  1. Check existing issues
  2. Create a new issue with:
    • Detailed problem description
    • Steps to reproduce
    • System configuration
    • Error logs

💡 Propose a Feature

  1. Create an issue with "enhancement" label
  2. Describe the desired feature
  3. Explain the use case
  4. Propose an implementation

📄 License

This project is licensed under the MIT License. See the LICENSE file for details.

MIT License

Copyright (c) 2024 DHCP Monitor

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

🙏 Acknowledgments

  • Tauri - Cross-platform framework
  • React - User interface
  • libpcap - Network capture
  • Recharts - Graphs
  • Tailwind CSS - Styling
  • Lucide React - Icons

DHCP Monitor - Option 50 Tracker

Modern and performant DHCP monitoring

⭐ Don't hesitate to give a star if this project is useful to you!

📚 Navigation

Clone this wiki locally