I have a home-installed OpenWRT router with OpenVPN server that I have been accessing remotely for years as I travel to various locations. Now as I travel I have begun to encounter more travel destinations that have IP6 enabled on the local router which is interfering with my VPN function since the IP6 is not being sent through the VPN which is configured only for IP4. As a result, the IP6 route is favored and the IP6 address shows as my real location and the IP4 as the VPN server is ignored by websites that I access.
Now as an option I can configure my Windows network adapter and set IP6 "off" and the VPN works but I would like to be able to issue a batch file called by the openvpn client to turn off IP6 for the time I am using the VPN and then turn IP6 back on after I am done with the VPN client so that I begin cloaking my home router's IP4 address when the VPN is active, the way it used to work before IP6 became so readily available.
What I could attempt is connect via VPN into my home router and configure it to support IP6 as well, but considering ho2 I know nothing about IP6, I would give that about a 90% failure potential and there is a possibility I could crash the home router if I diddle with it and configure something wrong, so that's why I am going the route of trying to block IP6 on my laptop when I use the VPN and restore IP6 when I am done.
I have done extensive research and the following commands are supposed to block the IP6 protocol but they don't.
One expert's suggestion that did not work:
netsh interface teredo set state disable
netsh interface 6to4 set state disabled
netsh interface isatap set state disabled
Another expert's suggestion that did not work:
netsh interface teredo set state disabled
netsh interface ipv6 6to4 set state state=disabled undoonstop=disabled
netsh interface ipv6 isatap set state state=disabled