$ show ivpn/desktop-app
This repository contains the official IVPN desktop client, a multi-platform VPN application supporting Windows, macOS, and Linux. It is composed of three main components: a privileged Go daemon that manages VPN connections (OpenVPN, WireGuard, V2Ray), firewall (kill switch), DNS (including DNSCrypt-proxy for DoH), split tunneling, and WiFi trusted networks; a Go CLI for command-line control; and an Electron/Vue.js UI for graphical interaction. The daemon and clients communicate over a local TCP JSON protocol with authentication and event push. The codebase demonstrates strong engineering practices: platform abstraction via build tags, a custom ICMP ping library, a reusable logger, a type-safe IPC client library documented for third-party integration, and Windows WFP wrappers for firewall and split tunneling. Build scripts and native projects (Windows kernel driver, macOS helpers) handle cross-platform packaging and signing.
The LLM identified 4 files worth highlighting for reuse:
A self-contained ICMP ping library with UUID-based deduplication, TTL support, and exponential backoff. Can be extracted and reused in any Go project requiring latency measurement without external dependencies.
A per-module logger implementation with configurable levels (debug, info, warning, error) and file rotation. Demonstrates clean separation of concerns and can be extracted as a standalone logging package.
A type-safe Go client for the IVPN daemon's JSON-over-TCP protocol, with request/response matching, timeout handling, and async event callbacks. Documented for third-party use and easily adaptable to other daemon-client IPC scenarios.
A collection of Go wrappers for the Windows Filtering Platform (WFP), providing abstractions for providers, sublayers, filters, and conditions. Demonstrates non-trivial Windows API knowledge and can be extracted as a library for managing WFP firewall rules.