How starsden/gate works
GATE turns a Linux mini-PC into a managed Wi-Fi VPN gateway. An administrator uses the web controller to complete onboarding and manage gateway services; Wi-Fi clients then receive DHCP/DNS and their traffic is filtered and policy-routed through the VLESS/REALITY tunnel, with a direct WAN route for the VPN server to prevent loops. The graph includes the documented data plane and major management capabilities. Several backend call relationships are supported by the SOURCE INDEX; unsampled frontend/API wiring is shown only as unverified.
Main entry points: api.py REST and SSE API · setup.py Onboarding wizard · diagnostics.py Diagnostics and repair · vpn.py VLESS VPN service
Components 23
Web control
- Web controller
web/app.js - FastAPI application
backend/app.py - REST and SSE API
backend/api.py
Setup and security
- Onboarding wizard
backend/services/setup.py - Admin authentication
backend/services/auth.py
Gateway services
- Wi-Fi management
backend/services/wifi.py - Network and routing
backend/services/network.py - Firewall and NAT
backend/services/firewall.py - VLESS VPN service
backend/services/vpn.py - VPN subscriptions
backend/services/subscription.py - Connected clients
backend/services/clients.py - System status
backend/services/system.py
Health and recovery
- Diagnostics and repair
backend/services/diagnostics.py - Backup and rollback
backend/services/backups.py - Gateway logs
backend/services/logs.py
Traffic data plane
- Wi-Fi access point
configs/hostapd.conf - DHCP and DNS
configs/dnsmasq.conf - nftables rules
configs/nftables.conf - Policy routing
backend/services/network.py - Xray TUN tunnel
backend/services/vpn.py
Other components
- Administrator
- Wi-Fi clients
- WAN and Internet
Connections 37
- Administrator → Web controller: manages
README.md - Web controller → REST and SSE API: uses API
- FastAPI application → REST and SSE API: registers router
backend/app.py - REST and SSE API → Onboarding wizard: routes setup
backend/api.py - REST and SSE API → Admin authentication: routes authentication
backend/api.py - REST and SSE API → Wi-Fi management: routes Wi-Fi
backend/api.py - REST and SSE API → Network and routing: routes network
backend/api.py - REST and SSE API → Firewall and NAT: routes firewall
backend/api.py - REST and SSE API → VLESS VPN service: routes VPN
backend/api.py - REST and SSE API → VPN subscriptions: routes subscriptions
backend/api.py - REST and SSE API → Connected clients: routes clients
backend/api.py - REST and SSE API → System status: routes system
backend/api.py - REST and SSE API → Diagnostics and repair: routes diagnostics
backend/api.py - REST and SSE API → Backup and rollback: routes backups
backend/api.py - REST and SSE API → Gateway logs: routes logs
backend/api.py - Onboarding wizard → Wi-Fi management: configures Wi-Fi
backend/services/setup.py - Onboarding wizard → Network and routing: detects interfaces
backend/services/setup.py - Onboarding wizard → Admin authentication: checks onboarding
backend/services/setup.py - Onboarding wizard → VPN subscriptions: configures VPN
backend/services/setup.py - Onboarding wizard → Firewall and NAT: deploys firewall
backend/services/setup.py - Wi-Fi management → Connected clients: counts clients
backend/services/wifi.py - Network and routing → VLESS VPN service: reads VPN profile
backend/services/network.py - VPN subscriptions → VLESS VPN service: updates VPN endpoint
backend/services/subscription.py - Diagnostics and repair → Network and routing: checks and syncs routes
backend/services/diagnostics.py - Diagnostics and repair → Firewall and NAT: applies firewall
backend/services/diagnostics.py - Diagnostics and repair → System status: checks system
backend/services/diagnostics.py - Diagnostics and repair → VLESS VPN service: checks VPN
backend/services/diagnostics.py - Backup and rollback → Wi-Fi management: restores configuration
backend/services/backups.py - Backup and rollback → VLESS VPN service: restores configuration
backend/services/backups.py - Backup and rollback → Firewall and NAT: reapplies rules
backend/services/backups.py - Wi-Fi clients → Wi-Fi access point: connect over Wi-Fi
README.md - Wi-Fi access point → DHCP and DNS: uses DHCP and DNS
README.md - DHCP and DNS → nftables rules: serves LAN traffic
README.md - nftables rules → Policy routing: filters and NATs
README.md - Policy routing → Xray TUN tunnel: routes LAN traffic
README.md - Xray TUN tunnel → WAN and Internet: tunnels VLESS traffic
README.md - Policy routing → WAN and Internet: bypasses VPN server
README.md