OpenVPN for Private Network

This forum is for admins who are looking to build or expand their OpenVPN setup.
Forum rules
Please use the [oconf] BB tag for openvpn Configurations. See viewtopic.php?f=30&t=21589 for an example.
Post Reply
Basskick
OpenVpn Newbie
Posts: 3
Joined: Thu Apr 15, 2021 1:27 pm

OpenVPN for Private Network

Post by Basskick » Thu Apr 15, 2021 2:03 pm

Hello everybody,
I am currently trying to set up a private LAN for friends & family via OpenVPN, but I'm biting my teeth.

I get a connection to my server and pinging to other clients or to the server and each other also works, as does the direct file access.

But the network is recognized as a public network in Windows, both at the client and at the server. I tried to change this via the registry, it worked but only resulted in it becoming an unidentified network with the connectivity: No network access.

- The funny thing about it: The network access works.

During my research on the Internet I came across various solutions, such as "pushing a 0.0.0.0 route" but unfortunately none of them worked so far.

That's why I have to ask you for help and I hope someone has a solution.

As I said, I only want a LAN network for file sharing and gaming, I don't want to have the Internet routed from the server to the clients, and I don't want to hide any IPs either .

Here are my configs:
Server.ovpn
SERVER CONFIG:

server

port 1194
proto udp4
dev tun

ca "C:\\Program Files\\OpenVPN\\config\\ca.crt"
cert "C:\\Program Files\\OpenVPN\\config\\server.crt"
key "C:\\Program Files\\OpenVPN\\config\\server.key"
dh "C:\\Program Files\\OpenVPN\\config\\dh.pem"

server 192.168.143.0 255.255.255.0

keepalive 10 120
cipher AES-256-GCM
client-to-client
user nobody
group nogroup

push "route 192.168.143.0 255.255.255.0"

persist-key
persist-tun
verb 3
explicit-exit-notify 1
client-config-dir "C:\\Program Files\\OpenVPN\\config\\ccd"
ifconfig-pool-persist "C:\\Program Files\\OpenVPN\\log\\ipp.txt"


Client.ovpn
vCLIENT CONFIG:
client

client
dev tun

proto udp
remote XXX.de 1194
resolv-retry infinite
nobind
persist-key
persist-tun

ca ca.crt
cert client1.crt
key client1.key

remote-cert-tls server
cipher AES-256-GCM
verb 3


Sry about my english, im from germany.
Last edited by Basskick on Thu Apr 15, 2021 3:38 pm, edited 2 times in total.

User avatar
TinCanTech
Forum Team
Posts: 9248
Joined: Fri Jun 03, 2016 1:17 pm

Re: OpenVPN for Private Network

Post by TinCanTech » Thu Apr 15, 2021 2:21 pm

Basskick wrote:
Thu Apr 15, 2021 2:03 pm
the network is recognized as a public network in Windows
That is correct and all that you need.

Basskick
OpenVpn Newbie
Posts: 3
Joined: Thu Apr 15, 2021 1:27 pm

Re: OpenVPN for Private Network

Post by Basskick » Thu Apr 15, 2021 3:28 pm

no way to work as a recognized privat network ?

User avatar
TinCanTech
Forum Team
Posts: 9248
Joined: Fri Jun 03, 2016 1:17 pm

Re: OpenVPN for Private Network

Post by TinCanTech » Thu Apr 15, 2021 3:50 pm

Basskick wrote:
Thu Apr 15, 2021 3:28 pm
no way to work as a recognized privat network ?
No sensible way that I know of.

It is easier to configure a rule for your VPN network in Windows firewall.

Basskick
OpenVpn Newbie
Posts: 3
Joined: Thu Apr 15, 2021 1:27 pm

Re: OpenVPN for Private Network

Post by Basskick » Thu Apr 15, 2021 4:23 pm

ok, well thank you :)

Post Reply