• How to open port 22. Coasting - how to open ports on a router

    If you actively play Minecraft or other multiplayer games that require connecting to a server, then sooner or later you will probably be faced with the question of how to open ports. By default, the firewall and antivirus close most ports, so games and programs may not work correctly. This deficiency can only be corrected manually.

    Setting up a firewall

    Before you start opening a port, you need to find out its number. For example, for normal operation online mode GTA V you need to open the entrance number 80. For Unturned you need open port 25444. You can find this information on game forums or support pages.


    In some cases, you need to specify permission for two protocols - TCP and UDP.

    It's simple: two incoming rules are created, for which different protocols are specified. The rest of the data must match.

    Firewall in antivirus

    Some antiviruses manage the firewall themselves, so you need to open the logins in their settings. There is no fundamental difference, but the order changes slightly. Let's look at the algorithm using an antivirus as an example ESET Smart Security.


    If you do not want to configure rules in your antivirus settings, disable its firewall. The system will prompt you to activate Windows firewall, after which you can open access using the first part of our instructions.

    Allowing access in the router

    If you have a router, then you need to additionally open access in its interface, otherwise the data packets will not go through as intended. First, look at the physical address of the computer on the network - the input opens for a specific machine.

    1. Go to Network and Sharing Center and click on the connection you are using.
    2. Click Details.
    3. Find and remember the IPv 4 address.

    You have found out the physical address of the computer on the network, now you need to open ports for it in the router. Go to the router's web interface (usually available at 192.168.0.1). Go to the section responsible for the work firewall. You need to configure virtual server.

    Click "Add" to open the virtual server setup form. Please provide the required information:

    • Name (use the name of the game).
    • The interface is everything.
    • The protocol is the one you need, TCP or UDP.
    • External and internal starting port - a specific number, for example 25444.
    • Internal IP – the IPv4 address that you looked at in the connection information.

    After saving the configuration, the port will be open. To check its operation, go to the website 2ip.ru. There is a "Port Test" tool here.

    IN this review The following will be considered: how to open ports on the router and what must be done before this, as well as why all this is needed.

    Router DIR-300 D-Link

    Let's say a packet addressed to a specific port (for example, 8080) arrives from the Internet to the router. This package will be ignored by default. If it is necessary that it be sent to one of the PCs local network– perform port forwarding, or “open a port”.

    Before opening the port, necessary one or another program for its operation, you can check: what if the port is already open? We go to the site “2ip.ru” directly from the local network computer. IN address bar, add: “/check-port/”. And check the required port:

    But by performing certain manipulations in the router settings, you can make the port open. Only, in this case, you need to specify the IP of the target computer (therefore, all PCs for which port forwarding is performed on the router must be included in the “IP reservation area”).

    It is important to know: you can open a port with a certain value for no more than one PC on the local network. That is, you cannot open one port for two or more computers.

    Introduction to Port Forwarding

    Typical port values

    Information in networks is transmitted in packets. Each packet carries a recipient address and a port value (an “address: port” pair). If the required port is closed on the recipient's side, the packet is simply ignored and disappears from the network.

    The ports commonly used are:

    • 20 and 21 – ftp server ports
    • 22 – SSH secure management shell port
    • 80 – http server port (you need a site “in public access" – open port eightieth)
    • 8080 – web caching service port (hard to say what it is)

    In some programs (for example, in the DC++ client-server), you can specify the port value directly in the settings. That is, there is no concept of “default port” in these programs. However, the port value must be from a certain range (which is very desirable).

    Let's say there is a PC with an FTP server on the local network. Let’s also assume that the user knows the IP address assigned to him by the provider. This ftp server can be made accessible from an external network. For this purpose, they open ports on the router (20th and 21st). The route of incoming packets will look like this:

    Route of the packet directed to the ftp server

    If it is clear in general terms why “port forwarding” is needed, move on to the next chapter.

    Algorithm for forwarding in a router

    Having received incoming package, the router “looks” at the value of the port to which this packet is addressed. A list of the form “port –> local address: port", and the list is specified by the user himself.

    According to the given list, the behavior of the router should be as follows:

    • If given value port is not in the list - the packet is “lost”
    • If there is, then the IP address value in the packet header will be replaced (with the IP of the target computer), and the packet will be sent to the local network

    And setting up router ports is creating a list. Each line must contain 3 elements: the value of the port specified in the packet header; IP address of the local PC to which this packet should be sent; new port value (usually it is left the same).

    Example. For a computer with http server(and local IP equal to 192.168.0.112), the list line should contain the values: “80 -> 192.168.0.112: 80”. Everything should be clear here.

    Setting up the router

    “Reservation” of local IPs

    The router has a DHCP server enabled that changes IP addresses local devices(for example, once every 3 hours or more often). To forward a port to a PC with a specific IP, you need to “assign” the IP to this computer.

    Opening a port on a router should not remain “temporary”. There is a solution - turn off DHCP. We will do things differently by setting up a “reservation” of IP addresses for the required PCs.

    In the web interface TP-Link routers, for example, setting up a reservation is difficult. You need to know the MAC address of the target computer (its network card). On Windows, this can be found by going to the "Status" of the connection (opening the "Support" tab and clicking on "Details").

    In the configuration interface, on the “DHCP” -> “Address Reservation” tab, click the “Add New” button:

    Address reservation tab

    will appear new tab. Let's indicate the MAC address of the target PC (as well as the IP “assigned” to it):

    Address reservation for local PC

    Make “Status” – “Enabled”, click “Save”.

    It is important to know that we will have to “reserve IP” for each PC to which we will forward a port (at least one).

    IN D-Link routers– it’s easier to do the same thing. Go to the “Setup” -> “LAN Setup” tab:

    Setting up a local area network (LAN)

    We see the “DHCP Client List” block (here – all PCs on the local network). We remember the name “Host Name”, then in the block below we select the required one from the list. Click on the button "<<». IP-адрес

    from the middle cell - we assigned it to this PC.

    How to open ports through a router will be discussed using D-Link devices as an example (for others everything is very similar).

    Configuring port forwarding (“old” interface)

    Go to the “Advanced” -> “Port Forwarding” tab, check the box on the left:

    Port forwarding tab

    Next, the following is performed:

    1. You must specify the target PC (Host Name, or just local IP)
    2. Set the protocol to use (for most programs - TCP, you can also create two identical rules for TCP and UDP)
    3. Specify the value of the forwarded port (in the example - “35000”)
    4. We check that the rule is always on (Always On)
    5. Click “Save Settings”

    Thus, we looked at how to open a port on the router. In the modern version of the interface, you can specify a “range” of ports (by setting the minimum and maximum numbers). Also, there is an option to “change” the internal value of the port (a packet addressed to port 80 can be forwarded to port 81). Let's look at this in more detail.

    Configuring port forwarding (“new” interface)

    First of all, in the new version of the D-Link router, you need to enable the firewall. Then, the administrator creates “Virtual Servers” for it:

    Creating Firewall Servers

    Click the "Add" button. On the tab that appears, we will create a port forwarding rule:

    Forwarding port “23” to PC 192.168.0.100

    You need to set “Custom” at the top, then come up with a name for the rule. We are considering how to open ports through the router for packets directed “outside” (and therefore, we select the “WAN” interface). Then everything is standard: select the protocol used (TCP/UDP), indicate the port value (in this case, “internal” is no different from “external”). Finally, indicate the “target” IP address and click “Change”.

    Forwarding a port with changing its value

    In the IP packet header, you can change, firstly, the recipient address (which is done by the router), and also the port to which the packet is sent. Using this option is simple; just specify the “internal” port (it may differ from the “external” one).

    How to forward ports on a router by changing their values ​​is clear from the example in the previous chapter. It is necessary to indicate the value required by the program in the “Internal port” field. If the external port is "23", this does not mean that the "internal" will only be the same.

    Possible difficulties

    By opening a port on the router, you can get a negative result (the port will still be unavailable).

    This is possible for the following reasons:

    • The local address “reservation” was not performed correctly (which is necessary for each target PC)
    • The 2ip service is useless when the “internal” value of the port is obviously not equal to the “external” (there will be a message “Port closed”)
    • We looked at how to open a port through a router, but it may be blocked by your ISP

    At the same time, if the port is not open, there is no need to try to call the provider right away. It is better to try to solve the problem “locally”.

    Here we show how to open a port in the classic D-Link interface (which is different from the one discussed - here you can specify “internal” and “external” values):

    Quite often, Windows 7 users encounter the problem of opening a port in the firewall. This situation occurs when installing a new program or to be able to play games online. If you don’t know exactly how to do this, you can waste a lot of time and nerves on this activity. So, to open the port, first go to the Start menu - select Control Panel. In the upper left corner, click System and Security.
    In the menu that opens, select the Windows firewall item - it is second on the list.
    The firewall menu will open in front of you, where you can see its status: whether it is open or closed, active networks, notifications. On this page, select “Advanced settings” in the upper left corner - the “Windows Firewall with Advanced Security” window will open in front of us.
    Here, also in the top left menu, select the item “Rules for incoming connections”; in the window that opens, you can see a list of rules allowed for incoming connections. Next, in the upper right corner, click “Create a rule”, after which the wizard for creating a rule for a new incoming connection will open in front of us. Here we select the type - the rule that controls connections for the TCP port( Transmission Control Protocol - transmission control protocol) or UDP( User Datagram Protocol- user datagram protocol). Select the port and click next. A window will open where you need to select a protocol and specify ports: you can choose all ports or manually enter a specific local port - this is a certain number of numbers and dots. This figure can be individual for each specific task. Click next again. A window will open in front of us where we need to select the Allow connection option and click Next again. A window will open in front of us: “For which profiles the rule applies” - domain, private, public. You can select all and click next. Then we enter the name and description of the rule and that’s it – click ready, the port is open. You can see the name of this rule in the list of rules.
    The port remains open at all times, so close ports when they are no longer needed.

    Not everyone knows how to open ports on Windows 7, 8, 8.1, but many PC users have probably heard about them. However, for some online games or programs that require Internet access, opening additional connections becomes necessary. Sometimes you need to open or check already open ports.

    A port is a specific numeric code that allows the system to exchange data with hosting providers from the Internet. This is a kind of path that helps you check the necessary data and get it from a remote server to your computer, exactly at the address.

    Some applications do not require opening an additional connection, since it is already open. But for some closed resources, games (for example, Minecraft), this has to be done manually.

    Opening methods

    Easiest general way

    The most accessible method is quite simple. Below is an algorithm of actions that need to be performed:

    • In the “Control Panel” we find the “System and Security” item, then open “Windows Firewall”.

    Open Windows Firewall

    • Select "Advanced options"
    • In the window that appears, select “Rules for incoming connections” (left column).

    Select “Rules for incoming connections”

    • Next, you need to create a rule, click on the corresponding icon.
    • Rule type “For port”, click the “Next” button, put a marker on “TCP Protocol” and enter the number (you need to check it exactly). Click “Next” again.

    Place a marker on “TCP Protocol”

    • Leave all the checkboxes - they determine which profiles the rule will apply to.

    Leave all the boxes ticked

    • Then you will need to come up with a name and, if you require it, a description. Click “Finish”.

    Specifying a name

    That's it - you have a new rule, now the computer will be able to connect to the desired server.

    Connection for the program

    This method may be required if the previous one was unable to provide the required application with the required network activity. That is, simply, the required program still does not connect to the Internet.

    1. According to the previous algorithm, we get to the place where we need to select the type of rule, select the type of rule “For program”
    2. Place a marker on “Program Path”, select using the “Browse” button, or manually enter the program address.
    3. Click “Next” and check “Allow connection”.
    4. Then we repeat everything we did with the previous method.

    As a result, this program will be allowed to connect to the network.

    By itself, it can often block many connections, so in some cases you can simply try disabling it. However, if you do not have any antivirus installed on your computer, then using the Internet with the firewall disabled can be dangerous for your computer.

    To disable the firewall, you just need to go into it, select the “Turn Windows Firewall on or off” option, check the “Turn off Windows Firewall” option in the settings settings and click “OK”.

    Examination

    It is not always necessary to enter a new number and select a protocol; sometimes it is enough to know how to check if the port is open. This can be done using a special command. First, enter “cmd” (without quotes) in the command line (opened by pressing Win+R), then click “OK”, and in the window that appears, enter the command “netstat -a”. A list of all open protocols will then appear. This way it is easy to check their quantity. Such a check can be carried out on various free Internet services, which will also provide this information.

    It's quite easy to open new connections or disable blocking them altogether. These restrictions, with small skills, will not prevent you from gaining access to the necessary information or data from the Internet. Now, if necessary, you can both open a port on your computer and check which ones are open.

    Almost all programs that are available on a PC can communicate through network protocols. Any such communication occurs through the port. Port(actually it's just a number) is assigned to the program that made the connection when creating the connection.

    From an information security point of view, a port is a very convenient element for monitoring computer connections with the outside world (local or global networks). Such control can be carried out using a special program called Firewall. Applications of this type can either independently analyze all external connections, or work in manual mode, asking the user for permission to make a particular suspicious connection.

    Such a security program has been built into the Windows operating system, starting with XP, and is called - Firewall.

    Windows Firewall blocks all external incoming connections, thus protecting your PC from various types of external attacks. But there may be situations when it is necessary to disable this protection for a specific port - this is necessary to ensure the functionality of some applications that listen for incoming connections. This disabling of protection is called port opening.

    First stage

    So, Windows Firewall- this is a necessarily included software package included with the system.

    To complete our task it is necessary to perform the following sequence of actions:

    We performed several very simple manipulations; this was all the first stage of our work.

    Each user should pay attention to the fact that while working with the New Connection Wizard, he will constantly give advice. They concern both further actions and the overall performance of the created port. Don't ignore them; they contain a lot of useful information.

    Second stage

    You can proceed to the next step:


    We have offered you a fairly simple version of how to open ports on Windows 7. We hope that this process did not cause you any difficulties. If you strictly follow our instructions, there will be no problems.

    However, this must be done with extreme caution. After all, operating systems already have a sufficient number of holes for various viruses to penetrate.

    Opening ports increases the vulnerability of the system and makes it more susceptible to certain types of attacks and viruses. We recommend that you install an antivirus program on your computer or laptop.

    Remember that opening ports should always be done out of necessity. If you no longer need a particular port, for example after uninstalling a program that uses it, close it. Be extremely careful.

    Video on the topic