Linux, etc

[linux] 포트 port

jiheek 2022. 5. 9. 15:20

 

  • 특정 포트를 사용중인 프로세스 확인 방법
netstat -tulpn | grep 포트번호

 

Network Port는 0~65535의 범위를 가지며, 세 종류로 나뉜다.

  1. Well-known Ports: 0-1023
  2. Registered Ports: 1024-49151
  3. Dynamic Ports: 49152-65565

- 먼저 well-kown port를 사용하면 클라이언트 응용 프로그램이 다른 호스트에서 해당 서버 응용 프로그램 프로세스를 쉽게 찾을 수 있다. 예를 들어, 서버에서 실행 중인 DNS 프로세스에 연결하려는 클라이언트 프로세스는 데이터그램을 일부 목적 포트로 보내야 한다. DNS에 잘 알려진 포트 번호는 53이며 서버 프로세스가 클라이언트 요청을 수신 대기해야 하는 곳이다.

따라서 1023 이하의 포트 번호에서 새 응용 프로그램을 등록하는 것은 지양해야 한다.

 

- 두 번째로 Registered port는 따로 할당/제어되어 있지 않은 포트 번호들로, 사용을 위해 등록 가능하다.

 

- 마지막으로 Dynamic port는 할당/제어/등록되지 않는 포트이다. 일시적으로 또는 private하게 사용된다. 따라서 private/non-reserved port로도 알려져있다.

 

 

 

 

 

 

중요한 포트 번호들은 아래 사이트 참고하면 된다.

https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/4/html/security_guide/ch-ports

 

Appendix C. Common Ports Red Hat Enterprise Linux 4 | Red Hat Customer Portal

Access Red Hat’s knowledge, guidance, and support through your subscription.

access.redhat.com

https://ipcisco.com/lesson/network-ports/

 

Network Ports | TCP & UDP Well-Known Port Numbers ⋆ IpCisco

Network ports are used in networking for the specific network applications. Well-known ports are used by TCP and UDP Applications.

ipcisco.com

 

이미지 출처 및 참고 사이트(전체적인 설명 잘되어있음)

https://www.sciencedirect.com/topics/computer-science/registered-port

 

Registered Port - an overview | ScienceDirect Topics

Local Client 192.168.0.13 has made a secure web page connection to the following servers: 199.16.156.201, 23.73.162.234, 66.153.250.229, 66.153.250.234, 66.153.250.238, 66.153.250.241, 74.125.137.132, 74.125.137.154, 74.125.196.99, 74.125.230.127

www.sciencedirect.com