Super User Asked by DaRk_St0rM on December 12, 2020
I have an OpenVPN server set up on my Raspberry Pi, when I installed it the guide I followed said to add a line like: push "route 192.168.1.0 255.255.255.0"
so that the server would let the client know that that network could be reached through the VPN, or so I understood.But now I’m using the Pi as a router to share a WiFi Internet connection with a computer,using the network 192.168.0.0,and so I was thinking of adding a route for that network that way, but I tried connecting before doing it and the PC can be reached without doing anything.
Doing a traceroute I saw that apparently 10.8.0.1 is the default gateway, so it can just reach it from there without a problem.
So I’m wondering, what is that statement really used for? It doesn’t seem to be necessary for making the client aware of the network, since all the traffic is going through the VPN anyway.
It is generally used to set routes to the VPN clients.
For instance, I use it to push 0.0.0.0 to one of the computers inside the VPN so all traffic is tunneled through the VPN.
In your case, it would seem that you are pushing a route to the LAN behind the VPN so you end up sending packets to the VPN tunnel endpoint to be forwarded to the LAN.
In which case, I would suggest to set the VPN using a bridged TAP device, which automatically sets the route to the internal LAN without the need for forwarding or NATing.
Answered by Imanol Barba Sabariego on December 12, 2020
2 Asked on August 5, 2020 by mill
1 Asked on August 5, 2020 by kaleb
1 Asked on August 4, 2020 by techhorse
1 Asked on August 1, 2020 by finn-rup-nielsen
1 Asked on July 29, 2020 by igrimpe
2 Asked on July 27, 2020 by saadq
1 Asked on July 26, 2020 by cicekadam
4 Asked on July 26, 2020 by aarav-prasad
2 Asked on July 24, 2020 by marcusw
Get help from others!
Recent Questions
Recent Answers
© 2022 AnswerBun.com. All rights reserved. Sites we Love: PCI Database, MenuIva, UKBizDB, Menu Kuliner, Sharing RPP