Pi-Hole-on-Google-Compute-Engine-Free-Tier-with-Full-Tunnel-and-Split-Tunnel-Wireguard-VPN-Configs icon indicating copy to clipboard operation
Pi-Hole-on-Google-Compute-Engine-Free-Tier-with-Full-Tunnel-and-Split-Tunnel-Wireguard-VPN-Configs copied to clipboard

Is it possible to allow wireguard only for some IPS

Open xtendtech opened this issue 4 years ago • 3 comments

Hi, I want to enable VPN of wireguard only for certain IP address. Eg: I want all data for google.co.in to go through vpn and in normal case all should go outside vpn to reduce data. Certain services need country based Ip's . In Openvpn we have that option (Atleast for OpenVpn) But cannot find such option for Windows .Is it possible somehow

xtendtech avatar Oct 02 '20 06:10 xtendtech

you may have to do some research on arin.net or some other websites to determine which IP ranges are used in India.

this list may be a good start

https://md5calc.com/google/ip

rajannpatel avatar Oct 04 '20 00:10 rajannpatel

I know the ip range But quick question is how do I allow only this range to go through vpn and make the rest data go normally? Openvpn client has such options but cannot see it in wireguard. I was asking if wg has some option to skip or route only certain ips or ranges?

xtendtech avatar Oct 04 '20 06:10 xtendtech

In the Client Configuration, set the destinations you wish to route through the Wireguard connection in the AllowedIPs key value pair.

rajannpatel avatar Oct 09 '20 23:10 rajannpatel