-
client-server
多协议文件传输c/s网络应用设计与实现,程序用 TCP/UDP 两个协议模拟多协议服务器。首先服务器端要将两种协议的套接字创建好,并且监听 TCP 端口的连接。必要时使用select函数来进行多连接处理和非阻塞处理。而客户端直接可以按照发送的地址和端口号来进行通讯。
首先要运行服务器端,服务器会监听 TCP 端口。然后运行客户端,根据事先设定好的 IP和端口,就可以进行连接传输数据了。
程序实现的关键步骤:
以TCP协议为例
服务器端:
1.创建套接字;2.绑定端口;3.进入无穷的循环;4.接收请求;5.处理请求;6.应答。
客户端:
1.找到服务器的IP地址和协议的端口号;2.创建套接字;3.确定连接需要任意的,没有使用的端口号允许TCP去选择一个;4.将套接字和服务器连接;5.使用应用层协议和服务器交互;6.关闭连接。
(Multi-protocol file transfer c/s network application design and implementation of programs simulate multi-protocol server with TCP/UDP both protocols. First socket server to create a good two protocols, TCP port and listens for connections. If necessary, use the function to handle multiple connections and non-blocking treatment. And the client can follow directly address and port number to communicate.
First run on the server side, the server listens on TCP port. Then run the client, according to pre-configured IP and port, you can connect the data transmission.
The key step program implementation:
In TCP protocol as an example
Service-Terminal:
1. Create a socket 2 bound port 3 enter an infinite loop 4. receiving a request 5. processing requests 6 response.
Clients:
1. Locate the server s IP address and protocol port number 2 creates a socket 3 connections need to determine arbitrary, unused port allows TCP to choose a 4 and the socket server connections 5 using appli)
- 2016-07-11 10:19:07下载
- 积分:1
-
01liaotianshi
第1章实例01-简单网络聊天室.zip(Chapter 1 Examples 01- Simple network chat rooms. Zip)
- 2013-05-31 09:23:05下载
- 积分:1
-
telnet
自己实现的telnet的服务器端和客户端源码,VC2010实现(Their implementation of Telnet server and client source code, VC2010 implementation)
- 2021-01-12 16:38:48下载
- 积分:1
-
sipproxd-win32
移植的一个基于osip,使用vc编译的siproxd服务器软件(port siproxd to win32, compiled using vc)
- 2009-07-02 22:31:48下载
- 积分:1
-
UDP_Lost_test2
这是一个测试UDP数据包的丢包率的程序,包含程序源码,已经验证成功(This is a test UDP packet loss rate of the program, including program source code, has been successfully verified)
- 2013-12-30 11:10:56下载
- 积分:1
-
rxjh
热血江湖服务端C++源代码vs8应用程序向导已为您创建了这个 GameServer 应用程序。
此文件包含组成 GameServer 应用程序
的每个文件的内容摘要。
(RXJH_source)
- 2009-05-18 00:25:08下载
- 积分:1
-
getIPaddress
通过此程序,可以获得本地计算机的IP地址,并以提示框的形式显示出来.(Through this process, access to the local computer' s IP address, and the form of prompt box is displayed.)
- 2009-05-07 14:27:16下载
- 积分:1
-
ddos
说明: ddos,一个很好的DDOS工具。。。。。。(ddos a intersing software)
- 2020-06-19 09:15:41下载
- 积分:1
-
DoubleNetUDP
UDP方式双网冗余程序,一网卡断开,另一网卡自动连接,从而保证通讯正常(UDP mode dual-network redundancy procedures, disconnect a network card, another card to connect automatically to ensure the normal communication)
- 2009-07-15 21:57:13下载
- 积分:1
-
12084247tao2
基于ICMP协议的ping程序设计实验基于ICMP协议的ping程序设计实验(Based on the ICMP protocol ping program designed experimental program designed experiments based on the ICMP protocol ping)
- 2012-10-29 10:54:54下载
- 积分:1