[go: up one dir, main page]

CN102932467B - The transmission method of packet and device - Google Patents

The transmission method of packet and device Download PDF

Info

Publication number
CN102932467B
CN102932467B CN201210444003.5A CN201210444003A CN102932467B CN 102932467 B CN102932467 B CN 102932467B CN 201210444003 A CN201210444003 A CN 201210444003A CN 102932467 B CN102932467 B CN 102932467B
Authority
CN
China
Prior art keywords
address
data packet
mobile terminal
identification
network address
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201210444003.5A
Other languages
Chinese (zh)
Other versions
CN102932467A (en
Inventor
马霓
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
XFusion Digital Technologies Co Ltd
Original Assignee
Huawei Technologies Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Huawei Technologies Co Ltd filed Critical Huawei Technologies Co Ltd
Priority to CN201210444003.5A priority Critical patent/CN102932467B/en
Publication of CN102932467A publication Critical patent/CN102932467A/en
Application granted granted Critical
Publication of CN102932467B publication Critical patent/CN102932467B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Mobile Radio Communication Systems (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

The present invention relates to a kind of transmission method and device of packet.The transmission method of packet comprises: the first mobile terminal arranges initial data packets, first home address of the first source address corresponding to the first mobile terminal, second home address of first object address corresponding to the second mobile terminal; Carry out tunnel encapsulation to initial data packets obtain the first encapsulated data packet and send, first packaged source address is the first network address of the first mobile terminal, first encapsulation destination address is the second home address, so that the second home address is mapped as the second network address of the second mobile terminal by gateway.The transmission method of the packet of the present embodiment and device, first mobile terminal and the second mobile terminal can utilize home address namely can send packet to opposite end mobile terminal, gateway is utilized to carry out IP mapping, do not need application server or miscellaneous equipment to communicate first switching network address between mobile terminals, processing method is simple again.

Description

数据包的传输方法和装置Data packet transmission method and device

技术领域technical field

本发明涉及移动通信领域,尤其涉及一种数据包的传输方法和装置。The invention relates to the field of mobile communication, in particular to a data packet transmission method and device.

背景技术Background technique

现有的移动通信分组域网络分配给用户终端(UserEquipment,UE)的互联网协议(InternetProtocol,IP)地址大部分都是动态分配的的,如果UE关机后重开、或者断线后重连时,网络分配给UE的IP地址很可能会发生变化。这种情况给分组域终端互访业务带来很大的不方便,因为当分配给UE的IP地址每次发生变化时,就需要重新进行IP地址信息的交流,根据新的IP地址来进行数据业务处理。Most of the Internet Protocol (IP) addresses allocated to the user equipment (UE) by the existing mobile communication packet domain network are dynamically allocated. The IP address assigned to the UE by the network is likely to change. This situation brings great inconvenience to the inter-access business of packet domain terminals, because every time the IP address assigned to the UE changes, it is necessary to re-exchange the IP address information and perform data based on the new IP address. business processing.

一种现有技术是手机QQ、MSN、Skype等数据业务通过应用服务器中转IP地址信息来规避IP地址信息变化带来的不便问题。但是这种方式是通过部署应用服务器、在应用层进行IP地址信息的中转的,当IP地址发生变化时,数据业务处理还是非常不方便的。A prior art is that mobile phone QQ, MSN, Skype and other data services transfer the IP address information through the application server to avoid the inconvenience caused by the change of the IP address information. However, in this way, the IP address information is transferred at the application layer by deploying the application server. When the IP address changes, data service processing is still very inconvenient.

发明内容Contents of the invention

本发明实施例针对现有技术的缺陷,提供一种数据包的传输方法和装置,利用新增加的标识网络地址来唯一标识移动终端,避免了网路地址发生变化时,需要得知对端的网络地址才可以发送数据包的问题。The embodiment of the present invention aims at the defects of the prior art, and provides a data packet transmission method and device, which uses the newly added identification network address to uniquely identify the mobile terminal, and avoids the need to know the network address of the opposite end when the network address changes. The address can only send data packets.

第一方面,本发明实施例提供了一种数据包的传输方法,所述方法包括:In a first aspect, an embodiment of the present invention provides a data packet transmission method, the method comprising:

第一移动终端设置待向第二移动终端发送的初始数据包,所述初始数据包中的第一源地址为所述第一移动终端所对应的第一标识地址,第一目标地址为所述第二移动终端所对应的第二标识地址;The first mobile terminal sets an initial data packet to be sent to the second mobile terminal, the first source address in the initial data packet is the first identification address corresponding to the first mobile terminal, and the first target address is the A second identification address corresponding to the second mobile terminal;

对所述初始数据包进行隧道封装得到第一封装数据包并发送,所述第一封装数据包中的第一封装源地址为所述第一移动终端的第一网络地址,第一封装目标地址为所述第二标识地址,以便网关将所述第二标识地址映射为所述第二移动终端的第二网络地址。Perform tunnel encapsulation on the initial data packet to obtain a first encapsulated data packet and send it, the first encapsulation source address in the first encapsulation data packet is the first network address of the first mobile terminal, and the first encapsulation target address an address for the second identification, so that the gateway maps the second identification address to the second network address of the second mobile terminal.

第二方面,本发明实施例还提供了一种数据包的传输方法,所述方法包括:In a second aspect, the embodiment of the present invention also provides a data packet transmission method, the method comprising:

网关接收第一移动终端发送的第一封装数据包,所述第一封装数据包中的第一封装源地址为所述第一移动终端的第一网络地址,第一封装目标地址为第二移动终端所对应的第二标识地址;The gateway receives the first encapsulated data packet sent by the first mobile terminal, the first encapsulated source address in the first encapsulated data packet is the first network address of the first mobile terminal, and the first encapsulated target address is the second mobile the second identification address corresponding to the terminal;

所述网关将所述第二标识地址映射为所述第二移动终端的第二网络地址;The gateway maps the second identification address to a second network address of the second mobile terminal;

所述网关根据所述第二网络地址将所述第一封装数据包发送到所述第二移动终端,以便所述第二移动终端将所述第一封装数据包解封装得到所述第一网络地址。The gateway sends the first encapsulated data packet to the second mobile terminal according to the second network address, so that the second mobile terminal decapsulates the first encapsulated data packet to obtain the first network address address.

第三方面,本发明实施例还提供了一种数据包的传输方法,所述方法包括:In a third aspect, the embodiment of the present invention also provides a data packet transmission method, the method comprising:

第一移动终端设置待向第二移动终端发送的初始数据包,所述初始数据包中包括所述第一移动终端的第一标识地址;并且所述初始数据包中的第一源地址为所述第一移动终端所的第一网络地址,第一目标地址为所述第二移动终端所对应的第二标识地址;The first mobile terminal sets an initial data packet to be sent to the second mobile terminal, the initial data packet includes the first identification address of the first mobile terminal; and the first source address in the initial data packet is the The first network address of the first mobile terminal, the first target address is the second identification address corresponding to the second mobile terminal;

向第二移动终端发送初始数据包,以便网关将所述初始数据包的第二标识地址映射为所述第二移动终端的第二网络地址。sending the initial data packet to the second mobile terminal, so that the gateway maps the second identification address of the initial data packet to the second network address of the second mobile terminal.

第四方面,本发明实施例还提供了一种数据包的传输方法,所述方法包括:In a fourth aspect, the embodiment of the present invention also provides a data packet transmission method, the method comprising:

网关接收第一移动终端发送的初始数据包,所述初始数据包中包括所述第一移动终端的第一标识地址;并且所述初始数据包中的第一源地址为所述第一移动终端的第一网络地址,第一目标地址为所述第二移动终端所对应的第二标识地址;The gateway receives the initial data packet sent by the first mobile terminal, the initial data packet includes the first identification address of the first mobile terminal; and the first source address in the initial data packet is the first mobile terminal The first network address of the first target address is the second identification address corresponding to the second mobile terminal;

所述网关将所述第二标识地址映射为所述第二移动终端的第二网络地址;The gateway maps the second identification address to a second network address of the second mobile terminal;

所述网关根据所述第二网络地址将所述初始数据包发送到所述第二移动终端,以便所述第二移动终端从所述初始数据包中得到所述第一网络地址。The gateway sends the initial data packet to the second mobile terminal according to the second network address, so that the second mobile terminal obtains the first network address from the initial data packet.

第五方面,本发明实施例还提供了一种数据包的传输装置,所述装置包括:In the fifth aspect, the embodiment of the present invention also provides a data packet transmission device, the device comprising:

设置单元,用于第一移动终端设置待向第二移动终端发送的初始数据包,所述初始数据包中的第一源地址为所述第一移动终端所对应的第一标识地址,第一目标地址为所述第二移动终端所对应的第二标识地址;The setting unit is used for the first mobile terminal to set an initial data packet to be sent to the second mobile terminal, the first source address in the initial data packet is the first identification address corresponding to the first mobile terminal, and the first The target address is a second identification address corresponding to the second mobile terminal;

封装单元,用于对所述初始数据包进行隧道封装得到第一封装数据包并发送,所述第一封装数据包中的第一封装源地址为所述第一移动终端的第一网络地址,第一封装目标地址为所述第二标识地址,以便网关将所述第二标识地址映射为所述第二移动终端的第二网络地址。An encapsulation unit, configured to perform tunnel encapsulation on the initial data packet to obtain a first encapsulated data packet and send it, the first encapsulation source address in the first encapsulated data packet is the first network address of the first mobile terminal, The first encapsulation target address is the second identification address, so that the gateway maps the second identification address to the second network address of the second mobile terminal.

第六方面,本发明实施例还提供了一种数据包的传输装置,所述装置包括:In a sixth aspect, the embodiment of the present invention also provides a data packet transmission device, the device comprising:

接收单元,用于网关接收第一移动终端发送的第一封装数据包,所述第一封装数据包中的第一封装源地址为所述第一移动终端的第一网络地址,第一封装目标地址为第二移动终端所对应的第二标识地址;The receiving unit is used for the gateway to receive the first encapsulated data packet sent by the first mobile terminal, the first encapsulated source address in the first encapsulated data packet is the first network address of the first mobile terminal, and the first encapsulated target The address is a second identification address corresponding to the second mobile terminal;

映射单元,用于所述网关将所述第二标识地址映射为所述第二移动终端的第二网络地址;a mapping unit, configured for the gateway to map the second identification address to a second network address of the second mobile terminal;

发送单元,用于所述网关根据所述第二网络地址将所述第一封装数据包发送到所述第二移动终端,以便所述第二移动终端将所述第一封装数据包解封装得到所述第一网络地址。a sending unit, configured for the gateway to send the first encapsulated data packet to the second mobile terminal according to the second network address, so that the second mobile terminal decapsulates the first encapsulated data packet to obtain The first network address.

第七方面,本发明实施例还提供了一种数据包的传输装置,所述装置包括:In the seventh aspect, the embodiment of the present invention also provides a device for transmitting data packets, the device comprising:

设置单元,用于第一移动终端设置待向第二移动终端发送的初始数据包,所述初始数据包中包括所述第一移动终端的第一标识地址;并且所述初始数据包中的第一源地址为所述第一移动终端所的第一网络地址,第一目标地址为所述第二移动终端所对应的第二标识地址;The setting unit is used for the first mobile terminal to set an initial data packet to be sent to the second mobile terminal, the initial data packet includes the first identification address of the first mobile terminal; and the first data packet in the initial data packet A source address is a first network address of the first mobile terminal, and a first target address is a second identification address corresponding to the second mobile terminal;

发送单元,用于向所述第二移动终端发送初始数据包,以便网关将所述初始数据包中的所述第二标识地址映射为所述第二移动终端的第二网络地址。A sending unit, configured to send an initial data packet to the second mobile terminal, so that the gateway maps the second identification address in the initial data packet to a second network address of the second mobile terminal.

第八方面,本发明实施例还提供了一种数据包的传输装置,所述装置包括:In the eighth aspect, the embodiment of the present invention also provides a data packet transmission device, the device comprising:

接收单元,用于网关接收第一移动终端发送的初始数据包,所述初始数据包中包括所述第一移动终端的第一标识地址;并且所述初始数据包中的第一源地址为所述第一移动终端的第一网络地址,第一目标地址为所述第二移动终端所对应的第二标识地址;The receiving unit is used for the gateway to receive the initial data packet sent by the first mobile terminal, the initial data packet includes the first identification address of the first mobile terminal; and the first source address in the initial data packet is the The first network address of the first mobile terminal, the first target address is the second identification address corresponding to the second mobile terminal;

映射单元,用于所述网关将所述第二标识地址映射为所述第二移动终端的第二网络地址;a mapping unit, configured for the gateway to map the second identification address to a second network address of the second mobile terminal;

发送单元,用于所述网关根据所述第二网络地址将所述初始数据包发送到所述第二移动终端,以便所述第二移动终端从所述初始数据包中得到所述第一网络地址。a sending unit, configured for the gateway to send the initial data packet to the second mobile terminal according to the second network address, so that the second mobile terminal obtains the first network address from the initial data packet address.

本实施例的数据包的传输方法和装置,第一移动终端和第二移动终端可以利用标识地址即可以向对端移动终端发送数据包,利用网关进行IP映射,网络地址的变化对第一移动终端和第二移动终端发送数据包没有影响,不需要应用服务器或其它设备在移动终端之间先交换网络地址再通信,处理方法简单。In the data packet transmission method and device of this embodiment, the first mobile terminal and the second mobile terminal can use the identification address to send data packets to the opposite mobile terminal, and use the gateway to perform IP mapping. There is no influence on the data packets sent by the terminal and the second mobile terminal, and there is no need for an application server or other equipment to exchange network addresses before communicating between the mobile terminals, and the processing method is simple.

附图说明Description of drawings

图1为本发明实施例数据包的传输方法的流程图;Fig. 1 is the flowchart of the transmission method of data packet of the embodiment of the present invention;

图2为本发明实施例数据包的传输方法的另一流程图;Fig. 2 is another flow chart of the method for transmitting a data packet according to an embodiment of the present invention;

图3为本发明另一实施例数据包的传输方法的流程图;3 is a flowchart of a data packet transmission method according to another embodiment of the present invention;

图4为本发明另一实施例数据包的传输方法的另一流程图;4 is another flowchart of a data packet transmission method according to another embodiment of the present invention;

图5为本发明实施例数据包的传输装置的示意图;5 is a schematic diagram of a data packet transmission device according to an embodiment of the present invention;

图6为本发明实施例数据包的传输装置的另一示意图;6 is another schematic diagram of a data packet transmission device according to an embodiment of the present invention;

图7为本发明另一实施例数据包的传输装置的示意图;7 is a schematic diagram of a data packet transmission device according to another embodiment of the present invention;

图8为本发明另一实施例数据包的传输装置的另一示意图。FIG. 8 is another schematic diagram of a data packet transmission device according to another embodiment of the present invention.

具体实施方式Detailed ways

下面通过附图和实施例,对本发明的技术方案做进一步的详细描述。The technical solutions of the present invention will be described in further detail below with reference to the accompanying drawings and embodiments.

本发明实施例在移动通信分组域网络给UE动态分配IP地址的情况下直接实现分组域终端互访,不需要应用服务器或其它在UE之间先交换IP地址再通信的方法。In the embodiment of the present invention, when the mobile communication packet domain network dynamically assigns an IP address to the UE, the mutual access of the packet domain terminals is directly realized, without the need of an application server or other methods for exchanging IP addresses between UEs first and then communicating.

本发明实施例可以但不限于用于各种移动通信分组域网络:长期演进(LongTermEvolution,LTE)、高速下行链路分组接入(HighSpeedDownlinkPacketAccess,HSPA)、增强型高速下行链路分组接入(HSPAEvolution,HSPA+),通用移动通信系统(UniversalMobileTelecommunicationsSystem,UMTS),称码分多址接入(CodeDivisionMultipleAccess,CDMA),时分同步码分多址(TimeDivision-SynchronousCodeDivisionMultipleAccess,TD-SCDMA),通用分组无线服务(GeneralPacketRadioService,GPRS),增强型数据速率GSM演进(EnhancedDataRateforGSMEvolution,EDGE),全球微波互联接入(WorldwideInteroperabilityforMicrowaveAccess,WiMAX)。The embodiment of the present invention can be used but not limited to various mobile communication packet domain networks: Long Term Evolution (LongTermEvolution, LTE), High Speed Downlink Packet Access (HighSpeedDownlinkPacketAccess, HSPA), Enhanced High Speed Downlink Packet Access (HSPAEvolution , HSPA+), Universal Mobile Telecommunications System (UMTS), called Code Division Multiple Access (CDMA), Time Division Synchronous Code Division Multiple Access (TimeDivision-Synchronous Code Division Multiple Access, TD-SCDMA), General Packet Radio Service (GeneralPacketRadioService, GPRS), enhanced data rate GSM evolution (EnhancedDataRateforGSMEvolution, EDGE), global microwave interconnection access (WorldwideInteroperabilityforMicrowaveAccess, WiMAX).

本发明实施例在现有的网络地址,如IP地址分配机制之上,新增一个标识地址,即标识IP(IdentityIP)地址。In the embodiment of the present invention, an identification address, that is, an Identity IP (Identity IP) address is added on top of an existing network address, such as an IP address allocation mechanism.

该标识IP对每个终端固定且唯一,并且格式可以是IPv6、或IPv4,且与网络分配的IP地址格式完全独立,另外标识IP不参与网络通信的IP地址分配、不占用网络通信的IP地址实际资源。The identification IP is fixed and unique to each terminal, and the format can be IPv6 or IPv4, and is completely independent from the format of the IP address allocated by the network. In addition, the identification IP does not participate in the IP address allocation of network communication and does not occupy the IP address of network communication actual resources.

图1为本发明实施例数据包的传输方法的流程图,如图所示,本实施例为UE侧的具体处理过程,包括如下步骤:FIG. 1 is a flowchart of a data packet transmission method according to an embodiment of the present invention. As shown in the figure, this embodiment is a specific processing process on the UE side, including the following steps:

步骤101,第一移动终端UE1设置待向第二移动终端UE2发送的初始数据包,初始数据包中的第一源地址(第一Src地址)为第一移动终端所对应的第一标识地址I-IP-1,第一目标地址(第一Dest地址)为UE2所对应的第二标识地址I-IP-2;Step 101, the first mobile terminal UE1 sets an initial data packet to be sent to the second mobile terminal UE2, the first source address (first Src address) in the initial data packet is the first identification address I corresponding to the first mobile terminal -IP-1, the first destination address (first Dest address) is the second identification address I-IP-2 corresponding to UE2;

在UE1向UE2设置初始数据包的时候,UE1侧并不知道UE2的真实网络地址,即IP-2,而只知道UE2的标识地址,即I-IP-2,而且UE2的标识地址是与UE唯一对应而且不变的,这样就可以方便UE1为UE2发送数据包,例如IP数据包。When UE1 sets the initial data packet to UE2, UE1 does not know the real network address of UE2, that is, IP-2, but only knows the identification address of UE2, that is, I-IP-2, and the identification address of UE2 is the same as that of UE The only corresponding and unchanged, so that it is convenient for UE1 to send data packets, such as IP data packets, for UE2.

而且UE1知道本端的网络地址IP-1和标识地址I-IP-1,所以在向UE2设置的初始数据包中的第一Src地址填写为I-IP-1,第一Dest地址中填写为I-IP-2,具体的,可以由UE1的应用程序进行填写。Moreover, UE1 knows the network address IP-1 and the identification address I-IP-1 of the local end, so the first Src address in the initial data packet set to UE2 is filled with I-IP-1, and the first Dest address is filled with I -IP-2, specifically, can be filled by the application program of UE1.

步骤102,对初始数据包进行隧道封装得到第一封装数据包并发送,第一封装数据包中的第一封装源地址(第一封装Src地址)为UE1的第一网络地址IP-1,第一封装目标地址(第一封装Dest地址)为第二标识地址I-IP-2,以便网关将第二标识地址映射为UE2的第二网络地址IP-2。Step 102, perform tunnel encapsulation on the initial data packet to obtain the first encapsulated data packet and send it, the first encapsulated source address (first encapsulated Src address) in the first encapsulated data packet is the first network address IP-1 of UE1, the An encapsulation target address (the first encapsulation Dest address) is the second identification address I-IP-2, so that the gateway maps the second identification address to the second network address IP-2 of UE2.

UE1具有IP隧道功能,对IP初始数据包进行封装,封装后的第一封装数据包的第一封装Src地址为IP-1,第一封装Dest地址为I-IP-2,而网关维护有UE1的网络地址IP-1和标识地址I-IP-1,同时也维护有UE2的网络地址IP-2和标识地址I-IP-2;当接收到UE1发送的第一封装数据包时,得到该封装数据包的第一封装Dest地址I-IP-2,网关利用IP映射功能将第一封装Dest地址I-IP-2映射为UE2的网络地址IP-2。UE1 has an IP tunnel function, and encapsulates the initial IP data packet. The first encapsulated Src address of the encapsulated first encapsulated data packet is IP-1, the first encapsulated Dest address is I-IP-2, and the gateway maintains UE1 The network address IP-1 and identification address I-IP-1 of UE2 are maintained, and the network address IP-2 and identification address I-IP-2 of UE2 are also maintained; when the first encapsulated data packet sent by UE1 is received, the Encapsulate the first encapsulated Dest address I-IP-2 of the data packet, and the gateway uses the IP mapping function to map the first encapsulated Dest address I-IP-2 to the network address IP-2 of UE2.

再如图1所示,本实施例还包括如下步骤:As shown in Figure 1 again, the present embodiment also includes the following steps:

步骤103,UE2接收第一封装数据包;Step 103, UE2 receives the first encapsulated data packet;

步骤104,对第一封装数据包进行隧道解封装,得到第一网络地址IP-1。Step 104, perform tunnel decapsulation on the first encapsulated data packet to obtain the first network address IP-1.

UE2收到第一封装数据包后,对第一封装数据包进行解封装,解封装以后得到初始IP数据包,并且得到第一封装Src地址为UE1的网络地址IP-1。此时UE2通过此次接收UE1发送的第一封装数据包已经得到了UE1的网络地址IP-1,而且本身也保存有UE1的固定的唯一标识地址I-IP-1。After receiving the first encapsulated data packet, UE2 decapsulates the first encapsulated data packet, obtains the initial IP data packet after decapsulation, and obtains the first encapsulated Src address as UE1's network address IP-1. At this time, UE2 has obtained the network address IP-1 of UE1 by receiving the first encapsulated data packet sent by UE1 this time, and also stores the fixed unique identification address I-IP-1 of UE1 itself.

步骤105,UE2设置待向UE1发送的回复数据包,回复数据包中的第二源地址(第二Src地址)为第二标识地址I-IP-2,第二目标地址(第二Dest地址)为第一标识地址I-IP-1;回复数据包可以是IP数据包;Step 105, UE2 sets the reply data packet to be sent to UE1, the second source address (second Src address) in the reply data packet is the second identification address I-IP-2, and the second destination address (second Dest address) It is the first identification address I-IP-1; the reply data packet can be an IP data packet;

因为UE2知道了UE1的网络地址IP-1,也知道UE1的标识地址I-IP-1,所以UE2在回复数据包的第二Src地址填写I-IP-2,第二Dest地址填写I-IP-1,具体的,可以由UE1的应用程序进行填写。Because UE2 knows the network address IP-1 of UE1 and the identification address I-IP-1 of UE1, UE2 fills in I-IP-2 in the second Src address of the reply packet, and fills in I-IP in the second Dest address -1, specifically, can be filled in by the application program of UE1.

步骤106,对回复数据包进行隧道封装得到第二封装数据包并发送,第二封装数据包中的第二封装源地址(第二封装Src地址)为第二网络地址IP-2,第二封装目标地址(第二封装Dest地址)为第一网络地址IP-1,以便网关根据第一网络地址将第二封装数据包发送给UE1。Step 106, perform tunnel encapsulation on the reply data packet to obtain a second encapsulated data packet and send it, the second encapsulation source address (second encapsulation Src address) in the second encapsulation data packet is the second network address IP-2, the second encapsulation The destination address (the second encapsulated Dest address) is the first network address IP-1, so that the gateway sends the second encapsulated data packet to UE1 according to the first network address.

UE2也具有IP隧道功能,对IP回复数据包进行封装,封装后的第二封装数据包的第二封装Src地址为IP-2,第二封装Dest地址为IP-1,而当网关当接收到UE1发送的第二封装数据包时,得到该封装数据包的第一封装Dest地址IP-1。UE2 also has an IP tunnel function, and encapsulates the IP reply data packet. The second encapsulated Src address of the encapsulated second encapsulated data packet is IP-2, and the second encapsulated Dest address is IP-1. When the gateway receives When sending the second encapsulated data packet, UE1 obtains the first encapsulated Dest address IP-1 of the encapsulated data packet.

步骤107,UE1接收第二封装数据包;Step 107, UE1 receives the second encapsulated data packet;

步骤108,对第二封装数据包进行隧道解封装,得到第二网络地址IP2。Step 108, perform tunnel decapsulation on the second encapsulated data packet to obtain the second network address IP2.

UE1收到第二封装数据包后,对第二封装数据包进行解封装,解封装以后得到IP回复数据包,并且得到第二封装Src地址为UE2的网络地址IP-2。此时UE1通过此次接收UE2发送的第二封装数据包已经得到了UE2的网络地址IP-2,而且本身也保存有UE2的固定的唯一标识地址I-IP-2。After UE1 receives the second encapsulated data packet, it decapsulates the second encapsulated data packet, obtains an IP reply data packet after decapsulation, and obtains the second encapsulated Src address as UE2's network address IP-2. At this time, UE1 has obtained the network address IP-2 of UE2 by receiving the second encapsulated data packet sent by UE2 this time, and also stores the fixed unique identification address I-IP-2 of UE2 itself.

这样,此后UE1就可以像UE2向UE1发送第二封装数据包一样向UE2发送后续封装数据包了,因为已经得到UE2的网络地址IP-2,这样后续封装数据包的封装Dest地址就可以直接填写IP-2了,而非发送第一封装数据包时只能填写I-IP-2。网关接收到后续封装数据包后根据封装Dset地址IP-2就可以直接转发,而不需要进行IP映射,将第二标识地址映射为第二网络地址了。In this way, UE1 can then send subsequent encapsulated data packets to UE2 like UE2 sending the second encapsulated data packet to UE1, because the network address IP-2 of UE2 has been obtained, so the encapsulated Dest address of subsequent encapsulated data packets can be directly filled in IP-2, instead of sending the first encapsulated packet, you can only fill in I-IP-2. After the gateway receives the subsequent encapsulated data packet, it can directly forward it according to the encapsulated Dset address IP-2, without IP mapping, and maps the second identification address to the second network address.

此时对于UE1和UE2来讲都具有对方的网络地址IP和标识地址I-IP,这样如果需要向对端发送封装数据包的时候都类似于步骤105和106的过程,都可以直接将网络地址IP填充于封装数据包的Dest地址中了,这样就不需要网关再进行IP映射处理,直接根据Dest地址将封装数据包发送。At this time, both UE1 and UE2 have the other party's network address IP and identification address I-IP, so that if it is necessary to send an encapsulated data packet to the other end, it is similar to the process of steps 105 and 106, and the network address can be directly The IP is filled in the Dest address of the encapsulated data packet, so that the gateway does not need to perform IP mapping processing, and the encapsulated data packet is sent directly according to the Dest address.

图2为本发明实施例数据包的传输方法的另一流程图,如图所示,本实施例为上一实施例对应的网关侧的具体处理过程,包括如下步骤:Fig. 2 is another flow chart of the transmission method of the data packet of the embodiment of the present invention, as shown in the figure, this embodiment is the specific processing process of the gateway side corresponding to the previous embodiment, including the following steps:

步骤201,网关接收UE1发送的第一封装数据包,第一封装数据包中的第一封装源地址(第一封装Src地址)为UE1的第一网络地址IP-1,第一封装目标地址(第一封装Dest地址)为UE2所对应的第二标识地址I-IP-2;Step 201, the gateway receives the first encapsulated data packet sent by UE1, the first encapsulated source address (first encapsulated Src address) in the first encapsulated data packet is the first network address IP-1 of UE1, and the first encapsulated target address ( The first encapsulation Dest address) is the second identification address I-IP-2 corresponding to UE2;

步骤202,将第二标识地址映射为UE2的第二网络地址;Step 202, mapping the second identification address to the second network address of UE2;

网关维护有UE1的网络地址IP-1和标识地址I-IP-1,同时也维护有UE2的网络地址IP-2和标识地址I-IP-2;当接收到UE1发送的第一封装数据包时,得到该封装数据包的第一封装Dest地址I-IP-2,网关利用IP映射功能将第一封装Dest地址I-IP-2映射为UE2的网络地址IP-2。The gateway maintains the network address IP-1 and identification address I-IP-1 of UE1, and also maintains the network address IP-2 and identification address I-IP-2 of UE2; when receiving the first encapsulated data packet sent by UE1 , the first encapsulated Dest address I-IP-2 of the encapsulated data packet is obtained, and the gateway uses the IP mapping function to map the first encapsulated Dest address I-IP-2 to the network address IP-2 of UE2.

步骤203,根据第二网络地址IP-2将第一封装数据包发送到UE2,以便UE2将第一封装数据包解封装得到第一网络地址IP-1。Step 203: Send the first encapsulated data packet to UE2 according to the second network address IP-2, so that UE2 decapsulates the first encapsulated data packet to obtain the first network address IP-1.

再如图2所示,本实施例还包括如下步骤:As shown in Figure 2 again, the present embodiment also includes the following steps:

步骤204,网关接收UE2发送的第二封装数据包,第二封装数据包中的第二封装源地址(第二封装Src地址)为UE2的第二网络地址IP-2,第二封装目标地址(第二封装Dest地址)为第一网络地址IP-1;Step 204, the gateway receives the second encapsulated data packet sent by UE2, the second encapsulated source address (second encapsulated Src address) in the second encapsulated data packet is the second network address IP-2 of UE2, and the second encapsulated target address ( The second encapsulation Dest address) is the first network address IP-1;

步骤205,根据第一网络地址将第二封装数据包发送到UE1,以便UE1将第二封装数据包解封装得到第二网络地址IP-2。Step 205: Send the second encapsulated data packet to UE1 according to the first network address, so that UE1 decapsulates the second encapsulated data packet to obtain the second network address IP-2.

因为UE2在接收到UE1的第一封装数据包的时候,就得到UE1的第一网络地址IP-1了,所以在封装第二封装数据包的时候,将第二封装Dest地址填写为IP-1,这样网关接收到第二封装数据包的时候,第二封装Dest地址为IP-1,就可以直接根据IP-1将第二封装数据包发送到UE1了。UE1将第二封装数据包解封装就得到UE2的第二网络地址IP-2了。后续UE1向UE2发送手续封装数据包的时候,后续封装数据包的封装Dest地址都可以直接填写IP-2,这样网关就可以直接根据IP-2将后续封装数据包发送到UE2了,而无需再使用IP映射。Because UE2 obtains the first network address IP-1 of UE1 when receiving the first encapsulated data packet of UE1, so when encapsulating the second encapsulated data packet, fill in the second encapsulated Dest address as IP-1 , so that when the gateway receives the second encapsulated data packet, the second encapsulated Dest address is IP-1, and the second encapsulated data packet can be directly sent to UE1 according to IP-1. UE1 decapsulates the second encapsulated data packet to obtain the second network address IP-2 of UE2. When UE1 subsequently sends a procedure-encapsulated data packet to UE2, the encapsulated Dest address of the subsequent encapsulated data packet can be directly filled in IP-2, so that the gateway can directly send the subsequent encapsulated data packet to UE2 according to IP-2 without further Use IP mapping.

本发明实施例数据包的传输方法在UE侧进行初始数据包的封装,再并不知道网络地址的目标地址时封装入标识地址的目标地址,可以在网络层的网关进行IP映射,将标识地址映射为网络地址,而不需要终端侧知晓目标终端的网络地址,可以解决UE初始IP地址变化的问题,应用层的UE只需要知道自己和目标UE的标识IP即可、IP地址的变化对其完全透明,不需要应用服务器或其它设备在UE之间先交换IP地址再进行UE的通信,处理方法简单。The transmission method of the data packet in the embodiment of the present invention encapsulates the initial data packet on the UE side, and when the target address of the network address is not known, it is encapsulated into the target address of the identification address, IP mapping can be performed at the gateway of the network layer, and the identification address It is mapped to a network address without requiring the terminal side to know the network address of the target terminal, which can solve the problem of UE’s initial IP address change. The UE at the application layer only needs to know the identity IP of itself and the target UE. It is completely transparent and does not require an application server or other equipment to exchange IP addresses between UEs before communicating with UEs. The processing method is simple.

图3为本发明实施例另一数据包的传输方法的流程图,如图所示,本实施例为UE侧的具体处理过程,包括如下步骤:FIG. 3 is a flowchart of another data packet transmission method according to an embodiment of the present invention. As shown in the figure, this embodiment is a specific processing process on the UE side, including the following steps:

步骤301、UE1设置待向UE2发送的初始数据包,初始数据包中包括UE1的第一标识地址I-IP-1;并且初始数据包中的第一源地址(第一Src地址)为UE1所的第一网络地址IP-1,第一目标地址(第一Dest地址)为UE2所对应的第二标识地址I-IP-2;初始数据包可以是IP数据包;Step 301, UE1 sets an initial data packet to be sent to UE2, the initial data packet includes UE1's first identification address I-IP-1; and the first source address (first Src address) in the initial data packet is UE1's The first network address IP-1, the first destination address (the first Dest address) is the second identification address I-IP-2 corresponding to UE2; the initial data packet may be an IP data packet;

在UE1向UE2发送初始数据包的时候,UE1侧并不知道UE2的真实网络地址,即IP-2,而只知道UE2的标识地址,即I-IP-2,而且UE2的标识地址是固定唯一而且不变的,这样就可以方便UE1为UE2发送IP数据包。When UE1 sends the initial data packet to UE2, UE1 does not know the real network address of UE2, namely IP-2, but only knows the identification address of UE2, namely I-IP-2, and the identification address of UE2 is fixed and unique Moreover, it remains unchanged, so that it is convenient for UE1 to send IP data packets for UE2.

而且UE1知道本端的网络地址IP-1和标识地址I-IP-1,所以在向UE2发送的初始数据包中UE1的第一Src填写为UE1的网络地址IP-1,第一Dest地址填写为UE2的标识地址I-IP-2,具体的,可以由UE1的应用程序进行填写。另外可以在数据包的负载(Payload)中包含UE1的第一标识地址I-IP-1。Moreover, UE1 knows the network address IP-1 and the identification address I-IP-1 of the local end, so in the initial data packet sent to UE2, the first Src of UE1 is filled with the network address IP-1 of UE1, and the first Dest address is filled with The identification address I-IP-2 of UE2, specifically, can be filled in by the application program of UE1. In addition, the first identification address I-IP-1 of UE1 may be included in the payload (Payload) of the data packet.

步骤302、向UE2发送初始数据包,以便网关将初始数据包的第二标识地址映射为UE2的第二网络地址。Step 302: Send an initial data packet to UE2, so that the gateway maps the second identification address of the initial data packet to the second network address of UE2.

网关维护有UE1的网络地址IP-1和标识地址I-IP-1,同时也维护有UE2的网络地址IP-2和标识地址I-IP-2;当接收到UE1发送的IP初始数据包时,得到该初始数据包的第一Dest地址I-IP-2,网关利用IP映射功能将第一Dest地址I-IP-2映射为UE2的网络地址IP-2;网关根据UE2的网路地址IP-2将初始数据包发送给UE2。The gateway maintains the network address IP-1 and identification address I-IP-1 of UE1, and also maintains the network address IP-2 and identification address I-IP-2 of UE2; when receiving the IP initial data packet sent by UE1 , to obtain the first Dest address I-IP-2 of the initial data packet, the gateway uses the IP mapping function to map the first Dest address I-IP-2 to the network address IP-2 of UE2; -2 Send the initial data packet to UE2.

再如图3所示,本实施例还包括如下步骤:As shown in Figure 3 again, the present embodiment also includes the following steps:

步骤303、UE2接收初始数据包;Step 303, UE2 receives the initial data packet;

步骤304、从初始数据包中得到第一网络地址IP-1。Step 304. Obtain the first network address IP-1 from the initial data packet.

UE2收到IP初始数据包后,得到第一Src地址为UE1的网络地址IP-1和第一Dest的网路地址IP-2,以及从IP数据包的Payload中得到UE1的标识地址I-IP-1,得知该数据包是UE1发送给自己的。After receiving the IP initial data packet, UE2 obtains the network address IP-1 of UE1 with the first Src address and IP-2 of the first Dest, and obtains the identification address I-IP of UE1 from the Payload of the IP data packet -1, knowing that the data packet is sent by UE1 to itself.

此时UE2通过此次接收UE1发送的IP初始数据包已经得到了UE1的网络地址IP-1,而且本身也保存有UE1的固定且唯一的标识地址I-IP-1。At this time, UE2 has obtained the network address IP-1 of UE1 by receiving the IP initial data packet sent by UE1 this time, and also stores the fixed and unique identification address I-IP-1 of UE1 itself.

步骤305、UE2设置待向UE1发送的回复数据包,回复数据包中包括UE2所对应的第二标识地址I-IP-2;回复数据包中的第二源地址(第二Src地址)为第二网络地址IP-2,第二目标地址(第二Dest地址)为第一网络地址IP-1;Step 305, UE2 sets a reply data packet to be sent to UE1, the reply data packet includes the second identification address I-IP-2 corresponding to UE2; the second source address (second Src address) in the reply data packet is the first The second network address IP-2, the second destination address (the second Dest address) is the first network address IP-1;

因为UE2知道了UE1的网络地址IP-1,所以UE2在IP回复数据包的第二Src地址填写IP-2,第二Dest地址填写IP-1,具体的,可以由UE2的应用程序进行填写.另外在数据包的Payload中包含UE2自身的标识地址信息I-IP-2。Because UE2 knows the network address IP-1 of UE1, UE2 fills in IP-2 in the second Src address of the IP reply packet, and fills in IP-1 in the second Dest address. Specifically, it can be filled in by the application program of UE2. In addition, the Payload of the data packet includes the identification address information I-IP-2 of UE2 itself.

步骤306、向UE1发送回复数据包,以便网关根据第一网络地址将回复数据包发送给UE1。Step 306: Send a reply data packet to UE1, so that the gateway sends the reply data packet to UE1 according to the first network address.

网关收到IP数据包后,因为第二Dest地址为网络地址IP-1,所以不再需要其IP映射功能处理,直接根据Dest地址IP-1将封装IP数据包发送至UE1。After the gateway receives the IP data packet, because the second Dest address is the network address IP-1, it no longer needs its IP mapping function to process, and directly sends the encapsulated IP data packet to UE1 according to the Dest address IP-1.

步骤307、UE1接收回复数据包,得到第二网络地址IP-2。Step 307, UE1 receives the reply data packet, and obtains the second network address IP-2.

UE1收到IP回复数据包后,识别到的第二Src地址就是网络地址IP-2,第二Dest地址是网络地址IP-1,另外可以从IP回复数据包的Payload中得到UE2的标识地址I-IP-2,而且本身也保存有UE2的固定的唯一标识地址I-IP-2。After UE1 receives the IP reply packet, the second Src address recognized is the network address IP-2, and the second Dest address is the network address IP-1. In addition, UE2’s identification address I can be obtained from the Payload of the IP reply packet. -IP-2, and also stores the fixed unique identification address I-IP-2 of UE2.

这样,此后UE1就可以像UE2向UE1发送回复数据包一样向UE2发送后续数据包了,因为已经得到UE2的网络地址IP-2,这样后续数据包的Dest地址就可以直接填写IP-2了,而非发送初始数据包时只能填写I-IP-2。网关接收到后续数据包后根据Dset地址就可以直接转发,而不需要进行IP映射,将第二标识地址映射为第二网络地址了。In this way, UE1 can send subsequent data packets to UE2 in the same way that UE2 sends a reply packet to UE1, because the network address IP-2 of UE2 has been obtained, so the Dest address of subsequent data packets can be directly filled in IP-2. Instead of sending the initial data packet, only I-IP-2 can be filled in. After the gateway receives the subsequent data packet, it can directly forward it according to the Dset address without performing IP mapping, and maps the second identification address to the second network address.

此时对于UE1和UE2来讲都具有对方的网络地址IP和标识地址I-IP,这样如果需要向对端发送IP数据包的时候都类似于步骤305和306的过程,都可以直接将网络地址IP填充于IP数据包的Dest地址中了,这样就不需要网关再进行IP映射处理,直接根据Dest地址将IP数据包发送。At this time, both UE1 and UE2 have the other party's network address IP and identification address I-IP, so that if it is necessary to send an IP data packet to the other end, it is similar to the process of steps 305 and 306, and the network address can be directly The IP is filled in the Dest address of the IP data packet, so that the gateway does not need to perform IP mapping processing, and the IP data packet is directly sent according to the Dest address.

图4为本发明实施例另一数据包的传输方法的另一流程图,如图所示,本实施例为上一实施例对应的网关侧的具体处理过程,包括如下步骤:FIG. 4 is another flow chart of another data packet transmission method according to an embodiment of the present invention. As shown in the figure, this embodiment is a specific processing process on the gateway side corresponding to the previous embodiment, including the following steps:

步骤401,网关接收UE1发送的初始数据包,初始数据包中包括UE1的第一标识地址I-IP-1;并且初始数据包中的第一源地址(第一Src地址)为UE1的第一网络地址IP-1,第一目标地址(第一Dest地址)为UE2所对应的第二标识地址I-IP-2;初始数据包可以是IP数据包;Step 401, the gateway receives the initial data packet sent by UE1, the initial data packet includes UE1's first identification address I-IP-1; and the first source address (first Src address) in the initial data packet is UE1's first The network address IP-1, the first destination address (first Dest address) is the second identification address I-IP-2 corresponding to UE2; the initial data packet may be an IP data packet;

网关维护有UE1的网络地址IP-1和标识地址I-IP-1,同时也维护有UE2的网络地址IP-2和标识地址I-IP-2;当接收到UE1发送的IP初始数据包时,得到该初始数据包的第一Dest地址I-IP-2。The gateway maintains the network address IP-1 and identification address I-IP-1 of UE1, and also maintains the network address IP-2 and identification address I-IP-2 of UE2; when receiving the IP initial data packet sent by UE1 , to obtain the first Dest address I-IP-2 of the initial data packet.

步骤402,将第二标识地址映射为UE2的第二网络地址;Step 402, mapping the second identification address to the second network address of UE2;

网关利用IP映射功能将第一Dest地址I-IP-2映射为UE2的网络地址IP-2,The gateway uses the IP mapping function to map the first Dest address I-IP-2 to the network address IP-2 of UE2,

步骤403,根据第二网络地址将初始数据包发送到UE2,以便UE2从初始数据包中得到第一网络地址IP-1。Step 403: Send an initial data packet to UE2 according to the second network address, so that UE2 obtains the first network address IP-1 from the initial data packet.

网关根据UE2的网路地址IP-2将初始数据包发送给UE2,The gateway sends the initial data packet to UE2 according to the network address IP-2 of UE2,

再如图4所示,本实施例还包括如下步骤:As shown in Figure 4 again, the present embodiment also includes the following steps:

步骤404,网关接收UE2发送的回复数据包,回复数据包中包括UE2所对应的第二标识地址I-IP-2;回复数据包中的第二源地址(第二Src地址)为第二网络地址IP-2,第二目标地址(第二Dest地址)为第一网络地址IP-1;Step 404, the gateway receives the reply data packet sent by UE2, the reply data packet includes the second identification address I-IP-2 corresponding to UE2; the second source address (second Src address) in the reply data packet is the second network address Address IP-2, the second destination address (second Dest address) is the first network address IP-1;

步骤405,根据第一网络地址将回复数据包发送给UE1,以便UE1从回复数据包中得到第二网络地址IP-2。Step 405: Send a reply data packet to UE1 according to the first network address, so that UE1 obtains the second network address IP-2 from the reply data packet.

网关收到IP数据包后,因为第二Dest地址为网络地址IP-1,所以不再需要其IP映射功能处理,直接根据Dest地址IP-1将封装IP数据包发送至UE1。After the gateway receives the IP data packet, because the second Dest address is the network address IP-1, it no longer needs its IP mapping function to process, and directly sends the encapsulated IP data packet to UE1 according to the Dest address IP-1.

因为UE2在接收到UE1的初始数据包的时候,就得到UE1的第一网络地址IP-1了,所以在设置回复数据包的时候,将第二Dest地址填写为IP-1,这样网关接收到回复数据包的时候,第二Dest地址为IP-1,就可以直接根据IP-1将回复数据包发送到UE1了。UE1就得到UE2的第二网络地址IP-2了。后续UE1向UE2发送手续数据包的时候,后续数据包的封装Dest地址都可以直接填写IP-2,这样网关就可以直接根据IP-2将后续数据包发送到UE2了,而无需再使用IP映射。Because UE2 gets UE1's first network address IP-1 when it receives UE1's initial data packet, so when setting the reply packet, fill in the second Dest address as IP-1, so that the gateway receives When replying the data packet, the second Dest address is IP-1, and the reply data packet can be sent to UE1 directly according to IP-1. UE1 obtains the second network address IP-2 of UE2. When UE1 sends a procedure data packet to UE2, the encapsulation Dest address of the subsequent data packet can directly fill in IP-2, so that the gateway can directly send the subsequent data packet to UE2 according to IP-2, without using IP mapping .

本实施例的数据包的传输方法,在应用层UE发送初始数据包的时候在负载中携带本终端I-IP,而在Dest地址中填写目标终端的I-IP,利用网络侧的网关进行IP映射为目标终端的IP地址,目标终端则可以根据初始数据包得到源终端的IP地址。目标终端利用回复数据包中告知源终端目标终端的IP地址,这样终端在发送数据包的时候无需知道对端终端的IP地址,同样解决UE初始IP变化的问题,不需要应用服务器或其它设备在UE之间先交换IP地址再通信,处理方法简单。而且UE不需要具有IP隧道功能、不增加IP包大小。In the data packet transmission method of this embodiment, when the application layer UE sends the initial data packet, the I-IP of the terminal is carried in the load, and the I-IP of the target terminal is filled in the Dest address, and the IP address is carried out by using the gateway on the network side. Mapped to the IP address of the target terminal, the target terminal can obtain the IP address of the source terminal according to the initial data packet. The target terminal informs the source terminal of the IP address of the target terminal in the reply data packet, so that the terminal does not need to know the IP address of the peer terminal when sending the data packet, and also solves the problem of the initial IP change of the UE, without the need for an application server or other devices to The UEs exchange IP addresses before communicating, and the processing method is simple. Moreover, the UE does not need to have an IP tunnel function, and does not increase the size of the IP packet.

图5为本发明实施例数据包的传输装置的示意图,如图所示,本实施例具体包括:设置单元11和12封装单元。FIG. 5 is a schematic diagram of a data packet transmission device according to an embodiment of the present invention. As shown in the figure, this embodiment specifically includes: a setting unit 11 and a packaging unit 12 .

设置单元11用于第一移动终端UE1设置待向第二移动终端UE2发送的初始数据包,初始数据包中的第一源地址(第一Src地址)为第一移动终端所对应的第一标识地址I-IP-1,第一目标地址(第一Dest地址)为UE2所对应的第二标识地址I-IP-2;The setting unit 11 is used for the first mobile terminal UE1 to set the initial data packet to be sent to the second mobile terminal UE2, and the first source address (first Src address) in the initial data packet is the first identifier corresponding to the first mobile terminal Address I-IP-1, the first destination address (first Dest address) is the second identification address I-IP-2 corresponding to UE2;

封装单元12用于对初始数据包进行隧道封装得到第一封装数据包并发送,第一封装数据包中的第一封装源地址(第一封装Src地址)为UE1的第一网络地址IP-1,第一封装目标地址(第一封装Dest地址)为第二标识地址I-IP-2,以便网关将第二标识地址映射为UE2的第二网络地址IP-2。The encapsulation unit 12 is configured to perform tunnel encapsulation on the initial data packet to obtain a first encapsulated data packet and send it, and the first encapsulation source address (first encapsulation Src address) in the first encapsulated data packet is the first network address IP-1 of UE1 , the first encapsulation destination address (the first encapsulation Dest address) is the second identification address I-IP-2, so that the gateway maps the second identification address to the second network address IP-2 of UE2.

UE1具有IP隧道功能,对IP初始数据包进行封装,封装后的第一封装数据包的第一封装Src地址为IP-1,第一封装Dest地址为I-IP-2,而网关维护有UE1的网络地址IP-1和标识地址I-IP-1,同时也维护有UE2的网络地址IP-2和标识地址I-IP-2;当接收到UE1发送的第一封装数据包时,得到该封装数据包的第一封装Dest地址I-IP-2,网关利用IP映射功能将第一封装Dest地址I-IP-2映射为UE2的网络地址IP-2。UE1 has an IP tunnel function, and encapsulates the initial IP data packet. The first encapsulated Src address of the encapsulated first encapsulated data packet is IP-1, the first encapsulated Dest address is I-IP-2, and the gateway maintains UE1 The network address IP-1 and identification address I-IP-1 of UE2 are maintained, and the network address IP-2 and identification address I-IP-2 of UE2 are also maintained; when the first encapsulated data packet sent by UE1 is received, the Encapsulate the first encapsulated Dest address I-IP-2 of the data packet, and the gateway uses the IP mapping function to map the first encapsulated Dest address I-IP-2 to the network address IP-2 of UE2.

再如图5所示,本实施例还包括接收单元13和解封装单元14。As shown in FIG. 5 , this embodiment further includes a receiving unit 13 and a decapsulating unit 14 .

接收单元13用于UE2接收第一封装数据包;解封装单元14用于对第一封装数据包进行隧道解封装,得到第一网络地址IP-1。The receiving unit 13 is used for UE2 to receive the first encapsulated data packet; the decapsulating unit 14 is used for tunnel decapsulating the first encapsulated data packet to obtain the first network address IP-1.

所述设置单元12还用于UE2设置待向UE1发送的回复数据包,回复数据包中的第二源地址(第二Src地址)为第二标识地址I-IP-2,第二目标地址(第二Dest地址)为第一标识地址I-IP-1;回复数据包可以是IP数据包;The setting unit 12 is also used for UE2 to set the reply data packet to be sent to UE1, the second source address (second Src address) in the reply data packet is the second identification address I-IP-2, and the second destination address ( The second Dest address) is the first identification address I-IP-1; the reply data packet may be an IP data packet;

所述封装单元13还用于对回复数据包进行隧道封装得到第二封装数据包并发送,第二封装数据包中的第二封装源地址(第二封装Src地址)为第二网络地址IP-2,第二封装目标地址(第二封装Dest地址)为第一网络地址IP-1,以便网关根据第一网络地址将第二封装数据包发送给UE1。The encapsulation unit 13 is also used to perform tunnel encapsulation on the reply data packet to obtain a second encapsulated data packet and send it, and the second encapsulation source address (second encapsulation Src address) in the second encapsulated data packet is the second network address IP- 2. The second encapsulation destination address (second encapsulation Dest address) is the first network address IP-1, so that the gateway sends the second encapsulation data packet to UE1 according to the first network address.

所述接收单元13还用于UE1接收第二封装数据包;所述解封装单元14还用于对第二封装数据包进行隧道解封装,得到第二网络地址IP2。初始数据包为互联网协议IP数据包,所述第一网络地址和第二网络地址为IP地址,所述第一标识地址和第二标识地址为标识IP地址。The receiving unit 13 is also used for UE1 to receive the second encapsulated data packet; the decapsulating unit 14 is also used for performing tunnel decapsulation on the second encapsulated data packet to obtain the second network address IP2. The initial data packet is an Internet Protocol IP data packet, the first network address and the second network address are IP addresses, and the first identification address and the second identification address are identification IP addresses.

此时对于UE1和UE2来讲都具有对方的网络地址IP和标识地址I-IP,这样如果需要向对端发送封装数据包的时候都类似于步骤105和106的过程,都可以直接将网络地址IP填充于封装数据包的Dest地址中了,这样就不需要网关再进行IP映射处理,直接根据Dest地址将封装数据包发送。At this time, both UE1 and UE2 have the other party's network address IP and identification address I-IP, so that if it is necessary to send an encapsulated data packet to the other end, it is similar to the process of steps 105 and 106, and the network address can be directly The IP is filled in the Dest address of the encapsulated data packet, so that the gateway does not need to perform IP mapping processing, and the encapsulated data packet is sent directly according to the Dest address.

图6为本发明实施例数据包的传输装置的另一示意图,如图所示,本实施例具体包括:接收单元21、映射单元22和发送单元23。FIG. 6 is another schematic diagram of a data packet transmission device according to an embodiment of the present invention. As shown in the figure, this embodiment specifically includes: a receiving unit 21 , a mapping unit 22 and a sending unit 23 .

接收单元21用于网关接收UE1发送的第一封装数据包,第一封装数据包中的第一封装源地址(第一封装Src地址)为UE1的第一网络地址IP-1,第一封装目标地址(第一封装Dest地址)为UE2所对应的第二标识地址I-IP-2;The receiving unit 21 is used for the gateway to receive the first encapsulated data packet sent by UE1, the first encapsulated source address (first encapsulated Src address) in the first encapsulated data packet is the first network address IP-1 of UE1, and the first encapsulated target The address (first encapsulated Dest address) is the second identification address I-IP-2 corresponding to UE2;

映射单元22用于将第二标识地址映射为UE2的第二网络地址;The mapping unit 22 is configured to map the second identification address to a second network address of UE2;

发送单元23用于根据第二网络地址IP-2将第一封装数据包发送到UE2,以便UE2将第一封装数据包解封装得到第一网络地址IP-1。The sending unit 23 is configured to send the first encapsulated data packet to UE2 according to the second network address IP-2, so that UE2 decapsulates the first encapsulated data packet to obtain the first network address IP-1.

所述接收单元21还用于网关接收UE2发送的第二封装数据包,第二封装数据包中的第二封装源地址(第二封装Src地址)为UE2的第二网络地址IP-2,第二封装目标地址(第二封装Dest地址)为第一网络地址IP-1;The receiving unit 21 is also used for the gateway to receive the second encapsulated data packet sent by UE2, the second encapsulated source address (second encapsulated Src address) in the second encapsulated data packet is the second network address IP-2 of UE2, the second The destination address of the second encapsulation (the second encapsulation Dest address) is the first network address IP-1;

所述发送单元23还用于根据第一网络地址将第二封装数据包发送到UE1,以便UE1将第二封装数据包解封装得到第二网络地址IP-2。所述第一网络地址和第二网络地址为IP地址,所述第一标识地址和第二标识地址为标识IP地址。The sending unit 23 is further configured to send the second encapsulated data packet to UE1 according to the first network address, so that UE1 decapsulates the second encapsulated data packet to obtain the second network address IP-2. The first network address and the second network address are IP addresses, and the first identification address and the second identification address are identification IP addresses.

本发明实施例数据包的传输装置在UE侧进行初始数据包的封装,再并不知道网络地址的目标地址时封装入标识地址的目标地址,可以在网络层的网关进行IP映射,将标识地址映射为网络地址,而不需要终端侧知晓目标终端的网络地址,可以解决UE初始IP地址变化的问题,应用层的UE只需要知道自己和目标UE的标识IP即可、IP地址的变化对其完全透明,不需要应用服务器或其它设备在UE之间先交换IP地址再进行UE的通信,处理简单。The data packet transmission device in the embodiment of the present invention encapsulates the initial data packet on the UE side, and when the target address of the network address is not known, it is encapsulated into the target address of the identification address, and IP mapping can be performed at the gateway of the network layer, and the identification address It is mapped to a network address without requiring the terminal side to know the network address of the target terminal, which can solve the problem of UE’s initial IP address change. The UE at the application layer only needs to know the identity IP of itself and the target UE. It is completely transparent, and does not require an application server or other equipment to exchange IP addresses between UEs before communicating with UEs, and the processing is simple.

图7为本发明另一实施例数据包的传输装置的示意图,如图所示,本实施例具体包括:设置单元31和发送单元32。FIG. 7 is a schematic diagram of a data packet transmission device according to another embodiment of the present invention. As shown in the figure, this embodiment specifically includes: a setting unit 31 and a sending unit 32 .

设置单元31,用于UE1设置待向UE2发送的初始数据包,初始数据包中包括UE1的第一标识地址I-IP-1;并且初始数据包中的第一源地址(第一Src地址)为UE1所的第一网络地址IP-1,第一目标地址(第一Dest地址)为UE2所对应的第二标识地址I-IP-2;初始数据包可以是IP数据包址;The setting unit 31 is used for UE1 to set an initial data packet to be sent to UE2, the initial data packet includes the first identification address I-IP-1 of UE1; and the first source address (first Src address) in the initial data packet It is the first network address IP-1 of UE1, and the first destination address (first Dest address) is the second identification address I-IP-2 corresponding to UE2; the initial data packet may be an IP data packet address;

发送单元32用于向UE2发送初始数据包,以便网关将初始数据包的第二标识地址映射为UE2的第二网络地址。The sending unit 32 is configured to send the initial data packet to UE2, so that the gateway maps the second identification address of the initial data packet to the second network address of UE2.

再如图7所示,本实施例还包括:接收单元33和获取单元34。As shown in FIG. 7 , this embodiment further includes: a receiving unit 33 and an acquiring unit 34 .

接收单元33用于UE2接收初始数据包;获取单元34用于从初始数据包中得到第一网络地址IP-1。The receiving unit 33 is used for UE2 to receive the initial data packet; the obtaining unit 34 is used for obtaining the first network address IP-1 from the initial data packet.

所述设置单元31还用于UE2设置待向UE1发送的回复数据包,回复数据包中包括UE2所对应的第二标识地址I-IP-2;回复数据包中的第二源地址(第二Src地址)为第二网络地址IP-2,第二目标地址(第二Dest地址)为第一网络地址IP-1;The setting unit 31 is also used for UE2 to set a reply data packet to be sent to UE1, the reply data packet includes the second identification address I-IP-2 corresponding to UE2; the second source address (second source address) in the reply data packet Src address) is the second network address IP-2, and the second destination address (second Dest address) is the first network address IP-1;

所述发送单元32还用于向UE1发送回复数据包,以便网关根据第一网络地址将回复数据包发送给UE1。The sending unit 32 is further configured to send a reply data packet to UE1, so that the gateway sends the reply data packet to UE1 according to the first network address.

所述接收单元33还用于UE1接收回复数据包,得到第二网络地址IP-2。所述初始数据包具体在负载Payload中包括所述第一标识地址;所述回复数据包具体在负载中包括所述第二标识地址。所述第一网络地址和第二网络地址为IP地址,所述第一标识地址和第二标识地址为标识IP地址。The receiving unit 33 is also used for UE1 to receive the reply data packet to obtain the second network address IP-2. The initial data packet specifically includes the first identification address in the payload Payload; the reply data packet specifically includes the second identification address in the payload. The first network address and the second network address are IP addresses, and the first identification address and the second identification address are identification IP addresses.

此时对于UE1和UE2来讲都具有对方的网络地址IP和标识地址I-IP,这样如果需要向对端发送IP数据包的时候都类似于步骤305和306的过程,都可以直接将网络地址IP填充于IP数据包的Dest地址中了,这样就不需要网关再进行IP映射处理,直接根据Dest地址将IP数据包发送。At this time, both UE1 and UE2 have the other party's network address IP and identification address I-IP, so that if it is necessary to send an IP data packet to the other end, it is similar to the process of steps 305 and 306, and the network address can be directly The IP is filled in the Dest address of the IP data packet, so that the gateway does not need to perform IP mapping processing, and the IP data packet is directly sent according to the Dest address.

图8为本发明另一实施例数据包的传输装置的另一示意图,如图所示,本实施例具体包括:接收单元41、映射单元42和发送单元43。FIG. 8 is another schematic diagram of a data packet transmission device according to another embodiment of the present invention. As shown in the figure, this embodiment specifically includes: a receiving unit 41 , a mapping unit 42 and a sending unit 43 .

接收单元41用于网关接收UE1发送的初始数据包,初始数据包中包括UE1的第一标识地址I-IP-1;并且初始数据包中的第一源地址(第一Src地址)为UE1的第一网络地址IP-1,第一目标地址(第一Dest地址)为UE2所对应的第二标识地址I-IP-2;初始数据包可以是IP数据包;;The receiving unit 41 is used for the gateway to receive the initial data packet sent by UE1, the initial data packet includes the first identification address I-IP-1 of UE1; and the first source address (first Src address) in the initial data packet is UE1's The first network address IP-1, the first destination address (the first Dest address) is the second identification address I-IP-2 corresponding to UE2; the initial data packet may be an IP data packet;

映射单元42用于将第二标识地址映射为UE2的第二网络地址;The mapping unit 42 is configured to map the second identification address to a second network address of UE2;

发送单元43用于根据第二网络地址将初始数据包发送到UE2,以便UE2从初始数据包中得到第一网络地址IP-1。The sending unit 43 is configured to send the initial data packet to UE2 according to the second network address, so that UE2 obtains the first network address IP-1 from the initial data packet.

所述接收单元41还用于网关接收UE2发送的回复数据包,回复数据包中包括UE2所对应的第二标识地址I-IP-2;回复数据包中的第二源地址(第二Src地址)为第二网络地址IP-2,第二目标地址(第二Dest地址)为第一网络地址IP-1;The receiving unit 41 is also used for the gateway to receive the reply data packet sent by UE2, the reply data packet includes the second identification address I-IP-2 corresponding to UE2; the second source address (second Src address) in the reply data packet ) is the second network address IP-2, and the second destination address (the second Dest address) is the first network address IP-1;

所述发送单元43还用于根据第一网络地址将回复数据包发送给UE1,以便UE1从回复数据包中得到第二网络地址IP-2。所述初始数据包具体在负载中包括所述第一标识地址;所述回复数据包具体在负载中包括所述第二标识地址。所述第一网络地址和第二网络地址为IP地址,所述第一标识地址和第二标识地址为标识IP地址。The sending unit 43 is further configured to send a reply data packet to UE1 according to the first network address, so that UE1 obtains the second network address IP-2 from the reply data packet. The initial data packet specifically includes the first identification address in the payload; the reply data packet specifically includes the second identification address in the payload. The first network address and the second network address are IP addresses, and the first identification address and the second identification address are identification IP addresses.

本实施例的数据包的传输装置,在应用层UE发送初始数据包的时候在负载中携带本终端I-IP,而在Dest地址中填写目标终端的I-IP,利用网络侧的网关进行IP映射为目标终端的IP地址,目标终端则可以根据初始数据包得到源终端的IP地址。目标终端利用回复数据包中告知源终端目标终端的IP地址,这样终端在发送数据包的时候无需知道对端终端的IP地址,同样解决UE初始IP变化的问题,不需要应用服务器或其它设备在UE之间先交换IP地址再通信,处理方法简单。而且UE不需要具有IP隧道功能、不增加IP包大小。The device for transmitting data packets in this embodiment carries the I-IP of the terminal in the payload when the UE at the application layer sends the initial data packet, and fills in the I-IP of the target terminal in the Dest address, and uses the gateway on the network side to carry out IP Mapped to the IP address of the target terminal, the target terminal can obtain the IP address of the source terminal according to the initial data packet. The target terminal informs the source terminal of the IP address of the target terminal in the reply data packet, so that the terminal does not need to know the IP address of the peer terminal when sending the data packet, and also solves the problem of the initial IP change of the UE, without the need for an application server or other devices to The UEs exchange IP addresses before communicating, and the processing method is simple. Moreover, the UE does not need to have an IP tunnel function, and does not increase the size of the IP packet.

专业人员应该还可以进一步意识到,结合本文中所公开的实施例描述的各示例的单元及算法步骤,能够以电子硬件、计算机软件或者二者的结合来实现,为了清楚地说明硬件和软件的可互换性,在上述说明中已经按照功能一般性地描述了各示例的组成及步骤。这些功能究竟以硬件还是软件方式来执行,取决于技术方案的特定应用和设计约束条件。专业技术人员可以对每个特定的应用来使用不同方法来实现所描述的功能,但是这种实现不应认为超出本发明的范围。Professionals should further realize that the units and algorithm steps described in conjunction with the embodiments disclosed herein can be implemented by electronic hardware, computer software, or a combination of the two. In order to clearly illustrate the relationship between hardware and software Interchangeability. In the above description, the composition and steps of each example have been generally described according to their functions. Whether these functions are executed by hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art may use different methods to implement the described functions for each specific application, but such implementation should not be regarded as exceeding the scope of the present invention.

结合本文中所公开的实施例描述的方法或算法的步骤可以用硬件、处理器执行的软件模块,或者二者的结合来实施。软件模块可以置于随机存储器(RAM)、内存、只读存储器(ROM)、电可编程ROM、电可擦除可编程ROM、寄存器、硬盘、可移动磁盘、CD-ROM、或技术领域内所公知的任意其它形式的存储介质中。The steps of the methods or algorithms described in connection with the embodiments disclosed herein may be implemented by hardware, software modules executed by a processor, or a combination of both. Software modules can be placed in random access memory (RAM), internal memory, read-only memory (ROM), electrically programmable ROM, electrically erasable programmable ROM, registers, hard disk, removable disk, CD-ROM, or any other Any other known storage medium.

以上所述的具体实施方式,对本发明的目的、技术方案和有益效果进行了进一步详细说明,所应理解的是,以上所述仅为本发明的具体实施方式而已,并不用于限定本发明的保护范围,凡在本发明的精神和原则之内,所做的任何修改、等同替换、改进等,均应包含在本发明的保护范围之内。The specific embodiments described above have further described the purpose, technical solutions and beneficial effects of the present invention in detail. It should be understood that the above descriptions are only specific embodiments of the present invention and are not intended to limit the scope of the present invention. Protection scope, within the spirit and principles of the present invention, any modification, equivalent replacement, improvement, etc., shall be included in the protection scope of the present invention.

Claims (28)

1.一种数据包的传输方法,其特征在于,所述方法包括:1. A transmission method of data packet, is characterized in that, described method comprises: 第一移动终端设置待向第二移动终端发送的初始数据包,所述初始数据包中的第一源地址为所述第一移动终端所对应的第一标识地址,第一目标地址为所述第二移动终端所对应的第二标识地址,所述标识地址对每个终端固定且唯一,且与网络分配的互联网协议IP地址格式完全独立;The first mobile terminal sets an initial data packet to be sent to the second mobile terminal, the first source address in the initial data packet is the first identification address corresponding to the first mobile terminal, and the first target address is the The second identification address corresponding to the second mobile terminal, the identification address is fixed and unique to each terminal, and is completely independent of the Internet protocol IP address format allocated by the network; 对所述初始数据包进行隧道封装得到第一封装数据包并发送,所述第一封装数据包中的第一封装源地址为所述第一移动终端的第一网络地址,第一封装目标地址为所述第二标识地址,以便网关将所述第二标识地址映射为所述第二移动终端的第二网络地址;Perform tunnel encapsulation on the initial data packet to obtain a first encapsulated data packet and send it, the first encapsulation source address in the first encapsulation data packet is the first network address of the first mobile terminal, and the first encapsulation target address being the second identification address, so that the gateway maps the second identification address to the second network address of the second mobile terminal; 所述初始数据包为IP数据包,所述第一网络地址和第二网络地址为IP地址,所述第一标识地址和第二标识地址为标识IP地址。The initial data packet is an IP data packet, the first network address and the second network address are IP addresses, and the first identification address and the second identification address are identification IP addresses. 2.根据权利要求1所述的方法,其特征在于,所述方法还包括:2. The method according to claim 1, characterized in that the method further comprises: 所述第二移动终端接收所述第一封装数据包;The second mobile terminal receives the first encapsulated data packet; 对所述第一封装数据包进行隧道解封装,得到所述第一网络地址。performing tunnel decapsulation on the first encapsulated data packet to obtain the first network address. 3.根据权利要求2所述的方法,其特征在于,所述方法还包括:3. The method according to claim 2, wherein the method further comprises: 所述第二移动终端设置待向所述第一移动终端发送的回复数据包,所述回复数据包中的第二源地址为所述第二标识地址,第二目标地址为所述第一标识地址;The second mobile terminal sets a reply data packet to be sent to the first mobile terminal, the second source address in the reply data packet is the second identification address, and the second target address is the first identification address; 对所述回复数据包进行隧道封装得到第二封装数据包并发送,所述第二封装数据包中的第二封装源地址为所述第二网络地址,第二封装目标地址为所述第一网络地址,以便所述网关根据所述第一网络地址将所述第二封装数据包发送给所述第一移动终端。performing tunnel encapsulation on the reply data packet to obtain a second encapsulated data packet and sending it, the second encapsulation source address in the second encapsulation data packet is the second network address, and the second encapsulation target address is the first network address, so that the gateway sends the second encapsulated data packet to the first mobile terminal according to the first network address. 4.根据权利要求3所述的方法,其特征在于,所述方法还包括:4. method according to claim 3, is characterized in that, described method also comprises: 所述第一移动终端接收所述第二封装数据包;The first mobile terminal receives the second encapsulated data packet; 对所述第二封装数据包进行隧道解封装,得到所述第二网络地址。performing tunnel decapsulation on the second encapsulated data packet to obtain the second network address. 5.一种数据包的传输方法,其特征在于,所述方法包括:5. A transmission method of data packet, is characterized in that, described method comprises: 网关接收第一移动终端发送的第一封装数据包,所述第一封装数据包中的第一封装源地址为所述第一移动终端的第一网络地址,第一封装目标地址为第二移动终端所对应的第二标识地址,所述标识地址对每个终端固定且唯一,且与网络分配的互联网协议IP地址格式完全独立;The gateway receives the first encapsulated data packet sent by the first mobile terminal, the first encapsulated source address in the first encapsulated data packet is the first network address of the first mobile terminal, and the first encapsulated target address is the second mobile The second identification address corresponding to the terminal, the identification address is fixed and unique to each terminal, and is completely independent from the Internet Protocol IP address format allocated by the network; 所述网关将所述第二标识地址映射为所述第二移动终端的第二网络地址;The gateway maps the second identification address to a second network address of the second mobile terminal; 所述网关根据所述第二网络地址将所述第一封装数据包发送到所述第二移动终端,以便所述第二移动终端将所述第一封装数据包解封装得到所述第一网络地址;The gateway sends the first encapsulated data packet to the second mobile terminal according to the second network address, so that the second mobile terminal decapsulates the first encapsulated data packet to obtain the first network address address; 所述第一网络地址和第二网络地址为IP地址,所述第一标识地址和第二标识地址为标识IP地址。The first network address and the second network address are IP addresses, and the first identification address and the second identification address are identification IP addresses. 6.根据权利要求5所述的数据包的传输方法,其特征在于,所述方法还包括:6. The transmission method of data packet according to claim 5, is characterized in that, described method also comprises: 所述网关接收所述第二移动终端发送的第二封装数据包,所述第二封装数据包中的第二封装源地址为所述第二移动终端的第二网络地址,第二封装目标地址为所述第一网络地址;The gateway receives the second encapsulated data packet sent by the second mobile terminal, the second encapsulated source address in the second encapsulated data packet is the second network address of the second mobile terminal, and the second encapsulated target address is the first network address; 根据所述第一网络地址将所述第二封装数据包发送到所述第一移动终端,以便所述第一移动终端将所述第二封装数据包解封装得到所述第二网络地址。sending the second encapsulated data packet to the first mobile terminal according to the first network address, so that the first mobile terminal decapsulates the second encapsulated data packet to obtain the second network address. 7.一种数据包的传输方法,其特征在于,所述方法包括:7. A method for transmitting data packets, characterized in that the method comprises: 第一移动终端设置待向第二移动终端发送的初始数据包,所述初始数据包中包括所述第一移动终端的第一标识地址;并且所述初始数据包中的第一源地址为所述第一移动终端的第一网络地址,第一目标地址为所述第二移动终端所对应的第二标识地址,所述标识地址对每个终端固定且唯一,且与网络分配的互联网协议IP地址格式完全独立;The first mobile terminal sets an initial data packet to be sent to the second mobile terminal, the initial data packet includes the first identification address of the first mobile terminal; and the first source address in the initial data packet is the The first network address of the first mobile terminal, the first target address is the second identification address corresponding to the second mobile terminal, the identification address is fixed and unique to each terminal, and is consistent with the Internet Protocol IP address assigned by the network The address format is completely independent; 向第二移动终端发送初始数据包,以便网关将所述初始数据包的第二标识地址映射为所述第二移动终端的第二网络地址;sending an initial data packet to the second mobile terminal, so that the gateway maps the second identification address of the initial data packet to the second network address of the second mobile terminal; 所述第一网络地址和第二网络地址为IP地址,所述第一标识地址和第二标识地址为标识IP地址。The first network address and the second network address are IP addresses, and the first identification address and the second identification address are identification IP addresses. 8.根据权利要求7所述的数据包的传输方法,其特征在于,所述方法还包括:8. The transmission method of data packet according to claim 7, is characterized in that, described method also comprises: 所述第二移动终端接收所述初始数据包;The second mobile terminal receives the initial data packet; 从所述初始数据包中得到所述第一网络地址。The first network address is obtained from the initial data packet. 9.根据权利要求8所述的方法,其特征在于,所述方法还包括:9. The method of claim 8, further comprising: 所述第二移动终端设置待向所述第一移动终端发送的回复数据包,所述回复数据包中包括所述第二移动终端所对应的第二标识地址;所述回复数据包中的第二源地址为所述第二网络地址,第二目标地址为所述第一网络地址;The second mobile terminal sets a reply data packet to be sent to the first mobile terminal, and the reply data packet includes a second identification address corresponding to the second mobile terminal; the second identification address in the reply data packet The second source address is the second network address, and the second destination address is the first network address; 向所述第一移动终端发送回复数据包,以便所述网关根据所述第一网络地址将所述回复数据包发送给所述第一移动终端。sending a reply data packet to the first mobile terminal, so that the gateway sends the reply data packet to the first mobile terminal according to the first network address. 10.根据权利要求9所述的方法,其特征在于,所述方法还包括:10. The method according to claim 9, further comprising: 所述第一移动终端接收所述回复数据包,得到所述第二网络地址。The first mobile terminal receives the reply data packet to obtain the second network address. 11.根据权利要求9或10所述的数据包的传输方法,其特征在于,所述初始数据包具体在负载中包括所述第一标识地址;所述回复数据包具体在负载中包括所述第二标识地址。11. The transmission method of the data packet according to claim 9 or 10, wherein the initial data packet specifically includes the first identification address in the load; the reply data packet specifically includes the first identification address in the load; The second identification address. 12.一种数据包的传输方法,其特征在于,所述方法包括:12. A method for transmitting data packets, characterized in that the method comprises: 网关接收第一移动终端发送的初始数据包,所述初始数据包中包括所述第一移动终端的第一标识地址;并且所述初始数据包中的第一源地址为所述第一移动终端的第一网络地址,第一目标地址为所述第二移动终端所对应的第二标识地址,所述标识地址对每个终端固定且唯一,且与网络分配的互联网协议IP地址格式完全独立;The gateway receives the initial data packet sent by the first mobile terminal, the initial data packet includes the first identification address of the first mobile terminal; and the first source address in the initial data packet is the first mobile terminal The first network address, the first target address is the second identification address corresponding to the second mobile terminal, the identification address is fixed and unique to each terminal, and is completely independent of the Internet Protocol IP address format assigned by the network; 所述网关将所述第二标识地址映射为所述第二移动终端的第二网络地址;The gateway maps the second identification address to a second network address of the second mobile terminal; 所述网关根据所述第二网络地址将所述初始数据包发送到所述第二移动终端,以便所述第二移动终端从所述初始数据包中得到所述第一网络地址;The gateway sends the initial data packet to the second mobile terminal according to the second network address, so that the second mobile terminal obtains the first network address from the initial data packet; 所述第一网络地址和第二网络地址为IP地址,所述第一标识地址和第二标识地址为标识IP地址。The first network address and the second network address are IP addresses, and the first identification address and the second identification address are identification IP addresses. 13.根据权利要求12所述的数据包的传输方法,其特征在于,所述方法还包括:13. The transmission method of the data packet according to claim 12, characterized in that, the method further comprises: 所述网关接收所述第二移动终端发送的回复数据包,所述回复数据包中包括所述第二移动终端所对应的第二标识地址;所述回复数据包中的第二源地址为所述第二网络地址,第二目标地址为所述第一网络地址;The gateway receives the reply data packet sent by the second mobile terminal, the reply data packet includes the second identification address corresponding to the second mobile terminal; the second source address in the reply data packet is the The second network address, the second target address is the first network address; 根据所述第一网络地址将所述回复数据包发送给所述第一移动终端,以便所述第一移动终端从所述回复数据包中得到所述第二网络地址。sending the reply data packet to the first mobile terminal according to the first network address, so that the first mobile terminal obtains the second network address from the reply data packet. 14.根据权利要求13所述的数据包的传输方法,其特征在于,所述初始数据包具体在负载中包括所述第一标识地址;所述回复数据包具体在负载中包括所述第二标识地址。14. The method for transmitting a data packet according to claim 13, wherein the initial data packet specifically includes the first identification address in the payload; the reply packet specifically includes the second identification address in the payload. Identify the address. 15.一种数据包的传输装置,其特征在于,所述装置包括:设置单元和封装单元;15. A data packet transmission device, characterized in that the device comprises: a setting unit and an encapsulation unit; 设置单元,用于第一移动终端设置待向第二移动终端发送的初始数据包,所述初始数据包中的第一源地址为所述第一移动终端所对应的第一标识地址,第一目标地址为所述第二移动终端所对应的第二标识地址,所述标识地址对每个终端固定且唯一,且与网络分配的互联网协议IP地址格式完全独立;The setting unit is used for the first mobile terminal to set an initial data packet to be sent to the second mobile terminal, the first source address in the initial data packet is the first identification address corresponding to the first mobile terminal, and the first The target address is the second identification address corresponding to the second mobile terminal, the identification address is fixed and unique to each terminal, and is completely independent from the Internet Protocol IP address format allocated by the network; 封装单元,用于对所述初始数据包进行隧道封装得到第一封装数据包并发送,所述第一封装数据包中的第一封装源地址为所述第一移动终端的第一网络地址,第一封装目标地址为所述第二标识地址,以便网关将所述第二标识地址映射为所述第二移动终端的第二网络地址;An encapsulation unit, configured to perform tunnel encapsulation on the initial data packet to obtain a first encapsulated data packet and send it, the first encapsulation source address in the first encapsulated data packet is the first network address of the first mobile terminal, The first encapsulation target address is the second identification address, so that the gateway maps the second identification address to the second network address of the second mobile terminal; 所述初始数据包为IP数据包,所述第一网络地址和第二网络地址为IP地址,所述第一标识地址和第二标识地址为标识IP地址。The initial data packet is an IP data packet, the first network address and the second network address are IP addresses, and the first identification address and the second identification address are identification IP addresses. 16.根据权利要求15所述的装置,其特征在于,所述装置还包括:16. The device according to claim 15, further comprising: 接收单元,用于所述第二移动终端接收所述第一封装数据包;a receiving unit, configured for the second mobile terminal to receive the first encapsulated data packet; 解封装单元,用于对所述第一封装数据包进行隧道解封装,得到所述第一网络地址。The decapsulation unit is configured to tunnel decapsulate the first encapsulated data packet to obtain the first network address. 17.根据权利要求16所述的装置,其特征在于:17. The device of claim 16, wherein: 所述设置单元还用于所述第二移动终端设置待向所述第一移动终端发送的回复数据包,所述回复数据包中的第二源地址为所述第二标识地址,第二目标地址为所述第一标识地址;The setting unit is also used for the second mobile terminal to set a reply data packet to be sent to the first mobile terminal, the second source address in the reply data packet is the second identification address, and the second target The address is the first identification address; 所述封装单元还用于对所述回复数据包进行隧道封装得到第二封装数据包并发送,所述第二封装数据包中的第二封装源地址为所述第二网络地址,第二封装目标地址为所述第一网络地址,以便所述网关根据所述第一网络地址将所述第二封装数据包发送给所述第一移动终端。The encapsulation unit is further configured to perform tunnel encapsulation on the reply data packet to obtain a second encapsulated data packet and send it, the second encapsulated source address in the second encapsulated data packet is the second network address, and the second encapsulated The target address is the first network address, so that the gateway sends the second encapsulated data packet to the first mobile terminal according to the first network address. 18.根据权利要求17所述的装置,其特征在于:18. The device of claim 17, wherein: 所述接收单元还用于所述第一移动终端接收所述第二封装数据包;The receiving unit is also used for the first mobile terminal to receive the second encapsulated data packet; 所述解封装单元还用于对所述第二封装数据包进行隧道解封装,得到所述第二网络地址。The decapsulating unit is further configured to tunnel decapsulate the second encapsulated data packet to obtain the second network address. 19.一种数据包的传输装置,其特征在于,所述装置包括:接收单元、映射单元和发送单元;19. A data packet transmission device, characterized in that the device comprises: a receiving unit, a mapping unit and a sending unit; 接收单元,用于网关接收第一移动终端发送的第一封装数据包,所述第一封装数据包中的第一封装源地址为所述第一移动终端的第一网络地址,第一封装目标地址为第二移动终端所对应的第二标识地址,所述标识地址对每个终端固定且唯一,且与网络分配的互联网协议IP地址格式完全独立;The receiving unit is used for the gateway to receive the first encapsulated data packet sent by the first mobile terminal, the first encapsulated source address in the first encapsulated data packet is the first network address of the first mobile terminal, and the first encapsulated target The address is a second identification address corresponding to the second mobile terminal, the identification address is fixed and unique to each terminal, and is completely independent of the Internet Protocol IP address format allocated by the network; 映射单元,用于所述网关将所述第二标识地址映射为所述第二移动终端的第二网络地址;a mapping unit, configured for the gateway to map the second identification address to a second network address of the second mobile terminal; 发送单元,用于所述网关根据所述第二网络地址将所述第一封装数据包发送到所述第二移动终端,以便所述第二移动终端将所述第一封装数据包解封装得到所述第一网络地址;a sending unit, configured for the gateway to send the first encapsulated data packet to the second mobile terminal according to the second network address, so that the second mobile terminal decapsulates the first encapsulated data packet to obtain said first network address; 所述第一网络地址和第二网络地址为IP地址,所述第一标识地址和第二标识地址为标识IP地址。The first network address and the second network address are IP addresses, and the first identification address and the second identification address are identification IP addresses. 20.根据权利要求19所述的数据包的传输装置,其特征在于:20. The device for transmitting data packets according to claim 19, characterized in that: 所述接收单元还用于所述网关接收所述第二移动终端发送的第二封装数据包,所述第二封装数据包中的第二封装源地址为所述第二移动终端的第二网络地址,第二封装目标地址为所述第一网络地址;The receiving unit is also used for the gateway to receive the second encapsulated data packet sent by the second mobile terminal, and the second encapsulated source address in the second encapsulated data packet is the second network of the second mobile terminal address, where the second encapsulation target address is the first network address; 所述发送单元还用于根据所述第一网络地址将所述第二封装数据包发送到所述第一移动终端,以便所述第一移动终端将所述第二封装数据包解封装得到所述第二网络地址。The sending unit is further configured to send the second encapsulated data packet to the first mobile terminal according to the first network address, so that the first mobile terminal decapsulates the second encapsulated data packet to obtain the the second network address. 21.一种数据包的传输装置,其特征在于,所述装置包括设置单元和发送单元:21. A data packet transmission device, characterized in that the device comprises a setting unit and a sending unit: 设置单元,用于第一移动终端设置待向第二移动终端发送的初始数据包,所述初始数据包中包括所述第一移动终端的第一标识地址;并且所述初始数据包中的第一源地址为所述第一移动终端所的第一网络地址,第一目标地址为所述第二移动终端所对应的第二标识地址,所述标识地址对每个终端固定且唯一,且与网络分配的互联网协议IP地址格式完全独立;The setting unit is used for the first mobile terminal to set an initial data packet to be sent to the second mobile terminal, the initial data packet includes the first identification address of the first mobile terminal; and the first data packet in the initial data packet A source address is the first network address of the first mobile terminal, the first target address is the second identification address corresponding to the second mobile terminal, the identification address is fixed and unique to each terminal, and is the same as The Internet Protocol IP address format assigned by the network is completely independent; 发送单元,用于向所述第二移动终端发送初始数据包,以便网关将所述初始数据包中的所述第二标识地址映射为所述第二移动终端的第二网络地址;a sending unit, configured to send an initial data packet to the second mobile terminal, so that the gateway maps the second identification address in the initial data packet to a second network address of the second mobile terminal; 所述第一网络地址和第二网络地址为IP地址,所述第一标识地址和第二标识地址为标识IP地址。The first network address and the second network address are IP addresses, and the first identification address and the second identification address are identification IP addresses. 22.根据权利要求21所述的数据包的传输装置,其特征在于,所述装置还包括:22. The device for transmitting data packets according to claim 21, wherein the device further comprises: 接收单元,用于所述第二移动终端接收所述初始数据包;a receiving unit, configured for the second mobile terminal to receive the initial data packet; 获取单元,用于从所述初始数据包中得到所述第一网络地址。An obtaining unit, configured to obtain the first network address from the initial data packet. 23.根据权利要求22所述的装置,其特征在于:23. The device of claim 22, wherein: 所述设置单元还用于所述第二移动终端设置待向所述第一移动终端发送的回复数据包,所述回复数据包中包括所述第二移动终端所对应的第二标识地址;所述回复数据包中的第二源地址为所述第二网络地址,第二目标地址为所述第一网络地址;The setting unit is also used for the second mobile terminal to set a reply data packet to be sent to the first mobile terminal, and the reply data packet includes a second identification address corresponding to the second mobile terminal; The second source address in the reply data packet is the second network address, and the second target address is the first network address; 所述发送单元还用于向所述第一移动终端发送回复数据包,以便所述网关根据所述第一网络地址将所述回复数据包发送给所述第一移动终端。The sending unit is further configured to send a reply data packet to the first mobile terminal, so that the gateway sends the reply data packet to the first mobile terminal according to the first network address. 24.根据权利要求23所述的装置,其特征在于:所述接收单元还用于所述第一移动终端接收所述回复数据包,得到所述第二网络地址。24. The device according to claim 23, wherein the receiving unit is further configured for the first mobile terminal to receive the reply data packet to obtain the second network address. 25.根据权利要求23或24所述的数据包的传输装置,其特征在于,所述初始数据包具体在负载中包括所述第一标识地址;所述回复数据包具体在负载中包括所述第二标识地址。25. The device for transmitting data packets according to claim 23 or 24, wherein the initial data packet specifically includes the first identification address in the load; the reply data packet specifically includes the first identification address in the load; The second identification address. 26.一种数据包的传输装置,其特征在于,所述装置包括:接收单元、映射单元和发送单元;26. A data packet transmission device, characterized in that the device comprises: a receiving unit, a mapping unit and a sending unit; 接收单元,用于网关接收第一移动终端发送的初始数据包,所述初始数据包中包括所述第一移动终端的第一标识地址;并且所述初始数据包中的第一源地址为所述第一移动终端的第一网络地址,第一目标地址为所述第二移动终端所对应的第二标识地址,所述标识地址对每个终端固定且唯一,且与网络分配的互联网协议IP地址格式完全独立;The receiving unit is used for the gateway to receive the initial data packet sent by the first mobile terminal, the initial data packet includes the first identification address of the first mobile terminal; and the first source address in the initial data packet is the The first network address of the first mobile terminal, the first target address is the second identification address corresponding to the second mobile terminal, the identification address is fixed and unique to each terminal, and is consistent with the Internet Protocol IP address assigned by the network The address format is completely independent; 映射单元,用于所述网关将所述第二标识地址映射为所述第二移动终端的第二网络地址;a mapping unit, configured for the gateway to map the second identification address to a second network address of the second mobile terminal; 发送单元,用于所述网关根据所述第二网络地址将所述初始数据包发送到所述第二移动终端,以便所述第二移动终端从所述初始数据包中得到所述第一网络地址;a sending unit, configured for the gateway to send the initial data packet to the second mobile terminal according to the second network address, so that the second mobile terminal obtains the first network address from the initial data packet address; 所述第一网络地址和第二网络地址为IP地址,所述第一标识地址和第二标识地址为标识IP地址。The first network address and the second network address are IP addresses, and the first identification address and the second identification address are identification IP addresses. 27.根据权利要求26所述的数据包的传输装置,其特征在于:27. The device for transmitting data packets according to claim 26, characterized in that: 所述接收单元还用于所述网关接收所述第二移动终端发送的回复数据包,所述回复数据包中包括所述第二移动终端所对应的第二标识地址;所述回复数据包中的第二源地址为所述第二网络地址,第二目标地址为所述第一网络地址;The receiving unit is also used for the gateway to receive the reply data packet sent by the second mobile terminal, the reply data packet includes the second identification address corresponding to the second mobile terminal; the reply data packet The second source address is the second network address, and the second destination address is the first network address; 所述发送单元还用于根据所述第一网络地址将所述回复数据包发送给所述第一移动终端,以便所述第一移动终端从所述回复数据包中得到所述第二网络地址。The sending unit is further configured to send the reply data packet to the first mobile terminal according to the first network address, so that the first mobile terminal obtains the second network address from the reply data packet . 28.根据权利要求27所述的数据包的传输装置,其特征在于,所述初始数据包具体在负载中包括所述第一标识地址;所述回复数据包具体在负载中包括所述第二标识地址。28. The data packet transmission device according to claim 27, characterized in that, the initial data packet specifically includes the first identification address in the load; the reply data packet specifically includes the second identification address in the load. Identify the address.
CN201210444003.5A 2012-11-08 2012-11-08 The transmission method of packet and device Active CN102932467B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201210444003.5A CN102932467B (en) 2012-11-08 2012-11-08 The transmission method of packet and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201210444003.5A CN102932467B (en) 2012-11-08 2012-11-08 The transmission method of packet and device

Publications (2)

Publication Number Publication Date
CN102932467A CN102932467A (en) 2013-02-13
CN102932467B true CN102932467B (en) 2015-11-25

Family

ID=47647163

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201210444003.5A Active CN102932467B (en) 2012-11-08 2012-11-08 The transmission method of packet and device

Country Status (1)

Country Link
CN (1) CN102932467B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108737557A (en) * 2018-05-29 2018-11-02 Oppo(重庆)智能科技有限公司 A kind of data pack transmission method, terminal and computer storage media
CN113163028B (en) * 2021-04-29 2023-01-24 全球能源互联网研究院有限公司 Service data transmission method, device and system

Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102377629A (en) * 2010-08-20 2012-03-14 成都市华为赛门铁克科技有限公司 Method and device for communicating with server in IMS (IP multimedia subsystem) core network by using terminal to pass through private network as well as network system

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8769156B2 (en) * 2009-12-23 2014-07-01 Citrix Systems, Inc. Systems and methods for maintaining transparent end to end cache redirection

Patent Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102377629A (en) * 2010-08-20 2012-03-14 成都市华为赛门铁克科技有限公司 Method and device for communicating with server in IMS (IP multimedia subsystem) core network by using terminal to pass through private network as well as network system

Also Published As

Publication number Publication date
CN102932467A (en) 2013-02-13

Similar Documents

Publication Publication Date Title
US11838203B2 (en) Multipath data transmission method and device
US9622072B2 (en) Communication method, method for forwarding data message during the communication process and communication node thereof
TWI531190B (en) Mtc device bandwidth reduction
JP6009630B2 (en) Simultaneous packet data network (PDN) access
CN102006337B (en) CGN (Carrier Grade NAT) entity based data transmission method, CGN entity, gateway and system
US20120082110A1 (en) Method and terminal for transmitting service data
CN104521220B (en) Message processing method and equipment
CN111031078A (en) Communication method and device
WO2021027858A1 (en) Method and device for determining rlc channel
CN101257517B (en) Method and device for processing address analysis protocol request message
CN103609050A (en) Air interface transmission method and relevant device and system
US20240356893A1 (en) Generating or providing ipv6 addresses
CN102932467B (en) The transmission method of packet and device
WO2018045521A1 (en) Method and device for transmitting signaling in wireless network
CN104284383B (en) A kind of method and apparatus for keeping business continuance
CN116527792B (en) Method, apparatus, device, readable storage medium and program product for identifying message
WO2015096734A1 (en) Downlink transmission method for service data, and packet data gateway
WO2014169590A1 (en) Data service communication method, device, and system
EP3331264A1 (en) Packet forwarding to subnets hosted by lte cellular equipments
US20170078942A1 (en) Method and network node for routing ip packets
EP2568715A1 (en) Mobile node, care of address acquisition method and system thereof, and dhcp server
US20250080490A1 (en) Method of NAT64 Translation
CN103369592B (en) Message transmitting method in packet domain and relevant device
EP4315743A1 (en) Encapsulating an sctp packet in a udp packet
CN106792933A (en) A kind of link establishing method, base station, gateway and system

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant
TR01 Transfer of patent right
TR01 Transfer of patent right

Effective date of registration: 20211223

Address after: 450046 Floor 9, building 1, Zhengshang Boya Plaza, Longzihu wisdom Island, Zhengdong New Area, Zhengzhou City, Henan Province

Patentee after: xFusion Digital Technologies Co., Ltd.

Address before: 518129 Bantian HUAWEI headquarters office building, Longgang District, Guangdong, Shenzhen

Patentee before: HUAWEI TECHNOLOGIES Co.,Ltd.