# muhdsyahirk/netmon architecture

> Architecture diagram of the GitHub repository muhdsyahirk/netmon, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-11-24). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/muhdsyahirk/netmon
- Repository: https://github.com/muhdsyahirk/netmon

## Overview

NetMon is a desktop network-monitoring application for small networks. Users select a network interface, monitor traffic, inspect packets, discover and manage hosts, review security checks and alerts, and view traffic over time. The README identifies these product capabilities, while the single 73 KB `main.py` contains the sampled implementation. The graph preserves the documented feature areas, but several connections to the main window are dashed because the relevant event handlers were not excerpted; it does not assume an unsampled call sequence.

Main entry points: [`main.py`](https://github.com/muhdsyahirk/netmon/blob/master/main.py) (Main window)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_app["Monitoring app"]
  node_window["Main window<br/>[main.py]"]
  node_interfaces["Interface mapping<br/>[main.py]"]
  node_capture["Packet capture<br/>[main.py]"]
  node_packet_view["Packet details<br/>[main.py]"]
  node_traffic_graph["Traffic graph<br/>[main.py]"]
end

subgraph group_hosts["Host management"]
  node_discovery["Host discovery<br/>[main.py]"]
  node_device_db[("Device database<br/>[main.py]")]
  node_host_management["Host management<br/>[main.py]"]
  node_security_scan["Host security scan<br/>[main.py]"]
end

subgraph group_analysis["Analysis and alerts"]
  node_alert_detection["Alert detection<br/>[main.py]"]
  node_alert_history["Alert history<br/>[main.py]"]
  node_notifications["Desktop notifications<br/>[main.py]"]
end

node_user(("Network administrator"))
node_network(("Monitored network"))
node_sqlite[("SQLite")]

node_user -->|"uses"| node_window
node_window -.->|"maps"| node_interfaces
node_window -.->|"starts"| node_capture
node_window -.->|"opens"| node_packet_view
node_window -.->|"updates"| node_traffic_graph
node_window -.->|"starts"| node_discovery
node_window -.->|"manages"| node_host_management
node_window -.->|"starts"| node_security_scan
node_window -.->|"displays"| node_alert_detection
node_network -->|"supplies traffic"| node_capture
node_alert_detection -->|"looks up hosts"| node_device_db
node_device_db -->|"reads and writes"| node_sqlite
node_alert_history -->|"notifies"| node_notifications

click node_window "https://github.com/muhdsyahirk/netmon/blob/master/main.py"
click node_interfaces "https://github.com/muhdsyahirk/netmon/blob/master/main.py"
click node_capture "https://github.com/muhdsyahirk/netmon/blob/master/main.py"
click node_packet_view "https://github.com/muhdsyahirk/netmon/blob/master/main.py"
click node_traffic_graph "https://github.com/muhdsyahirk/netmon/blob/master/main.py"
click node_discovery "https://github.com/muhdsyahirk/netmon/blob/master/main.py"
click node_device_db "https://github.com/muhdsyahirk/netmon/blob/master/main.py"
click node_host_management "https://github.com/muhdsyahirk/netmon/blob/master/main.py"
click node_security_scan "https://github.com/muhdsyahirk/netmon/blob/master/main.py"
click node_alert_detection "https://github.com/muhdsyahirk/netmon/blob/master/main.py"
click node_alert_history "https://github.com/muhdsyahirk/netmon/blob/master/main.py"
click node_notifications "https://github.com/muhdsyahirk/netmon/blob/master/main.py"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_window,node_interfaces,node_capture,node_packet_view,node_traffic_graph toneBlue
class node_discovery,node_device_db,node_host_management,node_security_scan,node_sqlite toneAmber
class node_alert_detection,node_alert_history,node_notifications toneMint
class node_user,node_network toneIndigo
```

## Components

### Monitoring app

- [Main window](https://github.com/muhdsyahirk/netmon/blob/master/main.py): `main.py`
- [Interface mapping](https://github.com/muhdsyahirk/netmon/blob/master/main.py): `main.py`
- [Packet capture](https://github.com/muhdsyahirk/netmon/blob/master/main.py): `main.py`
- [Packet details](https://github.com/muhdsyahirk/netmon/blob/master/main.py): `main.py`
- [Traffic graph](https://github.com/muhdsyahirk/netmon/blob/master/main.py): `main.py`

### Host management

- [Host discovery](https://github.com/muhdsyahirk/netmon/blob/master/main.py): `main.py`
- [Device database](https://github.com/muhdsyahirk/netmon/blob/master/main.py): `main.py`
- [Host management](https://github.com/muhdsyahirk/netmon/blob/master/main.py): `main.py`
- [Host security scan](https://github.com/muhdsyahirk/netmon/blob/master/main.py): `main.py`

### Analysis and alerts

- [Alert detection](https://github.com/muhdsyahirk/netmon/blob/master/main.py): `main.py`
- [Alert history](https://github.com/muhdsyahirk/netmon/blob/master/main.py): `main.py`
- [Desktop notifications](https://github.com/muhdsyahirk/netmon/blob/master/main.py): `main.py`

### Other components

- **Network administrator**
- **Monitored network**
- **SQLite**

## Connections

- Network administrator → Main window: uses (evidence: `README.md`)
- Main window → Interface mapping: maps (evidence: `main.py`)
- Main window → Packet capture: starts (evidence: `main.py`)
- Main window → Packet details: opens (evidence: `main.py`)
- Main window → Traffic graph: updates (evidence: `main.py`)
- Main window → Host discovery: starts (evidence: `main.py`)
- Main window → Host management: manages (evidence: `main.py`)
- Main window → Host security scan: starts (evidence: `main.py`)
- Main window → Alert detection: displays (evidence: `main.py`)
- Monitored network → Packet capture: supplies traffic (evidence: `README.md`)
- Alert detection → Device database: looks up hosts (evidence: `main.py`)
- Device database → SQLite: reads and writes (evidence: `main.py`)
- Alert history → Desktop notifications: notifies (evidence: `main.py`)
