Tunnel side interface processing method and apparatus, communication device and storage medium

By determining the target tunnel side interface in the 6to4 automatic tunnel scenario and performing decapsulation attribute marking processing, the problem of waste of ACL resources and low forwarding efficiency caused by the routing device to decapsulate all interface marks is solved, and the accuracy of packet forwarding is achieved Improved sex and efficiency.

WO2024234697A1PCT designated stage expired Publication Date: 2024-11-21ZTE CORP

Patent Information

Application Number
PCT/CN2024/071635
Authority / Receiving Office
WO · WO
Patent Type
Applications
Current Assignee / Owner
Priority Date
2023-05-12
Filing Date
2024-01-10
Publication Date
2024-11-21

AI Technical Summary

Technical Problem

In the 6to4 automatic tunneling scenario, the routing device needs to mark decapsulate properties for all interfaces to forward packets, resulting in waste of ACL resources and reduced forwarding efficiency.

Method used

By determining the target tunnel-side interface in the routing device and performing precise marking processing of decapsulating attributes based on its port information, the port configuration information of the tunnel-side interface is dynamically obtained to save ACL resources.

Benefits of technology

The precise marking of the actual exit of the packet tunnel in the 6to4 automatic tunnel scenario is realized, reducing ACL resource consumption and improving packet forwarding efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN2024071635_21112024_PF_FP_ABST
    Figure CN2024071635_21112024_PF_FP_ABST
Patent Text Reader

Abstract

The present application relates to the technical field of optical network communications, and discloses a tunnel side interface processing method and apparatus, a communication device and a storage medium. The tunnel side interface processing method comprises: determining at least one target tunnel side interface, wherein the target tunnel side interface is used for forwarding an IPV6 packet, and the IPV6 packet is encapsulated into an IPV4 packet to be transmitted in an IPV4 tunnel corresponding to the target tunnel side interface; and marking a de-encapsulation attribute of the target tunnel side interface according to port information of the target tunnel side interface.
Need to check novelty before this filing date? Find Prior Art

Description

Tunnel side interface processing method, device, communication equipment and storage medium

[0001] Related applications

[0002] This application claims priority to Chinese patent application No. 202310542502.6 filed on May 12, 2023, the entire contents of which are incorporated by reference into this application. Technical Field

[0003] The present application relates to the field of Internet communication technology, and in particular to a method, apparatus, communication equipment, and storage medium for processing a tunnel side interface. Background Art

[0004] The 6to4 automatic tunnel in Internet communications is an IPv6 conversion and transmission mechanism. In related technologies, routing devices in 6to4 automatic tunnel scenarios need to decapsulate the IPv4 packets obtained by converting the IPv6 packets to obtain the tunnel's destination IP address and forward the packets. However, the actual exit of the tunnel that transmits the packets often cannot be accurately marked. This requires marking the decapsulation attribute on all interfaces of the routing device so that the routing device can perform decapsulation checks on all packets received on any interface. Marking the decapsulation attribute on all interfaces of the routing device means that a large amount of ACL (a mechanism for controlling access rights to resources in a computer system or network) resources will be consumed.

[0005] Summary of the Invention

[0006] The main purpose of this application is to provide a tunnel-side interface processing method, apparatus, communication equipment, and storage medium, aiming to accurately mark the actual exit of the tunnel for transmitting data packets in a 6to4 automatic tunnel scenario, thereby eliminating the need to perform decapsulation attribute marking on all interfaces of the routing device to save ACL resources.

[0007] To achieve the above objectives, an embodiment of the present application provides a method for processing a tunnel-side interface. The method for processing a tunnel-side interface is applied to a routing device, and the method includes:

[0008] Determine at least one target tunnel side interface, the target tunnel side interface is used to forward the IPv6 message, the IPv6 message is encapsulated as an IPv4 message and transmitted in the IPv4 tunnel corresponding to the target tunnel side interface;

[0009] A marking process of decapsulation attributes is performed on the target tunnel side interface according to the port information of the target tunnel side interface.

[0010] In addition, to achieve the above-mentioned purpose, an embodiment of the present application further provides a tunnel-side interface processing device, wherein the tunnel-side interface processing device is applied to a routing device, and the device includes:

[0011] a tunnel module configured to receive first port configuration information and determine the at least one target tunnel-side interface according to the first port configuration information;

[0012] A driver layer, configured to convert the first port configuration information into configuration data of a chip interface;

[0013] The chip sending interface is configured to send the configuration data for marking of decapsulation attributes.

[0014] In addition, to achieve the above-mentioned purpose, an embodiment of the present application further provides another tunnel-side interface processing device, which is applied to a routing device and includes:

[0015] an adaptation layer configured to receive second port configuration information and determine the at least one target tunnel-side interface according to the second port configuration information;

[0016] A driver layer, configured to convert the first port configuration information into configuration data of a chip interface;

[0017] The chip sending interface is configured to send the configuration data for marking of decapsulation attributes.

[0018] Each functional module of the tunnel side interface processing device implements the steps of the tunnel side interface processing method described above during operation.

[0019] In addition, an embodiment of the present application also provides a communication device, which includes: a processing device of the tunnel side interface as described above, a memory, a processor, and a computer program stored on the memory and runnable on the processor, wherein the computer program is configured to implement the steps of the processing method of the tunnel side interface as described above.

[0020] In addition, an embodiment of the present application further provides a storage medium, which is a computer-readable storage medium. A computer program is stored on the storage medium. When the computer program is executed by a processor, the steps of the tunnel side interface processing method as described above are implemented. BRIEF DESCRIPTION OF THE DRAWINGS

[0021] FIG1 is a schematic diagram of the structure of the operating equipment of the hardware operating environment involved in the embodiment of the present application;

[0022] FIG2 is a schematic diagram of a process flow of an embodiment of a method for processing a tunnel side interface according to an embodiment of the present application;

[0023] FIG3 is a schematic diagram of a 6to4 automatic tunnel scenario involved in an embodiment of a method for processing a tunnel-side interface according to an embodiment of the present application;

[0024] FIG4 is a schematic diagram of an application flow involved in an embodiment of a method for processing a tunnel side interface provided by an embodiment of the present application;

[0025] FIG5 is a schematic diagram of another application flow involved in an embodiment of a method for processing a tunnel side interface provided by an embodiment of the present application;

[0026] FIG6 is a schematic diagram of the functional module architecture involved in an embodiment of a tunnel-side interface processing device according to an embodiment of the present application;

[0027] FIG7 is a schematic diagram of the functional module architecture involved in an embodiment of another tunnel-side interface processing device provided in an embodiment of the present application.

[0028] The realization of the objectives, functional features and advantages of this application will be further explained in conjunction with embodiments and with reference to the accompanying drawings. DETAILED DESCRIPTION

[0029] It should be understood that the specific embodiments described herein are only used to explain the present application and are not intended to limit the present application.

[0030] Refer to Figure 1, which is a schematic diagram of the operating equipment structure of the hardware operating environment involved in the embodiment of the present application.

[0031] In this embodiment, the operating device of the hardware operating environment involved in the embodiment of the present application may be a communication device including a processing device of a tunnel side interface, and the communication device may be a routing device in a 6to4 automatic tunnel scenario.

[0032] As shown in Figure 1, the operating device may include: a processor 1001, such as a central processing unit (CPU), a communication bus 1002, a user interface 1003, a network interface 1004, and a memory 1005. Among them, the communication bus 1002 is used to realize the connection and communication between these components. The user interface 1003 may include a display screen (Display), an input unit such as a keyboard (Keyboard), and the user interface 1003 may also include a standard wired interface and a wireless interface. The network interface 1004 may include a standard wired interface and a wireless interface (such as a wireless fidelity (WI-FI) interface). The memory 1005 may be a high-speed random access memory (RAM) memory, or a stable non-volatile memory (NVM), such as a disk memory. The memory 1005 may also be a storage device independent of the aforementioned processor 1001.

[0033] Those skilled in the art will understand that the structure shown in FIG1 does not constitute a limitation on the operating device, and may include more or fewer components than shown, or a combination of certain components, or a different arrangement of components.

[0034] As shown in FIG. 1 , the memory 1005 as a storage medium may include an operating system, a data storage module, a network communication module, a user interface module, and a computer program.

[0035] In the operating device shown in FIG1 , the network interface 1004 is mainly used for data communication with other devices; the user interface 1003 is mainly used for data interaction with the user; the processor 1001 and the memory 1005 in the operating device of the present application can be set in the operating device, and the operating device calls the computer program stored in the memory 1005 through the processor 1001 and performs the following operations:

[0036] Determine at least one target tunnel side interface, the target tunnel side interface is used to forward the IPv6 message, the IPv6 message is encapsulated as an IPv4 message and transmitted in the IPv4 tunnel corresponding to the target tunnel side interface;

[0037] A marking process of decapsulation attributes is performed on the target tunnel side interface according to the port information of the target tunnel side interface.

[0038] Exemplarily, the processor 1001 may call a computer program stored in the memory 1005 and further perform the following operations:

[0039] Find the route based on the IPv4 address in the received IPv6 message;

[0040] When route lookup fails, ARP learning is triggered to determine the at least one target tunnel-side interface.

[0041] Exemplarily, the processor 1001 may call a computer program stored in the memory 1005 and further perform the following operations:

[0042] In the event that route lookup fails, the IPV6 message is reported to the software platform of the routing device to trigger ARP learning, wherein the software platform performs ARP learning by sending an APR request and receiving a response from the peer device to the APR request, and the target tunnel side interface is the routing interface that receives the response from the peer device.

[0043] Exemplarily, the processor 1001 may call a computer program stored in the memory 1005 and further perform the following operations:

[0044] Adding identification information to the IPV6 message, wherein the identification information includes a message sending reason and a message type;

[0045] The IPV6 message with the identification information added is sent to the software platform to trigger ARP learning, so that the software platform can parse the IPV4 address from the IPV6 message according to the message type, and find the route according to the reason for sending the message and the IPV4 address, so as to perform ARP learning when the route search fails.

[0046] Exemplarily, the processor 1001 may call a computer program stored in the memory 1005 to further perform the following operations before performing the operation of determining at least one target tunnel-side interface:

[0047] The port configuration information of the at least one target tunnel side interface is preconfigured through a user-defined interface.

[0048] Exemplarily, the processor 1001 may call a computer program stored in the memory 1005 and further perform the following operations:

[0049] The port configuration information is received, and the at least one target tunnel-side interface is determined according to the port configuration information.

[0050] Exemplarily, the processor 1001 may call a computer program stored in the memory 1005 and further perform the following operations:

[0051] Converting the port information of the target tunnel side interface into configuration data of the chip interface;

[0052] The chip sending interface is called to send the configuration data to perform a marking process of decapsulation attributes on the target tunnel side port.

[0053] Exemplarily, the processor 1001 may call a computer program stored in the memory 1005, and after executing the operation of marking the decapsulation attribute of the target tunnel side interface, further perform the following operations:

[0054] The received IPV6 message is encapsulated into an IPV4 message, and the IPV4 message is forwarded through the target tunnel side interface, so that the opposite device receiving the IPV4 message can confirm whether to decapsulate the IPV4 message according to the decapsulation attribute marked by the target tunnel side interface.

[0055] Based on the operating device structure of the hardware operating environment involved in the above-mentioned embodiment of the present application, the overall concept of the processing method of the tunnel side interface provided by the embodiment of the present application is first proposed.

[0056] In Internet communications, 6to4 automatic tunneling is an IPv6 conversion and transmission mechanism that encapsulates IPv6 packets directly in IPv4 packets and uses the IPv4 address information embedded in the IPv6 address to enable direct transmission over the IPv4 network without explicitly configuring a tunnel.

[0057] In the related art, since the routing device needs to decapsulate the data packet to obtain the tunnel destination IP address and forward the data packet, but the actual exit of the tunnel that transmits the data packet cannot be accurately marked, it is necessary to mark the decapsulation attribute for all interfaces of the routing device so that the routing device can perform decapsulation processing on all data packets received by any interface. Marking the decapsulation attribute for all interfaces of the routing device requires consuming a large amount of ACL resources.

[0058] In response to the above phenomenon, the embodiment of the present application proposes a method for processing the tunnel side interface, which first determines at least one target tunnel side interface for forwarding IPV6 messages through a routing device, wherein the IPV6 message is encapsulated as an IPV4 message and transmitted in the IPV4 tunnel corresponding to the target tunnel side interface; then, the tunnel side interface is marked with decapsulation attributes according to the port information of the target tunnel side interface.

[0059] In this way, compared with the related technology of marking the decapsulation attributes of all interfaces of the routing device in advance, the embodiment of the present application can dynamically obtain the port configuration information of the tunnel side interface during the process of the routing device receiving and forwarding IPV6 messages, so that only a small amount of ACL resources need to be consumed to mark the decapsulation attributes of the tunnel side interface, effectively saving the device ACL resources.

[0060] In addition, because the related art pre-marks all interfaces of a routing device with decapsulation attributes, the peer device of the routing device needs to check whether to decapsulate any message forwarded by the routing device after receiving it. This will seriously affect the forwarding efficiency of messages in tunnel scenarios when some messages do not require decapsulation. However, because the embodiments of the present application do not pre-mark all interfaces of the routing device with decapsulation attributes, the peer device of the routing device can directly forward certain messages that do not require decapsulation. In this way, the embodiments of the present application can also improve the forwarding efficiency of messages.

[0061] Based on the overall concept of the method for processing the tunnel side interface provided by the above-mentioned embodiment of the present application, various embodiments of the method for processing the tunnel side interface of the present application are proposed.

[0062] The tunnel-side interface processing method of the present application is applied to the aforementioned operating device, which may be a communication device including a tunnel-side interface processing device. It should be understood that, based on different design requirements of actual applications, in different feasible embodiments, the tunnel-side interface processing method of the present application can of course also be applied to other terminal devices. To facilitate understanding and explanation of the technical solution, the following text will use the routing device in the 6to4 automatic tunnel scenario as the execution subject of the solution implementation to illustrate the tunnel-side interface processing method of the present application.

[0063] Please refer to Figure 2, which is a flowchart illustrating the steps of the first embodiment of the method for processing a tunnel-side interface of the present application. Although the flowchart shows a logical order, in some cases, the method for processing a tunnel-side interface of the present application can also perform the steps in a different order than shown or described here.

[0064] As shown in FIG2 , in a first embodiment of a method for processing a tunnel side interface of the present application, the method for processing a tunnel side interface provided by the present application may include the following steps:

[0065] Step S10: determining at least one target tunnel side interface, wherein the target tunnel side interface is used to forward the IPv6 message, and the IPv6 message is encapsulated as an IPv4 message and transmitted in the IPv4 tunnel corresponding to the target tunnel side interface;

[0066] In this embodiment, when performing interface attribute marking processing on a tunnel-side interface in a 6to4 automatic tunnel scenario, the routing device first determines at least one target tunnel-side interface that needs to be marked with interface attributes at the current moment from among multiple tunnel-side interfaces.

[0067] In this embodiment and other feasible embodiments, any target tunnel side interface determined by the routing device in the 6to4 automatic tunnel scenario is a tunnel side interface for forwarding IPV6 packets, that is, the routing device encapsulates the IPV6 packet received by the user access side chip into an IPV4 packet and then transmits it in the IPV4 tunnel corresponding to the target tunnel side interface, thereby transmitting the IPV6 packet in the form of an IPV4 packet to the opposite device connected to the IPV4 tunnel (specifically, it can also be a routing device).

[0068] Step S20: Marking the decapsulation attribute of the target tunnel side interface according to the port information of the target tunnel side interface.

[0069] In this embodiment, after the routing device determines at least one target tunnel-side interface that currently requires interface attribute marking, it can further invoke its driver layer and chip-based delivery interface to mark the decapsulation attributes of the target tunnel-side interface based on the port information of the target tunnel-side interface. Thus, after the decapsulation attribute marking process for the target tunnel-side interface takes effect, when the routing device forwards message data through the target tunnel-side interface, the peer device, upon receiving the message data, will further search the tunnel table based on the decapsulation attributes of the target tunnel-side interface to confirm whether decapsulation processing is required for the message data.

[0070] In this way, compared with the traditional technology of pre-marking the decapsulation attribute on all interfaces of the routing device, so that the opposite device needs to check whether the message is decapsulated after receiving any message forwarded by the routing device, the processing method of the tunnel side interface of the present application does not need to pre-mark the decapsulation attribute on all interfaces of the routing device. Therefore, for some messages that do not need to be decapsulated, the opposite device of the routing device can directly forward them, which can effectively improve the forwarding efficiency of the message.

[0071] In one embodiment, in some feasible embodiments of the method for processing a tunnel-side interface of the present application, the operation of "determining at least one target tunnel-side interface" may include:

[0072] Find the route based on the IPv4 address in the received IPv6 message;

[0073] When route lookup fails, ARP learning is triggered to determine the at least one target tunnel-side interface.

[0074] In this embodiment, the routing device can dynamically determine the target tunnel side interface that currently needs to be processed for interface attribute marking during the user's interaction with the IPv6 message in the current 6to4 automatic tunnel scenario. That is:

[0075] The routing device receives the IPv6 message that the user needs to communicate with through its configured user-side chip interface. After receiving the IPv6 message, the routing device parses the address of the user who sent the IPv6 message to determine the IPv4 address in the IPv6 message. The routing device can then use this IPv4 address to find the routing exit for forwarding the IPv6 message.

[0076] If the routing device successfully finds a route using the IPv4 address in the IPv6 packet, it will directly forward the IPv6 packet using the found route. If the routing device fails to find a route using the IPv4 address, it will immediately trigger ARP learning to determine at least one route for forwarding the IPv6 packet, and determine the route as the target tunnel-side interface that currently needs to be marked with interface attributes.

[0077] For example, as shown in FIG3 , in a 6to4 automatic tunnel scenario where the routing device is located, user 1: 2002:a01:101:1::2 communicates with user 2: 2002:b01:101:1::2, the tunnel address of the routing device DUT1 is 2002:a01:101::1, and the tunnel address of the routing device DUT2 is 2002:b01:101::1.

[0078] In this way, when user 1 sends an IPv6 packet with the destination address 2002:b01:101:1::2, it arrives at routing device DUT1. Routing device DUT1 parses 2002:b01:101:1::2 and derives the destination IPv4 address 11.1.1.1. Routing device DUT1 then searches for a route using this IPv4 address. If a route is found, it forwards the packet. If not, it sends the packet to the software platform, triggering ARP learning. After ARP learns that the tunnel-side interface for IPv4 address 11.1.1.1 is gei-0 / 1 / 1 / 1, routing device DUT1 encapsulates the IPv6 packet in IPv4 and forwards it correctly.

[0079] After the encapsulated message reaches router DUT2, if the tunnel-side interface gei-0 / 1 / 1 / 4 is set to decapsulate, router DUT2 will need to decapsulate the message received through this tunnel-side interface to restore the inner IPv6 message. Router DUT2 then forwards the restored IPv6 message to user 2.

[0080] In one embodiment, in some feasible embodiments of the method for processing a tunnel-side interface of the present application, when the routing device fails to look up a route, triggering ARP learning to determine at least one target tunnel-side interface may include:

[0081] In the event that route lookup fails, the IPV6 message is reported to the software platform of the routing device to trigger ARP learning, wherein the software platform performs ARP learning by sending an APR request and receiving a response from the peer device to the APR request, and the target tunnel side interface is the routing interface that receives the response from the peer device.

[0082] In this embodiment, when the routing device fails to find a routing exit using the IPv4 address in the IPv6 message and thus determines that the route search has failed, it can automatically trigger ARP learning by reporting the IPv6 message to a software platform specifically for managing the routing device. That is, the software platform sends an ARP request and receives the response made by the routing device's peer device to the ARP request - the peer device response - to perform ARP learning. In this way, the software platform can use the routing interface (also called the routing exit) on the routing device that receives the peer device's response as the target tunnel-side interface that currently needs to be marked with interface attributes, and inform the routing device of the target tunnel-side interface.

[0083] In one embodiment, in some feasible embodiments of the processing method of the tunnel side interface of the present application, the step of reporting the IPv6 message to the software platform to trigger ARP learning may include:

[0084] Adding identification information to the IPV6 message, wherein the identification information includes a message sending reason and a message type;

[0085] The IPV6 message with the identification information added is sent to the software platform to trigger ARP learning, so that the software platform can parse the IPV4 address from the IPV6 message according to the message type, and find the route according to the reason for sending the message and the IPV4 address, so as to perform ARP learning when the route search fails.

[0086] In this embodiment, when a routing device fails to find a route using the IPv4 address in an IPv6 message and thus reports the IPv6 message to a software platform to automatically trigger ARP learning, the routing device can add identification information including the message sending reason and message type to the IPv6 message while reporting the IPv6 message, and then send the IPv6 message with the added target identification information to the software platform to automatically trigger ARP learning. Based on this, the software platform of the routing device can parse the IPv4 address from the IPv6 message based on the message type in the target identification information, and then, based on the message sending reason and the parsed IPv4 address in the target identification information, search for a route to determine whether the routing device has a routing interface for transmitting the IPv6 message in the 6to4 automatic tunnel scenario in which it is located. If a routing exit is not found using the IPv4 address, thus determining that the route search failed, the routing device sends an ARP request to perform ARP learning.

[0087] For example, as shown in Figure 4, after receiving an IPV6 message through the device's user access side chip, the routing device parses the IPV4 address in the IPV6 address that sent the IPV6 message and uses the IPV4 address to search for a routing exit. If no routing exit is found, the IPV6 message is sent to the routing device's software platform for processing. When the IPV6 message is sent, the reason for sending the message (6to4 tunnel route search failure) and the message type are identified.

[0088] After receiving an IPv6 packet, the routing device's software platform records the packet's source IPv4 address, destination IPv4 address, and source information. Using this destination IPv4 address, the platform then searches for a routing exit on the routing device. If the software platform finds no routing exit and determines that the route search has failed, it triggers ARP learning. Specifically, the software platform sends an ARP request message from gei-0 / 1 / 1 / 1. If the peer device detects that the ARP request message is for the device's IP address, it immediately responds with an ARP reply message. This ARP reply message is sent from gei-0 / 1 / 1 / 4 to gei-0 / 1 / 1 / 1. Upon receiving the ARP reply message, gei-0 / 1 / 1 / 1 recognizes that it is the IP address it wishes to learn, completing the ARP learning process. The software device then records gei-0 / 1 / 1 / 1 as the target tunnel-side interface requiring attribute tagging.

[0089] Finally, after the software platform of the routing device learns the destination IPv4 address information and the target tunnel side interface through ARP learning, it matches the corresponding 6to4 tunnel information by associating the source IPv4 address information, and notifies the tunnel module of the routing device of the tunnel port information it has learned.

[0090] In this embodiment, after determining the target tunnel side interface through ARP learning, the software platform of the routing device can also display information such as the target tunnel side interface and the IPv4 tunnel corresponding to the target tunnel side interface by adding a show command.

[0091] In an embodiment of the present application, the present application first determines at least one target tunnel-side interface for forwarding IPV6 packets through a routing device, wherein the IPV6 packet is encapsulated as an IPV4 packet and transmitted in the IPV4 tunnel corresponding to the target tunnel-side interface; thereafter, the decapsulation attribute of the tunnel-side interface is marked based on the port information of the target tunnel-side interface. Thus, compared with the related art of marking the decapsulation attribute of all interfaces of the routing device in advance, the embodiment of the present application can dynamically obtain the port configuration information of the tunnel-side interface during the process of the routing device receiving and forwarding IPV6 packets, thereby only consuming a small amount of ACL resources to accurately mark the decapsulation attribute of the tunnel-side interface, effectively saving the device ACL resources.

[0092] In one embodiment, in some feasible embodiments of the tunnel-side interface processing method of the present application, in addition to dynamically determining the target tunnel-side interface that currently requires interface attribute tagging during the user's interaction with IPv6 packets in the current 6to4 automatic tunnel scenario, the routing device may also determine the target tunnel-side interface based on a static configuration performed by the user. That is, prior to the aforementioned operation of "determining at least one target tunnel-side interface," the tunnel-side interface processing method of the present application may further include:

[0093] Pre-configuring port configuration information of the at least one target tunnel side interface through a user-defined interface;

[0094] In this embodiment, a user of the routing device (e.g., a staff member) can manually specify one or more tunnel-side ports of the routing device as target tunnel-side interfaces that currently require interface attribute tagging by performing a static configuration operation. That is, the user of the routing device pre-determines one or more target tunnel-side interfaces from the multiple tunnel-side ports of the routing device, and then statically configures the port configuration information of the one or more target tunnel-side interfaces through the user-defined interface, so that the routing device receives the port configuration information through the user-defined interface.

[0095] Based on this, the above operation of "determining at least one target tunnel-side interface" may further include:

[0096] The port configuration information is received, and the at least one target tunnel-side interface is determined according to the port configuration information.

[0097] In this embodiment, after receiving the port configuration information generated by the user performing static configuration through the user-defined interface configured by the routing device, the routing device can determine one or more target tunnel-side interfaces manually specified by the user according to the port configuration information.

[0098] For example, as shown in Figure 5, a worker statically configures one or more tunnel-side interfaces through a user-defined interface configured on the routing device to designate them as target tunnel-side interfaces requiring interface attribute marking. The routing device then receives the port configuration information for these target tunnel-side interfaces and sends it to its adaptation layer. Upon receiving this port configuration information, the adaptation layer parses and identifies the required operations and stores them as data. This data is then sent to the routing device's driver layer for conversion and then dispatched via the chip's dispatch interface to complete the marking of the decapsulation attributes for these target tunnel-side interfaces.

[0099] Based on the first embodiment of the method for processing the tunnel side interface of the present application, a second embodiment of the method for processing the tunnel side interface of the present application is proposed.

[0100] In the second embodiment of the method for processing a tunnel side interface of the present application, the operation of “marking the decapsulation attribute of the target tunnel side interface according to the port information of the target tunnel side interface” may include:

[0101] Converting the port information of the target tunnel side interface into configuration data of the chip interface;

[0102] The chip sending interface is called to send the configuration data to perform a marking process of decapsulation attributes on the target tunnel side port.

[0103] In this embodiment, when the routing device calls its driver layer and chip delivery interface to mark the decapsulation attributes of the target tunnel-side interface based on the port information of the target tunnel-side interface, it can first convert the port information of the target tunnel-side interface into chip interface configuration data by calling the driver layer. This configuration data is recognizable by the chip. The routing device then calls the chip delivery interface to deliver this configuration data, thereby marking the decapsulation attributes of the target tunnel-side port.

[0104] In one embodiment, in some feasible embodiments of the method for processing a tunnel side interface of the present application, after marking the decapsulation attribute of the target tunnel side interface, the method for processing a tunnel side interface of the present application may further include:

[0105] The received IPV6 message is encapsulated into an IPV4 message, and the IPV4 message is forwarded through the target tunnel side interface, so that the opposite device receiving the IPV4 message can confirm whether to decapsulate the IPV4 message according to the decapsulation attribute marked by the target tunnel side interface.

[0106] In this embodiment, after the routing device completes the marking process for the decapsulation attributes of the target tunnel-side interface, it can then normally transmit message data through the target tunnel-side interface. Specifically, after receiving an IPv6 message with which a user needs to interact, the routing device encapsulates the IPv6 message into an IPv4 message in the 6to4 automatic tunnel scenario. The IPv4 message is then transmitted through the target tunnel-side interface to the IPv4 tunnel corresponding to the target tunnel-side interface for forwarding. Thus, upon receiving the IPv4 message, the peer device connected to the IPv4 tunnel can further search the tunnel table based on the decapsulation attributes marked by the target tunnel-side interface to determine whether decapsulation processing is required for the IPv4 message.

[0107] For example, as shown in Figures 4 and 5, after the routing device receives the port configuration information of the target tunnel side interface through the tunnel module or the user-defined interface, the port information is further sent to the driver layer of the routing device. Thereby, the driver layer can convert the port information into port configuration information that can be recognized by the chip, and send the port configuration data by calling the chip sending interface to realize the marking processing of the decapsulation attributes for the target tunnel side port.

[0108] Afterwards, after marking the decapsulation attribute for the target tunnel side port so that the chip configuration takes effect, when the routing device forwards the IPV6 message that the user needs to interact with, it first encapsulates the IPV6 message into an IPV4 message, and transmits the IPV4 message to the IPV4 tunnel corresponding to the target tunnel side interface through the target tunnel side interface to forward the IPV4 message. Furthermore, after the opposite-end device connected to the IPV4 tunnel receives the IPV4 message, since the target tunnel side interface is set with the decapsulation attribute, the opposite-end device needs to look up the tunnel table to confirm whether the IPV4 message needs to be decapsulated. If it is determined that decapsulation is required, the received IPV4 message is decapsulated to restore the inner IPV6 message, and the restored IPV6 is forwarded to the user.

[0109] In an embodiment of the present application, a routing device first determines at least one target tunnel-side interface for forwarding IPv6 packets, and then performs decapsulation attribute marking on the tunnel-side interface based on the port information of the target tunnel-side interface. In this way, the embodiment of the present application can dynamically obtain the port configuration information of the tunnel-side interface, thereby only consuming a small amount of ACL resources to accurately mark the decapsulation attributes of the tunnel-side interface, effectively conserving device ACL resources.

[0110] In addition, an embodiment of the present application further provides a tunnel-side interface processing device, and the tunnel-side interface processing device of the present application is also applied to the routing device described above.

[0111] Referring to FIG. 6 , the tunnel-side interface processing device of the present application may include:

[0112] a tunnel module configured to receive first port configuration information and determine the at least one target tunnel-side interface according to the first port configuration information;

[0113] A driver layer, configured to convert the first port configuration information into configuration data of a chip interface;

[0114] The chip sending interface is configured to send the configuration data for marking of decapsulation attributes.

[0115] In one embodiment, in some feasible embodiments of the processing device of the tunnel side interface of the present application, the processing device of the tunnel side interface of the present application may further include:

[0116] The software platform is configured to send an ARP request and receive a peer device response to the APR request to perform ARP learning to generate the first port configuration information, and the target tunnel side interface is a routing interface that receives the peer device response.

[0117] In addition, an embodiment of the present application also provides another tunnel-side interface processing device, which is also applied to the routing device described above.

[0118] Referring to FIG. 7 , another tunnel-side interface processing device of the present application may include:

[0119] an adaptation layer configured to receive second port configuration information and determine the at least one target tunnel-side interface according to the second port configuration information;

[0120] A driver layer, configured to convert the first port configuration information into configuration data of a chip interface;

[0121] The chip sending interface is configured to send the configuration data for marking of decapsulation attributes.

[0122] In one embodiment, in some feasible embodiments of another tunnel-side interface processing device of the present application, the another tunnel-side interface processing device may further include:

[0123] The user-defined interface is configured to receive a user's static configuration to generate the second port configuration information.

[0124] The tunnel-side interface processing device provided in the embodiment of the present application adopts the tunnel-side interface processing method in the above embodiment to first determine at least one target tunnel-side interface for forwarding IPV6 messages through a routing device, wherein the IPV6 message is encapsulated as an IPV4 message and transmitted in the IPV4 tunnel corresponding to the target tunnel-side interface; thereafter, the tunnel-side interface is subjected to a marking process of decapsulation attributes based on the port information of the target tunnel-side interface. Compared with the related art, the beneficial effects of the tunnel-side interface processing device provided in the embodiment of the present application are the same as the beneficial effects of the tunnel-side interface processing method provided in the above embodiment, and the other technical features of the tunnel-side interface processing device are the same as the features disclosed in the above embodiment method, which will not be described in detail here.

[0125] In addition, an embodiment of the present application also provides a communication device, which includes: a processing device of the tunnel side interface as described above, a memory, a processor, and a computer program stored on the memory and runnable on the processor, wherein the computer program is configured to implement the steps of the processing method of the tunnel side interface as described above.

[0126] In addition, an embodiment of the present application further provides a storage medium, which is a computer-readable storage medium. A computer program is stored on the storage medium. When the computer program is executed by a processor, the steps of the tunnel side interface processing method as described above are implemented.

[0127] As used herein, the terms "comprises," "comprising," or any other variations thereof are intended to encompass non-exclusive inclusion, such that a process, method, article, or system that includes a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such process, method, article, or system. In the absence of further limitations, an element defined by the phrase "comprising a ..." does not preclude the presence of additional identical elements in the process, method, article, or system that includes the element.

[0128] Through the description of the above implementation methods, those skilled in the art can clearly understand that the above-mentioned embodiment methods can be implemented by means of software plus the necessary general hardware platform, and of course can also be implemented by hardware, but in many cases the former is a better implementation method. Based on this understanding, the technical solution of the present application is essentially or the part that contributes to the prior art can be embodied in the form of a software product, which is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk) as described above, and includes a number of instructions for enabling a terminal device (which can be a mobile phone, computer, server or network device, etc.) to execute the methods described in each embodiment of the present application.

[0129] The above are only preferred embodiments of the present application and do not limit the patent scope of the present application. Any equivalent structure or equivalent process transformation made using the contents of the present application specification and drawings, or directly or indirectly applied in other related technical fields, are also included in the patent protection scope of the present application.

Claims

1. A method for processing a tunnel side interface, wherein: Applied to a routing device, the method comprises: Determine at least one target tunnel side interface, the target tunnel side interface is used to forward the IPv6 message, the IPv6 message is encapsulated as an IPv4 message and transmitted in the IPv4 tunnel corresponding to the target tunnel side interface; The target tunnel side interface is subjected to a marking process of decapsulation attributes according to the port information of the target tunnel side interface.

2. The method for processing a tunnel side interface according to claim 1, wherein: Determining at least one target tunnel side interface includes: Find the route based on the IPv4 address in the received IPv6 message; When route lookup fails, ARP learning is triggered to determine the at least one target tunnel-side interface.

3. The method for processing a tunnel side interface according to claim 2, wherein: In the case of a route search failure, triggering ARP learning to determine the at least one target tunnel side interface comprises: In the event of a failure in finding a route, the IPV6 message is reported to the software platform of the routing device to trigger ARP learning, wherein the software platform performs ARP learning by sending an APR request and receiving a response from the peer device to the APR request, and the target tunnel side interface is the routing interface that receives the response from the peer device.

4. The method for processing a tunnel side interface according to claim 3, wherein: Reporting the IPv6 message to the software platform to trigger ARP learning includes: Adding identification information to the IPV6 message, wherein the identification information includes a message sending reason and a message type; The IPV6 message with the identification information added is sent to the software platform to trigger ARP learning, so that the software platform can parse the IPV4 address from the IPV6 message according to the message type, and find the route according to the reason for sending the message and the IPV4 address, so as to perform ARP learning when the route search fails.

5. The method for processing a tunnel side interface according to claim 1, wherein: Before determining at least one target tunnel side interface, the method further includes: Pre-configuring port configuration information of the at least one target tunnel side interface through a user-defined interface; Determining at least one target tunnel side interface includes: The port configuration information is received, and the at least one target tunnel-side interface is determined according to the port configuration information.

6. The method for processing a tunnel side interface according to any one of claims 1 to 5, wherein: The method further comprises: performing a marking process of decapsulating the target tunnel side interface according to the port information of the target tunnel side interface, comprising: Convert the port information of the target tunnel side interface into configuration data of the chip interface; The chip sending interface is called to send the configuration data to perform a marking process of decapsulation attributes on the target tunnel side port.

7. The method for processing a tunnel side interface according to any one of claims 1 to 5, wherein: After performing a marking process of decapsulation attribute on the target tunnel side interface, the method further includes: The received IPV6 message is encapsulated into an IPV4 message, and the IPV4 message is forwarded through the target tunnel side interface, so that the opposite device receiving the IPV4 message can confirm whether to decapsulate the IPV4 message according to the decapsulation attribute marked by the target tunnel side interface.

8. A processing device for a tunnel side interface, wherein: Applied to a routing device, the device comprises: A tunnel module is configured to receive first port configuration information and determine the at least one target tunnel-side interface; A driver layer, configured to convert the first port configuration information into configuration data of a chip interface; The chip sending interface is configured to send the configuration data to perform marking processing of the decapsulation attributes.

9. The processing device of the tunnel side interface according to claim 8, wherein: The device also includes: The software platform is configured to send out an APR request and receive a peer device response to the APR request to perform ARP learning to generate the first port configuration information, and the target tunnel side interface is a routing interface that receives the peer device response.

10. A processing device for a tunnel side interface, wherein: Applied to a routing device, the device comprises: an adaptation layer, configured to receive second port configuration information, and determine the at least one target tunnel side interface according to the second port configuration information; A driver layer, configured to convert the first port configuration information into configuration data of a chip interface; The chip sending interface is configured to send the configuration data to perform marking processing of the decapsulation attributes.

11. The processing device of the tunnel side interface according to claim 10, wherein: The device also includes: The user-defined interface is configured to receive a user's static configuration to generate the second port configuration information.

12. A communication device, wherein: The communication device includes: a processing device for the tunnel side interface as described in claim 8, a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the computer program is configured to implement the steps of the processing method for the tunnel side interface as described in any one of claims 1 to 7.

13. A storage medium, wherein: The storage medium is a computer-readable storage medium, and a computer program is stored on the storage medium. When the computer program is executed by a processor, the steps of the method for processing a tunnel side interface according to any one of claims 1 to 7 are implemented.

Citation Information

Patent Citations

  • Field programmable gate array based tunnel implementing device and method

    CN101136841A

  • Tunnel packet processing method for implementing IPv6 traversing IPv4 based on network processor

    CN101247308A

  • Method for forwarding IPv6 multicast report between 6to4 networks and 6to4 device

    CN101383834A

  • Method and device for preventing generation of automatic tunnel loop

    CN102685271A

  • Message forwarding method and gateway equipment

    CN115914143A

Cited By

  • Network coding erasure correction method and system based on IPv6 tunnel transmission technology

    CN120034293A