• How to set up your own VPN server. How to set up a VPN connection in different versions of Windows

    Greetings! And straight to the point. What is a VPN server for? It is mainly used to change the IP address and your country in order to bypass various site blocking at work and at home. In addition, a VPN connection helps to encrypt the traffic and thus ensures the security of the transmitted data.

    For example, using public Wi-Fi, all data transmitted through the network can be “hijacked”. Theoretically, these could be any files, but usually they steal passwords from wallets, mail, Skype, and anything else. In this article we will configure own VPN server, it's not difficult. Despite the volume of the text, the main action occupies a small part, and the rest is buns. The article also contains a video.

    There are a lot of them on the Internet, some small ones, from free to very paid ones. Disadvantages of free VPN services:

    • limited in speed
    • instability (everything is fine, then it’s terribly slow)
    • traffic restrictions (up to several Gigabytes per month)
    • Free period restrictions
    • periodically you need to look for other services
    • It’s not a fact that the transmitted data will be safe; you shouldn’t hope for anonymity at all, I would say.

    Disadvantages of paid ones:

    • the desired country or city is not always available
    • hackneyed IP addresses (used by hundreds of clients), also applies to free ones
    • there is simply a scam without a refund, for example, the traffic is not unlimited, some servers do not work or are too slow

    There are also advantages of VPN services - ease of use and relative cheapness.

    Own VPN server on VPS/VDS hosting

    So, if you need a specific country or city, or you need a lot of traffic that VPN services do not provide, or a guarantee of security, then it makes sense to bother setting up a personal VPN server. Typically, this requires in-depth knowledge of server system administration. But I tried to explain everything simply so that even a teapot could understand it)

    This method also has disadvantages:

    • there is only one IP address to which you can “transfer”, but there are additional ones for a fee
    • non-trivial setup for the first time
    • paid

    Read to the end, and I will show you how to use your VPS server to bypass blocks without setting up a VPN on it.

    What is a VPS/VDS server?

    There are countless hosting providers on the Internet. All of them allow you to host your websites with them. The most popular service is virtual hosting. More advanced is dedicated virtual server– VPS (VDS is the same thing). On VPS you can host websites, set up a VPN server, mail server, game server– yes, whatever!

    You need to know that VPS servers come in several types: OpenVZ, Xen and KVM. For the VPN server to work you need KVM. The server type is indicated in the hosting plans. OpenVZ and Xen are also sometimes suitable, but you need to write to the hosting technical support and ask if the “TUN” module is connected. Without going into details about what it is for, just asking. If not, can they enable it. It also doesn't hurt to ask if the VPN itself will work (even on KVM), because... some companies cover this possibility. Oh yes, the server operating system is Debian, Ubuntu or CentOS (in general, Linux-like). Server power doesn't matter.

    Setting up a VPN server

    I have a KVM VPS server at my disposal. Everything works here right away, you don’t need to write anywhere.

    • When ordering a service, you can choose the simplest one tariff plan"Micro"
    • All sites open even on servers in Russia
    • There is a free trial period of 7 days
    • Technical support helps
    • For my visitors, when you enter the promotional code: itlike60 - you will receive a real 60% discount on your first payment.

    “Hostname” enter any or the name of your site (if you will in the future). “OS Template” select “Ubuntu 14.04 64bit” or any of Ubuntu, Debian, CentOS:

    The operating system can then be changed if suddenly something does not work out.

    After payment, you will receive an email with login details for the control panel and a Root password for setting up the server. And also the IP address of the server, and this will be your IP address when we install a VPN and connect to it from a computer

    Click the “Manage” button and get into the administration window:

    We don't need to touch anything here. The only thing that may be needed is to reinstall the operating system - the “Reinstall” button, more on that later.

    Now we need to connect to the server to send commands to it. For this we will use free program Putty.

    Unpack the archive with the program and run the file

    putty.org.ru\PuTTY PORTABLE\ PuTTY_portable.exe

    In the “Host Name” field we paste the IP address of the server that came in the letter, you can also copy it from the control panel:

    and click “Connect”. If a window like this pops up, then click “Yes”:

    A black console window (command line) should appear in front of us. This is where we will give commands. But first you need to log in. To do this, enter “root” in the “login” field

    Then copy the root password from the letter and paste it into the “password” field. To paste here from the clipboard, you just need to right-click once on the console window. However, the password is not printed on the screen, it feels like nothing happened. Everything is fine, press “Enter”. Lines with information about the system should appear. If you wrote some error, check everything again. Also, the console will not wait long while you look for the root password. If by that time an error occurs, then launch Putty again.

    Installing and running the main script

    We are already at the finish line in setting up our own VPN server. There are many instructions on the Internet on how to install a server, but they all require knowledge system administrator, because small nuances are overlooked. To the delight of all dummies, there is a universal script “OpenVPN road warrior” that will do all the work itself. We only need to give the command to download and run it.

    So, copy this line and paste it into the console window with the right button and press “Enter”:

    wget https://git.io/vpn -O openvpn-install.sh && bash openvpn-install.sh

    All sorts of lines will flash through and, if the script has been successfully downloaded and launched, a dialogue with us will begin with the VPN server setup wizard:

    The script finds the expected value for each parameter and offers to agree with it, i.e. Press “Enter” or enter your value.

    1. The first parameter is "IP address". The script should offer the same IP of the VPS server. This should be the case in 99.9% of cases, but if for some reason this is not the case, then correct it to the correct address.
    2. Second - protocol UDP or TCP. Leave the default UDP.
    3. Let's move on "Port: 1194"- we agree.
    4. "What DNS do you want to use with the VPN?"— select “Google”, i.e. Enter the number “2” instead of one, Enter. If Google is blocked, then we leave it as default.
    5. "Client name"— username. You can create access for different users. By default “client” - we agree.
    6. "Press any key..."— press “Enter” and wait a few minutes until everything is installed and configured.

    In general, the creation of a VPN server is now complete, it’s time to reap the benefits. During the installation process, the script created a file with settings for our computer. In order for us to use the server, this file must be downloaded. To do this, insert into command line:

    cat ~/client.ovpn

    The contents of the “client.ovpn” file will be displayed on the screen. Now you need to carefully copy it to the clipboard. Scroll up until you enter the command, select with the mouse all the lines except the very last one (for new commands), i.e. the last highlighted line will be “ " To copy the selection to the clipboard, press “Ctrl-V”.

    Now on a computer in Windows 7/8/10, open Notepad and paste the copied text into it. Save the file on your desktop under the name “client.ovpn”.

    If you plan to give access to the server to other people, then it is better to create separate files for them, for example vasya.ovpn. To do this, simply run the script again and now select the 1st item - creating a new user.

    Client installation for Windows 7/8/10/XP and Android

    Congratulations, we are at the finish line! Now all that remains is to install a free program that will connect to our VPN server. It's called "OpenVPN".

    Download the version for Windows and install it, no need to run it.

    If during the installation process all sorts of windows pop up, we agree with everything.

    To connect to the server, right-click on the “client.ovpn” file on the desktop and select “Start OpenVPN on this config file”:

    A black window will appear indicating the connection initialization process. If everything went well, then the last line should be something like:

    A window may also pop up with a question like new network, then select “Public Network”.

    You can check, go to the website 2ip.ru and look at your IP, it must match the IP of the VPS server:

    The server console window can now be safely closed. And to close the VPN connection and return the old IP, you need to close the OpenVPN window.

    To connect next time, just right-click the “client.ovpn” file from the desktop, you don’t need to do anything else.

    With a phone It’s even simpler, you need to install the OpenVPN application through the playmarket, download the client.ovpn file into memory, select it in the application and connect to our VPN server.

    What if something went wrong

    If you feel that because of your mistake everything is now going wrong, then you can reinstall operating system on hosting. To do this, click “Reinstall” in the control panel (see screenshot of the panel) and select a new operating system (or the same one):

    Press the “Reinstall” button and wait 10 minutes. A new Root password will also be issued, do not lose it!

    Connection errors

    Most problems arise at the stage of connecting to the server in the OpenVPN program, especially in Windows 8/10. The black window may contain errors, for example:

    • FlushIpNetTable failed on interface
    • All TAP-Win32 adapters on this system are currently in use
    • CreateFile failed on TAP device
    • DNS failed..

    In this case, the first thing to do is to give the program administrator rights and, accordingly, log into the system with administrator rights. Let's go to "C:\Program Files\OpenVPN\bin\", right-click on the file openvpn.exe -> properties. On the “Compatibility” tab, check the “Run this program as an administrator” checkbox. Now everything should work.

    More treatment options:

    • remove the program and reinstall as administrator
    • disable the Routing and remote access» (“Routing and Remote Access”) via “Control Panel -> Administration -> Services”
    • try reinstalling from or here
    • remove all VPN programs and gadgets from other paid and free services

    You can find out whether the problem is with your computer or laptop if you install the OpenVPN application on your phone or tablet through the play market, upload the client.ovpn file to it and connect to our VPN server. If this doesn’t work, then you need to look for the reason on the server and write to support.

    If everything works, the sites are stuck and open intermittently

    Pay attention to the messages in the black window to see if there are repeated lines “read from TUN/TAP ... (code=234)”

    and also to the message somewhere in the middle “WARNING: ‘tun-mtu’ is used inconsistently, local...”:

    In this case, open the client.ovpn file in Notepad and in the new very first line write:

    tun-mtu 'server value'

    server value is the number indicated at the end of the line in the text “remote=’tun-mtu 1500′”. Substitute your meaning! In the end it should look like this:

    This is done because for some reason the MTU value on the computer and on the VPS server are different. We leave the .ovpn file for the smartphone untouched!

    We allow traffic through a proxy without any settings at all

    You can use our VPS/VDS server as a Proxy Server. To do this, we do everything as before until we click the “Connect” button in the Putty program. There is no need to open the console and run the script. Go to the “SSH->Tunnel” tab, enter Source Port: 3128

    Oops, I finished the article later, here I have Putty in English, but the essence is the same.

    If it writes the error “You need to specify a destination address in the form host.name:port”, then switch to “Dynamic” instead of “Local”.

    On the “Connection” tab, in the “Seconds between keepalives...” field, set it to 100 seconds, this is necessary so that the connection does not break due to downtime. Now let’s connect - click “Open” and enter your login/password. Next, go to the network settings in the browser and register the proxy server there. In chrome it's “Settings->Search for settings->write ‘proxy’->Proxy server settings.” We do everything as in the screenshot:

    Now all sites will work through our server, but only in the browser and some programs. Other programs will not see the proxy and will work directly. In each program, in the connection settings, if provided, you need to specify the address, port and proxy type: Socks4/5. Or install OpenVPN and don't use a proxy.

    How to allow only certain sites through a proxy

    Install the extension for Google Chrome or Mozilla Firefox, called . In the settings you need to add our proxy server:

    On the “URL Patterns” tab we add masks for sites that should be opened through our server. The site mask is its name with asterisks on the sides.

    That's it, now the added site will go through a proxy, and all others will go directly. If you click on the extension icon, you can choose to allow all sites through it or none at all.

    Shortcut for automatic connection

    You can connect Putty to a proxy with one click. To do this, before connecting, you need to enter the server login in the “Connection->Data” section, the one that usually root

    Now you need to create a shortcut on the desktop in which you specify the following parameters:

    “C:\Program Files\PuTTY\putty.exe” -load myvpn -pw server_password

    Where myvpn is the name of the saved session. That's it, there is only one detail left - remove the Putty window from the taskbar to the system tray. You need to download a modification of the utility and replace the exe file. Now in the settings tab Behavior a corresponding check mark will appear, but you don’t have to do this.

    Telegram was blocked, free proxies and VPNs work intermittently due to a large influx of users or completely stop functioning without explanation, like.

    Paid tools can also disappear at any time: the law banning anonymizers and VPNs was passed a long time ago, but has not yet been applied. In this situation, the only guarantee of freedom on the Internet is your own VPN. Lifehacker will tell you how to set it up in 20 minutes.

    Choosing hosting

    To set up a VPN, you need a VPS - virtual private server. You can choose any hosting provider, as long as the following conditions are met:

    • The server is located in a country that does not fall under the jurisdiction of Russian authorities, but is quite close to your real location.
    • Random access memory (RAM) must be at least 512 MB.
    • Speed network interface- 100 MB/sec and above.
    • Network traffic- 512 GB and above or unlimited.

    The amount of allocated hard disk space and the type of drive does not matter. You can find a suitable solution for $3–4 per month.

    When purchasing a server, choose KVM. OpenVZ and Xen are also suitable if they have TUN connected - you need to ask about this at technical service hosting provider.

    There is no need to perform any additional manipulations with KVM, although some hosting providers may limit the ability to create a VPN on it. You can also clarify this with the support service.

    When setting up a server, you can enter any value in the “Hostname” item: for example, test.test. The prefixes NS1 and NS2 are also not important: we write ns1.test And ns2.test.

    Operating system - CentOS 7.4 64 bit or any other distribution, fundamental differences not in the settings. Network traffic leave 512 GB or select additional volume, if you are afraid that what you have is not enough. Location - the closer, the better. The Netherlands will do.

    After payment, you will receive an email with all the necessary data to set up a VPN. You have purchased space on a server in another country, all that remains is to redirect all traffic to it.

    Setting up a VPN

    To connect to the server and send commands we will use the Putty program. I received a link to it in an email with registration data for hosting. You can download the program. Putty and its analogues are also available on macOS, the settings will be identical.

    Launch Putty. On the Session tab, in the Host Name field, enter the IP address that came in the letter and click Open.

    When a warning window appears, click Yes. After this, the console will launch, through which you will send commands to the server. First you need to log in - the authorization data is also in the letter from the hoster. Login will be root, type it by hand. Copy the password to the clipboard. To paste the password into the console, right-click and press Enter. The password will not be displayed in the console, but if you are logged in, you will see information about the system or server number.


    There should not be much time between entering your login and password. If an error message appears, restart Putty and try again.

    To configure the VPN, I used the ready-made OpenVPN road warrior script. This method does not guarantee complete anonymity, so the user can be easily found when committing illegal actions. But it is enough to bypass the blocking. If all VPN services stop working, this connection will continue to function as long as I pay for hosting.

    To use the script, paste the line wget https://git.io/vpn -O openvpn-install.sh && bash openvpn-install.sh into the console.

    After successfully adding the script, a dialogue with the setup wizard will start. It independently finds the optimal values, all you have to do is agree or choose suitable option. All actions are confirmed by pressing the Enter key. Let's go in order:

    1. The IP address must match the IP address that you received in the letter from the hoster.
    2. Leave the default protocol as UDP.
    3. Port:1194 - agree.
    4. Which DNS to use - select Google. Erase 1 , write 3 and press Enter.
    5. Client name - enter the user name. You can leave client.
    6. Press any key - press Enter again and wait until the settings are completed.

    After completing the setup, you need to create a file through which you will connect to the VPN. Enter the command cat ~/client.ovpn.

    The contents of the file will appear in the console. Scroll up to the command cat ~/client.ovpn and select everything that appears below except the last line. The selection should end at. To copy a fragment, press Ctrl + V.

    Launch Notepad, paste the copied fragment and save the file on your desktop with the name client.ovpn.

    Connecting to the server

    To connect using the created file, you need an OpenVPN client. The computer version can be downloaded. Download and install the program, but do not run it. Right click on the file client.ovpn and select Start OpenVPN.

    A console window will appear with the connection initialized. If the connection was successful, the Initialization Sequence Completed status will appear below. During the connection process, a network selection window may appear, click on the public network.

    To make sure the connection is correct, . It must match the one the hoster wrote in the letter. To stop sending requests to a server in another country, close the OpenVPN window.

    OpenVPN also has clients for mobile devices.

    To establish a connection, transfer the file to the phone memory client.ovpn. Launch the application and select OVPN Profile. Specify the path to the file and move the slider to the “Enabled” position.


    A VPN connection icon will appear at the top. To verify that traffic is being routed through a server in another country, open mobile browser any IP address checking service.

    Instructions

    Click on the Start menu and select Control Panel. Find the "Network and Internet" section. To organize a VPN connection, you need to launch the Network and Sharing Center snap-in. You can also click on the network icon in the tray and select a similar command. Proceed to create a new connection or network, noting that you need to connect to your desktop. Click the "Next" button. You will be prompted to use an existing connection. Check the box "No, create a new connection" and go to next stage settings.

    Select "Use my Internet connection" to set up a VPN connection. Set aside the Internet settings prompt that appears before continuing. A window will appear in which you need to specify the VPN server address according to the agreement and come up with a name for the connection, which will be displayed in the Network and Sharing Center. Check the “Don’t connect now” checkbox, otherwise the computer will try to establish a connection immediately after setup. Check Use Smart Card if the remote VPN host authenticates the connection using a smart card. Click Next.

    Enter your username, password and domain, according to which you gain access to the remote network. Click the “Create” button and wait until the VPN connection is configured. Now you need to establish an Internet connection. To do this, click on the network icon in the tray and start setting the properties of the created connection.

    Open the Security tab. Set "VPN Type" to "Automatic" and "Data Encryption" to "Optional". Check "Allow the following protocols" and select the CHAP and MS-CHAP protocols. Go to the “Network” tab and leave a checkmark next to “Internet Protocol Version 4” only. Click the "Ok" button and connect the VPN connection.

    Any VPN net provides for the presence of a specific server that will provide communication network computers and other devices. At the same time, it provides some of them (or all) with access to an external network, for example, the Internet.

    You will need

    Instructions

    Most simple example VPN network can be created local network between , each of which will access the Internet. Naturally, direct connections Only one PC will have access to the provider's server. Select this computer.

    Install an additional network adapter into it, which will be connected to the second computer. Using a network cable of the required length, connect the network cards of two computers to each other. To another network adapter main PC, connect the provider cable.

    Set up your Internet connection. This can be a LAN or DSL connection. In this case it doesn't matter at all. Once you've completed creating and configuring your new connection, go to its properties.

    Open the "Access" menu in the window that appears. Allow all computers that are part of a specific local network to use this Internet connection. Specify net, formed by your two computers.

    IN lately Methods of accessing the Internet through VPN networks are becoming increasingly popular. This allows you to maintain maximum confidentiality, as well as visit web resources blocked for various reasons by providers. Let's see what methods you can use to set up a VPN on a computer running Windows 7.

    Setting up a VPN in Windows 7, like most other tasks in this OS, is carried out using two groups of methods: by using third party applications and using only the internal functionality of the system. Next, we will consider in detail these methods for solving the problem.

    Method 1: Third Party Programs

    Let's immediately look at the algorithm for setting up a VPN using third-party applications. We will do this using the example of the popular Windscribe software. This program good because, unlike others free analogues can provide a fairly high-quality connection level. But the limit of transmitted and received data is limited to 2 GB for anonymous users and 10 GB for those who indicated their email.

    1. After downloading, run the program installer. In the window that opens, you will be offered two installation options:
      • Express installation;
      • Selective.
    2. The installation procedure will start.
    3. After its completion, the corresponding entry will be displayed in the installer window. If you want the application to launch immediately after closing the window, leave a checkmark in the checkbox "Launch Windscribe". Then click "Finish".
    4. Next, a window will open asking if you have a Windscribe account. If this is your first time installing this program, then click "No".
    5. The browser that is assigned by default in the OS will launch. It will open the official Windscribe website in the registration section.

      In the field "Choose Username" enter the desired account. It must be unique in the system. If you choose a non-unique login, you will have to change it. You can also generate it automatically by clicking on the icon in the form of arrows forming a circle on the right.

      Into the fields "Choose Password" And "Password Again" enter the same password that you created. Unlike a login, it does not have to be unique, but it is advisable to make it reliable, using generally accepted rules for composing such code expressions. For example, combine letters in different cases and numbers.

      In the field "Email (Optional)" enter your address email. This is not necessary, but if this field is filled in, you will receive as much as 10 GB of Internet traffic instead of the basic 2 GB.

      Once everything is filled in, click "Create Free Account".

    6. Then go to your email box, find the email from Windscribe and sign in. Inside the letter, click on the element in the form of a button "Confirm Email". By doing this, you will confirm your email and receive an additional 8 GB of traffic.
    7. Now close your browser. Most likely, you will already be logged into Windscribe using the current account you just registered. But if this is not so, then in the window with the inscription "You already have an account" click "Yes". In the new window, enter your registration data: login and password. Next click "Entrance".
    8. A small Windscribe window will open. To start the VPN, click on the large round button on the right side of it.
    9. After a short period of time during which activation is carried out, the VPN will be connected.
    10. By default, the program selects the best location with the most stable connection. But you can choose any other available option. To do this, click on the element "Connected".
    11. A list will open with a list of locations. Those marked with an asterisk are only available for a paid premium account. Select the name of the region of the country through the IP of which you want to present yourself on the Internet.
    12. A list of settlements will open. Select your desired city.
    13. After this, the VPN will be reconnected to your chosen location and the IP will be changed. You can easily see this right in the main window of the program.

    As you can see, the procedure for setting up a VPN and changing the IP address using the Windscribe program is quite simple and convenient, and specifying your email during registration allows you to increase the amount of free traffic several times.

    Method 2: Built-in functionality of Windows 7

    You can also set up a VPN using exclusively the built-in tools of Windows 7, without installation third party software. But for implementation this method you must be registered on one of the services that provide access services for the specified type of connection.

    1. Click "Start" followed by transition to "Control Panel".
    2. Click "Network and Internet".
    3. Open the directory "Control Center...".
    4. Go to “Setting up a new connection...”.
    5. Displayed "Connection Wizard". Select the option that involves solving the problem by connecting to the workplace. Click "Next".
    6. Then a window for selecting a connection method opens. Click on the element that suggests your connection.
    7. In the window that appears in the field "Internet address" Enter the address of the service through which the connection will be made, and where you registered in advance. Field "Destination name" determines what it will be called this connection on your computer. You don’t have to change it, but you can replace it with any option convenient for you. Check the checkbox below "Don't connect now...". After that click "Next".
    8. In the field "User" Enter the login for the service you are registered with. In shape "Password" enter the login code and click "Create".
    9. The next window will display information that the connection is ready for use. Click "Close".
    10. Back at the window "Control Center", click on the element on the left side "Changing parameters...".
    11. A list of all connections created on the PC will be displayed. Find a VPN connection. Right-click on it ( RMB) and select "Properties".
    12. In the shell that appears, move to the tab "Options".
    13. Uncheck the checkbox here "Enable domain...". It should be checked in all other checkboxes. Click "PPP Settings...".
    14. In the window interface that appears, uncheck all checkboxes and click "OK".
    15. After returning to the main connection properties window, move to the section "Safety".
    16. From the list "VPN Type" stop by position "Tunnel Protocol...". From the dropdown list "Data Encryption" select an option "Optional...". Also uncheck the checkbox "Microsoft CHAP Protocol...". Leave other parameters in default state. After completing these steps, click "OK".
    17. A dialog box will open warning you that if you use the PAP and CHAP protocols, encryption will not occur. We indicated universal settings VPNs that will work even if the service providing the corresponding service does not support encryption. But if this is critical for you, then register only with an external service that supports specified function. In the same window, click "OK".
    18. Now you can start the connection VPN made simple left-click on the corresponding element in the list network connections. But it will be inconvenient to go to this directory every time, and therefore it makes sense to create a launch icon on "Desktop". Click RMB by VPN connection name. From the list that appears, select "Create shortcut".
    19. A dialog box will prompt you to move the icon to "Desktop". Click "Yes".
    20. To start the connection, open "Desktop" and click on the icon you created earlier.
    21. In the field "Username" Enter the login of the VPN service, which you already entered at the stage of creating the connection. In the field "Password" Enter the appropriate code expression to enter. To always avoid having to enter the specified data, you can check the checkbox "Save username...". To start the connection, click "Connection".
    22. After the connection procedure, the network location settings window will open. Select a position in it "Public Network".
    23. The connection will be completed. Now you can send and receive data over the Internet using a VPN.

    You can set up a network connection via VPN in Windows 7 using third party programs or using only the functionality of the system. In the first case, you mandatory You will need to download the application, but the actual settings procedure will be as simple as possible; you will not have to look for any proxy services that provide the corresponding services. When using the built-in tools, you do not need to download anything, but you will need to first find and register on a special VPN service. In addition, you will still need to perform a number of settings, which are much more complicated than when using software method. So you need to choose for yourself which option suits you best.

    The use of VPN networks in our time has become an integral part of working with the Internet. A variety of virtual private network technologies and specifications are used by both huge international corporations and by individual users. Some providers even provide Internet services based on VPN servers. One way or another, connecting to existing ones or setting up your own VPNs is not difficult, but very necessary. Everything connected with it is clearly illustrated by example. Windows systems 7.

    What is a VPN connection

    VPN (English abbreviation for “virtual private network") is the common name for several technologies that enable the creation of network connections on top of existing ones. VPNs are often used in closely held corporations to restrict access to the corporate network. Thus, an internal network is created on the basis of an existing external network (most often the Internet).

    A simplified diagram-icon symbolizing a VPN connection

    Thus, data exchange is carried out using Internet technologies, while corporate network(VPN) has closed access for employees only. In this case, employees may be in different parts globe. “Closed” access is achieved through cryptographic technologies such as encryption, authentication and/or public key infrastructure.

    The general structure of a VPN is shown in the figure below.

    The diagram shows what a VPN structure typically looks like using lines and icons

    So, two regional branches, the main office, as well as individual employees are connected to a common network. At the same time, the connection between them is carried out through Internet technologies, and information security tools make it possible to limit the access of unauthorized users or completely close it.

    For an individual user, VPN technology can also be useful for personal purposes. For example, if you connect to a remote VPN server, you can bypass the geographic restrictions of some web resources. That is, pretend that you are in another country. In addition, the user's location is hidden in the same way. These actions are not limited by law, but access to some sites is prohibited for such networks.

    In addition to the examples above, VPN is now used by some providers to connect users into groups. This allows you to connect multiple computers to the same IP address. Thus, savings are made on renting Internet addresses, which means the cost of connection services drops. At the same time, data transmitted by users remains encrypted.

    How to connect and configure VPN services on Windows 7

    Setting up a VPN connection on Windows 7 is quite simple. You won't need any additional software. Just follow the instructions.

    1. First of all, go to the Network and Sharing Center: open Start and select Control Panel. In the open window you will see a button to enter the “Center...”. Select "Set up a new connection...".
      In the Network and Sharing Center, click "Set up a new connection or network"
    2. From the list, select “Connect to a workplace.” This paragraph contains settings for the VPN connection.
      Select “Workplace Connection” from the list of network connection options
    3. The program will ask: “How to connect?” In our case, we need to choose the first option. Then click Next. By the way, in this window you can view Microsoft's VPN data (click the link at the bottom of the screen).
      When asked how to connect, select "Use my Internet connection (VPN)"
    4. A window will appear in front of you to fill in your connection information. In the “Internet address” line, you must specify a link to the VPN server. You can find this out from your provider and/or administrator. You can enter any “Destination Name”. In addition, you need to check the box next to “Don’t connect now...”. When everything is ready, click “Next”.
      Enter the required VPN connection information: Internet address, destination name. These can be obtained from your provider.
    5. Now you need to enter your username and password to connect to the VPN network. If you are not sure if they are correct, contact your administrator (provider). In addition, for ease of access to VPN server you can specify its domain. If you are simply setting up an Internet connection to an ISP, leave the field blank. Now click the “Create” button.
      Enter your username and password in the appropriate fields when connecting to your workplace

      A message appears indicating that the connection is ready. Just click "Close".

      Close the VPN Ready message box

      In the “Center…” window that opened earlier, click on “Change adapter settings.”

      In the Network and Sharing Center, click on “Change adapter settings”

      A window will open in front of you, which contains information about available connections. The newly created connection is named as the “Destination Name” you specified earlier. Right-click on it. If you want, you can create a shortcut for this connection on your desktop. This will make it easier to access the network. Then select Properties: There are a few things you need to change before you can start using the VPN.

      Create a connection shortcut if you want and then go into its properties

      Now be careful. In the small “Properties” window of your connection, switch to the “Security” tab. Select the type of VPN network, which depends on the specifics of it. Contact your administrator or provider for this information. For example, if you want to connect to some remote server, the connection type is usually “PPTP”. But this is just an example. Be sure to check the correct choice.

      Select the appropriate VPN network type; if you don't know it, contact your ISP or administrator

      Please note that on the same tab there is a drop-down list “Data encryption”. You can choose the item that suits you personally. But this does not guarantee uninterrupted operation of the connection. Such data should also be clarified with the administrator.

    6. Go to the Network tab. Here, uncheck the “Internet Protocol Version 6...” option to increase data transfer speeds, because most likely it is not used on your VPN server (unless specified otherwise). Now single-click on “Internet Protocol Version 4...” and select its “Properties”. Click "Properties" with the cursor over "Internet Protocol Version 4..."
    7. In the window that opens, select “Advanced...” You should not change the DNS server addresses here, as we will set them next to match your VPN. Click “Advanced...” to go to additional. menu
    8. In the window " Additional parameters TCP/IP" on the "IP Settings" tab, uncheck the words "Use the default gateway in remote network" If this is not done, Internet traffic will pass through the VPN server, which will reduce the data transfer speed. Uncheck "Use the default gateway on the remote network" to increase connection speed

      If you are just connecting to a remote server, go to the DNS tab. In the “DNS connection suffix” column, enter the suffix provided by the administrator. This way, you don't have to enter it every time to go to a specific site.

    9. In all previously opened windows, click “OK”. The VPN connection is ready to use! You can launch it from the “Desktop” if you created a shortcut earlier.

    Video: how to install and connect to a VPN in Windows 7

    Possible connection problems

    There are a number of errors that can cause your VPN connection to not work or not work properly. But before we move on to their descriptions, let’s look at the most common problem: when you turn on the VPN, the Internet connection disappears.

    What to do if the Internet connection disappears after startup

    This problem is relevant if you connect to a certain server, and not to the provider. It doesn’t matter how you are connected to the Internet (cord, Wi-Fi, another VPN), the connection drops for the same reason. And restoring it is quite simple.

    As we indicated above, enabling this option may slow down the speed of your Internet connection, since traffic will pass through the VPN server. If the connection is completely lost, it means that the gateway to the server is closed. remote connections. After unchecking the box, the Internet will work again.

    VPN connection problems and their solutions

    Errors when trying to automatically connect to a VPN connection are numbered with a three-digit number - an error code. This code appears in a separate window as shown in the screenshot.

    VPN connection error window; in this case, error 807 popped up

    Here are ways to correct the most common errors.

    400 Bad Request

    This error means that the request from your computer contained some information incorrectly.

    1. Try turning everything off additional programs for working with the network.
    2. Refresh your browser and reset its settings.

    Error 624

    Error 691

    This error can have many causes, but they are all similar to some extent. So, it appears if you have not paid for the services to the provider, entered an incorrect login or password, incorrectly specified any VPN connection settings, or the connection has already been established. One way or another, check all the entered data in the connection properties or simply create it again, as we did above.

    Error 800

    This error indicates that there are problems with the VPN server itself. Perhaps it receives too many requests that it does not have time to process, or there is a load directly on your segment virtual network. In this case, you can only report the problem to the server provider/administrator and wait for a solution from them.

    Error 800 means the VPN server is overloaded

    Error 650

    If this error occurs, you need to check the health of your equipment: network card and cable. To do this, it is better to call a specialist. Before doing this, go to “Properties: Internet Protocol Version 4...” (see the item “What should I do if the Internet connection is lost after turning on the VPN?”) and set the switch to “Obtain an IP address automatically.”

    Enable automatic IP address selection

    Thus, the server itself will provide you with an IP address from the list of available ones with each new connection.

    Error 735

    The appearance of error 735 indicates incorrect setting VPN connections. Most likely, a specific IP address is specified. Set it to be selected automatically, as in the case of error 650.

    Error 789

    In this case, you need to enter the properties of the VPN connection and go to the “Security” tab (we have already described how to do this earlier). From the VPN Type drop-down list, select Automatic. This will solve the problem.

    Set VPN type to auto-select to check network health

    Other errors

    In addition to the above, there are many other local errors. If you are an advanced user, sometimes you can solve them yourself (for example, open some ports in the firewall so that the server works), but most often they must be resolved by your ISP or server administrator. The only thing you can do is to go through all the points we suggested and check that the VPN connection is configured correctly. If the connection worked before, but is now lost, the problem is definitely on the server side.

    How to disable automatic VPN connection

    Sometimes you may need to disable your VPN connection for a while. For example, to connect to another network or check the possibility of reconnection. To do this, go to Control Panel from the Start menu. Open the list of settings “Network and Internet” -> “Network Center...”. Click on "Change adapter settings" on the left. Your connection will be displayed in the window. Right-click on it and select Disable.

    To disable VPN, select the appropriate context menu item

    Additionally, once disconnected, you can remove the VPN connection completely. This is necessary if you have configured it incorrectly or you no longer need it. Just click "Delete" in the same context menu.

    Creating and masking your own connection

    In this section we will talk about the possibilities of masking a VPN connection for the average user. This may be needed in different cases. For example, if you want to create your own small server to control your home computer from a work computer, which would be maximally protected from outsiders. Or you need to mask your IP address through a remote VPN server to gain access to online sites and stores in other countries.

    How to create a VPN network using the OpenVPN client

    If you want to create a personal small network VPN or connect to a geographically distant server, you will need the OpenVPN program and configuration files from the provider. These files should be selected according to your purposes. Please note that the VPN provider may have nothing to do with your Internet Service Provider. VPN services are paid.

    1. Download the OpenVPN installer from the developer's website. After downloading, run the installer (all actions on the computer must be performed as an administrator) and click Next.

      A program downloaded from other sites may turn out to be fake or even dangerous virus.

      Click "Next" to begin the OpenVPN installation

    2. Read the user agreement and click I Agree.
      Click the I agree button after reading the documentation
    3. A list of components to be installed will appear in the installer window. Without changing anything in it, click Next.

      Without changing anything in the list of installed components, click Next

      Specify the desired path to the OpenVPN program and click Install to begin installation.

      Select the desired path to the program and click Install

      When installing Windows programs will ask permission to install the driver because OpenVPN creates a virtual device. Just click “Install” in the window that appears.

      Install the driver virtual device, without it OpenVPN will not work

      Once the installation is complete, click Next and then Finish.
      Once the installation is complete, click Next, then Finish

      Now you need to copy the files provided by your VPN provider to special folder OpenVPN programs. Follow the path […]OpenVPN\config (here “[…]” is the program path you selected during installation), right-click and click on “Paste”.

      Paste the provider files into the config folder

      Go to the Start menu and find OpenVPN under All Programs. Right click on the file OpenVPN GUI and select its "Properties".

      Enter OpenVPN GUI properties

      Switch to the “Compatibility” tab and make sure that the “Run this program as an administrator” checkbox is checked. Otherwise it won't work.

      Make sure that the OpenVPN GUI program will be run as administrator

      After clicking OK, launch OpenVPN GUI from the Start menu. The program icon will appear in the notification area on the taskbar. Right-click on it and select Connect.

      Right-click on the program icon and click Connect to launch

      The program will start and a log of connection data will appear on the screen.

      This window provides information about the VPN server startup

      Now you can click the Hide button to hide this window. A message will appear on the taskbar indicating a successful connection and the IP address assigned to you.

      Successful connection message

      Your VPN connection is ready to use!

    Video: detailed OpenVPN setup for advanced users

    Masking a VPN Connection with Obfsproxy

    Now your VPN connection is ready to use. Now let's move on directly to his disguise. The Obfsproxy program will help you cope with this task best.

    The steps involved in installing Obfsproxy require basic programming and administration knowledge.

    This program is created on the basis of Linux systems for multi-level encryption of transmitted data. The full cryptographic algorithms, of course, are kept secret, however, Obfsproxy has proven itself to be excellent among both advanced administrators and ordinary users. Therefore, its use guarantees complete isolation and protection of information transmitted over the VPN network.

    As we already said, Obfsproxy is developed on Linux. Therefore, for its use in Windows environment 7 will require a Python compiler. You can download it from the official website of the Python Software Foundation. The recommended version is 2.7.13.

  • Run installation file and when choosing the installation path, specify C:\Python27\.
    Install Python on your computer
  • In addition, you will need a Visual C++ compiler for Python. You can download it from the Microsoft website. It's called something like this: Microsoft Visual C++ Compiler for Python 2.7. Please note that the compiler version (2.7) must be the same as the Python version (2.7.13). Install the program to any folder on the C:\ drive.

    Install Microsoft Visual C++ Compiler for Python 2.7

    Install OpenSSL Light v1.0.2d

    Then it's a matter of little things. Run Command Prompt as an administrator: From the Start menu, type cmd in the search bar, right-click and select Run as administrator.
    Run Command Prompt as Administrator

    Enter the following commands into the command line window in the given sequence (press Enter after entering each command):

  • cd C:\Python27\Scripts
  • pip install --upgrade pip
  • pip install obfsproxy
  • obfsproxy.exe --log-min-severity debug obfs3 socks 127.0.0.1:1050
  • After that, without closing the command line, run OpenVPN as an administrator, click Connect (as we did earlier) and enter the login and password provided by the provider or server administrator.
    Run OpenVPN as administrator
  • You must run the first and fourth commands from the list before each launch of OpenVPN. In this case, you do not need to close the command line, otherwise obfsproxy will not work.

    Your VPN connection is now secure and camouflaged!

    As you can see, working with a VPN is not that difficult. Any user with minimal knowledge can not only connect to an existing network, but even create its own. Besides, cryptographic protection personal data, it turns out, is also available to everyone. The main thing is to be vigilant when connecting to the traffic of foreign servers. After all, any actions performed by their administrators will be governed by the laws of the country in which the server is located.