Very Confusing is OpenVPN Setup
-
@viragomann does this help?
-
The first step to configuring a VPN is understanding what it is you are actually doing.
On the client, connect the VPN. Then print the routing table.
Some common command lines:
Windows:
route print
Mac:netstat -rnfinet
Linux:netstat -rn4
You can use Diagnostics > Routes in the pfSense software.
-
@rwhitney said in Very Confusing is OpenVPN Setup:
I have set the route LAN network to 192.168.0.1/24
That should be 192.168.0.0/24 in the local subnets field. Unless you have set
Redirect IPv4 Gateway
in which case that should be not set anywhere as everything is routed.Steve
-
@Derelict please pardon my dust as I AM learning!
=========================================================================== Interface List 4...d0 17 c2 02 fb 3e ......Realtek PCIe GBE Family Controller 18...16 c6 3b 02 82 0f ......Microsoft Wi-Fi Direct Virtual Adapter 13...26 c6 3b 02 82 0f ......Microsoft Wi-Fi Direct Virtual Adapter #2 19...00 ff f9 1a 4d b8 ......TAP Adapter OAS NDIS 6.0 16...00 ff e2 a9 d8 ab ......TAP-Windows Adapter V9 10...74 c6 3b 02 82 0f ......Qualcomm Atheros AR9485 Wireless Network Adapter 1...........................Software Loopback Interface 1 =========================================================================== IPv4 Route Table =========================================================================== Active Routes: Network Destination Netmask Gateway Interface Metric 0.0.0.0 0.0.0.0 192.168.1.1 192.168.1.12 55 0.0.0.0 128.0.0.0 10.0.8.1 10.0.8.3 291 10.0.8.0 255.255.255.0 On-link 10.0.8.3 291 10.0.8.3 255.255.255.255 On-link 10.0.8.3 291 10.0.8.255 255.255.255.255 On-link 10.0.8.3 291 98.174.x.x 255.255.255.255 192.168.1.1 192.168.1.12 311 127.0.0.0 255.0.0.0 On-link 127.0.0.1 331 127.0.0.1 255.255.255.255 On-link 127.0.0.1 331 127.255.255.255 255.255.255.255 On-link 127.0.0.1 331 128.0.0.0 128.0.0.0 10.0.8.1 10.0.8.3 291 192.168.1.0 255.255.255.0 On-link 192.168.1.12 311 192.168.1.12 255.255.255.255 On-link 192.168.1.12 311 192.168.1.255 255.255.255.255 On-link 192.168.1.12 311 224.0.0.0 240.0.0.0 On-link 127.0.0.1 331 224.0.0.0 240.0.0.0 On-link 10.0.8.3 291 224.0.0.0 240.0.0.0 On-link 192.168.1.12 311 255.255.255.255 255.255.255.255 On-link 127.0.0.1 331 255.255.255.255 255.255.255.255 On-link 10.0.8.3 291 255.255.255.255 255.255.255.255 On-link 192.168.1.12 311 =========================================================================== Persistent Routes: None
-
@stephenw10 setting it to 192.168.0.0/24 does not seem to make a difference - I did have it set to Redirect IPv4 Gateway, but have removed that
-
Just to indicate my gratitude to everyone who has offered advice in this thread - thank you! (I am not yet connected to internal LAN however)
-
It's still sending route all and not just 192.168.0.0/24.
Try restarting the server end to be sure that new setting in place and then check the Windows client routing table.
Steve
-
@stephenw10 so reboot the netgate server? I will have to wait a couple of hours first
-
No. Restart the OpenVPN process. (Status > Services, stop it and start it. This is restarted when you make a change like disabling the redirect gateway push but Steve is just being thorough.)
-
@Derelict I just restarted the running process for openvpn. I did just notice that I am getting a connection error: key registration failed to occur within 60 seconds... I am trying this from a Windows laptop at work through an external wirelass network. I don't have this connectivity problem from home on my linux box - just from there I still cannot see the local LAN here at work. All I can see is the firewall
-
@viragomann Here is my server setting for Tunnel:
I do not see a setting for Remote Network in OpenVPN > Server
-
@rwhitney
That was wrong. It should be "Local Networks".
I'll correct it above. -
@viragomann Oh, so I do have something correct?!!
-
@rwhitney
Yeah! -
@viragomann
If I were to start from scratch, what would be the first thing to do? (setup the Cert?)
second: setup an openvpn server: (I think I have this set).
Third: setup a user?
Fourth: setup a user cert?
Fifth: download config from Client Export
What am I missing? -
Your setup looks well, however starting from scratch with the OpenVPN part may help making it work.
The cert should not be wrong as long as you've generated the correct type (CA, server, client).
Apart from this, I start with the certs:
CA
server
client(s)Then I set up the server and at last I export the config and install it on the client computer.
-
@viragomann ok this is quite helpful - now how do I populate the remote access server dropdown?
I created a new user certificate, am using an existing server cert and added a new client, but this does not appear in the remote access server list? (under Client Export) -
it seems to me the only way to populate the remote access server list is to use the wizard?
Yes, I see now that the wizard is for Remote Access Server setup specifically -
@viragomann I am having some success - I deleted all the old clients and severs except for one. Now I do not see the new clients in Client Export - also, there are some clients left over (in Client Export) after deleting them from clients.
Again thanks so much for all the help you have given me! -
Consider that the server and user certificates have to be from the same CA.
So in the client export tool, after selecting the server, you only get users whose certs are from the same CA as the cert of the selected server.