Thank you all,

So it should be possible.


The OVPN-Client is a NAS and ip_forward is enabled.

I also added

iptables -t nat -I POSTROUTING 1 -s 0.0.0.0/0 -o bond0 -j MASQUERADE

to make the LAN behind it available. There is a existing one for tun0 which the 
NAS does "by itself".

Would it be better to set a route on modem2 ??? ...instead of MASQ on NAS but I 
have no access to modem2 at the moment, forgot password and is in another 
country.

Unfortunately Server and Client are both NAT`ed and cannot change that.


Windows 7 <--> pfSense <--> Modem1 <--WAN--> Modem2 <--> NAS


pfSense is Server, Site-to-Site with ccd


<Windows 7-192.168.30.9> <LAN-192.168.30/24> pfSense <WAN-192.168.11.11> 
<LAN-192.168.11/24> Modem1 <WAN>

<WAN> Modem2 <192.168.5/24> <NAS-192.168.5.250>


vpn-net is 192.168.158/24

pfSense server is 192.168.158.1

NAS is 192.168.158.3


Windows 7 with standard GW-192.168.30.1 can reach LAN "behind" NAS.

So that works but only I do not succeed to make NAS the GW for Windows 7.


I`ve tried to play with GW on Windows but I see that metric is not set as I 
tell it to, must be me or Windows doing what it wants :)

Thanks.

________________________________
Van: Alarig Le Lay <[email protected]>
Verzonden: maandag 22 augustus 2016 20:10:32
Aan: [email protected]
Onderwerp: Re: [Openvpn-users] Client as exit point?

On Mon Aug 22 17:15:07 2016, Dreetjeh D wrote:
> Hello,
>
>
> Yes, that`s what I mean.
>
> Ideally the Window 7 machine would use the OVPN-Client as GW/exit point "on 
> the fly"
>
> With on the fly I mean, VPN-ON.cmd and VPN-OFF.cmd on Windows 7 for example.
>
> I thought maybe it could be done by changing gateway but can`t get it working.
>
>
> Thanks.

You have to do NAT and IP forwarding on your OVPN client. I don’t know
how to do this on windows… I never touched something like that since
many years. But it’s pretty simple to do this on Linux, FreeBSD or
OpenBSD.

--
alarig
------------------------------------------------------------------------------
_______________________________________________
Openvpn-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/openvpn-users

Reply via email to