# VPN access with overlapping network addresses



## D-FENS (Nov 9, 2022)

I use OpenVPN to log into a corporate network with a network IP range 10.0.0.0/8. This works when at home when my LAN's network address is 192.168.0.0/24.
However, in an Internet Café the LAN network IP is also 10.0.0.0/8 and when I start the VPN the routes get overwritten and all packets are suddenly lost due to the clash.

The VPN's network address is set by the company and I cannot change it. Also, the Internet Café's LAN is non configurable. I could play with virtual machines or jails on my notebook and use them as routers if necessary.

Do you have any ideas how I could connect to the corporate VPN and communicate with hosts on it as simply as possible? I have looked into this solution but it requires NAT on external routers. I could create a VM and use it as a router, then do a two-sided NAT as suggested in the link. Is there a simpler solution?

Thanks.


----------



## covacat (Nov 9, 2022)

@the cafe, before starting the vpn 
just route add -host 10.0.1.2 -interface re0
where 10.0.1.2 is the default gw you get from the cafe's dhcp and re0 is your interface
if the most important server on the corporate network has same ip with the cafe's gw you are out of luck


----------



## Eric A. Borisch (Nov 9, 2022)

I recall running into this once; I manually set my IP to the assigned-via-dhcp one with /32 netmask, as I recall.


----------

