WO2023231431A1 - 报文接收方法、发送方法、转发方法、装置及系统 - Google Patents

报文接收方法、发送方法、转发方法、装置及系统 Download PDF

Info

Publication number
WO2023231431A1
WO2023231431A1 PCT/CN2023/073744 CN2023073744W WO2023231431A1 WO 2023231431 A1 WO2023231431 A1 WO 2023231431A1 CN 2023073744 W CN2023073744 W CN 2023073744W WO 2023231431 A1 WO2023231431 A1 WO 2023231431A1
Authority
WO
WIPO (PCT)
Prior art keywords
parameter field
node
message
field
segment identifier
Prior art date
Application number
PCT/CN2023/073744
Other languages
English (en)
French (fr)
Inventor
李振斌
李呈
毛健炜
Original Assignee
华为技术有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 华为技术有限公司 filed Critical 华为技术有限公司
Publication of WO2023231431A1 publication Critical patent/WO2023231431A1/zh

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L45/00Routing or path finding of packets in data switching networks
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L45/00Routing or path finding of packets in data switching networks
    • H04L45/74Address processing for routing

Definitions

  • the present application relates to the field of communication technology, and in particular to a message receiving method, sending method, forwarding method, device and system.
  • IPv6 Internet protocol version 6
  • HBV hop-by-hop options header
  • HAH destination options header
  • DOH destination options header
  • TLV type-length-value
  • the instruction information indicating the packet processing behaviors can be carried in the above-mentioned IPv6 extension header or the TLV field of the SRH.
  • an option indicating network slice information can be inserted into the HBH or DOH, so that nodes in the forwarding path forward packets based on the specified network slice.
  • the in-situ flow information telemetry (IFIT) TLV can be inserted into the TLV field of the SRH to enable nodes in the forwarding path to detect the traffic along the flow.
  • This application provides a message receiving method, sending method, forwarding method, device and system, which can solve the technical problem of high complexity of message forwarding caused by separately defining SID for each node.
  • a message receiving method applied to a first node in a message forwarding system; the method includes: receiving a first message, the first destination address field of the first message including the first segment Identification: determine a first parameter field corresponding to the first segment identification from the first destination address field, and perform at least one first processing behavior indicated by the first parameter field.
  • the solution provided by this application can indicate the processing behavior through the parameter field in the destination address field. Therefore, compared with inserting an additional IPv6 extension header or extended TLV to indicate the processing behavior, the length of the message header can be effectively reduced, that is, the length of the message header can be reduced. overhead, thereby improving data transmission efficiency.
  • the first parameter field is a structured parameter field that can indicate one or more processing behaviors, it can guide the first node to perform richer processing behaviors.
  • the first node determines at least one first processing behavior indicated by the first parameter field, it is not necessary to match the first parameter field with the function field in the first segment identification. That is, the first parameter field does not need to cooperate with the function field to indicate at least one first processing behavior.
  • the process of the first node performing at least one first processing behavior indicated by the first parameter field may include: Identify at least one behavior instruction carried in the first parameter field, and execute the at least one first processing behavior indicated by the at least one behavior instruction.
  • each behavior instruction can indicate a processing behavior. Since the first parameter field can carry one or more behavioral instructions, and each behavioral instruction can indicate a first processing behavior, the flexibility of the first parameter field when carrying behavioral instructions is effectively improved, thereby improving the execution of processing behaviors by the node. time flexibility.
  • the process of identifying the at least one behavioral instruction carried in the first parameter field may include: identifying the at least one behavioral instruction carried in the first parameter field according to the parameter field template.
  • the parameter field template may be used to define the type, position and/or length of at least one behavioral instruction carried by the first parameter field.
  • the first node can accurately and quickly identify at least one behavioral instruction carried in the first parameter field.
  • the first parameter field may also include a template identifier; the method may further include: determining the parameter field template according to the corresponding relationship between the template identifier and the parameter field template.
  • the first node can parse the first parameter field according to different parameter field templates indicated by different template identifiers. Based on this, different parameter field templates can be flexibly used to encode the first parameter field, thereby effectively improving the flexibility of the first parameter field in carrying behavioral instructions.
  • the method may also include: determining the parameter field template according to the corresponding relationship between the behavior or behavioral characteristics indicated by the first segment identification and the parameter field template.
  • the behavior (behavior) or behavioral characteristics (flavor) indicated by the segment identifier may refer to the behavior or behavioral characteristics indicated by the function field in the segment identifier.
  • the parameter field template can also be associated with the behavior or behavioral characteristics indicated by the function field.
  • the behavior or behavior characteristics of the feature are associated with a specific parameter field template.
  • the corresponding parameter field template can be determined, and then the parameter field template is used to modify the first parameter field. Identify and read at least one behavioral instruction carried therein. Therefore, the first node can directly determine the corresponding parameter field template according to the first segment identifier. Since there is no need to carry the template ID in the first parameter field in this implementation, more bits can be reserved for the first line of instructions.
  • the process of identifying at least one behavioral instruction carried in the first parameter field may include: identifying at least one flag bit carried in the first parameter field, and identifying the first parameter field based on the at least one flag bit. At least one behavioral instruction carried in . Among them, each flag bit corresponds to a behavioral instruction.
  • each flag bit may be used to indicate whether the first parameter field carries a corresponding behavioral instruction, or to indicate whether the corresponding behavioral instruction in the first parameter field can be recognized. Among them, if a certain flag bit indicates that a corresponding behavioral instruction can be recognized, it indicates that the behavioral instruction is valid; if a certain flag bit indicates that a corresponding behavioral instruction cannot be recognized, it indicates that the behavioral instruction is invalid.
  • the flag bit in the first parameter field can indicate whether the first parameter field carries a corresponding behavior instruction, or whether the corresponding behavior instruction can be recognized, the first node can be flexibly selected according to the needs of the application scenario.
  • the number of behavioral instructions when a certain behavioral instruction is not carried in the first parameter field, the bits occupied by the behavioral instruction can also be used to carry other behavioral instructions, thereby enabling flexible adjustment of the length of the behavioral instruction.
  • the process of the first node executing at least one first processing behavior indicated by the first parameter field may include: based on the structured parameter function of the first node being in an enabled state, executing at least one process indicated by the first parameter field.
  • the first node can enable the structured parameter function, or determine the first parameter number. After the segment is a structured parameter field, at least one first processing behavior indicated by the first parameter field is executed. Correspondingly, if the first node does not enable the structured parameter function, or recognizes that the first parameter field is not a structured parameter field, it is not necessary to parse the first parameter field in a structured manner, and thus the at least one parameter field will not be executed. First processing behavior.
  • the first segment identifier may be a compressed segment identifier, and the length of the compressed segment identifier is less than 128 bits.
  • the compressed segment identifier can be a compressed SID (compressed SID, CSID), a micro SID (micro SID, uSID) or a general SID (generalized SID, G-SID).
  • the length of the first segment identifier may be 128 bits, that is, the first segment identifier may be a common SRv6 SID.
  • the first parameter field may be included in the first segment identifier, or the first parameter field may be located after the first segment identifier.
  • the first segment identifier may include a first parameter field.
  • the first parameter field may be located after the first segment identifier.
  • the first message belongs to the target service flow
  • the method may further include: receiving a second message of the target service flow, the second destination address field of the second message including a second segment identifier; from the Determine a second parameter field corresponding to the second segment identification in the second destination address field, and perform at least one second processing behavior indicated by the second parameter field.
  • the at least one second processing behavior is different from the at least one first processing behavior.
  • different processing behaviors can be indicated through different parameter fields, so that the first node can perform different processing behaviors according to the different parameter fields. For example, perform different processing behaviors on different packets of the target service flow. Therefore, the first node can be enabled to perform a larger number of processing behaviors without increasing the length of the parameter field.
  • the first segment of identification may also include a function field, where the function field is used to indicate the third processing behavior.
  • the method may further include: processing the first message according to the third processing behavior.
  • the third processing act is different from at least one first processing act. That is to say, the first parameter field can independently indicate at least one first processing behavior without cooperating with the function field.
  • the first parameter field can also be used to carry parameters of the third processing behavior. That is to say, the first parameter field can also retain the function of the original parameter field, thereby being compatible with the original function.
  • the parameters of the third processing behavior may include: parameters of the behavior of endpoint with decapsulation and L2 table flooding (End.DT2M), and/or the index of the compressed segment identifier. .
  • the process of the first node performing at least one first processing behavior indicated by the first parameter field may include: processing the first message according to at least one first processing behavior indicated by the first parameter field.
  • the at least one first processing behavior includes at least one of the following behaviors: forwarding messages based on slice resources of network slices; forwarding messages based on network services indicated by application awareness information; following flow detection; Network resources forward messages; encrypt forward messages; security verification.
  • the first node can be caused to perform rich processing behaviors.
  • the first parameter field may include at least one of a first subfield, a second subfield, a third subfield, a fourth subfield, a fifth subfield and a sixth subfield.
  • the first subfield is used to carry the slice information of the network slice;
  • the second subfield is used to carry the application awareness information;
  • the third subfield is used to carry the information of the flow detection;
  • the fourth subfield is used to carry the allocated network Resource information;
  • the fifth subfield is used to carry the encryption method of the encrypted forwarding;
  • the sixth subfield is used to carry the message authentication code used for the security verification.
  • the first parameter field may also include a seventh subfield; the seventh subfield is used to carry parameters of the third processing behavior indicated by the function field in the first section identification.
  • the at least one first processing behavior may include at least one of the following behaviors: adjusting the operating status of the first node; establishing a flow table, a forwarding table and/or a status table for traffic locally on the first node.
  • the traffic flow may refer to the service flow to which the first message belongs.
  • the at least one first processing behavior may also include processing behavior performed locally by the first node and unrelated to the first message. That is to say, the first node's execution of the first processing behavior will not modify the content of the first message, nor will it affect the forwarding process of the first message.
  • the process of determining the first parameter field from the first destination address field may include: determining the first parameter field from the first destination address field based on determining that the first segment is identified as the local SID of the first node. . It can be understood that if the first segment identifier is not the local SID of the first node, the first node does not need to determine and process the first parameter field.
  • the first node does not support forwarding technology based on SRv6.
  • the process of determining the first parameter field from the first destination address field may include: determining the first parameter field from the first destination address field based on the local configuration information of the first node.
  • the local configuration information can indicate the position of the first parameter field in the first destination address field.
  • the local configuration information may be configured by operation and maintenance personnel, or may be issued by the controller.
  • the first parameter field may also include at least one compressed segment identifier, for example, may include at least one uSID.
  • the at least one first-line instruction may be located after the at least one uSID. During the packet forwarding process, the at least one uSID may be shifted.
  • the second aspect provides a message sending method, which can be applied to the head node of the message forwarding system.
  • the method includes: encapsulating a first segment identifier in a first message and sending the first message.
  • the first message is used for the node that receives the first message to determine a first parameter field from the first destination address field of the first message and perform at least one first processing behavior indicated by the first parameter field. .
  • the first parameter field corresponds to the first segment identifier.
  • the process of encapsulating the first segment identifier in the first message may include: encapsulating the first segment identifier in the first destination address field; or, encapsulating the SRH in the first message, the SRH including the first segment identifier.
  • a piece of identification Among them, if the first segment is identified as uSID, and each node in the forwarding path of the first message can be encoded in a uSID bearer, the uSID bearer can be carried directly through the first destination address field, that is, the first There is no need to carry SRH in the message.
  • the first message belongs to the target service flow
  • the method may further include: encapsulating the second segment identifier in the second message of the target service flow, and sending the second message.
  • the second message is used for the node that receives the second message to determine a second parameter field from the second destination address field of the second message and perform at least one second process indicated by the second parameter field.
  • Behavior wherein, the second parameter field corresponds to the second segment identifier, and the at least one second processing behavior is different from the at least one first processing behavior.
  • the node indicated by the first segment identifier is the same as the node indicated by the second segment identifier.
  • the first segment identifier is a compressed segment identifier, and the length of the compressed segment identifier is less than 128 bits; or, the length of the first segment identifier is 128 bits.
  • the first parameter field is included in the first section identifier, or the first parameter field is located after the first section identifier.
  • a message forwarding method is provided, which is applied to a message forwarding system.
  • the message forwarding system includes a first node and a second node.
  • the method includes: a first node receives a first message, the first destination address field of the first message includes a first segment identifier; the first node determines a first parameter field from the first destination address field, and the first parameter field The field corresponds to the first segment identifier; the first node performs at least one first processing behavior indicated by the first parameter field.
  • the second node receives the second message sent by the first node, the second message is obtained based on the first message, and the second destination address field of the second message includes a second segment identifier; the second node A second parameter field is determined from the second destination address field, and the second parameter number The segment corresponds to the second segment identifier; the second node performs at least one second processing behavior indicated by the second parameter field.
  • the first parameter field and the second parameter field may be the same field. That is to say, during the process of processing the first message, the first node can update the segment identifier in the first destination address field without updating the first parameter field.
  • the at least one first processing behavior and the at least one second processing behavior may be the same.
  • first segment identifier and the second segment identifier may both be compressed segment identifiers, and the length of the compressed segment identifier may be less than 128 bits; or, the length of the first segment identifier and the second segment identifier may both be 128 bits. .
  • the first parameter field may be included in the first segment identifier, and the second parameter field may be included in the second segment identifier.
  • the first parameter field may be located after the first segment identifier, and the second parameter field may be located after the second segment identifier.
  • a fourth aspect provides a network device, which may be the first node or the third node (ie, the head node) in the message forwarding system.
  • the network device includes at least one module, and the at least one module can be used to implement the method provided in any of the above aspects.
  • a network device in a fifth aspect, is provided, and the network device may be the first node or the head node in the message forwarding system.
  • the network device includes: a memory, a processor, and a computer program stored on the memory and executable on the processor. When the processor executes the computer program, it implements the method provided in any of the above aspects.
  • a sixth aspect provides a network device, which may be the first node or the head node in the message forwarding system.
  • the network device may include: a main control board and an interface board, and the main control board and the interface board may be used to implement the method provided in any of the above aspects.
  • a computer-readable storage medium is provided. Instructions are stored in the computer-readable storage medium, and the instructions are executed by a processor to implement the method provided in any of the above aspects.
  • An eighth aspect provides a computer program product containing instructions that, when run on a processor, cause the processor to execute the method provided in any of the above aspects.
  • a message forwarding system in a ninth aspect, includes: a plurality of nodes; wherein at least one node among the plurality of nodes can implement the message receiving method provided in the first aspect.
  • the first node among the plurality of nodes may implement the message receiving method provided in the first aspect.
  • the first node and the second node may also implement the message forwarding method provided in the third aspect.
  • At least one node among the plurality of nodes can also be used to implement the message sending method provided in the second aspect.
  • a tenth aspect provides a chip, which can be used to implement the method provided in any of the above aspects.
  • this application provides a message receiving method, sending method, forwarding method, device and system.
  • the destination address field of the message received by the first node includes a segment identifier
  • the first node can determine the parameter field corresponding to the segment identifier from the destination address field, and can execute the parameter field Indicated processing action. Since the solution provided by this application can indicate processing behavior through the parameter field in the destination address field, it can effectively reduce the length of the message header and improve data transmission compared to inserting additional IPv6 extension headers or extended TLVs to indicate processing behavior. efficiency.
  • the first parameter field is a structured parameter field that can indicate one or more processing behaviors, it can guide the first node to perform richer processing behaviors.
  • Figure 1 is a schematic structural diagram of a message forwarding system provided by an embodiment of the present application.
  • Figure 2 is a schematic structural diagram of an SRv6 message provided by an embodiment of the present application.
  • FIG. 3 is a schematic structural diagram of a SID provided by an embodiment of the present application.
  • Figure 4 is a schematic structural diagram of a compressed segment identifier provided by an embodiment of the present application.
  • Figure 5 is a schematic structural diagram of a uSID bearer provided by an embodiment of the present application.
  • Figure 6 is a schematic structural diagram of HOH and DOH provided by the embodiment of the present application.
  • Figure 7 is a schematic structural diagram of an option field provided by an embodiment of the present application.
  • Figure 8 is a schematic structural diagram of an SRH provided by an embodiment of the present application.
  • FIG. 9 is a schematic structural diagram of an HMAC TLV provided by an embodiment of the present application.
  • Figure 10 is a flow chart of a message receiving method provided by an embodiment of the present application.
  • Figure 11 is a flow chart of a message forwarding method provided by an embodiment of the present application.
  • Figure 12 is a schematic structural diagram of a first destination address field provided by an embodiment of the present application.
  • Figure 13 is a schematic structural diagram of another first destination address field provided by an embodiment of the present application.
  • Figure 14 is a schematic structural diagram of a G-SID bearer provided by an embodiment of the present application.
  • Figure 15 is a schematic structural diagram of a first parameter field provided by an embodiment of the present application.
  • Figure 16 is a schematic diagram of a first parameter field template provided by an embodiment of the present application.
  • Figure 17 is a schematic diagram of the arrangement position of each flag bit in the first parameter field provided by an embodiment of the present application.
  • Figure 18 is a schematic diagram of the arrangement order of each behavioral instruction in the first parameter field provided by an embodiment of the present application.
  • Figure 19 is a schematic diagram of a filling method of redundant bits in the first parameter field provided by an embodiment of the present application.
  • Figure 20 is a schematic diagram of instruction filling for the first line in the first parameter field provided by an embodiment of the present application.
  • Figure 21 is a schematic structural diagram of a first node provided by an embodiment of the present application.
  • Figure 22 is a schematic structural diagram of a third node provided by an embodiment of the present application.
  • Figure 23 is a schematic structural diagram of a second node provided by an embodiment of the present application.
  • Figure 24 is a schematic structural diagram of a network device provided by an embodiment of the present application.
  • Figure 25 is a schematic structural diagram of another network device provided by an embodiment of the present application.
  • FIG 1 is a schematic structural diagram of a message forwarding system provided by an embodiment of the present application.
  • the message forwarding system may include multiple nodes 01, and communication connections are established between the multiple nodes 01.
  • each node 01 can be a router, switch, broadband remote access server (BRAS), firewall or virtual network element, etc., and each node 01 can also be called a network device.
  • BRAS broadband remote access server
  • node 01 may be a provider (provider, P) device or a provider edge (provider edge, PE) device.
  • the message forwarding system may also include a customer edge (CE) device 02 connected to the PE device.
  • CE customer edge
  • the CE device 02 is connected to the user terminal and used to provide network access services for the user terminal.
  • the user terminal can also be called user equipment, which can be a residential gateway (RGW), a mobile phone, a laptop or a desktop computer.
  • RGW residential gateway
  • the message forwarding system may also include a controller 03.
  • the controller 03 is connected to at least one node 01 and is used to manage and control the node 01 to which it is connected.
  • the controller 03 may be a network controller.
  • the message forwarding system may be an SRv6 system, and the messages forwarded by each node in the SRv6 system It is an SRv6 message, which is a message obtained by inserting SRH into an IPv6 message.
  • Figure 2 is a schematic structural diagram of an SRv6 message provided by an embodiment of the present application. As shown in Figure 2, the SRv6 message includes: IPv6 header, SRH and payload. Among them, the IPv6 header includes the following fields: version (version), traffic class (TC), flow label (flow label), payload length (payload length), next header (next header), hop limit (hop limit), source address (source address, SA) and DA.
  • SRH includes the following fields: next header, extension header length (Hdr Ext Len), routing header type (routing type), number of remaining segments (segment left, SL), last entry (last entry), Flags, tags, segment lists, and optional TLVs.
  • the segment list includes segment list [0] to segment list [n], a total of n+1 identification fields (n can be an integer greater than or equal to 1), and each identification field is used to carry a node in the message forwarding path.
  • SID which can be the IPv6 address of the node.
  • FIG 3 is a schematic structural diagram of an SID provided by an embodiment of the present application.
  • each SID may include a locator field, a function field and an arguments field.
  • the locator field is used to identify a certain network domain and a certain node in the network domain.
  • the function field is used to identify the action performed on the corresponding node, also called behavior.
  • the parameter field is used to carry the parameters required to perform the action.
  • the compression scheme defines a compressed segment identifier, as shown in Figure 4.
  • the compressed segment identifier can include at least one of a node ID and a function ID.
  • Figure 4 uses a compressed segment identifier to include a node ID and a function. ID is taken as an example.
  • the node ID can form a locator field with the common prefix in the destination address field.
  • the locator field, function ID, and parameter field (or padding field) in the destination address field can form a 128-bit SRv6 SID.
  • a compressed segment identifier only includes one of the node ID and the function ID
  • the node ID and the function ID can be carried by two adjacent compressed segment identifiers respectively, thereby realizing the identification of a node in the network domain. , and the identification of the processing behavior that needs to be performed on the node.
  • the compressed segment identifier described in the embodiment of this application may be CSID, uSID or G-SID.
  • uSID refers to a uSID bearer (container) as an example for explanation.
  • a uSID bearer (container) is defined in the uSID solution.
  • the structure of the uSID bearer can be: ⁇ uSID block> ⁇ active uSID> ⁇ next uSID> ... ⁇ last uSID> ⁇ padding part>. Among them, the padding part is optional.
  • the uSID block is the address block of the uSID, which can be a public prefix, such as an IPv6 prefix.
  • Active uSID (Active uSID) is the first uSID located after the uSID block.
  • the next uSID (Next uSID) is the uSID located after the active uSID.
  • the uSID bearer can include one or more next uSIDs.
  • the last uSID (Last uSID) is the uSID located before the end mark of the bearer.
  • the padding part is the reserved part located at the end of the uSID bearer, and its value is generally 0, and the padding part can also be called the end-of-Container mark (End-of-Container).
  • the node can look up the table based on the combination of the uSID block and the active uSID to determine the corresponding processing behavior.
  • This processing behavior generally includes shifting and forwarding. Assuming that the length of the uSID block in the uSID bearer, each uSID, and the end flag of each bearer are all 16 bits, then the forwarding behavior can include:
  • the uSID bearer can share the same uSID address block, so the length of the message header can be effectively reduced. Moreover, if each node in the forwarding path of the SRv6 message can be encoded in a uSID bearer, the uSID bearer can be carried directly through the destination address field of the SRv6 message, that is, there is no need to carry the SRH in the SRv6 message.
  • IPv6 extension headers such as HBH or DOH
  • HBH or DOH various other types of IPv6 extension headers
  • instruction information indicating packet processing behaviors can usually be carried in the above-mentioned IPv6 extension header or the TLV field of the SRH.
  • both the HBH and DOH may include a next header field, an extension header length field and an option field, so an option indicating network slice information may be inserted into the HBH or DOH so that the nodes in the forwarding path are based on Network slice forwards packets.
  • the option field may include option type (option type), option data length (option data length) and option data (option data).
  • the IFIT TLV and/or the hash-based message authentication code (HMAC) TLV can be inserted in the optional TLV field of the SRH.
  • IFITTLV can instruct the nodes in the forwarding path to perform flow detection on the packets
  • HMAC TLV can instruct the nodes in the forwarding path to perform security verification on the packets.
  • the optional TLV in SRH is located between the segment list and the payload.
  • the SRv6 message also includes an Ethernet header (ETH) and an IPv6 basic header (basic header).
  • Figure 9 is a schematic structural diagram of a HMACTLV provided by an embodiment of the present application.
  • the HMAC TLV includes: type field, length field, D field, reserved field, HMAC key ID and HMAC. Among them, the length of the HMAC key ID is 4 bytes, and the length of the HMAC is a variable length.
  • the D in the D field indicates the destination address.
  • the above methods of inserting IPv6 extension headers or extending TLVs will significantly increase the length of the packet header and reduce data transmission efficiency.
  • the above method of inserting an IPv6 extension header requires each node in the forwarding path to parse the IPv6 extension header and perform corresponding processing actions. Therefore, its flexibility is low and cannot be achieved by specifying only some nodes in the forwarding path. Functions that perform processing actions.
  • the SRv6 message will no longer carry SRH.
  • some DOH needs to be inserted before the SRH. If the SRH is no longer carried in the SRv6 message, part of the DOH cannot be carried, and the instruction information indicating the message processing behavior cannot be carried through this part of the DOH.
  • the embodiment of the present application provides a message receiving method, which can be applied to the first node in the message forwarding system such as shown in Figure 1.
  • the first node can be any node in the message forwarding system. Referring to Figure 10, the method includes:
  • Step 101 Receive a first message, where the first destination address field of the first message includes a first segment identifier.
  • the first node can receive other nodes (such as the head node) in the message forwarding system.
  • the first message sent, the first destination address field of the first message includes the first segment identifier.
  • the first segment identifier may be a compressed segment identifier with a length less than 128 bits, or the first segment identifier may be a common SRv6 SID with a length of 128 bits.
  • the first node can receive the first message sent by the CE device or the user terminal. Furthermore, the first node may add the first segment identifier in the first destination address field of the first message. For example, when the first segment identifier is a common SRv6 SID or a compressed segment identifier, the first node can first encapsulate the SRH in the first message, and the SRH includes the first segment identifier, for example, the last segment identifier in the segment list. The value of an identification field is the first segment identification. Afterwards, the first node may copy the first segment identifier in the segment list to the first destination address field. Alternatively, if the first segment identifier is a compressed segment identifier and the first message does not include the SRH, the first node may directly encapsulate the first segment identifier into the first destination address field of the first message.
  • Step 102 Determine a first parameter field from the first destination address field, where the first parameter field corresponds to the first segment identifier.
  • the first node can also determine a first parameter (arguments) field corresponding to the first segment identifier from the first destination address field.
  • the first parameter field may be included in the first segment identifier, and accordingly, the first node may determine the first parameter field from the first segment identifier.
  • the first parameter field may be located after the first segment identifier, and the first node may determine the first parameter from the first destination address field according to the preconfigured encapsulation position of the first parameter field in the first destination address field. field.
  • the first parameter field may be located at the end of the first destination address field, such as 16 to 32 bits at the end of the first destination address field.
  • the first parameter field may be located after the first segment identifier and immediately adjacent to the first segment identifier, such as 16 to 32 bits after the first segment identifier.
  • Step 103 Execute at least one first processing behavior indicated by the first parameter field.
  • the first parameter field can indicate at least one first processing action.
  • the first node may perform the at least one first processing behavior.
  • the first node may process the first message according to the at least one first processing behavior.
  • the first parameter field may also be called a structured argument field.
  • the first parameter field may also be called a generalized arguments field.
  • the first segment of the identifier may also include a function field, and the function field can indicate the processing behavior of the first node on the first message (such as the third processing behavior described below).
  • the first node when determining at least one first processing behavior indicated by the first parameter field, the first node does not need to match the first parameter field with the function field. That is to say, the first node can directly determine the at least one first processing behavior based on the first parameter field, or it can be understood that the first parameter field does not need to cooperate with the function field in the first section of identification, and can independently indicate at least one A first processing act.
  • the at least one first processing behavior indicated by the first parameter field may be the same as the processing behavior indicated by additionally inserting an IPv6 extension header or an extension TLV, or may be deleted. This application The embodiment does not limit this.
  • the at least one first processing behavior indicated by the first parameter field may include a processing behavior for the first packet, and the at least one first processing behavior may include at least one of the following behaviors: network slice-based Forwarding messages based on slice resources; forwarding messages based on network services indicated by application awareness information; forwarding messages based on flow detection; forwarding messages based on allocated network resources; forwarding messages encrypted; and security verification.
  • the at least one first processing behavior indicated by the first parameter field may also include processing behavior performed locally by the first node and unrelated to the first message.
  • the at least one first processing behavior may include at least one of the following behaviors: adjusting the operating status of the first node; establishing a flow table, a forwarding table and/or a status table for traffic locally on the first node.
  • the traffic refers to the traffic to which the first message belongs.
  • the operating state of the first node may include a sleep state, a shutdown state, etc.
  • adjusting the operating state of the first node may mean causing the first node to enter a sleep state or a shutdown state.
  • the embodiment of the present application provides a message receiving method.
  • the destination address field of the first message received by the first node includes the first segment identifier, and the first node can determine the first parameter field corresponding to the first segment identifier from the destination address field, and can execute the first segment identifier.
  • a parameter field indicates at least one first processing action. Since the method provided by the embodiment of the present application can indicate the processing behavior through the first parameter field in the destination address field, compared with indicating the processing behavior by inserting an additional IPv6 extension header or extended TLV, the length of the message header can be effectively reduced. Improve data transmission Transmission efficiency. And because the first parameter field is a structured parameter field that can indicate one or more first processing behaviors, it can guide the first node to perform richer processing behaviors.
  • the first segment identifier may be a compressed segment identifier, for example, it may be a uSID.
  • the forwarding path of the first message can be encoded in the destination address field, there is no need to insert an SRH into the first message.
  • the instruction information indicating the packet processing behavior cannot be carried through the optional TLV field in the SRH or part of the DOH, the first parameter field in the destination address field can be used to guide the first node to perform rich processing behaviors. .
  • the embodiment of the present application provides a message forwarding method, which can be applied to a message forwarding system.
  • the message forwarding system includes a first node, a second node and a third node, and the third node is a head node, the first node is an intermediate node, and the second node is an intermediate node or a tail node.
  • This message forwarding method is introduced. Referring to Figure 11, the method includes:
  • Step 201 The third node encapsulates the first segment identifier in the first packet of the target service flow.
  • the third node serves as the head node of the target service flow in the message forwarding system and can encapsulate the first segment identifier in the first message of the target service flow.
  • the target business flow may be a business flow that needs to be processed using specified processing behavior. It can be understood that the third node can also encapsulate a first parameter field in the first message, where the first parameter field is used to indicate at least one first processing behavior.
  • the first segment of the identifier can be a common SRv6 SID, and its length can be 128 bits.
  • the first segment identifier may be a compressed segment identifier, and the length of the compressed segment identifier may be less than 128 bits.
  • the length of the compressed segment identifier may be 16 to 32 bits.
  • the compressed segment identifier may also be called CSID, uSID or G-SID.
  • the third node can directly The first segment identifier is encapsulated in the first destination address field of a message. Furthermore, the third node can also encapsulate the first parameter field corresponding to the first segment identifier in the first destination address field, and the first parameter field may be located after the first segment identifier.
  • the third node may encapsulate a common prefix and a total of n uSIDs from uSID1 to uSIDn in the first destination address field of the first message.
  • n is an integer greater than 1
  • the first identifier can be any uSID from uSID1 to uSIDn.
  • the first destination address field may also include: a first parameter field A0 located after the n uSIDs, and the first parameter field A0 may be shared by the n uSIDs. That is, the first parameter field A0 can correspond to each uSID in the first destination address field.
  • the destination address field may include n parameter fields corresponding to the n uSIDs one-to-one, where each parameter field is located after the corresponding uSID and is immediately adjacent to the corresponding uSID.
  • the first parameter field may be a parameter field located after the first segment identifier. For example, assuming that the first segment identifier is uSID1, the first parameter field may be A1.
  • the third node can encapsulate the SRH in the first message, and the SRH includes the first segment identifier.
  • the SRH encapsulated by the third node in the first message may include segment list [0] to segment list [n], a total of n+1 Identification field, the first segment identifier can be carried in any segment list from segment list [0] to segment list [n].
  • the first parameter field may be included in the first segment identification.
  • the SRH encapsulated by the third node in the first message may include one or more G-SID bearers (containers).
  • the G-SID bearer may include G-SID0 to G-SIDn, a total of n+1 G- SID, the first segment identifier can be any G-SID from G-SID0 to G-SIDn.
  • each identification field can carry the SID of a node, or can carry a uSID block and multiple uSIDs, for example, it can carry a uSID bearer such as shown in Figure 5.
  • the first segment identifier may be carried in any uSID bearer, the first parameter field may be located after the first segment identifier, and the location of the first parameter field may refer to Figure 12 or Figure 13.
  • Step 202 The third node sends the first message to the first node.
  • the first node After the first node encapsulates the first segment identifier in the first message, it can send the first message to the first node. Wherein, if the first node is the next hop node of the third node, the third node can directly send the first message to the first node. If the first node is not the next hop node of the third node, the third node can forward the first message to the first node through other intermediate nodes.
  • Step 203 The third node encapsulates the second segment identifier in the second packet of the target service flow.
  • the second message is also encapsulated with a second parameter field corresponding to the second segment identifier.
  • the second parameter field can indicate at least one second processing behavior, that is, the second parameter field is also a structured parameter field.
  • the at least one second processing behavior is different from the at least one first processing behavior indicated by the first parameter field.
  • the at least one second processing behavior being different from the at least one first processing behavior may mean that the at least one second processing behavior does not have the same processing behavior as the at least one first processing behavior, or that the at least one second processing behavior is different from the at least one first processing behavior. Only part of at least one first processing act is the same.
  • the first parameter field may include at least one first behavior instruction, and the at least one first behavior instruction is used to indicate the at least one first processing behavior.
  • the second parameter field may include at least one second behavior instruction, the at least one second behavior instruction being used to indicate the at least one second processing behavior.
  • the multiple behavior instructions used to instruct the multiple processing behaviors cannot be carried by multiple parameter fields.
  • Each parameter field can carry some behavioral instructions, and different parameter fields can carry different behavioral instructions.
  • each parameter field may correspond to a segment identifier (ie, be associated with a segment identifier), and different parameter fields may correspond to different segment identifiers.
  • the third node when the third node (or controller) compiles the segment list of the forwarding path of the target service flow, it can generate multiple segment lists based on the multiple segment identifiers associated with the above parameter fields, and then generate multiple SRv6 policies (policy). ).
  • the third node can use different SRv6 policies for different packets of the target service flow, that is, encapsulate different segment identifiers and their corresponding parameter fields.
  • the third node can use different SRv6 policies for different packets of the target service flow through load balancing, polling, randomization or other methods.
  • the nodes in the forwarding path can be enabled to perform different processing behaviors, thereby enabling the above-mentioned multiple processing behaviors to be executed.
  • nodes in the forwarding path can perform different processing behaviors on different packets of the target service flow.
  • the nodes indicated by the multiple segment identifiers can be the same.
  • the first segment identifier and the second segment identifier may indicate the same node, for example, they may both indicate the first node.
  • the parameter field carries the slice information of the network slice and the application awareness information
  • the second parameter field can carry flow detection information.
  • the first parameter field may be associated with the first segment identifier SID1
  • the second parameter field may be associated with the second segment identifier SID2.
  • the first segment identifier SID1 and the second segment identifier SID2 may indicate the same node in the forwarding path of the target service flow.
  • the third node can arrange 2 segment lists and can Generate 2 SRv6 policies corresponding to the 2 segment lists. For example, the third node can generate SRv6 policy1 corresponding to segment list 1, which is: SID1-SID R-SID S-SID T. The third node can generate SRv6 policy2 corresponding to segment list 2.
  • the segment list 2 is: SID2-SID R-SID S-SID T.
  • the third node uses polling or load balancing to use different SRv6 policies for the messages of the target service flow. Then the third node can use SRv6 policy1 for message 1, message 3, message 5, message 7 and message 9. That is, the third node can encapsulate the segment list 1 in the above message (ie, the first message), and the segment list 1 includes the first segment identifier SID1 associated with the first parameter field. Moreover, the third node can use SRv6 policy2 for message 2, message 4, message 6, message 8 and message 10.
  • the third node can encapsulate the segment list 2 in the above message (ie, the second message), and the segment list 2 includes the second segment identifier SID2 associated with the second parameter field.
  • the node indicated by SID1 can forward message 1, message 3, message 5, message 7 and message 9 based on the network slice and the network service indicated by the application awareness information.
  • the node indicated by SID2 can perform flow-following detection on message 2, message 4, message 6, message 8 and message 10.
  • the nodes in the forwarding path can perform the above three processing behaviors on the packets of the target service flow.
  • the structure and packaging position of the second segment identifier can be the same as the first segment identifier, and the structure and packaging position of the second parameter field can also be the same as the first parameter field, which will not be described again here.
  • Step 204 The third node sends the second message to the first node.
  • the third node may directly send the second message to the first node, or may forward the second message to the first node through other intermediate nodes.
  • Step 205 The first node determines the first parameter field from the first destination address field of the first message.
  • the first destination address field of the first message received by the first node includes a first segment identifier.
  • the first segment identifier may be directly encapsulated by the third node in the first destination address field, or may be copied from the SRH of the first message into the first destination address field by the previous hop node of the first node.
  • the first node can determine the first parameter field corresponding to the first segment identifier from the first destination address field of the first message.
  • the first parameter field may be included in the first segment identification.
  • the first node can determine the first parameter field from the first segment identifier. For example, referring to Figure 3, assuming that the first segment identifier is a 128-bit SRv6 SID, the first node may determine several low-order bits in the first segment identifier as the first parameter field.
  • the first parameter field may be located after the first segment identifier, and the first node may obtain the first destination address from the first destination address based on the preconfigured encapsulation position of the first parameter field in the first destination address field.
  • the first parameter field is determined in the address field.
  • the third node may determine several low-order bits in the first destination address field as the first parameter field.
  • the third node may determine several bits located after the first segment identifier and adjacent to the first segment identifier as the first parameter field.
  • the first node may be a node that supports SRv6 forwarding technology.
  • the first node may first detect whether the first segment identifier in the first destination address field of the first message is the first The local SID of the node. If the first segment identifier is the local SID of the first node, the first node can continue to determine the first parameter field from the first destination address field. If the first segment identifier is not the local SID of the first node, the first node does not need to determine the first parameter field from the first destination address field, and further does not need to process the first parameter field.
  • the first node may also be a node that does not support SRv6 forwarding technology.
  • the first node can determine the first parameter field from the first destination address field of the first message based on its local configuration information. Therefore, nodes that do not support SRv6 forwarding technology can also perform At least one first processing act as described above.
  • the local configuration information can indicate the position of the first parameter field in the first destination address field.
  • the local configuration information may be configured by operation and maintenance personnel, or may be issued by the controller.
  • Step 206 The first node identifies at least one first behavioral instruction carried in the first parameter field.
  • the first parameter field may carry at least one first line instruction. After the first node determines the first parameter field from the first destination address field, it can identify at least one first behavioral instruction carried in the first parameter field. Wherein, each first line instruction may indicate a first processing action. Each first processing behavior may be a processing behavior for the first message, or may be a processing behavior performed locally by the first node and unrelated to the first message.
  • the first parameter field may include at least one of a first subfield, a second subfield, a third subfield, a fourth subfield, a fifth subfield and a sixth subfield.
  • Each subfield can carry a first behavior instruction, and the first behavior instructions used by the six subfields can be as follows: the first subfield is used to carry the slice information of the network slice; the second subfield is used to carry the application Perception information; the third subfield is used to carry flow detection information; the fourth subfield is used to carry information about allocated network resources; the fifth subfield is used to carry the encryption method of encryption forwarding; the sixth subfield is used to carry Message authentication code used for security verification. That is to say, each of the above-mentioned slice information, application awareness information, flow detection information, network resource information, encryption method, and message authentication code is a first-behavior instruction.
  • the slice information of the network slice may include a slice ID.
  • Application aware information may also be called application aware network (application aware networking, APN) information, and the APN information may include at least one of a user group identifier and an application group identifier. Moreover, it may also include at least one of a flow identification, a service level agreement (service level agreement, SLA) level and a service requirement.
  • the service requirements can be requirements for performance indicators such as delay and packet loss rate.
  • the flow ID is also called a session ID.
  • the information of the in-situ detection may include IFIT information, such as flow monitoring ID, packet loss detection flag, delay detection flag, etc.
  • the information of the in-situ detection may also include in-situ operations, management and maintenance (In-situ Operations). , Administration, and Maintenance, IOAM) information.
  • the network resource information may include bandwidth resources of an interface used to forward packets.
  • Encryption methods may include media access control security (MACsec) encryption.
  • the message authentication code may include HMAC.
  • the first parameter field may also include at least one of the eighth subfield and the ninth subfield.
  • the eighth subfield is used to carry running status information
  • the ninth subfield is used to carry information about the entry to be established.
  • the running status information may include information indicating to adjust the running status of the first node to a sleep state or a shutdown state.
  • the information of the entry to be established may include: information used to instruct the first node to locally establish a flow table, a forwarding table and/or a state table for the traffic.
  • the first parameter field may also include at least one compression segment identifier. At least one first behavior instruction in the first parameter field may be located after the at least one compression segment identifier.
  • the first parameter field may include at least one uSID, and the at least one uSID may be shifted during the message forwarding process.
  • the at least one first behavior instruction may not shift with the at least one uSID, that is, the position of the at least one first behavior instruction in the first parameter field is fixed.
  • the at least one first line instruction may also be shifted together with the at least one uSID.
  • the first parameter field may include a total of n-1 uSIDs from uSID2 to uSIDn, and the behavior instruction A1
  • m first behavioral instructions up to behavioral instructions Am, where m is an integer greater than or equal to 1.
  • uSID2 to uSIDn can be shifted during the message forwarding process.
  • the m first-line instructions are located at the end of the first parameter field and do not need to be shifted together with the uSID.
  • Step 207 The first node executes at least one first processing behavior indicated by the at least one first behavior instruction.
  • the first node can process the first message according to the at least one first processing behavior. For example, the first node may perform at least one of the following first processing actions on the first packet: forwarding the packet based on slice resources of the network slice; forwarding the packet based on the network service indicated by the application awareness information; following flow detection; based on allocation Network resources forward messages; encrypt forward messages; security verification.
  • the first node can directly execute the first processing behavior, and the first node does not need to perform the first processing behavior.
  • the content of the first message will be modified and the forwarding process of the first message will not be affected.
  • the first node may locally perform at least one of the following first processing behaviors: adjusting the operating status of the first node; and establishing a flow table, a forwarding table, and/or a status table for traffic locally on the first node.
  • the flow refers to the service flow to which the first message belongs, that is, the target service flow.
  • the at least one first processing behavior may include both processing behavior for the first message and processing behavior performed locally by the first node and unrelated to the first message.
  • the at least one first processing behavior may include: flow detection, and establishing a state table for the service flow to which the first message belongs.
  • the first identification section also includes a function field, which can be used to indicate the third processing behavior.
  • the first node After the first node identifies at least one first behavior instruction carried in the first parameter field and determines the third processing behavior indicated by the function field, it can process the first message according to the third processing behavior. If the at least one first processing behavior includes the processing behavior of the first message, the first node can process the first message according to the at least one first processing behavior and the third processing behavior, thereby obtaining the third message. arts.
  • the third processing behavior indicated by the function field in the first segment identifier may include: End, End.X, End.T, End.DT4, End.DT6, End.DT2M, etc.
  • the first parameter field can also be used to carry parameters of the third processing behavior. Since the first parameter field can also retain the function of the original parameter field, it can be effectively compatible with the original function.
  • the first parameter field may also include a seventh subfield, and the seventh subfield may be used to carry parameters of the third processing behavior.
  • the parameters of the third processing behavior may include: the parameters of the End.DT2M behavior, and/or the index of the compressed segment identifier.
  • the parameter of the End.DT2M behavior may be the Arg.FE2 parameter, and the parameter may include multicast and/or split horizon parameters.
  • the index of the compressed segment identifier may refer to the index of G-SID (G-SID index, SI).
  • the first node also needs to shift the compressed segment identifier when processing the first message.
  • the first parameter field may be shifted together with the first segment identifier. For example, referring to Figure 13, parameter field A1 may be shifted with uSID1, and parameter field A2 may be shifted with uSID1.
  • the first parameter field may not be shifted, that is, the encoding position of the first parameter field is fixed to facilitate reading by other nodes.
  • the first parameter field may also be shifted together with the multiple compression segment identifiers, which is not limited in the embodiment of the present application.
  • the first parameter field may also include a tenth subfield, the tenth subfield being used to carry a shift flag.
  • the shift flag may be used to indicate which bits in the first destination address field need to be shifted.
  • the first parameter field also includes at least one compression section identifier, the shift flag may be used to indicate which bits in the first parameter field need to be shifted.
  • the shift mark may indicate that bits 32 to 95 in the first destination address field are Bits are shifted.
  • the shift flag may indicate that bits 32 to 127 in the first destination address field are shifted. It is assumed that the first parameter field is located at bits 32 to 127 of the first destination address field, and bits 32 to 95 are the compressed segment identifiers, and bits 96 to 127 are the first line instructions. If the first parameter field is not shifted, the shift flag may indicate that bits 0 to 63 in the first parameter field are shifted. Alternatively, if the first parameter field also needs to be shifted, the shift flag may indicate that bits 0 to 95 in the first destination address field are shifted.
  • the first node may be configured with a structured parameter function, and the status of the structured parameter function of the first node may be an enabled state or a closed state. If the first node determines that its structured parameter function is in an enabled state, it may perform at least one first processing behavior indicated by the first parameter field.
  • the status of the structured parameter function of the first node may be configured locally, for example, by operation and maintenance personnel or the controller.
  • the first message received by the first node may also include a status enable flag, and the first node may enable its structured parameter function based on the status enable flag.
  • the first node determines that its structured parameter function is enabled, it can identify at least one first behavioral instruction carried in the first parameter field, and determine at least one first process indicated by the at least one first behavioral instruction. Behavior. If the first node determines that its structured parameter function is in a closed state, the first node may determine whether to process the first parameter field based on the type of the third processing behavior indicated by the function field in the first segment identification. For example, if the third processing behavior indicated by the function field requires parameters, the first node can read the parameters of the third processing behavior from the first parameter field. If the third processing behavior indicated by the function field does not require parameters, the first node does not need to process the first parameter field.
  • the encapsulation position of the parameters of the third processing behavior in the first parameter field may be locally configured in the first node, or may be system preset or fixed configuration, or may be standardized.
  • the first node determines that the first parameter field is a structured parameter field based on the behavior indicated by the function field in the first segment identification (ie, the third processing behavior) or behavioral characteristics (flavor) , then at least one first processing behavior indicated by the first parameter field can be performed.
  • a new SRv6 behavior characteristic may be defined in the first node, and the flavor may be associated with the behavior indicated by the function field in at least one SID, or may be associated with the at least one SID.
  • the parameter fields corresponding to the at least one SID are all structured parameter fields. Based on this, if the first node determines that the third processing behavior indicated by the function field in the first segment identifier is associated with the new flavor, it can determine that the first parameter field is a structured parameter field, and then can identify that the first parameter field carries At least one of the first lines of instructions.
  • the association between the flavor and the behavior indicated by the function field in the SID may mean that the behavior indicated by the function field in the SID includes, in addition to the regular SRv6 behavior (behavior), additional behaviors indicated by the flavor.
  • the additional behavior may be variants of regular SRv6 behavior, and the additional behavior may include: processing the first parameter field according to the processing method of the structured parameter field.
  • Step 208 The first node determines the second parameter field from the second destination address field of the second message.
  • the first node may also determine the second parameter field from the second destination address field of the second message.
  • the second parameter field corresponds to the second segment identifier in the second destination address field.
  • step 208 the process of determining the second parameter field by the first node may be the same as the process of determining the first parameter field described above. Therefore, for the implementation process of step 208, reference can be made to the relevant description of step 205 above, which will not be described again here.
  • Step 209 The first node performs at least one second processing behavior indicated by the second parameter field.
  • the at least one second processing act may be different from the at least one first processing act.
  • the first node may first identify at least one second behavior instruction from the second parameter field, and determine what the at least one second behavior instruction indicates. At least one secondary processing act. Afterwards, the first node can perform the at least one second processing behavior. For example, the first node may process the second message according to the at least one second processing behavior. Alternatively, the first node may locally execute at least one second processing line unrelated to the second message.
  • the at least one second processing behavior may include at least one of the following behaviors: forwarding messages based on slice resources of network slicing; forwarding messages based on network services indicated by application awareness information; following flow detection; based on allocated network Resource forwarding messages; encrypted forwarding messages; security verification.
  • the at least one second processing behavior may include at least one of the following behaviors: adjusting the operating status of the first node; establishing a flow table, a forwarding table and/or a status table for traffic locally on the first node.
  • step 209 may refer to the relevant descriptions of step 206 and step 207 above.
  • Step 210 The first node sends the third message to the second node.
  • the first node may send a third message to the second node, where the third message is a message obtained based on the first message.
  • the second node may be the next hop node of the first node.
  • the third destination address field of the third message may include a third segment identifier, and the third segment identifier may be the local SID of the second node.
  • the first segment identifier and the third segment identifier may both be SRv6 SIDs with a length of 128 bits, or the first segment identifier and the third segment identifier may both be compressed segment identifiers.
  • the first identifier may be uSID1
  • the second identifier may be uSID2.
  • the first segment identifier may be G-SID0
  • the second segment identifier may be G-SID1.
  • Step 211 The second node determines the third parameter field from the third destination address field of the third message.
  • the third parameter field corresponds to the third segment identifier, and the way in which the second node determines the third parameter field can be the same as the way in which the first node determines the first parameter field described above, so no details are given here.
  • the third parameter field may be included in the third segment identifier.
  • the third segment identifier is a compressed segment identifier, and the third destination address field has a parameter field corresponding to each uSID, the third parameter field may be adjacent to the third segment identifier and located in the third segment After identification.
  • the third parameter field and the first parameter field are different fields.
  • the third parameter field and the first parameter field may be the same. field.
  • the first parameter field and the third parameter field are both A0.
  • Step 212 The second node performs at least one fourth processing behavior indicated by the third parameter field.
  • the process by which the second node determines at least one fourth processing behavior indicated by the third parameter field may be the same as the process by which the first node determines at least one first processing behavior indicated by the first parameter field. Therefore, the implementation process of step 212 may refer to the related descriptions of step 206 and step 207 above.
  • the at least one fourth processing behavior and the at least one first processing behavior may be the same.
  • one parameter field can be used to guide different nodes in the forwarding path to perform the same processing behavior. For example, referring to Figure 12, n nodes indicated by uSID1 to uSIDn can all perform the same processing behavior under the guidance of parameter field A0.
  • the at least one fourth processing behavior and the at least one first processing behavior may be the same or different.
  • different parameter fields can be used to cause different nodes in the forwarding path to all perform the same processing.
  • Behavior For example, referring to Figure 2, the SIDs carried in segment list [0] to segment list [n] can all contain the same parameter field, so that different nodes in the forwarding path all perform the same processing behavior.
  • the at least one fourth processing behavior is different from the at least one first processing behavior, different nodes in the forwarding path can be caused to perform different processing behaviors through different parameter fields.
  • the parameter fields A1 to An in the destination address field may not be exactly the same, so that different nodes in the forwarding path can perform different processing behaviors.
  • the first node may also send a fourth message obtained by processing the second message to the second node, and the fourth destination address field of the fourth message includes the fourth message.
  • the second node may determine a fourth parameter field corresponding to the fourth segment identification from the fourth destination address field, and perform at least one processing behavior indicated by the fourth parameter field.
  • the process of the second node performing at least one processing behavior indicated by the fourth parameter field reference may be made to the above steps 211 and 212, which will not be described again here.
  • the message forwarding system may include nodes that support the SRv6 forwarding technology, or may include nodes that do not support the SRv6 forwarding technology.
  • the structured parameter function of nodes that support SRv6 forwarding technology may be on or off. Based on this, if nodes in the message forwarding system need to identify and parse structured parameter fields, when planning the message forwarding path, they can avoid the above-mentioned nodes that do not support the SRv6 forwarding technology, and support SRv6 forwarding technology, but the structure The node whose parameterization function is turned off.
  • the packet forwarding path needs to include the above-mentioned nodes that do not support the SRv6 forwarding technology, or nodes whose structured parameter function is turned off, you can use local configuration to enable the above-mentioned nodes to change the destination address field of the message.
  • Some bits in are read and parsed as structured parameter fields. That is, the node can determine the structured parameter field from the destination address field of the message through local configuration information, and identify at least one behavioral instruction in the structured parameter field. Since the above node identifies and parses the structured parameter field based on local configuration information, the structured parameter field is no longer associated with the SRv6 function, but is associated with the function indicated by the above configuration information, or is implemented as an independent function.
  • the following describes the process in which the first node identifies at least one first behavior instruction from the first parameter field in step 206.
  • the first node is pre-configured with a first parameter field template, and the first node can identify at least one subfield included in the first parameter field based on the first parameter field template, and then At least one first line instruction carried by the at least one subfield is identified.
  • the first parameter field template is used to define the type, position and/or length of at least one first line instruction carried by the first parameter field.
  • the first parameter field template is used to define the type, position and/or length of at least one subfield included in the first parameter field.
  • the first node can be pre-hardcoded with the types of each first behavior instruction contained in the first parameter field.
  • the first behavioral instruction is type A
  • the second behavioral instruction is type B.
  • the location of each first behavior instruction included in the first parameter field may be pre-hardcoded in the first node.
  • the position of the at least one first line instruction may be in the same order as when the first parameter field template defines the type and length of the at least one first line instruction. For example, assuming that the first line in the first parameter field template defines the length of behavior instruction A, the second line defines the length of behavior instruction B, and the third line defines the length of behavior instruction C, then the first parameter field
  • the three behavioral instructions carried can be arranged in the order of behavioral instruction A, behavioral instruction B and behavioral instruction C.
  • the length of each first line instruction included in the first parameter field can be pre-hardcoded in the first node, For example, every The length of a line of instructions can be n bits, where n is an integer greater than 1. Alternatively, the lengths of each first-behavior instruction contained in the first parameter field may be equal, and the first node may determine the length of each first-behavior instruction based on the total length of the first parameter field and the number of first-behavior instructions carried by the first parameter field.
  • the first line is the length of the instruction.
  • the first node can determine the number of m first behavior instructions for each first parameter field.
  • the length is z/m bits. Among them, z is an integer greater than 1, and m is an integer greater than or equal to 1.
  • the parameter field template can define that the 1st to xth bits in the first parameter field are used to carry the first line instruction X, the x+1 to yth bits are used to carry the first line instruction Y, and the yth bits are used to carry the first line instruction Y.
  • the +1 to z-th bits are used to carry the first line of instructions Z.
  • x and y satisfy: 0 ⁇ x ⁇ y ⁇ z.
  • the first node can identify the first behavior instruction X, the first behavior instruction Y and the first behavior instruction Z from the first parameter field.
  • the first parameter field template can be The following definitions are made: bits 1 to 8 are the first subfield, used to carry slice information; bits 9 to 24 are the second subfield, used to carry APN information; bits 25 to 32 are the third subfield, Used to carry information for flow detection.
  • the first node may be pre-configured with multiple different parameter field templates (templates), and a template identifier corresponding to each parameter field template.
  • the first parameter field also includes a template identifier, that is, template ID.
  • the first node determines the first parameter field from the destination address field, it can first identify the template ID from the first parameter field, and then determine the template ID for the destination address based on the corresponding relationship between the template ID and the first parameter template.
  • the first parameter field identifies the first parameter template. Afterwards, the first node can identify at least one first behavioral instruction in the first parameter field based on the first parameter field.
  • the position of the template ID in the first parameter field is pre-configured in the first node, and the first node can directly identify the template ID from the first parameter field based on the pre-configured position.
  • the last one or more bits of the first parameter field may be used to carry the template ID.
  • the fixed-length first parameter field may carry different numbers, different types, and/or different lengths of first line instructions. This effectively improves the flexibility when the first parameter field carries behavioral instructions, thereby improving the flexibility when the node executes processing behaviors.
  • the first node may be pre-configured with multiple different parameter field templates, and the behavior or behavior characteristics indicated by the segment identifier corresponding to each parameter field template.
  • the first node may determine the first parameter field template used to identify the first parameter field based on the corresponding relationship between the behavior or behavior characteristics indicated by the first segment identifier and the first parameter field template.
  • the behavior indicated by the segment identifier may refer to the behavior indicated by the function field in the segment identifier.
  • the first node can directly determine the corresponding first parameter field template based on the first segment identifier. Therefore, there is no need to carry the template ID in the first parameter field, and more bits can be reserved for the first behavior. instruction.
  • each flavor corresponds to (ie is associated with) a parameter field template.
  • each flavor is associated with a behavior indicated by a segment identifier, or each flavor is associated with a segment identifier.
  • the behavior indicated by the segment identifier may refer to the processing behavior indicated by the function field in the segment identifier, and the processing behavior may include regular SRv6 behavior (behavior), and additional behaviors indicated by the flavor associated with the segment identifier.
  • the additional behavior may include: parsing the first parameter field according to the specified parameter field template.
  • Flavor 1 a total of two flavors, Flavor 1 and Flavor 2 can be defined in the first node.
  • Flavor 1 is related to Template 1
  • Flavor 2 is associated with Template 2 and is associated with the second segment ID SID2.
  • template 1 defines two first-behavior instructions carrying slice information and APN information in the parameter field, as well as the arrangement order and length of the two behavioral instructions.
  • Template 2 defines that the parameter field carries the flow detection information, as well as the position, name, and length of each field included in the flow detection information.
  • the first node can use template 1 to parse the first parameter field corresponding to the SID1, To identify the two first line instructions in the first parameter field, namely slice information and APN information. If the second segment identifier in the second destination address field of the second message received by the first node is SID2, the first node can use template 2 to parse the second parameter field corresponding to the SID2 to identify the A second line instruction in the second parameter field is information for flow detection.
  • all or some nodes in the message forwarding system may be configured with parameter field templates. Some of the nodes may be nodes that need to parse structured parameter fields.
  • the first parameter field may include at least one flag bit in the form of a bitmap, and each flag bit corresponds to a first line instruction.
  • each flag bit may be used to indicate whether the first parameter field carries its corresponding first behavior instruction.
  • each flag bit may be used to indicate whether a corresponding behavioral instruction in the first parameter field can be recognized. Among them, if a certain flag bit indicates that a corresponding behavioral instruction can be recognized, it indicates that the behavioral instruction is valid; if a certain flag bit indicates that a corresponding behavioral instruction cannot be recognized, it indicates that the behavioral instruction is invalid (invalid ).
  • the flag bit For example, if the value of the flag bit is 1, it means that the first parameter field carries a corresponding first behavior instruction, or the corresponding first behavior instruction in the first parameter field can be recognized, that is, the first behavior The command is valid. If the value of the flag bit is 0, it means that the first parameter field does not carry a corresponding first line instruction, or the corresponding first line instruction cannot be recognized.
  • the failure of the first line instruction to be recognized may include the following situations: Case 1, the first line instruction has expired; Case 2, the first line instruction has been executed, and there is no need for the first node to execute it again; Case 3, it is not required The first node executes the first line instruction, or the first node needs to ignore the first line instruction.
  • a certain flag bit indicates that the first parameter field does not carry a corresponding first behavioral instruction, it indicates that the first behavioral instruction does not occupy the coding space of the first parameter field.
  • This encoding space can be used for other purposes, or left as a reserved field.
  • the first behavior instruction still exists in the first parameter field, that is, it still occupies the The encoding space of the first parameter field, but the first node will not recognize and execute the first line of instructions.
  • the first node can first identify at least one flag bit carried in the first parameter field, and then identify the at least one flag bit carried in the first parameter field. At least one first line directive. For example, the first node may determine at least one flag bit with a value of 1, and then identify at least one first line instruction corresponding to the at least one flag bit with a value of 1.
  • each flag bit in the first parameter field can be encoded starting from the most significant bit.
  • the three flag bits S, A, and I included in the first parameter field may be located in the high bit bits.
  • each flag bit in the first parameter field may be encoded starting from the least significant bit.
  • the three flag bits S, A, and I included in the first parameter field may be located in the low bits.
  • each flag bit in the first parameter field can be encoded at any other position.
  • the three flag bits S, A, and I included in the first parameter field may be located at the middle bit.
  • each flag bit in the first parameter field can be arranged continuously.
  • the three flag bits S, A and I in the first parameter field occupy three consecutive bits.
  • the flag bits in the first parameter field may also be arranged loosely.
  • the three flag bits S, A and I in the first parameter field can be arranged at intervals, and the bits after each flag bit are the first bits corresponding to the flag bit. Behavioral instructions.
  • the arrangement order of each first line instruction in the first parameter field and the arrangement order of the corresponding flag bits may be the same or different.
  • the flag bit S in the first parameter field corresponds to the first line instruction I-S
  • the flag bit A corresponds to the first line instruction I-A
  • the flag bit I corresponds to the first line instruction I-I.
  • the three flag bits in the first parameter field are arranged in the order of S, A and I
  • the three first line instructions corresponding to the three flag bits can be in accordance with The first row of instructions I-S
  • the first row of instructions I-A and the first row of instructions I-I are arranged in order.
  • the three first behavior instructions corresponding to the three flag bits may also be arranged in the order of the first behavior instruction I-S, the first behavior instruction I-I, and the first behavior instruction I-A.
  • first parameter field does not carry a first line instruction corresponding to a certain flag bit
  • other first line instructions can be filled in to form a compact field arrangement.
  • other first-line instructions may not be filled in, forming a dispersed or fixed-position arrangement.
  • the first parameter field does not carry the first line instruction I-A, then the three flag bits S, A and I in the first parameter field, And the remaining 2 first line instructions I-S and I-I can be arranged continuously.
  • the first parameter field does not carry the first line instruction I-A, then the remaining two first line instructions I-S and I-I in the first parameter field do not need to be filled, but are retained. in its original fixed position.
  • the redundant bits in the first parameter field i.e., free bits
  • the reservation may refer to keeping the originally filled content of the bit unchanged.
  • the redundant bits in the first parameter field may be occupied by other first-line instructions. Therefore, the length of other first-line instructions can be effectively increased so that the other first-line instructions contain more information. For example, referring to (a) in FIG. 20 , if the first parameter field does not carry the first behavioral instruction I-A, the first behavioral instruction I-S located before the first behavioral instruction I-A can occupy the space originally used to carry the first behavioral instruction I-A. several bits. Alternatively, referring to (b) in FIG. 20 , the first line instruction I-I located after the first line instruction I-A may occupy several bits originally used to carry the first line instruction I-A.
  • each flag bit in the first parameter field can be standardized and unified, or can be Customized within a network domain.
  • the first parameter field can not only indicate the processing behavior alone, but also the third parameter field can indicate the processing behavior independently.
  • the number and type of behavioral instructions carried in a parameter field can be flexibly adjusted. This effectively improves the flexibility of the first node in executing processing behavior according to the instructions of the first parameter field.
  • the first parameter field includes at least one first behavior instruction and other information, such as parameters of the third processing behavior, a shift flag, and/or at least one compression segment identifier, then the first The node can also identify other information in the first parameter field based on either of the above two implementation methods.
  • the first node can use the second parameter field template or bitmap to parse the second parameter field to identify at least one second behavioral instruction.
  • the second parameter field template may be determined based on the template ID in the second parameter field, or may be determined based on the behavior indicated by the second segment identifier.
  • the second parameter field template and the first parameter field template may be the same or different.
  • the sequence of steps in the message forwarding method provided by the embodiments of the present application can be appropriately adjusted, and the steps can also be increased or decreased accordingly according to the situation.
  • the above steps 203 and 204 may be performed before step 202.
  • the above steps 203 and 204, as well as steps 208 and 209 can be deleted according to circumstances.
  • the above steps 211 and 212 can be deleted according to circumstances, that is, the third node does not need to identify and parse the third parameter field.
  • first message, second message, third message and fourth message are only used to distinguish different messages.
  • the first parameter field, the second parameter field, the third parameter field and The fourth parameter field is only used to distinguish parameter fields in different messages, and the first processing behavior, second processing behavior, third processing behavior, and fourth processing behavior are only used to distinguish processing behaviors indicated by different fields.
  • the above-mentioned third message may also be called a second message
  • the third parameter field may also be called a second parameter field
  • fourth processing behavior may also be called a second processing behavior.
  • the embodiment of the present application provides a message forwarding method.
  • the destination address field of the first message received by the first node includes the first segment identifier, and the first node can determine the first parameter field corresponding to the first segment identifier from the destination address field, and can execute the first segment identifier.
  • a parameter field indicates at least one first processing action. Since the method provided by the embodiment of the present application can indicate the processing behavior through the first parameter field in the destination address field, compared with indicating the processing behavior by inserting an additional IPv6 extension header or extended TLV, the length of the message header can be effectively reduced. Improve data transmission efficiency. And because the first parameter field is a structured parameter field that can indicate one or more first processing behaviors, it can guide the first node to perform richer processing behaviors.
  • the forwarding path of the first message can be encoded in the destination address field, there is no need to insert SRH into the first message.
  • the instruction information indicating the packet processing behavior cannot be carried through the optional TLV field in the SRH or part of the DOH, the first parameter field in the destination address field can be used to guide the first node to perform rich processing behaviors. .
  • Figure 21 is a schematic structural diagram of a first node provided by an embodiment of the present application.
  • the first node can be applied to a message forwarding system such as that shown in Figure 1, and can implement the steps performed by the first node in the above method embodiment. step.
  • the first node includes:
  • the receiving module 301 is configured to receive a first message, where the first destination address field of the first message includes a first segment identifier.
  • the receiving module 301 please refer to the relevant descriptions of step 101 and step 202 in the above method embodiment.
  • the determining module 302 is configured to determine a first parameter field from the first destination address field, where the first parameter field corresponds to the first segment identifier.
  • the determination module 302 please refer to the relevant descriptions of steps 102 and 205 in the above method embodiment.
  • the processing module 303 is configured to perform at least one first processing behavior indicated by the first parameter field.
  • the processing module 303 please refer to the relevant description of step 103 in the above method embodiment.
  • the processing module 303 may be configured to identify at least one behavior instruction carried in the first parameter field, and execute at least one first processing behavior indicated by the at least one behavior instruction.
  • the processing module 303 For the functional implementation of the processing module 303, reference can also be made to the relevant descriptions of steps 206 and 207 in the above method embodiment.
  • the processing module 303 may be configured to identify at least one behavioral instruction carried in the first parameter field according to the parameter field template.
  • the parameter field template is used to define the type, position and/or length of at least one behavioral instruction carried by the first parameter field.
  • the first parameter field may also include a template identifier; the processing module 303 may also be configured to determine the parameter field template according to the corresponding relationship between the template identifier and the parameter field template.
  • the processing module 303 may also be configured to determine the parameter field template according to the corresponding relationship between the behavior or behavioral characteristics indicated by the first segment identification and the parameter field template.
  • the processing module 303 may be configured to identify at least one flag bit carried in the first parameter field, and identify at least one behavioral instruction carried in the first parameter field based on the at least one flag bit.
  • Each flag bit corresponds to a behavioral instruction and is used to indicate whether the first parameter field carries a corresponding behavioral instruction, or is used to indicate whether a corresponding behavioral instruction in the first parameter field can be recognized.
  • the processing module 303 may be configured to perform at least one first processing behavior indicated by the first parameter field based on the structured parameter function of the first node being enabled; or, based on the first segment identification
  • the behavior or behavior characteristics indicated by the function field determines that the first parameter field is a structured parameter field, and at least one first processing behavior indicated by the first parameter field is executed.
  • the first segment identifier is a compressed segment identifier, and the length of the compressed segment identifier is less than 128 bits, or the length of the first segment identifier is 128 bits.
  • the first parameter field is included in the first section identifier, or the first parameter field is located after the first section identifier.
  • the first packet belongs to the target service flow.
  • the receiving module 301 may also be configured to receive a second message of the target service flow, where the second destination address field of the second message includes a second segment identifier.
  • the receiving module 301 please refer to the relevant description of step 204 in the above method embodiment.
  • the determining module 302 may also be configured to determine a second parameter field from the second destination address field, where the second parameter field corresponds to the second segment identifier.
  • the determination module 302 For the functional implementation of the determination module 302, reference can also be made to the relevant description of step 208 in the above method embodiment.
  • the processing module 303 may also be configured to perform at least one second processing behavior indicated by the second parameter field. Wherein, the at least one second processing behavior is different from the at least one first processing behavior.
  • the processing module 303 please refer to the relevant description of step 209 in the above method embodiment.
  • the first segment of identification may also include a function field, where the function field is used to indicate the third processing behavior.
  • the processing module 303 may also be used to process the first message according to the third processing behavior.
  • the first parameter field is also used to carry parameters of the third processing behavior.
  • the parameters of the third processing behavior may include: the parameters of the End.DT2M behavior, and/or the index of the compression segment identifier.
  • the processing module 303 may be configured to process the first message according to at least one first processing behavior indicated by the first parameter field.
  • the at least one first processing behavior includes at least one of the following behaviors: forwarding messages based on slice resources of network slices; forwarding messages based on network services indicated by application awareness information; following flow detection; Network resources forward messages; encrypt forward messages; security verification.
  • the first parameter field includes at least one of a first subfield, a second subfield, a third subfield, a fourth subfield, a fifth subfield and a sixth subfield; wherein, the first subfield The field is used to carry the slice information of the network slice; the second subfield is used to carry the application awareness information; the third subfield is used to carry the information of the flow detection; the fourth subfield is used to carry the allocated Information about network resources; the fifth subfield is used to carry the encryption method of the encrypted forwarding; the sixth subfield is used to carry the message authentication code used for the security verification.
  • the first parameter field also includes a seventh subfield; the seventh subfield is used to carry parameters of the third processing behavior indicated by the function field in the first section identification.
  • the at least one first processing behavior may also include at least one of the following behaviors: adjusting the operating status of the first node; establishing a flow table, a forwarding table and/or a status table for traffic locally on the first node.
  • the determining module 302 may be configured to determine the first parameter field from the first destination address field based on determining that the first segment is identified as the local SID of the first node.
  • the first node does not support SRv6 forwarding technology; the determination module 302 may be configured to determine the first parameter field from the first destination address field based on the local configuration information of the first node.
  • the first parameter field may also include at least one compressed segment identifier, such as at least one uSID.
  • the embodiment of the present application provides a first node.
  • the destination address field of the first message received by the first node includes the first segment identifier, and the first node can determine the first parameter field corresponding to the first segment identifier from the destination address field, and can execute the At least one first processing action indicated by the first parameter field. Since the solution provided by the embodiment of the present application can indicate the processing behavior through the first parameter field in the destination address field, compared with indicating the processing behavior by inserting an additional IPv6 extension header or extended TLV, the length of the message header can be effectively reduced. Improve data transmission efficiency. And because the first parameter field is a structured parameter field that can indicate one or more first processing behaviors, it can guide the first node to perform richer processing behaviors.
  • Figure 22 is a schematic structural diagram of a third node provided by an embodiment of the present application.
  • the third node can be applied to a message forwarding system such as that shown in Figure 1, and can implement the steps performed by the third node in the above method embodiment. step.
  • the first node includes:
  • the encapsulating module 401 is used to encapsulate the first segment identifier in the first message.
  • the encapsulation module 401 please refer to the relevant description of step 201 in the above method embodiment.
  • Sending module 402 configured to send the first message so that the node that receives the first message determines the first parameter field from the first destination address field of the first message and executes the first parameter field At least one first processing action indicated.
  • the first parameter field corresponds to the first segment identifier.
  • the encapsulation module 401 can be used to encapsulate the first segment identifier in the first destination address field; or, encapsulate the SRH in the first message, and the SRH includes the first segment identifier.
  • the first packet belongs to the target service flow
  • the encapsulation module 401 can also be used to encapsulate the second segment identifier in the second packet of the target service flow.
  • the sending module 402 can also be used to send the second message, so that the node that receives the second message determines the second parameter field from the second destination address field of the second message, and executes the second message.
  • the two parameter field indicates at least one second processing action.
  • the second parameter field corresponds to the second segment identifier, and the at least one second processing behavior is different from the at least one first processing behavior.
  • the sending module 402 please refer to the relevant description of step 204 in the above method embodiment.
  • the node indicated by the first segment identifier is the same as the node indicated by the second segment identifier.
  • the first segment identifier is a compressed segment identifier, and the length of the compressed segment identifier is less than 128 bits; or, the length of the first segment identifier is 128 bits.
  • the first parameter field is included in the first section identifier, or the first parameter field is located after the first section identifier.
  • the embodiment of the present application provides a third node.
  • the third node can encapsulate the first message in the first message. segment identifier, and the node that receives the first message can determine the first parameter field corresponding to the first segment identifier from the destination address field of the first message, and can execute at least one of the first parameter fields indicated by the first parameter field.
  • One processing behavior Since the solution provided by the embodiment of the present application can indicate the processing behavior through the first parameter field in the destination address field, compared with indicating the processing behavior by inserting an additional IPv6 extension header or extended TLV, the length of the message header can be effectively reduced. Improve data transmission efficiency.
  • the first parameter field is a structured parameter field that can indicate one or more first processing behaviors, it can guide the first node to perform richer processing behaviors.
  • Figure 23 is a schematic structural diagram of a second node provided by an embodiment of the present application.
  • the second node can be applied to a message forwarding system such as that shown in Figure 1, and can implement the steps performed by the second node in the above method embodiment. step.
  • the second node includes:
  • the receiving module 501 is configured to receive a second message sent by the first node, where the second destination address field of the second message includes a second segment identifier.
  • the second message is obtained based on the first message received by the first node.
  • the receiving module 501 please refer to the relevant description of step 210 in the above method embodiment.
  • the determining module 502 is configured to determine a second parameter field from the second destination address field, where the second parameter field corresponds to the second segment identifier.
  • the determination module 502 please refer to the relevant description of step 211 in the above method embodiment.
  • the processing module 503 is configured to perform at least one second processing behavior indicated by the second parameter field.
  • the processing module 503 please refer to the relevant description of step 212 in the above method embodiment.
  • the first parameter field and the second parameter field may be the same field.
  • the at least one first processing behavior and the at least one second processing behavior are the same.
  • the first segment identifier and the second segment identifier are both compressed segment identifiers, and the length of the compressed segment identifier is less than 128 bits; or, the length of the first segment identifier and the second segment identifier is both 128 bits.
  • the first parameter field is included in the first section identifier, and the second parameter field is included in the second section identifier; or, the first parameter field is located after the first section identifier, and the second parameter field is located After the second paragraph of logo.
  • the embodiment of the present application provides a second node.
  • the destination address field of the second message received by the second node includes the second segment identifier, and the second node can determine the second parameter field corresponding to the second segment identifier from the destination address field, and can execute the At least one second processing action indicated by the second parameter field. Since the solution provided by the embodiment of the present application can indicate the processing behavior through the first parameter field in the destination address field, compared with indicating the processing behavior by inserting an additional IPv6 extension header or extended TLV, the length of the message header can be effectively reduced. Improve data transmission efficiency.
  • the first node, the second node and the third node provided by the embodiments of the present application can also be implemented using an application-specific integrated circuit (ASIC) or a programmable logic device (programmable logic device).
  • ASIC application-specific integrated circuit
  • programmable logic device programmable logic device
  • the above PLD can be a complex programmable logical device (CPLD), a field-programmable gate array (FPGA), a general array logic (GAL) or any combination thereof .
  • the message receiving method, message sending method or message forwarding method provided by the above method embodiment can also be implemented through software.
  • the first node, the second node and Each functional module in the third node can also be a software module.
  • Figure 24 is a schematic structural diagram of a network device provided by an embodiment of the present application.
  • the network device may be applied to a system such as that shown in Figure 1, and may be a first node, a second node or a third node in the system.
  • the network device includes: a processor 601, a memory 602, a network interface 603 and a bus 604.
  • the computer program 6021 is stored in the memory 602, and the computer program 6021 is used to implement various application functions.
  • the processor 601 is configured to execute the computer program 6021 to implement the method provided by the above method embodiment and applied to the first node, the second node or the third node.
  • the processor 601 is used to execute the computer program 6021 to implement the functions of each module in the node shown in Figure 21, Figure 22 or Figure 23.
  • the processor 601 may be a central processing unit (CPU).
  • the processor 601 may also be other general-purpose processors, digital signal processors (DSP), ASICs, FPGAs, or graphics processing units. unit, GPU) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc.
  • DSP digital signal processor
  • a general purpose processor can be a microprocessor or any conventional processor.
  • Memory 602 may be volatile memory or non-volatile memory, or may include both volatile and non-volatile memory.
  • non-volatile memory can be read-only memory (ROM), programmable ROM (PROM), erasable programmable read-only memory (erasable PROM, EPROM), electrically removable memory. Erase electrically programmable read-only memory (EPROM, EEPROM) or flash memory.
  • Volatile memory can be random access memory (RAM), which is used as an external cache.
  • RAM static random access memory
  • DRAM dynamic random access memory
  • SDRAM synchronous dynamic random access memory
  • double data rate synchronous dynamic random access memory double data date SDRAM, DDR SDRAM
  • enhanced synchronous dynamic random access memory enhanced SDRAM, ESDRAM
  • synchronous link dynamic random access memory direct rambus RAM, DR RAM
  • the network interfaces 603 are used to implement communication connections with other devices (which may be wired or wireless). Among them, in this embodiment of the present application, the network interface 603 is used to send and receive messages. Among them, other devices may be terminals, servers, VMs and other devices or other network devices.
  • the bus 604 is used to connect the processor 601, the memory 602 and the network interface 603. Furthermore, in addition to the data bus, the bus 604 may also include a power bus, a control bus, a status signal bus, etc. However, for the sake of clarity, the various buses are labeled bus 604 in the figure.
  • the processor 601 is configured to receive a first message through the network interface 603.
  • the first destination address field of the first message includes a first segment identifier, and is configured to receive the first message from the first destination.
  • a first parameter field is determined in the address field, and at least one first processing behavior indicated by the first parameter field is performed.
  • the first parameter field corresponds to the first segment identifier.
  • the processor 601 is configured to encapsulate the first segment identifier in the first message and send the first message so that the node that receives the first message can obtain the first segment identifier from the first message.
  • the first parameter field is determined in the first destination address field, and at least one first processing behavior indicated by the first parameter field is performed.
  • the first parameter field corresponds to the first segment identifier.
  • the processor 601 is configured to receive a second message sent by the first node through the network interface 603, where the second destination address field of the second message includes a second segment identifier, and for from the second destination address field A second parameter field is determined, and at least one second processing action indicated by the second parameter field is performed.
  • the second parameter field corresponds to the second segment identifier.
  • Figure 25 is a schematic structural diagram of another network device provided by an embodiment of the present application.
  • the network device can be applied to a system such as that shown in Figure 1, and can be a first node, a second node or a third node in the system.
  • the network device may include: a main control board 701 and at least one interface board (the interface board is also called a line card or a service board).
  • the interface board is also called a line card or a service board.
  • Figure 25 shows an interface board 702 and an interface board 703.
  • the network device may also include a switching network board 704, which is used to complete data exchange between the interface boards.
  • the main control board 701 is also called a main processing unit (MPU) or a route processor card.
  • the main control board 701 is used to complete functions such as system management, equipment maintenance, and protocol processing.
  • the main control board 701 includes: a central processing unit 7011 and a memory 7012.
  • the interface boards 702 and 703 are also called line processing unit (LPU), line card (line card) or service boards.
  • the interface boards are used to provide various service interfaces and implement packet forwarding.
  • the service interfaces provided by the interface board can include: SONET/SDH-based packet (packet over SONET/SDH, POS) interface, Gigabit Ethernet (gigabit Ethernet, GE) interface and asynchronous transfer mode (asynchronous transfer mode, ATM) interface, etc.
  • SONET refers to synchronous optical network (synchronous optical network)
  • SDH refers to synchronous digital hierarchy (synchronous digital hierarchy).
  • the main control board 701, the interface board 702 and the interface board 703 are connected to the system backplane through a system bus to achieve intercommunication.
  • the interface board 702 includes one or more central processors 7021.
  • the central processor 7021 is used to control and manage the interface board 702 and communicate with the central processor 7011 on the main control board 701 and the interface board 702 .
  • the memory 7024 on the interface board 702 is used to store forwarding entries, and the network processor 7022 can forward messages by searching for the forwarding entries stored in the memory 7024.
  • Memory 7024 may also be used to store program code.
  • the interface board 702 also includes one or more physical interface cards 7023.
  • the one or more physical interface cards 7023 are used to receive messages sent by the previous hop node and send them to the next hop node according to the instructions of the central processor 7021. processed message.
  • the central processor 7021 and/or the network processor 7022 in the interface board 702 in Figure 25 can be dedicated hardware or chips.
  • an ASIC can be used to implement the above functions.
  • This implementation method is generally The forwarding plane is processed by dedicated hardware or chips.
  • the central processor 7021 and/or the network processor 7022 may also use a general-purpose processor, such as a general-purpose CPU, to implement the functions described above.
  • main control boards 701 there may be one or more main control boards 701 , and when there are multiple main control boards, they may include a main main control board and a backup main control board. There may be one or more interface boards. The stronger the data processing capability of the network device, the more interface boards are provided.
  • the network device includes an interface board 702 and an interface board 703.
  • the structure of the interface board 703 is basically the same as that of the interface board 702, and the operations on the interface board 703 are basically similar to the operations on the interface board 702. For the sake of simplicity, they will not be described again.
  • the multiple interface boards can communicate with each other through one or more switching network boards 704, and can realize load sharing and redundancy backup to provide large-capacity data exchange and processing capabilities. .
  • the network device does not need the switching network board 704, and the interface board is responsible for processing the service data of the entire system. Therefore, the data access and processing capabilities of network equipment with a distributed architecture are greater than those with a centralized architecture.
  • the specific architecture used depends on the specific networking deployment scenario and is not limited here.
  • the memory 7012 and the memory 7024 can be ROM or other types of static storage devices that can store static information and instructions, or RAM or other types of dynamic storage devices that can store information and instructions. They can also be It is EEPROM, compact disc read-only memory (CD-ROM) or other optical disc storage, optical disc storage (including compressed optical disc, laser disc, optical disc, digital versatile disc, Blu-ray disc, etc.), magnetic disk or other magnetic storage device , or any other medium that can be used to carry or store desired program code in the form of instructions or data structures and that can be accessed by a computer, but is not limited thereto.
  • EEPROM compact disc read-only memory
  • CD-ROM compact disc read-only memory
  • optical disc storage including compressed optical disc, laser disc, optical disc, digital versatile disc, Blu-ray disc, etc.
  • magnetic disk or other magnetic storage device or any other medium that can be used to carry or store desired program code in the form of instructions or data structures and that can be accessed by a computer, but is not limited thereto.
  • the memory 7024 in the interface board 702 can exist independently and be connected to the central processor 7021 through a communication bus; or the memory 7024 can also be integrated with the central processor 7021.
  • the memory 7012 in the main control board 701 can exist independently and be connected to the central processor 7011 through a communication bus; or the memory 7012 can also be integrated with the central processor 7011.
  • the program code stored in the memory 7024 is controlled and executed by the central processor 7021, and the program code stored in the memory 7012 is controlled and executed by the central processor 7011.
  • the central processor 7021 and/or the central processor 7011 can implement the method executed by any node provided by the above method embodiments by executing program codes.
  • One or more software units may be included in the program code stored in memory 7024 and/or memory 7012. This one or more software units may be functional modules shown in any of the figures in Figures 21 to 23.
  • the physical interface card 7023 can be any device such as a transceiver, used to communicate with other devices or communication networks, such as Ethernet, radio access network (radio access network, RAN), Wireless local area networks (WLAN), etc.
  • a transceiver used to communicate with other devices or communication networks, such as Ethernet, radio access network (radio access network, RAN), Wireless local area networks (WLAN), etc.
  • the device shown in any one of Figures 21 to 24 can also be implemented using the structure shown in Figure 25.
  • Embodiments of the present application also provide a computer-readable storage medium. Instructions are stored in the computer-readable storage medium. When the instructions are run on a processor, they cause the processor to execute the steps performed by the first node, Steps performed by the second or third node.
  • Embodiments of the present application also provide a computer program product containing instructions. When the instructions are run on a processor, they cause the processor to execute what is executed by the first node, the second node, or the third node in the above method embodiment. step.
  • the embodiment of the present application also provides a message forwarding system.
  • the message forwarding system includes multiple nodes 01.
  • the plurality of nodes 01 include a first node, and the first node can be used to implement the method performed by the first node in the above method embodiment.
  • the plurality of nodes 01 may also include second nodes and/or third nodes.
  • the second node can be used to implement the method executed by the second node in the above method embodiment
  • the third node can be used to implement the method executed by the third node in the above method embodiment.
  • the structure of the first node can be as shown in Figure 21, Figure 24 or Figure 25, the structure of the third node can be as shown in Figure 22, Figure 24 or Figure 25, and the structure of the second node can be as shown in Figure 23 , as shown in Figure 24 or Figure 25.
  • the terms “first”, “second” and “third” are only used for description purposes and cannot be understood as indicating or implying relative importance.
  • the term “and/or” in this application is just an association relationship describing related objects, indicating that there can be three relationships, for example, A and/or B, which can mean: A exists alone, A and B exist simultaneously, alone There are three situations B.
  • the character "/" in this article generally indicates that the related objects are an "or" relationship.

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

本申请提供了一种报文接收方法、发送方法、转发方法、装置及系统,属于通信技术领域。在本申请提供的方案中,第一节点接收到的报文的目的地址字段中包括段标识,第一节点能够从该目的地址字段中确定与该段标识对应的参数字段,并可以执行该参数字段指示的处理行为。由于本申请提供的方案能够通过目的地址字段中的参数字段指示处理行为,因此相比于通过额外插入IPv6扩展头或者扩展TLV来指示处理行为,可以有效缩减报文头的长度,提高数据的传输效率。又由于该第一参数字段是能够指示一个或多个处理行为的结构化参数字段,因此可以指导第一节点执行较为丰富的处理行为。

Description

报文接收方法、发送方法、转发方法、装置及系统
本申请要求于2022年5月28日提交的申请号为202210595079.1、发明名称为“一种实现结构SRv6 SID Argument的方法”的中国专利申请的优先权,以及要求于2022年7月18日提交的申请号为202210843988.2、发明名称为“报文接收方法、发送方法、转发方法、装置及系统”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。
技术领域
本申请涉及通信技术领域,特别涉及一种报文接收方法、发送方法、转发方法、装置及系统。
背景技术
在互联网协议第6版(Internet protocol version 6,IPv6)系统中,IPv6报文中可以插入多种IPv6扩展头,例如逐跳选项头(hop-by-hop options header,HBH)或目的选项头(destination options header,DOH)等。或者,在基于互联网协议第6版的段路由(segment routing based on Internet protocol version 6,SRv6)系统中,可以在该SRv6报文的SRH的类型-长度-值(type-length-value,TLV)字段中插入扩展TLV。
为了指导报文转发路径中的节点执行更丰富的报文处理行为,可以在上述IPv6扩展头或者SRH的TLV字段中携带指示报文处理行为的指令信息。例如,可以在HBH或DOH中插入指示网络切片信息的选项(option),以使转发路径中的节点基于指定的网络切片转发报文。或者,可以在SRH的TLV字段中插入带内流信息测量(in-situ flow information telemetry,IFIT)TLV,以使转发路径中的节点对流量进行随流检测。
但是,上述插入IPv6扩展头或者扩展TLV的方式均会增加报文头的长度,降低数据的传输效率。
发明内容
本申请提供了一种报文接收方法、发送方法、转发方法、装置及系统,可以解决为每个节点分别定义SID导致的报文转发的复杂度较高的技术问题。
第一方面,提供了一种报文接收方法,应用于报文转发系统中的第一节点;该方法包括:接收第一报文,该第一报文的第一目的地址字段包括第一段标识;从该第一目的地址字段中确定对应该第一段标识的第一参数字段,并执行该第一参数字段指示的至少一个第一处理行为。
本申请提供的方案能够通过目的地址字段中的参数字段指示处理行为,因此相比于通过额外插入IPv6扩展头或者扩展TLV来指示处理行为,可以有效缩减报文头的长度,即降低报文头开销,进而提高数据的传输效率。又由于该第一参数字段是能够指示一个或多个处理行为的结构化参数字段,因此可以指导第一节点执行较为丰富的处理行为。
可以理解的是,第一节点在确定第一参数字段指示的至少一个第一处理行为时,无需将该第一参数字段与第一段标识中的功能字段配合。也即是,第一参数字段无需与功能字段配合即可指示至少一个第一处理行为。
可选地,第一节点执行该第一参数字段指示的至少一个第一处理行为的过程可以包括: 识别该第一参数字段中携带的至少一个行为指令,并执行该至少一个行为指令指示的该至少一个第一处理行为。
其中,每个行为指令可以指示一个处理行为。由于第一参数字段能够携带一个或多个行为指令,且每个行为指令能够指示一个第一处理行为,因此有效提高了第一参数字段携带行为指令时的灵活性,进而提高了节点执行处理行为时的灵活性。
可选地,识别该第一参数字段中携带的至少一个行为指令的过程可以包括:根据参数字段模板,识别该第一参数字段中携带的该至少一个行为指令。其中,该参数字段模板可以用于定义该第一参数字段所携带的至少一个行为指令的类型、位置和/或长度。
基于该参数字段模板,可以确保第一节点能够准确且快速地识别出第一参数字段中携带的至少一个行为指令。
可选地,该第一参数字段还可以包括模板标识;该方法还可以包括:根据该模板标识与该参数字段模板的对应关系,确定该参数字段模板。
通过在第一参数字段中携带不同的模板标识,即可使得第一节点按照不同的模板标识指示的不同的参数字段模板,解析第一参数字段。基于此,可以灵活采用不同的参数字段模板对第一参数字段进行编码,从而有效提高了第一参数字段携带行为指令时的灵活性。
可选地,该方法还可以包括:根据该第一段标识指示的行为或行为特征与该参数字段模板的对应关系,确定该参数字段模板。
其中,段标识指示的行为(behavior)或行为特征(flavor)可以是指段标识中的功能字段指示的行为或行为特征。在本申请提供的方案中,参数字段模板还可以与该功能字段指示的行为或行为特征关联。例如,将特征的行为或行为特征与特定的参数字段模板相关联,当识别到该特定的行为或行为特征时,即可确定相应的参数字段模板,进而采用该参数字段模板对第一参数字段进行识别,读取其中携带的至少一个行为指令。由此,第一节点即可直接根据第一段标识确定对应的参数字段模板。由于该实现方式中无需在第一参数字段中携带模板ID,因此可以预留更多的比特位给第一行为指令。
可选地,识别该第一参数字段中携带的至少一个行为指令的过程可以包括:识别该第一参数字段中携带的至少一个标志位,并根据该至少一个标志位,识别该第一参数字段中携带的至少一个行为指令。其中,每个标志位对应一个行为指令。
可选地,每个标志位可以用于指示该第一参数字段中是否携带对应的一个行为指令,或者用于指示该第一参数字段中对应的一个行为指令是否能够被识别。其中,若某个标志位指示对应的一个行为指令能够被识别,则表明该行为指令有效,若某个标志位指示对应的一个行为指令不能够被识别,则表明该行为指令无效。
由于第一参数字段中的标志位能够指示第一参数字段中是否携带对应的一个行为指令,或对应的行为指令是否能被识别,因此可以根据应用场景的需求,灵活选择第一节点能够识别出的行为指令的个数。并且,当第一参数字段中未携带某个行为指令时,该行为指令所占用的比特位还可以用于携带其他行为指令,由此还能实现对行为指令的长度的灵活调节。
可选地,第一节点执行该第一参数字段指示的至少一个第一处理行为的过程可以包括:基于该第一节点的结构化参数功能处于启用状态,执行所述第一参数字段指示的至少一个第一处理行为;或者,根据该第一段标识中功能字段指示的行为或行为特征确定该第一参数字段为结构化参数字段,执行该第一参数字段指示的至少一个第一处理行为。
在本申请提供的方案中,第一节点可以在启用结构化参数功能,或者,确定第一参数字 段为结构化参数字段后,再执行该第一参数字段指示的至少一个第一处理行为。相应的,若第一节点未启用结构化参数功能,或者,识别出第一参数字段不是结构化参数字段,则可以无需按照结构化的方式解析该第一参数字段,进而不会执行该至少一个第一处理行为。
可选地,该第一段标识可以为压缩段标识,该压缩段标识的长度小于128比特。其中,该压缩段标识可以是压缩SID(compressed SID,CSID)、微型SID(micro SID,uSID)或通用SID(generalized SID,G-SID)。
可选地,该第一段标识的长度可以为128比特,即该第一段标识可以为普通的SRv6 SID。
可选地,该第一参数字段可以包括在该第一段标识中,或者,该第一参数字段位于该第一段标识之后。例如,若第一段标识为普通的SRv6 SID,则该第一段标识可以包括第一参数字段。若第一段标识为压缩段标识,则该第一参数字段可以位于该第一段标识之后。
可选地,该第一报文属于目标业务流,该方法还可以包括:接收该目标业务流的第二报文,该第二报文的第二目的地址字段包括第二段标识;从该第二目的地址字段中确定对应该第二段标识的第二参数字段,并执行该第二参数字段指示的至少一个第二处理行为。其中,该至少一个第二处理行为与该至少一个第一处理行为不同。
本申请提供的方案中,可以通过不同的参数字段指示不同的处理行为,以使得第一节点能够根据该不同的参数字段执行不同的处理行为。例如,对目标业务流的不同报文执行不同的处理行为。由此,可以在不增加参数字段的长度的前提下,使得第一节点能够执行较多数量的处理行为。
可选地,该第一段标识还可以包括功能字段,该功能字段用于指示第三处理行为。该方法还可以包括:按照该第三处理行为,处理该第一报文。
其中,该第三处理行为与至少一个第一处理行为不同。也即是,第一参数字段无需与功能字段配合,即可独立指示至少一个第一处理行为。
可选地,该第一参数字段还可以用于携带该第三处理行为的参数。也即是,第一参数字段还可以保留原有参数字段的功能,从而与原有功能兼容。
其中,该第三处理行为的参数可以包括:具有解封装和二层表泛洪的端点(Endpoint with decapsulation and L2 table flooding,End.DT2M)的行为的参数,和/或,压缩段标识的索引。
可选地,第一节点执行第一参数字段指示的至少一个第一处理行为的过程可以包括:按照该第一参数字段指示的至少一个第一处理行为,处理该第一报文。
可选地,该至少一个第一处理行为包括下述行为中的至少一个:基于网络切片的切片资源转发报文;基于应用感知信息所指示的网络服务转发报文;随流检测;基于分配的网络资源转发报文;加密转发报文;安全验证。
由于第一参数字段能够指示上述一个或多个第一处理行为,因此可以使得第一节点执行丰富的处理行为。
可选地,该第一参数字段可以包括第一子字段,第二子字段,第三子字段,第四子字段、第五子字段和第六子字段中的至少一个。其中,第一子字段用于携带网络切片的切片信息;第二子字段用于携带应用感知信息;第三子字段用于携带随流检测的信息;第四子字段用于携带该分配的网络资源的信息;第五子字段用于携带该加密转发的加密方式;第六子字段用于携带用于进行该安全验证的消息认证码。
可选地,该第一参数字段还可以包括第七子字段;该第七子字段用于携带第一段标识中的功能字段所指示的第三处理行为的参数。
可选地,该至少一个第一处理行为可以包括下述行为中的至少一个:调整第一节点的运行状态;在第一节点的本地为流量建立流表、转发表和/或状态表。
其中,流量可以是指第一报文所属的业务流。基于上述第一处理行为的举例可知,该至少一个第一处理行为还可以包括第一节点本地执行的与该第一报文无关的处理行为。也即是,第一节点执行第一处理行为不会修改第一报文的内容,也不影响第一报文的转发流程。
可选地,从该第一目的地址字段中确定第一参数字段的过程可以包括:基于确定该第一段标识为第一节点的本地SID,从该第一目的地址字段中确定第一参数字段。可以理解的是,若第一段标识不为第一节点的本地SID,则第一节点无需确定并处理该第一参数字段。
可选地,该第一节点不支持基于SRv6转发技术。相应的,从该第一目的地址字段中确定第一参数字段的过程可以包括:基于该第一节点的本地配置信息,从该第一目的地址字段中确定第一参数字段。
其中,该本地配置信息能够指示第一参数字段在第一目的地址字段中的位置。并且,该本地配置信息可以是运维人员配置的,或者可以是控制器下发的。
可选地,该第一参数字段还可以包括至少一个压缩段标识,例如可以包括至少一个uSID。并且,该至少一个第一行为指令可以位于该至少一个uSID之后。在报文转发过程中,该至少一个uSID可以移位。
第二方面,提供了一种报文发送方法,该方法可以应用于报文转发系统的头节点。该方法包括:在第一报文中封装第一段标识,并发送该第一报文。该第一报文用于供接收到该第一报文的节点从第一报文的第一目的地址字段中确定第一参数字段,并执行该第一参数字段指示的至少一个第一处理行为。其中,该第一参数字段对应该第一段标识。
可选地,在第一报文中封装第一段标识的过程可以包括:在第一目的地址字段中封装第一段标识;或者,在第一报文中封装SRH,该SRH中包括该第一段标识。其中,若第一段标识为uSID,且第一报文的转发路径中的各个节点能够在一个uSID承载器中编码完成,则可以直接通过第一目的地址字段携带该uSID承载器,即第一报文中无需再携带SRH。
可选地,该第一报文属于目标业务流,该方法还可以包括:在该目标业务流的第二报文中封装第二段标识,并发送该第二报文。该第二报文用于供接收到该第二报文的节点从该第二报文的第二目的地址字段中确定第二参数字段,并执行该第二参数字段指示的至少一个第二处理行为。其中,该第二参数字段对应该第二段标识,该至少一个第二处理行为与该至少一个第一处理行为不同。
可选地,该第一段标识指示的节点与该第二段标识指示的节点相同。
可选地,该第一段标识为压缩段标识,该压缩段标识的长度小于128比特;或者,该第一段标识的长度为128比特。
可选地,该第一参数字段包括在该第一段标识中,或者,该第一参数字段位于该第一段标识之后。
第三方面,提供了一种报文转发方法,应用于报文转发系统,该报文转发系统包括第一节点和第二节点。该方法包括:第一节点接收第一报文,该第一报文的第一目的地址字段包括第一段标识;第一节点从第一目的地址字段中确定第一参数字段,该第一参数字段对应第一段标识;第一节点执行该第一参数字段指示的至少一个第一处理行为。第二节点接收该第一节点发送的第二报文,该第二报文基于所述第一报文得到,且该第二报文的第二目的地址字段包括第二段标识;第二节点从该第二目的地址字段中确定第二参数字段,该第二参数字 段对应该第二段标识;第二节点执行该第二参数字段指示的至少一个第二处理行为。
可选地,该第一参数字段和第二参数字段可以为同一字段。也即是,第一节点在处理第一报文的过程中,可以对该第一目的地址字段中的段标识进行更新,而无需更新该第一参数字段。
可选地,该至少一个第一处理行为和该至少一个第二处理行为可以相同。
可选地,该第一段标识和第二段标识可以均为压缩段标识,该压缩段标识的长度小于128比特;或者,该第一段标识和第二段标识的长度可以均为128比特。
可选地,该第一参数字段可以包括在第一段标识中,该第二参数字段可以包括在第二段标识中。或者,该第一参数字段可以位于第一段标识之后,该第二参数字段可以位于第二段标识之后。
第四方面,提供了一种网络设备,该网络设备可以是报文转发系统中的第一节点或第三节点(即头节点)。该网络设备包括至少一个模块,该至少一个模块可以用于实现上述任一方面所提供的方法。
第五方面,提供了一种网络设备,该网络设备可以是报文转发系统中的第一节点或头节点。该网络设备包括:存储器,处理器及存储在该存储器上并可在该处理器上运行的计算机程序,该处理器执行该计算机程序时实现如上述任一方面所提供的方法。
第六方面,提供了一种网络设备,该网络设备可以是报文转发系统中的第一节点或头节点。该网络设备可以包括:主控板和接口板,该主控板和接口板可以用于实现上述任一方面所提供的方法。
第七方面,提供了一种计算机可读存储介质,该计算机可读存储介质中存储有指令,该指令由处理器执行以实现如上述任一方面所提供的方法。
第八方面,提供了一种包含指令的计算机程序产品,当该指令在处理器上运行时,使得处理器执行如上述任一方面所提供的方法。
第九方面,提供了一种报文转发系统,该报文转发系统包括:多个节点;其中,该多个节点中的至少一个节点能够实现上述第一方面所提供的报文接收方法。例如,该多个节点中的第一节点可以实现上述第一方面所提供的报文接收方法。该第一节点和第二节点还可以实现上述第三方面所提供的报文转发方法。
可选地,该多个节点中的至少一个节点(例如第三节点)还可以用于实现上述第二方面提供的报文发送方法。
第十方面,提供了一种芯片,该芯片可以用于实现上述任一方面所提供的方法。
综上所述,本申请提供了一种报文接收方法、发送方法、转发方法、装置及系统。本申请提供的方案中,第一节点接收到的报文的目的地址字段中包括段标识,第一节点能够从该目的地址字段中确定与该段标识对应的参数字段,并可以执行该参数字段指示的处理行为。由于本申请提供的方案能够通过目的地址字段中的参数字段指示处理行为,因此相比于通过额外插入IPv6扩展头或者扩展TLV来指示处理行为,可以有效缩减报文头的长度,提高数据的传输效率。又由于该第一参数字段是能够指示一个或多个处理行为的结构化参数字段,因此可以指导第一节点执行较为丰富的处理行为。
附图说明
图1是本申请实施例提供的一种报文转发系统的结构示意图;
图2是本申请实施例提供的一种SRv6报文的结构示意图;
图3是本申请实施例提供的一种SID的结构示意图;
图4是本申请实施例提供的一种压缩段标识的结构示意图;
图5是本申请实施例提供的一种uSID承载器的结构示意图;
图6是本申请实施例提供的一种HOH和DOH的结构示意图;
图7是本申请实施例提供的一种选项字段的结构示意图;
图8是本申请实施例提供的一种SRH的结构示意图;
图9是本申请实施例提供的一种HMAC TLV的结构示意图;
图10是本申请实施例提供的一种报文接收方法的流程图;
图11是本申请实施例提供的一种报文转发方法的流程图;
图12是本申请实施例提供的一种第一目的地址字段的结构示意图;
图13是本申请实施例提供的另一种第一目的地址字段的结构示意图;
图14是本申请实施例提供的一种G-SID承载器的结构示意图;
图15是本申请实施例提供的一种第一参数字段的结构示意图;
图16是本申请实施例提供的一种第一参数字段模板的示意图;
图17是本申请实施例提供的一种第一参数字段中各标志位的排列位置的示意图;
图18是本申请实施例提供的一种第一参数字段中各行为指令的排列顺序的示意图;
图19是本申请实施例提供的一种第一参数字段中多余比特位的填充方式的示意图;
图20是本申请实施例提供的一种第一参数字段中第一行为指令补位的示意图;
图21是本申请实施例提供的一种第一节点的结构示意图;
图22是本申请实施例提供的一种第三节点的结构示意图;
图23是本申请实施例提供的一种第二节点的结构示意图;
图24是本申请实施例提供的一种网络设备的结构示意图;
图25是本申请实施例提供的另一种网络设备的结构示意图。
具体实施方式
下面结合附图详细介绍本申请实施例提供的报文接收方法、发送方法、转发方法、装置及系统。
图1是本申请实施例提供的一种报文转发系统的结构示意图,如图1所示,该报文转发系统可以包括多个节点01,该多个节点01之间建立有通信连接。其中,每个节点01可以为路由器、交换机、宽带接入服务器(broadband remote access server,BRAS)、防火墙或虚拟网元等,且每个节点01也可以称为网络设备。
示例的,节点01可以为运营商(provider,P)设备或者运营商边缘(provider edge,PE)设备。若节点01为PE设备,则如图1所示,该报文转发系统还可以包括与该PE设备连接的用户边缘(customer edge,CE)设备02。该CE设备02与用户终端连接,并用于为用户终端提供网络接入服务。其中,用户终端也可以称为用户设备,其可以为家庭网关(residential gateway,RGW)、手机、笔记本电脑或者台式电脑等设备。
可选地,如图1所示,该报文转发系统还可以包括控制器03。控制器03与至少一个节点01连接,并用于管理和控制其所连接的节点01。其中,该控制器03可以为网络控制器。
在本申请实施例中,该报文转发系统可以为SRv6系统,该SRv6系统中各节点转发的报文 为SRv6报文,该SRv6报文是在IPv6报文中插入SRH得到的报文。图2是本申请实施例提供的一种SRv6报文的结构示意图,如图2所示,SRv6报文包括:IPv6头、SRH和载荷(payload)。其中,IPv6头包括如下字段:版本(version)、流分类(traffic class,TC)、流标签(flow label)、载荷长度(payload length)、下一头部(next header)、跳数限制(hop limit)、源地址(source address,SA)和DA。
SRH包括如下字段:下一头部、扩展头长度(header extension length,Hdr Ext Len)、路由头类型(routing type)、剩余分段(segment left,SL)个数、最后条目(last entry)、标记(flags)、标签(tag)、段列表以及可选TLV。其中,该段列表包括段列表[0]至段列表[n]共n+1个标识字段(n可以为大于或等于1的整数),每个标识字段用于携带报文转发路径中一个节点的SID,该SID可以为节点的IPv6地址。
图3是本申请实施例提供的一种SID的结构示意图。如图3所示,每个SID可以包括定位符(locator)字段、功能(function)字段和参数(arguments)字段。其中,定位符字段用于标识某个网络域以及该网络域中的某个节点。功能字段用于标识在相应的节点上执行的动作,也称为行为(behavior)。参数字段用于携带执行该动作所需的参数。
由于段列表中每个SID的长度一般为128比特(bit),因此当SRH中所需携带的SID的数量较多时,会显著增加报文头的长度,进而降低数据的传输效率。为了减小报文头的长度,业界提出了对SID进行压缩的方案。该压缩方案定义了一种压缩段标识,如图4所示,该压缩段标识可以包括节点(node)ID和功能(function)ID中的至少一个,图4以压缩段标识包括节点ID和功能ID为例进行示意。其中,节点ID能够与目的地址字段中的公共前缀(common prefix)组成定位符字段。该定位符字段、功能ID以及目的地址字段中的参数字段(或填充字段)可以组成一个128bit的SRv6 SID。
其中,若一个压缩段标识仅包括节点ID和功能ID中的一个ID,则可以通过相邻的两个压缩段标识分别携带节点ID和功能ID,从而实现对网络域中的某个节点的标识,以及对该节点所需执行的处理行为的标识。
可以理解的是,本申请实施例中所述的压缩段标识可以是CSID、uSID或G-SID。下文以uSID为例进行说明,如图5所示,uSID方案中定义了一种uSID承载器(container),该uSID承载器的结构可以为:<uSID块><活跃uSID><下一个uSID>...<最后一个uSID><填充部分>。其中,填充部分为可选的。
其中,uSID块(Block)是uSID的地址块,其可以是公共前缀,例如IPv6前缀。活跃uSID(Active uSID)是位于uSID块之后的第一个uSID。下一个uSID(Next uSID)是位于活跃uSID之后的uSID,uSID承载器中可以包括一个或多个下一个uSID。最后一个uSID(Last uSID)位于承载器结束标志之前的一个uSID。填充(padding)部分是位于uSID承载器尾部的保留部分,其取值一般为0,且该填充部分也可以称为承载器结束标志(End-of-Container)。
若SRv6报文的目的地址(destination address,DA)字段包括多个压缩SID,则节点可以根据uSID块和活跃uSID的组合查表,以确定对应的处理行为。该处理行为一般包括移位(shift)和转发。假设uSID承载器中的uSID块,每个uSID,以及每个承载器结束标志的长度均为16bit,则该转发行为可以包括:
将目的地址字段中的32至127位的内容拷贝至第16至111位(即二进制左移16位);
将目的地址字段中的112至127位的内容置为0;
根据更新后的目的地址转发报文。
基于上述分析可知,uSID承载器中的多个uSID可以共享同一个uSID的地址块,因此可以有效缩减报文头的长度。并且,若SRv6报文的转发路径中的各个节点能够在一个uSID承载器中编码完成,则可以直接通过SRv6报文的目的地址字段携带该uSID承载器,即SRv6报文中无需再携带SRH。
可以理解的是,IPv6报文中除了可以插入SRH,还可以插入多种其他类型的IPv6扩展头,例如HBH或DOH等。为了指导转发路径中的节点执行更丰富的处理行为,通常可以在上述IPv6扩展头,或者SRH的TLV字段中携带指示报文处理行为的指令信息。例如,参考图6,该HBH和DOH均可以包括下一头部字段、扩展头长度字段和选项字段,因此可以在HBH或DOH中插入指示网络切片信息的选项,以使转发路径中的节点基于网络切片转发报文。其中,参考图7,该选项字段可以包括选项类型(option type)、选项数据长度(option data length)和选项数据(option data)。或者,如图8所示,可以在SRH的可选TLV字段中插入IFIT TLV,和/或,基于哈希的消息认证码(hashed message authentication code,HMAC)TLV。其中,IFITTLV能够指示转发路径中的节点对报文进行随流检测,HMAC TLV能够指示转发路径中的节点对报文进行安全验证。
从图8可以看出,SRH中的可选TLV位于段列表与载荷之间,SRv6报文还包括以太网报文头(Ethernet header,ETH)和IPv6基本头(basic header)。图9是本申请实施例提供的一种HMACTLV的结构示意图。如图9所示,该HMAC TLV包括:类型字段、长度字段、D字段、保留字段、HMAC秘钥(key)ID和HMAC。其中,HMAC秘钥ID的长度为4字节,HMAC的长度为可变(variable)长度。D字段中的D表示目的地址。
但是,上述插入IPv6扩展头或者扩展TLV的方式均会显著增加报文头的长度,降低数据的传输效率。并且,上述插入IPv6扩展头的方式中,需要转发路径中的每个节点都解析该IPv6扩展头并执行相应的处理行为,因此其灵活性较低,无法实现仅由转发路径中的部分指定节点执行处理行为的功能。
此外,在SID压缩方案中,若SRv6报文的转发路径中的各个节点能够在目的地址字段中编码完成,则SRv6报文中不会再携带SRH。相应的,也就无法通过该SRH中的可选TLV字段来指示更为丰富的处理行为。并且,某些DOH需要插入在SRH之前,若SRv6报文中不再携带SRH,则也就无法携带部分DOH,进而无法通过该部分DOH携带指示报文处理行为的指令信息。
本申请实施例提供了一种报文接收方法,该方法可以应用于诸如图1所示的报文转发系统中的第一节点,该第一节点可以为报文转发系统中的任一节点。参考图10,该方法包括:
步骤101、接收第一报文,该第一报文的第一目的地址字段包括第一段标识。
在本申请实施例中,若第一节点为报文转发系统中的中间节点或者尾节点(也称出口节点),则该第一节点能够接收报文转发系统中的其他节点(例如头节点)发送的第一报文,该第一报文的第一目的地址字段包括第一段标识。其中,该第一段标识可以是长度小于128bit的压缩段标识,或者,该第一段标识可以是长度为128bit的普通SRv6 SID。
若第一节点为报文转发系统中的头节点,也称为入节点或源(source)节点,则第一节点可以接收CE设备或用户终端发送的第一报文。并且,第一节点可以在该第一报文的第一目的地址字段中添加第一段标识。示例的,当该第一段标识为普通SRv6 SID或压缩段标识时,第一节点可以先在第一报文中封装SRH,该SRH中包括第一段标识,例如,该段列表中的最后 一个标识字段的值为第一段标识。之后,第一节点可以将该段列表中的第一段标识拷贝至第一目的地址字段。或者,若该第一段标识为压缩段标识且第一报文中不包括SRH时,则第一节点可以将该第一段标识直接封装至第一报文的第一目的地址字段。
步骤102、从第一目的地址字段中确定第一参数字段,该第一参数字段对应该第一段标识。
在本申请实施例中,第一节点还能够从该第一目的地址字段中确定与该第一段标识对应的第一参数(arguments)字段。例如,该第一参数字段可以包括在第一段标识中,相应的,第一节点可以从第一段标识中确定出第一参数字段。或者,该第一参数字段可以位于第一段标识之后,第一节点可以根据预先配置的第一参数字段在第一目的地址字段中的封装位置,从该第一目的地址字段中确定第一参数字段。例如,该第一参数字段可以位于第一目的地址字段的尾部,比如位于第一目的地址字段末尾的16至32比特。或者,该第一参数字段可以位于第一段标识之后且与第一段标识紧邻,比如位于第一段标识之后的16至32比特。
步骤103、执行该第一参数字段指示的至少一个第一处理行为。
该第一参数字段能够指示至少一个第一处理行为。第一节点可以执行该至少一个第一处理行为,例如第一节点可以按照该至少一个第一处理行为,处理该第一报文。由于该第一参数字段可以指示一个或多个第一处理行为,因此该第一参数字段也可以称为结构化参数(structured arguments)字段。或者,该第一参数字段也可以称为通用参数(generalized arguments)字段。
可以理解的是,该第一段标识还可以包括功能(function)字段,该功能字段能够指示第一节点对第一报文的处理行为(如下文所述的第三处理行为)。在本申请实施例中,第一节点在确定第一参数字段指示的至少一个第一处理行为时,无需将第一参数字段与该功能字段配合。也即是,第一节点可以直接根据第一参数字段确定出该至少一个第一处理行为,或者可以理解为:第一参数字段无需与第一段标识中的功能字段配合,即可单独指示至少一个第一处理行为。
还可以理解的是,该第一参数字段指示的至少一个第一处理行为,相比于通过额外插入IPv6扩展头或者扩展TLV所指示的处理行为,可以相同,也可以有所删减,本申请实施例对此不做限定。
可选地,该第一参数字段指示的至少一个第一处理行为可以包括对第一报文的处理行为,且该至少一个第一处理行为可以包括下述行为中的至少一个:基于网络切片的切片资源转发报文;基于应用感知信息所指示的网络服务转发报文;随流检测;基于分配的网络资源转发报文;加密转发报文;安全验证。
可选地,该第一参数字段指示的至少一个第一处理行为还可以包括第一节点本地执行的与第一报文无关的处理行为。例如,该至少一个第一处理行为可以包括下述行为中的至少一个:调整该第一节点的运行状态;在第一节点的本地为流量建立流表、转发表和/或状态表。其中,流量是指第一报文所属的流量。第一节点的运行状态可以包括休眠状态和关机状态等,相应的,调整第一节点的运行状态可以是指,使第一节点进入休眠状态,或者关机状态。
综上所述,本申请实施例提供了一种报文接收方法。第一节点接收到的第一报文的目的地址字段中包括第一段标识,第一节点能够从该目的地址字段中确定与该第一段标识对应的第一参数字段,并可以执行该第一参数字段指示的至少一个第一处理行为。由于本申请实施例提供的方法能够通过目的地址字段中的第一参数字段指示处理行为,因此相比于通过额外插入IPv6扩展头或者扩展TLV来指示处理行为,可以有效缩减报文头的长度,提高数据的传 输效率。又由于该第一参数字段是能够指示一个或多个第一处理行为的结构化参数字段,因此可以指导第一节点执行较为丰富的处理行为。
并且,在本申请实施例提供的方法中,该第一段标识可以是压缩段标识,例如可以是uSID。并且,若第一报文的转发路径能够在目的地址字段内编码完成,则该第一报文中无需插入SRH。此时,虽然无法通过SRH中的可选TLV字段,或者部分DOH来携带指示报文处理行为的指令信息,但能够通过目的地址字段中的第一参数字段来指导第一节点执行丰富的处理行为。
本申请实施例提供了一种报文转发方法,该方法可以应用于报文转发系统。下文以该报文转发系统包括第一节点、第二节点和第三节点,且以该第三节点为头节点,第一节点为中间节点,第二节点为中间节点或尾节点为例,对该报文转发方法进行介绍。参考图11,该方法包括:
步骤201、第三节点在目标业务流的第一报文中封装第一段标识。
在本申请实施例中,第三节点作为目标业务流在报文转发系统中的头节点,可以在该目标业务流的第一报文中封装第一段标识。其中,该目标业务流可以是需要采用指定的处理行为进行处理的业务流。可以理解的是,第三节点还能够在第一报文中封装第一参数字段,该第一参数字段用于指示至少一个第一处理行为。
可选地,该第一段标识可以为普通的SRv6 SID,其长度可以为128bit。或者,该第一段标识可以为压缩段标识,该压缩段标识的长度小于128比特,例如该压缩段标识的长度可以为16至32比特。其中,该压缩段标识也可以称为CSID、uSID或G-SID。
在第一种可能的实现方式中,若该第一段标识为uSID,且该第一报文的转发路径能够在目的地址字段(即128bit)内编码完成,则第三节点可以直接在该第一报文的第一目的地址字段中封装该第一段标识。并且,第三节点还能够在该第一目的地址字段中封装与第一段标识对应的第一参数字段,且该第一参数字段可以位于该第一段标识之后。
示例的,参考图12,第三节点可以在第一报文的第一目的地址字段中封装公共前缀,以及uSID1至uSIDn共n个uSID。其中,n为大于1的整数,第一段标识可以为uSID1至uSIDn中的任一uSID。
从图12可以看出,该第一目的地址字段还可以包括:位于该n个uSID之后的第一参数字段A0,该第一参数字段A0可以由该n个uSID共享。也即是,该第一参数字段A0能够与第一目的地址字段中的每个uSID对应。或者,参考图13,该目的地址字段可以包括与该n个uSID一一对应的n个参数字段,其中每个参数字段位于对应的一个uSID之后,且与对应的一个uSID紧邻。相应的,该第一参数字段可以是位于第一段标识之后的一个参数字段。例如,假设第一段标识为uSID1,则第一参数字段可以为A1。
在第二种可能的实现方式中,若第一段标识为普通的SRv6 SID,或者,若第一段标识为G-SID或CSID,又或者,若第一段标识为uSID,且第一报文的转发路径无法在目的地址字段内编码完成,则第三节点可以在第一报文中封装SRH,该SRH中包括该第一段标识。
示例的,若第一段标识为普通的SRv6 SID,则参考图2,第三节点在第一报文中封装的SRH中可以包括段列表[0]至段列表[n]共n+1个标识字段,该第一段标识可以携带在段列表[0]至段列表[n]中的任一段列表中。并且,参考图3,该第一参数字段可以包括在该第一段标识中。
若该第一段标识为G-SID,则如图14所示,第三节点在第一报文中封装的SRH可以包括一个或多个G-SID承载器(container)。其中,G-SID承载器可以包括G-SID0至G-SIDn共n+1个G- SID,该第一段标识可以为G-SID0至G-SIDn中的任一G-SID。
在第三种可能的实现方式中,若该第一段标识为uSID,且该第一报文的转发路径无法在目的地址字段内编码完成,则参考图2,第三节点在第一报文中封装的SRH中可以包括段列表[0]至段列表[n]共n+1个标识字段。其中,每个标识字段可以携带一个节点的SID,或者可以携带uSID块和多个uSID,例如可以携带诸如图5所示的uSID承载器。该第一段标识可以携带在任一uSID承载器中,该第一参数字段可以位于该第一段标识之后,且该第一参数字段的位置可以参考图12或图13。
步骤202、第三节点向第一节点发送该第一报文。
第一节点在第一报文中封装第一段标识后,即可向第一节点发送该第一报文。其中,若第一节点为第三节点的下一跳节点,则第三节点可以直接将第一报文发送至第一节点。若该第一节点不是第三节点的下一跳节点,则第三节点可以通过其他中间节点,将第一报文转发至第一节点。
步骤203、第三节点在目标业务流的第二报文中封装第二段标识。
该第二报文中还封装有与第二段标识对应的第二参数字段,该第二参数字段能够指示至少一个第二处理行为,即第二参数字段也为结构化参数字段。其中,该至少一个第二处理行为与第一参数字段所指示的至少一个第一处理行为不同。该至少一个第二处理行为与至少一个第一处理行为不同可以是指:该至少一个第二处理行为与至少一个第一处理行为中不存在相同的处理行为,或者,至少一个第二处理行为与至少一个第一处理行为中,仅部分处理行为相同。
可以理解的是,第一参数字段可以包括至少一个第一行为指令,该至少一个第一行为指令用于指示该至少一个第一处理行为。第二参数字段可以包括至少一个第二行为指令,该至少一个第二行为指令用于指示该至少一个第二处理行为。
在本申请实施例中,若需要第一节点执行的处理行为(例如第一节点对目标业务流执行的处理行为)的个数较多,用于指示该多个处理行为的多个行为指令无法通过长度有限的一个参数字段进行携带,则可以通过多个参数字段来携带该多个行为指令。其中,每个参数字段可以携带部分行为指令,且不同参数字段携带的行为指令可以不同。并且,每个参数字段可以与一个段标识对应(即与一个段标识关联),且不同的参数字段可以与不同的段标识对应。
相应的,第三节点(或控制器)在编排目标业务流的转发路径的段列表时,可以根据关联了上述参数字段的多个段标识生成多个段列表,进而生成多个SRv6策略(policy)。在转发目标业务流的报文的过程中,第三节点可以对目标业务流的不同报文使用不同的SRv6 policy,即封装不同的段标识及其对应的参数字段。例如,第三节点可以通过负载均衡、轮询、随机或其他方式,对目标业务流的不同报文使用不同的SRv6 policy。由此,即可使得转发路径中的节点能够执行不同的处理行为,进而使得上述多种处理行为均能够被执行。例如,转发路径中的节点能够对目标业务流的不同报文执行不同的处理行为。
可以理解的是,目标业务流中的不同报文可以均通过相同的转发路径进行转发,因此上述多个段标识所指示的节点可以相同。相应的,上述第一段标识和第二段标识可以指示相同的节点,例如可以均指示第一节点。
示例的,假设需要对目标业务流的报文执行如下3个处理行为:基于网络切片的切片资源转发报文,基于应用感知信息所指示的网络服务转发报文,以及随流检测。则可以通过第一 参数字段携带该网络切片的切片信息,以及该应用感知信息,并可以通过第二参数字段携带随流检测的信息。并且,可以将第一参数字段与第一段标识SID1关联,并将第二参数字段与第二段标识SID2关联。该第一段标识SID1和第二段标识SID2可以指示目标业务流的转发路径中的同一节点。
若目标业务流的转发路径还包括节点R、节点S和节点T,且该三个节点的段标识分别为SID R、SID S和SID T,则第三节点可以编排2个段列表,并可以生成与该2个段列表对应的2个SRv6 policy。例如,第三节点可以生成SRv6 policy1与段列表1对应,该段列表1为:SID1-SID R-SID S-SID T。第三节点可以生成SRv6 policy2与段列表2对应,该段列表2为:段列表为:SID2-SID R-SID S-SID T。
假设目标业务流包括报文1至报文10共10个报文,且第三节点采用轮询或负载均衡的方式对目标业务流的报文使用不同的SRv6 policy。则第三节点可以对报文1、报文3、报文5、报文7和报文9使用SRv6 policy1。也即是,第三节点可以在上述报文(即第一报文)中封装段列表1,该段列表1中包括与第一参数字段关联的第一段标识SID1。并且,第三节点可以对报文2、报文4、报文6、报文8和报文10使用SRv6 policy2。也即是,第三节点可以在上述报文(即第二报文)中封装段列表2,该段列表2中包括与第二参数字段关联的第二段标识SID2。基于此,SID1指示的节点即可基于该网络切片,以及该应用感知信息所指示的网络服务转发报文1、报文3、报文5、报文7和报文9。并且,SID2指示的节点可以对报文2、报文4、报文6、报文8和报文10执行随流检测。由此,即可使得转发路径中的节点能够对目标业务流的报文执行到上述3种处理行为。
可以理解的是,该第二段标识的结构和封装位置可以均与第一段标识相同,该第二参数字段的结构和封装位置也可以均与第一参数字段相同,此处不再赘述。
步骤204、第三节点向第一节点发送该第二报文。
参考上述步骤202,第三节点可以直接将第二报文发送至第一节点,或者,可以通过其他中间节点,将第二报文转发至第一节点。
步骤205、第一节点从第一报文的第一目的地址字段中确定第一参数字段。
第一节点接收到的第一报文的第一目的地址字段中包括第一段标识。该第一段标识可以是第三节点直接封装在第一目的地址字段中的,或者可以是第一节点的上一跳节点从第一报文的SRH中拷贝至第一目的地址字段中的。
第一节点能够从第一报文的第一目的地址字段中确定与该第一段标识对应的第一参数字段。作为一种可能的实现方式,该第一参数字段可以包括在第一段标识中。相应的,第一节点可以从第一段标识中确定出第一参数字段。例如,参考图3,假设该第一段标识为128bit的SRv6 SID,则第一节点可以将该第一段标识中的若干低比特位确定为第一参数字段。
作为另一种可能的实现方式,该第一参数字段可以位于第一段标识之后,第一节点可以根据预先配置的第一参数字段在第一目的地址字段中的封装位置,从该第一目的地址字段中确定第一参数字段。
例如,参考图12,假设第一段标识为压缩段标识,则第三节点可以将第一目的地址字段中的若干低比特位确定为第一参数字段。或者,参考图13,第三节点可以将位于第一段标识之后,且与第一段标识相邻的若干比特位确定为第一参数字段。
在本申请实施例中,该第一节点可以为支持SRv6转发技术的节点。相应的,第一节点在接收到第一报文后,可以先检测该第一报文的第一目的地址字段中的第一段标识是否为第一 节点的本地SID。若第一段标识为第一节点的本地SID,则第一节点可以继续从该第一目的地址字段中确定第一参数字段。若该第一段标识不为第一节点的本地SID,则第一节点可以无需从该第一目的地址字段中确定第一参数字段,进而无需处理该第一参数字段。
可以理解的是,该第一节点也可以为不支持SRv6转发技术的节点。相应的,在该步骤205中,第一节点可以基于其本地配置信息,从该第一报文的第一目的地址字段中确定第一参数字段,从而,不支持SRv6转发技术的节点也可以执行上述至少一个第一处理行为。其中,该本地配置信息能够指示第一参数字段在第一目的地址字段中的位置。并且,该本地配置信息可以是运维人员配置的,或者可以是控制器下发的。
步骤206、第一节点识别该第一参数字段中携带的至少一个第一行为指令。
如前文所述,第一参数字段中可以携带至少一个第一行为指令。第一节点从第一目的地址字段中确定出第一参数字段后,即可识别该第一参数字段中携带的至少一个第一行为指令。其中,每个第一行为指令可以指示一个第一处理行为。每个第一处理行为可以是对第一报文的处理行为,或者,可以是第一节点本地执行的与该第一报文无关的处理行为。
可选地,该第一参数字段可以包括第一子字段,第二子字段,第三子字段,第四子字段,第五子字段和第六子字段中的至少一个。其中,每个子字段可以携带一个第一行为指令,且该六个子字段所用于携带的第一行为指令可以如下:第一子字段用于携带网络切片的切片信息;第二子字段用于携带应用感知信息;第三子字段用于携带随流检测的信息;第四子字段用于携带分配的网络资源的信息;第五子字段用于携带加密转发的加密方式;第六子字段用于携带用于进行安全验证的消息认证码。也即是,上述切片信息、应用感知信息、随流检测的信息、网络资源的信息、加密方式以及消息认证码中的每个信息均为一个第一行为指令。
其中,网络切片的切片信息可以包括切片ID。应用感知信息也可以称为应用感知网络(application aware networking,APN)信息,该APN信息可以包括用户组标识和应用组标识中的至少一个。并且,还可以包括流标识、服务等级协议(service level agreement,SLA)级别和服务需求中的至少一个。该服务需求可以是对时延和丢包率等性能指标的需求,该流标识也称为会话标识(session ID)。
该随流检测的信息可以包括IFIT信息,例如流监控ID、丢包检测标志位和时延检测标志位等,该随流检测的信息还可以包括随流操作、管理和维护(In-situ Operations,Administration,and Maintenance,IOAM)的信息。该网络资源的信息可以包括用于转发报文的接口的带宽资源。加密方式可以包括媒体接入控制安全(media access control security,MACsec)加密。消息认证码可以包括HMAC。
可选地,该第一参数字段还可以包括第八子字段和第九子字段中的至少一个。其中,第八子字段用于携带运行状态信息,第九子字段用于携带待建立的表项的信息。该运行状态信息可以包括用于指示将第一节点的运行状态调整为休眠状态或关机状态的信息。该待建立的表项的信息可以包括:用于指示第一节点在本地为流量建立流表、转发表和/或状态表的信息。
可选地,该第一参数字段还可以包括至少一个压缩段标识。该第一参数字段中的至少一个第一行为指令可以位于该至少一个压缩段标识之后。例如,第一参数字段可以包括至少一个uSID,该至少一个uSID可以在报文转发过程中进行移位。并且,该至少一个第一行为指令可以不随该至少一个uSID移位,即该至少一个第一行为指令在第一参数字段中的位置固定不变。或者,该至少一个第一行为指令也可以随至少一个uSID一同移位。
示例的,参考图15,第一参数字段可以包括uSID2至uSIDn共n-1个uSID,以及行为指令A1 至行为指令Am共m个第一行为指令,m为大于或等于1的整数。其中,uSID2至uSIDn可以在报文转发过程中移位,该m个第一行为指令位于第一参数字段的尾部,且可以无需随uSID一同移位。
步骤207、第一节点执行该至少一个第一行为指令指示的至少一个第一处理行为。
在本申请实施例中,若该至少一个第一处理行为包括对第一报文的处理行为,则第一节点可以按照该至少一个第一处理行为处理第一报文。例如,第一节点可以对第一报文执行下述至少一个第一处理行为:基于网络切片的切片资源转发报文;基于应用感知信息所指示的网络服务转发报文;随流检测;基于分配的网络资源转发报文;加密转发报文;安全验证。
若该至少一个第一处理行为包括第一节点本地执行的与该第一报文无关的处理行为,则第一节点可以直接执行该第一处理行为,且第一节点执行该第一处理行为不会修改第一报文的内容,也不影响第一报文的转发流程。例如,第一节点可以在本地执行下述至少一个第一处理行为:调整第一节点的运行状态;在第一节点的本地为流量建立流表、转发表和/或状态表。其中,流量是指第一报文所属的业务流,即目标业务流。
可以理解的是,该至少一个第一处理行为可以既包括对第一报文的处理行为,也包括第一节点本地执行的与该第一报文无关的处理行为。例如,该至少一个第一处理行为可以包括:随流检测,以及为第一报文所属业务流建立状态表。
可选地,该第一段标识中还包括功能字段,该功能字段可以用于指示第三处理行为。第一节点识别出第一参数字段携带的至少一个第一行为指令,并确定该功能字段指示的第三处理行为后,即可按照该第三处理行为,处理该第一报文。若该至少一个第一处理行为包括对第一报文的处理行为,则第一节点可以按照该至少一个第一处理行为和该第三处理行为,处理该第一报文,从而得到第三报文。
其中,该第一段标识中的功能字段指示的第三处理行为可以包括:End、End.X、End.T、End.DT4、End.DT6以及End.DT2M等。
可选地,该第一参数字段还可以用于携带该第三处理行为的参数。由于第一参数字段还可以保留原有参数字段的功能,因此能够与原有功能有效兼容。例如,该第一参数字段还可以包括第七子字段,该第七子字段可以用于携带第三处理行为的参数。该第三处理行为的参数可以包括:End.DT2M的行为的参数,和/或,压缩段标识的索引。
其中,End.DT2M的行为的参数可以是Arg.FE2参数,且该参数可以包括多播和/或水平分割的参数。压缩段标识的索引可以是指G-SID的索引(G-SID index,SI)。
可以理解的是,若第一段标识为压缩段标识,则该第一节点在处理该第一报文时,还需对压缩段标识进行移位。若第一参数字段仅与第一段标识对应,则第一参数字段可以随该第一段标识一同移位。例如,参考图13,参数字段A1可以随uSID1移位,参数字段A2可以随uSID1移位。
若第一参数字段与多个压缩段标识对应,则第一参数字段可以不进行移位,即第一参数字段的编码位置固定,以便于其他节点读取。或者,第一参数字段也可以随该多个压缩段标识一同移位,本申请实施例对此不做限定。
可选地,该第一参数字段中还可以包括第十子字段,该第十子字段用于携带移位标记。该移位标记可以用于指示需要对第一目的地址字段中的哪些比特位进行移位。或者,若该第一参数字段中还包括至少一个压缩段标识,则该移位标记可以用于指示需要对第一参数字段中的哪些比特位进行移位。
示例的,假设第一参数字段位于第一目的地址字段中的第96至127位,且第一参数字段不移位,则该移位标记可以指示对第一目的地址字段中的第32至95位进行移位。或者,若第一参数字段也需移位,则该移位标记可以指示对第一目的地址字段中的第32至127位进行移位。假设第一参数字段位于第一目的地址字段中的第32至127位,且其中的第32至95位为压缩段标识,第96至127位为第一行为指令。若第一参数字段不移位,则该移位标记可以指示对第一参数字段中的第0至63位进行移位。或者,若第一参数字段也需移位,则该移位标记可以指示对第一目的地址字段中的第0至95位进行移位。
作为一种可选的实现方式,第一节点可以配置有结构化参数功能,且第一节点的结构化参数功能的状态可以为启用状态或关闭状态。若第一节点确定其结构化参数功能处于启用状态,则可以执行该第一参数字段指示的至少一个第一处理行为。
在该实现方式中,第一节点的结构化参数功能的状态可以是本地配置的,例如可以由运维人员或控制器配置。或者,第一节点接收到的第一报文中还可以包括状态启用标志位,第一节点可以基于该状态启用标志位,启用其结构化参数功能。
示例的,第一节点若确定其结构化参数功能处于启用状态,则可以识别该第一参数字段携带的至少一个第一行为指令,并确定该至少一个第一行为指令指示的至少一个第一处理行为。第一节点若确定其结构化参数功能处于关闭状态,则第一节点可以基于第一段标识中功能字段指示的第三处理行为的类型,判断是否处理该第一参数字段。例如,若该功能字段指示的第三处理行为需要参数,则第一节点可以从该第一参数字段中读取第三处理行为的参数。若该功能字段指示的第三处理行为不需要参数,则第一节点无需处理该第一参数字段。
其中,第三处理行为的参数在第一参数字段中的封装位置可以是第一节点中本地配置的,或者可以是系统预置或固定配置的,又或者可以是标准化的。
作为另一种可选的实现方式,第一节点若根据该第一段标识中功能字段指示的行为(即第三处理行为)或行为特征(flavor)确定该第一参数字段为结构化参数字段,则可以执行该第一参数字段指示的至少一个第一处理行为。
例如,第一节点中可以定义一种新的SRv6行为特征(flavor),该flavor可以与至少一个SID中功能字段指示的行为关联,或者可以与该至少一个SID关联。并且,该至少一个SID所对应的参数字段均为结构化参数字段。基于此,第一节点若确定第一段标识中功能字段指示的第三处理行为与该新的flavor关联,则可以确定第一参数字段为结构化参数字段,进而可以识别该第一参数字段携带的至少一个第一行为指令。其中,flavor与SID中功能字段指示的行为关联可以是指:SID中功能字段指示的行为除了包括常规的SRv6行为(behavior),还包括该flavor指示的附加行为。该附加行为可以是常规SRv6行为的变体(variants of behavior),且该附加行为可以包括:按照结构化参数字段的处理方式处理第一参数字段。
步骤208、第一节点从第二报文的第二目的地址字段中确定第二参数字段。
在本申请实施例中,第一节点接收到第二报文后,还可以从该第二报文的第二目的地址字段中确定第二参数字段。该第二参数字段对应第二目的地址字段中的第二段标识。
可以理解的是,第一节点确定第二参数字段的过程可以与前文所述的确定第一参数字段的过程相同。因此,该步骤208的实现过程可以参考上述步骤205的相关描述,此处不再赘述。
步骤209、第一节点执行第二参数字段指示的至少一个第二处理行为。
该至少一个第二处理行为与该至少一个第一处理行为可以不同。可选地,第一节点可以先从第二参数字段中识别出至少一个第二行为指令,并确定该至少一个第二行为指令指示的 至少一个第二处理行为。之后,第一节点即可执行该至少一个第二处理行为。例如,第一节点可以按照该至少一个第二处理行为,处理该第二报文。或者,第一节点可以在本地执行与该第二报文无关的至少一个第二处理行。
其中,该至少一个第二处理行为可以包括下述行为中的至少一个:基于网络切片的切片资源转发报文;于应用感知信息所指示的网络服务转发报文;随流检测;基于分配的网络资源转发报文;加密转发报文;安全验证。
或者,该至少一个第二处理行为可以包括下述行为中的至少一个:调整第一节点的运行状态;在述第一节点的本地为流量建立流表、转发表和/或状态表。
可以理解的是,该第一节点确定第二参数字段指示的至少一个第二处理行为的过程,可以与确定第一参数字段指示的至少一个第一处理行为的过程相同。因此,该步骤209的实现过程可以参考上述步骤206和步骤207的相关描述。
步骤210、第一节点向第二节点发送第三报文。
在上述步骤207之后,第一节点可以向第二节点发送第三报文,该第三报文是基于第一报文得到的报文。该第二节点可以为第一节点的下一跳节点。该第三报文的第三目的地址字段中可以包括第三段标识,该第三段标识可以是第二节点的本地SID。
可选地,该第一段标识和第三段标识可以均为长度为128bit的SRv6 SID,或者,该第一段标识和第三段标识可以均为压缩段标识。例如,参考图12和图13,该第一段标识可以为uSID1,该第二段标识可以为uSID2。或者,参考图14,该第一段标识可以为G-SID0,该第二段标识可以为G-SID1。
步骤211、第二节点从该第三报文的第三目的地址字段中确定第三参数字段。
该第三参数字段对应该第三段标识,且该第二节点确定第三参数字段的方式可以与前文所述的第一节点确定第一参数字段的方式相同,故此处不再赘述。
可以理解的是,若第三段标识为长度为128bit的SRv6 SID,则该第三参数字段可以包括在第三段标识中。或者,若第三段标识为压缩段标识,且第三目的地址字段中具有与每个uSID对应的一个参数字段,则该第三参数字段可以与第三段标识相邻,且位于第三段标识之后。并且,在该两种实现方式中,第三参数字段与第一参数字段是不同的字段。
若第三段标识为G-SID,或者若第三段标识为uSID,且第三目的地址字段中的多个uSID共享一个参数字段,则该第三参数字段与第一参数字段可以是同一个字段。例如,参考图12,该第一参数字段和第三参数字段均为A0。
步骤212、第二节点执行该第三参数字段指示的至少一个第四处理行为。
在本申请实施例中,该第二节点确定第三参数字段指示的至少一个第四处理行为的过程,可以与第一节点确定第一参数字段指示的至少一个第一处理行为的过程相同。因此,该步骤212的实现过程可以参考上述步骤206和步骤207的相关描述。
可以理解的是,若该第三参数字段与第一参数字段为同一字段,则该至少一个第四处理行为与该至少一个第一处理行为可以相同。由此,可以通过一个参数字段指导转发路径中的不同节点执行相同的处理行为。例如,参考图12,uSID1至uSIDn所指示的n个节点均可以在参数字段A0的指导下,执行相同的处理行为。
若该第三参数字段与第一参数字段为不同的字段,则该至少一个第四处理行为与该至少一个第一处理行为可以相同,也可以不同。其中,若至少一个第四处理行为与该至少一个第一处理行为相同,则可以通过不同的参数字段使得转发路径中的不同节点均执行相同的处理 行为。例如,参考图2,可以通过使段列表[0]至段列表[n]中携带的SID均包含相同的参数字段,以使得转发路径中的不同节点均执行相同的处理行为。若至少一个第四处理行为与该至少一个第一处理行为不同,则可以通过不同的参数字段使得转发路径中的不同节点执行不同的处理行为。例如,参考图13,目的地址字段中的参数字段A1至An可以不完全相同,从而使得转发路径中的不同节点能够执行不同的处理行为。
还可以理解的是,在上述步骤209之后,第一节点也可以向第二节点发送对第二报文进行处理后得到的第四报文,该第四报文的第四目的地址字段包括第四段标识。第二节点可以从第四目的地址字段中确定与该第四段标识对应的第四参数字段,并执行该第四参数字段指示的至少一个处理行为。其中,第二节点执行第四参数字段指示的至少一个处理行为的过程可以参考上述步骤211和步骤212,此处不再赘述。
还可以理解的是,报文转发系统可以包括支持SRv6转发技术的节点,也可以包括不支持该SRv6转发技术的节点。其中,支持SRv6转发技术的节点的结构化参数功能可能处于开启状态,也可能处于关闭状态。基于此,若需要报文转发系统中的节点识别并解析结构化参数字段,则在规划报文转发路径时,可以避开上述不支持该SRv6转发技术的节点,以及支持SRv6转发技术,但结构化参数功能处于关闭状态的节点。
或者,若需要报文转发路径包含上述不支持该SRv6转发技术的节点,或者结构化参数功能处于关闭状态的节点,则可以通过本地配置的方式,以使上述节点能够将报文的目的地址字段中的部分比特位作为结构化参数字段进行读取和解析。也即是,上述节点可以通过本地配置信息,从报文的目的地址字段中确定出结构化参数字段,并识别该结构化参数字段中的至少一个行为指令。由于上述节点是基于本地配置信息识别并解析结构化参数字段,因此该结构化参数字段不再与SRv6功能相关联,而是与上述配置信息指示的功能关联,或作为独立的功能实现。
下文对上述步骤206中,第一节点从第一参数字段中识别出至少一个第一行为指令的过程进行介绍。
在第一种可能的实现方式中,第一节点中预先配置有第一参数字段模板,第一节点可以根据该第一参数字段模板,识别该第一参数字段中包括的至少一个子字段,进而识别该至少一个子字段携带的至少一个第一行为指令。其中,该第一参数字段模板用于定义第一参数字段所携带的至少一个第一行为指令的类型、位置和/或长度。或者可以理解为:该第一参数字段模板用于定义第一参数字段所包含的至少一个子字段的类型、位置和/或长度。
其中,若第一参数字段模板未定义第一参数字段所包含的至少一个第一行为指令的类型,则第一节点中可以预先硬编码有第一参数字段所包含的各个第一行为指令的类型。例如,第一个行为指令为A类型,第二个行为指令为B类型。
若第一参数字段模板未定义第一参数字段所包含的至少一个第一行为指令的位置,则该第一节点中可以预先硬编码有第一参数字段所包含的各个第一行为指令的位置。或者,该至少一个第一行为指令的位置可以与第一参数字段模板定义该至少一个第一行为指令的类型和长度时的顺序相同。例如,假设第一参数字段模板中的第一行定义了行为指令A的长度,第二行定义了行为指令B的长度,第三行定义了行为指令C的长度,则该第一参数字段中携带的3个行为指令可以按照行为指令A、行为指令B和行为指令C的顺序排列。
若第一参数字段模板未定义第一参数字段所包含的至少一个第一行为指令的长度,则该第一节点中可以预先硬编码有第一参数字段所包含的各个第一行为指令的长度,例如每个第 一行为指令的长度均可以n比特,n为大于1的整数。或者,第一参数字段所包含的各个第一行为指令的长度可以相等,则第一节点可以基于第一参数字段的总长度以及第一参数字段所携带的第一行为指令的个数,确定每个第一行为指令的长度。例如,假设第一参数字段的长度为z比特,第一节点基于第一参数字段模板确定该第一参数字段携带了m个第一行为指令,则第一节点可以确定每个第一行为指令的长度为z/m比特。其中,z为大于1的整数,m为大于或等于1的整数。
假设该第一参数字段的长度为z比特,例如z可以为32。参考图16,该参数字段模板可以定义第一参数字段中的第1至第x比特用于携带第一行为指令X,第x+1至第y比特用于携带第一行为指令Y,第y+1至第z比特用于携带第一行为指令Z。其中,x和y满足:0<x<y<z。第一节点基于图16所示的参数字段模板,可以从第一参数字段中识别出第一行为指令X、第一行为指令Y和第一行为指令Z。
示例的,假设第一参数字段的长度为32比特,即z=32,且第一参数字段需要同时携带网络切片的切片信息、APN信息和随流检测的信息,则该第一参数字段模板可以做出如下定义:第1至8比特为第一子字段,用于携带切片信息;第9至24比特为第二子字段,用于携带APN信息;第25至32比特为第三子字段,用于携带随流检测的信息。
作为该第一种实现方式的第一种示例,第一节点中可以预先配置有多个不同的参数字段模板(template),以及每个参数字段模板对应的模板标识。该第一参数字段中还包括模板标识,即模板ID。第一节点从目的地址字段中确定出第一参数字段后,可以先从该第一参数字段中识别出模板ID,然后再根据该模板ID与第一参数模板的对应关系,确定出用于对第一参数字段进行识别的第一参数模板。之后,第一节点即可基于该第一参数字段识别第一参数字段中的至少一个第一行为指令。
可以理解的是,第一节点中预先配置有模板ID在第一参数字段中的位置,第一节点可以基于该预先配置的位置,直接从第一参数字段中识别出模板ID。例如,该第一参数字段的最后一个或多个比特可以用于携带该模板ID。
还可以理解的是,基于不同的参数字段模板,可以在长度固定的第一参数字段中携带不同个数,不同类型,和/或,不同长度的第一行为指令。由此,有效提高了第一参数字段携带行为指令时的灵活性,进而提高了节点执行处理行为时的灵活性。
作为该第一种实现方式的第二种示例,第一节点中可以预先配置有多个不同的参数字段模板,以及每个参数字段模板对应的段标识指示的行为或行为特征。第一节点可以根据该第一段标识指示的行为或行为特征与第一参数字段模板的对应关系,确定出用于对第一参数字段进行识别的第一参数字段模板。其中,段标识指示的行为可以是指段标识中的功能字段指示的行为。
在该示例中,第一节点可以直接根据第一段标识确定出对应的第一参数字段模板,因此无需在第一参数字段中携带模板ID,从而可以预留更多的比特位给第一行为指令。
可选地,第一节点中可以定义多个SRv6 flavor,每个flavor与一个参数字段模板对应(即关联)。并且,每个flavor与一个段标识指示的行为关联,或者每个flavor与一个段标识关联。其中,段标识指示的行为可以是指该段标识中的功能字段指示的处理行为,且该处理行为可以包括常规的SRv6行为(behavior),以及与该段标识关联的flavor所指示的附加行为。该附加行为可以包括:按照指定的参数字段模板解析第一参数字段。
示例的,第一节点中可以定义有Flavor 1和Flavor 2共2个flavor。其中,Flavor 1与模板1关 联,且与第一段标识SID1关联,Flavor 2与模板2关联,且与第二段标识SID2关联。并且,模板1中定义了在参数字段中携带切片信息和APN信息共两个第一行为指令,以及该两个行为指令的排列顺序和长度。模板2中定义了在参数字段中携带随流检测的信息,以及该随流检测的信息所包括的各个字段的位置、名称和长度。
基于此,若第一节点接收到的第一报文的第一目的地址字段中的第一段标识为SID1,则第一节点可以采用模板1对与该SID1对应的第一参数字段进行解析,以识别该第一参数字段中的两个第一行为指令,即切片信息和APN信息。若第一节点接收到的第二报文的第二目的地址字段中的第二段标识为SID2,则第一节点可以采用模板2对与该SID2对应的第二参数字段进行解析,以识别该第二参数字段中的一个第二行为指令,即随流检测的信息。
可以理解的是,在上述第一种实现方式中,报文转发系统中的全部或部分节点中可以配置有参数字段模板。其中,部分节点可以是需要解析结构化参数字段的节点。
在第二种可能的实现方式中,第一参数字段中可以包括比特串(bitmap)形式的至少一个标志位,每个标志位对应一个第一行为指令。作为第一种示例,每个标志位可以用于指示该第一参数字段中是否携带其对应的一个第一行为指令。作为第二种示例,每个标志位可以用于指示第一参数字段中对应的一个行为指令是否能够被识别。其中,若某个标志位指示其对应的一个行为指令能够被识别,则表明该行为指令有效,若某个标志位指示其对应的一个行为指令不能够被识别,则表明该行为指令无效(invalid)。
例如,若标志位的取值为1,则表示第一参数字段中携带了对应的一个第一行为指令,或者第一参数字段中该对应的一个第一行为指令能够被识别,即第一行为指令有效。若标志位的取值为0,则表示第一参数字段中未携带对应的一个第一行为指令,或者该对应的一个第一行为指令不能够被识别。
其中,第一行为指令不能够被识别可以包括如下几种情况:情况1,第一行为指令已失效;情况2,第一行为指令已被执行,无需第一节点再执行;情况3,不要求第一节点执行该第一行为指令,或者第一节点需要忽略该第一行为指令。
可以理解的是,在上述第一种示例中,若某个标志位指示第一参数字段未携带对应的一个第一行为指令,则表明该第一行为指令未占用第一参数字段的编码空间。该编码空间可以用于其他用途,或者被剩下作为预留字段。在上述第二种示例中,若某个标志位指示第一参数字段中对应的一个第一行为指令不能够被识别,则该第一行为指令仍然存在于第一参数字段中,即仍然占用了第一参数字段的编码空间,但第一节点不会识别并执行该第一行为指令。
还可以理解的是,在该第二种实现方式中,第一节点可以先识别第一参数字段中携带的至少一个标志位,然后再根据该至少一个标志位,识别第一参数字段中携带的至少一个第一行为指令。例如,第一节点可以确定出取值为1的至少一个标志位,然后识别该取值为1的至少一个标志位对应的至少一个第一行为指令。
可选地,该第一参数字段中的各个标志位可以从最高有效位开始编码。例如,参考图17中的(a),第一参数字段包括的3个标志位S、A和I可以位于高比特位。或者,该第一参数字段中的各个标志位可以从最低有效位开始编码。例如,参考图17中的(b),第一参数字段包括的3个标志位S、A和I可以位于低比特位。又或者,该第一参数字段中的各个标志位可以在其他任意位置编码。例如,参考图17中的(c),第一参数字段包括的3个标志位S、A和I可以位于中间比特位。
可选地,该第一参数字段中的各个标志位可以连续排列,例如,参考图17中的(a)至(c), 第一参数字段中的3个标志位S、A和I占用了3个连续的比特位。或者,该第一参数字段中的各个标志位也可以是松散排列。例如,参考图18中的(a),该第一参数字段中的3个标志位S、A和I可以间隔排列,且每个标志位之后的比特位即为该标志位对应的一个第一行为指令。
在本申请实施例中,该第一参数字段中的各个第一行为指令的排列顺序与对应的各个标志位的排列顺序可以相同,也可以不同。例如,假设第一参数字段中的标志位S对应第一行为指令I-S,标志位A对应第一行为指令I-A,标志位I对应第一行为指令I-I。则参考图18中的(a)和(b),第一参数字段中的3个标志位按照S、A和I的顺序排列,则该3个标志位对应的3个第一行为指令可以按照第一行为指令I-S、第一行为指令I-A和第一行为指令I-I的顺序排列。或者,参考图18中的(c),该3个标志位对应的3个第一行为指令也可以按照第一行为指令I-S、第一行为指令I-I和第一行为指令I-A的顺序排列。
可以理解的是,若第一参数字段中未携带某个标志位对应的第一行为指令,则其他第一行为指令可以进行补位,以构成紧凑的字段排列。或者,其他第一行为指令也可以不进行补位,构成分散的或者固定位置的排列。
例如,参考图19中的(a)、(b)和(c),第一参数字段中未携带第一行为指令I-A,则该第一参数字段中的3个标志位S、A和I,以及剩余的2个第一行为指令I-S和I-I可以连续排列。或者,参考图19中的(d),第一参数字段中未携带第一行为指令I-A,则该第一参数字段中剩余的2个第一行为指令I-S和I-I可以无需补位,而是保留在原来的固定位置。
对于第一参数字段未携带某个标志位对应的第一行为指令的场景,作为一种可能的示例,参考图19中的(a)至(d),该第一参数字段中多余的比特位(即空闲的比特位)可以置零、任意填充或预留。其中,预留可以是指保持该比特位原来填充的内容不变。
作为另一种可能的示例,该第一参数字段中多余的比特位可以由其他第一行为指令占用。由此,可以有效增加其他第一行为指令的长度,以便使其他第一行为指令包含更多的信息。例如,参考图20中的(a),若第一参数字段未携带第一行为指令I-A,则位于该第一行为指令I-A之前的第一行为指令I-S可以占用原本用于携带第一行为指令I-A的若干比特位。或者,参考图20中的(b),位于该第一行为指令I-A之后的第一行为指令I-I可以占用原本用于携带第一行为指令I-A的若干比特位。
在该第二种实现方式中,第一参数字段中各个标志位的位置和长度,以及每个标志位对应的第一行为指令的类型、位置和长度,均可以是标准化统一的,或者可以是在某个网络域内自定义的。
基于上述两种实现方式可知,相比于传统的参数字段仅用于携带功能字段指示的处理行为的参数,本申请实施例提供的方案中,第一参数字段不仅可以单独指示处理行为,且第一参数字段中携带的行为指令的个数和类型可以灵活调节。由此,有效提高了第一节点根据第一参数字段的指示,执行处理行为时的灵活性。
可以理解的是,若第一参数字段中除了包括至少一个第一行为指令,还包括其他信息,例如还包括第三处理行为的参数、移位标记和/或至少一个压缩段标识,则第一节点也可以基于上述两种实现方式中的任一种识别该第一参数字段中的其他信息。
还可以理解的是,在上述步骤209中,第一节点可以采用第二参数字段模板或bitmap解析该第二参数字段,以识别出至少一个第二行为指令。其中,该第二参数字段模板可以是根据第二参数字段中的模板ID确定的,或者可以是根据第二段标识指示的行为确定的。并且,该第二参数字段模板与该第一参数字段模板可以相同,也可以不同。
还可以理解的是,本申请实施例提供的报文转发方法的步骤先后顺序可以进行适当调整,步骤也可以根据情况进行相应增减。例如,上述步骤203和步骤204可以在步骤202之前执行。或者,上述步骤203和步骤204,以及步骤208和步骤209可以根据情况删除。又或者,上述步骤211和步骤212可以根据情况删除,即第三节点可以无需识别并解析第三参数字段。
还可以理解的是,上述第一报文、第二报文、第三报文和第四报文仅用于区分不同的报文,第一参数字段、第二参数字段、第三参数字段和第四参数字段仅用于区分不同报文中的参数字段,第一处理行为、第二处理行为、第三处理行为和第四处理行为仅用于区分不同字段指示的处理行为。在一些实施例中,上述第三报文也可以称为第二报文,第三参数字段也可以称为第二参数字段,第四处理行为也可以称为第二处理行为。
综上所述,本申请实施例提供了一种报文转发方法。第一节点接收到的第一报文的目的地址字段中包括第一段标识,第一节点能够从该目的地址字段中确定与该第一段标识对应的第一参数字段,并可以执行该第一参数字段指示的至少一个第一处理行为。由于本申请实施例提供的方法能够通过目的地址字段中的第一参数字段指示处理行为,因此相比于通过额外插入IPv6扩展头或者扩展TLV来指示处理行为,可以有效缩减报文头的长度,提高数据的传输效率。又由于该第一参数字段是能够指示一个或多个第一处理行为的结构化参数字段,因此可以指导第一节点执行较为丰富的处理行为。
并且,对于第一段标识为压缩段标识的场景,若第一报文的转发路径能够在目的地址字段内编码完成,则该第一报文中无需插入SRH。此时,虽然无法通过SRH中的可选TLV字段,或者部分DOH来携带指示报文处理行为的指令信息,但能够通过目的地址字段中的第一参数字段来指导第一节点执行丰富的处理行为。
图21是本申请实施例提供的一种第一节点的结构示意图,该第一节点可以应用于诸如图1所示的报文转发系统,且可以实现上述方法实施例中由第一节点执行的步骤。参考图21,该第一节点包括:
接收模块301,用于接收第一报文,该第一报文的第一目的地址字段包括第一段标识。该接收模块301的功能实现可以参考上述方法实施例中步骤101和步骤202的相关描述。
确定模块302,用于从该第一目的地址字段中确定第一参数字段,该第一参数字段对应该第一段标识。该确定模块302的功能实现可以参考上述方法实施例中步骤102和步骤205的相关描述。
处理模块303,用于执行该第一参数字段指示的至少一个第一处理行为。该处理模块303的功能实现可以参考上述方法实施例中步骤103的相关描述。
可选地,该处理模块303,可以用于识别该第一参数字段中携带的至少一个行为指令,并执行该至少一个行为指令指示的至少一个第一处理行为。该处理模块303的功能实现还可以参考上述方法实施例中步骤206和步骤207的相关描述。
可选地,该处理模块303,可以用于根据参数字段模板,识别该第一参数字段中携带的至少一个行为指令。其中,该参数字段模板用于定义第一参数字段所携带的至少一个行为指令的类型、位置和/或长度。
可选地,该第一参数字段还可以包括模板标识;该处理模块303,还可以用于根据该模板标识与参数字段模板的对应关系,确定该参数字段模板。
可选地,该处理模块303,还可以用于根据该第一段标识指示的行为或行为特征与该参数字段模板的对应关系,确定该参数字段模板。
可选地,该处理模块303,可以用于识别该第一参数字段中携带的至少一个标志位,并根据该至少一个标志位,识别该第一参数字段中携带的至少一个行为指令。其中,每个标志位对应一个行为指令,且用于指示该第一参数字段中是否携带对应的一个行为指令,或者用于指示所述第一参数字段中对应的一个行为指令是否能够被识别。
可选地,该处理模块303,可以用于基于该第一节点的结构化参数功能处于启用状态,执行该第一参数字段指示的至少一个第一处理行为;或,根据该第一段标识中功能字段指示的行为或行为特征确定该第一参数字段为结构化参数字段,执行该第一参数字段指示的至少一个第一处理行为。
可选地,该第一段标识为压缩段标识,该压缩段标识的长度小于128比特,或者,该第一段标识的长度为128比特。
可选地,该第一参数字段包括在该第一段标识中,或者,该第一参数字段位于该第一段标识之后。
可选地,该第一报文属于目标业务流。该接收模块301,还可以用于接收该目标业务流的第二报文,该第二报文的第二目的地址字段包括第二段标识。该接收模块301的功能实现还可以参考上述方法实施例中步骤204的相关描述。
该确定模块302,还可以用于从该第二目的地址字段中确定第二参数字段,该第二参数字段对应该第二段标识。该确定模块302的功能实现还可以参考上述方法实施例中步骤208的相关描述。
该处理模块303,还可以用于执行该第二参数字段指示的至少一个第二处理行为。其中,该至少一个第二处理行为与该至少一个第一处理行为不同。该处理模块303的功能实现还可以参考上述方法实施例中步骤209的相关描述。
可选地,该第一段标识还可以包括功能字段,该功能字段用于指示第三处理行为。该处理模块303,还可以用于按照该第三处理行为,处理该第一报文。
可选地,该第一参数字段还用于携带该第三处理行为的参数。
可选地,该第三处理行为的参数可以包括:End.DT2M的行为的参数,和/或,压缩段标识的索引。
可选地,该处理模块303,可以用于按照第一参数字段指示的至少一个第一处理行为,处理第一报文。
可选地,该至少一个第一处理行为包括下述行为中的至少一个:基于网络切片的切片资源转发报文;基于应用感知信息所指示的网络服务转发报文;随流检测;基于分配的网络资源转发报文;加密转发报文;安全验证。
可选地,该第一参数字段包括第一子字段,第二子字段,第三子字段,第四子字段、第五子字段和第六子字段中的至少一个;其中,该第一子字段用于携带该网络切片的切片信息;该第二子字段用于携带该应用感知信息;该第三子字段用于携带该随流检测的信息;该第四子字段用于携带该分配的网络资源的信息;该第五子字段用于携带该加密转发的加密方式;该第六子字段用于携带用于进行该安全验证的消息认证码。
可选地,该第一参数字段还包括第七子字段;该第七子字段用于携带该第一段标识中的功能字段所指示的第三处理行为的参数。
可选地,该至少一个第一处理行为还可以包括下述行为中的至少一个:调整第一节点的运行状态;在第一节点的本地为流量建立流表、转发表和/或状态表。
可选地,该确定模块302,可以用于基于确定该第一段标识为第一节点的本地SID,从该第一目的地址字段中确定第一参数字段。
可选地,该第一节点不支持SRv6转发技术;该确定模块302,可以用于基于该第一节点的本地配置信息,从该第一目的地址字段中确定第一参数字段。
可选地,该第一参数字段还可以包括至少一个压缩段标识,例如包括至少一个uSID。
综上所述,本申请实施例提供了一种第一节点。该第一节点接收到的第一报文的目的地址字段中包括第一段标识,第一节点能够从该目的地址字段中确定与该第一段标识对应的第一参数字段,并可以执行该第一参数字段指示的至少一个第一处理行为。由于本申请实施例提供的方案能够通过目的地址字段中的第一参数字段指示处理行为,因此相比于通过额外插入IPv6扩展头或者扩展TLV来指示处理行为,可以有效缩减报文头的长度,提高数据的传输效率。又由于该第一参数字段是能够指示一个或多个第一处理行为的结构化参数字段,因此可以指导第一节点执行较为丰富的处理行为。
图22是本申请实施例提供的一种第三节点的结构示意图,该第三节点可以应用于诸如图1所示的报文转发系统,且可以实现上述方法实施例中由第三节点执行的步骤。参考图22,该第一节点包括:
封装模块401,用于在第一报文中封装第一段标识。该封装模块401的功能实现可以参考上述方法实施例中步骤201的相关描述。
发送模块402,用于发送该第一报文,以供接收到该第一报文的节点从该第一报文的第一目的地址字段中确定第一参数字段,并执行该第一参数字段指示的至少一个第一处理行为。其中,该第一参数字段对应该第一段标识。该发送模块402的功能实现可以参考上述方法实施例中步骤202的相关描述。
可选地,该封装模块401,可以用于在第一目的地址字段中封装第一段标识;或者,在第一报文中封装SRH,该SRH中包括该第一段标识。
可选地,该第一报文属于目标业务流,该封装模块401,还可以用于在该目标业务流的第二报文中封装第二段标识。该封装模块401的功能实现还可以参考上述方法实施例中步骤203的相关描述。
该发送模块402,还可以用于发送该第二报文,以供接收到该第二报文的节点从该第二报文的第二目的地址字段中确定第二参数字段,并执行该第二参数字段指示的至少一个第二处理行为。其中,该第二参数字段对应该第二段标识,该至少一个第二处理行为与该至少一个第一处理行为不同。该发送模块402的功能实现还可以参考上述方法实施例中步骤204的相关描述。
可选地,该第一段标识指示的节点与该第二段标识指示的节点相同。
可选地,该第一段标识为压缩段标识,该压缩段标识的长度小于128比特;或者,该第一段标识的长度为128比特。
可选地,该第一参数字段包括在该第一段标识中,或者,该第一参数字段位于该第一段标识之后。
综上所述,本申请实施例提供了一种第三节点。该第三节点能够在第一报文中封装第一 段标识,且接收到第一报文的节点能够从第一报文的目的地址字段中确定与该第一段标识对应的第一参数字段,并可以执行该第一参数字段指示的至少一个第一处理行为。由于本申请实施例提供的方案能够通过目的地址字段中的第一参数字段指示处理行为,因此相比于通过额外插入IPv6扩展头或者扩展TLV来指示处理行为,可以有效缩减报文头的长度,提高数据的传输效率。又由于该第一参数字段是能够指示一个或多个第一处理行为的结构化参数字段,因此可以指导第一节点执行较为丰富的处理行为。
图23是本申请实施例提供的一种第二节点的结构示意图,该第二节点可以应用于诸如图1所示的报文转发系统,且可以实现上述方法实施例中由第二节点执行的步骤。参考图23,该第二节点包括:
接收模块501,用于接收第一节点发送的第二报文,该第二报文的第二目的地址字段包括第二段标识。其中,第二报文基于第一节点接收到的第一报文得到。该接收模块501的功能实现可以参考上述方法实施例中步骤210的相关描述。
确定模块502,用于从第二目的地址字段中确定第二参数字段,该第二参数字段对应第二段标识。该确定模块502的功能实现可以参考上述方法实施例中步骤211的相关描述。
处理模块503,用于执行该第二参数字段指示的至少一个第二处理行为。该处理模块503的功能实现可以参考上述方法实施例中步骤212的相关描述。
可选地,该第一参数字段和第二参数字段可以为同一字段。
可选地,该至少一个第一处理行为和该至少一个第二处理行为相同。
可选地,该第一段标识和第二段标识均为压缩段标识,该压缩段标识的长度小于128比特;或者,该第一段标识和第二段标识的长度均为128比特。
可选地,该第一参数字段包括在第一段标识中,该第二参数字段包括在第二段标识中;或者,该第一参数字段位于第一段标识之后,该第二参数字段位于第二段标识之后。
综上所述,本申请实施例提供了一种第二节点。该第二节点接收到的第二报文的目的地址字段中包括第二段标识,第二节点能够从该目的地址字段中确定与该第二段标识对应的第二参数字段,并可以执行该第二参数字段指示的至少一个第二处理行为。由于本申请实施例提供的方案能够通过目的地址字段中的第一参数字段指示处理行为,因此相比于通过额外插入IPv6扩展头或者扩展TLV来指示处理行为,可以有效缩减报文头的长度,提高数据的传输效率。
所属领域的技术人员可以清楚地了解到,为描述的方便和简洁,上述描述的第一节点、第二节点、第三节点以及各模块的具体工作过程,可以参考前述方法实施例中的对应过程,在此不再赘述。
应理解的是,本申请实施例提供的第一节点、第二节点和第三节点还可以用特定应用集成电路(application-specific integrated circuit,ASIC)实现,或可编程逻辑器件(programmable logic device,PLD)实现,上述PLD可以是复杂程序逻辑器件(complex programmable logical device,CPLD),现场可编程门阵列(field-programmable gate array,FPGA),通用阵列逻辑(generic array logic,GAL)或其任意组合。此外,也可以通过软件实现上述方法实施例提供的报文接收方法、报文发送方法或报文转发方法,当通过软件实现上述方法实施例提供的方法时,该第一节点、第二节点和第三节点中的各个功能模块也可以为软件模块。
图24是本申请实施例提供的一种网络设备的结构示意图。该网络设备可以应用于诸如图1所示的系统,且可以为该系统中的第一节点、第二节点或第三节点。参考图24,该网络设备包括:处理器601、存储器602、网络接口603和总线604。
其中,存储器602中存储有计算机程序6021,计算机程序6021用于实现各种应用功能。处理器601用于执行该计算机程序6021以实现上述方法实施例提供的应用于第一节点、第二节点或第三节点的方法。例如,处理器601用于执行该计算机程序6021以实现上述图21、图22或图23所示节点中各个模块的功能。
处理器601可以是中央处理器(central processing unit,CPU),该处理器601还可以是其他通用处理器、数字信号处理器(digital signal processor,DSP)、ASIC、FPGA、图形处理器(graphics processing unit,GPU)或者其他可编程逻辑器件、分立门或者晶体管逻辑器件、分立硬件组件等。通用处理器可以是微处理器或者是任何常规的处理器。
存储器602可以是易失性存储器或非易失性存储器,或可包括易失性和非易失性存储器两者。其中,非易失性存储器可以是只读存储器(read-only memory,ROM)、可编程只读存储器(programmable ROM,PROM)、可擦除可编程只读存储器(erasable PROM,EPROM)、电可擦除可编程只读存储器(electrically EPROM,EEPROM)或闪存。易失性存储器可以是随机存取存储器(random access memory,RAM),其用作外部高速缓存。通过示例性但不是限制性说明,许多形式的RAM可用,例如静态随机存取存储器(static RAM,SRAM)、动态随机存取存储器(dynamic RAM,DRAM)、同步动态随机存取存储器(synchronous DRAM,SDRAM)、双倍数据速率同步动态随机存取存储器(double data date SDRAM,DDR SDRAM)、增强型同步动态随机存取存储器(enhanced SDRAM,ESDRAM)、同步连接动态随机存取存储器(synchlink DRAM,SLDRAM)和直接内存总线随机存取存储器(direct rambus RAM,DR RAM)。
网络接口603可以为多个,且网络接口603用于实现与其他设备之间的通信连接(可以是有线或者无线)。其中,在本申请实施例中,网络接口603用于收发报文。其中,其他设备可以是终端、服务器、VM等设备或其它网络设备。
总线604用于连接处理器601、存储器602和网络接口603。并且,总线604除包括数据总线之外,还可以包括电源总线、控制总线和状态信号总线等。但是为了清楚说明起见,在图中将各种总线都标为总线604。
若该网络设备为第一节点,则处理器601用于通过网络接口603接收第一报文,该第一报文的第一目的地址字段包括第一段标识,以及用于从该第一目的地址字段中确定第一参数字段,并执行该第一参数字段指示的至少一个第一处理行为。其中,该第一参数字段对应第一段标识。该处理器601的详细处理过程请参考上述图10和图11所示方法实施例中由第一节点执行的步骤,这里不再赘述。
若该网络设备为第三节点,则处理器601用于在第一报文中封装第一段标识,并发送该第一报文,以供接收到第一报文的节点从第一报文的第一目的地址字段中确定第一参数字段,并执行第一参数字段指示的至少一个第一处理行为。其中,该第一参数字段对应第一段标识。该处理器601的详细处理过程请参考上述图11所示方法实施例中由第三节点执行的步骤,这里不再赘述。
若该网络设备为第二节点,则处理器601用于通过网络接口603接收第一节点发送的第二报文,该第二报文的第二目的地址字段包括第二段标识,以及用于从该第二目的地址字段中 确定第二参数字段,并执行该第二参数字段指示的至少一个第二处理行为。其中,该第二参数字段对应第二段标识。该处理器601的详细处理过程请参考上述图11所示方法实施例中由第二节点执行的步骤,这里不再赘述。
图25是本申请实施例提供的另一种网络设备的结构示意图。该网络设备可以应用于诸如图1所示系统,且可以为该系统中的第一节点、第二节点或第三节点。如图25所示,该网络设备可以包括:主控板701和至少一个接口板(接口板也称为线卡或业务板),例如图25中示出了接口板702和接口板703。多个接口板的情况下网络设备还可以包括交换网板704,该交换网板704用于完成各接口板之间的数据交换。
其中,主控板701也称为主处理单元(main processing unit,MPU)或路由处理卡(route processor card),主控板701用于完成系统管理、设备维护和协议处理等功能。主控板701上主要有3类功能单元:系统管理控制单元、系统时钟单元和系统维护单元。主控板701包括:中央处理器7011和存储器7012。
接口板702和703也称为线路接口单元卡(line processing unit,LPU)、线卡(line card)或业务板,接口板用于提供各种业务接口,并实现报文的转发。其中,接口板所提供的业务接口可以包括:基于SONET/SDH的数据包(packet over SONET/SDH,POS)接口、千兆以太网(gigabit Ethernet,GE)接口和异步传输模式(asynchronous transfer mode,ATM)接口等。其中,SONET是指同步光纤网络(synchronous optical network),SDH是指同步数字体系(synchronous digital hierarchy)。主控板701、接口板702以及接口板703之间通过系统总线与系统背板相连以实现互通。如图25所示,接口板702上包括一个或多个中央处理器7021。中央处理器7021用于对接口板702进行控制管理并与主控板701上的中央处理器7011进行通信,以及接口板702。接口板702上的存储器7024用于存储转发表项,网络处理器7022可以通过查找存储器7024中存储的转发表项进行报文的转发。存储器7024还可以用于存储程序代码。
该接口板702还包括一个或多个物理接口卡7023,该一个或多个物理接口卡7023用于接收上一跳节点发送的报文,并根据中央处理器7021的指示向下一跳节点发送处理后的报文。
此外,可以理解的是,图25中的接口板702中的中央处理器7021和/或网络处理器7022可以是专用硬件或芯片,如可以采用ASIC来实现上述功能,这种实现方式即为通常所说的转发面采用专用硬件或芯片处理的方式。在另外的实施方式中,所述中央处理器7021和/或网络处理器7022也可以采用通用的处理器,如通用的CPU来实现以上描述的功能。
此外应理解的是,主控板701可能有一块或多块,有多块的时候可以包括主用主控板和备用主控板。接口板可能有一块或多块,该网络设备的数据处理能力越强,提供的接口板越多。如图25所示,网络设备包括接口板702和接口板703。当采用分布式的转发机制时,接口板703的结构与接口板702的结构基本相同,且接口板703上的操作与接口板702的操作基本相似,为了简洁,不再赘述。网络设备具有多块接口板的情况下,该多块接口板之间可以通过一块或多块交换网板704通信,且可以实现负荷分担和冗余备份,以提供大容量的数据交换和处理能力。
在集中式转发架构下,该网络设备可以不需要交换网板704,接口板承担整个系统的业务数据的处理功能。所以,分布式架构的网络设备的数据接入和处理能力要大于集中式架构的网络设备。具体采用哪种架构,取决于具体的组网部署场景,此处不做任何限定。
在本申请实施例中,存储器7012和存储器7024可以是ROM或可存储静态信息和指令的其它类型的静态存储设备,也可以是RAM或者可存储信息和指令的其它类型的动态存储设备,还可以是EEPROM、只读光盘(compact disc read-only Memory,CD-ROM)或其它光盘存储、光碟存储(包括压缩光碟、激光碟、光碟、数字通用光碟、蓝光光碟等)、磁盘或者其它磁存储设备、或者能够用于携带或存储具有指令或数据结构形式的期望的程序代码并能够由计算机存取的任何其它介质,但不限于此。接口板702中的存储器7024可以是独立存在,并通过通信总线与中央处理器7021相连接;或者,存储器7024也可以和中央处理器7021集成在一起。主控板701中的存储器7012可以是独立存在,并通过通信总线与中央处理器7011相连接;或者,存储器7012也可以和中央处理器7011集成在一起。
存储器7024中存储的程序代码,由中央处理器7021来控制执行,存储器7012存储的程序代码,由中央处理器7011来控制执行。该中央处理器7021和/或中央处理器7011可以通过执行程序代码来实现上述方法实施例所提供的由任一节点执行的方法。存储器7024和/或存储器7012存储的程序代码中可以包括一个或多个软件单元。这一个或多个软件单元可以为图21至图23中任一附图所示的功能模块。
在本申请实施例中,该物理接口卡7023,可以是使用任何收发器一类的装置,用于与其它设备或通信网络通信,如以太网,无线接入网(radio access network,RAN),无线局域网(wireless local area networks,WLAN)等。
可选地,图21至图24中任一附图所示的设备也可以采用图25所示的结构实现。
本申请实施例还提供了一种计算机可读存储介质,该计算机可读存储介质中存储有指令,当该指令在处理器运行时,使得处理器执行如上述方法实施例中由第一节点、第二节点或第三节点执行的步骤。
本申请实施例还提供了一种包含指令的计算机程序产品,当该指令在处理器上运行时,使得处理器执行如上述方法实施例中由第一节点、第二节点或第三节点执行的步骤。
本申请实施例还提供了一种报文转发系统,如图1所示,该报文转发系统包括多个节点01。该多个节点01中包括第一节点,该第一节点可以用于实现上述方法实施例中由第一节点执行的方法。
可选地,该多个节点01还可以包括第二节点和/或第三节点。其中,该第二节点可以用于实现上述方法实施例中由第二节点执行的方法,第三节点可以用于实现上述方法实施例中由第三节点执行的方法。
其中,该第一节点的结构可以如图21、图24或图25所示,该第三节点的结构可以如图22、图24或图25所示,该第二节点的结构可以如图23、图24或图25所示。
本领域普通技术人员可以理解实现上述实施例的全部或部分步骤可以通过硬件来完成,也可以通过程序来指令相关的硬件完成,所述的程序可以存储于一种计算机可读存储介质中,上述提到的存储介质可以是只读存储器,磁盘或光盘等。
在本申请实施例中,术语“第一”、“第二”和“第三”仅用于描述目的,而不能理解为指示或暗示相对重要性。本申请中术语“和/或”,仅仅是一种描述关联对象的关联关系,表示可以存在三种关系,例如,A和/或B,可以表示:单独存在A,同时存在A和B,单独存在B这三种情况。另外,本文中字符“/”,一般表示前后关联对象是一种“或”的关系。
以上所述仅为本申请的可选实施例,并不用以限制本申请,凡在本申请的构思和原则之内,所作的任何修改、等同替换、改进等,均应包含在本申请的保护范围之内。

Claims (39)

  1. 一种报文接收方法,其特征在于,应用于第一节点,所述方法包括:
    接收第一报文,所述第一报文的第一目的地址字段包括第一段标识;
    从所述第一目的地址字段中确定第一参数字段,所述第一参数字段对应所述第一段标识;
    执行所述第一参数字段指示的至少一个第一处理行为。
  2. 根据权利要求1所述的方法,其特征在于,所述执行所述第一参数字段指示的至少一个第一处理行为,包括:
    识别所述第一参数字段中携带的至少一个行为指令;
    执行所述至少一个行为指令指示的所述至少一个第一处理行为。
  3. 根据权利要求2所述的方法,其特征在于,所述识别所述第一参数字段中携带的至少一个行为指令,包括:
    根据参数字段模板,识别所述第一参数字段中携带的所述至少一个行为指令;
    其中,所述参数字段模板用于定义所述第一参数字段所携带的所述至少一个行为指令的类型、位置和/或长度。
  4. 根据权利要求3所述的方法,其特征在于,所述第一参数字段还包括模板标识;所述方法还包括:
    根据所述模板标识与所述参数字段模板的对应关系,确定所述参数字段模板。
  5. 根据权利要求3所述的方法,其特征在于,所述方法还包括:
    根据所述第一段标识指示的行为或行为特征与所述参数字段模板的对应关系,确定所述参数字段模板。
  6. 根据权利要求2所述的方法,其特征在于,所述识别所述第一参数字段中携带的至少一个行为指令,包括:
    识别所述第一参数字段中携带的至少一个标志位,其中,每个标志位对应一个行为指令;
    根据所述至少一个标志位,识别所述第一参数字段中携带的至少一个行为指令。
  7. 根据权利要求6所述的方法,其特征在于,每个标志位用于指示所述第一参数字段中是否携带对应的一个行为指令,或者用于指示所述第一参数字段中对应的一个行为指令是否能够被识别。
  8. 根据权利要求1至7任一所述的方法,其特征在于,所述执行所述第一参数字段指示的至少一个第一处理行为,包括:
    基于所述第一节点的结构化参数功能处于启用状态,执行所述第一参数字段指示的至少一个第一处理行为;或,
    根据所述第一段标识中功能字段指示的行为或行为特征确定所述第一参数字段为结构化参数字段,执行所述第一参数字段指示的至少一个第一处理行为。
  9. 根据权利要求1至8任一所述的方法,其特征在于,所述第一段标识为压缩段标识,所述压缩段标识的长度小于128比特。
  10. 根据权利要求1至8任一所述的方法,其特征在于,所述第一段标识的长度为128比特。
  11. 根据权利要求1至10任一所述的方法,其特征在于,所述第一参数字段包括在所述第一段标识中,或者,所述第一参数字段位于所述第一段标识之后。
  12. 根据权利要求1至11任一所述的方法,其特征在于,所述第一报文属于目标业务流,所述方法还包括:
    接收所述目标业务流的第二报文,所述第二报文的第二目的地址字段包括第二段标识;
    从所述第二目的地址字段中确定第二参数字段,所述第二参数字段对应所述第二段标识;
    执行所述第二参数字段指示的至少一个第二处理行为,所述至少一个第二处理行为与所述至少一个第一处理行为不同。
  13. 根据权利要求1至12任一所述的方法,其特征在于,所述第一段标识还包括功能字段,所述功能字段用于指示第三处理行为;所述方法还包括:
    按照所述第三处理行为,处理所述第一报文。
  14. 根据权利要求13所述的方法,其特征在于,所述第一参数字段还用于携带所述第三处理行为的参数。
  15. 根据权利要求14所述的方法,其特征在于,所述第三处理行为的参数包括:
    具有解封装和二层L2表泛洪的端点End.DT2M的行为的参数,和/或,压缩段标识的索引。
  16. 根据权利要求1至15任一所述的方法,其特征在于,所述执行所述第一参数字段指示的至少一个第一处理行为,包括:
    按照所述第一参数字段指示的至少一个第一处理行为,处理所述第一报文。
  17. 根据权利要求16所述的方法,其特征在于,所述至少一个第一处理行为包括下述行为中的至少一个:
    基于网络切片的切片资源转发报文;
    基于应用感知信息所指示的网络服务转发报文;
    随流检测;
    基于分配的网络资源转发报文;
    加密转发报文;
    安全验证。
  18. 根据权利要求17所述的方法,其特征在于,所述第一参数字段包括第一子字段,第二 子字段,第三子字段,第四子字段、第五子字段和第六子字段中的至少一个;
    其中,所述第一子字段用于携带所述网络切片的切片信息;
    所述第二子字段用于携带所述应用感知信息;
    所述第三子字段用于携带所述随流检测的信息;
    所述第四子字段用于携带所述分配的网络资源的信息;
    所述第五子字段用于携带所述加密转发的加密方式;
    所述第六子字段用于携带用于进行所述安全验证的消息认证码。
  19. 根据权利要求18所述的方法,其特征在于,所述第一参数字段还包括第七子字段;
    所述第七子字段用于携带所述第一段标识中的功能字段所指示的第三处理行为的参数。
  20. 根据权利要求1至19任一所述的方法,其特征在于,所述至少一个第一处理行为包括下述行为中的至少一个:
    调整所述第一节点的运行状态;
    在所述第一节点的本地为流量建立流表、转发表和/或状态表。
  21. 根据权利要求1至20任一所述的方法,其特征在于,所述从所述第一目的地址字段中确定第一参数字段,包括:
    基于确定所述第一段标识为所述第一节点的本地段标识SID,从所述第一目的地址字段中确定第一参数字段。
  22. 根据权利要求1至21任一所述的方法,其特征在于,所述第一节点不支持基于互联网协议第6版的段路由SRv6转发技术;所述从所述第一目的地址字段中确定第一参数字段,包括:
    基于所述第一节点的本地配置信息,从所述第一目的地址字段中确定第一参数字段。
  23. 根据权利要求1至22任一所述的方法,其特征在于,所述第一参数字段还包括至少一个压缩段标识。
  24. 一种报文发送方法,其特征在于,所述方法包括:
    在第一报文中封装第一段标识;
    发送所述第一报文,以供接收到所述第一报文的节点从所述第一报文的第一目的地址字段中确定第一参数字段,并执行所述第一参数字段指示的至少一个第一处理行为;
    其中,所述第一参数字段对应所述第一段标识。
  25. 根据权利要求24所述的方法,其特征在于,所述在第一报文中封装第一段标识,包括:
    在所述第一目的地址字段中封装第一段标识;
    或者,在第一报文中封装分段路由头SRH,所述SRH中包括所述第一段标识。
  26. 根据权利要求24或25所述的方法,其特征在于,所述第一报文属于目标业务流,所述方法还包括:
    在所述目标业务流的第二报文中封装第二段标识;
    发送所述第二报文,以供接收到所述第二报文的节点从所述第二报文的第二目的地址字段中确定第二参数字段,并执行述第二参数字段指示的至少一个第二处理行为;
    其中,所述第二参数字段对应所述第二段标识,所述至少一个第二处理行为与所述至少一个第一处理行为不同。
  27. 根据权利要求26所述的方法,其特征在于,所述第一段标识指示的节点与所述第二段标识指示的节点相同。
  28. 根据权利要求24至27任一所述的方法,其特征在于,所述第一段标识为压缩段标识,所述压缩段标识的长度小于128比特;
    或者,所述第一段标识的长度为128比特。
  29. 根据权利要求24至28任一所述的方法,其特征在于,所述第一参数字段包括在所述第一段标识中,或者,所述第一参数字段位于所述第一段标识之后。
  30. 一种报文转发方法,其特征在于,应用于报文转发系统,所述报文转发系统包括第一节点和第二节点;所述方法包括:
    所述第一节点接收第一报文,所述第一报文的第一目的地址字段包括第一段标识;
    所述第一节点从所述第一目的地址字段中确定第一参数字段,所述第一参数字段对应所述第一段标识;
    所述第一节点执行所述第一参数字段指示的至少一个第一处理行为;
    所述第二节点接收所述第一节点发送的第二报文,所述第二报文基于所述第一报文得到,且所述第二报文的第二目的地址字段包括第二段标识;
    所述第二节点从所述第二目的地址字段中确定第二参数字段,所述第二参数字段对应所述第二段标识;
    所述第二节点执行所述第二参数字段指示的至少一个第二处理行为。
  31. 根据权利要求30所述的方法,其特征在于,所述第一参数字段和所述第二参数字段为同一字段。
  32. 根据权利要求30或31所述的方法,其特征在于,所述至少一个第一处理行为和所述至少一个第二处理行为相同。
  33. 根据权利要求30至32任一所述的方法,其特征在于,所述第一段标识和所述第二段标识均为压缩段标识,所述压缩段标识的长度小于128比特;
    或者,所述第一段标识和所述第二段标识的长度均为128比特。
  34. 根据权利要求30至33任一所述的方法,其特征在于,所述第一参数字段包括在所述第一段标识中,所述第二参数字段包括在所述第二段标识中;
    或者,所述第一参数字段位于所述第一段标识之后,所述第二参数字段位于所述第二段标识之后。
  35. 一种网络设备,其特征在于,所述网络设备包括:存储器,处理器及存储在所述存储器上并能够在所述处理器上运行的计算机程序,所述处理器执行所述计算机程序时实现如权利要求1至34任一所述的方法。
  36. 一种计算机可读存储介质,其特征在于,所述计算机可读存储介质中存储有指令,当所述指令在处理器上运行时,使得所述处理器执行如权利要求1至34任一所述的方法。
  37. 一种包含指令的计算机程序产品,其特征在于,所述指令由处理器执行,以实现如权利要求1至34任一所述的方法。
  38. 一种报文转发系统,其特征在于,所述系统包括:多个节点;
    所述多个节点中的至少一个节点用于实现如权利要求1至23任一所述的方法。
  39. 根据权利要求38所述的系统,其特征在于,所述多个节点中的至少一个节点还用于实现如权利要求24至29任一所述的方法。
PCT/CN2023/073744 2022-05-28 2023-01-29 报文接收方法、发送方法、转发方法、装置及系统 WO2023231431A1 (zh)

Applications Claiming Priority (4)

Application Number Priority Date Filing Date Title
CN202210595079 2022-05-28
CN202210595079.1 2022-05-28
CN202210843988.2A CN117176632A (zh) 2022-05-28 2022-07-18 报文接收方法、发送方法、转发方法、装置及系统
CN202210843988.2 2022-07-18

Publications (1)

Publication Number Publication Date
WO2023231431A1 true WO2023231431A1 (zh) 2023-12-07

Family

ID=88941904

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2023/073744 WO2023231431A1 (zh) 2022-05-28 2023-01-29 报文接收方法、发送方法、转发方法、装置及系统

Country Status (2)

Country Link
CN (1) CN117176632A (zh)
WO (1) WO2023231431A1 (zh)

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20170104669A1 (en) * 2015-10-08 2017-04-13 Abl Ip Holding Llc Multicast message translation in a network device
CN110266594A (zh) * 2019-06-28 2019-09-20 Ut斯达康通讯有限公司 跨网络切片的分段路由转发方法及装置
CN110636001A (zh) * 2018-06-25 2019-12-31 华为技术有限公司 发送网络性能参数、计算网络性能的方法和网络节点
CN110784411A (zh) * 2019-09-30 2020-02-11 华为技术有限公司 建立bier转发表项的方法、装置和系统
CN113411834A (zh) * 2020-03-17 2021-09-17 华为技术有限公司 报文处理方法、装置、设备及存储介质
CN113438160A (zh) * 2020-03-23 2021-09-24 中兴通讯股份有限公司 路由方法、路由装置及计算机可读存储介质
CN113726654A (zh) * 2021-08-13 2021-11-30 新华三信息安全技术有限公司 Srv6协议的报文转发方法、装置、电子设备及介质

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20170104669A1 (en) * 2015-10-08 2017-04-13 Abl Ip Holding Llc Multicast message translation in a network device
CN110636001A (zh) * 2018-06-25 2019-12-31 华为技术有限公司 发送网络性能参数、计算网络性能的方法和网络节点
CN110266594A (zh) * 2019-06-28 2019-09-20 Ut斯达康通讯有限公司 跨网络切片的分段路由转发方法及装置
CN110784411A (zh) * 2019-09-30 2020-02-11 华为技术有限公司 建立bier转发表项的方法、装置和系统
CN113411834A (zh) * 2020-03-17 2021-09-17 华为技术有限公司 报文处理方法、装置、设备及存储介质
CN113438160A (zh) * 2020-03-23 2021-09-24 中兴通讯股份有限公司 路由方法、路由装置及计算机可读存储介质
CN113726654A (zh) * 2021-08-13 2021-11-30 新华三信息安全技术有限公司 Srv6协议的报文转发方法、装置、电子设备及介质

Also Published As

Publication number Publication date
CN117176632A (zh) 2023-12-05

Similar Documents

Publication Publication Date Title
CN111512601B (zh) 分组的分段路由网络处理
CN111541613B (zh) 一种基于SRv6的数据处理方法及相关设备
US11824771B2 (en) Packet processing method, related device, and computer storage medium
US20220078114A1 (en) Method and Apparatus for Providing Service for Traffic Flow
CN113259238B (zh) 分段标识的处理方法及设备
US20230102984A1 (en) METHOD AND APPARATUS FOR VERIFYING SRv6 PACKET
US20230283554A1 (en) BIER Packet Forwarding Method, Device, and System
WO2022001835A1 (zh) 发送报文的方法、装置、网络设备、系统及存储介质
US20220263751A1 (en) Packet Processing Method, Apparatus, and System
US20220255772A1 (en) Packet sending method, apparatus, and system
WO2021151381A1 (zh) 分段标识的处理方法及设备
US20240048479A1 (en) Packet Forwarding Method and Apparatus, Network Device, and Storage Medium
WO2021227746A1 (zh) 发送和转发报文的方法、头节点、转发节点、存储介质
WO2022057810A1 (zh) 业务报文的转发方法、sr策略的发送方法、设备及系统
US20230388223A1 (en) Packet forwarding method, apparatus, and system
WO2023231431A1 (zh) 报文接收方法、发送方法、转发方法、装置及系统
WO2023185235A1 (zh) 报文转发方法、装置及系统
WO2024041064A1 (zh) Quic报文的传输方法及相关设备
US20230291537A1 (en) Network Synchronization Method, Apparatus, Device, and System, and Readable Storage Medium
US11863446B2 (en) User group-based packet forwarding method, device, and system
WO2023231428A1 (zh) IPv4报文的封装方法、电子设备和计算机存储介质
WO2024088199A1 (zh) 业务处理方法、系统、存储介质及电子设备
WO2024104007A1 (zh) 报文发送方法、装置、存储介质及电子装置
WO2024002101A1 (zh) 报文传输方法、装置、相关设备及存储介质
CN116938830A (zh) 报文转发方法、装置及系统

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 23814630

Country of ref document: EP

Kind code of ref document: A1