DED9

Mikrotik IKEv2 Setup Guide (Updated)

These days, the use of the IKEV2 encryption protocol to set up a VPN between two computers, two sites, and a remote office branch has increased. Because the IKEV2 protocol is relatively new and has very good capabilities for building a virtual private network and sending and receiving information securely and encrypted.

The easiest way to set up an IKEV2 server is to use Mikrotik routers. Along with Winbox software and RouterOS operating system, Mikrotik routers give you many features in terms of VPN, firewall, and proxy server, and you can easily install and set up an SSH or web server and Telnet on them, and a local access license for each user. gave

Today, most of network engineers and professionals started using Mikrotik hardware and software to meet their needs, such as routing in the network and setting up all kinds of servers, including web servers, VPN servers, proxy servers, file servers, firewalls, etc..

If you are unfamiliar with these concepts and are interested in taking computer network training, We suggest you visit the following site to learn these concepts in a simple and practical language.

Mikrotik servers give you the highest stability and security and have high boot speed and a series of automatic processes to get things done. These servers can be installed in a few minutes, and a series of commands can be given to it so that these tasks can be done with high speed and stability without the need to log in multiple times and in a row or restart processes.

Setting up and setting up Mikrotik servers is also simple, and most of the time, you can copy these settings from one system to another. For this reason, in recent years, many businesses or network professionals have been interested in setting up a VPN with Mikrotik servers, and the relatively new IKEV2 VPN protocol has shone brightly. In this article, we first want to have a look at some concepts and protocols and then check the installation steps of the IKEV2 protocol on Mikrotik.

Familiarity with Mikrotik, Mikrotik router, Winbox, and RouterOS

If you have been in the world of network and security and Internet hardware, You have probably heard and seen these expressions. Some say Mikrotik is hardware, and others consider Mikrotik an operating system and software. One article talks about the Mikrotik server, and another article says Mikrotik router or network settings in the Mikrotik software!

We must say that almost all these terms and concepts are correct. Initially, in 1996, two MIT students from “Latvia” in Eastern Europe developed and marketed the MicroTik operating system. This operating system was based on the Linux kernel, but its biggest advantage was the ability to install on ordinary PCs based on Microsoft Windows.

What are IKE and IKEv2 protocols?

Internet Key Exchange or IKE is an IPSec-based tunneling protocol that provides a secure VPN communication channel and defines automatic authentication and negotiation for IPSec SAs in a secure manner.

The first version of this VPN protocol (IKEv1) was introduced in 1998, and the second version (IKEv2) was released 7 years later.

If you want to get acquainted with various types of secure protocols, we have a thoroughly professional tutorial for you, which we have provided a link to you.

Features of the IKEv2 protocol

Why use IKEv2:

Security: IKEv2 uses a server authentication certificate, meaning that no action will be taken until the requester’s identity is known. This feature will prevent DDOS attacks.

Speed: Complex architecture and an efficient IKEv2 messaging system can improve performance. In addition, its connection speed is significantly faster, especially due to built-in NAT traversal, which significantly speeds up the passage of firewalls and connection establishment.

Pros of IKEv2 protocol

Disadvantages of the IKEv2 protocol

Perhaps the only negative point of this protocol is the use of UDP port 500, which will block some firewalls.

Mikrotik IKEv2 Setup Guide

Modern operating systems (such as Windows 7 and newer) support the IKEv2 standard. Internet Key Exchange (IKE or IKEv2) is a protocol that establishes a security association within the IPsec protocol suite. Compared to IKE version 1, IKEv2 includes improvements such as support for Mobility via MOBIKE standard and greater reliability. Mikrotik IKEv2 setup allows you to manage anonymous and secure internet traffic of devices connected to your router and unblock geo-restricted content. This article will examine how to set up ikev2 in Macrotik.

Advantages of setting up ikev2 on Mikrotik

The main performance advantage of IKEv2 over L2TP/IPsec VPNs is that L2TP assigns only one source IP per client, whereas IKEv2 has no restrictions. If, for example, three Windows laptops connected to the same Internet connection point (WiFi hotel or hotspot) are trying to connect to the company’s VPN, only the last connected device will succeed. It means just a laptop. However, this problem can be solved using one mobile hotspot for each laptop, but the source IP will change. Also, this option is not always available.

IKEv2 VPNs don’t have this problem with L2TP VPNs, so you can connect as many clients as you want to the endpoint. IKEv2 is much more difficult to configure for the first time than L2TP/IPsec and even more difficult for first-time OSX users.

Mikrotik’s 6.41 release channel has an issue that results in a local issuer certificate invalidation error. Sometimes IKEv2 connects well with exactly one code. However, when using version 6.41, in many cases, you will encounter the error “local issuer certificate depth 0” in the Mikrotik Log in the IPsec section. Use the BugFix/Stable channel (currently 6.393) to fix this issue.

 

Licensing management

The MikroTik router is becoming a licensing authority that can sign the TLS server certificate and the licenses for the connected devices. This means connected computers are authenticated by the device, not by username and password. You must configure Radius authentication if you prefer to have the username and password in the Machine Permissions header. To issue a license, you can follow the example code below:

The default key expiration is 365 days (1 year), so set it to 3650 (10 years) to avoid validity issues. Set the VPN provider’s DNS address as the common name. For example, vpn.yourdomain.com. In this example, CA-Crl-Host is set as the LAN IP address of the device. In this way, we create a licensing management center that allows the issuance of licenses and certificates.

Configuring ikev2 settings in Mikrotik

Mikrotik’s ikev2 setup tutorial aims to have clients connect their VPN to a subnet to obtain their IP address from a DHCP server on the main LAN. Also, it allows you to manage the subnet of VPN clients with custom rules if needed, which is very useful for access control or traffic shaping.

How to setup ikev2 in MIkrotik

As mentioned, ikev2 is the protocol used to set up a security association in the IPsec protocol suite. Setting up ikev2 on Mikrotik can generally be summarized in three steps:

Launch manual VPN settings

Before setting up a VPN on the Mikrotik router, you must create IKEv2 settings on the KeepSolid desktop. For this, it is enough to go through a few simple steps. First, log in to your User Office system. Then press the Manage option to use KeepSolid VPN Unlimited services and follow these steps in order:

 

How to configure ikev2 Connection in Mikrotik

Configuring the ikev2 Connection in Mikrotik is complicated and requires careful attention. However, if you learn the setup and configuration steps and execute them correctly, you will not face many problems. To configure an ikev2 connection in Mikrotik, proceed as follows:

 

 

1. Fill in the profile fields

At this stage, you must enter the information required to create a new profile for the Mikrotik router in the specified fields. To correctly configure the ikrv2 Connection, the desired information must be entered correctly and as follows:

 

2. Create a new offer

Go to the Proposals tab on the same IPsec page and click Add New. To avoid technical problems, the fields presented to you in this step must be filled in a certain way. Fill in the relevant fields as follows:

3. Create a group

At this point, go to the Groups tab, and press the Add New option. Enter the name of the new group and click OK. Now you need to create an IPsec policy on your Mikrotik router. Go to the Policies tab and click on the Add New option. Fill in the fields as follows and click OK:

4. Choose a configuration name and create an IPsec peer

Go to the Mode Configs tab in the same IPsec section and press Add New. Enter the configuration name and click Apply è OK. Create an IPsec peer on the IPsec è Peers tab. Click on the Add New option. After entering the following information, click on Apply and OK:

 

 

 

5. Identification

After you have gone through all the mentioned steps, you need to create a new identity. To do this, first, select the Add New option through the IPsec è Identities tab, then fill in the provided fields in this order and select Apply è OK.

 

6. Check the Connection

The established connections can be checked through the Active Peers and Installed SAs tabs in the IPsec section. To send all traffic to the tunnel, you must create a list of addresses by your local network. To do this, select the Add New option through Firewall è Address Lists. In the Name field, select your local network and type the IP address and prefix length of the network in the Address field.

Now you need to assign this list to your mode configuration. To do this, go to IPsec è Mode Configs è KeepSolid-VPN, and select the list you just created from the drop-down menu in front of the Src field. Select Address List. Don’t forget to disable the FastTrack rule through Firewall è Filter Rules.

To get more technical information, you can use the training for setting up ikev2 in Mikrotik provided in the tutorial and benefit from the necessary training for setting up ikev2 on the Mikrotik router.

User management training with Mikrotik – click

Learn how to send the required traffic through the VPN tunnel

After completing all these steps to set up ikev2 on Mikrotik, it should learn to send only the traffic it needs through the VPN tunnel. To do this, do the following steps correctly and in order:

 

Filling the token connection field

If you followed the steps mentioned correctly, you should fill in the required fields to add a new Mangle rule. Just like the other fields mentioned in the ikev2 setup guide in Mikrotik, this field should also be filled with specific information:

The important thing is that if you have FastTrack enabled, you need to edit the rule. Selecting your connection mark in the relevant Connection Mark field is enough, and click on the OK option. This completes the setup of ikev2 on the Mikrotik router.

It should be noted that if you are interested in computer networks, their application, benefits, and security, you can gain expertise in your field of interest by referring to the extracurriculars and pieces of training provided in computer networks training.

We are setting up ikev2 on Mikrotik using Nord Vpn.

MikroTik routers with RouterOS user interface version 6.45 later allow creating an IKEv2 EAP VPN tunnel to a NordVPN server. To set up ikev2 on Mikrotik using Nord VPN, you can do this:

Specialized work requires specialized training.

In this article, we learned how to set up ikev2 in Mikrotik, but don’t forget that doing this is a rather specialized task. Therefore, if you intend to do your job in the best possible way, it is better to learn the necessary training first.

One of the ways to learn how to set up ikev2 in Mikrotik is to refer to the tutorial and view the provided tutorials. In extracurriculars, in addition to the mentioned training, you can benefit from computer basics training, software pieces of training, network security pieces of training and various other trainings. Do not forget that specialized training is the key to success.

Die mobile Version verlassen