CN101350693B - Method and apparatus for conveying protocol information - Google Patents
Method and apparatus for conveying protocol information Download PDFInfo
- Publication number
- CN101350693B CN101350693B CN 200710076084 CN200710076084A CN101350693B CN 101350693 B CN101350693 B CN 101350693B CN 200710076084 CN200710076084 CN 200710076084 CN 200710076084 A CN200710076084 A CN 200710076084A CN 101350693 B CN101350693 B CN 101350693B
- Authority
- CN
- China
- Prior art keywords
- header
- protocol information
- ipv6 packet
- ipv6
- node
- 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.)
- Expired - Fee Related
Links
Images
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L69/00—Network arrangements, protocols or services independent of the application payload and not provided for in the other groups of this subclass
- H04L69/16—Implementation or adaptation of Internet protocol [IP], of transmission control protocol [TCP] or of user datagram protocol [UDP]
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L69/00—Network arrangements, protocols or services independent of the application payload and not provided for in the other groups of this subclass
- H04L69/16—Implementation or adaptation of Internet protocol [IP], of transmission control protocol [TCP] or of user datagram protocol [UDP]
- H04L69/161—Implementation details of TCP/IP or UDP/IP stack architecture; Specification of modified or new header fields
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L69/00—Network arrangements, protocols or services independent of the application payload and not provided for in the other groups of this subclass
- H04L69/16—Implementation or adaptation of Internet protocol [IP], of transmission control protocol [TCP] or of user datagram protocol [UDP]
- H04L69/167—Adaptation for transition between two IP versions, e.g. between IPv4 and IPv6
Landscapes
- Engineering & Computer Science (AREA)
- Computer Security & Cryptography (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Data Exchanges In Wide-Area Networks (AREA)
Abstract
本发明提供了一种传送协议信息的发送、接收方法以及发送、接收装置,属于通信领域。包括:构造协议信息;构造IPv6分组的首部,并标记所述IPv6分组为IPv6空包;在所述IPv6分组的净荷区加入所述协议信息构成IPv6分组;将构造好的IPv6分组发送出去。接收IPv6分组;当所述IPv6分组为IPv6空包并包含协议信息时,根据所述IPv6分组的首部,确定当前节点是否为解析处理所述协议信息的节点;当确定当前节点为解析处理所述协议信息的节点时,解析处理所述协议信息。本发明提供的技术方案通过对IPv6进行协议扩展,用于传送协议信息,能够完全兼容于常规的IPv6协议,还可以保证协议信息形式的简单性和解析的方便性。
The invention provides a sending and receiving method and a sending and receiving device of transmission protocol information, which belong to the communication field. Including: constructing protocol information; constructing the header of the IPv6 packet, and marking the IPv6 packet as an IPv6 empty packet; adding the protocol information to the payload area of the IPv6 packet to form an IPv6 packet; sending out the constructed IPv6 packet. Receive IPv6 grouping; When the IPv6 grouping is IPv6 empty packet and include protocol information, according to the header of the IPv6 grouping, determine whether the current node is the node for parsing and processing the protocol information; when it is determined that the current node is for parsing and processing the When the node of the protocol information is used, the protocol information is parsed and processed. The technical scheme provided by the invention is used to transmit protocol information by extending the IPv6 protocol, can be completely compatible with the conventional IPv6 protocol, and can also ensure the simplicity of the protocol information form and the convenience of analysis.
Description
技术领域technical field
本发明涉及通信领域,特别涉及一种发送协议信息的方法和装置,以及一种接收协议信息的方法和装置。The invention relates to the communication field, in particular to a method and device for sending protocol information, and a method and device for receiving protocol information.
背景技术Background technique
目前Internet主要采用的还是IPv4技术,但是随着各种网络应用和业务的迅速发展,用户急剧增加,IPv4技术面临着一些难以克服的困难,例如IP地址的耗尽,实时业务QoS(Quality of Service,服务质量)的支持差等方面的不足。而IPv6技术在地址数量、安全性、服务质量、移动性等方面具有明显的优势。因此,采用IPv6的网络将比现有的IPv4网络扩展性更好、更容易为用户提供QoS业务。At present, the Internet mainly adopts IPv4 technology, but with the rapid development of various network applications and services, the number of users has increased sharply, and IPv4 technology is facing some insurmountable difficulties, such as exhaustion of IP addresses, real-time business QoS (Quality of Service) , service quality) poor support and other deficiencies. The IPv6 technology has obvious advantages in the number of addresses, security, quality of service, mobility and so on. Therefore, the network adopting IPv6 will have better scalability than the existing IPv4 network, and it will be easier to provide users with QoS services.
参见图1,它是IPv6的分组格式,包含一个基本首部10和可选个数的扩展首部20,以及可选的上层协议载荷30。其中,基本首部由版本号(数值固定为6)、信流类型、流标签、PL(Playload Length,载荷长度)、NH(Next Header,下一首部)、HL(Hop Limit,路径段限制)、源地址、目的地址8个字段组成。而IPv6扩展首部有很多种,其中包括:逐跳选项首部、目的选项首部、路由首部、分片首部、认证首部、封装安全载荷首部、NNH(No Next Header,一种IPv6扩展首部)等等,它们可按照一定的规则组合到一个IPv6分组中。无论是基本首部还是扩展首部,其中的Next Header字段都指示其后所跟的扩展首部类型或者上层协议类型。Referring to FIG. 1 , it is an IPv6 packet format, which includes a
IPv6作为下一代因特网的基础技术,现有技术针对它提出了不少的扩展协议,通常这些协议都需要定义自己的信令信息。参见图2,它给出了一种典型的协议信息封装格式。As the basic technology of the next generation Internet, IPv6 has proposed many extension protocols for it in the prior art, and usually these protocols need to define their own signaling information. See Figure 2, which shows a typical protocol information encapsulation format.
特别地,IP电信网很有可能成为未来的电信网络发展方向。然而,目前IPv6本身尚不能支持电信网络所需要的OAM(Operation Administration Maintenance,运营管理维护)功能。OAM是监控和解决网络问题的工具。它能够报告网络的状态,使网络管理员能够更有效地管理网络,包括链路性能监测、故障侦测和告警、环路测试、远程MIB变量请求。OAM作为一种设备互操作、互维护的通用机制,其基本操作包括建立OAM连接、链路监控、远端故障诊断、远程环回和远程MIB变量请求。In particular, the IP telecommunication network is likely to become the development direction of the future telecommunication network. However, at present, IPv6 itself cannot support the OAM (Operation Administration Maintenance, Operation Administration Maintenance) function required by the telecommunication network. OAM is a tool for monitoring and solving network problems. It can report the status of the network, enabling network administrators to manage the network more effectively, including link performance monitoring, fault detection and alarm, loop test, remote MIB variable request. OAM is a general mechanism for device interoperability and mutual maintenance. Its basic operations include establishing OAM connections, link monitoring, remote fault diagnosis, remote loopback, and remote MIB variable requests.
虽然正处于IETF(Internet Engineering Task Force,互联网工程任务组)草案阶段的双向转发检测有助于在一定程度上提高故障检测的速度,但它是在IPv6包头之后封装UDP层,然后再封装双向转发检测载荷,因此,它需要经过上层协议处理或者深度包分析之后才能够获取该载荷。这使得它不适合在数据转发平面上实现,难以达到时间要求严格的保护切换要求。Although the two-way forwarding detection that is in the draft stage of IETF (Internet Engineering Task Force, Internet Engineering Task Force) helps to improve the speed of fault detection to a certain extent, it encapsulates the UDP layer after the IPv6 packet header, and then encapsulates the two-way forwarding To detect the payload, therefore, it needs to be processed by the upper layer protocol or deep packet analysis before it can obtain the payload. This makes it unsuitable for implementation on the data forwarding plane, and it is difficult to meet the time-critical protection switching requirements.
参见图3,现有技术一定义了一种新的扩展首部类型40,并在扩展首部40内封装协议信息。由于这种扩展首部的处理可能会涉及到一条路径上的多个节点甚至所有节点,所以它需要定义为逐跳处理的扩展首部,或者是与逐跳选项、目的选项以及路由扩展首部等组合起来应用。Referring to FIG. 3 , prior art 1 defines a new
但是,该方法需要修改IPv6标准,包括定义新的扩展首部类型及其处理机制,以及该扩展首部相对其它扩展首部的处理顺序,这必须取得IETF的支持,因此涉及漫长的标准化过程。另外,增加该扩展首部后,在转发平面处理任何带扩展首部的IPv6分组时,都需要识别它是否就是这种特殊扩展首部,这会增加转发过程的复杂性,影响转发速度。However, this method needs to modify the IPv6 standard, including defining a new extension header type and its processing mechanism, as well as the processing sequence of the extension header relative to other extension headers. This method must obtain the support of the IETF, and therefore involves a long standardization process. In addition, after the extension header is added, when any IPv6 packet with the extension header is processed on the forwarding plane, it is necessary to identify whether it is this special extension header, which will increase the complexity of the forwarding process and affect the forwarding speed.
参见图4,现有技术二定义了一种新的IPv6选项类型,然后将协议信息封装在这种选项类型内,并且让IPv6协议中,逐跳选项扩展首部和目的选项扩展首部两种扩展首部都能够解析和处理这种选项类型。其选项类型的前3个比特的二进制数值设置为000,这样中间节点即使不能识别该选项类型,也可以无改变地转发该分组。然而该方法需要定义新的IPv6选项类型,其信息构造过程比较复杂,解析效率相对较低。特别是对于前述OAM信息,可能还需要修改多种扩展首部的选项处理行为才能满足协议的要求。另外,如同现有技术一,为了满足IPv6网络互通的要求,它也需要取得IETF的支持,修改IPv6标准。Referring to Fig. 4, the prior art 2 defines a new IPv6 option type, and then encapsulates the protocol information in this option type, and allows two types of extension headers in the IPv6 protocol, the hop-by-hop option extension header and the destination option extension header are able to parse and handle this option type. The binary value of the first 3 bits of the option type is set to 000, so that even if the intermediate node cannot recognize the option type, it can forward the packet unchanged. However, this method needs to define a new IPv6 option type, and its information construction process is relatively complicated, and its parsing efficiency is relatively low. Especially for the aforementioned OAM information, it may be necessary to modify the option processing behaviors of various extension headers to meet the requirements of the protocol. In addition, like the prior art 1, in order to meet the requirement of IPv6 network intercommunication, it also needs the support of IETF to modify the IPv6 standard.
目前,ITU—T(International Telecom Union-Telecom,国际电信联盟电信标准化部门)尚未开始对IPv6的OAM进行标准化,但是从它公布的T—MPLS(Transport-MPLS,传送多协议标签交换)等分组传送网络的建议草案要求来看,其OAM在功能上丰富很多,实时性要求也很高。IPv6若要用于电信网络,也需要达到类似的OAM性能要求。因此,需要对IPv6进行协议扩展,例如增加电信级别的传送网络所需要的OAM功能。At present, ITU-T (International Telecom Union-Telecom, International Telecommunication Union Telecommunication Standardization Sector) has not yet started to standardize IPv6 OAM, but from the T-MPLS (Transport-MPLS, Transport Multi-Protocol Label Switching) and other packet transmissions announced by it According to the proposed draft requirements of the network, its OAM is rich in functions and has high real-time requirements. If IPv6 is to be used in telecommunication networks, it also needs to meet similar OAM performance requirements. Therefore, it is necessary to extend the protocol of IPv6, for example, to increase the OAM function required by the transport network of the telecommunication level.
发明内容Contents of the invention
本发明旨在提供了一种传送协议信息的方法,传送例如电信级别的传送网络所需要的OAM功能的协议信息。由于完成传送该协议信息需要支持相当复杂的信令信息,因此需要通过对IPv6进行协议扩展,将扩展协议信息直接封装到IPv6分组的首部。The present invention aims to provide a method for transmitting protocol information, such as the protocol information of the OAM function required by the telecommunication level transmission network. Since the transmission of the protocol information needs to support quite complex signaling information, it is necessary to extend the IPv6 protocol to directly encapsulate the extended protocol information into the header of the IPv6 packet.
为了解决上述问题,本发明实施例提供了一种传送协议信息的发送方法、接收方法和网络节点,技术方案如下:In order to solve the above problems, the embodiment of the present invention provides a sending method, a receiving method and a network node for transmitting protocol information, and the technical solution is as follows:
首先,本发明实施例提供了一种发送协议信息的方法,所述方法包括:First, an embodiment of the present invention provides a method for sending protocol information, the method including:
构造协议信息;Construct protocol information;
构造IPv6分组首部;Construct the IPv6 packet header;
在IPv6分组的净荷区加入所述协议信息和所述IPv6分组首部构成IPv6分组,并在所述IPv6分组首部标记所述IPv6分组为IPv6空包;Adding the protocol information and the IPv6 packet header in the payload area of the IPv6 packet to form an IPv6 packet, and marking the IPv6 packet at the IPv6 packet header as an IPv6 empty packet;
在所述IPv6分组首部标识传输路径上需要解析处理所述协议信息的节点,将所述IPv6分组发送出去。The IPv6 packet header identifies a node on the transmission path that needs to parse and process the protocol information, and sends the IPv6 packet.
本发明实施例还提供了一种接收协议信息的方法,所述方法具体包括:The embodiment of the present invention also provides a method for receiving protocol information, the method specifically includes:
接收IPv6分组;receive IPv6 packets;
当所述IPv6分组为IPv6空包时,确定所述IPv6分组是否包含协议信息,是则根据所述IPv6分组的首部,确定接收到所述IPv6分组的当前节点是否为解析处理所述协议信息的节点;When the IPv6 packet is an IPv6 empty packet, determine whether the IPv6 packet contains protocol information, and then determine whether the current node that receives the IPv6 packet is the one that parses and processes the protocol information according to the header of the IPv6 packet node;
当确定当前节点为解析处理所述协议信息的节点时,解析所述IPv6分组,并解析处理所述协议信息。When it is determined that the current node is a node that parses and processes the protocol information, parses the IPv6 packet, and parses and processes the protocol information.
本发明实施里还提供了一种发送协议信息的装置,所述装置包括:In the implementation of the present invention, a device for sending protocol information is also provided, and the device includes:
协议信息构造模块,用于构造协议信息;The protocol information construction module is used to construct the protocol information;
分组首部构造模块,用于构造IPv6分组首部;A packet header construction module for constructing an IPv6 packet header;
分组构造模块,用于在IPv6分组的净荷区加入所述协议信息和所述IPv6分组首部构成IPv6分组,并在所述IPv6分组首部标记所述IPv6分组为IPv6空包;A packet construction module, configured to add the protocol information and the IPv6 packet header in the payload area of the IPv6 packet to form an IPv6 packet, and mark the IPv6 packet at the IPv6 packet header as an IPv6 empty packet;
发送模块,用于在所述IPv6分组首部标识传输路径上需要解析处理所述协议信息的节点,将所述IPv6分组发送出去。A sending module, configured to identify a node on the transmission path that needs to parse and process the protocol information in the header of the IPv6 packet, and send the IPv6 packet.
本发明实施例还提供了一种接收协议信息的装置,所述装置包括:The embodiment of the present invention also provides a device for receiving protocol information, the device comprising:
接收模块,用来接收IPv6分组;A receiving module, configured to receive IPv6 packets;
第一判断模块,用来当所述IPv6分组为IPv6空包时,根据所述IPv6分组的基本首部载荷长度字段是否大于所有扩展首部的长度之和判断所述IPv6分组是否为包含协议信息的IPv6分组;The first judging module is used to determine whether the IPv6 packet is an IPv6 packet containing protocol information according to whether the basic header load length field of the IPv6 packet is greater than the sum of the lengths of all extended headers when the IPv6 packet is an IPv6 empty packet group;
第二判断模块,用于当第一判断模块判断所述IPv6分组为包含协议信息的分组时,根据所述IPv6分组的首部判断当前节点是否为解析处理所述协议信息的节点;The second judging module is used to judge whether the current node is a node for parsing and processing the protocol information according to the header of the IPv6 packet when the first judging module judges that the IPv6 packet is a packet containing protocol information;
解析处理模块,用来当所述IPv6分组包含协议信息时,解析所述IPv6分组,并解析处理所述协议信息。The parsing and processing module is used for parsing the IPv6 packet when the IPv6 packet contains protocol information, and parsing and processing the protocol information.
本发明以上实施例通过将扩展协议信息直接封装到IPv6分组的首部的净荷区,利用IPv6空包特性,增强协议信息的传送功能,它向后兼容常规的IPv6协议,并且扩展的协议信息在传统IPv6路由器的中间节点上可以透明传输,从而能够保证网络的互通性,而且无需IETF分配新的Next Header类型或者增加新的选项数据类型,因此更容易推行。基于该方法能够构造复杂的协议信息,并保持形式的简单性和解析的简易性,提高了转发速度。In the above embodiments of the present invention, by directly encapsulating the extended protocol information into the payload area of the header of the IPv6 packet, utilizing the IPv6 empty packet feature, the transmission function of the protocol information is enhanced, and it is backward compatible with the conventional IPv6 protocol, and the extended protocol information is in The intermediate nodes of traditional IPv6 routers can be transparently transmitted to ensure network interoperability, and there is no need for IETF to allocate new Next Header types or add new option data types, so it is easier to implement. Based on this method, complex protocol information can be constructed, and the simplicity of form and simplicity of analysis can be maintained, thereby improving the forwarding speed.
附图说明Description of drawings
图1为现有技术中IPv6的分组格式示意图;Fig. 1 is a schematic diagram of the packet format of IPv6 in the prior art;
图2为一种典型的协议信息封装格式示意图;Fig. 2 is a schematic diagram of a typical protocol information encapsulation format;
图3为现有技术一将协议信息封装在新的IPv6扩展首部内的示意图;Fig. 3 is a schematic diagram of prior art one encapsulating protocol information in a new IPv6 extension header;
图4为现有技术二将协议信息封装在新的IPv6选项类型内的示意图;Fig. 4 is a schematic diagram of prior art 2 encapsulating protocol information in a new IPv6 option type;
图5为根据本发明实施例1提供的包含协议信息的IPv6分组示意图;FIG. 5 is a schematic diagram of an IPv6 packet including protocol information provided according to Embodiment 1 of the present invention;
图6为根据本发明实施例1提供的发送协议信息方法流程图;FIG. 6 is a flowchart of a method for sending protocol information according to Embodiment 1 of the present invention;
图7为根据本发明实施例2提供的接收协议信息方法流程图;FIG. 7 is a flowchart of a method for receiving protocol information according to Embodiment 2 of the present invention;
图8为根据本发明实施例3提供的对任意IPv6分组进行接收处理的流程图。FIG. 8 is a flow chart of receiving any IPv6 packet according to Embodiment 3 of the present invention.
图9为根据本发明实施例4提供的发送协议信息装置示意图;FIG. 9 is a schematic diagram of an apparatus for sending protocol information according to Embodiment 4 of the present invention;
图10为根据本发明实施例5提供的接收协议信息装置示意图。Fig. 10 is a schematic diagram of an apparatus for receiving protocol information according to Embodiment 5 of the present invention.
具体实施方式Detailed ways
下面将结合本发明实施例中的附图,对本发明实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅仅是本发明一部分实施例,而不是全部的实施例。基于本发明中的实施例,本领域普通技术人员在没有做出创造性劳动的前提下所获得的所有其他实施例,都属于本发明保护的范围。The following will clearly and completely describe the technical solutions in the embodiments of the present invention with reference to the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only some, not all, embodiments of the present invention. Based on the embodiments of the present invention, all other embodiments obtained by persons of ordinary skill in the art without making creative efforts belong to the protection scope of the present invention.
根据IPv6规范,若IPv6基本首部或者任何扩展首部的Next Header字段为59,则表明在该首部之后没有任何东西,因此这种首部类型实际上定义了一种空包。另外它还规定,任何这种空包,即使其IPv6载荷长度表示其后有额外字节,也应该忽略这些字节并且无改变地转发该分组。According to the IPv6 specification, if the Next Header field of the IPv6 basic header or any extended header is 59, it indicates that there is nothing after the header, so this header type actually defines an empty packet. It also specifies that any such empty packet, even if its IPv6 payload length indicates that there are extra bytes following it, should ignore these bytes and forward the packet unchanged.
如图6所示,本发明实施例1提供了一种发送协议信息的方法。为了传送某种满足应用需求的协议信息,根据本发明技术方案,构造为空包的IPv6分组,其中所述IPv6分组包含所述协议信息。具体如下:As shown in FIG. 6 , Embodiment 1 of the present invention provides a method for sending protocol information. In order to transmit certain protocol information that meets application requirements, according to the technical solution of the present invention, an IPv6 packet of an empty packet is constructed, wherein the IPv6 packet contains the protocol information. details as follows:
步骤101,构造协议信息;
协议信息的格式如图2所示,本发明不限制协议信息的构造格式,任何满足协议信息本身的构造要求,并按照需要做任意扩展的形式应用于本发明都在本发明保护之内。The format of the protocol information is shown in Figure 2. The present invention does not limit the structural format of the protocol information. Any form that meets the structural requirements of the protocol information itself and is arbitrarily expanded as required is applied to the present invention and is within the protection of the present invention.
其中,协议类型、版本、协议功能号根据实际需要传输的协议信息内容定义,并将上述三个信息作为协议信息格式的头部,其后跟着放置该协议信息的数据。Among them, the protocol type, version, and protocol function number are defined according to the content of the protocol information that needs to be transmitted actually, and the above three information are used as the header of the protocol information format, followed by the data for placing the protocol information.
步骤102,构造IPv6分组首部;
设置IPv6分组的基本首部的载荷长度字段值等于所有扩展首部和所述协议信息的长度之和。The value of the payload length field of the basic header of the IPv6 packet is set equal to the sum of the lengths of all extended headers and the protocol information.
根据应用的需要,可以选择是否使用符合IPv6协议的扩展首部,并选择任何一种或多种扩展首部,因此,分组首部可以是IPv6基本首部,也可以是IPv6基本首部和符合IPv6协议规范的各种扩展首部的组合。According to the needs of the application, you can choose whether to use the extension header conforming to the IPv6 protocol, and choose any one or more extension headers. Therefore, the packet header can be the basic IPv6 header, or it can be the basic IPv6 header and various IPv6 protocol specifications. A combination of extension headers.
步骤103,在IPv6分组的净荷区加入所述协议信息和所述IPv6分组首部构成IPv6分组,并在所述IPv6分组首部标记所述IPv6分组为IPv6空包;
如果没有扩展首部,就将IPv6分组的基本首部的Next Header字段置为59(没有扩展头时),如果有,就将最后一个扩展首部的Next Header字段置为59,从而该IPv6分组为一个IPv6空包。If there is no extended header, the Next Header field of the basic header of the IPv6 packet is set to 59 (when there is no extended header), if there is, the Next Header field of the last extended header is set to 59, so that the IPv6 grouping is an IPv6 Empty package.
其中,协议信息用以如图2所示的格式封装,置于IPv6分组的净荷区。图5所示为包含协议信息的IPv6分组示意图。其中左图是将该协议信息直接封装在基本首部之后的净荷区,右图是将该协议信息封装在扩展首部之后的净荷区。例如,当协议信息为OAM协议信息时,将OAM协议信息进行封装并放置在IPv6空包的净荷区。Wherein, the protocol information is encapsulated in the format shown in FIG. 2 and placed in the payload area of the IPv6 packet. Figure 5 is a schematic diagram of an IPv6 packet containing protocol information. The left picture shows the payload area where the protocol information is directly encapsulated after the basic header, and the right picture shows the payload area where the protocol information is encapsulated after the extended header. For example, when the protocol information is OAM protocol information, the OAM protocol information is encapsulated and placed in the payload area of the IPv6 null packet.
这时,构造好的IPv6分组的基本首部的载荷长度字段值为能够反映所携带的OAM协议信息长度和该分组所有扩展首部长度的总和。At this time, the payload length field value of the basic header of the constructed IPv6 packet can reflect the sum of the length of the carried OAM protocol information and the length of all extended headers of the packet.
步骤104,在所述IPv6分组首部标识传输路径上需要解析处理所述协议信息的节点,将所述IPv6分组发送出去。
例如,当所述IPv6分组只包括基本首部时,利用所述基本首部的流标签来标识解析处理所述协议信息的节点,或者当IPv6分组同时包括基本首部和其它类型扩展首部时,利用所用的扩展首部来标识解析处理所述协议信息的节点。例如,当IPv6分组同时包括基本首部和其它类型扩展首部时,可以有以下几种情况,本发明实施例不限于以下的几种使用扩展首部的情况。For example, when the IPv6 packet only includes the basic header, use the flow label of the basic header to identify the node that parses and processes the protocol information, or when the IPv6 packet includes both the basic header and other types of extended headers, use the used The header is extended to identify the nodes that parse and process the protocol information. For example, when the IPv6 packet includes both the basic header and other types of extended headers, the following situations may occur, and the embodiment of the present invention is not limited to the following situations of using the extended headers.
当所述IPv6分组包括的扩展首部为逐跳选项首部和NNH首部时,标识传输路径上所有节点为解析处理所述协议信息的节点;或者When the extended header included in the IPv6 packet is a hop-by-hop option header and an NNH header, identify all nodes on the transmission path as nodes that parse and process the protocol information; or
当所述IPv6分组包括的扩展首部为目的选项首部和NNH首部,标识目的节点为解析处理所述协议信息的节点;或者When the extended header included in the IPv6 packet is a destination option header and an NNH header, identify the destination node as a node that parses and processes the protocol information; or
当所述IPv6分组包括的扩展首部为路由扩展首部和NNH首部,标识由所述路由首部指定的节点为解析处理所述协议信息的节点。When the extension header included in the IPv6 packet is a routing extension header and an NNH header, identify the node specified by the routing header as a node for parsing and processing the protocol information.
如图7所示,为本发明实施例2提供的一种接收协议信息的方法的流程图,所述接收方法具体包括:As shown in FIG. 7, it is a flow chart of a method for receiving protocol information provided by Embodiment 2 of the present invention. The receiving method specifically includes:
步骤201,接收IPv6分组;
步骤202,当接收到的IPv6分组为IPv6空包时,确定所述IPv6分组是否包含协议信息,是则根据所述IPv6分组的首部,确定接收到所述IPv6分组的当前节点是否为解析处理所述协议信息的节点;
其中,当所述IPv6分组有任一首部的Next Header值为59时,所述IPv6分组为IPv6空包。Wherein, when the Next Header value of any header of the IPv6 packet is 59, the IPv6 packet is an IPv6 empty packet.
继续判断所述IPv6分组是否包含协议信息,具体包括:当所述IPv6分组为IPv6空包时,并且当所述IPv6分组的基本首部的载荷长度字段等于所有扩展首部和所述协议信息长度之和时,所述IPv6分组包含协议信息。Continue to determine whether the IPv6 packet contains protocol information, specifically including: when the IPv6 packet is an IPv6 empty packet, and when the payload length field of the basic header of the IPv6 packet is equal to the sum of all extended headers and the length of the protocol information , the IPv6 packet contains protocol information.
步骤203,当确定当前节点为解析处理所述协议信息的节点时,解析所述IPv6分组,并解析处理所述协议信息。
其中,判断当前节点是否为解析处理所述协议信息的节点的步骤又包括:Wherein, the step of judging whether the current node is a node for parsing and processing the protocol information further includes:
提取所述IPv6分组的首部;Extracting the header of the IPv6 packet;
当所述IPv6分组只包括基本首部时,由所述IPv6分组的基本首部的流标签来标识所述当前节点是否为解析处理所述协议信息的节点;When the IPv6 packet only includes a basic header, the flow label of the basic header of the IPv6 packet identifies whether the current node is a node that parses and processes the protocol information;
或者or
当所述IPv6分组同时包括基本首部和其它类型扩展首部时,根据所用的扩展首部来标识所述当前节点是否为解析处理所述协议信息的节点。When the IPv6 packet includes both the basic header and other types of extended headers, it is identified whether the current node is a node that parses and processes the protocol information according to the used extended headers.
例如:当所述IPv6分组包括的扩展首部为逐跳选项首部和NNH首部时,则当前节点为解析处理所述协议信息的节点;或者For example: when the extended header included in the IPv6 packet is the hop-by-hop option header and the NNH header, the current node is the node that parses and processes the protocol information; or
当所述IPv6分组包括的扩展首部为目的选项首部和NNH首部,且当前节点是目的节点时,则当前节点为解析处理所述协议信息的节点;或者When the extended header included in the IPv6 packet is a destination option header and an NNH header, and the current node is a destination node, the current node is a node that parses and processes the protocol information; or
当所述IPv6分组包括的扩展首部为路由扩展首部和NNH首部,且当前节点由所述路由首部指定,则当前节点为解析处理所述协议信息的节点。When the extension header included in the IPv6 packet is a routing extension header and an NNH header, and the current node is specified by the routing header, then the current node is a node that parses and processes the protocol information.
如图8所示,对于任意一个IPv6分组,本发明实施例3接收处理所述IPv6分组的流程如下:As shown in Figure 8, for any IPv6 packet, the process of receiving and processing the IPv6 packet in Embodiment 3 of the present invention is as follows:
接收IPv6分组;receive IPv6 packets;
判断所述IPv6分组是否为IPv6空包:Judging whether the IPv6 grouping is an IPv6 empty packet:
当接收到的IPv6分组为IPv6空包,判断所述IPv6分组是否包含协议信息,当所述IPv6分组不包含协议信息时,判断当前节点是否为目的节点,是则完成对该IPv6分组的处理,否则直接转发所述IPv6分组;或者,当接收到的IPv6分组不为空包时,且其任一首部标识所述IPv6分组包含上层协议信息时,进行上层协议信息处理;When the received IPv6 packet is an IPv6 empty packet, it is judged whether the IPv6 packet contains protocol information, and when the IPv6 packet does not contain protocol information, it is judged whether the current node is a destination node, if so, the processing of the IPv6 packet is completed, Otherwise, directly forward the IPv6 packet; or, when the received IPv6 packet is not an empty packet, and any header identifies that the IPv6 packet contains upper-layer protocol information, perform upper-layer protocol information processing;
当所述IPv6分组为IPv6空包并包含协议信息时,根据所述IPv6分组的首部,确定当前节点是否为解析处理所述协议信息的节点。When the IPv6 packet is an IPv6 empty packet and contains protocol information, determine whether the current node is a node that parses and processes the protocol information according to the header of the IPv6 packet.
当确定当前节点为解析处理所述协议信息的节点时,解析处理所述协议信息。When it is determined that the current node is a node that parses and processes the protocol information, parses and processes the protocol information.
当当前节点为IPv6路由器时,直接转发所述IPv6分组。When the current node is an IPv6 router, directly forward the IPv6 packet.
判断所述IPv6分组是否到达目的节点,当到达当前节点为目的节点时,完成对该IPv6分组的处理,否则将接着转发下去。It is judged whether the IPv6 packet has reached the destination node, and when the current node is the destination node, the processing of the IPv6 packet is completed, otherwise, it will be forwarded.
参见图9,本发明实施例4还提供了一种发送协议信息的装置,所述装置包括:Referring to FIG. 9, Embodiment 4 of the present invention also provides an apparatus for sending protocol information, the apparatus including:
协议信息构造模块101,用于构造协议信息;A protocol
分组首部构造模块102,用于构造IPv6分组首部;A packet
分组构造模块103,用于在IPv6分组的净荷区加入所述协议信息和所述IPv6分组首部构成IPv6分组,并在所述IPv6分组首部标记所述IPv6分组为IPv6空包;The
发送模块104,用于在所述IPv6分组首部标识传输路径上需要解析处理所述协议信息的节点,将所述IPv6分组发送出去。The sending
如图9所示,所述分组首部构造模块102包括:As shown in Figure 9, the packet
第一填充单元,用于填充所述IPv6分组的首部的Next Header字段,以标记所述IPv6分组为IPv6空包;The first filling unit is used to fill the Next Header field of the header of the IPv6 packet, to mark the IPv6 packet as an IPv6 empty packet;
第二填充单元,用于填充所述IPv6分组的首部的载荷长度字段。The second filling unit is used to fill the payload length field of the IPv6 packet header.
所述发送模块104还包括:The sending
节点标识单元,当所述IPv6分组只包括基本首部时,用于利用所述基本首部的流标签来标识解析处理所述协议信息的节点,或者当IPv6分组同时包括基本首部和其它类型扩展首部时,用于利用所用的扩展首部来标识解析处理所述协议信息的节点。A node identification unit, when the IPv6 packet only includes a basic header, used to use the flow label of the basic header to identify the node that parses and processes the protocol information, or when the IPv6 packet includes both a basic header and other types of extended headers , which is used to identify the node that parses and processes the protocol information by using the used extension header.
例如,当IPv6分组同时包括基本首部和其它类型扩展首部时,可以有以下几种情况,本发明实施例不限于以下的几种使用扩展首部的情况。For example, when the IPv6 packet includes both the basic header and other types of extended headers, the following situations may occur, and the embodiment of the present invention is not limited to the following situations of using the extended headers.
当所述IPv6分组包括的扩展首部为逐跳选项首部和NNH首部时,用于标识传输路径上所有节点为解析处理所述协议信息的节点;或者When the extended header included in the IPv6 packet is a hop-by-hop option header and an NNH header, it is used to identify all nodes on the transmission path as nodes that parse and process the protocol information; or
当所述IPv6分组包括的扩展首部为目的选项首部和NNH首部,用于标识目的节点为解析处理所述协议信息的节点;或者When the extended header included in the IPv6 packet is a destination option header and an NNH header, it is used to identify the destination node as a node that parses and processes the protocol information; or
当所述IPv6分组包括的扩展首部为路由扩展首部和NNH首部,用于标识由所述路由首部指定的节点为解析处理所述协议信息的节点。When the extension header included in the IPv6 packet is a routing extension header and an NNH header, it is used to identify the node specified by the routing header as a node for parsing and processing the protocol information.
参见图10,本发明实施例5还提供了一种接收协议信息的装置,所述装置包括:Referring to Figure 10, Embodiment 5 of the present invention also provides an apparatus for receiving protocol information, the apparatus comprising:
接收模块201,用来接收IPv6分组;Receiving
第一判断模块202,用来当所述IPv6分组为IPv6空包时,根据所述IPv6分组的基本首部载荷长度字段是否大于所有扩展首部的长度之和判断所述IPv6分组是否为包含协议信息的IPv6分组;The
第二判断模块203,用于当第一判断模块判断所述IPv6分组为包含协议信息的分组时,根据所述IPv6分组的首部判断当前节点是否为解析处理所述协议信息的节点;The
解析处理模块204,用来当所述IPv6分组包含协议信息时,解析所述IPv6分组,并解析处理所述协议信息。The parsing and processing module 204 is configured to parse the IPv6 packet when the IPv6 packet contains protocol information, and parse and process the protocol information.
当当前节点为解析处理协议信息的节点时,并且接收到的分组包含协议信息时,解析处理模块204对接收到的分组进行解析,并提取所述的协议信息。When the current node is a node for analyzing and processing protocol information, and the received packet contains protocol information, the analyzing processing module 204 analyzes the received packet, and extracts the protocol information.
如上所述的一种接收协议信息的装置,所述装置还包括:A device for receiving protocol information as described above, the device further includes:
转发模块205,用于转发所述IPv6分组;A forwarding module 205, configured to forward the IPv6 packet;
当所述当前节点为为解析处理所述协议信息的节点但不为目的节点时,所述解析处理协议信息后,转发模块205对所述IPv6分组进行转发,或者当所述当前节点不为解析处理所述协议信息的节点且不为目的节点时,转发模块205直接转发所述IPv6分组,直到所述当前节点是目的节点。When the current node is a node for parsing and processing the protocol information but not a destination node, after the parsing and processing of the protocol information, the forwarding module 205 forwards the IPv6 packet, or when the current node is not for parsing When the node processing the protocol information is not the destination node, the forwarding module 205 directly forwards the IPv6 packet until the current node is the destination node.
如上所述的接收装置,所述第二判断模块203具体包括:As described above in the receiving device, the
信息提取模块,用于提取所述IPv6分组中的首部信息;An information extraction module, configured to extract header information in the IPv6 packet;
节点判断模块,用于当所述IPv6分组只包括基本首部时,根据所述IPv6分组的基本首部流标签的标识判断所述当前节点是否为解析处理所述协议信息的节点;A node judging module, configured to judge whether the current node is a node for parsing and processing the protocol information according to the identifier of the basic header flow label of the IPv6 packet when the IPv6 packet only includes a basic header;
或者,or,
当所述IPv6分组同时包括基本首部和其它类型扩展首部时,用于根据所用的扩展首部的标识判断所述当前节点是否为解析处理所述协议信息的节点。When the IPv6 packet includes a basic header and other types of extended headers at the same time, it is used to judge whether the current node is a node that parses and processes the protocol information according to the identifier of the used extended header.
其中,根据所述IPv6分组的首部判断当前节点是否为解析处理所述协议信息的节点,包括以下几种情况,本发明实施例不限于以下几种使用扩展首部的情况。Wherein, judging whether the current node is a node for parsing and processing the protocol information according to the header of the IPv6 packet includes the following situations, and the embodiment of the present invention is not limited to the following situations of using the extended header.
当所述IPv6分组包括的扩展首部为逐跳选项首部和NNH首部时,则当前节点为解析处理所述协议信息的节点;或者When the extended header included in the IPv6 packet is a hop-by-hop option header and an NNH header, the current node is a node that parses and processes the protocol information; or
当所述IPv6分组包括的扩展首部为目的选项首部和NNH首部,且当前节点是目的节点时,则当前节点为解析处理所述协议信息的节点;或者When the extended header included in the IPv6 packet is a destination option header and an NNH header, and the current node is a destination node, the current node is a node that parses and processes the protocol information; or
当所述IPv6分组包括的扩展首部为路由扩展首部和NNH首部,且当前节点由所述路由首部指定,则当前节点为解析处理所述协议信息的节点。When the extension header included in the IPv6 packet is a routing extension header and an NNH header, and the current node is specified by the routing header, then the current node is a node that parses and processes the protocol information.
从上述实施方式的描述可以看出,本发明实施例提供了一种新方法来传送的协议信息,通过利用IPv6空包特性,将协议信息直接封装到IPv6分组的首部之后的净荷区,增强协议信息传送功能,并且使得扩展的协议信息在传统IPv6路由器的中间节点上可以透明传输,从而能够保证网络的互通性,而且无需IETF分配新的Next Header类型或者增加新的选项数据类型,很容易推行。同时它能够完全兼容于常规的IPv6协议,保证IPv6兼容网络的互通,还可以保证协议信息形式的简单性和解析的简易性,提高了转发速度。As can be seen from the description of the above implementation, the embodiment of the present invention provides a new method to transmit the protocol information, by utilizing the IPv6 empty packet feature, the protocol information is directly encapsulated into the payload area after the header of the IPv6 packet, enhancing Protocol information transmission function, and enables transparent transmission of extended protocol information on the intermediate nodes of traditional IPv6 routers, thereby ensuring network interoperability, and without the need for IETF to allocate new Next Header types or add new option data types, it is easy carry out. At the same time, it is fully compatible with the conventional IPv6 protocol, ensures the intercommunication of IPv6 compatible networks, and can also ensure the simplicity of the protocol information form and the simplicity of analysis, improving the forwarding speed.
Claims (18)
Priority Applications (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN 200710076084 CN101350693B (en) | 2007-07-20 | 2007-07-20 | Method and apparatus for conveying protocol information |
PCT/CN2008/071656 WO2009012695A1 (en) | 2007-07-20 | 2008-07-16 | A method and device for transmitting protocol information |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN 200710076084 CN101350693B (en) | 2007-07-20 | 2007-07-20 | Method and apparatus for conveying protocol information |
Publications (2)
Publication Number | Publication Date |
---|---|
CN101350693A CN101350693A (en) | 2009-01-21 |
CN101350693B true CN101350693B (en) | 2011-04-06 |
Family
ID=40269302
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN 200710076084 Expired - Fee Related CN101350693B (en) | 2007-07-20 | 2007-07-20 | Method and apparatus for conveying protocol information |
Country Status (2)
Country | Link |
---|---|
CN (1) | CN101350693B (en) |
WO (1) | WO2009012695A1 (en) |
Families Citing this family (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN106411930B (en) * | 2016-11-09 | 2019-06-07 | 腾讯音乐娱乐(深圳)有限公司 | A kind of protocol information executes method and its equipment |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN1246013A (en) * | 1999-07-14 | 2000-03-01 | 邮电部武汉邮电科学研究院 | Frame encapsulation of adaptation method for making internet be compatible with synchronous digital system |
CN1300149A (en) * | 1999-12-14 | 2001-06-20 | 日本电气株式会社 | Frame structing method, frame-structuring device and data transmission system |
CN1435980A (en) * | 2002-01-30 | 2003-08-13 | 华为技术有限公司 | Method for transmission of protocol data unit information |
CN101001258A (en) * | 2006-01-09 | 2007-07-18 | 三星电子株式会社 | Device supporting mobile internet protocol version 6 (mobile IPv6) |
Family Cites Families (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20060262788A1 (en) * | 2005-05-23 | 2006-11-23 | Broadcom Corporation | Dynamic payload header suppression extensions for IPV6 |
-
2007
- 2007-07-20 CN CN 200710076084 patent/CN101350693B/en not_active Expired - Fee Related
-
2008
- 2008-07-16 WO PCT/CN2008/071656 patent/WO2009012695A1/en active Application Filing
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN1246013A (en) * | 1999-07-14 | 2000-03-01 | 邮电部武汉邮电科学研究院 | Frame encapsulation of adaptation method for making internet be compatible with synchronous digital system |
CN1300149A (en) * | 1999-12-14 | 2001-06-20 | 日本电气株式会社 | Frame structing method, frame-structuring device and data transmission system |
CN1435980A (en) * | 2002-01-30 | 2003-08-13 | 华为技术有限公司 | Method for transmission of protocol data unit information |
CN101001258A (en) * | 2006-01-09 | 2007-07-18 | 三星电子株式会社 | Device supporting mobile internet protocol version 6 (mobile IPv6) |
Non-Patent Citations (2)
Title |
---|
S.Deering et al.Request for Comments:2460.《Internet Protocol,Version 6(IPv6) Specification》.1998,全文. * |
马光星.IPv6扩展首部的使用.《中国数据通信》.2001,41-52. * |
Also Published As
Publication number | Publication date |
---|---|
WO2009012695A1 (en) | 2009-01-29 |
CN101350693A (en) | 2009-01-21 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN111953604B (en) | A method and device for providing business services for business flows | |
US7499445B2 (en) | System and method for routing ISIS traffic through unidirectional links of a computer network | |
US8913623B2 (en) | Method and apparatus for processing labeled flows in a communications access network | |
CN102404197B (en) | Data path processing information included in the pseudowire layer of packets | |
CN105656774B (en) | A kind of network real-time video conversation media data multipath hybrid redundancy transmission method | |
CN101364939B (en) | Data packet forwarding method and device, data packet generating device and communication system | |
CN101322374A (en) | Systems and methods for voice over multiprotocol label switching | |
WO2009012688A1 (en) | Method, system and apparatus for forwarding message in three-layer virtual private network | |
CN102217378B (en) | Method, device and system for detecting path information | |
WO2009056061A1 (en) | Method, system and device for transmitting general packet radio service tunneling protocol datagram | |
CN105897665B (en) | Method for realizing TCP transmission in satellite network environment and corresponding gateway | |
CN101459547A (en) | Label forwarding path failure detection method and system | |
CN107370654B (en) | Encapsulation and decapsulation method and related device for pseudowire data message | |
CN111917650B (en) | Method, equipment and system for determining Generic Routing Encapsulation (GRE) tunnel identifier | |
CN108400911A (en) | A kind of device and method for realizing Micro-BFD agreements | |
CN108156050A (en) | Seamless bidirectional forwarding detection (BFD) method and device | |
CN115604339A (en) | IP transparent transmission method and system based on UDP and QUIC protocols | |
CN116057911B (en) | Load Balancing and OAM in Service Function Chaining Using Multiprotocol Label Switching | |
CN115842876A (en) | Method, system, device and storage medium for processing message | |
WO2021254454A1 (en) | Bier oam detection method, and device and system | |
CN101350693B (en) | Method and apparatus for conveying protocol information | |
CN101272326A (en) | A method and communication device for transmitting packets by aggregation links | |
CN100393065C (en) | Packet Encapsulation Method for Multiplexed Connectionless Data Network in IP Telecommunication Network System | |
CN100433722C (en) | Method for recognizing multiple emulation service flow path | |
CN1581876B (en) | System and method for processing network traffic data for router automatic configuration |
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 | ||
CF01 | Termination of patent right due to non-payment of annual fee | ||
CF01 | Termination of patent right due to non-payment of annual fee |
Granted publication date: 20110406 Termination date: 20170720 |