OpenVPN Multi Socket Support
Important notices
Before you add a new report, we ask you kindly to acknowledge the following:
- [X] I have read the contributing guidelines at https://github.com/opnsense/core/blob/master/CONTRIBUTING.md
- [X] I am convinced that my issue is new after having checked both open and closed issues at https://github.com/opnsense/core/issues?q=is%3Aissue
Is your feature request related to a problem? Please describe.
Currently OPNsense 26.1.9-amd64 ships with openvpn 2.7.4 which supports multiple "local" variables. The WebUI currently only supports binding the openvpn instance to all IPs or just one ip.
Describe the solution you like
Allow configuring multiple "local" IP and port combinations. like:
local 10.10.10.10 1194
local 2001:db8::1 1194
Additional context
This new feature of openvpn has been published in the media: https://www.heise.de/en/news/OpenVPN-2-7-0-with-multi-socket-support-and-new-Windows-driver-11174406.html
With multi socket support it is possible to build dual stack setups per interface.
we're still thinking about it as it doesn't seem to offer a performance improvement as both will have the same (single core) bottleneck. Spinning multiple instances with the same configuration in practice might be a better alternative, but requires more work.
I dont think about this from a performance perspective. In my scenario i have multiple IPs on some interfaces with different services on them. On one ip there is NGINX running on Port 443 (dualstack). On the other interface maybe something else.
When you allow openvpn to bind on multiple different ips one can run it on tcp 443 on a interface with dualstack. The default config "*.443" (binding to all interfaces and ips) would cause issues with other applications like nginx.
+1 This also lets me to use same IP subnet for VPN clients on both TCP and UDP.
+1 This also lets me to use same IP subnet for VPN clients on both TCP and UDP.
We prefer UDP, but TCP on Port 443 works even through restrictiv Firewall like Hotels, etc and some Providers with Dual-Stack Lite and Carrier-Grade-NAT. With legacy we call a Script (learn-address under Advanced) to update the route to the client, if Protocol/Server-Instance has switched.
Would love to see this for an easy fallback to TCP, which I suppose is the primary use case of said protocol. If anyone is particularly concerned about performance, they may always decide to run a second instance as before.