How To Determine The Port

Table of contents:

How To Determine The Port
How To Determine The Port

Video: How To Determine The Port

Video: How To Determine The Port
Video: Port Numbers Explained | Cisco CCNA 200-301 2024, November
Anonim

A lot of programs are running on the computer at any time. In the event that a program connects to the Internet, a specific port is allocated to it. Sometimes the user needs to determine which port a particular program or service occupies.

How to determine the port
How to determine the port

Instructions

Step 1

Open the command line: "Start - All Programs - Accessories - Command Prompt". Enter the command netstat –aon and press Enter. You will see a list of existing connections. Look at the column "Local address" - in it, at the end of each line, the numbers of ports open on your computer are indicated.

Step 2

To find out which program is opening these ports, look at the last column - "PID". It contains process identifiers - that is, their numbers. In the same Command Prompt window, enter the tasklist command and press Enter again. You will see a window with a list of processes running on the computer. After each name there is a number, this is the PID. Looking in the "Local address" column for the PID of the program that opens the port you are interested in, find this identifier in the list of running processes. Now, by the name of the process, you can understand which program is opening the port you are interested in.

Step 3

In the event that the name of the process does not tell you anything and you do not know which program it belongs to, enter it into a search engine - you will receive all the information about this process. Alternatively, use the AnVir Task Manager program - with its help you can track where the process you are interested in starts from.

Step 4

Sometimes it becomes necessary to find out which ports are open on a remote computer. In this case, use a port scanner like Nmap and XSpider. To scan, you need to know the ip-address of the remote computer. Enter it in the program address field, set the necessary options (read about them in the instructions for the program) and start scanning. After the program finishes its work, you will receive information about the ports open on the remote machine. The most common ports that are open are port 21 - ftp, 23 - telnet, 3389 - Remote Desktop, 4988 - Radmin, etc. The law does not prohibit scanning - nevertheless, if the resource administrator notices the scanning, he can deny access from your ip-address.

Step 5

You can also scan your own computer by setting the address 127.0.0.1. In this case, you will receive all the information about open ports, which will help you ensure a high degree of security. Always try to close unnecessary services that have access to the Internet. The wwdc program can help you with this, which can close some vulnerable ports for an attack - in particular, 445 and 137. Use it if you are working with Windows XP.

Recommended: