Transmission control method and device of SRv6 message, equipment and storage medium
By obtaining and matching the SRv6 traffic conditions in the Flowspec route, the problem that Flowspec technology cannot recognize and control SRv6 traffic is solved, effectively control of SRv6 messages is achieved, and its application scenarios are expanded.
Patent Information
- Application Number
- CN202310764028.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-06-26
- Publication Date
- 2024-12-27
AI Technical Summary
Flowspec technology cannot identify and control SRv6 traffic other than Native IP traffic, resulting in the inability to implement device-side traffic control for SRv6 messages through Flowspec NLRI, which greatly limits its application scenarios.
By obtaining Flowspec routes, including matching conditions and control actions for SRv6 traffic, matching and processing received SRv6 messages, determining their transmission methods, and realizing and controlling SRv6 traffic.
It breaks the limitations of Flowspec technology for identification and control of SRv6 traffic, enriches its application scenarios, and realizes device-side traffic control of SRv6 messages.
Smart Images

Figure CN119211099A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of communication technology, and in particular to a transmission control method, device, equipment and storage medium for SRv6 messages. Background Art
[0002] At present, Flowspec (Flow Specification) technology is limited to traffic matching (traffic identification) and traffic action (traffic control) of IP traffic (for example, IPv4 (Internet Protocol version 4) traffic and IPv6 (Internet Protocol version 6) traffic, etc.), and cannot identify traffic other than Native IP (pure IP) traffic.
[0003] With the deepening of SDN (Software Defined Network) technology, the application of new technologies such as SRv6 (Segment Routing IPv6, segment routing based on IPv6 forwarding plane) will be more extensive. SRv6 is based on IPv6 basic network capabilities and SR (Segment Routing) technology. Through flexible extension header capabilities, it realizes SDN-based network programmability. When transmitting traffic through an SRv6 tunnel, it is necessary to insert a routing extension header SRH (Segment Routing Header) into the IPv6 message after encapsulating the traffic into an IPv6 message to form an SRv6 message. The routing extension header is used to carry segment transmission information to achieve segment routing. However, Flowspec technology is limited to the identification and control of Native IP traffic, and cannot identify the routing extension header of SRv6 traffic, resulting in the inability to implement device-side traffic control for SRv6 messages through Flowspec NLRI (Network Layer Reachability Information) (hereinafter referred to as "Flowspec routing"), which greatly limits its application scenarios.
[0004] Therefore, the Flowspec technology in the related art has limitations in identifying and controlling flow. Summary of the invention
[0005] The main purpose of this application is to provide a transmission control method, device, equipment and storage medium for SRv6 messages, aiming to solve the technical problem that Flowspec technology has limitations in identifying and controlling traffic.
[0006] To achieve the above object, the present application provides a transmission control method of an SRv6 message, which is applied to a routing device and includes the following steps:
[0007] Obtain a Flowspec route, where the Flowspec route includes a first flow matching condition configured for SRv6 flow, and a flow control action corresponding to the first flow matching condition;
[0008] Based on the first traffic matching condition, matching the currently received message to obtain a target SRv6 message;
[0009] Based on the flow control action, a transmission mode of the target SRv6 message is determined.
[0010] The present application also provides a transmission control device for an SRv6 message, the device comprising:
[0011] A route receiving module, configured to obtain a Flowspec route, wherein the Flowspec route includes a first flow matching condition configured for SRv6 flow, and a flow control action corresponding to the first flow matching condition;
[0012] A matching module, configured to match the currently received message based on the first traffic matching condition to obtain a target SRv6 message;
[0013] A control module is used to determine a transmission mode of the target SRv6 message based on the flow control action.
[0014] The present application also provides a SRv6 message transmission device, the device comprising: a memory, a processor, and a SRv6 message transmission program stored in the memory and executable on the processor, the SRv6 message transmission program being configured to implement the steps of the SRv6 message transmission control method as described in any one of the above items.
[0015] The present application also provides a storage medium, on which a transmission program for an SRv6 message is stored. When the transmission program for the SRv6 message is executed by a processor, the steps of the SRv6 message transmission control method as described in any one of the above items are implemented.
[0016] The present application provides a transmission control method for SRv6 messages. Compared with the Flowspec technology in the related art, which is limited to the identification and control of Native IP traffic, it has no identification capability for such SRv6 traffic, resulting in the inability to implement device-side traffic control for SRv6 messages through Flowspec routing, which greatly limits its application scenarios. The present application obtains a Flowspec route, and the Flowspec route includes a first traffic matching condition configured for SRv6 traffic, and a traffic control action corresponding to the first traffic matching condition; based on the first traffic matching condition, the currently received message is matched to obtain a target SRv6 message; based on the traffic control action, the transmission mode of the target SRv6 message is determined. Since the first traffic matching condition in the Flowspec route and the traffic control action corresponding to the first traffic matching condition are both configured for the SRv6 traffic, the target SRv6 message can be identified through the first traffic matching condition in the Flowspec route, and the identification and processing of the SRv6 message can be realized based on the traffic control action corresponding to the first traffic matching condition. Break the limitations of the Flowspec technology on the identification and control of SRv6 traffic. BRIEF DESCRIPTION OF THE DRAWINGS
[0017] Figure 1 A flowchart of a first embodiment of a transmission control method for SRv6 messages of the present application;
[0018] Figure 2 A schematic diagram of a first scenario of the SRv6 message transmission control method of the first embodiment of the present application;
[0019] Figure 3 A schematic diagram of a second scenario of the SRv6 message transmission control method of the first embodiment of the present application;
[0020] Figure 4 A schematic diagram of a third scenario of the SRv6 message transmission control method of the first embodiment of the present application;
[0021] Figure 5 A schematic diagram of a fourth scenario of the SRv6 message transmission control method of the first embodiment of the present application;
[0022] Figure 6 A schematic diagram of a fifth scenario of the SRv6 message transmission control method of the first embodiment of the present application;
[0023] Figure 7 This is a schematic diagram of the sixth scenario of the SRv6 message transmission control method of the second embodiment of the present application;
[0024] Figure 8It is a structural diagram of a transmission control device for SRv6 messages in a hardware operating environment involved in an embodiment of the present application;
[0025] Fig. 9 This is a schematic diagram of a transmission control device for SRv6 messages according to the first embodiment of the present application.
[0026] The realization of the purpose, functional features and advantages of this application will be further explained in conjunction with embodiments and with reference to the accompanying drawings. DETAILED DESCRIPTION
[0027] It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application. Although the terms first, second, third, etc. may be used herein to describe various information, these information should not be limited to these terms. These terms are only used to distinguish the same type of information from each other. For example, without departing from the scope of this article, the first information may also be referred to as the second information, and similarly, the second information may also be referred to as the first information.
[0028] The present application embodiment provides a method for controlling the transmission of an SRv6 message, referring to Figure 1 In this embodiment, the transmission control method of the SRv6 message includes:
[0029] Step S10: Acquire a Flowspec route, where the Flowspec route includes a first flow matching condition configured for SRv6 flow, and a flow control action corresponding to the first flow matching condition;
[0030] Step S20: Based on the first traffic matching condition, matching the currently received message to obtain a target SRv6 message;
[0031] Step S30: Based on the flow control action, determine the transmission mode of the target SRv6 message.
[0032] As an example, the transmission control method of the SRv6 message is applied to the transmission control device of the SRv6 message, the transmission control device of the SRv6 message is subordinate to the transmission control equipment of the SRv6 message, the transmission control equipment of the SRv6 message may be a routing device, and the routing device may be a router.
[0033] With the deepening of SDN (Software Defined Network) technology, the application of new technologies such as SRv6 (Segment Routing IPv6, segment routing based on IPv6 forwarding plane) will be more extensive. SRv6 is based on IPv6 basic network capabilities and SR (Segment Routing) technology. Through flexible extension header capabilities, it realizes SDN-based network programmability. When transmitting traffic through an SRv6 tunnel, it is necessary to insert a routing extension header SRH (Segment Routing Header) into the IPv6 message after encapsulating the traffic into an IPv6 message to form an SRv6 message. The routing extension header is used to carry segment transmission information to achieve segment routing. However, Flowspec technology is limited to the identification and control of Native IP traffic, and cannot identify the routing extension header of SRv6 traffic, resulting in the inability to implement device-side traffic control for SRv6 messages through Flowspec NLRI (Network Layer Reachability Information) (hereinafter referred to as "Flowspec routing"), which greatly limits its application scenarios.
[0034] Specifically, Flowspec technology is currently used for policy routing of the inbound port of the routing device. By receiving the remote Flowspec route and applying it to the corresponding port of the device, traffic match (traffic matching conditions) and traffic action (traffic control actions) are designed for the IP traffic inbound to the Global or VPN (Virtual Private Network) port, which are used for accurate identification of traffic and policy execution respectively. When the traffic enters the inbound port of the routing device, it will be matched by the traffic matching conditions of the Flowspec route. If all the matching items are matched, the traffic forwarding action will be executed according to the traffic control action of the Flowspec route; if any item does not meet the traffic matching condition requirements, the match is not matched, and the forwarding action will be executed according to the forwarding table pre-configured by the routing device.
[0035] As an example, Figure 2As shown in the figure, the destination address (DA) of the inbound traffic of the device is 12.12.12.1 / 24, the source address (SA) is 10.10.10.1 / 24, and the DSCP (Differentiated Services Code Point) value is equal to 10; based on the forwarding table pre-configured by the routing device, the next hop is the egress port A; when the routing device receives the Flowspec route, it matches the IP traffic based on the destination address, source address and DSCP in the Flowspec route; the corresponding flow control action includes at least one of the following:
[0036] 1) Redirection: the forwarding table can be ignored and the new next hop can be selected as the egress port B specified in the Flowspec route;
[0037] 2) Remark: the DSCP value in the forwarded message can be rewritten to 20;
[0038] 3) Rate limit: You can define the upper limit of the traffic rate, the size of the data content, etc.
[0039] This embodiment aims to add a first flow matching condition configured for SRv6 flow in the Flowspec route, and a flow control action corresponding to the first flow matching condition. When a message is received, the SRv6 flow can be hit and the transmission of the message can be controlled, thereby realizing device-side flow control for the SRv6 message, enriching the application scenarios of the Flowspec technology.
[0040] The specific steps are as follows:
[0041] Step S10: Acquire a Flowspec route, where the Flowspec route includes a first flow matching condition configured for SRv6 flow, and a flow control action corresponding to the first flow matching condition;
[0042] As an example, the Flowspec route is sent to a local routing device through a Flowspec server (Flowspec server).
[0043] As an example, the Flowspec route includes a first flow matching condition configured for SRv6 flow, and a flow control action corresponding to the first flow matching condition.
[0044] As an example, the network layer reachability information includes an address family and a sub-address family. The address family is a configuration module of a network layer protocol, which is used to classify and configure different types of networks to facilitate the management of different network types.
[0045] like Figure 3 The encapsulation structure of FSv2 (FSv2, Flowspec Technology Version 2) BGP NLRI shown in the figure encapsulates data through TLVs in the existing Flowspec Version 2 (Flowspec routing) design. TLV is a combination of Type-Length-Value, where Type indicates the type of information carried in this structure; Value indicates the information carried by TLV; Length indicates the valid byte length of the "Value" field. TLV can be a nested structure, and the nested TLV is called a sub-TLV. Each sub-TLV can be used as a traffic matching condition. The FSv2 can realize the recognition capability of IPv4, IPv6, VPNv4 (Virtual Private Network version 4) and VPNv6 (VirtualPrivate Network version 6), but has no recognition capability for SRv6 traffic.
[0046] Specifically, the definitions of the fields in the existing FSv2 BGP NLRI (Flowspec routing) are as follows: Figure 3 As shown:
[0047] 1) total-length: includes the length of all Sub-TLVs fields;
[0048] 2)order: the order of traffic matching conditions;
[0049] 3) identifier: identifier of the flow control action;
[0050] 4) type: an identifier of a Flowspec route in FSv2 TLV format.
[0051] 5)length-Subtlv: length of the Sub-TLV field;
[0052] 6) value: the value contained in the Sub-TLV.
[0053] The type field in the existing FSv2 BGP NLRI (Flowspec routing) is set as follows:
[0054] -0-reserved field;
[0055] -1-IP traffic rules: IP traffic rules (traffic matching conditions for IP traffic);
[0056] -2-L2 traffic rules: data link layer traffic rules;
[0057] -3-SFC traffic rules: service chain traffic rules;
[0058] -4-SFC VPN traffic rules: VPN service chain traffic rules;
[0059] -5-BGP / MPLS VPN IP traffic rules: BGP, MPLS (Multi-Protocol Label Switching), VPN, IP traffic rules;
[0060] -6-BGP / MPLS VPN L2 traffic rules: BGP, MPLS, VPN, L2 traffic rules.
[0061] In this embodiment, the Flowspec route further includes a route distinguisher, and the route distinguisher is used to identify VPN traffic.
[0062] As an example, the original traffic matching condition for VPN traffic is replaced by setting the route distinguisher in the existing FSv2 BGP NLRI, that is, the type field related to VPN traffic is removed, and the VPN traffic is identified by the route distinguisher.
[0063] Specifically, the type field is designed as follows in this embodiment:
[0064] -0 - reserved field,
[0065] -1-L2(Ether or VPN) traffic match;
[0066] -2-L3 (IP or VPN) traffic match: network layer traffic rules;
[0067] -3-MPLS traffic match;
[0068] -4-SRv6 traffic match: SRv6 (Segment Routing IPv6, segment routing based on IPv6 forwarding plane) traffic rules;
[0069] -5-reserved for EVPN: EVPN (Ethernet Virtual Private Network) traffic rules.
[0070] As an example, SRv6 traffic match is the first traffic matching condition configured for SRv6 traffic.
[0071] Step S20: Based on the first traffic matching condition, matching the currently received message to obtain a target SRv6 message;
[0072] Since SRv6 is based on IPv6 basic network capabilities and SR (Segment Routing) technology, it implements SDN-based network programmability through flexible extension header capabilities. When transmitting traffic through an SRv6 tunnel, it is necessary to insert a routing extension header SRH (Segment Routing Header) into the IPv6 message after encapsulating the traffic into an IPv6 message to form an SRv6 message. The routing extension header is used to carry segment transmission information to implement segment routing. SRv6 messages are significantly different from traditional IP messages.
[0073] In this embodiment, the SRv6 traffic includes SRv6 Policy traffic, the target SRv6 message includes an SRv6 Policy message corresponding to the SRv6 Policy traffic, and a routing extension header is encapsulated in the SRv6 Policy message.
[0074] In this embodiment, the SRv6 traffic also includes SRv6 BE (Best Effort) traffic, and the target SRv6 message also includes an SRv6 BE message corresponding to the SRv6 BE traffic, and the SRv6 BE message is encapsulated with an IPv6 header.
[0075] As an example, compared with the transmission of SRv6 Policy traffic, the encapsulation of the corresponding message of SRv6 BE traffic lacks a routing extension header. Therefore, this embodiment designs corresponding traffic matching conditions based on SRv6 BE traffic and SRv6 Policy traffic, respectively, to achieve the identification of SRv6 traffic.
[0076] In this embodiment, for SRv6 Policy traffic, the matching item in the first traffic matching condition includes at least one of the following:
[0077] Next Header field in the Routing extension header;
[0078] The segment list field in the routing extension header;
[0079] The type field of the segment identifier in the routing extension header;
[0080] The partial segment identifier field in the routing extension header;
[0081] The remaining segments field in the routing extension header;
[0082] The Flags field in the routing extension header;
[0083] The Tag field in the routing extension header.
[0084] As an example, during the SRv6 message forwarding process, the IPv6 header encapsulated in the routing extension header is encapsulated with a Next Header field. Generally, the Next Header defaults to 43. The Next Header field is used to identify other routing extension headers after the basic IPv6 header. There can be 0, 1 or more routing extension headers. All routing extension headers have a Next Header field. The value of the Next Header field represents the different message types after the routing extension header. Therefore, the Next Header field in the routing extension header can be used as a match item for the first traffic matching condition for the SRv6 Policy traffic.
[0085] As an example, by default, the value of the SID (Segment Identifier) corresponds to the destination address (Destination Address, DA) in the IPv6 header, and the value of the segment identifier can be selected through the segment list (Segment List, SL) to determine the destination address of the SRv6 message; therefore, the segment list field in the routing extension header can be used as a match item for the first traffic matching condition for SRv6 Policy traffic.
[0086] As an example, there are multiple types of segment identifiers, including END (corresponding to the address of the routing device), END.X (corresponding to the address of the transmission link), END.DT (corresponding to the VPN address), END.DX (corresponding to the VPN link address), etc.; therefore, the type field of the segment identifier in the routing extension header can be used as a matching item for the first traffic matching condition for SRv6 Policy traffic.
[0087] It should be noted that, when the local routing device does not have the ability to identify the segment identifier notification sent by the remote end, the matching item of the type field of the segment identifier in the routing extension header is defined as a miss.
[0088] As an example, the draft <draft-ietf-idr-flowspec-srv6-02>The partial segment identifier field in the routing extension header is used as the matching item of the first traffic matching condition for the SRv6 Policy traffic, and this embodiment continues to use this matching item. By default, for the destination address in the IPv6 header, the IPv6 address is 128 bits, and the SRv6 SID is also a 128-bit value, in the form of an IPv6 address, consisting of three parts: locator, Function, and Argument. Locator: has a positioning function, provides IPv6 routing capabilities, and implements addressing forwarding through this field; Function: is used to characterize the forwarding action that needs to be performed, and different forwarding lines correspond to different Functions; Arguments: supplements the Function and specifies the corresponding parameters during execution. Therefore, by identifying the partial segment identifier field in the routing extension header, the corresponding SRv6 Policy traffic can be matched.
[0089] As an example, the Segment Left field is used to identify the index of the current segment identifier. Therefore, the Segment Left field in the routing extension header can be used as a matching item for the first traffic matching condition for the SRv6 Policy traffic.
[0090] As an example, the Flags field is used to identify the type of the message. Therefore, the Flags field in the routing extension header can be used as a matching item of the first traffic matching condition for the SRv6 Policy traffic.
[0091] As an example, the Tag field is used to identify packets of the same class or the same group. Therefore, the Tag field in the routing extension header can be used as a matching item of the first traffic matching condition for SRv6 Policy traffic.
[0092] As an example, based on the first traffic matching condition, the currently received message is matched, and if the currently received message can hit the field corresponding to at least one of the above matching items, it is determined that the message is a target SRv6 message.
[0093] As an example, the flow control actions in the original Flowspec technology include rate-limit, remark, and redirect.
[0094] In this embodiment, the redirection action is designed only based on the characteristics of the SRv6 message.
[0095] As an example, in order to facilitate transmission control of the SRv6 Policy message, this embodiment designs a flow control action corresponding to the first flow matching condition for the SRv6 Policy message.
[0096] In this embodiment, the traffic control action includes a first redirection action configured for the SRv6 Policy traffic, and the first redirection action includes at least one of the following:
[0097] The action of popping up the routing extension header is used to remove the routing extension header of the SRv6 Policy message, encapsulate the preset segment identifier into the IPv6 header of the SRv6 Policy message, and iterate the SRv6 Policy message to the forwarding process of the SRv6 BE traffic by querying the forwarding table (that is, changing the message type), and the forwarding process is mapped with the target port of the target SRv6 message (based on the forwarding process of the SRv6BE traffic, the SRv6 Policy message is forwarded to the target port to realize the transmission control of the message).
[0098] It should be noted that the action of popping the routing extension header is applicable to public network forwarding scenarios. For VPN scenarios, after the routing extension header is popped, the SRv6 Policy message cannot be forwarded only through the inner address.
[0099] A remaining segment rewrite action is used to modify the value of the remaining segment in the SRv6 Policy message, wherein the modified remaining segment value indicates a corresponding segment identifier, and the segment identifier is mapped with a target port of the target SRv6 message (the value of the segment identifier corresponds to the destination address in the IPv6 header, and based on the specified segment identifier, the destination address of the SRv6 Policy message is changed to implement message transmission control);
[0100] The Tag value modification action is used to modify the Tag value in the SRv6 Policy message, where the Tag value indicates the message type of the SRv6 Policy message, and the message type is mapped with the data type of the target SRv6 message (by modifying the Tag value, the data type of the target SRv6 message is changed, thereby changing the processing flow of the target SRv6 message by other routing devices, thereby realizing message transmission control).
[0101] The segment identifier modification action is used to delete, add or change the segment identifier in the segment list, and the segment identifier is mapped with the target port of the target SRv6 message (by deleting, adding or changing the segment identifier, the target port of the target SRv6 message is changed).
[0102] In this embodiment, for SRv6 BE traffic, the matching item in the first traffic matching condition further includes a destination address (DA) field in the IPv6 header.
[0103] As an example, in order to facilitate transmission control of the SRv6 BE message, this embodiment designs a flow control action corresponding to the first flow matching condition for the SRv6 BE message.
[0104] In this embodiment, the traffic control action further includes a second redirection action configured for the SRv6 BE traffic, and the second redirection action includes at least one of the following:
[0105] An IPv6 header pop-up action is used to remove the IPv6 header of the SRv6 BE message, and query a forwarding table based on the destination IP address in the payload, wherein the forwarding table maps the destination port of the target SRv6 message (by removing the IPv6 header of the SRv6 BE message, changing the data type of the SRv6 BE message, thereby changing the destination port of the target SRv6 message, and realizing message transmission control);
[0106] A source address modification action, used to modify the source address in the SRv6 BE message, so that other routing devices can determine whether to receive the SRv6 BE message based on the source address (by modifying the source address in the SRv6 BE message, changing the processing flow of the SRv6 BE message by other routing devices, and realizing message transmission control);
[0107] The destination address modification action is used to modify the destination address of the IPv6 header in the SRv6 BE message, and the destination address is mapped with the destination port of the target SRv6 BE message (by modifying the destination address, changing the destination port of the target SRv6 BE message, the transmission control of the message is realized).
[0108] Step S30: Based on the flow control action, determine the transmission mode of the target SRv6 message.
[0109] As an example, after determining the target SRv6 message, the target SRv6 message may be controlled for transmission based on the flow control action corresponding to the first flow matching condition.
[0110] As an example, Figure 4 As shown, the routing devices include: R1, R2, R3, R4, and R5. IS-IS, BGP and other routing protocols are configured between the routing devices, and the configuration of each forwarding path is the same. SRv6 is enabled, and SRv6 related information and VPN related information are configured. Among them, END(Rn) represents the END SID (destination address) information of routing device Rn (number of routing device), END.X(Rn to Rm) represents the END.X SID (address of destination transmission link) information from routing device Rn to Rm, and END.DX(Rn) represents the END.DX SID (destination VPN link address) information corresponding to routing device Rn.
[0111] When the inbound port of the routing device R1 receives SRv6 traffic: the inbound public network port Int1 of the routing device R1 receives an SRv6 BE message encapsulated with IPv6 DA=END.DX(R5) (the destination address is the VPN link corresponding to the routing device R5).
[0112] Assume that Flowspec route 1 includes: Sub-TLV type=4, the matching item in the first traffic matching condition includes a partial segment identifier field (constraining Locator and Function values); the corresponding traffic control action includes a pop-up IPv6 header action (for SRv6 BE traffic).
[0113] Flowspec route 2 includes: Sub-TLV type=4, the matching items in the first flow matching condition include SIDtype=END.DX SID (the type field of the segment identifier is the VPN link address), and the corresponding flow control action includes the destination address modification action: IPv6 DA=END.DX(R5) (modify the IPv6 destination address encapsulated in the SRv6 BE message to the VPN link address corresponding to the routing device R5).
[0114] When the Flowspec route is not received, the public network port Int1 of routing device R1 receives the SRv6 BE message corresponding to the SRv6BE traffic in the inbound direction, and by querying the IPv6 forwarding table, the destination address in the outer IPv6 header is routing device R5. Routing device R5 pops out the outer IPv6 header of the SRv6 BE message, and iterates based on the modified END.DX (VPN link address) to send the SRv6 BE message with the outer IPv6 header popped out from the outbound port Int2 based on the local forwarding table.
[0115] When receiving the route of Flowspec route 1, verify the validity of Flowspec route 1 and apply it to the inbound port Int1. The inbound port of routing device R1 receives SRv6 BE traffic and determines the traffic matching condition as the first traffic matching condition corresponding to SRv6 based on the Sub-TLV type=4 field. Based on the corresponding values of the Locator field and the Function field in the first traffic matching condition, hit the END.DX(R5) (VPN link address corresponding to routing device R5) field. Correspondingly, the IPv6 header pop-up action is performed. On the forwarding plane, routing device R1 queries the forwarding table based on the destination IP address in the payload to complete the forwarding.
[0116] As an example, verify the validity of the Flowspec route: first, the traffic matching condition is required to include the destination prefix of the network layer. Second, if the traffic control action includes redirect IP, the redirection destination address is required to come from the unicast BGP route published by the Flowspec server.
[0117] When Flowspec route 2 is received, the validity of Flowspec route 2 is checked and applied to the inbound port Int1. The inbound port of routing device R1 receives SRv6 BE traffic and determines that the traffic matching condition is the first traffic matching condition corresponding to SRv6 based on the Sub-TLV type=4 field. Based on the SID type=END.DX field in the first traffic matching condition, the END.DX(R5) field is hit. The destination address modification action is performed accordingly, and the IPv6 destination address encapsulated in the SRv6 BE message is modified to the VPN link address corresponding to routing device R5. On the forwarding plane, routing device R1 queries the IPv6 forwarding table and forwards the SRv6 BE message to routing device R5 based on the destination address in the outer IPv6 header. Since the destination address is the VPN link address corresponding to R5, routing device R5 needs to pop out the outer IPv6 encapsulation and iterate based on the modified END.DX to send the SRv6 BE message with the outer IPv6 header popped out from the outbound port Int3 based on the local forwarding table.
[0118] As an example, Figure 5 As shown, the inbound port of routing device R1 receives an SRv6 Policy message with a destination IPv6 address of R1 and SL=4 (the segment list field is 4), and based on SID (4) to SID (0), determines the forwarding path to be R1-R2-R4-R5, and sends it to the private network egress port (VPN link) of R5.
[0119] Assume that Flowspec route 3: Sub-TLV type = 4, and the matching item in the first traffic matching condition includes SL = 4. The corresponding traffic control action includes popping the route extension header action, and assigning SID (0) = END.DT (R5) to the IPv6 DA (iterating the SRv6 Policy message to the forwarding process of the SRv6 BE traffic).
[0120] Flowspec route 4: Sub-TLV type=4, the matching item in the first flow matching condition includes SID(0)type=END.X. The corresponding flow control action includes a segment left (SL) rewrite action.
[0121] When the Flowspec route is not received, the inbound port Int1 of the routing device R1 receives the SRv6 Policy traffic. The destination address in the outer IPv6 header hits the local segment list, SL-1=3 is executed, and the DA in the IPv6 header is updated to SID(3)=END(R2). The next hop node is the routing device R2, and the SRv6Policy traffic is forwarded from R1 to R2. Similarly, the SRv6Policy traffic is forwarded from R2 to R4 and R5. Finally, R5 performs the action of popping up the routing extension header, iterates the SRv6 Policy message to the forwarding process of the SRv6 BE traffic, and sends it out from the private network egress port Int2. The overall traffic forwarding path is R1-R2-R4-R5.
[0122] When receiving Flowspec route 3, check the validity of Flowspec route 3 and apply it to the inbound port Int1; determine the traffic matching condition as the first traffic matching condition corresponding to SRv6 based on the Sub-TLV type=4 field. Based on the SL=4 field in the first traffic matching condition, hit the SRv6 Policy traffic. Correspondingly, perform the action of popping up the routing extension header, and assign SID(0) to IPv6DA=END.DT(R5). On the forwarding plane, routing device R1 queries the forwarding table to iterate the SRv6 Policy message to the forwarding process of the SRv6 BE traffic, and transmits it to routing device R5, which performs the pop-up of the outer IPv6 header of the SRv6 BE message. Routing device R5 completes the pop-up of the outer IPv6 encapsulation, and iterates based on END.DT to send the SRv6 BE message with the outer IPv6 header popped out from the outbound port Int2 based on the local forwarding table.
[0123] When receiving the route of Flowspec route 4, the validity of Flowspec route 4 is checked and applied to the inbound port Int1. The inbound port of routing device R1 receives SRv6 Policy traffic and determines the traffic matching condition as the first traffic matching condition corresponding to SRv6 based on the Sub-TLV type=4 field. Based on the SID(1)type=END.X field in the first traffic matching condition, the SRv6 Policy traffic is hit. Correspondingly, the remaining segment rewrite action is performed, and SL=4 is rewritten to SL=1, that is, IPv6DA=END.X (R4 to R5) is assigned. On the forwarding plane, routing device R1 executes SL=1 based on the local segment list, updates the DA in the IPv6 header to SID(1)=END.X(R4 to R5), and the next hop node is R4. Then, the SRv6 Policy traffic is forwarded to R5 via R4. Routing device R5 pops out the outer IPv6 encapsulation and, based on END.DT iteration, sends the SRv6 BE message with the outer IPv6 header popped out from the egress port Int2 based on the local forwarding table.
[0124] As an example, Figure 6 As shown, the inbound port of routing device R1 receives SRv6 traffic: the destination IPv6 address is R1 END.SID, SL=4 (the segment list field is 4), and based on SID(4) to SID(0), the forwarding path is determined to be R1-R2-R4-R5, and the SRv6 Policy message is sent to the private network egress port (VPN link) of R5.
[0125] Assume Flowspec route 5: Sub-TLV type = 4, the matching item in the first flow matching condition includes LOC (Locator) = END (R1) of IPv6DA, and the default SID is the DA in the current IPv6 header. The corresponding flow control action includes deleting the SID (3).
[0126] Flowspec route 6: Sub-TLV type=4, the matching item in the first flow matching condition includes SID(1)type=END.X, and the corresponding flow control action includes inserting SID(3)=END.X before SID(2) (R3 to R4).
[0127] Flowspec route 7: Sub-TLV type=4, the matching item in the first flow matching condition includes SID(1)type=END.X, and the corresponding flow control action includes making SID(3)=END.X (R1 to R3).
[0128] When the routing device R1 does not receive a Flowspec route and the ingress port Int1 of the routing device R1 receives SRv6 Policy traffic, the destination address in the outer IPv6 header hits the local segment list, SL-1 = 3 is executed, the DA in the IPv6 header is updated to SID(3) = END(R2), and the next-hop node is the routing device R2. Then, the SRv6 Policy traffic is forwarded from R1 to R2. Similarly, the SRv6 Policy traffic is forwarded from R2 to R4 and R5. Finally, R5 executes the action of popping the routing extension header, iterates the SRv6 Policy packet to the forwarding process of the SRv6 BE traffic, and sends it out from the private network egress port Int2. The overall traffic forwarding path is R1-R2-R4-R5.
[0129] When receiving the Flowspec route 5, verify the validity of the Flowspec route 5 and apply it to the ingress port Int1; determine that the traffic matching condition is the SRv6 corresponding to the first traffic matching condition based on the Sub-TLV type = 4 field. Based on the LOC = END(R1) field in the first traffic matching condition, the SRv6 Policy traffic is hit. Correspondingly, execute the action of deleting SID(3). On the forwarding plane, the routing device R1 queries the forwarding table and judges the sizes of m and n in SID(n) and SL = m in the action item. (If n < m, then execute SL-1-1 = 2; if n ≥ m, then execute SL-1 = 3). The DA in the IPv6 header is updated to SID(2) = END(R4), that is, the next-hop node is R4. And because of the lower metric value (the metric value is a variable value obtained after the routing selection protocol algorithm is completed, such as the number of routers passed through, bandwidth, etc.), it is determined that the next-hop node is R3. Then, the SRv6 Policy traffic is forwarded from R1 through R3 and R4 to R5. Finally, R5 executes the popping of the outer IPv6 encapsulation, and iterates based on END.DT to send out the SRv6 Policy packet with the outer IPv6 header popped from the egress port Int2 based on the local forwarding table. The overall traffic forwarding selects a path with lower resource consumption and changes to R1-R3-R4-R5.
[0130] When receiving Flowspec route 6, verify the validity of Flowspec route 6 and apply it to the inbound port Int1; the inbound port of routing device R1 receives SRv6 Policy traffic and determines the traffic matching condition as the first traffic matching condition corresponding to SRv6 based on the Sub-TLV type=4 field. Based on the SID(1)type=END.X field in the first traffic matching condition, the SRv6 Policy traffic is hit. Correspondingly, a new SID(3)=END.X(R3 to R4) is added. On the forwarding plane, routing device R1 executes SL-1=3 based on the local segment list, and the DA in the IPv6 header is updated to SID(3)=END.X(R3 to R4). If the next hop node is R3, the traffic is forwarded from R1 to R2. After adding SID (3), the traffic will be forwarded from R2 to R3, and then forwarded to R4 and R5 based on END.X (R3 to R4). Finally, R5 pops the outer IPv6 encapsulation and sends the SRv6 BE message with the outer IPv6 header popped out from the egress port Int2 based on the iteration of END.DT based on the local forwarding table. The overall traffic forwarding chooses the path with lower resource consumption and changes to R1-R2-R3-R4-R5.
[0131] When receiving Flowspec route 7, the validity of Flowspec route 7 is verified and applied to the inbound port Int1; the inbound port of routing device R1 receives SRv6 Policy traffic and determines that the traffic matching condition is the first traffic matching condition corresponding to SRv6 based on the Sub-TLV type=4 field. Based on SID(1)=END(R4) in the first traffic matching condition, the SRv6 Policy traffic is hit. The action of assigning SID(3) to END.X(R1 to R3) is executed accordingly. On the forwarding plane, routing device R1 executes SL-1=3 based on the local segment list, updates the DA in the IPv6 header to SID(3)=END.X(R1 to R3), and the next hop node is R3, so the traffic is forwarded from R1 to R3. Continue to reach R5 through R4 through Policy iteration, and finally R5 completes the pop-up of the outer IPv6 encapsulation, and based on the END.DT iteration, the SRv6BE message with the outer IPv6 header popped out is sent from the outbound port Int2 based on the local forwarding table. The overall traffic forwarding chooses a path with lower resource consumption and is changed to R1-R3-R4-R5.
[0132] In this embodiment, a Flowspec route is obtained through a routing device, and the Flowspec route includes a first traffic matching condition configured for SRv6 traffic, and a traffic control action corresponding to the first traffic matching condition; based on the first traffic matching condition, the currently received message is matched to obtain a target SRv6 message; based on the traffic control action, the transmission mode of the target SRv6 message is determined. Since the first traffic matching condition in the Flowspec route and the traffic control action corresponding to the first traffic matching condition are both configured for the SRv6 traffic, the target SRv6 message can be identified through the first traffic matching condition in the Flowspec route, and the SRv6 message can be identified and processed based on the traffic control action corresponding to the first traffic matching condition. This breaks the limitations of Flowspec technology on the identification and control of SRv6 traffic.
[0133] Furthermore, based on the above-mentioned embodiment of the present application, another embodiment of the present application is provided. In this embodiment, the Flowspec routing also includes a second flow matching condition configured for other types of flows.
[0134] In this embodiment, if Figure 7 As shown, the other types of traffic include at least one of data link layer traffic, network layer traffic, MPLS traffic, SRv6 traffic and EVPN traffic.
[0135] In this embodiment, the Flowspec route includes a type field, and the type field is used to indicate the matching conditions of different types of traffic included in the Flowspec route.
[0136] As an example, the following content included in the type field is the second traffic matching condition configured for other types of traffic:
[0137] -1-L2(Ether or VPN) traffic match;
[0138] -2-L3 (IP or VPN) traffic match: network layer traffic rules;
[0139] -3-MPLS traffic match;
[0140] -5-reserved for EVPN: EVPN (Ethernet Virtual Private Network) traffic rules.
[0141] As an example, the second traffic matching condition of other types of traffic configurations may be set based on the characteristics of the type of traffic.
[0142] As an example, based on the type field, the currently received message is matched to obtain the message corresponding to the target type traffic.
[0143] As an example, when a Flowspec route is obtained, the Flowspec route may include matching conditions for different types of traffic.
[0144] Therefore, it is necessary to match the currently received message based on the traffic matching conditions corresponding to each traffic type in the type field in the Flowspec route.
[0145] For example, if the type field in the current Flowspec route includes traffic matching conditions corresponding to MPLS traffic and EVPN traffic, then, when matching the currently received message based on the type field, when a certain traffic matching condition is hit, it is determined that the currently received message is a message corresponding to the target type traffic. (Wherein, the target type traffic is the traffic that the Flowspec route wants to match and is matched, and the message corresponding to the target type traffic is at least one of the messages corresponding to MPLS traffic and EVPN traffic).
[0146] In this embodiment, the SRv6 Policy message corresponding to the SRv6 Policy traffic is further encapsulated with an IPv6 header. The step of matching the currently received message based on the first traffic matching condition to obtain the target SRv6 message includes:
[0147] Step A1: Based on the first traffic matching condition, the first IPv6 header and / or the first routing extension header of the currently received message in the encapsulation order are matched to obtain the target SRv6 message.
[0148] As an example, due to the existence of multiple decapsulation schemes such as BSID (compression or decompression of the header), multiple IPv6 headers and routing extension headers may appear simultaneously in the message. Therefore, in the process of matching the currently received message based on the first traffic matching condition, the first IPv6 header and / or the first routing extension header of the currently received message in the encapsulation order is matched to obtain the target SRv6 message to save matching time.
[0149] In this embodiment, the step of matching the currently received message based on the first traffic matching condition to obtain the target SRv6 message includes:
[0150] Step A1: matching the currently received message based on the priorities of the first traffic matching condition and the second traffic matching condition, and the priorities of each matching item in the first traffic matching condition to obtain a target SRv6 message;
[0151] In this embodiment, the priority of the first traffic matching condition is lower than the priority of the second traffic matching condition, and the priorities of the matching items in the first traffic matching condition are, from high to low, the next header field in the routing extension header, the segment list field in the routing extension header, the type field of the segment identifier in the routing extension header, the partial segment identifier field in the routing extension header, the remaining segments field in the routing extension header, the Flags field in the routing extension header, and the Tag field in the routing extension header.
[0152] As an example, if the first traffic matching condition includes only one of the above matching items, then in the process of matching the currently received message based on the first traffic matching condition, there is no need to determine the priority between the above matching items.
[0153] As an example, if the first traffic matching condition includes at least two of the above matching items at the same time, matching the currently received message based on the priority between the above matching items can improve the efficiency of traffic matching.
[0154] As an example, at the same time, since different types of traffic have different processing priorities, it is necessary to match the currently received message based on the priority of the first traffic matching condition and the priority of the second traffic matching condition corresponding to different types of traffic. Specifically, the priority of the first traffic matching condition is lower than the priority of the second traffic matching condition.
[0155] In this embodiment, after the step of matching the currently received message based on the first traffic matching condition, the method further includes:
[0156] If the currently received message is matched based on the first traffic matching condition in the Flowspec route to obtain the target SRv6 message, and at the same time, the currently received message is matched based on the second traffic matching condition in the Flowspec route to obtain the message corresponding to the other type of traffic, then it is determined that the matched target SRv6 message is invalid, and the matched message corresponding to the other type of traffic is valid.
[0157] As an example, since the processing priority of SRv6 traffic is lower, if the Flowspec route contains the first traffic matching condition and the second traffic matching condition, then in the traffic matching process, if the currently received message is matched based on the first traffic matching condition in the Flowspec route to obtain the target SRv6 message, and at the same time, the currently received message is matched based on the second traffic matching condition in the Flowspec route to obtain the message corresponding to the other type of traffic, then it is determined that the matched target SRv6 message is invalid, and the matched message corresponding to the other type of traffic is valid. If the currently received message is matched based on the first traffic matching condition in the Flowspec route to obtain the target SRv6 message, and no message corresponding to other types of traffic is matched, then it is determined that the target SRv6 message is valid.
[0158] In this embodiment, the flow control action also includes other redirection actions.
[0159] As an example, the flow control action includes at least one of all the rewriting actions in the above-designed first redirection action and the second redirection action.
[0160] As an example, the flow control action also includes other redirection actions specified by the original Flowspe technology.
[0161] Therefore, before the step of determining the transmission control mode of the target SRv6 message based on the flow control action, it is necessary to determine whether the redirection action and the other redirection action exist in the flow control action corresponding to the first flow matching condition at the same time, then it is considered that the flow control action conflicts, the Flowspec route is determined to be invalid, and the step of determining the transmission control mode of the target SRv6 message based on the flow control action is not performed. If not, it is determined that the Flowspec route is valid, and the step of determining the transmission control mode of the target SRv6 message based on the flow control action is continued.
[0162] In this embodiment, in this embodiment, the matching objects of SRv6 traffic (the first IPv6 header and / or the first routing extension header in the encapsulation order) are standardized, and standardized suggestions are made for the priority and effectiveness conditions of traffic matching conditions for various types of traffic. Standard suggestions are made for conflict handling of redirection actions and the validity of Flowspec routes, so as to facilitate the standardized implementation of the transmission control method of SRv6 packets.
[0163] Reference Figure 8 , Figure 8 It is a schematic diagram of the device structure of the hardware operating environment involved in the embodiment of the present application.
[0164] like Figure 8 As shown, the SRv6 message transmission control method device may include: a processor 1001, a memory 1005, and a communication bus 1002. The communication bus 1002 is used to implement connection communication between the processor 1001 and the memory 1005.
[0165] Optionally, the SRv6 message transmission control method device may further include a user port, a network port, a camera, an RF (Radio Frequency) circuit, a sensor, a WiFi module, etc. The user port may include a display screen (Display), an input submodule such as a keyboard (Keyboard), and the optional user port may also include a standard wired port and a wireless port. The network port may include a standard wired port and a wireless port (such as a WI-FI port).
[0166] Those skilled in the art will understand that Figure 8 The SRv6 message transmission control method device structure shown in the figure does not constitute a limitation on the SRv6 message transmission control method device, and may include more or fewer components than shown in the figure, or combine certain components, or arrange the components differently.
[0167] like Figure 8 As shown, the memory 1005 as a storage medium may include an operating system, a network communication module, and a transmission control method program for SRv6 messages. The operating system is a program that manages and controls the hardware and software resources of the transmission control method device for SRv6 messages, and supports the operation of the transmission control method program for SRv6 messages and other software and / or programs. The network communication module is used to realize communication between the components inside the memory 1005, and to communicate with other hardware and software in the transmission control method system for SRv6 messages.
[0168] exist Figure 8 In the SRv6 message transmission control method device shown, the processor 1001 is used to execute the SRv6 message transmission control method program stored in the memory 1005 to implement the steps of the SRv6 message transmission control method described in any one of the above items.
[0169] The specific implementation of the SRv6 message transmission control method device of the present application is basically the same as the various embodiments of the SRv6 message transmission control method method described above, and will not be repeated here.
[0170] The present application also provides a transmission control method and device for SRv6 messages, which is applied to routing devices, such as Fig. 9 As shown, the device comprises:
[0171] A route receiving module 10 is used to obtain a Flowspec route, wherein the Flowspec route includes a first flow matching condition configured for SRv6 flow, and a flow control action corresponding to the first flow matching condition;
[0172] A matching module 20, configured to match the currently received message based on the first traffic matching condition to obtain a target SRv6 message;
[0173] The control module 30 is used to determine the transmission mode of the target SRv6 message based on the flow control action.
[0174] Optionally, in a possible implementation manner of the present application, the SRv6 traffic includes SRv6 Policy traffic, the target SRv6 message includes an SRv6 Policy message corresponding to the SRv6 Policy traffic, a routing extension header is encapsulated in the SRv6 Policy message, and the matching item in the first traffic matching condition includes at least one of the following:
[0175] Next Header field in the Routing extension header;
[0176] The segment list field in the routing extension header;
[0177] The type field of the segment identifier in the routing extension header;
[0178] The partial segment identifier field in the routing extension header;
[0179] The remaining segments field in the routing extension header;
[0180] The Flags field in the routing extension header;
[0181] The Tag field in the routing extension header.
[0182] Optionally, in a possible implementation of the present application, the SRv6 traffic also includes SRv6BE traffic, the target SRv6 message also includes an SRv6 BE message corresponding to the SRv6 BE traffic, the SRv6 BE message is encapsulated with an IPv6 header, and the matching item in the first traffic matching condition also includes the destination address field in the IPv6 header.
[0183] Optionally, in a possible implementation manner of the present application, the matching module 20 includes:
[0184] The first matching submodule is used to match the first IPv6 header and / or the first routing extension header of the currently received message in the encapsulation order based on the first traffic matching condition to obtain the target SRv6 message.
[0185] Optionally, in a possible implementation manner of the present application, the traffic control action includes a first redirection action configured for the SRv6 Policy traffic, and the first redirection action includes at least one of the following:
[0186] Popping up the routing extension header action, used to remove the routing extension header of the SRv6 Policy message, encapsulate the preset segment identifier into the IPv6 header of the SRv6 Policy message, and iterate the SRv6 Policy message to the forwarding process of the SRv6 BE traffic by querying the forwarding table, and the forwarding process is mapped with the target port of the target SRv6 message;
[0187] A remaining segment rewriting action is used to modify the assignment of the remaining segment in the SRv6 Policy message, wherein the modified assignment of the remaining segment indicates a corresponding segment identifier, and the segment identifier is mapped with a target port of the target SRv6 message;
[0188] A Tag value modification action, used to modify a Tag value in the SRv6 Policy message, wherein the Tag value indicates a message type of the SRv6 Policy message, and the message type is mapped to a data type of the target SRv6 message;
[0189] The segment identifier modification action is used to delete, add or change the segment identifier in the segment list, and the segment identifier is mapped with the target port of the target SRv6 message.
[0190] Optionally, in a possible implementation manner of the present application, the traffic control action further includes a second redirection action configured for the SRv6 BE traffic, and the second redirection action includes at least one of the following:
[0191] An IPv6 header pop-up action is used to remove the IPv6 header of the SRv6 BE message, and query a forwarding table based on the destination IP address in the payload, wherein the forwarding table maps a destination port of the target SRv6 message;
[0192] A source address modification action, used to modify the source address in the SRv6 BE message, so that other routing devices can determine whether to receive the SRv6 BE message based on the source address;
[0193] The destination address modification action is used to modify the destination address of the IPv6 header in the SRv6 BE message, and the destination address is mapped with the destination port of the target SRv6 BE message.
[0194] Optionally, in a possible implementation manner of the present application, the Flowspec routing further includes a second flow matching condition configured for other types of flows;
[0195] The matching module 20 further includes:
[0196] A second matching submodule, configured to match the currently received message based on the priorities of the first traffic matching condition and the second traffic matching condition, and the priorities of each matching item in the first traffic matching condition, to obtain a target SRv6 message;
[0197] Among them, the priority of the first traffic matching condition is lower than the priority of the second traffic matching condition, and the priorities of the matching items in the first traffic matching condition are, from high to low, the next header field in the routing extension header, the segment list field in the routing extension header, the type field of the segment identifier in the routing extension header, the partial segment identifier field in the routing extension header, the remaining segments field in the routing extension header, the Flags field in the routing extension header, and the Tag field in the routing extension header.
[0198] Optionally, in a possible implementation manner of the present application, the other types of traffic include at least one of data link layer traffic, network layer traffic, MPLS traffic, and EVPN traffic;
[0199] After the step of matching the currently received message based on the first traffic matching condition, the device further includes:
[0200] The effectiveness judgment module is used to match the currently received message based on the first flow matching condition in the Flowspec route to obtain the target SRv6 message, and at the same time match the currently received message based on the second flow matching condition in the Flowspec route to obtain the message corresponding to the other type of flow, then determine that the matched target SRv6 message is invalid, and the matched message corresponding to the other type of flow is valid.
[0201] The specific implementation of the SRv6 message transmission control method device of the present application is basically the same as the various embodiments of the SRv6 message transmission control method method described above, and will not be repeated here.
[0202] The present application also provides a storage medium, on which a transmission control method program for an SRv6 message is stored. When the transmission control method program for the SRv6 message is executed by a processor, the steps of the transmission control method for the SRv6 message as described in any one of the above items are implemented.
[0203] The specific implementation method of the storage medium of the present application is basically the same as the various embodiments of the above-mentioned SRv6 message transmission control method, and will not be repeated here.
[0204] It should be noted that, in this article, the term "includes", "comprising" or any other variation thereof is intended to cover non-exclusive inclusion, so that a process, method, article or system including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or system. In the absence of further restrictions, an element defined by the sentence "comprising a ..." does not exclude the existence of other identical elements in the process, method, article or system including the element.
[0205] The serial numbers of the above-mentioned embodiments of the present application are for description only and do not represent the advantages or disadvantages of the embodiments.
[0206] 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 a necessary general hardware platform, and of course by hardware, but in many cases the former is a better implementation method. Based on such an 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 a terminal device (which can be a mobile phone, computer, server, air conditioner, or network device, etc.) to execute the methods described in each embodiment of the present application.
[0207] The above are only preferred embodiments of the present application, and are not intended to 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 controlling transmission of SRv6 packets, characterized in that: Applied to routing equipment, including the following steps: Obtain a Flowspec route, where the Flowspec route includes a first flow matching condition configured for SRv6 flow, and a flow control action corresponding to the first flow matching condition; Based on the first traffic matching condition, matching the currently received message to obtain a target SRv6 message; Based on the flow control action, a transmission mode of the target SRv6 message is determined.
2. The SRv6 message transmission control method according to claim 1, characterized in that: The SRv6 traffic includes SRv6 Policy traffic, the target SRv6 message includes an SRv6 Policy message corresponding to the SRv6 Policy traffic, a routing extension header is encapsulated in the SRv6 Policy message, and the matching item in the first traffic matching condition includes at least one of the following: Next Header field in the Routing extension header; The segment list field in the routing extension header; The type field of the segment identifier in the routing extension header; The partial segment identifier field in the routing extension header; The remaining segments field in the routing extension header; The Flags field in the routing extension header; The Tag field in the routing extension header.
3. The SRv6 message transmission control method according to claim 2, characterized in that: The SRv6 traffic also includes SRv6 BE traffic, the target SRv6 message also includes an SRv6 BE message corresponding to the SRv6 BE traffic, the SRv6 BE message is encapsulated with an IPv6 header, and the matching item in the first traffic matching condition also includes a destination address field in the IPv6 header.
4. The SRv6 message transmission control method according to claim 3, characterized in that: The SRv6 Policy message corresponding to the SRv6 Policy traffic is further encapsulated with an IPv6 header. The step of matching the currently received message based on the first traffic matching condition to obtain the target SRv6 message includes: Based on the first traffic matching condition, the first IPv6 header and / or the first routing extension header of the currently received message in the encapsulation order are matched to obtain the target SRv6 message.
5. The SRv6 message transmission control method according to any one of claims 3 to 4, characterized in that: The traffic control action includes a first redirection action configured for the SRv6 Policy traffic, and the first redirection action includes at least one of the following: Popping up the routing extension header action, used to remove the routing extension header of the SRv6 Policy message, encapsulate the preset segment identifier into the IPv6 header of the SRv6 Policy message, and iterate the SRv6 Policy message to the forwarding process of the SRv6 BE traffic by querying the forwarding table, and the forwarding process is mapped with the target port of the target SRv6 message; A remaining segment rewriting action is used to modify the assignment of the remaining segment in the SRv6 Policy message, wherein the modified assignment of the remaining segment indicates a corresponding segment identifier, and the segment identifier is mapped with a target port of the target SRv6 message; A Tag value modification action, used to modify a Tag value in the SRv6 Policy message, wherein the Tag value indicates a message type of the SRv6 Policy message, and the message type is mapped with a data type of the target SRv6 message; The segment identifier modification action is used to delete, add or change the segment identifier in the segment list, and the segment identifier is mapped with the target port of the target SRv6 message.
6. The SRv6 message transmission control method according to claim 5, characterized in that: The traffic control action further includes a second redirection action configured for the SRv6 BE traffic, wherein the second redirection action includes at least one of the following: An IPv6 header pop-up action is used to remove the IPv6 header of the SRv6 BE message, and query a forwarding table based on the destination IP address in the payload, wherein the forwarding table maps a destination port of the target SRv6 message; A source address modification action, used to modify the source address in the SRv6 BE message, so that other routing devices can determine whether to receive the SRv6 BE message based on the source address; The destination address modification action is used to modify the destination address of the IPv6 header in the SRv6 BE message, and the destination address is mapped with the destination port of the target SRv6 BE message.
7. The SRv6 message transmission control method according to claim 2-4, characterized in that: The Flowspec routing also includes a second flow matching condition configured for other types of flows; The step of matching the currently received message based on the first traffic matching condition to obtain the target SRv6 message includes: Based on the priorities of the first traffic matching condition and the second traffic matching condition, and the priorities of the matching items in the first traffic matching condition, the currently received message is matched to obtain a target SRv6 message; Among them, the priority of the first traffic matching condition is lower than the priority of the second traffic matching condition, and the priorities of the matching items in the first traffic matching condition are, from high to low, the next header field in the routing extension header, the segment list field in the routing extension header, the type field of the segment identifier in the routing extension header, the partial segment identifier field in the routing extension header, the remaining segments field in the routing extension header, the Flags field in the routing extension header, and the Tag field in the routing extension header.
8. The SRv6 message transmission control method according to claim 7, characterized in that: The other types of traffic include at least one of data link layer traffic, network layer traffic, MPLS traffic, and EVPN traffic; After the step of matching the currently received message based on the first traffic matching condition, the method further includes: If the currently received message is matched based on the first traffic matching condition in the Flowspec route to obtain the target SRv6 message, and at the same time, the currently received message is matched based on the second traffic matching condition in the Flowspec route to obtain the message corresponding to the other type of traffic, then it is determined that the matched target SRv6 message is invalid, and the matched message corresponding to the other type of traffic is valid.
9. A transmission control device for SRv6 messages, characterized in that: The device comprises: A route receiving module, configured to obtain a Flowspec route, wherein the Flowspec route includes a first flow matching condition configured for SRv6 flow, and a flow control action corresponding to the first flow matching condition; A matching module, configured to match the currently received message based on the first traffic matching condition to obtain a target SRv6 message; A control module is used to determine a transmission mode of the target SRv6 message based on the flow control action.
10. A transmission device for SRv6 messages, characterized in that: The device includes: a memory, a processor, and a transmission program for SRv6 messages stored in the memory and executable on the processor, wherein the transmission program for SRv6 messages is configured to implement the steps of the transmission control method for SRv6 messages as described in any one of claims 1 to 8.
11. A storage medium, characterized in that: The storage medium stores a transmission program for an SRv6 message, and when the transmission program for the SRv6 message is executed by a processor, the steps of the SRv6 message transmission control method according to any one of claims 1 to 8 are implemented.
Citation Information
Cited By
Srv6 message transmission control method, apparatus, device and storage medium
EP4723580A1
