

Find your firmware using this handy tool, and flash your router. If your router does not have OpenWRT firmware, check if it is compatible with OpenWRT here. In the following sections, the uci commands can be copy pasted into the OpenWRT shell, and some changes in the configuration pages using luci, and the router will be fully configured by the time you reach the last section. mwan3 allows for seamless switching between network interfaces, so that when the vpn connection fails or during command restarts, the network switches back to regular internet, so that our videos will keep playing, and will switch back the VPN network when it becomes available again. Once a working tunnel is setup, multi-wan ( mwan3) and a new network can be configured to enable VPN for all LAN and WiFi connected devices. These *.ovpn files can be used to create a tunnel, which appears as ‘ /dev/tun0’ in the OpenWRT device. VPN service providers usually provide OpenVPN configuration files for their servers. It has a lot of useful libraries in package manager opkg, of which we will use openvpn and mwan3 packages to create a multi-wan VPN router. It is easy to use and configure for many different applications. OpenWRT is a secure open source linux based firmware compatible with many routers. This is illustrated in the diagram below.

This will be more efficient than individual devices connecting to VPN directly, as all VPN related processing is done on this dedicated device instead of on each connected device separately. Red lines represent regular traffic which can be logged.Īfter configuring an OpenWRT router as described in this article, all LAN and WiFi connected devices will access the internet through one VPN tunnel opened by the router.

Any spies logging traffic cannot look inside the tunnel, making the communications secure. When a device connects to VPN using an app, it opens an encrypted tunnel to the VPN server, shown as the green line in illustration below.
