Summary of the invention
The technical problem to be solved in the present invention is to provide a kind of data encapsulation method and system, under identify label and position separation, solves the out of order and packet loss problem of message in transmitting procedure or in user's moving process.
In order to address the above problem, the invention provides a kind of data encapsulation method, comprising:
When routing node receives source terminal and mails to the message of object terminal, in described message, increase by an encapsulated layer, and in described encapsulated layer, encapsulate sequence information and source routing station location marker RID and target RID and source user sign AID and target AID that described terminal sends described message;
When the routing node at described object terminal place receives described message, carry out decapsulation processing, and after the message receiving being sorted according to described sequence information, send to described object terminal.
Further, in described encapsulated layer, comprise a flag field, for whether identifying described message with sequence information.
Further, the routing node at described source terminal place adopts the mode of User Datagram Protoco (UDP) (UDP) to carry out data encapsulation to described message.
Further, in described encapsulated layer, also comprise a kind of or its combination in any in following field:
Message type field, is packet or signaling bag for identifying described message, if signaling bag, also for identifying the type of signaling; Version number field, for identifying the version number of described data encapsulation form; Reserved field.
Another technical problem to be solved by this invention is to provide a kind of data encapsulation method, is applied to identify label and position separation, comprising:
When source access support node (ASN) or Interworking gateway node (ISN) receive source terminal and mail to the message of the object terminal that is positioned at described framework, in described message, increase by an encapsulated layer, in described encapsulated layer, comprise sequence information and source routing station location marker RID and target RID and source user sign AID and target AID that described terminal sends described message;
When the object ASN at described object terminal place receives described message, carry out decapsulation processing, and after the message receiving being sorted according to described sequence information, send to described object terminal.
Further, described source ASN or ISN inquire about corresponding route station location marker (RID) according to the object AID in the described data message receiving, and the object RID inquiring is encapsulated in described data message, are forwarded to backbone network;
Described backbone network according to described object RID by described data message forwarding to described object ASN.
Further, described source ASN or ISN are when the RID of the described correspondence of inquiry, and first the local identity station location marker map information of whether preserving described object AID of inquiry, in the situation that not preserving, inquires about the map information of described AID and RID to mapping plane,
Further, described message comprises packet or signaling bag, and described package module packet and signaling bag adopt unified form.
Further, in described encapsulated layer, comprise a kind of or its combination in any in following field:
Whether flag field, for identifying described message with sequence information;
Message type field, is packet or signaling bag for identifying described message, if signaling bag, also for identifying the type of signaling; Version number field, for identifying the version number of described data encapsulation form; Reserved field.
Further, described message adopts the IP bag of standard; Described source ASN adopts the mode of UDP to carry out data encapsulation to described message.
The present invention also provides a kind of data encapsulation system, comprising: routing node and terminal, and described routing node further comprises package module, decapsulation module and forwarding module, wherein,
Described package module is used for, when receiving the message that source terminal sends, in described message, increase by an encapsulated layer, and in described encapsulated layer, encapsulate described terminal and send after the sequence information of described message and source routing station location marker RID and target RID and source user sign AID and target AID, send to described forwarding module;
Described decapsulation module is used for, and while receiving the described message that mails to object terminal, carries out, after decapsulation processing, sending to described forwarding module;
Described forwarding module is used for, and when receiving the data message of described package module transmission, is transmitted to the decapsulation module of object routing node; And, when receiving the data message of described decapsulation module transmission, after the message receiving being sorted according to described sequence information, send to described object terminal.
Further, described package module also for, in described encapsulated layer, encapsulate a flag field, for whether identifying described message with sequence information.
Further, described package module adopts the mode of UDP to carry out data encapsulation to described message.
Further, described package module also for, in described encapsulated layer, encapsulate a kind of or its combination in any in following field:
Message type field, is packet or signaling bag for identifying described message, if signaling bag, also for identifying the type of signaling; Version number field, for identifying the version number of described data encapsulation form; Reserved field.
The present invention also provides a kind of data encapsulation system, is applied to identify label and position separation, comprises ASN, ISN and terminal, and wherein said ASN further comprises package module, decapsulation module and forwarding module, wherein:
Described package module is used for, when receiving source terminal and mailing to the message of the object terminal that is positioned at described framework, in described message, increase by an encapsulated layer, in described encapsulated layer, comprise sequence information and source routing station location marker RID and target RID and source user sign AID and target AID that described terminal sends described message;
Described decapsulation module is used for, and while receiving the described message that mails to object terminal, carries out, after decapsulation processing, sending to described forwarding module;
Described forwarding module is used for, and when receiving the data message of described package module transmission, is transmitted to the decapsulation module of object ASN; And, when receiving the data message of described decapsulation module transmission, after the message receiving being sorted according to described sequence information, send to described object terminal.
Further, package module is used for, and according to the object AID in the data message receiving, inquires about corresponding RID, and the object RID inquiring is encapsulated in described data message, is forwarded to backbone network;
Described backbone network according to described object RID by described data message forwarding to described object ASN.
Further, described package module is used for, when the RID of the described correspondence of inquiry, first whether inquiry this locality preserves the identity station location marker map information of described object AID, in the situation that not preserving, to mapping plane, inquire about the map information of described AID and RID
Further, described package module is used for, and to the message of packet or signaling bag type, adopts unified form to encapsulate.
Further, described package module also for, in described encapsulated layer, encapsulate a kind of or its combination in any in following field:
Whether flag field, for identifying described message with sequence information;
Message type field, is packet or signaling bag for identifying described message, if signaling bag, also for identifying the type of signaling;
Version number field, for identifying the version number of described data encapsulation form;
Reserved field.
Further, described package module adopts the mode of UDP to carry out data encapsulation to described message.
Adopt above-mentioned data encapsulation form, at least there is following beneficial effect:
1, in encapsulation header, be with sequence number information, in reception, ASN can judge on transmission path, whether there is out of order or packet loss according to sequence number information; If occurred out of orderly, carry out out of order processing receiving the characteristic that ASN side can increase progressively according to sequence number, improved transmission quality;
2, in encapsulation header with type of message, can distinguishing signaling and data, be convenient to the exchange of non-data message between ASN;
3, in encapsulation header with version number, when agreement has upgrading afterwards, can be according to version number, guarantee to communicate by letter mutually between the ASN of diversity of protocol versions;
4, in encapsulation header with attribute field S, only having this S is 1, just represents that the sequence number in packet header is significant, if under the good scene of transmission quality, tape serial number not, at this moment S position is 0;
5, in encapsulation header with reserved field, the expansion to agreement after being convenient to.This field can be for different data content in sign encapsulation of data;
6, encapsulation after packet can the enterprising walking along the street of IP backbone network by, the router on existing backbone network does not need to make any modification.
Embodiment
Below in conjunction with drawings and Examples, the present invention will be described in more detail.
In order to overcome the deficiencies in the prior art, the present embodiment has proposed a kind of network identify label and position separation, its core concept is: network is divided into Access Network and backbone network, for the unique User Identity of each user assignment in network, it is constant that this User Identity remains in moving process; In network, there are two kinds of sign types: User Identity (Access Identifier is called for short AID) and route station location marker (Routing-Location Identifier is called for short RID).Wherein AID is the unique identify label for each user assignment in network, can only use at Access Layer, and in the moving process of user terminal, remain constant, between user terminal, use AID sign opposite end, between user terminal, only need to use the AID of opposite end to communicate; RID is the route station location marker distributing for user terminal, can only use at backbone network.
The present embodiment based on identify label and the concrete network topology of position separation as shown in Figure 1, wherein the logic function of each network element is as follows:
1. access support node (Access Support Node is called for short ASN)
Access support node is responsible for various mobile terminals access service is provided, and is user assignment AID and the RID of access, and the data message that terminal is sent identify after encapsulating and transmits in core net.
2. shine upon plane
Mapping plane is mainly responsible for safeguarding the mapping relations (being RID-AID mapping relations) of User Identity and route station location marker in identify label and locator separation network, and provides inquiry service to ASN and other mapping server.Mapping plane is by a plurality of identity location registers (Identity Location Register, be called for short ILR) form, ASN query communication to end position process in, if ASN this locality does not have the route positional information of Correspondent Node, just by mapping plane go to search.
3. authentication center
Authentication center is responsible for the information such as recording user classification, user's grade of service, when user accesses, user is carried out to legitimacy authentication and authorization.Bi-directional authentification between authentication center's network enabled and user.
4.IP backbone network
IP backbone is the internet between ASN, and major function is to carry out routing and forwarding data packets according to the route station location marker in data message, and the data retransmission that ASN is sent is to correct destination; IP network is comprised of core switch router (Central Switch Router is called for short CSR).Be the same with existing IP network, do not need to carry out any modification.
5. Interworking gateway node (Interconnect Service Node, be called for short ISN)
ISN is identity locator separation network and other networks, the intercommunication node of Internet for example, and the network that two classes are different must be communicated by letter mutually by ISN.ISN encapsulation, route and forward this architecture network and traditional IP between the data message that comes and goes.
6. wireless network
Wireless network is responsible for providing also maintenance customer's terminal to the two layers of link (physical layer and link layer) between ASN, in cellular mobile network, to be responsible for the functions such as allocation of radio resources and management.Wireless network herein can be WCDMA (Wideband CDMA, Wideband Code Division Multiple Access (WCDMA)), TD-SCDMA (Time Division-Synchronous Code Division Multiple Access, TD SDMA), CDMA2000, the wireless networks such as LTE (Long Term Evolution, Long Term Evolution).
On ASN, be mobile terminal (the Mobile Node of each local access, abbreviation MN) preserve all Correspondent Nodes (Correspondent Node, abbreviation CN) information, when the position of mobile terminal changes, new ASN will notify the ASN to Correspondent Node place the sign of terminal location now, Correspondent Node has a plurality of time, needs notice to each CN, guarantees that each CN issues correct ASN packet.
In the present embodiment, provide a kind of based on the data encapsulation form between ASN and between ASN and ISN under above-mentioned identify label and position separation, data after encapsulation can marking terminal be sent the sequential of message, and the terminal that receives data can sort to data according to sign.
The data encapsulation method of the present embodiment is not limited to and is applied to above-mentioned framework, also goes for multiple other frameworks or communication network.
For example, in other embodiments of the invention, when routing node receives source terminal and mails to the message of object terminal, in message, increase by an encapsulated layer, and package terminals sends the sequence information of message in encapsulated layer; When the routing node at object terminal place receives described message, carry out decapsulation processing, and after the message receiving being sorted according to described sequence information, send to object terminal.
In addition, in this encapsulated layer, also comprise a kind of or its combination in any in following field:
Whether flag field, for identifying described message with sequence information;
Message type field, is packet or signaling bag for identifying described message, if signaling bag, also for identifying the type of signaling;
Version number field, for identifying the version number of described data encapsulation form;
Reserved field.
In the present embodiment, ASN and ISN when receiving the message that terminal sends, concrete process as follows:
Adopt UDP (User Datagram Protocol, User Datagram Protoco (UDP)) mode is carried out data encapsulation to message, in the message sending in terminal, add an encapsulated layer, at encapsulation header carried terminal, send the time sequence information of message, for example, for each, send terminal, in the message sending, comprise the sequence number increasing progressively, thereby receiving terminal can judge according to this sequence number the out of order and packet drop of message.
Concrete realization can adopt following encapsulation format:
IP head |
Source RID |
Target RID |
UDP head |
Encapsulated layer |
Source AID |
Target AID |
Packet/signaling bag |
In order to make full use of existing backbone network, in the present embodiment, between the packet between ASN and ASN and ISN, all adopt the IP bag of standard, guarantee that the packet after encapsulation can normally carry out route on IP backbone network.
Below in conjunction with two application examples, the embodiment of data encapsulation of the present invention is described in further detail.
Application example one
Terminal based in identify label and position separation network is when communicating, and the forwarding process of the data message between ASN is as follows:
Step 101: the packet that source ASN receiving terminal sends:
Data packet format is the IPV4 data packet format of standard, and source address and destination address are respectively source AID and object AID (being the AID of Correspondent Node);
Step 102: source ASN carries out data encapsulation;
Source ASN receives after packet, according to object AID wherein, inquire about the AID-RID mapping table in local cache: if do not find corresponding AID-RID map entry,, by query mappings plane, obtain the RID of Correspondent Node, it is encapsulated in to header as target RID; And increase an encapsulated layer, in this encapsulated layer, at least comprise the sequence number of Packet Generation.The object that wherein encapsulates RID is for carrying out routing forwarding;
In the present embodiment, the data packet format following (in this table, every row has 4 bytes) after source ASN encapsulation:
Wherein, the implication of each field is described as follows:
Standard I P head: i.e. IP packet header of traditional IP;
Source RID: the RID that refers to source ASN;
Target RID: the RID of the ASN of feeling the pulse with the finger-tip;
Source port, destination interface, UDP length, UDP verification: i.e. traditional UDP head;
Source AID: the source user sign that refers to send packet;
Target AID: finger is received targeted customer's sign of packet;
Type of message: for showing that this encapsulated message is data or signaling, if signaling can also be distinguished different signalings;
Version number (optional): account for 4 bits, refer to the version number of this data encapsulation form, expansion after being convenient to;
Res (optional): account for 3 bits, as reserved field, expansion after being convenient to;
S (optional): account for 1 bit, whether sign notebook data message tape serial number, if S is 1, explanation sequence-number field is below effectively, if S is 0, explanation sequence-number field is below invalid.
Sequence number: refer to that data sending terminal ASN is for each identical AID, in the packet sending with on the sequence number increasing progressively, at receiving terminal, can judge out of order and packet drop according to this sequence number.Sequence number accounts for 2 bytes.
After source ASN encapsulation, the source address of packet and destination address are the RID of source ASN and object ASN, format of user data and content in step 1 remain unchanged, data after encapsulation send to broad sense Forwarding plane, and broad sense Forwarding plane is forwarded to object ASN according to the Route Distinguisher RID of object ASN;
Step 103: object ASN receives packet bag and carries out decapsulation, and whole encapsulation header is all removed, and reverts to the data format before encapsulation, sends the data to the user of target AID sign; Meanwhile, the ASN that receives packet can be used sequence number in encapsulation header to the packet the receiving processing of sorting as required.For example, in the situation that terminal is moved, switch when just having completed, have partial data and from original ASN, be forwarded to new ASN and come, in this case, new ASN need to sort to these data according to sequence number.
Application example two
When the terminal access in traditional IP the present invention is based on the terminal in identify label and position separation network, the forwarding process of data message is as follows:
The packet that step 201:ISN receiving terminal sends, this data packet format is the packet of the IPV4 of standard;
Step 202, ISN encapsulates packet, and its encapsulation format is identical with step 102;
The AID that ISN is Correspondent Node according to destination address in data message inquires about the AID-RID mapping table in local cache: if find corresponding AID-RID map entry, the RID of CN is encapsulated in to header as destination address, is forwarded to broad sense Forwarding plane; If do not find corresponding AID-RID map entry, after data message being done to tunnel encapsulation, be forwarded to mapping forward plane, by mapping forward plane, find corresponding AID-RID map entry, the RID of CN is encapsulated in to header as destination address, be forwarded to broad sense Forwarding plane.
And, when ISN can not find out corresponding AID-RID map entry, can send to mapping forward plane the flow process of inquiry AID-RID mapping relations, return after AID-RID mapping relations receiving mapping forward plane, be saved in local cache.
Step 203, broad sense Forwarding plane sends to object ASN by data message, object ASN carries out decapsulation processing to the data message receiving, peel off the RID encapsulation of data message head, the source address destination address of the data message after decapsulation is converted to the IP address format of traditional Internet network support.
Above-mentioned example is to take packet data encapsulation process of the present invention to be described as example, applicable equally for signaling bag implementation step.
In addition, in example of the present invention, for ease of simplify processing, between ASN and ASN, and the packet between ASN and ISN and signaling bag all adopt unified form.In the situation that form is identical, when ASN or ISN process packet or signaling bag, only need just can judge according to the fixed position of message header is data and signaling, thereby can improve the processing speed of system.
In the present invention, ASN or ISN only, when receiving data/signaling message that terminal is sent, carry out the encapsulation of sequence number; When receiving the message that mails to terminal, ASN or ISN sort (if necessary) according to sequence number, then carry out issuing object terminal after decapsulation.
As shown in Figure 2, the present invention also provides a kind of data encapsulation system, is applied to identify label and position separation, comprises ASN, ISN and terminal, and wherein ASN and ISN further comprise package module, decapsulation module and forwarding module.Wherein, the function of each network element/module is as follows:
Package module is used for, and when receiving source terminal and mailing to the message of the object terminal that is positioned at this framework, increases by an encapsulated layer in message, comprises the sequence information that terminal sends message in encapsulated layer;
Decapsulation module is used for, and while receiving the message that mails to object terminal, carries out, after decapsulation processing, sending to forwarding module;
Forwarding module is used for, and when receiving the data message of package module transmission, is transmitted to the decapsulation module of object ASN; And, when receiving the data message of decapsulation module transmission, after the message receiving being sorted according to described sequence information, send to described object terminal.
Wherein, package module also for, according to the object AID in the data message receiving, inquire about corresponding RID, and the object RID inquiring be encapsulated in data message, be forwarded to backbone network;
Backbone network according to object RID by data message forwarding to object ASN.
Further, package module also for, when RID corresponding to inquiry, the local identity station location marker map information of whether preserving object AID of inquiry first, in the situation that not preserving, to the map information of mapping plane inquiry AID and RID,
Further, described package module is used for comprising that packet or signaling packet voice adopt unified form to encapsulate.
Further, package module also for, in encapsulated layer, encapsulate a kind of or its combination in any in following field:
Whether flag field, for identifying message with sequence information;
Message type field, is packet or signaling bag for identifying message, if signaling bag, also for identifying the type of signaling;
Version number field, for the version number of identification data encapsulation format;
Reserved field.
Further, package module adopts the mode of UDP to carry out data encapsulation to message.