Sunday, March 1, 2020

Need help with making a IKEv2 VPN server from a Ubuntu VirtualBox

I've been trying to make a VPN that uses the IKEv2 protocol using StrongSwan on Ubuntu following the instructions following this link: https://www.digitalocean.com/community/tutorials/how-to-set-up-an-ikev2-vpn-server-with-strongswan-on-ubuntu-18-04-2

i will try to give as much detail as possible to what i did following the instructions given.

in Step 1 i updated the local package cache as told to do, installed the StrongSwan package

in Step 2 i did the command : mkdir -p ~/pki/{cacerts,certs,private} , i was not too sure if i had to exactly that line so i did and also did all 3 individually : mkdir -p ~/pki/cacerts ""/certs and ""/private after that i just copy pasted the 3 command lines in.

In Step 3 i followed the steps, in the second part where i had to put a cn and a san i put 192.168.5.220 which is different from the VirtualBox that has a 192.168.5.12 ip, not sure if i was supposed to put the machine's ip or if i was supposed to do what i did.

In Step 4 the first part where i had to type in sudo mv /etc/ipsec.conf{,.original}, that one like the first one, i wasn't sure if i was supposed to copy paste the whole thing including "{,.original} but i did and it seemed to work, continued to follow the steps, where i had to put in an address next to "leftid:" i put in 192.168.5.220 again.

Step 5 followed the steps and restarted StrongSwan.

Step 6 i added the exceptions to the firewall, in before.rules i put instead of 10.10.10.0/24 i put 192.168.5.0/24 not sure either if that was what i was really supposed to do, for the rest i followed the steps and retarded the firewall.

Step 7 i retrieved the certificate, added it to another VirtualBox, could not connect, tried to add it the host, did not work, and could not make it work from my phone, all 3 devices got the unreachable error or Error 809. I could ping the ip 192.168.5.220 from the other VirtualBox(Win7) but got :

Reply from 192.168.5.14 : Destination host unreachable. 0% loss

Sorry for the long text, not sure if i did everything properly, did i do something wrong?



No comments:

Post a Comment