WO2015180560A1 - Service router packet processing method and service node - Google Patents

Service router packet processing method and service node Download PDF

Info

Publication number
WO2015180560A1
WO2015180560A1 PCT/CN2015/078518 CN2015078518W WO2015180560A1 WO 2015180560 A1 WO2015180560 A1 WO 2015180560A1 CN 2015078518 W CN2015078518 W CN 2015078518W WO 2015180560 A1 WO2015180560 A1 WO 2015180560A1
Authority
WO
WIPO (PCT)
Prior art keywords
socket
packet
message
unit
processed
Prior art date
Application number
PCT/CN2015/078518
Other languages
French (fr)
Chinese (zh)
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 WO2015180560A1 publication Critical patent/WO2015180560A1/en

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L65/00Network arrangements, protocols or services for supporting real-time applications in data packet communication
    • H04L65/40Support for services or applications

Definitions

  • the present invention relates to the field of data processing technologies, and in particular, to a method and a service node for processing a service routing message.
  • the service chain (Service Chaining) technology is a forwarding technology that guides the order of network service packets through multiple service nodes (English is Service Node, English abbreviated as SN), where service packets are between nodes.
  • the forwarding behavior is called a service route.
  • the original packet is encapsulated in the service routing header.
  • the service routing header is used to guide the forwarding of the service packet and also carries the element in the encapsulation information.
  • the data (metadata in English), the metadata can be generated by the service router (English Service Router, abbreviated as SR) or generated by the SN itself, and can be modified.
  • the SN entry message standards can be generally divided into two categories. One type is: when the message arriving at the SN is the original message, the SN can directly receive, process, and send. The other type is that the packet arriving at the SN is a service routing packet with the service routing header information and the metadata. In this case, the SN needs to identify and strip the service routing header when receiving the service routing packet. After the packet is processed, the appropriate service routing header can be encapsulated for the original packet and sent to the SR.
  • the application in the SN (Application in English is APP) directly obtains service routing packets through the network driver layer, strips the service routing headers, identifies the original packets, and processes them. After the processing is completed, the APP The layer encapsulates the appropriate service routing headers for the packets and sends them through the network driver layer.
  • the inventors of the present invention have found that all related information of service routing in the prior art is exposed to the APP. Layer, there are security risks.
  • the embodiment of the present invention provides a method for processing a service routing message, which may be processed by a socket unit in the service node SN for service routing information, and the application unit in the SN does not need to learn the service.
  • the information related to the route is processed only to prevent the related information of the service route from being exposed to the application unit in the SN, thereby improving the security of the service route.
  • the embodiment of the invention also provides a corresponding service node.
  • a first aspect of the present invention provides a method for processing a service routing message, including:
  • the socket unit in the service node SN creates a first socket, and the first socket is used to listen to the first packet, where the first packet is a service routing report belonging to the first service routing type.
  • the first packet includes the service routing information and the to-be-processed packet.
  • the socket unit stores a correspondence between the to-be-processed message and the second socket, where the second socket corresponds to the service routing information;
  • the socket unit receives a message acquisition request from an application unit in the SN, where the message acquisition request is used to request the to-be-processed message corresponding to the second socket;
  • the socket unit sends the to-be-processed message to the application unit by sending a response to the message acquisition request to the application unit.
  • the method further includes:
  • the socket unit determines the service routing information according to the second socket corresponding to the processed message
  • the second packet is a service routing packet that includes the processed packet, and the service routing information of the second packet includes the service routing information.
  • the socket unit saves a correspondence between the to-be-processed message and the second socket Specifically include:
  • the socket unit When the socket unit receives the first packet, if the second socket is not saved in the socket unit, the second socket is created, and the The processing message is added to the message queue corresponding to the second socket.
  • the socket unit saves a correspondence between the to-be-processed message and the second socket Specifically include:
  • the socket unit When the socket unit receives the first packet, if the second socket is saved in the socket unit, the to-be-processed message is added to the second The queue corresponding to the socket in the message.
  • the socket unit is from an application unit in the SN Before receiving the packet obtaining request including the second socket, the method further includes:
  • the socket unit sends the second socket to the application unit.
  • the socket unit is configured to send to the application unit And sending, by the application unit, the to-be-processed message, the method includes:
  • the socket unit sends a response to the message acquisition request to the application unit, where the response carries a storage address of the to-be-processed message;
  • the application unit acquires the to-be-processed message according to the storage address.
  • the socket unit is sent by using the application unit And sending, to the application unit, the to-be-processed message, in the manner of the response of the packet obtaining request, including:
  • the socket unit sends a response to the message acquisition request to the application unit, where the response carries the to-be-processed message.
  • a second aspect of the present invention provides a service node, including: a socket unit and an application unit;
  • the socket unit includes:
  • Creating a sub-unit configured to create a first socket, where the first packet is used to listen to the first packet, where the first packet is a service routing packet belonging to the first service routing type.
  • the first packet includes service routing information and pending packets;
  • Determining a subunit configured to determine, according to the first socket created by the creating subunit, that the SN receives the first packet
  • a saving subunit configured to save a correspondence between the to-be-processed message and the second socket, where the second socket corresponds to the service routing information
  • a receiving subunit configured to receive a message obtaining request from an application unit in the SN, where the message obtaining request is used to request the to-be-processed message corresponding to the second socket;
  • the determining subunit is further configured to determine, according to the packet obtaining request that is received by the receiving subunit and the corresponding relationship that is saved by the saving subunit, that the to-be-processed packet is the requested packet;
  • a sending subunit configured to send the to-be-processed message determined by the determining subunit to the application unit by sending a response to the packet request to the application unit.
  • the receiving subunit is further configured to receive, from the application unit, a processed message corresponding to the second socket, where the processed message is sent by the application unit to the to-be-processed message Obtained by processing the text;
  • the determining subunit is further configured to determine the service routing information according to the second socket corresponding to the processed message received by the receiving subunit;
  • the sending subunit is further configured to send a second packet to the service router SR, where the second packet is a service routing packet that includes the processed packet, and the service routing information of the second packet includes Determining the service routing information determined by the subunit.
  • the creating subunit is further configured to: when the receiving subunit receives the first packet, if the second socket is not saved in the saving subunit, create the second socket word;
  • the saving subunit is specifically configured to add the to-be-processed message to a message queue corresponding to the second socket created by the creating subunit.
  • the saving subunit is configured to: when the receiving subunit receives the first packet, if the second socket is saved in the saving subunit, the to-be-processed packet is sent Add to the message queue corresponding to the second socket.
  • any one of the first to third possible implementation manners of the second aspect in a fourth possible implementation manner,
  • the sending subunit is further configured to send the second socket to the application unit before receiving a message obtaining request including the second socket from an application unit in the SN.
  • any one of the first to fourth possible implementation manners of the second aspect in a fifth possible implementation manner,
  • the sending subunit is configured to send a response to the packet obtaining request to the application unit, where the response carries a storage address of the to-be-processed packet;
  • the application unit is configured to acquire the to-be-processed message according to the storage address.
  • any one of the first to fifth possible implementation manners of the second aspect in a sixth possible implementation manner,
  • the sending subunit is configured to send a response to the packet obtaining request to the application unit, where the response carries the to-be-processed message.
  • the socket unit in the service node SN creates a first socket, and the first socket is used to listen to the first packet, where the first packet belongs to the first service routing type.
  • the service routing message the first packet includes service routing information and a to-be-processed message;
  • the socket unit determines, according to the first socket, that the SN receives the first packet;
  • the socket unit saves a correspondence between the to-be-processed message and the second socket, where the second socket corresponds to the service routing information;
  • the socket unit is from the SN
  • the application unit receives a message acquisition request, and the message acquisition request is used to request the to-be-processed message corresponding to the second socket;
  • the socket unit acquires a request according to the message and Determining, by the correspondence, the to-be-processed message is a requested message;
  • the socket unit sends the response to the message acquisition request to the application unit to the application unit Send the to-be-processed message.
  • the method for processing the service routing packet provided by the embodiment of the present invention may be performed by the socket unit pair in the service node SN, as compared with the information about the service routing in the prior art.
  • the service routing message is processed by the service routing information, and the application unit in the SN does not need to know the relevant information of the service routing, and only processes the service, thereby preventing the related information of the service routing from being exposed to the application unit in the SN, thereby improving Security of service routing.
  • FIG. 1 is a schematic diagram of an embodiment of a method for processing a service routing message according to an embodiment of the present invention
  • FIG. 2 is a schematic diagram of an embodiment of a method for processing a service routing message according to an embodiment of the present invention
  • FIG. 3 is a schematic diagram of an embodiment of a method for processing a service routing message according to an embodiment of the present invention
  • FIG. 4 is a schematic diagram of a service node in an embodiment of the present invention.
  • FIG. 5 is a schematic diagram of a service node in an embodiment of the present invention.
  • the embodiment of the present invention provides a method for processing a service routing message, which may be processed by a socket unit in the service node SN for service routing information, and the application unit in the SN does not know the service route.
  • the related information is processed only to prevent the related information of the service route from being exposed to the application unit in the SN, thereby improving the security of the service route.
  • the embodiment of the invention also provides a corresponding service node. The details are described below separately.
  • an embodiment of a method for processing a service routing packet includes:
  • the embodiment of the present invention provides a new first socket (English socket) protocol family, which is used to assist the application layer to complete partial processing of service routing messages at the driver layer, and can route the new service to the socket protocol family.
  • Named AF_SR can also be named with other names.
  • the embodiment of the present invention introduces a new service routing socket protocol stack in the SN, and the application program interface provided by the protocol stack to the APP (English name is Application)
  • the Programming Interface (abbreviated as API) collection is defined as the SR socket API.
  • the processing module of the API is a service router socket module (SR socket module in English), hereinafter referred to as SRM.
  • SRM service router socket module
  • the service node SN includes two parts, one part is a socket unit, one part is an application unit, and the socket unit includes two parts: an SR socket API and an SRM.
  • FIG. 2 an implementation of a method for processing a service routing message according to an embodiment of the present invention is provided. Examples include:
  • the socket unit 301 in the service node SN30 creates a first socket.
  • the first socket is configured to listen to the first packet, where the first packet is a service routing packet that belongs to the first service routing type, and the first packet includes the service routing information and the to-be-processed packet. Text.
  • the specific process of the socket unit 301 to create the first socket may include the following.
  • the application unit 302 sends a first socket creation instruction to the socket unit 301.
  • This step can be understood in conjunction with FIG. 1 as: the application unit calls the service routing socket API in the SR socket API.
  • the socket unit 301 creates the first socket according to the creation instruction of the first socket.
  • the socket unit 301 After the socket unit 301 creates the first socket, it can start receiving the first message belonging to the first service route type, and the instruction for receiving the first message can be invoked by the application unit 302 through the first socket. The instruction is triggered to the socket unit 301. After receiving the call instruction of the first socket, the socket unit 301 can learn that the first message of the first service route type can be received.
  • the service routing type in the embodiment of the present invention may be: a transmission type and/or a transmission mode of the service routing bearer layer.
  • an application unit has the processing capability of the to-be-processed packet in the service routing packet belonging to a service routing type, and of course, it can also have the to-be-processed packet in the service routing packet belonging to multiple service routing types. Processing power, there can be multiple application units in one SN.
  • the specific process of the socket unit 301 to create the first socket may further include: the creation process is not initiated by the application unit, but the socket unit actively creates the first socket according to the first service route type. word.
  • the socket unit may actively create the first socket after the SN where it is started, or may actively create the first socket after reaching a predetermined time.
  • the socket unit 301 can also create the first socket according to an instruction of a controller in the network.
  • the process of creating the first socket may include an operation of creating a socket, and may continue to include an operation of configuring the created socket.
  • the service router SR40 sends the first packet to the service node 30.
  • the socket unit 301 determines, according to the first socket, that the SN30 receives the first packet.
  • the first socket corresponds to the first service routing type
  • the first packet is a service routing packet of the first service routing type
  • the service routing type of the packet received by the socket unit 301 is the first service.
  • the packet can be determined to be the first packet.
  • the socket unit 301 starts to receive the first packet of the first service route type from the SR after the first service route type is learned.
  • the SRM receives the first packet from the SR according to the first service route type.
  • the socket unit determines, when the first packet is received, whether the second socket is saved in the socket unit. If otherwise, step S115 is performed, and if yes, step S120 is performed.
  • the second socket in the embodiment of the present invention is attached to the first socket, the first socket corresponds to the first service routing type, and the second socket corresponds to a session of the first service routing type. There may be multiple sessions belonging to the first service route type.
  • the socket unit may parse the first packet and separate the service routing information and the to-be-processed packet in the first packet.
  • the process of separation may not be performed.
  • the service routing information is carried in the service routing header of the first packet.
  • the to-be-processed packet may include the original packet without any routing information, and may also include the original packet and metadata without any routing information.
  • This step can be understood as a process performed by SRM with reference to FIG.
  • the correspondence between the service routing information and the second socket is unique, and each service routing information uniquely corresponds to a second socket.
  • a service routing information can correspond to multiple pending packets, and a queue of pending packets can be established for a second socket, and the same service routing letter is used. The pending message in the message is stored in the queue.
  • Second socket Service routing information Pending message queue 1 Service routing information 1 Q1 2 Service routing information 2 Q2 3 Service routing information 3 Q3 ... ... ... N Service routing information N QN
  • each second socket corresponds to one service routing information, and the service routing information belongs to the first service routing type in S100.
  • Each second socket identifier also corresponds to a queue of all pending packets under the service routing information.
  • the socket unit determines that the service routing information in the first packet does not exist in the socket unit, it can be understood that the entry of the service routing information does not exist in the table 1, and the Table 1 lists the entries corresponding to the service routing information.
  • This step can be understood as a process performed by SRM with reference to FIG.
  • Table 1 can also include the service route type. After adding the service route type, refer to Table 2 for understanding.
  • Second socket Route type Routing information Message queue 1 Type1 Routing information 1 Q1 2 Type2 Routing information 2 Q2 3 Type3 Routing information 3 Q3 ... ... ... ... N TypeN Routing information N QN
  • the socket unit When receiving the first packet, the socket unit adds the to-be-processed message to the same if the second socket is saved in the socket unit. The packet queue corresponding to the second socket.
  • the service routing information exists in the socket unit, it can be understood that the entry of the service routing information already exists in the table 1 and does not need to be re-established, and only the to-be-processed message needs to be stored in the The queue of pending packets corresponding to the service routing information. For example, when the correspondence between the second socket 1 and the message queue Q1 is saved in the table 1, the to-be-processed message can be added to the Q1 queue.
  • This step can be understood as a process performed by SRM with reference to FIG.
  • the socket unit 301 sends the second socket to the application unit 302.
  • This step may be: the socket unit 301 receives the second socket acquisition instruction sent by the application unit 302, and then the socket unit 301 sends the instruction to the application unit according to the second socket acquisition instruction. 302 transmits the second socket.
  • the application unit 302 when the application unit 302 needs to process the to-be-processed message, it first sends a second socket acquisition instruction to the socket unit.
  • This step in conjunction with Figure 1, can be understood as: the application unit calls the second socket creation interface in the SR socket API.
  • the socket unit 301 After receiving the second socket acquisition instruction, the socket unit 301 generally sends the second socket identifier to the application unit 302 in the order in which the second socket is generated.
  • This step can be understood as a process performed by SRM with reference to FIG.
  • the sending, by the socket unit, the second socket to the application unit may further include: after the second socket is generated, the socket unit 301 does not receive the second socket. In the case of an instruction, the second socket is actively sent to the application unit 302.
  • the socket unit 301 receives a message from the application unit 302 in the SN. And taking the request, the message obtaining request is used to request the to-be-processed message corresponding to the second socket.
  • the packet obtaining request in the embodiment of the present invention may directly carry the packet obtaining request, or may not carry the second socket, but the socket unit 301 corresponds to the second socket.
  • the dedicated interface receives the message acquisition request.
  • the socket unit 301 can determine the relationship between the request and the second socket, that is, to request the to-be-processed message corresponding to the second socket.
  • the socket unit 301 determines, according to the packet obtaining request and the correspondence, that the to-be-processed packet is the requested packet.
  • the corresponding relationship may determine a to-be-processed message corresponding to the second socket.
  • the corresponding relationship between the second socket and the to-be-processed message may also be expressed as the second socket and the foregoing, because the to-be-processed message is saved in the message queue.
  • the to-be-processed message may be determined according to the correspondence between the second socket and the second socket and the message queue identifier. For example, according to the second socket 1, it can be determined that the message queue is the pending message in Q1 as the requested message.
  • the socket unit sends the to-be-processed message to the application unit by sending a response to the message acquiring request to the application unit.
  • a solution of step S140 may be:
  • the socket unit sends a response to the message acquisition request to the application unit, where the response carries a storage address of the to-be-processed message; the application unit acquires according to the storage address.
  • the to-be-processed message In this way, the socket unit and the application unit do not need to directly transmit the data to be processed, and the response speed to the request can be improved.
  • step S140 Another solution of step S140 may be:
  • the socket unit sends a response to the message acquisition request to the application unit, where the response carries the to-be-processed message.
  • the socket unit can be targeted
  • the response to the request directly carries the to-be-processed message, and the application unit is not required to search for the to-be-processed message.
  • the packet when sending a response to the packet request, the packet may be sent to the queue first according to the order in which the packets are to be processed. The response of the pending message until the queue pending message is sent.
  • This step can be understood as a process performed by SRM with reference to FIG.
  • the application unit 302 processes the to-be-processed message into a processed message.
  • the application unit After the application unit obtains the to-be-processed message, the to-be-processed message is processed into the processed message.
  • the socket unit 301 receives, from the application unit 302, a processed message corresponding to the second socket.
  • the processed message is obtained by the application unit 302 processing the to-be-processed message.
  • the solution that the socket unit 301 receives the processed message corresponding to the second socket from the application unit 302 may be:
  • the socket unit 301 receives, from the application unit 302, a message or a message including the storage address of the processed message and the second socket, and may also receive the processed text body and the second socket. Word message or message. Since the processed message and the second socket are both obtained by the socket unit 301, the socket unit 301 can determine that the processed message and the second socket are corresponding. .
  • Another scheme for the socket unit 301 to receive the processed message corresponding to the second socket from the application unit 302 may also be: the socket unit 301 from the application unit 302 a second socket-specific interface between the storage address of the processed message or the processed message, and determining, according to the dedicated interface of the second socket, that the processed message is the same as the first
  • the two sets of connectors correspond to each other.
  • the socket unit 301 determines the service routing information according to the second socket corresponding to the processed message.
  • the corresponding service routing information can be determined. If the second socket is 1, the corresponding service routing information may be determined as the service routing information 1.
  • the socket unit sends a second packet to the service router SR, where the second packet is a service routing packet that includes the processed packet, and the service routing information of the second packet includes the service. Routing information.
  • the socket unit 301 may encapsulate the processed message by using the service routing information determined in step S155, or may directly send the processed message and the service routing information to the SR without encapsulation, but The processed message and the service routing information are separately identified, so that the SR 40 can separately identify the processed message and the service routing information.
  • steps S130 to S140 have no sequence with steps S150 to S160. Steps S130 to S140 and steps S150 to S160 may be performed simultaneously for different service routing messages, or steps S150 to S160 may be performed first.
  • the socket unit 301 receives the second socket close instruction sent by the application unit 302.
  • the second socket closing instruction may carry the second socket, or may receive the second socket closing instruction through the dedicated interface of the second socket.
  • the socket unit 301 deletes the correspondence between the second socket, the service routing information, and the packet queue in the first service routing type according to the second socket closing instruction.
  • the socket unit 301 receives the first socket close instruction sent by the application unit 302.
  • the first socket close command may carry the first service route type, or may not carry the first service route type, but receive the second socket by using a dedicated interface of the first socket. instruction.
  • the service node SN30 and the service router SR in this embodiment may be two physical devices that are independent of each other, or two virtual devices that are implemented in the same physical device or physical system.
  • the names of service nodes and service routers may change. Therefore, as long as a physical or virtual device performs the operations performed by the service node SN30 in this embodiment, even if the name of the physical or virtual device is not a "service node", it should be understood as The service node SN30 in the embodiment of the present invention.
  • the determination criterion of the service router is the same as the standard of the service node 30, that is, as long as one device performs the operation performed by the service router SR40 in this embodiment, the device should be understood as a service router. Whether a target device can be understood as the device in this embodiment is independent of the name of the target device in the industry, and is related to the operations and functions performed by the target device.
  • the method for processing the service routing packet provided by the embodiment of the present invention may be performed by the socket unit pair in the service node SN, as compared with the information about the service routing in the prior art.
  • the service routing message is processed by the service routing information, and the application unit in the SN does not need to know the relevant information of the service routing, and only processes the service, thereby preventing the related information of the service routing from being exposed to the application unit in the SN, thereby improving Security of service routing.
  • another embodiment of a method for processing a service routing packet according to an embodiment of the present invention includes:
  • the socket unit in the service node SN creates a first socket, where the first socket is used to listen to the first packet, and the first packet is a service belonging to the first service routing type.
  • the routing packet includes the service routing information and the to-be-processed packet.
  • the socket unit determines, according to the first socket, that the SN receives the first packet.
  • the socket unit saves a correspondence between the to-be-processed message and a second socket, where the second socket corresponds to the service routing information.
  • the socket unit receives a message acquisition request from an application unit in the SN, where the message acquisition request is used to request the to-be-processed message corresponding to the second socket.
  • the socket unit determines, according to the packet obtaining request and the correspondence, that the to-be-processed packet is the requested packet.
  • the socket unit sends the to-be-processed message to the application unit by sending a response to the message acquisition request to the application unit.
  • the socket unit in the service node SN creates a first socket, and the first socket is used to listen to the first packet, where the first packet belongs to the first service routing type.
  • the service routing message the first packet includes service routing information and a to-be-processed message;
  • the socket unit determines, according to the first socket, that the SN receives the first packet;
  • the socket unit saves a correspondence between the to-be-processed message and the second socket, where the second socket corresponds to the service routing information;
  • the socket unit is from the SN
  • the application unit receives a message acquisition request, and the message acquisition request is used to request the to-be-processed message corresponding to the second socket;
  • the socket unit acquires a request according to the message and Determining, by the correspondence, the to-be-processed message is a requested message;
  • the socket unit sends the response to the message acquisition request to the application unit to the application unit Send the to-be-processed message.
  • the method for processing the service routing packet provided by the embodiment of the present invention may be performed by the socket unit pair in the service node SN, as compared with the information about the service routing in the prior art.
  • the service routing message is processed by the service routing information, and the application unit in the SN does not need to know the relevant information of the service routing, and only processes the service, thereby preventing the related information of the service routing from being exposed to the application unit in the SN, thereby improving Security of service routing.
  • the method may further include:
  • the socket unit determines the service routing information according to the second socket corresponding to the processed message
  • the socket unit saves the to-be-processed on the basis of the foregoing embodiment or the optional embodiment of FIG.
  • the correspondence between the packet and the second socket may specifically include:
  • the socket unit When the socket unit receives the first packet, if the second socket is not saved in the socket unit, the second socket is created, and the The processing message is added to the message queue corresponding to the second socket.
  • the socket unit saves the to-be-processed on the basis of the foregoing embodiment or the optional embodiment of FIG.
  • the correspondence between the packet and the second socket may specifically include:
  • the socket unit When the socket unit receives the first packet, if the second socket is saved in the socket unit, the to-be-processed message is added to the second The queue corresponding to the socket in the message.
  • the socket unit is from the SN, according to the foregoing embodiment or the optional embodiment of FIG.
  • the method may further include: before the application unit receives the message acquisition request including the second socket, the method may further include:
  • the socket unit sends the second socket to the application unit.
  • the socket unit is configured to be applied to the application, according to the foregoing embodiment or the optional embodiment.
  • sending, by the program unit, the to-be-processed message to the application unit, where the program unit sends the response to the message requesting request which may include:
  • the socket unit sends a response to the message acquisition request to the application unit, where the response carries a storage address of the to-be-processed message;
  • the application unit acquires the to-be-processed message according to the storage address.
  • the socket unit is configured to be applied to the application, according to the foregoing embodiment or the optional embodiment.
  • sending, by the program unit, the to-be-processed message to the application unit, where the program unit sends the response to the message requesting request which may include:
  • the socket unit sends a response to the message acquisition request to the application unit, where the response carries the to-be-processed message.
  • the method for processing the service routing message described in the embodiment of the present invention can be understood by referring to the description in the parts of FIG. 1 and FIG. 2, and details are not described in the embodiment of the present invention.
  • FIG. 4 is a schematic diagram of a service node SN30 according to an embodiment of the present invention.
  • the service node SN30 shown in FIG. 4 is the service node SN30 shown in FIG. 1 and FIG. 2, and may also be the service node in the embodiment corresponding to FIG. 3.
  • Individual units and subunits in the schematic diagram can be understood as logical units that are divided according to different logical functions.
  • the service node SN30 includes a socket unit 301 and an application unit 302.
  • the socket unit 301 includes:
  • the sub-unit 3011 is configured to create a first socket, where the first packet is used to monitor the first packet, and the first packet is a service routing packet belonging to the first service routing type.
  • the first packet includes the service routing information and the to-be-processed packet, and the first packet may be sent by the service router SR40 to the service node SN30, and the service node SN30 and the service router SN40 belong to the same system;
  • a determining subunit 3012 configured to determine, according to the first socket created by the creating subunit 3011, that the SN receives the first packet
  • a saving subunit 3013 configured to save a correspondence between the to-be-processed message and the second socket, where the second socket corresponds to the service routing information
  • the receiving subunit 3014 is configured to receive a message obtaining request from the application unit 302 in the SN, where the message obtaining request is used to request the to-be-processed message corresponding to the second socket;
  • the determining subunit 3012 is further configured to determine, according to the packet obtaining request received by the receiving subunit 3014 and the corresponding relationship saved by the saving subunit, that the to-be-processed packet is the requested packet. ;
  • a sending subunit 3015 configured to send, by using the application unit 302, the message And obtaining, by the application unit, the to-be-processed message determined by the determining subunit.
  • the information about the service routing in the prior art is all exposed to the APP layer, and the service node SN can provide the service routing information of the service routing message by the socket unit.
  • the processing unit of the SN does not need to know the information about the service route, and only processes the service, so as to prevent the related information of the service route from being exposed to the application unit in the SN, thereby improving the security of the service route.
  • the embodiment may further include a first alternative, the first alternative comprising the first part of the content of the SN 30.
  • This embodiment may further include a second alternative, the second alternative comprising the first part of the content of the SN 30 or the first alternative.
  • the creating subunit 3011 is further configured to: when the receiving subunit 3014 receives the first packet, if the saving subunit 3013 does not save the second a socket, the second socket is created; the saving sub-unit 3013 is specifically configured to add the to-be-processed message to the second socket created by the creating sub-unit 3011. In the message queue.
  • the embodiment may further include a third optional solution, where the third optional solution includes the first part of the content of the SN 30, the first option, or the second option.
  • the saving subunit 3013 is specifically configured to: when the receiving subunit 3014 receives the first packet, if the saving subunit 3013 holds the first Two sockets, then Adding the to-be-processed message to a message queue corresponding to the second socket.
  • the embodiment may further include a fourth optional solution, where the fourth optional solution includes the first part content of the SN 30, the first optional solution, the second optional solution, or the third optional Program.
  • the sending subunit 3015 is further configured to: before receiving, by the application unit 302 in the SN, the packet obtaining request including the second socket, to the application The unit transmits the second socket.
  • the embodiment may further include a fifth optional solution, where the fifth optional solution includes the first part content of the SN 30, the first optional solution, the second optional solution, and the third optional Scheme or the fourth alternative.
  • the sending sub-unit 3015 is configured to send, to the application unit, a response to the message acquiring request, where the response carries a storage address of the to-be-processed message;
  • the application unit 302 is configured to acquire the to-be-processed message according to the storage address.
  • the sending subunit 3015 is configured to send a response to the packet acquiring request to the application unit 302, where the response carries the to-be-processed, based on the foregoing part of the content of the SN 30 or any optional solution. Message.
  • the service node 30 shown in FIG. 4 can implement all the operations and functions of the service node 30 shown in FIG. 1 and FIG. 2 and the service node in the embodiment corresponding to FIG. 3. Since FIG. 4 embodies a service node from the perspective of logical functions, all of the operations and functions can be implemented by the respective units and sub-units shown in FIG. As to which unit and sub-unit are implemented by the whole operation and function respectively, this is only a logical division, that is, the service node 30 is divided into operations or added to a logical unit in FIG. 1, FIG. 2 or FIG. The method of division is very flexible. Any of the divisions should be considered as part of this embodiment.
  • FIG. 5 is a schematic structural diagram of the service node 30.
  • the service node 30 can include an input device 310, an output device 320, a processor 330, and a memory 340.
  • the service node 30 shown in FIG. 5 and the service node 30 shown in FIG. 4 may be the same service node, but FIG. 4 is embodied from the perspective of logical functions. This service node, and Figure 5 shows this service node from a physical implementation perspective.
  • Memory 340 can include read only memory and/or random access memory and provides instructions and data to processor 330. A portion of the memory 340 may also include non-volatile random access memory (NVRAM).
  • NVRAM non-volatile random access memory
  • the memory 340 stores the following elements, executable modules or data structures, or a subset thereof, or an extended set thereof:
  • Operation instructions include various operation instructions for implementing various operations.
  • Operating system Includes a variety of system programs for implementing various basic services and handling hardware-based tasks.
  • the processor 330 performs the following operations by calling an operation instruction stored in the memory 340, which can be stored in the operating system:
  • Creating a first socket where the first packet is used to monitor the first packet, and the first packet is a service routing packet belonging to the first service routing type, where the first packet includes Service routing information and pending messages;
  • the socket unit in the service node SN provides the service routing information processing on the service routing packet, and the application unit in the SN does not need to know the related information of the service routing, and only processes the service, thereby avoiding The information about the service route is exposed to the application unit in the SN, which improves the security of the service route.
  • the processor 330 controls the operation of the service node SN30, which may also be referred to as a CPU (Central Processing Unit).
  • Memory 340 can include read only memory and random access memory and provides instructions and data to processor 330. A portion of the memory 340 may also include non-volatile random access memory (NVRAM).
  • NVRAM non-volatile random access memory
  • the components of the service node SN30 are coupled together by a bus system 350.
  • the bus system 350 may include a power bus, a control bus, a status signal bus, and the like in addition to the data bus. However, for clarity of description, various buses are labeled as bus system 350 in the figure.
  • Processor 330 may be an integrated circuit chip with signal processing capabilities. In the implementation process, each step of the foregoing method may be completed by an integrated logic circuit of hardware in the processor 330 or an instruction in a form of software.
  • the processor 330 described above may be a general purpose processor, a digital signal processor (DSP), an application specific integrated circuit (ASIC), an off-the-shelf programmable gate array (FPGA) or other programmable logic device, a discrete gate or transistor logic device, or discrete hardware. Component.
  • DSP digital signal processor
  • ASIC application specific integrated circuit
  • FPGA off-the-shelf programmable gate array
  • the methods, steps, and logical block diagrams disclosed in the embodiments of the present invention may be implemented or carried out.
  • the general purpose processor may be a microprocessor or the processor or any conventional processor or the like.
  • the steps of the method disclosed in the embodiments of the present invention may be directly implemented by the hardware decoding processor, or may be performed by a combination of hardware and software modules in the decoding processor.
  • the software module can be located in a conventional storage medium such as random access memory, flash memory, read only memory, programmable read only memory or electrically erasable programmable memory, registers, and the like.
  • the storage medium is located in memory 340, and processor 330 reads the information in memory 340 and, in conjunction with its hardware, performs the steps of the above method.
  • the input device 310 is further configured to receive, from the application unit, a processed message corresponding to the second socket, where the processed message is configured by the application unit The processed message is processed;
  • the processor 330 is further configured to determine the service routing information according to the second socket corresponding to the processed message;
  • the output device 320 is further configured to send a second packet to the service router SR, where the second packet is a service routing packet that includes the processed packet, and the service routing information of the second packet includes The service routing information.
  • the processor is specifically configured to: when the socket unit receives the first packet, if the second socket is not saved in the socket unit, create a Said second socket;
  • the memory 340 is specifically configured to add the to-be-processed message to a message queue corresponding to the second socket.
  • the memory 340 is specifically configured to: when the socket unit receives the first packet, if the second socket is saved in the socket unit, The pending processing message is added to the message queue corresponding to the second socket.
  • the output device 320 is configured to send the second socket to the application unit.
  • the output device 320 is specifically configured to send, by the socket unit, a response to the message acquiring request to the application unit, where the response carries a storage address of the to-be-processed message;
  • the application unit acquires the to-be-processed message according to the storage address.
  • the output device 320 is specifically configured to send, to the application unit, a response to the message acquisition request, where the response carries the to-be-processed message.
  • the socket unit 301 and application unit 302 in the service node 30 shown in FIG. 4 can be implemented as being implemented by the processor 330 based on readable instructions stored in the memory 340 and data that needs to be used. All of the instructions and data needed to implement the socket unit 301 and the application unit 302 can be stored in the memory 340.
  • the processing reads the corresponding instruction and operates in accordance with the instruction, thereby implementing the socket unit 301 and the application unit 302.
  • the program may be stored in a computer readable storage medium, and the storage medium may include: ROM, RAM, disk or CD.

Landscapes

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

Abstract

Disclosed is a service router (SR) packet processing method, comprising: a socket unit in a service node (SN) creating a first socket, the first socket being used to listen for a first packet, and the first packet comprising SR information and a packet to be processed; storing the correspondence between the packet to be processed and a second socket, the second socket corresponding to the SR information; receiving a packet acquisition request from an application (APP) unit in the SN, and determining, according to the packet acquisition request and the correspondence, that the packet to be processed is the requested packet; and transmitting the packet to be processed to the APP unit by transmitting to the APP unit a response to the packet acquisition request. The SR packet processing method of the present invention prevents related information of the SR from being disclosed to the APP unit in the SN, and improves the security of the SR.

Description

一种对业务路由报文进行处理的方法和业务节点Method and service node for processing service routing message
本申请要求于2014年5月30日提交中国专利局、申请号为CN 201410240822.7、发明名称为“一种对业务路由报文进行处理的方法和业务节点”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。This application claims the priority of the Chinese Patent Application filed on May 30, 2014, the Chinese Patent Office, the application number is CN 201410240822.7, and the invention name is “a method and service node for processing service routing messages”. The content is incorporated herein by reference.
技术领域Technical field
本发明涉及数据处理技术领域,具体涉及一种对业务路由报文进行处理的方法和业务节点。The present invention relates to the field of data processing technologies, and in particular, to a method and a service node for processing a service routing message.
背景技术Background technique
业务链(英文为Service Chaining)技术,是一种引导网络业务报文次序通过多个业务节点(英文为Service Node,英文缩写为SN)的转发技术,其中,业务报文在各个节点之间的转发行为称为业务路由。The service chain (Service Chaining) technology is a forwarding technology that guides the order of network service packets through multiple service nodes (English is Service Node, English abbreviated as SN), where service packets are between nodes. The forwarding behavior is called a service route.
目前,业务报文在各SN之间进行转发时,需要给原始报文封装上业务路由头中,该业务路由头用于指导业务报文的转发行为,同时,也会在封装信息中携带元数据(英文为metadata),元数据可以是业务路由器(英文为Service Router,英文缩写为SR)产生或SN自身产生,并可以被修改。At the same time, when the service packet is forwarded between the SNs, the original packet is encapsulated in the service routing header. The service routing header is used to guide the forwarding of the service packet and also carries the element in the encapsulation information. The data (metadata in English), the metadata can be generated by the service router (English Service Router, abbreviated as SR) or generated by the SN itself, and can be modified.
对于SN的入口报文标准,大体上可以分为两类,一类是:到达SN的报文是原始报文时,SN可以直接接收、处理并发送。另一类是:到达SN的报文是带有业务路由头信息及元数据的业务路由报文,这时,SN需要在接收到业务路由报文时,能够识别并剥离业务路由头,对原始报文处理完成后,能够为原始报文封装适当的业务路由头,并发送至SR。The SN entry message standards can be generally divided into two categories. One type is: when the message arriving at the SN is the original message, the SN can directly receive, process, and send. The other type is that the packet arriving at the SN is a service routing packet with the service routing header information and the metadata. In this case, the SN needs to identify and strip the service routing header when receiving the service routing packet. After the packet is processed, the appropriate service routing header can be encapsulated for the original packet and sent to the SR.
现有技术方案中,SN中的应用(英文为Application,英文缩写为APP)层直接通过网络驱动层获取业务路由报文,自行剥离业务路由头,识别原始报文并处理,处理完成后,APP层自行为报文封装适当的业务路由头,并通过网络驱动层发出。In the prior art solution, the application in the SN (Application in English is APP) directly obtains service routing packets through the network driver layer, strips the service routing headers, identifies the original packets, and processes them. After the processing is completed, the APP The layer encapsulates the appropriate service routing headers for the packets and sends them through the network driver layer.
本发明的发明人发现,现有技术中业务路由的相关信息全部暴露给APP 层,存在安全隐患。The inventors of the present invention have found that all related information of service routing in the prior art is exposed to the APP. Layer, there are security risks.
发明内容Summary of the invention
本发明实施例提供一种对业务路由报文进行处理的方法,可以由业务节点SN中的套接字单元对业务路由报文进行业务路由信息的处理,SN中的应用程序单元不需要获知业务路由的相关信息,只对业务进行处理,从而避免业务路由的相关信息暴露给SN中的应用程序单元,提高了业务路由的安全性。本发明实施例还提供了相应的业务节点。The embodiment of the present invention provides a method for processing a service routing message, which may be processed by a socket unit in the service node SN for service routing information, and the application unit in the SN does not need to learn the service. The information related to the route is processed only to prevent the related information of the service route from being exposed to the application unit in the SN, thereby improving the security of the service route. The embodiment of the invention also provides a corresponding service node.
本发明第一方面提供一种对业务路由报文进行处理的方法,包括:A first aspect of the present invention provides a method for processing a service routing message, including:
业务节点SN中的套接字单元创建第一套接字,所述第一套接字用于对第一报文进行监听,所述第一报文为属于第一业务路由类型的业务路由报文,所述第一报文包括业务路由信息和待处理报文;The socket unit in the service node SN creates a first socket, and the first socket is used to listen to the first packet, where the first packet is a service routing report belonging to the first service routing type. The first packet includes the service routing information and the to-be-processed packet.
所述套接字单元根据所述第一套接字确定所述SN接收到所述第一报文;Determining, by the socket unit, that the SN receives the first packet according to the first socket;
所述套接字单元保存所述待处理报文和第二套接字的对应关系,其中所述第二套接字与所述业务路由信息相对应;The socket unit stores a correspondence between the to-be-processed message and the second socket, where the second socket corresponds to the service routing information;
所述套接字单元从所述SN中的应用程序单元接收报文获取请求,所述报文获取请求用于请求与所述第二套接字对应的所述待处理报文;The socket unit receives a message acquisition request from an application unit in the SN, where the message acquisition request is used to request the to-be-processed message corresponding to the second socket;
所述套接字单元根据所述报文获取请求和所述对应关系确定所述待处理报文为被请求的报文;Determining, by the socket unit, the to-be-processed message as the requested message according to the packet obtaining request and the corresponding relationship;
所述套接字单元通过向所述应用程序单元发送针对所述报文获取请求的响应的方式,向所述应用程序单元发送所述待处理报文。The socket unit sends the to-be-processed message to the application unit by sending a response to the message acquisition request to the application unit.
结合第一方面,在第一种可能的实现方式中,所述方法还包括:In conjunction with the first aspect, in a first possible implementation, the method further includes:
所述套接字单元从所述应用程序单元接收与所述第二套接字对应的已处理报文,所述已处理报文是由所述应用程序单元对所述待处理报文进行处理而得到的;Receiving, by the application unit, a processed message corresponding to the second socket, where the processed message is processed by the application unit to process the to-be-processed message Obtained
所述套接字单元根据与所述已处理报文相对应的所述第二套接字,确定所述业务路由信息; The socket unit determines the service routing information according to the second socket corresponding to the processed message;
向业务路由器SR发送第二报文,所述第二报文为包括所述已处理报文的业务路由报文,所述第二报文的业务路由信息包括所述业务路由信息。Sending a second packet to the service router SR, where the second packet is a service routing packet that includes the processed packet, and the service routing information of the second packet includes the service routing information.
结合第一方面或第一方面第一种可能的实现方式,在第二种可能的实现方式中,所述套接字单元保存所述待处理报文和所述第二套接字的对应关系具体包括:With reference to the first aspect or the first possible implementation manner of the first aspect, in a second possible implementation manner, the socket unit saves a correspondence between the to-be-processed message and the second socket Specifically include:
所述套接字单元在接收到所述第一报文时,如果所述套接字单元中未保存所述第二套接字,则创建所述第二套接字,并将所述待处理报文添加至与所述第二套接字对应的报文队列中。When the socket unit receives the first packet, if the second socket is not saved in the socket unit, the second socket is created, and the The processing message is added to the message queue corresponding to the second socket.
结合第一方面或第一方面第一种可能的实现方式,在第三种可能的实现方式中,所述套接字单元保存所述待处理报文和所述第二套接字的对应关系具体包括:With reference to the first aspect or the first possible implementation manner of the first aspect, in a third possible implementation, the socket unit saves a correspondence between the to-be-processed message and the second socket Specifically include:
所述套接字单元在接收到所述第一报文时,如果所述套接字单元中保存有所述第二套接字,则将所述待处理报文添加至与所述第二套接字对应的报文队列中。When the socket unit receives the first packet, if the second socket is saved in the socket unit, the to-be-processed message is added to the second The queue corresponding to the socket in the message.
结合第一方面、第一方面第一种至第三种可能的实现方式中的任意一种,在第四种可能的实现方式中,所述套接字单元从所述SN中的应用程序单元接收包括所述第二套接字的报文获取请求之前,所述方法还包括:With reference to the first aspect, any one of the first to third possible implementation manners of the first aspect, in a fourth possible implementation, the socket unit is from an application unit in the SN Before receiving the packet obtaining request including the second socket, the method further includes:
所述套接字单元向所述应用程序单元发送所述第二套接字。The socket unit sends the second socket to the application unit.
结合第一方面、第一方面第一种至第四种可能的实现方式中的任意一种,在第五种可能的实现方式中,所述套接字单元通过向所述应用程序单元发送针对所述报文获取请求的响应的方式,向所述应用程序单元发送所述待处理报文,包括:With reference to the first aspect, any one of the first to fourth possible implementation manners of the first aspect, in a fifth possible implementation, the socket unit is configured to send to the application unit And sending, by the application unit, the to-be-processed message, the method includes:
所述套接字单元向所述应用程序单元发送针对所述报文获取请求的响应,所述响应中携带所述待处理报文的存储地址;The socket unit sends a response to the message acquisition request to the application unit, where the response carries a storage address of the to-be-processed message;
所述应用程序单元根据所述存储地址,获取所述待处理报文。The application unit acquires the to-be-processed message according to the storage address.
结合第一方面、第一方面第一种至第五种可能的实现方式中的任意一种,在第六种可能的实现方式中,所述套接字单元通过向所述应用程序单元发送 针对所述报文获取请求的响应的方式,向所述应用程序单元发送所述待处理报文,包括:With reference to the first aspect, any one of the first to fifth possible implementation manners of the first aspect, in a sixth possible implementation, the socket unit is sent by using the application unit And sending, to the application unit, the to-be-processed message, in the manner of the response of the packet obtaining request, including:
所述套接字单元向所述应用程序单元发送针对所述报文获取请求的响应,所述响应中携带所述待处理报文。The socket unit sends a response to the message acquisition request to the application unit, where the response carries the to-be-processed message.
本发明第二方面提供一种业务节点,包括:套接字单元和应用程序单元;A second aspect of the present invention provides a service node, including: a socket unit and an application unit;
所述套接字单元包括:The socket unit includes:
创建子单元,用于创建第一套接字,所述第一套接字用于对第一报文进行监听,所述第一报文为属于第一业务路由类型的业务路由报文,所述第一报文包括业务路由信息和待处理报文;Creating a sub-unit, configured to create a first socket, where the first packet is used to listen to the first packet, where the first packet is a service routing packet belonging to the first service routing type. The first packet includes service routing information and pending packets;
确定子单元,用于根据所述创建子单元创建的所述第一套接字确定所述SN接收到所述第一报文;Determining a subunit, configured to determine, according to the first socket created by the creating subunit, that the SN receives the first packet;
保存子单元,用于保存所述待处理报文和第二套接字的对应关系,其中所述第二套接字与所述业务路由信息相对应;a saving subunit, configured to save a correspondence between the to-be-processed message and the second socket, where the second socket corresponds to the service routing information;
接收子单元,用于从所述SN中的应用程序单元接收报文获取请求,所述报文获取请求用于请求与所述第二套接字对应的所述待处理报文;a receiving subunit, configured to receive a message obtaining request from an application unit in the SN, where the message obtaining request is used to request the to-be-processed message corresponding to the second socket;
所述确定子单元,还用于根据所述接收子单元接收的所述报文获取请求和所述保存子单元保存的所述对应关系确定所述待处理报文为被请求的报文;The determining subunit is further configured to determine, according to the packet obtaining request that is received by the receiving subunit and the corresponding relationship that is saved by the saving subunit, that the to-be-processed packet is the requested packet;
发送子单元,用于通过向所述应用程序单元发送针对所述报文获取请求的响应的方式,向所述应用程序单元发送所述确定子单元确定的所述待处理报文。And a sending subunit, configured to send the to-be-processed message determined by the determining subunit to the application unit by sending a response to the packet request to the application unit.
结合第二方面,在第一种可能的实现方式中,In combination with the second aspect, in a first possible implementation manner,
所述接收子单元,还用于从所述应用程序单元接收与所述第二套接字对应的已处理报文,所述已处理报文是由所述应用程序单元对所述待处理报文进行处理而得到的;The receiving subunit is further configured to receive, from the application unit, a processed message corresponding to the second socket, where the processed message is sent by the application unit to the to-be-processed message Obtained by processing the text;
所述确定子单元,还用于根据与所述接收子单元接收的所述已处理报文相对应的所述第二套接字,确定所述业务路由信息; The determining subunit is further configured to determine the service routing information according to the second socket corresponding to the processed message received by the receiving subunit;
所述发送子单元,还用于向业务路由器SR发送第二报文,所述第二报文为包括所述已处理报文的业务路由报文,所述第二报文的业务路由信息包括所述确定子单元确定的所述业务路由信息。The sending subunit is further configured to send a second packet to the service router SR, where the second packet is a service routing packet that includes the processed packet, and the service routing information of the second packet includes Determining the service routing information determined by the subunit.
结合第二方面或第二方面第一种可能的实现方式,在第二种可能的实现方式中,With reference to the second aspect or the first possible implementation manner of the second aspect, in a second possible implementation manner,
所述创建子单元,还用于在所述接收子单元接收到所述第一报文时,如果所述保存子单元中未保存所述第二套接字,则创建所述第二套接字;The creating subunit is further configured to: when the receiving subunit receives the first packet, if the second socket is not saved in the saving subunit, create the second socket word;
所述保存子单元,具体用于将所述待处理报文添加至与所述创建子单元创建的所述第二套接字对应的报文队列中。The saving subunit is specifically configured to add the to-be-processed message to a message queue corresponding to the second socket created by the creating subunit.
结合第二方面或第二方面第一种可能的实现方式,在第三种可能的实现方式中,With reference to the second aspect or the first possible implementation manner of the second aspect, in a third possible implementation manner,
所述保存子单元,具体用于在所述接收子单元接收到所述第一报文时,如果所述保存子单元中保存有所述第二套接字,则将所述待处理报文添加至与所述第二套接字对应的报文队列中。The saving subunit is configured to: when the receiving subunit receives the first packet, if the second socket is saved in the saving subunit, the to-be-processed packet is sent Add to the message queue corresponding to the second socket.
结合第二方面、第二方面第一种至第三种可能的实现方式中的任意一种,在第四种可能的实现方式中,With reference to the second aspect, any one of the first to third possible implementation manners of the second aspect, in a fourth possible implementation manner,
所述发送子单元,还用于从所述SN中的应用程序单元接收包括所述第二套接字的报文获取请求之前,向所述应用程序单元发送所述第二套接字。The sending subunit is further configured to send the second socket to the application unit before receiving a message obtaining request including the second socket from an application unit in the SN.
结合第二方面、第二方面第一种至第四种可能的实现方式中的任意一种,在第五种可能的实现方式中,With reference to the second aspect, any one of the first to fourth possible implementation manners of the second aspect, in a fifth possible implementation manner,
所述发送子单元,用于向所述应用程序单元发送针对所述报文获取请求的响应,所述响应中携带所述待处理报文的存储地址;The sending subunit is configured to send a response to the packet obtaining request to the application unit, where the response carries a storage address of the to-be-processed packet;
所述应用程序单元,用于根据所述存储地址,获取所述待处理报文。The application unit is configured to acquire the to-be-processed message according to the storage address.
结合第二方面、第二方面第一种至第五种可能的实现方式中的任意一种,在第六种可能的实现方式中,With reference to the second aspect, any one of the first to fifth possible implementation manners of the second aspect, in a sixth possible implementation manner,
所述发送子单元,用于向所述应用程序单元发送针对所述报文获取请求的响应,所述响应中携带所述待处理报文。 The sending subunit is configured to send a response to the packet obtaining request to the application unit, where the response carries the to-be-processed message.
本发明实施例业务节点SN中的套接字单元创建第一套接字,所述第一套接字用于对第一报文进行监听,所述第一报文为属于第一业务路由类型的业务路由报文,所述第一报文包括业务路由信息和待处理报文;所述套接字单元根据所述第一套接字确定所述SN接收到所述第一报文;所述套接字单元保存所述待处理报文和第二套接字的对应关系,其中所述第二套接字与所述业务路由信息相对应;所述套接字单元从所述SN中的应用程序单元接收报文获取请求,所述报文获取请求用于请求与所述第二套接字对应的所述待处理报文;所述套接字单元根据所述报文获取请求和所述对应关系确定所述待处理报文为被请求的报文;所述套接字单元通过向所述应用程序单元发送针对所述报文获取请求的响应的方式,向所述应用程序单元发送所述待处理报文。与现有技术中业务路由的相关信息全部暴露给APP层,存在安全隐患相比,本发明实施例提供的对业务路由报文进行处理的方法,可以由业务节点SN中的套接字单元对业务路由报文进行业务路由信息的处理,SN中的应用程序单元不需要获知业务路由的相关信息,只对业务进行处理,从而避免业务路由的相关信息暴露给SN中的应用程序单元,提高了业务路由的安全性。In the embodiment of the present invention, the socket unit in the service node SN creates a first socket, and the first socket is used to listen to the first packet, where the first packet belongs to the first service routing type. The service routing message, the first packet includes service routing information and a to-be-processed message; the socket unit determines, according to the first socket, that the SN receives the first packet; The socket unit saves a correspondence between the to-be-processed message and the second socket, where the second socket corresponds to the service routing information; the socket unit is from the SN The application unit receives a message acquisition request, and the message acquisition request is used to request the to-be-processed message corresponding to the second socket; the socket unit acquires a request according to the message and Determining, by the correspondence, the to-be-processed message is a requested message; the socket unit sends the response to the message acquisition request to the application unit to the application unit Send the to-be-processed message. The method for processing the service routing packet provided by the embodiment of the present invention may be performed by the socket unit pair in the service node SN, as compared with the information about the service routing in the prior art. The service routing message is processed by the service routing information, and the application unit in the SN does not need to know the relevant information of the service routing, and only processes the service, thereby preventing the related information of the service routing from being exposed to the application unit in the SN, thereby improving Security of service routing.
附图说明DRAWINGS
为了更清楚地说明本发明实施例中的技术方案,下面将对实施例描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本发明的一些实施例,对于本领域技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the drawings used in the description of the embodiments will be briefly described below. It is obvious that the drawings in the following description are only some embodiments of the present invention. Other drawings can also be obtained from those skilled in the art based on these drawings without paying any creative effort.
图1是本发明实施例中对业务路由报文进行处理的方法的一实施例示意图;1 is a schematic diagram of an embodiment of a method for processing a service routing message according to an embodiment of the present invention;
图2是本发明实施例中对业务路由报文进行处理的方法的一实施例示意图;2 is a schematic diagram of an embodiment of a method for processing a service routing message according to an embodiment of the present invention;
图3是本发明实施例中对业务路由报文进行处理的方法的一实施例示意图; 3 is a schematic diagram of an embodiment of a method for processing a service routing message according to an embodiment of the present invention;
图4是本发明实施例中业务节点的示意图;4 is a schematic diagram of a service node in an embodiment of the present invention;
图5是本发明实施例中业务节点的示意图。FIG. 5 is a schematic diagram of a service node in an embodiment of the present invention.
具体实施方式detailed description
本发明实施例提供对业务路由报文进行处理的方法,可以由业务节点SN中的套接字单元对业务路由报文进行业务路由信息的处理,SN中的应用程序单元不会获知业务路由的相关信息,只对业务进行处理,从而避免业务路由的相关信息暴露给SN中的应用程序单元,提高了业务路由的安全性。本发明实施例还提供了相应的业务节点。以下分别进行详细说明。The embodiment of the present invention provides a method for processing a service routing message, which may be processed by a socket unit in the service node SN for service routing information, and the application unit in the SN does not know the service route. The related information is processed only to prevent the related information of the service route from being exposed to the application unit in the SN, thereby improving the security of the service route. The embodiment of the invention also provides a corresponding service node. The details are described below separately.
下面将结合本发明实施例中的附图,对本发明实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅仅是本发明一部分实施例,而不是全部的实施例。基于本发明中的实施例,本领域技术人员在没有作出创造性劳动前提下所获得的所有其他实施例,都属于本发明保护的范围。The technical solutions in the embodiments of the present invention are clearly and completely described in the following with reference to the accompanying drawings in the embodiments of the present invention. It is obvious that the described embodiments are only a part of the embodiments of the present invention, but not all embodiments. All other embodiments obtained by a person skilled in the art based on the embodiments of the present invention without creative efforts are within the scope of the present invention.
参阅图1,本发明实施例提供的对业务路由报文进行处理的方法的一实施例包括:Referring to FIG. 1, an embodiment of a method for processing a service routing packet according to an embodiment of the present invention includes:
本发明实施例提供了一种新的第一套接字(英文为socket)协议族,用于在驱动层协助应用层完成业务路由报文的部分处理,可以将该新的业务路由socket协议族命名为AF_SR,当然,也可以用其他名字命名。The embodiment of the present invention provides a new first socket (English socket) protocol family, which is used to assist the application layer to complete partial processing of service routing messages at the driver layer, and can route the new service to the socket protocol family. Named AF_SR, of course, can also be named with other names.
业务路由器SR在与业务节点SN间传输业务路由报文时,本发明实施例在SN中引入了一套新的业务路由socket协议栈,该协议栈对APP提供的应用程序接口(英文名称为Application Programming Interface,英文缩写为API)集合定义为SR socket API。When the service router SR transmits the service routing message between the service node and the service node SN, the embodiment of the present invention introduces a new service routing socket protocol stack in the SN, and the application program interface provided by the protocol stack to the APP (English name is Application) The Programming Interface (abbreviated as API) collection is defined as the SR socket API.
API的处理模块为业务路由器套接字模块(英文为SR socket Module),以下简称为SRM。The processing module of the API is a service router socket module (SR socket module in English), hereinafter referred to as SRM.
如图1所示,业务节点SN包括两部分,一部分为套接字单元,一部分为应用程序单元,套接字单元包括SR socket API和SRM两部分。As shown in FIG. 1, the service node SN includes two parts, one part is a socket unit, one part is an application unit, and the socket unit includes two parts: an SR socket API and an SRM.
参阅图2,本发明实施例提供的对业务路由报文进行处理的方法的一实施 例包括:Referring to FIG. 2, an implementation of a method for processing a service routing message according to an embodiment of the present invention is provided. Examples include:
S100、业务节点SN30中的套接字单元301创建第一套接字。S100. The socket unit 301 in the service node SN30 creates a first socket.
所述第一套接字用于对第一报文进行监听,所述第一报文为属于第一业务路由类型的业务路由报文,所述第一报文包括业务路由信息和待处理报文。The first socket is configured to listen to the first packet, where the first packet is a service routing packet that belongs to the first service routing type, and the first packet includes the service routing information and the to-be-processed packet. Text.
套接字单元301创建第一套接字的具体过程可以包括如下内容。The specific process of the socket unit 301 to create the first socket may include the following.
应用程序单元302向套接字单元301发送第一套接字的创建指令,这个步骤结合图1可以理解为是:应用程序单元调用SR socket API中的业务路由socket API。The application unit 302 sends a first socket creation instruction to the socket unit 301. This step can be understood in conjunction with FIG. 1 as: the application unit calls the service routing socket API in the SR socket API.
套接字单元301根据所述第一套接字的创建指令,创建所述第一套接字。The socket unit 301 creates the first socket according to the creation instruction of the first socket.
套接字单元301创建第一套接字后,可以开始接收属于第一业务路由类型的第一报文,这个接收第一报文的指令可以由应用程序单元302通过第一套接字的调用指令向所述套接字单元301触发,所述套接字单元301接收到所述第一套接字的调用指令后,就可以获知可以接收第一业务路由类型的第一报文。After the socket unit 301 creates the first socket, it can start receiving the first message belonging to the first service route type, and the instruction for receiving the first message can be invoked by the application unit 302 through the first socket. The instruction is triggered to the socket unit 301. After receiving the call instruction of the first socket, the socket unit 301 can learn that the first message of the first service route type can be received.
举例来说,本发明实施例中的业务路由类型可以是:业务路由承载层的传输类型和/或传输方式等。For example, the service routing type in the embodiment of the present invention may be: a transmission type and/or a transmission mode of the service routing bearer layer.
通常一个应用程序单元具有对属于一个业务路由类型的业务路由报文中的待处理报文的处理能力,当然,也可以具有属于多种业务路由类型的业务路由报文中的待处理报文的处理能力,一个SN中可以有多个应用程序单元。Generally, an application unit has the processing capability of the to-be-processed packet in the service routing packet belonging to a service routing type, and of course, it can also have the to-be-processed packet in the service routing packet belonging to multiple service routing types. Processing power, there can be multiple application units in one SN.
套接字单元301创建第一套接字的具体过程还可以包括:不由应用程序单元发起创建过程,而是由套接字单元根据所述第一业务路由类型,主动创建所述第一套接字。例如,套接字单元可以在其所在的SN启动后主动创建所述第一套接字,也可以在到达某个预定时间后主动创建所述第一套接字。The specific process of the socket unit 301 to create the first socket may further include: the creation process is not initiated by the application unit, but the socket unit actively creates the first socket according to the first service route type. word. For example, the socket unit may actively create the first socket after the SN where it is started, or may actively create the first socket after reaching a predetermined time.
此外,套接字单元301还可以根据网络中控制器的指令来创建所述第一套接字。In addition, the socket unit 301 can also create the first socket according to an instruction of a controller in the network.
对所述第一套接字的创建过程可以包括创建一个套接字的操作,还可以继续包括对所述已创建的套接字进行配置的操作。 The process of creating the first socket may include an operation of creating a socket, and may continue to include an operation of configuring the created socket.
S102、业务路由器SR40向业务节点30发送所述第一报文。S102. The service router SR40 sends the first packet to the service node 30.
S105、所述套接字单元301根据所述第一套接字确定所述SN30接收到所述第一报文。S105. The socket unit 301 determines, according to the first socket, that the SN30 receives the first packet.
第一套接字对应第一业务路由类型,所述第一报文为属于第一业务路由类型的业务路由报文,当套接字单元301接收到的报文的业务路由类型为第一业务路由类型时,则可以确定该报文为第一报文。The first socket corresponds to the first service routing type, and the first packet is a service routing packet of the first service routing type, and the service routing type of the packet received by the socket unit 301 is the first service. When the route type is used, the packet can be determined to be the first packet.
可选地,套接字单元301在获知第一业务路由类型后,才开始从SR接收该第一业务路由类型的第一报文。Optionally, the socket unit 301 starts to receive the first packet of the first service route type from the SR after the first service route type is learned.
这个步骤参阅图1可以理解为是:SRM按照第一业务路由类型从SR接收第一报文。This step can be understood by referring to FIG. 1 as follows: The SRM receives the first packet from the SR according to the first service route type.
S110、所述套接字单元在接收到所述第一报文时,判断所述套接字单元中是否保存有第二套接字。如果否则执行步骤S115,如果是则执行步骤S120。S110. The socket unit determines, when the first packet is received, whether the second socket is saved in the socket unit. If otherwise, step S115 is performed, and if yes, step S120 is performed.
本发明实施例中的第二套接字附属于第一套接字,第一套接字对应第一业务路由类型,第二套接字对应该属于第一业务路由类型的一个会话。可以有多个会话均属于所述第一业务路由类型。The second socket in the embodiment of the present invention is attached to the first socket, the first socket corresponds to the first service routing type, and the second socket corresponds to a session of the first service routing type. There may be multiple sessions belonging to the first service route type.
本发明实施例中,套接字单元在接收到所述第一报文后,可以对该第一报文进行解析并将该第一报文中的业务路由信息和待处理报文分离,也可以不执行分离的过程。In the embodiment of the present invention, after receiving the first packet, the socket unit may parse the first packet and separate the service routing information and the to-be-processed packet in the first packet. The process of separation may not be performed.
业务路由信息携带在第一报文的业务路由头中,待处理报文可以包括没有任何路由信息的原始报文,也可以包括没有任何路由信息的原始报文和元数据。The service routing information is carried in the service routing header of the first packet. The to-be-processed packet may include the original packet without any routing information, and may also include the original packet and metadata without any routing information.
这个步骤参阅图1可以理解为是SRM所执行的过程。This step can be understood as a process performed by SRM with reference to FIG.
S115、如果所述套接字单元中未保存所述第二套接字,则创建所述第二套接字,并将所述待处理报文添加至与所述第二套接字对应的报文队列中。S115. If the second socket is not saved in the socket unit, create the second socket, and add the to-be-processed message to the second socket. In the message queue.
业务路由信息与第二套接字的对应关系是唯一的,每个业务路由信息都会唯一对应一个第二套接字。一个业务路由信息可以对应多个待处理报文,可以针对一个第二套接字建立一个待处理报文的队列,将同一个业务路由信 息下的所述待处理报文都存储到该队列中。The correspondence between the service routing information and the second socket is unique, and each service routing information uniquely corresponds to a second socket. A service routing information can correspond to multiple pending packets, and a queue of pending packets can be established for a second socket, and the same service routing letter is used. The pending message in the message is stored in the queue.
可以参阅表1所提供的业务路由映射表来理解第二套接字、业务路由类型、业务路由信息和待处理报文队列的对应关系。You can refer to the service route mapping table provided in Table 1 to understand the correspondence between the second socket, service route type, service routing information, and pending message queue.
表1:业务路由映射表Table 1: Service Route Mapping Table
第二套接字Second socket 业务路由信息Service routing information 待处理报文队列Pending message queue
11 业务路由信息1Service routing information 1 Q1Q1
22 业务路由信息2Service routing information 2 Q2Q2
33 业务路由信息3Service routing information 3 Q3Q3
... ... ...
NN 业务路由信息NService routing information N QNQN
从表1中可以看出,每个第二套接字都对应一个业务路由信息,该业务路由信息要属于S100中的第一业务路由类型。每个第二套接字标识还对应着该业务路由信息下的所有待处理报文的队列。It can be seen from Table 1 that each second socket corresponds to one service routing information, and the service routing information belongs to the first service routing type in S100. Each second socket identifier also corresponds to a queue of all pending packets under the service routing information.
当套接字单元确定到第一报文中的业务路由信息在套接字单元中不存在时,也就可以理解为在表1中不存在该业务路由信息的表项,这时就需要在表1中建立该业务路由信息对应的表项。When the socket unit determines that the service routing information in the first packet does not exist in the socket unit, it can be understood that the entry of the service routing information does not exist in the table 1, and the Table 1 lists the entries corresponding to the service routing information.
这个步骤参阅图1可以理解为是SRM所执行的过程。This step can be understood as a process performed by SRM with reference to FIG.
表1还可以包含业务路由类型,加入业务路由类型后可以参阅表2进行理解。Table 1 can also include the service route type. After adding the service route type, refer to Table 2 for understanding.
表2:业务路由映射表Table 2: Service Route Mapping Table
第二套接字Second socket 路由类型Route type 务路由信息Routing information 理报文队列Message queue
11 Type1Type1 务路由信息1Routing information 1 Q1Q1
22 Type2Type2 务路由信息2Routing information 2 Q2Q2
33 Type3Type3 务路由信息3Routing information 3 Q3Q3
... ... ... ...
NN TypeNTypeN 务路由信息NRouting information N QNQN
S120、所述套接字单元在接收到所述第一报文时,如果所述套接字单元中保存有所述第二套接字,则将所述待处理报文添加至与所述第二套接字对应的报文队列中。S120. When receiving the first packet, the socket unit adds the to-be-processed message to the same if the second socket is saved in the socket unit. The packet queue corresponding to the second socket.
所述业务路由信息在套接字单元中存在时,就可以理解为在表1中已经存在了该业务路由信息的表项,不需要再重新建立,只需要将该待处理报文存储到该业务路由信息对应的待处理报文队列中。例如:当表1中保存有第二套接字1和报文队列Q1的对应关系,则可以将所述待处理报文添加到Q1队列中。When the service routing information exists in the socket unit, it can be understood that the entry of the service routing information already exists in the table 1 and does not need to be re-established, and only the to-be-processed message needs to be stored in the The queue of pending packets corresponding to the service routing information. For example, when the correspondence between the second socket 1 and the message queue Q1 is saved in the table 1, the to-be-processed message can be added to the Q1 queue.
这个步骤参阅图1可以理解为是SRM所执行的过程。This step can be understood as a process performed by SRM with reference to FIG.
S125、所述套接字单元301向所述应用程序单元302发送所述第二套接字。S125. The socket unit 301 sends the second socket to the application unit 302.
本步骤可以是:套接字单元301接收所述应用程序单元302发送的第二套接字获取指令,然后套接字单元301根据所述第二套接字获取指令,向所述应用程序单元302发送所述第二套接字。This step may be: the socket unit 301 receives the second socket acquisition instruction sent by the application unit 302, and then the socket unit 301 sends the instruction to the application unit according to the second socket acquisition instruction. 302 transmits the second socket.
例如:应用程序单元302需要处理待处理报文时,先向套接字单元发送第二套接字获取指令。For example, when the application unit 302 needs to process the to-be-processed message, it first sends a second socket acquisition instruction to the socket unit.
这个步骤结合图1可以理解为是:应用程序单元调用SR socket API中的第二套接字创建接口。This step, in conjunction with Figure 1, can be understood as: the application unit calls the second socket creation interface in the SR socket API.
套接字单元301接收到该第二套接字获取指令后,通常会按照第二套接字生成的顺序向应用程序单元302发送第二套接字标识。After receiving the second socket acquisition instruction, the socket unit 301 generally sends the second socket identifier to the application unit 302 in the order in which the second socket is generated.
当然也可以是其他的预置策略,例如:先发送第二套接字是奇数的,再发送第二套接字是偶数的。Of course, other preset strategies may also be used, for example, sending the second socket first is odd, and then sending the second socket is even.
这个步骤参阅图1可以理解为是SRM所执行的过程。This step can be understood as a process performed by SRM with reference to FIG.
所述套接字单元向所述应用程序单元发送所述第二套接字还可以包括:套接字单元301在生成第二套接字后,在没有收到所述第二套接字获取指令的情况下,主动向所述应用程序单元302发送所述第二套接字。The sending, by the socket unit, the second socket to the application unit may further include: after the second socket is generated, the socket unit 301 does not receive the second socket. In the case of an instruction, the second socket is actively sent to the application unit 302.
S130、所述套接字单元301从所述SN中的应用程序单元302接收报文获 取请求,所述报文获取请求用于请求与所述第二套接字对应的所述待处理报文。S130. The socket unit 301 receives a message from the application unit 302 in the SN. And taking the request, the message obtaining request is used to request the to-be-processed message corresponding to the second socket.
本发明实施例中的所述报文获取请求可以直接携带所述报文获取请求,也可以不携带所述第二套接字,而是由套接字单元301从对应该第二套接字的专用接口接收所述报文获取请求。通过上述两种方式,套接字单元301都可以确定该请求与第二套接字的关系,即用于请求与所述第二套接字对应的所述待处理报文。The packet obtaining request in the embodiment of the present invention may directly carry the packet obtaining request, or may not carry the second socket, but the socket unit 301 corresponds to the second socket. The dedicated interface receives the message acquisition request. In the above two manners, the socket unit 301 can determine the relationship between the request and the second socket, that is, to request the to-be-processed message corresponding to the second socket.
S135、所述套接字单元301根据所述报文获取请求和所述对应关系确定所述待处理报文为被请求的报文。S135. The socket unit 301 determines, according to the packet obtaining request and the correspondence, that the to-be-processed packet is the requested packet.
所述套接字单元先根据所述报文获取请求确定所述第二套接字,然后再根据所述第二套接字,以及所述第二套接字和所述待处理报文的所述对应关系就可以确定第二套接字对应的待处理报文。由于所述待处理报文是保存在报文队列中的,因此所述第二套接字和所述待处理报文的所述对应关系也可以表现为所述第二套接字与所述报文队列标识的对应关系。相应地,就可以根据所述第二套接字和所述第二套接字与所述报文队列标识的对应关系来确定所述待处理报文。例如:根据第二套接字1就可以确定报文队列为Q1中的待处理报文为被请求报文。Determining, by the socket unit, the second socket according to the packet obtaining request, and then according to the second socket, the second socket, and the to-be-processed message. The corresponding relationship may determine a to-be-processed message corresponding to the second socket. The corresponding relationship between the second socket and the to-be-processed message may also be expressed as the second socket and the foregoing, because the to-be-processed message is saved in the message queue. Correspondence between packet queue identifiers. Correspondingly, the to-be-processed message may be determined according to the correspondence between the second socket and the second socket and the message queue identifier. For example, according to the second socket 1, it can be determined that the message queue is the pending message in Q1 as the requested message.
S140、所述套接字单元通过向所述应用程序单元发送针对所述报文获取请求的响应的方式,向所述应用程序单元发送所述待处理报文。S140. The socket unit sends the to-be-processed message to the application unit by sending a response to the message acquiring request to the application unit.
步骤S140的一种方案可以是:A solution of step S140 may be:
所述套接字单元向所述应用程序单元发送针对所述报文获取请求的响应,所述响应中携带所述待处理报文的存储地址;所述应用程序单元根据所述存储地址,获取所述待处理报文。这样,套接字单元和应用程序单元就不需要直接传输待处理数据,可以提高针对所述请求的响应速度。The socket unit sends a response to the message acquisition request to the application unit, where the response carries a storage address of the to-be-processed message; the application unit acquires according to the storage address. The to-be-processed message. In this way, the socket unit and the application unit do not need to directly transmit the data to be processed, and the response speed to the request can be improved.
步骤S140的另一种方案可以是:Another solution of step S140 may be:
所述套接字单元向所述应用程序单元发送针对所述报文获取请求的响应,所述响应中携带所述待处理报文。该种方案中,套接字单元可以在针对 所述请求的响应中直接携带所述待处理报文,就不需要应用程序单元再去查找该待处理报文。The socket unit sends a response to the message acquisition request to the application unit, where the response carries the to-be-processed message. In this scheme, the socket unit can be targeted The response to the request directly carries the to-be-processed message, and the application unit is not required to search for the to-be-processed message.
因为一个报文队列中可以有很多个待处理报文,所以在发送针对所述报文获取请求的响应时,可以是按照待处理报文存入报文队列的先后顺序,优先发送先进入队列的待处理报文的响应,直到该队列待处理报文发送完毕。Because there can be a large number of pending packets in a packet queue, when sending a response to the packet request, the packet may be sent to the queue first according to the order in which the packets are to be processed. The response of the pending message until the queue pending message is sent.
这个步骤参阅图1可以理解为是SRM所执行的过程。This step can be understood as a process performed by SRM with reference to FIG.
S145、应用程序单元302将所述待处理报文处理成已处理报文。S145. The application unit 302 processes the to-be-processed message into a processed message.
应用程序单元获取到待处理报文后,将该待处理报文处理成已处理报文。After the application unit obtains the to-be-processed message, the to-be-processed message is processed into the processed message.
S150、所述套接字单元301从所述应用程序单元302接收与所述第二套接字对应的已处理报文。S150. The socket unit 301 receives, from the application unit 302, a processed message corresponding to the second socket.
所述已处理报文是由所述应用程序单元302对所述待处理报文进行处理而得到的。The processed message is obtained by the application unit 302 processing the to-be-processed message.
所述套接字单元301从所述应用程序单元302接收与所述第二套接字对应的已处理报文的一种方案可以是:The solution that the socket unit 301 receives the processed message corresponding to the second socket from the application unit 302 may be:
套接字单元301从所述应用程序单元302接收包括所述已处理报文的存储地址以及第二套接字的报文或消息,还可以是接收包括已处理报文本身和第二套接字的报文或消息。由于所述已处理报文和所述第二套接字均被套接字单元301获得,因此套接字单元301可以确定所述已处理报文和所述第二套接字是相对应的。The socket unit 301 receives, from the application unit 302, a message or a message including the storage address of the processed message and the second socket, and may also receive the processed text body and the second socket. Word message or message. Since the processed message and the second socket are both obtained by the socket unit 301, the socket unit 301 can determine that the processed message and the second socket are corresponding. .
所述套接字单元301从所述应用程序单元302接收与所述第二套接字对应的已处理报文的另一种方案还可以是:套接字单元301从所述应用程序单元302之间的第二套接字专用接口接收所述已处理报文的存储地址或者已处理报文,并根据所述第二套接字的专用接口确定所述已处理报文是与所述第二套接子相对应的。Another scheme for the socket unit 301 to receive the processed message corresponding to the second socket from the application unit 302 may also be: the socket unit 301 from the application unit 302 a second socket-specific interface between the storage address of the processed message or the processed message, and determining, according to the dedicated interface of the second socket, that the processed message is the same as the first The two sets of connectors correspond to each other.
S155、所述套接字单元301根据与所述已处理报文相对应的所述第二套接字,确定所述业务路由信息。S155. The socket unit 301 determines the service routing information according to the second socket corresponding to the processed message.
如表1所示,当第二套接字确定后,就可以确定对应的业务路由信息, 如第二套接字为1时,则可以确定对应的业务路由信息为业务路由信息1。As shown in Table 1, when the second socket is determined, the corresponding service routing information can be determined. If the second socket is 1, the corresponding service routing information may be determined as the service routing information 1.
S160、套接字单元向业务路由器SR发送第二报文,所述第二报文为包括所述已处理报文的业务路由报文,所述第二报文的业务路由信息包括所述业务路由信息。S160. The socket unit sends a second packet to the service router SR, where the second packet is a service routing packet that includes the processed packet, and the service routing information of the second packet includes the service. Routing information.
套接字单元301可以使用步骤S155中确定的所述业务路由信息对已处理报文进行封装,也可以不进行封装,直接将所述已处理报文和所述业务路由信息发送给SR,但需要对所述已处理报文和所述业务路由信息分别进行标识,以使SR40能够分别识别出所述已处理报文和所述业务路由信息。The socket unit 301 may encapsulate the processed message by using the service routing information determined in step S155, or may directly send the processed message and the service routing information to the SR without encapsulation, but The processed message and the service routing information are separately identified, so that the SR 40 can separately identify the processed message and the service routing information.
需要说明的是,步骤S130至S140,与步骤S150至S160没有先后顺序,针对不同的业务路由报文可以步骤S130至S140与步骤S150至S160同时执行,也可以步骤S150至S160先执行。It should be noted that steps S130 to S140 have no sequence with steps S150 to S160. Steps S130 to S140 and steps S150 to S160 may be performed simultaneously for different service routing messages, or steps S150 to S160 may be performed first.
S170、套接字单元301接收所述应用程序单元302发送的第二套接字关闭指令。S170. The socket unit 301 receives the second socket close instruction sent by the application unit 302.
所述第二套接字关闭指令中可以携带第二套接字,也可以通过第二套接字的专用接口接收所述第二套接字关闭指令。The second socket closing instruction may carry the second socket, or may receive the second socket closing instruction through the dedicated interface of the second socket.
S175、套接字单元301根据所述第二套接字关闭指令,删除所述第一业务路由类型下的第二套接字、业务路由信息与报文队列的对应关系。S175. The socket unit 301 deletes the correspondence between the second socket, the service routing information, and the packet queue in the first service routing type according to the second socket closing instruction.
一个会话结束后,如果应用程序单元指示关闭本次会话,则可以删除表1或表2中与本次会话有关的表项。After a session ends, if the application unit instructs to close the session, the entries related to the session in Table 1 or Table 2 can be deleted.
S180、套接字单元301接收所述应用程序单元302发送的第一套接字关闭指令。S180. The socket unit 301 receives the first socket close instruction sent by the application unit 302.
所述第一套接字关闭指令中可以携带所述第一业务路由类型,也可以不携带该第一业务路由类型,而是通过第一套接字的专用接口接收该第二套接字关闭指令。The first socket close command may carry the first service route type, or may not carry the first service route type, but receive the second socket by using a dedicated interface of the first socket. instruction.
S185、根据所述第一套接字关闭指令,删除与所述第一业务路由类型下的第二套接字、业务路由信息与报文队列的对应关系。S185. The corresponding relationship between the second socket, the service routing information, and the packet queue in the first service routing type is deleted according to the first socket closing instruction.
如果应用程序单元指示关闭已经创建的业务路由socket,则删除表1或表 2中与该第一业务路由类型有关的表项。Delete Table 1 or Table if the application unit indicates to close the service routing socket that has been created The entry related to the first service route type in 2.
本实施例中的业务节点SN30和业务路由器SR可以是相互独立的两台物理设备,也可以是在同一个物理设备或物理系统中实现的两个虚拟设备。此外,随着技术的发展,业务节点和业务路由器的名称可能会发生变化。因此,只要当一个物理的或者虚拟的设备执行了本实施例中的业务节点SN30执行的操作,那么即使这个物理的或者虚拟的设备的名称并不是“业务节点”,它也应当被理解为是本发明实施例中的业务节点SN30。业务路由器的确定标准和业务节点30的标准相同,即只要一台设备执行了本实施例中业务路由器SR40所执行的操作,那么这台设备就应当被理解为业务路由器。一台目标设备是否能被理解为本实施例中的设备,与目标设备在行业中的名称无关,与目标设备执行的操作和具备的功能相关。The service node SN30 and the service router SR in this embodiment may be two physical devices that are independent of each other, or two virtual devices that are implemented in the same physical device or physical system. In addition, as technology evolves, the names of service nodes and service routers may change. Therefore, as long as a physical or virtual device performs the operations performed by the service node SN30 in this embodiment, even if the name of the physical or virtual device is not a "service node", it should be understood as The service node SN30 in the embodiment of the present invention. The determination criterion of the service router is the same as the standard of the service node 30, that is, as long as one device performs the operation performed by the service router SR40 in this embodiment, the device should be understood as a service router. Whether a target device can be understood as the device in this embodiment is independent of the name of the target device in the industry, and is related to the operations and functions performed by the target device.
与现有技术中业务路由的相关信息全部暴露给APP层,存在安全隐患相比,本发明实施例提供的对业务路由报文进行处理的方法,可以由业务节点SN中的套接字单元对业务路由报文进行业务路由信息的处理,SN中的应用程序单元不需要获知业务路由的相关信息,只对业务进行处理,从而避免业务路由的相关信息暴露给SN中的应用程序单元,提高了业务路由的安全性。The method for processing the service routing packet provided by the embodiment of the present invention may be performed by the socket unit pair in the service node SN, as compared with the information about the service routing in the prior art. The service routing message is processed by the service routing information, and the application unit in the SN does not need to know the relevant information of the service routing, and only processes the service, thereby preventing the related information of the service routing from being exposed to the application unit in the SN, thereby improving Security of service routing.
参阅图3,本发明实施例提供的一种对业务路由报文进行处理的方法的另一实施例包括:Referring to FIG. 3, another embodiment of a method for processing a service routing packet according to an embodiment of the present invention includes:
201、业务节点SN中的套接字单元创建第一套接字,所述第一套接字用于对第一报文进行监听,所述第一报文为属于第一业务路由类型的业务路由报文,所述第一报文包括业务路由信息和待处理报文。201. The socket unit in the service node SN creates a first socket, where the first socket is used to listen to the first packet, and the first packet is a service belonging to the first service routing type. The routing packet includes the service routing information and the to-be-processed packet.
202、所述套接字单元根据所述第一套接字确定所述SN接收到所述第一报文。202. The socket unit determines, according to the first socket, that the SN receives the first packet.
203、所述套接字单元保存所述待处理报文和第二套接字的对应关系,其中所述第二套接字与所述业务路由信息相对应。203. The socket unit saves a correspondence between the to-be-processed message and a second socket, where the second socket corresponds to the service routing information.
204、所述套接字单元从所述SN中的应用程序单元接收报文获取请求,所述报文获取请求用于请求与所述第二套接字对应的所述待处理报文。 204. The socket unit receives a message acquisition request from an application unit in the SN, where the message acquisition request is used to request the to-be-processed message corresponding to the second socket.
205、所述套接字单元根据所述报文获取请求和所述对应关系确定所述待处理报文为被请求的报文。205. The socket unit determines, according to the packet obtaining request and the correspondence, that the to-be-processed packet is the requested packet.
206、所述套接字单元通过向所述应用程序单元发送针对所述报文获取请求的响应的方式,向所述应用程序单元发送所述待处理报文。206. The socket unit sends the to-be-processed message to the application unit by sending a response to the message acquisition request to the application unit.
本发明实施例业务节点SN中的套接字单元创建第一套接字,所述第一套接字用于对第一报文进行监听,所述第一报文为属于第一业务路由类型的业务路由报文,所述第一报文包括业务路由信息和待处理报文;所述套接字单元根据所述第一套接字确定所述SN接收到所述第一报文;所述套接字单元保存所述待处理报文和第二套接字的对应关系,其中所述第二套接字与所述业务路由信息相对应;所述套接字单元从所述SN中的应用程序单元接收报文获取请求,所述报文获取请求用于请求与所述第二套接字对应的所述待处理报文;所述套接字单元根据所述报文获取请求和所述对应关系确定所述待处理报文为被请求的报文;所述套接字单元通过向所述应用程序单元发送针对所述报文获取请求的响应的方式,向所述应用程序单元发送所述待处理报文。与现有技术中业务路由的相关信息全部暴露给APP层,存在安全隐患相比,本发明实施例提供的对业务路由报文进行处理的方法,可以由业务节点SN中的套接字单元对业务路由报文进行业务路由信息的处理,SN中的应用程序单元不需要获知业务路由的相关信息,只对业务进行处理,从而避免业务路由的相关信息暴露给SN中的应用程序单元,提高了业务路由的安全性。In the embodiment of the present invention, the socket unit in the service node SN creates a first socket, and the first socket is used to listen to the first packet, where the first packet belongs to the first service routing type. The service routing message, the first packet includes service routing information and a to-be-processed message; the socket unit determines, according to the first socket, that the SN receives the first packet; The socket unit saves a correspondence between the to-be-processed message and the second socket, where the second socket corresponds to the service routing information; the socket unit is from the SN The application unit receives a message acquisition request, and the message acquisition request is used to request the to-be-processed message corresponding to the second socket; the socket unit acquires a request according to the message and Determining, by the correspondence, the to-be-processed message is a requested message; the socket unit sends the response to the message acquisition request to the application unit to the application unit Send the to-be-processed message. The method for processing the service routing packet provided by the embodiment of the present invention may be performed by the socket unit pair in the service node SN, as compared with the information about the service routing in the prior art. The service routing message is processed by the service routing information, and the application unit in the SN does not need to know the relevant information of the service routing, and only processes the service, thereby preventing the related information of the service routing from being exposed to the application unit in the SN, thereby improving Security of service routing.
可选地,在上述图3对应的实施例的基础上,本发明实施例提供的对业务路由报文进行处理的方法的另一实施例中,所述方法还可以包括:Optionally, in another embodiment of the method for processing a service routing packet according to the embodiment of the present disclosure, the method may further include:
所述套接字单元从所述应用程序单元接收与所述第二套接字对应的已处理报文,所述已处理报文是由所述应用程序单元对所述待处理报文进行处理而得到的;Receiving, by the application unit, a processed message corresponding to the second socket, where the processed message is processed by the application unit to process the to-be-processed message Obtained
所述套接字单元根据与所述已处理报文相对应的所述第二套接字,确定所述业务路由信息;The socket unit determines the service routing information according to the second socket corresponding to the processed message;
向业务路由器SR发送第二报文,所述第二报文为包括所述已处理报文的 业务路由报文,所述第二报文的业务路由信息包括所述业务路由信息。Sending a second packet to the service router SR, where the second packet is the packet that includes the processed packet The service routing message, where the service routing information of the second packet includes the service routing information.
可选地,在上述图3对应的实施例或可选实施例的基础上,本发明实施例提供的报文处理的方法的另一实施例中,所述套接字单元保存所述待处理报文和所述第二套接字的对应关系具体可以包括:Optionally, in another embodiment of the packet processing method provided by the embodiment of the present invention, the socket unit saves the to-be-processed on the basis of the foregoing embodiment or the optional embodiment of FIG. The correspondence between the packet and the second socket may specifically include:
所述套接字单元在接收到所述第一报文时,如果所述套接字单元中未保存所述第二套接字,则创建所述第二套接字,并将所述待处理报文添加至与所述第二套接字对应的报文队列中。When the socket unit receives the first packet, if the second socket is not saved in the socket unit, the second socket is created, and the The processing message is added to the message queue corresponding to the second socket.
可选地,在上述图3对应的实施例或可选实施例的基础上,本发明实施例提供的报文处理的方法的另一实施例中,所述套接字单元保存所述待处理报文和所述第二套接字的对应关系具体可以包括:Optionally, in another embodiment of the packet processing method provided by the embodiment of the present invention, the socket unit saves the to-be-processed on the basis of the foregoing embodiment or the optional embodiment of FIG. The correspondence between the packet and the second socket may specifically include:
所述套接字单元在接收到所述第一报文时,如果所述套接字单元中保存有所述第二套接字,则将所述待处理报文添加至与所述第二套接字对应的报文队列中。When the socket unit receives the first packet, if the second socket is saved in the socket unit, the to-be-processed message is added to the second The queue corresponding to the socket in the message.
可选地,在上述图3对应的实施例或可选实施例的基础上,本发明实施例提供的报文处理的方法的另一实施例中,所述套接字单元从所述SN中的应用程序单元接收包括所述第二套接字的报文获取请求之前,所述方法还可以包括:Optionally, in another embodiment of the packet processing method provided by the embodiment of the present invention, the socket unit is from the SN, according to the foregoing embodiment or the optional embodiment of FIG. The method may further include: before the application unit receives the message acquisition request including the second socket, the method may further include:
所述套接字单元向所述应用程序单元发送所述第二套接字。The socket unit sends the second socket to the application unit.
可选地,在上述图3对应的实施例或可选实施例的基础上,本发明实施例提供的报文处理的方法的另一实施例中,所述套接字单元通过向所述应用程序单元发送针对所述报文获取请求的响应的方式,向所述应用程序单元发送所述待处理报文,可以包括:Optionally, in another embodiment of the method for processing a packet according to the embodiment of the present invention, the socket unit is configured to be applied to the application, according to the foregoing embodiment or the optional embodiment. And sending, by the program unit, the to-be-processed message to the application unit, where the program unit sends the response to the message requesting request, which may include:
所述套接字单元向所述应用程序单元发送针对所述报文获取请求的响应,所述响应中携带所述待处理报文的存储地址;The socket unit sends a response to the message acquisition request to the application unit, where the response carries a storage address of the to-be-processed message;
所述应用程序单元根据所述存储地址,获取所述待处理报文。The application unit acquires the to-be-processed message according to the storage address.
可选地,在上述图3对应的实施例或可选实施例的基础上,本发明实施例提供的报文处理的方法的另一实施例中,所述套接字单元通过向所述应用 程序单元发送针对所述报文获取请求的响应的方式,向所述应用程序单元发送所述待处理报文,可以包括:Optionally, in another embodiment of the method for processing a packet according to the embodiment of the present invention, the socket unit is configured to be applied to the application, according to the foregoing embodiment or the optional embodiment. And sending, by the program unit, the to-be-processed message to the application unit, where the program unit sends the response to the message requesting request, which may include:
所述套接字单元向所述应用程序单元发送针对所述报文获取请求的响应,所述响应中携带所述待处理报文。The socket unit sends a response to the message acquisition request to the application unit, where the response carries the to-be-processed message.
本发明实施例所描述的对业务路由报文进行处理的方法,可以参阅图1和图2部分的描述进行理解,本发明实施例中不做过多赘述。The method for processing the service routing message described in the embodiment of the present invention can be understood by referring to the description in the parts of FIG. 1 and FIG. 2, and details are not described in the embodiment of the present invention.
图4所示为本发明实施例提供的业务节点SN30的示意图。图4所示的业务节点SN30即为图1和图2所示的业务节点SN30,也可以为与图3对应的实施例中的业务节点。该示意图中的各个单元和子单元可以被理解为是根据逻辑功能的不同来划分的逻辑单元。业务节点SN30包括套接字单元301和应用程序单元302。FIG. 4 is a schematic diagram of a service node SN30 according to an embodiment of the present invention. The service node SN30 shown in FIG. 4 is the service node SN30 shown in FIG. 1 and FIG. 2, and may also be the service node in the embodiment corresponding to FIG. 3. Individual units and subunits in the schematic diagram can be understood as logical units that are divided according to different logical functions. The service node SN30 includes a socket unit 301 and an application unit 302.
所述套接字单元301包括:The socket unit 301 includes:
创建子单元3011,用于创建第一套接字,所述第一套接字用于对第一报文进行监听,所述第一报文为属于第一业务路由类型的业务路由报文,所述第一报文包括业务路由信息和待处理报文,所述第一报文可以是由业务路由器SR40发送至业务节点SN30的,业务节点SN30和业务路由器SN40属于同一个系统;The sub-unit 3011 is configured to create a first socket, where the first packet is used to monitor the first packet, and the first packet is a service routing packet belonging to the first service routing type. The first packet includes the service routing information and the to-be-processed packet, and the first packet may be sent by the service router SR40 to the service node SN30, and the service node SN30 and the service router SN40 belong to the same system;
确定子单元3012,用于根据所述创建子单元3011创建的所述第一套接字确定所述SN接收到所述第一报文;a determining subunit 3012, configured to determine, according to the first socket created by the creating subunit 3011, that the SN receives the first packet;
保存子单元3013,用于保存所述待处理报文和第二套接字的对应关系,其中所述第二套接字与所述业务路由信息相对应;a saving subunit 3013, configured to save a correspondence between the to-be-processed message and the second socket, where the second socket corresponds to the service routing information;
接收子单元3014,用于从所述SN中的应用程序单元302接收报文获取请求,所述报文获取请求用于请求与所述第二套接字对应的所述待处理报文;The receiving subunit 3014 is configured to receive a message obtaining request from the application unit 302 in the SN, where the message obtaining request is used to request the to-be-processed message corresponding to the second socket;
所述确定子单元3012,还用于根据所述接收子单元3014接收的所述报文获取请求和所述保存子单元保存的所述对应关系确定所述待处理报文为被请求的报文;The determining subunit 3012 is further configured to determine, according to the packet obtaining request received by the receiving subunit 3014 and the corresponding relationship saved by the saving subunit, that the to-be-processed packet is the requested packet. ;
发送子单元3015,用于通过向所述应用程序单元302发送针对所述报文 获取请求的响应的方式,向所述应用程序单元发送所述确定子单元确定的所述待处理报文。a sending subunit 3015, configured to send, by using the application unit 302, the message And obtaining, by the application unit, the to-be-processed message determined by the determining subunit.
以上内容可以被理解为图4所示的SN30的第一部分内容。The above can be understood as the first part of the SN 30 shown in FIG.
根据上述内容可知,与现有技术中业务路由的相关信息全部暴露给APP层,存在安全隐患相比,本发明实施例提供业务节点SN可以由套接字单元对业务路由报文进行业务路由信息的处理,SN中的应用程序单元不需要获知业务路由的相关信息,只对业务进行处理,从而避免业务路由的相关信息暴露给SN中的应用程序单元,提高了业务路由的安全性。According to the above, the information about the service routing in the prior art is all exposed to the APP layer, and the service node SN can provide the service routing information of the service routing message by the socket unit. The processing unit of the SN does not need to know the information about the service route, and only processes the service, so as to prevent the related information of the service route from being exposed to the application unit in the SN, thereby improving the security of the service route.
本实施例可以进一步包括第一可选方案,所述第一可选方案包括所述SN30的第一部分内容。此外,在第一可选方案中,所述接收子单元3014还用于从所述应用程序单元302接收与所述第二套接字对应的已处理报文,所述已处理报文是由所述应用程序单元对所述待处理报文进行处理而得到的;所述确定子单元3012还用于根据与所述接收子单元3014接收的所述已处理报文相对应的所述第二套接字,确定所述业务路由信息;所述发送子单元3015还用于向业务路由器SR发送第二报文,所述第二报文为包括所述已处理报文的业务路由报文,所述第二报文的业务路由信息包括所述确定子单元3012确定的所述业务路由信息。The embodiment may further include a first alternative, the first alternative comprising the first part of the content of the SN 30. In addition, in a first alternative, the receiving subunit 3014 is further configured to receive, from the application unit 302, a processed message corresponding to the second socket, where the processed message is The application unit is configured to process the to-be-processed message; the determining sub-unit 3012 is further configured to use the second corresponding to the processed message received by the receiving sub-unit 3014 a socket, the service routing information is determined; the sending sub-unit 3015 is further configured to send a second packet to the service router SR, where the second packet is a service routing packet that includes the processed packet, The service routing information of the second packet includes the service routing information determined by the determining subunit 3012.
本实施例可以进一步包括第二可选方案,所述第二可选方案包括所述SN30的第一部分内容或所述第一可选方案。此外,在第二可选方案中,所述创建子单元3011还用于在所述接收子单元3014接收到所述第一报文时,如果所述保存子单元3013中未保存所述第二套接字,则创建所述第二套接字;所述保存子单元3013具体用于将所述待处理报文添加至与所述创建子单元3011创建的所述第二套接字对应的报文队列中。This embodiment may further include a second alternative, the second alternative comprising the first part of the content of the SN 30 or the first alternative. In addition, in the second implementation, the creating subunit 3011 is further configured to: when the receiving subunit 3014 receives the first packet, if the saving subunit 3013 does not save the second a socket, the second socket is created; the saving sub-unit 3013 is specifically configured to add the to-be-processed message to the second socket created by the creating sub-unit 3011. In the message queue.
本实施例可以进一步包括第三可选方案,所述第三可选方案包括所述SN30的第一部分内容、所述第一可选方案或所述第二可选方案。此外,在第三可选方案中,所述保存子单元3013,具体用于在所述接收子单元3014接收到所述第一报文时,如果所述保存子单元3013中保存有所述第二套接字,则 将所述待处理报文添加至与所述第二套接字对应的报文队列中。The embodiment may further include a third optional solution, where the third optional solution includes the first part of the content of the SN 30, the first option, or the second option. In addition, in a third alternative, the saving subunit 3013 is specifically configured to: when the receiving subunit 3014 receives the first packet, if the saving subunit 3013 holds the first Two sockets, then Adding the to-be-processed message to a message queue corresponding to the second socket.
本实施例可以进一步包括第四可选方案,所述第四可选方案包括所述SN30的第一部分内容、所述第一可选方案、所述第二可选方案或所述第三可选方案。此外,在第四可选方案中,所述发送子单元3015还用于从所述SN中的应用程序单元302接收包括所述第二套接字的报文获取请求之前,向所述应用程序单元发送所述第二套接字。The embodiment may further include a fourth optional solution, where the fourth optional solution includes the first part content of the SN 30, the first optional solution, the second optional solution, or the third optional Program. In addition, in a fourth implementation, the sending subunit 3015 is further configured to: before receiving, by the application unit 302 in the SN, the packet obtaining request including the second socket, to the application The unit transmits the second socket.
本实施例可以进一步包括第五可选方案,所述第五可选方案包括所述SN30的第一部分内容、所述第一可选方案、所述第二可选方案、所述第三可选方案或所述第四可选方案。此外,在第五可选方案中,所述发送子单元3015用于向所述应用程序单元发送针对所述报文获取请求的响应,所述响应中携带所述待处理报文的存储地址;所述应用程序单元302,用于根据所述存储地址,获取所述待处理报文。The embodiment may further include a fifth optional solution, where the fifth optional solution includes the first part content of the SN 30, the first optional solution, the second optional solution, and the third optional Scheme or the fourth alternative. In addition, in a fifth alternative, the sending sub-unit 3015 is configured to send, to the application unit, a response to the message acquiring request, where the response carries a storage address of the to-be-processed message; The application unit 302 is configured to acquire the to-be-processed message according to the storage address.
基于上述SN30的第一部分内容或任意一种可选方案,所述发送子单元3015用于向所述应用程序单元302发送针对所述报文获取请求的响应,所述响应中携带所述待处理报文。The sending subunit 3015 is configured to send a response to the packet acquiring request to the application unit 302, where the response carries the to-be-processed, based on the foregoing part of the content of the SN 30 or any optional solution. Message.
本发明实施例所描述的业务节点,可以参阅图1和图2部分的描述进行理解,本发明实施例中不做过多赘述。The service node described in the embodiment of the present invention can be understood by referring to the description in the parts of FIG. 1 and FIG. 2, and details are not described in the embodiment of the present invention.
需要说明的是,图4所示的业务节点30能够实现图1、图2所示的业务节点30以及与图3对应的实施例中的业务节点的全部操作和功能。由于图4是从逻辑功能的角度来体现一个业务节点的,因此所述全部操作和功能可以图4所示的各个单元和子单元共同实现。至于所述全部操作和功能具体由哪个单元和子单元分别实现,这仅是逻辑上的划分,即把业务节点30在与图1、图2或图3中执行到操作划分或补充到一个逻辑单元中,其划分方法非常灵活。在任何一种划分方式都应当被视为是本实施例的一部分。It should be noted that the service node 30 shown in FIG. 4 can implement all the operations and functions of the service node 30 shown in FIG. 1 and FIG. 2 and the service node in the embodiment corresponding to FIG. 3. Since FIG. 4 embodies a service node from the perspective of logical functions, all of the operations and functions can be implemented by the respective units and sub-units shown in FIG. As to which unit and sub-unit are implemented by the whole operation and function respectively, this is only a logical division, that is, the service node 30 is divided into operations or added to a logical unit in FIG. 1, FIG. 2 or FIG. The method of division is very flexible. Any of the divisions should be considered as part of this embodiment.
图5是业务节点30的结构示意图。业务节点30可包括输入设备310、输出设备320、处理器330和存储器340。图5所示的业务节点30和图4所示的业务节点30可以是相同的业务节点,但是图4是从逻辑功能的角度来体现 这个业务节点,而图5是从物理实现的角度来体现这个业务节点。FIG. 5 is a schematic structural diagram of the service node 30. The service node 30 can include an input device 310, an output device 320, a processor 330, and a memory 340. The service node 30 shown in FIG. 5 and the service node 30 shown in FIG. 4 may be the same service node, but FIG. 4 is embodied from the perspective of logical functions. This service node, and Figure 5 shows this service node from a physical implementation perspective.
存储器340可以包括只读存储器和/或随机存取存储器,并向处理器330提供指令和数据。存储器340的一部分还可以包括非易失性随机存取存储器(NVRAM)。Memory 340 can include read only memory and/or random access memory and provides instructions and data to processor 330. A portion of the memory 340 may also include non-volatile random access memory (NVRAM).
存储器340存储了如下的元素,可执行模块或者数据结构,或者它们的子集,或者它们的扩展集:The memory 340 stores the following elements, executable modules or data structures, or a subset thereof, or an extended set thereof:
操作指令:包括各种操作指令,用于实现各种操作。Operation instructions: include various operation instructions for implementing various operations.
操作系统:包括各种系统程序,用于实现各种基础业务以及处理基于硬件的任务。Operating system: Includes a variety of system programs for implementing various basic services and handling hardware-based tasks.
在本发明实施例中,处理器330通过调用存储器340存储的操作指令(该操作指令可存储在操作系统中),执行如下操作:In the embodiment of the present invention, the processor 330 performs the following operations by calling an operation instruction stored in the memory 340, which can be stored in the operating system:
创建第一套接字,所述第一套接字用于对第一报文进行监听,所述第一报文为属于第一业务路由类型的业务路由报文,所述第一报文包括业务路由信息和待处理报文;Creating a first socket, where the first packet is used to monitor the first packet, and the first packet is a service routing packet belonging to the first service routing type, where the first packet includes Service routing information and pending messages;
根据所述第一套接字确定所述SN接收到所述第一报文;Determining, according to the first socket, that the SN receives the first packet;
通过存储器340保存所述待处理报文和第二套接字的对应关系,其中所述第二套接字与所述业务路由信息相对应;Saving a correspondence between the to-be-processed message and the second socket by using a memory 340, where the second socket corresponds to the service routing information;
通过输入设备310从所述SN中的应用程序单元接收报文获取请求,所述报文获取请求用于请求与所述第二套接字对应的所述待处理报文;Receiving, by the input device 310, a message acquisition request from an application unit in the SN, where the message acquisition request is used to request the to-be-processed message corresponding to the second socket;
所述套接字单元根据所述报文获取请求和所述对应关系确定所述待处理报文为被请求的报文;Determining, by the socket unit, the to-be-processed message as the requested message according to the packet obtaining request and the corresponding relationship;
通过输出设备320向所述应用程序单元发送针对所述报文获取请求的响应的方式,向所述应用程序单元发送所述待处理报文。Transmitting the to-be-processed message to the application unit by the output device 320 transmitting a response to the message acquisition request to the application unit.
本发明实施例提供的业务节点SN中的套接字单元对业务路由报文进行业务路由信息的处理,SN中的应用程序单元不需要获知业务路由的相关信息,只对业务进行处理,从而避免业务路由的相关信息暴露给SN中的应用程序单元,提高了业务路由的安全性。 The socket unit in the service node SN provides the service routing information processing on the service routing packet, and the application unit in the SN does not need to know the related information of the service routing, and only processes the service, thereby avoiding The information about the service route is exposed to the application unit in the SN, which improves the security of the service route.
处理器330控制业务节点SN30的操作,处理器330还可以称为CPU(Central Processing Unit,中央处理单元)。存储器340可以包括只读存储器和随机存取存储器,并向处理器330提供指令和数据。存储器340的一部分还可以包括非易失性随机存取存储器(NVRAM)。具体的应用中,业务节点SN30的各个组件通过总线系统350耦合在一起,其中总线系统350除包括数据总线之外,还可以包括电源总线、控制总线和状态信号总线等。但是为了清楚说明起见,在图中将各种总线都标为总线系统350。The processor 330 controls the operation of the service node SN30, which may also be referred to as a CPU (Central Processing Unit). Memory 340 can include read only memory and random access memory and provides instructions and data to processor 330. A portion of the memory 340 may also include non-volatile random access memory (NVRAM). In a specific application, the components of the service node SN30 are coupled together by a bus system 350. The bus system 350 may include a power bus, a control bus, a status signal bus, and the like in addition to the data bus. However, for clarity of description, various buses are labeled as bus system 350 in the figure.
上述本发明实施例揭示的方法可以应用于处理器330中,或者由处理器330实现。处理器330可能是一种集成电路芯片,具有信号的处理能力。在实现过程中,上述方法的各步骤可以通过处理器330中的硬件的集成逻辑电路或者软件形式的指令完成。上述的处理器330可以是通用处理器、数字信号处理器(DSP)、专用集成电路(ASIC)、现成可编程门阵列(FPGA)或者其他可编程逻辑器件、分立门或者晶体管逻辑器件、分立硬件组件。可以实现或者执行本发明实施例中的公开的各方法、步骤及逻辑框图。通用处理器可以是微处理器或者该处理器也可以是任何常规的处理器等。结合本发明实施例所公开的方法的步骤可以直接体现为硬件译码处理器执行完成,或者用译码处理器中的硬件及软件模块组合执行完成。软件模块可以位于随机存储器,闪存、只读存储器,可编程只读存储器或者电可擦写可编程存储器、寄存器等本领域成熟的存储介质中。该存储介质位于存储器340,处理器330读取存储器340中的信息,结合其硬件完成上述方法的步骤。The method disclosed in the foregoing embodiments of the present invention may be applied to the processor 330 or implemented by the processor 330. Processor 330 may be an integrated circuit chip with signal processing capabilities. In the implementation process, each step of the foregoing method may be completed by an integrated logic circuit of hardware in the processor 330 or an instruction in a form of software. The processor 330 described above may be a general purpose processor, a digital signal processor (DSP), an application specific integrated circuit (ASIC), an off-the-shelf programmable gate array (FPGA) or other programmable logic device, a discrete gate or transistor logic device, or discrete hardware. Component. The methods, steps, and logical block diagrams disclosed in the embodiments of the present invention may be implemented or carried out. The general purpose processor may be a microprocessor or the processor or any conventional processor or the like. The steps of the method disclosed in the embodiments of the present invention may be directly implemented by the hardware decoding processor, or may be performed by a combination of hardware and software modules in the decoding processor. The software module can be located in a conventional storage medium such as random access memory, flash memory, read only memory, programmable read only memory or electrically erasable programmable memory, registers, and the like. The storage medium is located in memory 340, and processor 330 reads the information in memory 340 and, in conjunction with its hardware, performs the steps of the above method.
可选地,所述输入设备310还用于从所述应用程序单元接收与所述第二套接字对应的已处理报文,所述已处理报文是由所述应用程序单元对所述待处理报文进行处理而得到的;Optionally, the input device 310 is further configured to receive, from the application unit, a processed message corresponding to the second socket, where the processed message is configured by the application unit The processed message is processed;
所述处理器330还用于根据与所述已处理报文相对应的所述第二套接字,确定所述业务路由信息;The processor 330 is further configured to determine the service routing information according to the second socket corresponding to the processed message;
所述输出设备320还用于向业务路由器SR发送第二报文,所述第二报文为包括所述已处理报文的业务路由报文,所述第二报文的业务路由信息包括 所述业务路由信息。The output device 320 is further configured to send a second packet to the service router SR, where the second packet is a service routing packet that includes the processed packet, and the service routing information of the second packet includes The service routing information.
可选地,所述处理器具体用于在所述套接字单元在接收到所述第一报文时,如果所述套接字单元中未保存所述第二套接字,则创建所述第二套接字;Optionally, the processor is specifically configured to: when the socket unit receives the first packet, if the second socket is not saved in the socket unit, create a Said second socket;
所述存储器340具体用于将所述待处理报文添加至与所述第二套接字对应的报文队列中。The memory 340 is specifically configured to add the to-be-processed message to a message queue corresponding to the second socket.
可选地,所述存储器340具体用于在所述套接字单元在接收到所述第一报文时,如果所述套接字单元中保存有所述第二套接字,则将所述待处理报文添加至与所述第二套接字对应的报文队列中。Optionally, the memory 340 is specifically configured to: when the socket unit receives the first packet, if the second socket is saved in the socket unit, The pending processing message is added to the message queue corresponding to the second socket.
可选地,所述输出设备320用于向所述应用程序单元发送所述第二套接字。Optionally, the output device 320 is configured to send the second socket to the application unit.
可选地,所述输出设备320具体用于所述套接字单元向所述应用程序单元发送针对所述报文获取请求的响应,所述响应中携带所述待处理报文的存储地址;Optionally, the output device 320 is specifically configured to send, by the socket unit, a response to the message acquiring request to the application unit, where the response carries a storage address of the to-be-processed message;
所述应用程序单元根据所述存储地址,获取所述待处理报文。The application unit acquires the to-be-processed message according to the storage address.
可选地,所述输出设备320具体用于向所述应用程序单元发送针对所述报文获取请求的响应,所述响应中携带所述待处理报文。Optionally, the output device 320 is specifically configured to send, to the application unit, a response to the message acquisition request, where the response carries the to-be-processed message.
此外,图4所示的业务节点30中的套接字单元301和应用程序单元302可是被认为是由处理器330根据存储器340中保存的可读指令和需要被使用的数据来实现的。存储器340中可以保存实现套接字单元301和应用程序单元302所需的全部指令和数据。处理读取相应的指令,按照指令进行操作,从而实现套接字单元301和应用程序单元302。Moreover, the socket unit 301 and application unit 302 in the service node 30 shown in FIG. 4 can be implemented as being implemented by the processor 330 based on readable instructions stored in the memory 340 and data that needs to be used. All of the instructions and data needed to implement the socket unit 301 and the application unit 302 can be stored in the memory 340. The processing reads the corresponding instruction and operates in accordance with the instruction, thereby implementing the socket unit 301 and the application unit 302.
本领域普通技术人员可以理解上述实施例的各种方法中的全部或部分步骤是可以通过程序来指令相关的硬件来完成,该程序可以存储于一计算机可读存储介质中,存储介质可以包括:ROM、RAM、磁盘或光盘等。A person skilled in the art may understand that all or part of the various steps of the foregoing embodiments may be performed by a program to instruct related hardware. The program may be stored in a computer readable storage medium, and the storage medium may include: ROM, RAM, disk or CD.
以上对本发明实施例所提供的对业务路由报文进行处理的方法和业务节点进行了详细介绍,本文中应用了具体个例对本发明的原理及实施方式进行了阐述,以上实施例的说明只是用于帮助理解本发明的方法及其核心思想; 同时,对于本领域的一般技术人员,依据本发明的思想,在具体实施方式及应用范围上均会有改变之处,综上所述,本说明书内容不应理解为对本发明的限制。 The method and the service node for processing the service routing message provided by the embodiment of the present invention are described in detail. The principle and the implementation manner of the present invention are described in the following. The description of the above embodiment is only used. To help understand the method of the present invention and its core ideas; In the meantime, the present invention is not limited by the scope of the present invention.

Claims (14)

  1. 一种对业务路由报文进行处理的方法,其特征在于,包括:A method for processing a service routing packet, which is characterized by:
    业务节点SN中的套接字单元创建第一套接字,所述第一套接字用于对第一报文进行监听,所述第一报文为属于第一业务路由类型的业务路由报文,所述第一报文包括业务路由信息和待处理报文;The socket unit in the service node SN creates a first socket, and the first socket is used to listen to the first packet, where the first packet is a service routing report belonging to the first service routing type. The first packet includes the service routing information and the to-be-processed packet.
    所述套接字单元根据所述第一套接字确定所述SN接收到所述第一报文;Determining, by the socket unit, that the SN receives the first packet according to the first socket;
    所述套接字单元保存所述待处理报文和第二套接字的对应关系,其中所述第二套接字与所述业务路由信息相对应;The socket unit stores a correspondence between the to-be-processed message and the second socket, where the second socket corresponds to the service routing information;
    所述套接字单元从所述SN中的应用程序单元接收报文获取请求,所述报文获取请求用于请求与所述第二套接字对应的所述待处理报文;The socket unit receives a message acquisition request from an application unit in the SN, where the message acquisition request is used to request the to-be-processed message corresponding to the second socket;
    所述套接字单元根据所述报文获取请求和所述对应关系确定所述待处理报文为被请求的报文;Determining, by the socket unit, the to-be-processed message as the requested message according to the packet obtaining request and the corresponding relationship;
    所述套接字单元通过向所述应用程序单元发送针对所述报文获取请求的响应的方式,向所述应用程序单元发送所述待处理报文。The socket unit sends the to-be-processed message to the application unit by sending a response to the message acquisition request to the application unit.
  2. 根据权利要求1所述的方法,其特征在于,所述方法还包括:The method of claim 1 further comprising:
    所述套接字单元从所述应用程序单元接收与所述第二套接字对应的已处理报文,所述已处理报文是由所述应用程序单元对所述待处理报文进行处理而得到的;Receiving, by the application unit, a processed message corresponding to the second socket, where the processed message is processed by the application unit to process the to-be-processed message Obtained
    所述套接字单元根据与所述已处理报文相对应的所述第二套接字,确定所述业务路由信息;The socket unit determines the service routing information according to the second socket corresponding to the processed message;
    向业务路由器SR发送第二报文,所述第二报文为包括所述已处理报文的业务路由报文,所述第二报文的业务路由信息包括所述业务路由信息。Sending a second packet to the service router SR, where the second packet is a service routing packet that includes the processed packet, and the service routing information of the second packet includes the service routing information.
  3. 根据权利要求1或2所述的方法,其特征在于,所述套接字单元保存所述待处理报文和所述第二套接字的对应关系具体包括:The method according to claim 1 or 2, wherein the storing the correspondence between the to-be-processed message and the second socket comprises:
    所述套接字单元在接收到所述第一报文时,如果所述套接字单元中未保存所述第二套接字,则创建所述第二套接字,并将所述待处理报文添加至与 所述第二套接字对应的报文队列中。When the socket unit receives the first packet, if the second socket is not saved in the socket unit, the second socket is created, and the Processing messages added to and The packet queue corresponding to the second socket.
  4. 根据权利要求1或2所述的方法,其特征在于,所述套接字单元保存所述待处理报文和所述第二套接字的对应关系具体包括:The method according to claim 1 or 2, wherein the storing the correspondence between the to-be-processed message and the second socket comprises:
    所述套接字单元在接收到所述第一报文时,如果所述套接字单元中保存有所述第二套接字,则将所述待处理报文添加至与所述第二套接字对应的报文队列中。When the socket unit receives the first packet, if the second socket is saved in the socket unit, the to-be-processed message is added to the second The queue corresponding to the socket in the message.
  5. 根据权利要求1至4中任一项所述的方法,其特征在于,所述套接字单元从所述SN中的应用程序单元接收包括所述第二套接字的报文获取请求之前,所述方法还包括:The method according to any one of claims 1 to 4, wherein the socket unit receives a message acquisition request including the second socket from an application unit in the SN, The method further includes:
    所述套接字单元向所述应用程序单元发送所述第二套接字。The socket unit sends the second socket to the application unit.
  6. 根据权利要求1至5中任一项所述的方法,其特征在于,所述套接字单元通过向所述应用程序单元发送针对所述报文获取请求的响应的方式,向所述应用程序单元发送所述待处理报文,包括:The method according to any one of claims 1 to 5, wherein the socket unit is to the application by transmitting a response to the message acquisition request to the application unit The unit sends the to-be-processed message, including:
    所述套接字单元向所述应用程序单元发送针对所述报文获取请求的响应,所述响应中携带所述待处理报文的存储地址;The socket unit sends a response to the message acquisition request to the application unit, where the response carries a storage address of the to-be-processed message;
    所述应用程序单元根据所述存储地址,获取所述待处理报文。The application unit acquires the to-be-processed message according to the storage address.
  7. 根据权利要求1至6中任一项所述的方法,其特征在于,所述套接字单元通过向所述应用程序单元发送针对所述报文获取请求的响应的方式,向所述应用程序单元发送所述待处理报文,包括:The method according to any one of claims 1 to 6, wherein the socket unit is to the application by transmitting a response to the message acquisition request to the application unit The unit sends the to-be-processed message, including:
    所述套接字单元向所述应用程序单元发送针对所述报文获取请求的响应,所述响应中携带所述待处理报文。The socket unit sends a response to the message acquisition request to the application unit, where the response carries the to-be-processed message.
  8. 一种业务节点,其特征在于,包括:套接字单元和应用程序单元;A service node, comprising: a socket unit and an application unit;
    所述套接字单元包括:The socket unit includes:
    创建子单元,用于创建第一套接字,所述第一套接字用于对第一报文进行监听,所述第一报文为属于第一业务路由类型的业务路由报文,所述第一报文包括业务路由信息和待处理报文;Creating a sub-unit, configured to create a first socket, where the first packet is used to listen to the first packet, where the first packet is a service routing packet belonging to the first service routing type. The first packet includes service routing information and pending packets;
    确定子单元,用于根据所述创建子单元创建的所述第一套接字确定所述 SN接收到所述第一报文;Determining a subunit, configured to determine, according to the first socket created by the creating subunit Receiving, by the SN, the first packet;
    保存子单元,用于保存所述待处理报文和第二套接字的对应关系,其中所述第二套接字与所述业务路由信息相对应;a saving subunit, configured to save a correspondence between the to-be-processed message and the second socket, where the second socket corresponds to the service routing information;
    接收子单元,用于从所述SN中的应用程序单元接收报文获取请求,所述报文获取请求用于请求与所述第二套接字对应的所述待处理报文;a receiving subunit, configured to receive a message obtaining request from an application unit in the SN, where the message obtaining request is used to request the to-be-processed message corresponding to the second socket;
    所述确定子单元,还用于根据所述接收子单元接收的所述报文获取请求和所述保存子单元保存的所述对应关系确定所述待处理报文为被请求的报文;The determining subunit is further configured to determine, according to the packet obtaining request that is received by the receiving subunit and the corresponding relationship that is saved by the saving subunit, that the to-be-processed packet is the requested packet;
    发送子单元,用于通过向所述应用程序单元发送针对所述报文获取请求的响应的方式,向所述应用程序单元发送所述确定子单元确定的所述待处理报文。And a sending subunit, configured to send the to-be-processed message determined by the determining subunit to the application unit by sending a response to the packet request to the application unit.
  9. 根据权利要求8所述的业务节点,The service node according to claim 8
    所述接收子单元,还用于从所述应用程序单元接收与所述第二套接字对应的已处理报文,所述已处理报文是由所述应用程序单元对所述待处理报文进行处理而得到的;The receiving subunit is further configured to receive, from the application unit, a processed message corresponding to the second socket, where the processed message is sent by the application unit to the to-be-processed message Obtained by processing the text;
    所述确定子单元,还用于根据与所述接收子单元接收的所述已处理报文相对应的所述第二套接字,确定所述业务路由信息;The determining subunit is further configured to determine the service routing information according to the second socket corresponding to the processed message received by the receiving subunit;
    所述发送子单元,还用于向业务路由器SR发送第二报文,所述第二报文为包括所述已处理报文的业务路由报文,所述第二报文的业务路由信息包括所述确定子单元确定的所述业务路由信息。The sending subunit is further configured to send a second packet to the service router SR, where the second packet is a service routing packet that includes the processed packet, and the service routing information of the second packet includes Determining the service routing information determined by the subunit.
  10. 根据权利要求8或9所述的业务节点,A service node according to claim 8 or 9,
    所述创建子单元,还用于在所述接收子单元接收到所述第一报文时,如果所述保存子单元中未保存所述第二套接字,则创建所述第二套接字;The creating subunit is further configured to: when the receiving subunit receives the first packet, if the second socket is not saved in the saving subunit, create the second socket word;
    所述保存子单元,具体用于将所述待处理报文添加至与所述创建子单元创建的所述第二套接字对应的报文队列中。The saving subunit is specifically configured to add the to-be-processed message to a message queue corresponding to the second socket created by the creating subunit.
  11. 根据权利要求8或9所述的业务节点,A service node according to claim 8 or 9,
    所述保存子单元,具体用于在所述接收子单元接收到所述第一报文时, 如果所述保存子单元中保存有所述第二套接字,则将所述待处理报文添加至与所述第二套接字对应的报文队列中。The saving subunit is specifically configured to: when the receiving subunit receives the first packet, If the second socket is saved in the save subunit, the to-be-processed message is added to the message queue corresponding to the second socket.
  12. 根据权利要求8-11任一所述的业务节点,其特征在于,A service node according to any of claims 8-11, characterized in that
    所述发送子单元,还用于从所述SN中的应用程序单元接收包括所述第二套接字的报文获取请求之前,向所述应用程序单元发送所述第二套接字。The sending subunit is further configured to send the second socket to the application unit before receiving a message obtaining request including the second socket from an application unit in the SN.
  13. 根据权利要求8-12任一所述的业务节点,其特征在于,A service node according to any of claims 8-12, characterized in that
    所述发送子单元,用于向所述应用程序单元发送针对所述报文获取请求的响应,所述响应中携带所述待处理报文的存储地址;The sending subunit is configured to send a response to the packet obtaining request to the application unit, where the response carries a storage address of the to-be-processed packet;
    所述应用程序单元,用于根据所述存储地址,获取所述待处理报文。The application unit is configured to acquire the to-be-processed message according to the storage address.
  14. 根据权利要求8-13任一所述的业务节点,其特征在于,A service node according to any of claims 8-13, characterized in that
    所述发送子单元,用于向所述应用程序单元发送针对所述报文获取请求的响应,所述响应中携带所述待处理报文。 The sending subunit is configured to send a response to the packet obtaining request to the application unit, where the response carries the to-be-processed message.
PCT/CN2015/078518 2014-05-30 2015-05-08 Service router packet processing method and service node WO2015180560A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201410240822.7 2014-05-30
CN201410240822.7A CN105471927B (en) 2014-05-30 2014-05-30 The method and service node that a kind of pair of business routing message is handled

Publications (1)

Publication Number Publication Date
WO2015180560A1 true WO2015180560A1 (en) 2015-12-03

Family

ID=54698063

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2015/078518 WO2015180560A1 (en) 2014-05-30 2015-05-08 Service router packet processing method and service node

Country Status (2)

Country Link
CN (1) CN105471927B (en)
WO (1) WO2015180560A1 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114221898A (en) * 2021-12-29 2022-03-22 优刻得科技股份有限公司 Message processing method and network system

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2017193427A1 (en) 2016-05-10 2017-11-16 华为技术有限公司 Packet switching service recognition method and terminal
US11611506B2 (en) 2020-10-09 2023-03-21 Juniper Networks, Inc. Processing a flow at the egress node in segment routing

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20090228970A1 (en) * 2008-03-07 2009-09-10 Nec Corporation Gateway device having socket library for monitoring, communication method of gateway device having socket library for monitoring, and communication program of gateway device having socket library for monitoring
CN102638395A (en) * 2012-03-19 2012-08-15 华为技术有限公司 Message forwarding method and message forwarding equipment
CN103796078A (en) * 2014-01-23 2014-05-14 深圳创维-Rgb电子有限公司 Multicast video playing method and video playing terminal

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1674538A (en) * 2004-03-25 2005-09-28 联想(北京)有限公司 Network storing system based on local network and its method for reading and writing data

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20090228970A1 (en) * 2008-03-07 2009-09-10 Nec Corporation Gateway device having socket library for monitoring, communication method of gateway device having socket library for monitoring, and communication program of gateway device having socket library for monitoring
CN102638395A (en) * 2012-03-19 2012-08-15 华为技术有限公司 Message forwarding method and message forwarding equipment
CN103796078A (en) * 2014-01-23 2014-05-14 深圳创维-Rgb电子有限公司 Multicast video playing method and video playing terminal

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114221898A (en) * 2021-12-29 2022-03-22 优刻得科技股份有限公司 Message processing method and network system
CN114221898B (en) * 2021-12-29 2023-11-10 优刻得科技股份有限公司 Message processing method and network system

Also Published As

Publication number Publication date
CN105471927A (en) 2016-04-06
CN105471927B (en) 2019-01-08

Similar Documents

Publication Publication Date Title
CN108432194B (en) Congestion processing method, host and system
WO2017157052A1 (en) Tunnel bonding-based communications method and network device
CN110022264B (en) Method for controlling network congestion, access device and computer readable storage medium
US11750515B2 (en) Data transmission method and apparatus
WO2016037504A1 (en) Unified server communication method, baseboard management controller and server
US11233724B2 (en) Multicast data packet processing method, and apparatus
US20220377819A1 (en) Method and apparatus for establishing data transmission link and computer-readable storage medium
US10873562B2 (en) IP address allocation system and method
WO2021233327A1 (en) Message processing method and apparatus, announcement method and apparatus, network bridge node, source device, storage medium, and message processing system
WO2015085576A1 (en) Method for processing address resolution protocol message, forwarder and controller
WO2018121535A1 (en) Load balance processing method and apparatus
US10797986B2 (en) Link discovery method and apparatus
WO2016184283A1 (en) Data stream management method and system for virtual machine
WO2021128927A1 (en) Message processing method and apparatus, storage medium, and electronic apparatus
WO2015196923A1 (en) Method for sending information and network device
WO2016197689A1 (en) Method, apparatus and system for processing packet
US11805049B2 (en) Communication method and communications device
CN110417632B (en) Network communication method, system and server
WO2015180560A1 (en) Service router packet processing method and service node
EP3032801A1 (en) Method and device for generating forwarding information
WO2020147081A1 (en) Data transmission method, related device, and computer storage medium
CN110278156B (en) Multicast routing processing method, network equipment and route reflector
CN113973091A (en) Message processing method, network equipment and related equipment
CN108471374B (en) Data message forwarding method and device
WO2022017503A1 (en) Information processing method, terminal, device and readable storage medium

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: 15799269

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 15799269

Country of ref document: EP

Kind code of ref document: A1