First I installed three Virtual Machines in HyperV. One VPN Client, VPN Server, and a Domain Controller. On the DC Server, I added the role DHCP Server so that the new Connected VPN Client will receive an IP address from the range 192.168.1.50 /24 – 192.168.1.99 /24. Also, I created a Domain User, so this User can be used to log in to the VPN Server and in the Domain.
VPN Server has two NICs:
On this Server, I Installed the Remote Access Server Role and configured a VPN access. I specified that the VPN connection should be through L2TP/IKEv2 Protocol and created a preshared key, this preshared key will be used also on the VPN Client-side for establishing the connection.
With the Network Policy Server Tool, I created an access policy to define which Users and Groups are allowed to connect to the VPN Server and also define the type of authentication.
On the VPN Client VM, I configured a Static IP address 22.214.171.124 and it is directly connected to the VPN Server WAN side (because it is a test environment all Virtual switches are private and it is simulated as an Internet connection), and set up a new connection.
On the new VPN Connection adapter, I specified the VPN type to L2TP and used the preshared key from the VPN Server. Also specified is the EAP MSCHAP v2 Authentication protocol.
Entered the credentials from the Domain user that I created earlier and the connection was established. The Client received an IP address from the DHCP Server and it is connected to the LAN.