
A lightweight, policy-driven framework that brings Zero-Trust micro-segmentation to SOHO networks using WireGuard.
SafeNet is a production-grade Zero-Trust Network Access (ZTNA) framework specifically engineered for Small Office/Home Office (SOHO) environments. By orchestrating a secure, identity-aware VPN overlay utilizing the WireGuard protocol, SafeNet provides granular control over network access through dynamic peer synchronization and strict /32 CIDR microsegmentation. The framework ensures a high-security perimeter via ephemeral cryptographic key management and a modern asynchronous control plane.
SafeNet implements a rigid Hub-and-Spoke topology where the central gateway acts as the authoritative Control Plane. Lateral movement is mathematically restricted through the enforcement of /32 CIDR masks for every connected peer, ensuring that devices remain isolated within the overlay unless explicit routing policies are defined.

The Core Hub-and-Spoke Topology with robust Control & Data Planes

Note on Microsegmentation: By assigning unique /32 addresses and managing the AllowedIPs table dynamically, SafeNet prevents unauthorized east-west traffic between peers at the kernel level.
SafeNet provides automated batch scripts to handle environment preparation and gateway ignition.
setup_env.bat. This script verifies the Python installation, creates a local virtual environment, and installs all required dependencies.run_server.bat and select Run as Administrator. This elevates the process to allow the FastAPI backend to interface with the Windows kernel and WireGuard driver.For developers requiring granular control over the initialization sequence:
python -m venv venv
.\venv\Scripts\activate
pip install -r requirements.txt
python run_api.py
The administrative interface allows for rapid enrollment and status monitoring of the security perimeter.
# Verify system and interface status
python cli/console.py status
# Activate the WireGuard tunnel service
python cli/console.py start
# Enroll a new device and generate a /32 configuration
python cli/console.py enroll new-device-name
Project SafeNet is released under the GPL-3.0 License.
Security Warning: This framework is designed to manage SOHO security perimeters. Users are responsible for ensuring that the underlying Windows host is hardened and that Administrator privileges are managed according to the principle of least privilege.
| Document | Description |
|---|
| Architecture | Technical deep dive into ZTNA principles and data flow. |
| API Contract | REST API specifications and authentication schemas. |
| Setup Guide | Detailed prerequisite and installation troubleshooting. |
| CLI Reference | Detailed command syntax and administrative usage. |