Todayβs users are increasingly faced with the need to bypass geographical constraints or provide additional security when working on the network. One of the most popular and time-tested solutions is the use of the L2TP/IPsec protocol. Owners of popular network equipment from the Chinese giant often wonder how to properly configure this type of connection on their devices.
The setup process may seem complicated for a beginner, but with the right approach, it takes only a few minutes. Xiaomi routers are famous for their minimalist interface, which, however, hides all the necessary tools for the advanced user. In this article, we will take a closer look at each step needed to create a stable environment. VPN-connection.
It is important to understand that the Xiaomi Router is a complex network device that runs on the OpenWrt operating system (or its modifications), which is why the approach to setting up here is different from installing an application on a smartphone. We will look at the work through the web interface and touch on the nuances of the mobile configuration.
Preparation for setup VPN-linkage
Before you go directly to enter parameters, you need to get the latest data from your provider. VPN-Without the exact server addresses, logins and passwords, the next steps are meaningless, and this information is usually available in the personal account on the service provider's website.
Make sure your router is connected to the Internet and you have access to the admin panel, and the device must be connected to your computer or phone via Wi-Fi or cable, and check that the router time is set correctly, as encryption protocols are sensitive to clock desynchronization.
β οΈ Attention: Before making any changes to network settings, it is recommended to back up the current router configuration so that in case of an error, you can quickly roll back.
You will need the following data to write down or keep on hand: server address, username, password and, crucially for L2TP, Pre-shared Key. Without this key, you will not be able to establish a connection, even if the username and password are correct.
Entrance to the router control panel
To start setting up, you need to log in to the administrative panel. Open any browser on a device connected to the router's network and enter the standard one in the address bar. IP-The most common address is 192.168.31.1 or the domain name miwifi.com.
Once you go to the address, the system will request an administrator password, and if you have changed it before, use the current code. If the password is lost, you will have to reset the device to factory settings, which will result in the loss of all current configurations.
Xiaomi Mi WiFi interface can be presented in Chinese or English, depending on the region of the firmware. Navigation is intuitive, but the names of the partitions may differ. VPN-client.
π‘
If the standard address 192.168.31.1 does not open, check your computer's network card settings β IP-The address must be automatically received through DHCP.
In some versions of the firmware, access to VPN-Customers are hidden in the "Additional settings" or "Advanced Settings" section, so that you do not miss the desired item.
Search and activation VPN-client
The interface of Xiaomi routers has undergone changes in different versions of the software. VPN-The client could be accessed "out of the box" in the Settings section β VPN. However, modern models often require the installation of a special plugin.
Find the Plugins or plugins section in the router menu. In the App Store, you need to find and install the VPN Client plugin or a similar one that supports L2TP protocols. This action will automatically add the corresponding item to the main settings menu.
After installing the plugin, go to the VPN management menu, and here you will see a list of supported protocols. We need L2TP/IPsec. Select it to create a new connection profile.
| Parameter | Default value | Change must be made. |
|---|---|---|
| Protocol | PPTP/L2TP | Yes (select L2TP) |
| Server address | Empty. | Yes (introduce IP/domain) |
| User name | Empty. | Yes. |
| Password. | Empty. | Yes. |
| Pre-shared Key | Empty. | Yes (required) |
If there is no plugin available VPN-The client, perhaps your router model has memory limitations or regional locks, in which case it is worth considering alternative methods of setting up or changing the firmware region.
Entering L2TP parameters and encryption keys
You open a form to fill in the data, and the first thing you do is, in the "Server Address" or "Server Address" field, you type in the data you've received from the provider. IP-address (e.g. 185.123.45.67) or domain name (vpn.example.com).
Then you fill in the authorization fields, enter your username and password in the respective username and Password fields, and notice the letter register, the system is sensitive to it, and a single character error will result in a denial of access.
The most important step is to enter Pre-shared Key (PSK), a field often referred to as "Secret Key" or "Shared Secret," which activates IPsec protection, without which L2TP is considered unsafe, and enters the key into a designated field, often hidden under the "Additional" or "Advanced" button.
βοΈ Verification of connection data
Some interfaces also require you to select an encryption algorithm, and it is recommended to leave the default value (usually AES-256 or Auto) as it provides the optimal balance between speed and security.
Configuring encryption and security algorithms
L2TP doesn't encrypt traffic by itself, it just creates a tunnel. The encryption is provided by the IPsec add-on, so it's critical to properly configure security settings in advanced connection settings.
In the encryption section, select AES-256, a modern standard that reliably protects data from interception, and older algorithms like DES or 3DES are not recommended for use because of their vulnerability.
β οΈ Note: Use of outdated encryption algorithms (MD5, SHA1) This may lead to the fact that modern VPN-Services will simply refuse the connection for security reasons.
If you have a choice between "Transport" and "Tunnel", for most use cases on the router, Tunnel mode is suitable, since it encrypts the entire data packet, hiding routing information.
Why is Pre-shared Key important?
After entering all the parameters, save the profile. Remember to click on the "Save" or "Apply" button, otherwise the entered data may be lost when the page reloads.
Starting a connection and diagnosing errors
After saving the configuration, return to the list VPN-Find the profile you created. L2TP and press Connect or Connect. The connection process can take anywhere from 5 to 30 seconds to set up.
If the connection is successful, the status will change to Connected, and the logs will contain an entry about the assigned internal IP-Now all traffic from devices connected to the router will go through a secure tunnel.
If you fail, check the error logs. Common problems include an incorrect PSK, an Internet provider blocking ports, or blocking the L2TP protocol itself in your country.
π‘
Successful L2TP connection on Xiaomi router requires the exact match of all four parameters: address, login, password and private key.
For diagnosis, you can use built-in router tools such as Ping or Traceroute by running them to the address. VPN-If the ping passes, but the connection is not established, the problem lies in the encryption settings.