OPNsense Forum

English Forums => Tutorials and FAQs => Topic started by: Dayve on August 12, 2020, 01:50:12 PM

Title: How to setup VPN client to Vlan?
Post by: Dayve on August 12, 2020, 01:50:12 PM
I just switched over to opnsense from Pfsense. With Pfsense I setup a VPN to my Vlan20. I just cannot figure it out with Opnsense. I do not want to have my LAN traffic on the VPN. Just the clients on the Vlan20.

Would anyone have some info on how to do this?
Title: Re: How to setup VPN client to Vlan?
Post by: Koldnitz on August 13, 2020, 05:11:29 AM
https://forum.opnsense.org/index.php?topic=4979.msg25066#msg25066 (https://forum.opnsense.org/index.php?topic=4979.msg25066#msg25066)

I think if you put the VLAN in vpn_users alias it will work .... I use 192.168.1.240/28 in said alias and it works for 14ish IP addresses.

NilsS setup works pretty well but you will probably need to customize it for your needs (the opnvpn configuration), the way he has the routing and aliases works and it has builtin DNS leak protection.

Cheers,
Title: Re: How to setup VPN client to Vlan?
Post by: Dayve on August 21, 2020, 10:58:20 AM
Thanks for the information. I was able to get my VPN Interface to the VPN. All I was missing was setting the DNS in the interface and a allow rule to the DNS.

Cheers