Hi everyone!
I'd like to introduce
os-zapret2-restyle (https://github.com/Tolian82/os-zapret2-restyle), an independent, free, open-source OPNsense plugin that integrates Zapret2 (https://github.com/bol-van/zapret2) with native WebGUI management, flexible DPI bypass strategies, and automated strategy testing.
I've been developing the project since May 2026. It started as a personal experiment and has gradually grown into a much larger project with its own architecture, package repository, and development roadmap.
What is os-zapret2-restyle?The plugin brings the native
dvtws2 engine into OPNsense, allowing users to manage Zapret2, configure traffic profiles, and test DPI bypass strategies directly from the firewall's WebGUI.
One of its main features is
Strategy Lab: instead of manually guessing which parameters might work, users can run automated tests against a selected destination using their own ISP connection.
The laboratory verifies candidate strategies and provides results that can be manually transferred to the traffic configuration.
Current Features- Native OPNsense integration — WebGUI, service management, startup control, upstream Zapret2 installation, and version switching.
- Traffic Strategies — configurable TCP/UDP profiles using native dvtws2 syntax, HOSTLIST, IPSET, custom parameters, and domain exclusions.
- Strategy Lab — automated DPI bypass strategy discovery and verification, including TLS, HTTP, QUIC/HTTP3 and UDP testing, Standard/Extended modes, stability checks, and saved results.
- Voice Transmission — a dedicated configuration page for five UDP/STUN profiles: Telegram, Discord, X (Twitter), SIP (VoIP), and Custom. This functionality is experimental; successful voice calls are not yet guaranteed.
- Additional Lua/BIN Resources — optional installation and removal of supplementary Lua scripts and binary payloads, including dynamic integration into strategy discovery.
- Safe configuration management — transactional Apply, configuration validation, IPFW integration, runtime health checks, and rollback mechanisms.
- Bilingual WebGUI — English and Russian translations for settings, help, diagnostics, and status messages.
- Package management — a dedicated FreeBSD pkg repository with installation and update integration for OPNsense.
Architecture overviewTraffic Strategies and Voice Transmission share a single configuration model, a common Apply/rollback pipeline, managed IPFW rules, and one dvtws2 process.
Strategy Lab uses a separate temporary testing workflow, restores the original service state after testing, and does not automatically modify saved user strategies.
View the architecture diagram in the README (https://github.com/Tolian82/os-zapret2-restyle#architecture-overview)
Active Development and RoadmapThe project is actively developed, with several major improvements underway.
Current development — v0.6.1- Full IPv4/IPv6 dual-stack support — extending IPSET, Traffic Strategies, Voice profiles, IPFW, and Strategy Lab.
- Global Exclude IPSet — centralized IPv4/IPv6 destination exclusions applied to all regular and voice profiles.
- IPv6 Strategy Lab — optional dual-stack testing, independent A/AAAA destination checks, and updated adaptive testing budgets.
The IPv4/IPv6 and Exclude IPSet work has already reached published development builds. Source-level, CI, and selected installed-system tests have passed, but full live WAN/IPv6 validation remains in progress.
Further development and research- Voice/P2P — researching per-service UDP port ranges, dynamic peer endpoints, STUN, and additional media protocols.
- Strategy Lab — improving candidate selection, testing efficiency, diagnostics, cancellation, saved-job handling, and recovery after interrupted tests.
- Lua/BIN ecosystem — expanding supported resources, improving compatibility detection, and smarter generation of test candidates.
- Reliability — further improvements to service lifecycle management, package upgrades, cleanup, runtime verification, and failure recovery.
- Performance — evaluating additional test parallelism and other optimizations based on real-world results.
- Long-term goals — completing the project toward v1.0.0 and eventually porting it to pfSense.
Development priorities and implementation details are documented in the repository:
Development Roadmap (https://github.com/Tolian82/os-zapret2-restyle/blob/main/docs/ROADMAP.md)
Architecture and Technical Specifications (https://github.com/Tolian82/os-zapret2-restyle/tree/main/docs/architecture)
Compatibility, Releases and InstallationLatest stable release: v0.6.0
Current testing line: v0.6.1
Target platform: OPNsense 26.7 / FreeBSD 15 amd64
Runtime: bol-van/zapret2 (dvtws2)
License: MIT
Source code:https://github.com/Tolian82/os-zapret2-restyle
Stable release:https://github.com/Tolian82/os-zapret2-restyle/releases/tag/v0.6.0
Development/testing releases:https://github.com/Tolian82/os-zapret2-restyle/releases
Installation instructions:https://github.com/Tolian82/os-zapret2-restyle#installation-from-the-opnsense-web-gui
The project is currently distributed through an independent, unofficial package repository rather than the official OPNsense plugin repository.
Because it modifies firewall traffic processing and uses privileged services, I recommend reviewing the source code and starting with a test installation.
AcknowledgementsI'd especially like to thank
Umurcan Gorur (ugorur) (https://github.com/ugorur), the author of the original os-zapret2 (https://github.com/ugorur/os-zapret2) plugin.
His project inspired me to take my first steps into software development with AI assistance.
Although I've worked in IT for 26 years, my professional background is primarily in systems architecture. Software development is a new chapter for me, and this project has become a valuable learning experience.
What began with his original idea has gradually evolved into an independent project with additional functionality and its own architecture.
I'm sincerely grateful for his work, encouragement, and constructive feedback.
A very special thanks also goes to
bol-van (https://github.com/bol-van) for creating and maintaining Zapret2 (https://github.com/bol-van/zapret2).
The original Zapret2 engine and its DPI research form the technological foundation of this project. Without that work, this integration would not exist.
Feedback and Code Review WelcomeThis is an actively evolving open-source project, and I'd really appreciate feedback from the OPNsense community.
I'm especially interested in:
- Code review and security-related feedback.
- Testing on supported OPNsense installations.
- Suggestions for improving reliability, packaging, and maintainability.
- Strategy Lab testing results and reproducible bug reports.
If you find an issue or have a suggestion, feel free to reply here or open a GitHub issue.
GitHub — Tolian82/os-zapret2-restyle (https://github.com/Tolian82/os-zapret2-restyle)Thanks to the OPNsense community for your time and feedback!
Best regards,
Tolian82