计算机网络----学习协议端口

来源:互联网 发布:阿里云 海外主机 编辑:程序博客网 时间:2024/04/29 04:31
端口(port)对硬件设备来讲可以是USB端口、COM串行端口或交换机、路由器设备的对外连接端口。而对软件来讲端口是通信协议之间的接口,其定义了UNIX或WINDOWS NT系统的所提供的服务。本地系统会为所提供的服务进程分配相应的端口号,也就是协议端口号。       协议端口号用正整数标识,范围在0到65535之间。0-1023之间的端口为知名端口,这些端口一般固定分配给一些服务,比如21端口分配给FTP服务,23端口分配给TELNET,80端口分配给HTTP服务;而1024到65535之间的端口为动态分配端口,这些端口一般不固定分配给某个服务,也就是说许多服务都可以使用这些端口。只要运行的程序向系统提出访问网络的申请,那么系统就可以从这些端口号中分配一个供该程序使用,在关闭程序进程后,就会释放所占用的端口号。        根据TCP/IP协议,端口又分为TCP端口和UDP端口两种:TCP端口和UDP端口。        TCP端口,即传输控制协议端口,是面向连接的服务端口,需要在客户端和服务器之间建立连接,以提供可靠的数据传输。常见的如FTP服务的21端口,Telnet服务的23端口,SMTP服务的25端口等等。        UDP端口,即用户数据包协议端口,是面向非连接的服务端口,无需在客户端和服务器之间建立连接。常见的如DNS服务的53端口,TFTP服务的69端口,QQ使用的8000和4000端口,SIP使用的5060端口等等。下面是常用的协议端口:

 

0=Reserved 1=tcpmux 2=compressnet 3=compressnet 4=Unassigned 5=Remote Job Entr 6=Unassigned 7=Echo 8=Unassigned 9=Discard 10=Unassigned 11=Active Users 12=Unassigned 13=Daytime 14=Unassigned 15=Unassigned 16=Unassigned 17=Quote of the Day 18=Message Send Protocol 19=Character Generator 20=FTP (Data) 21=FTP (Control) 22=Unassigned 23=Telnet 24=Private mail-system 25=SMTP 26=Unassigned 27=NSW User System FE 28=Unassigned 29=MSG ICP 30=Unassigned 31=MSG Authentication 32=Unassigned 33=Display Support Protocol 34=Unassigned 35=Private printer server 36=Unassigned 37=Time 38=Route Access Protocol 39=Resource Location Protocol 40=Unassigned 41=Graphics 42=Host Name Server 43=Who Is 44=MPM FLAGS Protocol 45=Message Processing Module (recv) 46=mpm-snd, MPM (default send) 47=ni-ftp 48=Digital Audit Daemon 49=login, Login Host Protocol 50=re-mail-ck, Remote Mail Checking Protocol 51=IMP Logical Address Maintenance 52=xns-time, XNS Time Protocol 53=domain, Domain Name Server 54=xns-ch, XNS Clearinghouse 55=ISI Graphics Language 56=XNS Authentication 57=Private terminal access 58=XNS Mail 59=Private file service 60=Unassigned 61=NI MAIL 62=ACA Services 63=Unassigned 64=Communications Integrator (CI) 65=TACACS-Database Service 66=Oracle SQL*NET 67=Bootstrap Protocol Server 68=Bootstrap Protocol Client 69=Trivial File Transfer 70=Gophergopher 71=Remote Job Service 72=Remote Job Service 73=Remote Job Service 74=Remote Job Service 75=any private dial out service 76=Distributed External Object Store 77=any private RJE service 78=vettcpvettcp 79=Finger server 80=HTTP 81=HOSTS2 Name Server 82=XFER Utility 83=MIT ML Device 84=Common Trace Facility 85=MIT ML Device 86=Micro Focus Cobol 87=Private terminal link 88=Kerberos 89=SU/MIT Telnet Gateway 90=DNSIX Securit Attribute Token Map 91=MIT Dover Spooler 92=Network Printing Protocol 93=Device Control Protocol 94=Tivoli Object Dispatcher 95=SUPDUPsupdup 96=DIXIE Protocol Specification 97=Swift Remote Vitural File Protocol 98=TAC Newstacnews 99=Metagram Relay 100=newacct [unauthorized use]
0 0