A message processing method, device and storage medium

By parsing, editing and updating the message header information in the egress process pipeline engine, it is directly used by the ACL and IPFIX modules, which solves the problem of message processing delay and cost in traditional technology and achieves more efficient message processing.

CN116074405BActive Publication Date: 2025-01-21SUZHOU CENTEC COMM CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202111289928.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-11-02
Publication Date
2025-01-21
Estimated Expiration
2041-11-02

AI Technical Summary

Technical Problem

A separate parsing module is needed to re-parse the packets in the traditional exit process pipeline engine to obtain packet information and pass it to the ACL module and IPFIX module, resulting in increased delays in message processing and increased costs.

Method used

Analyze the received packets received in the export process pipe engine, obtain information on the header of each layer of packets, and then edit and update the records of the newspaper header. Finally Matching, avoiding the steps to resume again.

Benefits of technology

By directly using the edited packet header information for ACL and IPFIX matching, packet processing delays are reduced and system costs are reduced.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116074405B_ABST
    Figure CN116074405B_ABST
Patent Text Reader

Abstract

The present invention discloses a message processing method, device and storage medium, wherein the method comprises: parsing a received message in an egress process pipeline engine, obtaining and recording information of message headers at each layer in the message; editing message headers at each layer in the message, and updating the recorded message header information at each layer after editing; and performing ACL matching and IPFXI matching according to the updated message header information at each layer. The present invention enables the egress process pipeline engine to no longer need to separately set a message parsing module to obtain information of the edited message, thereby reducing message processing delay and cost.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of network communication technology, and in particular to a message processing method and a device and a storage medium for implementing the message processing method. Background Art

[0002] During network communication, network communication equipment (such as switches, etc.) is equipped with message processing chips that can process messages, such as NP, ASIC, FPGA, etc. Figure 1 As shown, the current message processing chip includes an ingress process pipeline engine (IPPE), a traffic management module (TM, Traffic Manager) and an egress process pipeline engine (EPPE, Egress Process Pipeline Engine). Among them, the ingress process pipeline engine is mainly used to parse the received message, process the receiving interface, search the forwarding table based on the message information to determine the forwarding behavior and destination, and perform ACL and IPFIX operations in the incoming direction based on the parsed message information and the message processing information in the chip; the traffic management module is mainly used to store data packets, data packet buffer management, QoS, scheduling, and multicast replication; the egress process pipeline engine is mainly used to parse the message, process the egress interface, and then edit the headers of each layer. After editing the message, it will be parsed based on the edited message, and perform ACL and IPFIX operations in the direction based on the parsed information, and finally send it out from the port.

[0003] However, in the traditional export process pipeline engine, the ACL module is based on flow strategy, and the IPFIX module is based on flow monitoring and statistics, which means that it is necessary to match and analyze the message based on the information of the edited message. In the current export process pipeline engine, a separate parsing module needs to be added to re-parse the message to pass the acquired message information to the ACL module and the IPFIX module. Due to the addition of a level of message parsing module, the delay of message processing increases, which also increases the cost. Summary of the invention

[0004] The purpose of the present invention is to provide a message processing method, device and storage medium, which has the advantage that it eliminates the need to separately set up a message parsing module in the export process pipeline engine to obtain information of the edited message, thereby reducing the processing delay of the message and reducing the cost.

[0005] To achieve the above object, the present invention provides a message processing method, the message processing method comprising:

[0006] In the egress process pipeline engine, the received message is parsed, and the information of the message headers at each layer in the message is obtained and recorded;

[0007] Edit the headers of each layer in the message, and update the recorded information of the headers of each layer after editing;

[0008] ACL matching and IPFXI matching are performed based on the updated packet header information at each layer.

[0009] Preferably, the information includes inner layer 2 message header information, inner layer 3 message header information, outer layer 2 message header information, and outer layer 3 and 4 message header information.

[0010] Preferably, editing the header messages of each layer in the message, and updating the recorded information of the header messages of each layer after editing, comprises:

[0011] From inside to outside, edit the inner layer 3 message header, inner layer 2 message header, outer layer 3 and 4 message headers, and outer layer 2 message header.

[0012] Preferably, editing the message headers of each layer in the message, and updating the recorded information of the message headers of each layer after editing includes:

[0013] After editing the inner layer 3 message header, update the recorded inner layer 3 message header information;

[0014] After editing the inner layer 2 message header, the recorded inner layer 2 message header information is updated;

[0015] After editing the outer layer 3 and layer 4 message headers, the recorded outer layer 3 and layer 4 message header information is updated;

[0016] After editing the outer layer 2 message header, the recorded outer layer 2 message header information is updated.

[0017] The present invention also discloses a message processing device, the message processing device comprising:

[0018] The first processing module is used to parse the received message in the egress process pipeline engine, obtain and record the information of the message headers of each layer in the message;

[0019] The second processing module is used to edit the message headers of each layer in the message, and update the information of the recorded message headers of each layer after editing;

[0020] The third processing module is used to perform ACL matching and IPFXI matching according to the updated packet header information of each layer.

[0021] Preferably, the information includes inner layer 2 message header information, inner layer 3 message header information, outer layer 2 message header information, and outer layer 3 and 4 message header information.

[0022] Preferably, the second processing module edits the inner layer three-layer message header, the inner layer two-layer message header, the outer layer three-layer and four-layer message header, and the outer layer two-layer message header in sequence from the inside to the outside.

[0023] Preferably, after editing the inner layer three-layer message header, the second processing module updates the recorded information of the inner layer three-layer message header; after editing the inner layer two-layer message header, the second processing module updates the recorded information of the inner layer two-layer message header; after editing the outer layer three and four-layer message headers, the second processing module updates the recorded information of the outer layer three and four-layer message header; after editing the outer layer two-layer message header, the second processing module updates the recorded information of the outer layer two-layer message header.

[0024] The present invention also discloses a message processing device, the message processing device comprising:

[0025] at least one processor;

[0026] and at least one memory, the at least one memory being coupled to the at least one processor and storing a computer program for execution by the at least one processor, wherein when the computer program is executed by the at least one processor, the apparatus executes the method described above.

[0027] The present invention also discloses a computer-readable storage medium on which a computer program is stored. When the computer program is executed by a machine, the method described above is implemented.

[0028] The beneficial effects of the present invention are:

[0029] The present invention improves the message processing process of the export process pipeline engine so that after editing each message header in the message, the recorded information of each layer of message header is updated. This information can be directly used by the ACL and IPFIX modules. There is no need to set up a separate message parsing module to obtain the information of each layer of the edited message header, thereby reducing the delay of message processing and reducing costs. BRIEF DESCRIPTION OF THE DRAWINGS

[0030] Figure 1 It is a structural diagram of a message processing chip in the prior art;

[0031] Figure 2 is a flow chart of a message processing method in one embodiment of the present invention;

[0032] Figure 3 It is a structural diagram of a message processing device in one embodiment of the present invention. DETAILED DESCRIPTION

[0033] The technical solutions of the embodiments of the present invention will be described clearly and completely below in conjunction with the accompanying drawings of the present invention.

[0034] A message processing method disclosed by the present invention eliminates the need to separately set up a message parsing module (Parser Engine) in an egress process pipeline engine to obtain information of edited messages, thereby reducing message processing delay and costs.

[0035] like Figure 2 As shown, a message processing method disclosed by the present invention includes the following steps:

[0036] S100, in the egress process pipeline engine, the received message is parsed, information of each layer of message header in the message is obtained and recorded;

[0037] Specifically, the message processing chip in the network processing device (such as a switch, etc.) includes an ingress process pipeline engine (IPPE, Ingress Process Pipeline Engine), a traffic management module (TM, Traffic Manager) and an egress process pipeline engine (EPPE, Egress Process Pipeline Engine). When the message enters the egress process pipeline engine, that is, when the message enters the outbound processing process, the message is first parsed and processed to obtain the information carried by the message and record the information. The information here includes the inner header information and the outer header information of the message. Among them, the inner header information includes the inner three-layer message header information and the inner two-layer message header information. The inner three-layer message header information includes but is not limited to IPv4, IPv6, and MPLS information, and the inner two-layer message header information includes but is not limited to MACDA, MACSA, VLANTAG, and ETHTYPE. The outer header information includes outer layer 3 and 4 message header information, and outer layer 2 message header information. The outer layer 4 header information includes but is not limited to TCP, Normal UDP, and VxLAN. The outer layer 2 message header information includes but is not limited to MACDA, MACSA, VLAN TAG, and ETHTYPE.

[0038] After the above information is obtained by parsing the message, the information is further recorded. During implementation, the corresponding information can be recorded by configuring the corresponding fields, such as configuring the ParserResult field to record the information obtained after parsing. The ParserResult field may include the InnerL2Hdr field, the InnerL3Hdr field, the OuterL3L4Hdr field, the OuterL2Hdr field, and the like. For example, the inner layer 2 message header information can be recorded through the InnerL2Hdr field; the inner layer 3 message header information can be recorded by configuring the InnerL3Hdr field; the outer layer 3 and 4 message header information can be recorded by configuring the OuterL3L4Hdr field; the outer layer 2 message header information can be recorded by configuring the OuterL2Hdr field. The information recorded at this time is obtained by parsing the message received by the export process pipeline engine, and the message at this time is not edited.

[0039] S200, editing each layer of message headers in the message, and updating the recorded information of each layer of message headers after editing;

[0040] S300: Perform ACL matching and IPFXI matching according to the updated packet header information of each layer.

[0041] Specifically, after parsing the message, the message is further edited and processed. When editing the message, the message is edited from the inside to the outside, that is, the inner three-layer message header, the inner three-layer message header, the outer three-layer and four-layer message header, and the outer two-layer message header of the message are edited from the inside to the outside. And after editing the corresponding message header, the recorded information of the message header is updated, that is, after editing the inner three-layer message header, the InnerL3Hdr field is updated according to the edited information of the inner three-layer message header to realize the update of information; after editing the inner two-layer message header, the InnerL2Hdr field is updated according to the edited information of the inner two-layer message header to realize the update of information; after editing the outer three-layer and four-layer message headers, the OuterL3L4Hdr field is updated according to the edited outer three-layer and four-layer message header information to realize the update of information; after editing the outer two-layer message header, the OuterL2Hdr field is updated according to the edited outer two-layer message header information to realize the update of information.

[0042] After the information of the recorded message headers at each layer is updated, the information can be directly input into the ACL module and IPFIX module to identify the data flow. There is no need to set up a separate message parsing module to obtain the edited message information, thereby reducing the delay in message processing and reducing costs.

[0043] like Figure 3As shown, the present invention also discloses a message processing device, including a first processing module, a second processing module and a third processing module, wherein the first processing module is used to parse the received message in the egress process pipeline engine, obtain and record the information of each layer of message headers in the message, the second processing module is used to edit each layer of message headers in the message, and update the recorded information of each layer of message headers after editing; the third processing module is used to perform ACL matching and IPFXI matching according to the updated information of each layer of message headers. In this embodiment, the first processing module, the second processing module and the third processing module are arranged in the egress process pipeline engine, and how the first processing module parses the message, obtains and records the information of each layer of message headers in the message is detailed as described above, and will not be repeated here. At the same time, how the second processing module edits each layer of message headers in the message, and updates the recorded information of each layer of message headers after editing is detailed as described above, and will not be repeated here.

[0044] The present invention also discloses a message processing device, including a memory, a processor and a computer program, wherein the computer program is stored in the processor and can be run in the processor, such as a message processing program. When implemented, the processor can implement various steps in the above message processing method when executing the computer program, such as implementing the steps of parsing the message in the outgoing direction of the message, obtaining and recording the information of the message headers of each layer in the message, etc.

[0045] Exemplarily, the computer program may be divided into one or more units, which are stored in the memory and executed by the memory to implement the present invention. The one or more units may be a series of computer program instruction segments capable of implementing specific functions, and the computer program instruction segments are used to describe the execution process of the computer program in the message processing device.

[0046] The present invention also discloses a computer-readable storage medium, in which a computer program is stored, and when the computer program is executed by a processor, the above-mentioned message processing method can be implemented. The computer program includes a computer program code, and the computer program code can be in the form of source code, an executable file or some intermediate form, etc. The computer-readable medium can include any entity or device, recording medium, U disk, mobile hard disk, magnetic disk, optical disk, computer memory, read-only memory (ROM), random access memory (RAM), etc. that can carry the computer program code.

[0047] The present invention improves the message processing process of the export process pipeline engine so that after editing each message header in the message, the recorded information of each layer of message header is updated. This information can be directly used by ACL and IPFIX, and there is no need to set up a separate message parsing module to obtain the information of each layer of edited message headers, thereby reducing the delay of message processing and reducing costs.

[0048] The technical contents and technical features of the present invention have been disclosed as above. However, those skilled in the art may still make various substitutions and modifications based on the teachings and disclosures of the present invention without departing from the spirit of the present invention. Therefore, the protection scope of the present invention should not be limited to the contents disclosed in the embodiments, but should include various substitutions and modifications that do not depart from the present invention and are covered by the claims of this patent application.

Claims

1. A message processing method, characterized in that: The message processing method comprises: In the egress process pipeline engine, the received message is parsed, the information of each layer of the message header in the message is obtained and the information is recorded through the fields; Edit the headers of each layer in the message, and update the recorded information of the headers of each layer after editing; ACL matching and IPFXI matching are performed based on the updated packet header information at each layer.

2. The message processing method according to claim 1, wherein the information includes inner layer 2 message header information, inner layer 3 message header information, outer layer 2 message header information, and outer layer 3 and 4 message header information.

3. According to the message processing method of claim 2, editing the message headers of each layer in the message, and updating the recorded information of the message headers of each layer after editing comprises: From inside to outside, edit the inner layer 3 message header, inner layer 2 message header, outer layer 3 and 4 message headers, and outer layer 2 message header.

4. According to the message processing method of claim 2, editing the message headers of each layer in the message, and updating the recorded information of the message headers of each layer after editing comprises: After editing the inner layer 3 message header, update the recorded inner layer 3 message header information; After editing the inner layer 2 message header, the recorded inner layer 2 message header information is updated; After editing the outer layer 3 and layer 4 message headers, the recorded outer layer 3 and layer 4 message header information is updated; After editing the outer layer 2 message header, the recorded outer layer 2 message header information is updated.

5. A message processing device, characterized in that: The message processing device comprises: The first processing module is used to parse the received message in the egress process pipeline engine, obtain the information of each layer of the message header in the message and record the information through the field; The second processing module is used to edit the message headers of each layer in the message, and update the information of the recorded message headers of each layer after editing; The third processing module is used to perform ACL matching and IPFXI matching according to the updated packet header information of each layer.

6. The message processing device according to claim 5, wherein the information includes inner layer 2 message header information, inner layer 3 message header information, outer layer 2 message header information, and outer layer 3 and 4 message header information.

7. The message processing device according to claim 6, wherein the second processing module edits the inner layer three-layer message header, the inner layer two-layer message header, the outer layer three-layer and four-layer message header, and the outer layer two-layer message header in sequence from the inside to the outside.

8. According to the message processing device according to claim 6, the second processing module updates the recorded information of the inner layer three-layer message header after editing the inner layer two-layer message header, updates the recorded information of the inner layer two-layer message header after editing the inner layer three-layer and four-layer message headers, and updates the recorded information of the outer layer three-layer and four-layer message headers after editing the outer layer two-layer message header.

9. A message processing device, characterized in that: The device comprises: at least one processor; and at least one memory, the at least one memory being coupled to the at least one processor and storing a computer program for execution by the at least one processor, wherein when the computer program is executed by the at least one processor, the apparatus performs the method according to any one of claims 1 to 4.

10. A computer-readable storage medium having a computer program stored thereon, wherein the computer program implements the method according to any one of claims 1 to 4 when executed by a machine.

Citation Information

Patent Citations

  • Method and device for counting VXLAN inner layer virtual machine flux on intermediate switch

    CN104410541A

  • Message access control method, device, equipment and storage medium

    CN113438252A