Network service processing method, system and gateway device
By identifying the type of intranet device on the gateway device and allocating software packages, the intranet device can perform additional functions, solving the problem of gateway device performance degradation and achieving function expansion and resource utilization improvement.
Patent Information
- Application Number
- CN202211601153.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Priority Date
- 2019-11-11
- Filing Date
- 2019-11-19
- Publication Date
- 2024-10-11
- Estimated Expiration
- 2039-11-19
AI Technical Summary
When a gateway device integrates multiple additional functions, its performance is reduced due to hardware resource limitations, affecting the normal operation of the LAN system and making it difficult to meet more and more functional requirements.
The gateway device identifies the type of intranet device and sends a software package to it, allowing the intranet device to install and execute additional functions, thus transferring part of the burden of additional functions to the intranet device, reducing the processing burden on the gateway device and saving resources.
It achieves the integration of more functions on the gateway device at a lower cost, improves the utilization of intranet resources, reduces the storage and processing burden of the gateway device, and has good scalability.
Smart Images

Figure CN116032762B_ABST
Abstract
Description
[0001] This application is a divisional application. The application number of the original application is 201911134443.9, and the original application date is November 19, 2019. The entire contents of the original application are incorporated into this application by reference. Technical Field
[0002] The present application relates to the field of computer and communication technology, and in particular to a method for processing network services, a system for processing network services, and a gateway device. Background Art
[0003] Gateway devices are used to connect two networks. They are an important type of basic equipment for enterprises, campuses, homes and many other organizations to build local area networks. Various types of local area networks are connected to the Internet through gateway devices. The basic function of a gateway device is to forward messages between two networks. Considering user needs and costs, in many scenarios, gateway devices often need to integrate multiple additional functions, such as firewall functions, security sandbox functions, or network cache (also known as "net disk") functions, etc.
[0004] However, the gateway device is limited by its own hardware resources and cannot support more additional functions. Integrating multiple additional functions often significantly reduces the performance of the gateway device, thus affecting the normal operation of the entire LAN system. How to resolve this contradiction has become an urgent problem to be solved. Summary of the invention
[0005] The embodiment of the present application provides a method for processing network services, so as to alleviate the problem that the gateway device cannot meet the increasing demand for additional functions.
[0006] In a first aspect, a method for processing network services is provided. In the method, a gateway device identifies the type of a first intranet device, and the first intranet device belongs to an internal network to which the gateway device is connected. The gateway device obtains a first software package according to the type of the first intranet device, and the first software package is used to implement a first additional function. The gateway device sends a first indication message and the first software package to the first intranet device, and the first indication message is used to instruct the first intranet device to install the first software package and execute the first additional function.
[0007] Based on this method, the gateway device, as the management and control subject for implementing additional functions, controls the appropriate intranet device to install the software package to implement the additional functions according to the type of intranet device. Since part of the burden of executing the additional functions is transferred from the gateway device to the intranet device, the processing burden of the gateway device is reduced, the processing resources and storage resources of the gateway device are saved, and a low-cost solution for implementing the additional functions of the gateway device is provided. At the same time, the solution uses the idle resources of the intranet device to implement the additional functions, thereby improving the utilization rate of the intranet resources.
[0008] Optionally, in order to improve the accuracy of the match between the intranet device and the software package (or additional functions), the gateway device determines the software package to be installed on the intranet device based on the performance of the intranet device. In a possible implementation of the first aspect, the gateway device obtains the first software package in the following manner. The gateway device determines the performance of the first intranet device based on the type of the first intranet device, the performance including software capabilities and hardware capabilities, the software capabilities including whether the installation of the software package is supported, and the hardware capabilities including processor performance values and / or storage space size. The gateway device obtains the first software package based on the performance of the first intranet device, and the performance of the first intranet device meets the installation performance requirements of the first software package. Determining the software package to be installed on the intranet device based on the performance of the intranet device will likely greatly improve the implementation effect and performance of the additional functions.
[0009] Optionally, the gateway device stores a correspondence between software packages and installation performance requirements, so that the gateway device can find the first software package in the correspondence between software packages and installation performance requirements according to the performance of the first intranet device.
[0010] Optionally, in order to save storage resources of the gateway device, the above-mentioned multiple software packages for executing various additional functions are distributed and stored in other devices such as a server. In a possible implementation of the first aspect, the gateway device obtains the first software package in the following manner. The gateway device finds the identifier of the first software package in the correspondence between the identifier of the software package and the installation performance requirement according to the performance of the first intranet device. The gateway device sends the identifier of the first software package to the server, and receives the first software package returned by the server according to the identifier of the first software package.
[0011] Optionally, in order to save storage resources and processing resources of the gateway device, the function of matching a suitable software package according to the performance of the intranet device may also be shared by the server. In a possible implementation of the first aspect, the gateway device obtains the first software package in the following manner. The gateway device sends the performance of the first intranet device to the server. The gateway device receives the first software package returned by the server according to the performance of the first internal and external device.
[0012] Optionally, in order to further save storage resources and processing resources of the gateway device, the step of querying the installation performance requirements according to the type of the first intranet device and the step of obtaining the first software package according to the performance are both performed by the server. In a possible implementation of the first aspect, the gateway device obtains the first software package in the following manner. The gateway device sends the type of the first intranet device to the server. The gateway device receives the first software package returned by the server according to the type of the first internal and external device.
[0013] Optionally, in a possible implementation of the first aspect, when the first software package determined for two or more different intranet devices is the same software package, multiple intranet devices may respectively install the same software package and then execute the same additional function, which may lead to a waste of intranet device resources or a conflict problem in the implementation of the additional function. In order to avoid such a possible problem, before the gateway device sends the first indication message and the first software package to the first intranet device, the gateway device identifies the type of the second intranet device, and the second intranet device belongs to the internal network. The gateway device determines the performance of the second intranet device according to the type of the second intranet device. The gateway device finds the second software package in the corresponding relationship between the software package and the installation performance requirement according to the performance of the second intranet device, and the performance of the second intranet device meets the installation performance requirement of the second software package; if the first software package and the second software package are the same software package, the gateway device selects the first intranet device from the first intranet device and the second intranet device to install the first software package. The gateway device can select the first intranet device from the first intranet device and the second intranet device in a variety of ways, such as random selection or selection according to a policy. For example, the gateway device selects the first intranet device from the first intranet device and the second intranet device to install the first software package according to the performance of the first intranet device and the performance of the second intranet device and a predetermined selection strategy.
[0014] Optionally, in a possible implementation of the first aspect, in order to facilitate the subsequent correct forwarding of the data stream to be executed with the first additional function (i.e., the target data stream), so as to correctly execute the first additional function, after the gateway device sends the first indication message and the first software package to the first intranet device, the corresponding relationship between the identifier of the first intranet device and the first additional function is saved. The gateway device obtains the target data stream, which is the data stream to be executed with the first additional function. The gateway device sends the target data stream to the first intranet device according to the corresponding relationship between the identifier of the first intranet device and the first additional function, and receives the processing result of the target data stream by the first intranet device.
[0015] Further, after receiving the processing result of the first intranet device on the target data flow, the gateway device performs an action corresponding to the processing result on the target data flow according to the processing result, and the action includes forwarding, alarming or blocking.
[0016] Optionally, in a possible implementation of the first aspect, in order to facilitate the subsequent correct forwarding of the data stream to be executed for the first additional function (i.e., the target data stream) so as to correctly execute the first additional function, after the gateway device sends the first indication message and the first software package to the first intranet device, it saves the correspondence between the identifier of the first intranet device and the first additional function. The gateway device obtains the target data stream, which is the data stream to be executed for the first additional function. The gateway device determines description information, which is used to describe the target data stream. The gateway device sends the description information to the first intranet device based on the correspondence between the identifier of the first intranet device and the first additional function, and receives the processing result of the description information by the first intranet device. The gateway device sends the description information to the first intranet device instead of the target data stream, which can reduce the amount of data sent by the gateway device to the intranet device that executes the additional function.
[0017] Further, after receiving the processing result of the description information by the first intranet device, the gateway device performs an action corresponding to the processing result on the target data flow according to the processing result, and the action includes forwarding, alarming or blocking.
[0018] Optionally, in order to enhance the user experience, in a possible implementation of the first aspect, before the gateway device sends the first indication message and the first software package to the first intranet device, it outputs a prompt message, the prompt message including the correspondence between the identifier of the first intranet device and the first additional function, the prompt message being used to prompt the first intranet device that it has the ability to execute the first additional function; and receives input confirmation information, the confirmation information being used to indicate that the first intranet device is allowed to execute the first additional function.
[0019] Optionally, the gateway device identifies the type of the first intranet device through a variety of possible implementation methods. In actual application, one or more identification methods can be selected according to different needs. One method is to identify the type of the first intranet device from the forwarded traffic. The gateway device intercepts a characteristic message sent by the first intranet device, and the characteristic message carries a first characteristic field, wherein the content of the first characteristic field is used to indicate the operating system type of the sender or a predetermined website domain name. The gateway device queries the characteristic library for the first device type corresponding to the content of the first characteristic field, and the characteristic library stores the correspondence between the content of the first characteristic field and the first device type; the gateway device determines that the device type of the first intranet device is the first device type.
[0020] The second method is to identify based on the MAC address. The gateway device obtains the MAC address of the first intranet device; the gateway device queries the device information library for the first device type corresponding to the MAC address of the first intranet device, and the device information library stores the correspondence between the MAC address of the first intranet device and the first device type; the gateway device determines that the device type of the first intranet device is the first device type.
[0021] The third method is active scanning detection. The gateway device sends a detection message to the first intranet device; the gateway device receives a response message corresponding to the detection message sent by the first intranet device; the gateway device obtains a first identification fingerprint according to the response message; the gateway device queries the fingerprint library for the first device type corresponding to the first identification fingerprint, and the fingerprint library stores the corresponding relationship between the first identification fingerprint and the first device type; the gateway device determines that the device type of the first intranet device is the first device type.
[0022] Optionally, in the first aspect or any possible implementation of the first aspect, the first additional function is a data stream security detection function, a network cache function, or a security sandbox function. In the case where the first additional function is the data stream security detection function, the target data stream is a data stream to be detected. In the case where the first additional function is the network cache function, the target data stream is a data stream that carries content to be cached. In the case where the first additional function is the security sandbox function, the target data stream is a data stream that carries file content to be detected.
[0023] In a second aspect, a gateway device is provided, the gateway device comprising a network interface, a memory, and a processor connected to the memory. The memory is used to store instructions; the processor is used to execute the instructions, so that the gateway device executes the method in the first aspect or any possible implementation of the first aspect, see the detailed description above for details, which will not be repeated here.
[0024] In a third aspect, a network service processing device is provided, which has the function of implementing the method described in the first aspect or any possible implementation of the above aspects. The function can be implemented by hardware, or by hardware executing corresponding software. The hardware or software includes one or more modules corresponding to the above functions.
[0025] In a fourth aspect, an embodiment of the present application provides a computer storage medium for storing computer software instructions used for the above-mentioned gateway device, which includes a program designed for executing the above-mentioned first aspect or any possible implementation method of the above-mentioned aspects.
[0026] In a fifth aspect, another aspect of the present application provides a computer program product comprising instructions, which, when executed on a computer, enables the computer to execute the methods described in the above aspects.
[0027] In a sixth aspect, an embodiment of the present application provides a chip comprising a memory and a processor, wherein the memory is used to store computer instructions, and the processor is used to call and run the computer instructions from the memory to execute the method in the above-mentioned first aspect and any possible implementation of the first aspect. BRIEF DESCRIPTION OF THE DRAWINGS
[0028] In order to more clearly illustrate the technical solutions of the embodiments of the present application, a brief introduction will be given below to the drawings required for use in the embodiments. Obviously, the drawings described below are some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.
[0029] Figure 1It is a schematic diagram of an application scenario of a network service processing solution provided in an embodiment of the present application;
[0030] Figure 2 is a flow chart of a network service processing method provided by an embodiment of the present application;
[0031] Figure 3 This is a flowchart of the first method of identifying the type of intranet device provided by an embodiment of the present application;
[0032] Figure 4 This is a flow chart of a second method for identifying the type of an intranet device provided in an embodiment of the present application;
[0033] Figure 5 This is a flowchart of a third method for identifying the type of intranet device provided in an embodiment of the present application;
[0034] Figure 6 It is a flowchart of a method for selecting a software package installed on an intranet device based on the performance of the intranet device provided in an embodiment of the present application;
[0035] Figure 7 is a flow chart of another network service processing method provided by an embodiment of the present application;
[0036] Figure 8 It is a flow chart of the gateway device acquiring the first software package according to the performance of the first intranet device in the distributed storage solution 1 provided in the embodiment of the present application;
[0037] Fig. 9 It is a flow chart of the gateway device acquiring the first software package according to the performance of the first intranet device in the distributed storage solution 2 provided in the embodiment of the present application;
[0038] Fig.10 It is a flow chart of the gateway device acquiring the first software package according to the performance of the first intranet device in the distributed storage solution 3 provided in the embodiment of the present application;
[0039] Fig.11 is a flow chart of another network service processing method provided by an embodiment of the present application;
[0040] Fig.12 is a flow chart of another network service processing method provided by an embodiment of the present application;
[0041] Fig.13 is a schematic diagram of the structure of a gateway device provided in an embodiment of the present application;
[0042] Fig.14 It is a structural diagram of a network service processing device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0043] While integrating more additional functions into gateway devices provides convenience for users, it also makes gateway devices prone to becoming performance bottlenecks. Especially in scenarios where the enterprise LAN connected to the gateway device contains a large number of hosts, or in scenarios where the performance of a home router used as a home LAN gateway is low, the gateway device often finds it difficult to support the integration of more and more additional functions.
[0044] In view of the above situation, an embodiment of the present application provides a method for processing network services. Based on this method, under the management and control of the gateway device, the intranet device in the internal network to which the gateway device is connected performs certain additional functions, and part of the burden of the gateway device performing the additional functions is transferred to the intranet device, thereby reducing the processing burden of the gateway device, and providing a solution for realizing the additional functions of the gateway device at a lower cost. Specifically, the gateway device first identifies the type of intranet device in the connected internal network, and further sends a suitable software package for realizing certain additional functions to the intranet device according to the type of the intranet device. After the intranet device installs the software package, the corresponding additional functions are realized.
[0045] The main implementation principles, specific implementation methods and corresponding beneficial effects of the technical solutions of the embodiments of the present invention are described in detail below in conjunction with the accompanying drawings.
[0046] Attached Figure 1 1 is a schematic diagram of an application scenario of a processing solution for network services provided in an embodiment of the present application. The application scenario includes two networks, namely an external network 100 and an internal network 200. A gateway device 300 is used to connect the external network and the internal network 200. Optionally, the external network is the Internet, and the internal network is a local area network established by an organization such as an enterprise, a campus, or a family, or a campus network (Campus network, CAN) composed of multiple local area networks.
[0047] The internal network 200 includes several internal network devices, which are recorded as internal network devices 201 to internal network devices 20n, where n is a natural number greater than 1. The number of internal network devices is limited by the internal network address space, and the embodiment of the present application does not specifically limit the number of internal network devices. Intranet devices include but are not limited to personal computers, servers, laptops, virtual machines, wearable devices, mobile phones, smart screen TVs, sweeping robots, projectors, tablet computers, switches, wireless access points (AP) devices, etc., which have computing capabilities and network connection capabilities.
[0048] Optionally, the gateway device 300 in the embodiment of the present application includes a router, a firewall, a layer 3 switch, etc. The router further includes an access router (such as a home router), an enterprise-level router, a backbone router, and the like.
[0049] The network service processing system provided in the embodiment of the present application includes the following Figure 1 The gateway device 300 and at least one of the intranet devices 201 to 20n.
[0050] The gateway device 300 is used to identify the type of the first intranet device. Figure 1 An intranet device among intranet devices 201 to 20n; according to the type of the first intranet device, obtaining a first software package, the first software package is used to implement a first additional function; sending a first indication message and the first software package to the first intranet device, the first indication message is used to instruct the first intranet device to install the first software package and execute the first additional function. The type of intranet device refers to the category obtained by classifying the intranet devices according to factors such as function and usage characteristics. The types of intranet devices include: personal computers, servers, mobile terminals, printers, smart home devices, etc. The aforementioned laptops, mobile phones, tablets, etc. belong to the type of mobile terminals, and smart screen TVs, sweeping robots, and projectors belong to the type of smart home devices.
[0051] The additional functions in the embodiments of the present application include but are not limited to: a data flow security detection function, a network cache function, a security sandbox function, etc., taking a firewall function as an example. Among them, the firewall function includes filtering the forwarded messages between the local area network and the Internet according to a predetermined rule set, the security sandbox function includes running unknown specific types of content in a virtual operating environment, such as files, web pages, etc., and the network cache function includes caching qualified files, such as video files and audio files exceeding a predetermined size.
[0052] The intranet device is configured to receive the first indication message and the first software package sent by the gateway device, and execute a first additional function after installing the first software package according to the first indication message.
[0053] Optionally, the gateway device 300 selects a suitable software package for the intranet device to implement additional functions based on the performance corresponding to different types of intranet devices. Specifically, the gateway device 300 stores various software packages for implementing different additional functions, and the installation performance requirements corresponding to each software package (for example, the need to support the installation of the software package, the requirements for the CPU processing rate value, or the storage space size, etc.). In the process of obtaining the first software package according to the type of the first intranet device, the gateway device 300 first determines the performance of the first intranet device according to the type of the first intranet device, the performance includes software capabilities and hardware capabilities, the software capabilities include whether the installation of the software package is supported, and the hardware capabilities include processor performance values and / or storage space size. Optionally, the software capabilities also include whether the necessary support software has been installed, and the version of the current operating system, etc. The gateway device 300 obtains the first software package according to the performance of the first intranet device, and the performance of the first intranet device meets the installation performance requirements of the first software package. For example, the gateway device 300 finds the first software package in the corresponding relationship between the software package and the installation performance requirements according to the performance of the first intranet device.
[0054] Optionally, in a scenario where the internal network includes multiple intranet devices, the gateway device 300 is able to identify the types of at least two intranet devices. In this case, the gateway device 300 selects one of the intranet devices to install the first software package. Specifically, the gateway device 300 identifies the types of at least two intranet devices and obtains the performance of each of the at least two intranet devices. If there are at least two intranet devices, such as the performance of the first intranet device and the performance of the second intranet device, both of which meet the installation performance requirements of the first software package, the gateway device 300 selects an intranet device from the at least two intranet devices, such as the first intranet device, to install the first software package. In this case, the gateway device 300 can select an intranet device to install the first software package according to a plurality of selection strategies. Optionally, the gateway device 300 randomly selects an intranet device from the first intranet device and the second intranet device to install the first software package, or the gateway device 300 selects an intranet device with higher performance from the first intranet device and the second intranet device to install the first software package, or the gateway device 300 selects an intranet device with a shorter distance from the gateway device 300 from the first intranet device and the second intranet device according to the topology of the internal network to install the first software package. Due to space limitations, the selection strategies are not listed one by one here.
[0055] Optionally, after the gateway device 300 sends the first indication message and the first software package to the first intranet device, in order to facilitate the subsequent sending of the target data stream, which refers to the data stream to be executed with the first additional function, and / or the description information of the target data stream to the first intranet device that implements the first additional function, the gateway device 300 also needs to record the correspondence between the identifier of the first intranet device and the first additional function. Furthermore, after the gateway device 300 sends the target data stream and / or the above-mentioned description information to the first intranet device based on the correspondence between the identifier of the first intranet device and the first additional function, it also includes receiving the processing result returned by the first intranet device. Optionally, for some additional functions, the gateway device 300 is also used to perform an action corresponding to the processing result on the target data stream based on the processing result, and the action includes forwarding, alarming or blocking.
[0056] Optionally, the gateway device 300 identifies the type of the first intranet device by one of a plurality of methods or a combination of two or more methods. For example, the gateway device 300 determines the type of the intranet device according to a configuration table, wherein the configuration table stores the correspondence between the identifier of each intranet device and the type of the device, and the configuration table is generated according to the data input by the administrator. In addition, the gateway device 300 can also identify the type of the first intranet device in real time by other active or passive methods. These methods include but are not limited to: Method 1, obtaining the type of the first intranet device from the feature message; Method 2, identifying the type of the first intranet device based on the Media Access Control Address (MAC) address of the first intranet device; Method 3, determining the type of the first intranet device by active detection scanning.
[0057] Optionally, in order to save storage resources of the gateway device 300, the above software package can be stored in a server (such as the attached Figure 1 The first software package is stored in the server 101 (shown in FIG. 1 ), rather than in the gateway device 300. That is, the gateway device 300 does not need to store the correspondence between the software package and the installation performance requirement, but stores the correspondence between the software package identifier and the installation performance requirement. In this case, the gateway device 300 finds the identifier of the first software package in the correspondence between the software package identifier and the installation performance requirement, sends the identifier of the first software package to the server 101, and receives the first software package returned by the server. The server 101 is used to send the stored first software package to the gateway device 300 according to the received identifier of the first software package.
[0058] Optionally, in order to further reduce the occupied processing resources of the gateway device 300, the step of obtaining the first software package according to the performance of the first intranet device can be performed by the attached Figure 1In this case, the gateway device 300 sends the performance of the first intranet device to the server, and the gateway device 300 receives the first software package returned by the server 101. The server 101 saves the corresponding relationship between the software package and the installation performance requirement, receives the performance of the first intranet device sent by the gateway device 300, finds the first software package in the corresponding relationship between the software package and the installation performance requirement, and sends the queried first software package to the gateway device 300.
[0059] Optionally, in order to further reduce the occupied processing resources of the gateway device 300, the above step of querying the installation performance requirement according to the type of the first intranet device can also be performed by the attached Figure 1 The server 101 executes. In this case, after the gateway device 300 identifies the type of the first intranet device, it sends the type of the first intranet device to the server; and receives the first software package returned by the server. The server 101 determines the performance of the first intranet device according to the type of the first intranet device, and then obtains the first software package according to the performance of the first intranet device. For example, the first software package is found in the correspondence between the software package and the installation performance requirement. The server 101 sends the obtained first software package to the gateway device 300.
[0060] Optionally, the server 101 may be deployed in the internal network 200 ( Figure 1 Alternatively, the server 101 may also be deployed on the external network 100 (eg Figure 1 As shown). When the server 101 is deployed in the external network 100, the server 101 can support multiple different internal networks to implement the processing solution for network services provided in the embodiment of the present application. The server 101 is also called a "cloud server". The owner of the cloud server is an operator or a third-party organization other than the operator and the internal network owner, and the customers of the cloud server are several internal networks 200. The cloud server is managed by the operator or a third-party organization other than the operator and the internal network owner, and provides support services for multiple different internal networks by opening dedicated ports. After passing the registration and authentication, the internal network 200 communicates and interacts with the cloud server through a general protocol or a private protocol.
[0061] Attached Figure 2 Flow chart of the network service processing method provided in the embodiment of the present application. The network service processing method is executed by a gateway device, as shown in the attached Figure 1 The gateway device 300 in the embodiment of the present application provides a network service processing method including the following steps.
[0062] Step 210: The gateway device identifies the type of the first intranet device. It should be noted that the "first" and "second" in the "first intranet device" and the "second intranet device" that appear later do not indicate a sequential relationship, but are used to distinguish different intranet devices. The first, second, etc. that appear in the following description are also used to distinguish different information or messages.
[0063] The first intranet device belongs to the internal network connected to the gateway device. Figure 1 Intranet device 201.
[0064] According to the type of an intranet device, the gateway device can roughly determine whether the intranet device is suitable for executing additional functions and which additional functions it has the ability to execute. For example, if an intranet device is a mobile terminal, since the location of the mobile terminal often changes, the intranet device is not suitable for executing additional functions. If a mobile terminal is designated to execute a certain additional function, then when the mobile terminal is taken away from the internal network by the user, the additional function executed by the mobile terminal will be unavailable, which will lead to instability of the additional function. For another example, if an intranet device is a printer, since the storage and processing performance of printers are usually limited, it is not suitable for executing additional functions that consume more storage resources and processing resources, and is relatively more suitable for executing additional functions that consume less storage resources and processing resources.
[0065] Optionally, the gateway device uses one or more methods to identify the type of the intranet device, including but not limited to the following methods. For example, the gateway device preferably uses one of the methods to identify the type of a certain intranet device, and when the type of the intranet device cannot be successfully identified, it tries to identify the type of the intranet device through other methods.
[0066] Method 0: Determine the type of the intranet device based on the saved configuration table.
[0067] The gateway device generates a configuration table based on the data input by the administrator, wherein the configuration table stores the correspondence between the identifier of each intranet device (such as the Internet Protocol (IP) address of the intranet device) and the type of the device. Optionally, the administrator uses an input device connected to the input and output interface of the gateway device to input relevant data of an intranet device through the command line interface of the gateway device or other application software such as the network management software interface. These data include the IP address of the intranet device and the type of the intranet device. Further, the manufacturer, specific model and other information of the intranet device can also be input. The gateway device generates a table entry corresponding to the intranet device in the configuration table based on the above data. The table entry includes the IP address of the intranet device and the type of the intranet device.
[0068] When the gateway device needs to determine the type of an intranet device later, it searches for an entry containing the IP address in the configuration table according to the IP address of the intranet device, and obtains the type of the intranet device from the found entry.
[0069] Method 1: Obtain the type of the first intranet device from the forwarded characteristic message. Figure 3 This is a flowchart of the first method of identifying the type of intranet device provided in an embodiment of the present application.
[0070] Step 300: The gateway device intercepts a characteristic message sent by the first intranet device from the forwarded network traffic, wherein the characteristic message carries a first characteristic field, and the content of the first characteristic field is used to indicate the operating system type or the predetermined website domain name of the sender. Optionally, the predetermined website domain name includes the domain name of the device upgrade website.
[0071] Step 320: The gateway device searches a feature library for a first device type corresponding to the content of a first feature field in the feature message. The feature library stores a correspondence between the content of the first feature field and the first device type.
[0072] Step 340: The gateway device determines that the type of the first intranet device is the first device type.
[0073] For example, the characteristic message is a Hypertext Transfer Protocol (HTTP) message carrying a User-Agent field sent by an intranet device. The intranet device will send an HTTP message carrying a User-Agent field during the portal authentication process.
[0074] Specific examples of the specific contents of the two feature fields are given below.
[0075] Example 1: The User-Agent field content is "Android 8.0.0; VTR-L09 Build / HUAWEIVTR-L09". The User-Agent field content in the HTTP message sent by the HUAWEI P10 mobile phone during the Portal authentication process includes "Android 8.0.0; VTR-L09 Build / HUAWEIVTR-L09".
[0076] Example 2: The User-Agent field content is "Windows NT 6.1; Win64; x64". The User-Agent field content in the HTTP message sent by the personal computer during the Portal authentication process includes "Windows NT 6.1; Win64; x64".
[0077] The gateway device's feature library pre-stores the corresponding relationship between "Android 8.0.0; VTR-L09 Build / HUAWEIVTR-L09" and the device type "mobile terminal", as well as the corresponding relationship between "Windows NT 6.1; Win64; x64" and the device type "personal computer". After the gateway device parses the content of the User-Agent field from the feature message sent by the first intranet device, the content of the User-Agent field obtained by parsing is compared with each feature field in the feature library. If the content of the User-Agent field obtained by parsing includes "Android 8.0.0; VTR-L09Build / HUAWEIVTR-L09", it is determined that the type of the first intranet device is a mobile terminal. If the content of the User-Agent field obtained by parsing includes "Windows NT 6.1; Win64; x64", it is determined that the type of the first intranet device is a personal computer.
[0078] The characteristic message may also be a DHCP message carrying an Option field sent by an intranet device. The contents of the requested parameter list field (i.e., Option 55 field), the vendor ID field (i.e., Option 60 field), and the host name field (i.e., Option 12 field) in the Option field may also be used to identify the type of the intranet device that sent the DHCP message carrying the Option field.
[0079] The characteristic message may also be a probe request (Probe Request) message and / or an association request (Association Request) message sent by the intranet device to the AP.
[0080] Other characteristic messages are not listed here one by one.
[0081] The above signature database is pre-configured by the administrator and can also be obtained from public websites, such as https: / / fingerbank.inverse.ca.
[0082] Method 2: Identification based on MAC address. Figure 4 This is a flow chart of the second method of identifying the type of intranet device provided in an embodiment of the present application.
[0083] Step 400: The gateway device obtains the MAC address of the first intranet device. For example, the gateway device obtains the MAC address of the first intranet device from the message header of the forwarded IP message, or the gateway device sends an ARP request to the first intranet device and obtains the MAC address of the first intranet device from the corresponding Address Resolution Protocol (ARP) response.
[0084] In step 420, the gateway device queries the device information library for the first device type corresponding to the MAC address of the first intranet device, and the device information library stores the correspondence between the MAC address of the first intranet device and the first device type. The device information library is pre-stored. For example, when the gateway device administrator adds a new device to the internal network, when configuring network parameters and other parameters for the new intranet device, the MAC address of the new intranet device and the device type of the new intranet device are input into the gateway device through an input device connected to the gateway device and saved. Alternatively, the device information library is downloaded by the gateway device from the manufacturer support website of the intranet device.
[0085] Step 440: The gateway device determines that the type of the first intranet device is the first device type.
[0086] For example, the first three bytes of a MAC address are the MAC Organizationally Unique Identifier (OUI). The MAC OUI is uniformly assigned to each device manufacturer by the Institute of Electrical and Electronics Engineers (IEEE) and can be used to identify companies that are public to the IEEE. There is a corresponding relationship between device manufacturers and device types. For example, some manufacturers only produce printer devices, and some manufacturers only produce mobile terminal devices, and so on.
[0087] The above device information rule base can be established manually or by referring to the public information on the websites of some manufacturers and organizations. For example, the IEEE MAC OUI rule base http: / / standards-oui.ieee.ory / oui / oui.txt can be referred to.
[0088] Method 3: Identification through active detection scanning. The gateway device sends a detection message to the first intranet device, and identifies the type of the first intranet device according to the corresponding response message. Figure 5 This is a flowchart of the third method of identifying the type of intranet device provided in an embodiment of the present application.
[0089] Step 500: The gateway device sends a detection message to the first intranet device.
[0090] Step 520: The gateway device receives a response message corresponding to the detection message sent by the first intranet device.
[0091] Step 540: The gateway device obtains a first identification fingerprint according to the response message.
[0092] Step 560: The gateway device searches for the first device type corresponding to the first identification fingerprint in a fingerprint database, in which the corresponding relationship between the first identification fingerprint and the first device type is stored.
[0093] Step 580: The gateway device determines that the type of the first intranet device is the first device type.
[0094] For example, one or more scanner software are pre-installed in the gateway device, and the scanner software includes but is not limited to the vulnerability scanner NESSUS launched by Tenable, the open source scanning tool Nmap, the network tool netcat of the Unix operating system platform, etc. The gateway device actively sends a detection message to the intranet device by running the above scanner software, obtains an identification fingerprint from the corresponding response message, and identifies the type of the intranet device as the scanning object according to the identification fingerprint.
[0095] For example, when a gateway device uses Nmap to scan an intranet device, it sends multiple specially constructed detection messages. The gateway device receives the response message corresponding to the intranet device and generates an identification fingerprint based on the following field values in the response message. The fields used to generate the identification fingerprint in the response message include one or more of the following combinations: SEQ, OPS, WIN, T1-T7, IE, ECN, U1. The gateway device then uses the generated identification fingerprint as an index to query the corresponding device type in the fingerprint library.
[0096] The fingerprint library provided by Nmap version 7.70 contains 5652 fingerprints stored in plain text. These fingerprints correspond to 28 device types.
[0097] Back to the attached Figure 2 In the process shown, after the gateway device identifies the type of the first intranet device in step 210 , step 220 is executed.
[0098] Step 220: The gateway device obtains a first software package according to the type of the first intranet device, where the first software package is used to implement a first additional function.
[0099] Optionally, the gateway device stores a correspondence between the types of intranet devices and software packages, as shown in Table 1. After the gateway device identifies the type of the first intranet device, it searches the correspondence shown in Table 1 to find the software package corresponding to the type of the first intranet device.
[0100] A software package refers to a program or a group of programs that has a specific function and is used to complete a specific task. For the sake of simplicity and distinctiveness in the description, in the embodiments of the present application, a string with a suffix is used to represent a software package, and a string without a suffix is used to represent the identifier of the software package (the name of the software package). For example, "Firewall.exe" represents a software package for implementing a security detection additional function taking a firewall as an example, and Firewall represents the identifier of the software package.
[0101] Table 1
[0102]
[0103] Optionally, when the correspondence between the type of intranet device and the software package is specifically stored, there are multiple possible storage forms. For example, what is actually saved is the correspondence between the type of intranet device and the storage location of the software package in the file system of the gateway device, or the correspondence between the type of intranet device and the identifier of the software package. The storage location includes but is not limited to the path in the file system. If the correspondence between the type of intranet device and the storage location of the software package in the file system of the gateway device is saved, the gateway device finds the storage location of the corresponding first software package according to the type of the first intranet device, and then obtains the first software package at the storage location. If the correspondence between the type of intranet device and the identifier of the software package is saved, the gateway device finds the identifier of the corresponding first software package according to the type of the first intranet device, and then finds the first software package in the file system of the gateway device.
[0104] Optionally, since under normal circumstances, there is a one-to-one correspondence between software packages and additional functions, the correspondence shown in Table 1 can also be replaced by a correspondence between the type of intranet device and the additional function. In this case, after the gateway device identifies the type of the first intranet device, it queries the additional function corresponding to the type of the first intranet device from the correspondence between the type of the intranet device and the additional function, and then further obtains the software package that implements the additional function. Alternatively, the correspondence shown in Table 1 can also include both the software package and the additional function corresponding to the software package.
[0105] Step 230: The gateway device sends a first instruction message and a first software package to the first intranet device. The first instruction message is used to instruct the first intranet device to install the first software package and execute the first additional function. For example, the first instruction message includes an identifier and an operator of the first software package, where the operator corresponds to an installation operation and a running operation. The identifier of the first software package includes a name of the first software package, a hash value of the first software package, and the like.
[0106] Optionally, in order to enhance the user's experience and ensure the user's right to know, before the gateway device sends the first software package and the first instruction message to the first intranet device, the gateway device notifies the administrator that the first intranet device can perform the first additional function. After receiving the administrator's confirmation instruction, the gateway device executes step 230. Optionally, the notification method includes but is not limited to: prompting the administrator through the output device connected to the gateway device, sending a text message to the administrator's mobile phone, sending an email to the administrator, sending a message to the administrator through an instant messaging software such as WeChat and MSN (The Microsoft Network), etc.
[0107] According to the network service processing method provided in the embodiment of the present application, the gateway device serves as the management and control subject for implementing additional functions. The gateway device first identifies the type of intranet device, and according to the type of intranet device, sends a software package for implementing the appropriate additional function to the intranet device, instructing the intranet device to implement the additional function after successfully installing the software package. Since part of the burden of executing the additional function is transferred from the gateway device to the intranet device, the processing burden of the gateway device is reduced, the processing resources and storage resources of the gateway device are saved, and a low-cost solution for implementing the additional functions of the gateway device is provided. At the same time, the solution utilizes the idle resources of the intranet device to implement the additional functions, thereby improving the utilization rate of the intranet resources. In addition, in the solution, each additional function corresponds to an independent software package, and each time an additional function is added, it is only necessary to develop the corresponding software package. The execution of new additional functions does not significantly increase the burden on the gateway device, so it also has better scalability.
[0108] In the attached Figure 2 In the method for processing network services shown in FIG. 1 , in step 220, the gateway device obtains the first software package based on the correspondence between the type of intranet device and the software package shown in Table 1. This method is quick and effective. However, in actual implementation scenarios, there are often multiple types of intranet devices, and the performance of these intranet devices varies greatly. The method of step 220 can only achieve coarse-grained matching between intranet devices and software packages (or additional functions). In the specific implementation process, there may be problems such as failure to install the software package or poor implementation of the additional functions. For example, the performance of the intranet device is actually difficult to meet the requirements for implementing the additional functions, resulting in the failure of the software package installation, or the performance of the intranet device is too low, resulting in the software package running too slowly after installation, and the additional functions are poorly implemented.
[0109] If the accuracy of the match between the intranet device and the software package (or additional function) can be improved, it will be possible to greatly improve the implementation effect and performance of the additional function. For example, the first intranet device is a server and the second intranet device is a personal computer. Although the first intranet device and the second intranet device can both support an additional function that consumes more storage resources and processing resources. However, since the performance of the first intranet device is significantly higher than that of the second intranet device, for example, the first intranet device has a larger memory capacity and processor speed, the first intranet device can achieve better results by executing the additional function that consumes more storage resources and processing resources. Therefore, an embodiment of the present application provides a method for selecting a software package to be installed on an intranet device based on the performance of the intranet device, as shown in the attached figure. Figure 6 Attached Figure 6 The process shown is to execute the attached Figure 2 An alternative method to step 220 "the gateway device obtains the first software package according to the type of the first intranet device".
[0110] Step 610: The gateway device determines the performance of the first intranet device according to the type of the first intranet device, wherein the performance includes software capability and hardware capability, wherein the software capability includes whether the software package can be installed, and the hardware capability includes processor performance value, storage space size, etc.
[0111] Optionally, the gateway device stores a correspondence between the type and performance of the intranet device, as shown in Table 2. After the gateway device identifies the type of the first intranet device, it can query the performance of the first intranet device in the correspondence between the type and performance of the intranet device shown in Table 2.
[0112] Optionally, the type of the intranet device further includes the manufacturer and / or model information of the intranet device, which is equivalent to further subdividing the type of the intranet device. Figure 2 After the type of the first intranet device including the manufacturer and / or model information is identified in step 220, more accurate performance can be queried in the correspondence between the type and performance of the intranet device shown in Table 2.
[0113] Table 2
[0114]
[0115] Step 620: The gateway device obtains the first software package according to the performance of the first intranet device, wherein the performance of the first intranet device meets the installation performance requirement of the first software package.
[0116] Optionally, the gateway device stores the installation performance requirements corresponding to each software package, as shown in Table 3. After obtaining the performance of the first intranet device, the gateway device compares the performance of the first intranet device with the installation performance requirements corresponding to each software package, and if the main performance of the first intranet device is higher than the installation performance requirements of the first software package, it is determined that the performance of the first intranet device meets the installation performance requirements of the first software package.
[0117] Table 3
[0118]
[0119] For example, assuming that the type of the first intranet device is a personal computer and the model is H-TG01, the performance of the first intranet device meets the installation performance requirements of the software packages networkstorage.exe and Firewall.exe, but does not meet the installation performance requirements of the software package Websandbox.exe. In this case, the first software package is a software package named networkstorage.exe or a software package named Firewall.exe.
[0120] Assuming that the type of the first intranet device is a server and the model is D-R7, the performance of the first intranet device meets the installation performance requirements of the software packages networkstorage.exe, Firewall.exe and Websandbox.exe. In this case, the first software package is a software package named networkstorage.exe, a software package named Firewall.exe or a software package named Websandbox.exe.
[0121] In the embodiment of the present application, after the gateway device identifies the type of the first intranet device, it obtains the performance of the first intranet device according to the type of the first intranet device, and then compares the performance of the first intranet device with the installation performance requirements of the software package, thereby ensuring that the performance of the first intranet device meets the installation performance requirements of the selected first software package. In this way, the failure rate of the first intranet device installing the software package or running the software package can be reduced, and the success rate of the first intranet device installing the software package can be increased, thereby improving the implementation effect of the additional function.
[0122] Optionally, when attached Figure 1 When the internal network 200 in the embodiment includes multiple internal network devices, the gateway device 300 identifies the types of the multiple internal network devices in parallel, and after identifying the types of the multiple internal network devices, uses the attached Figure 2 Or attach Figure 6The method shown may result in a situation where the first software package determined for two or more different intranet devices is the same software package. In this case, if the gateway device 300 sends the same software package to two or more intranet devices, then these intranet devices will execute the same additional function after installing the same software package respectively, which may lead to a waste of intranet device resources or conflicts in the implementation of additional functions. In order to avoid this possible problem, in the case where the first software package determined by the gateway device 300 for multiple different intranet devices is the same software package, the gateway device 300 needs to select one intranet device from the multiple intranet devices. The gateway device 300 sends the first software package to the selected intranet device to avoid sending the same software package to multiple intranet devices at the same time. That is, in the attached Figure 2 In the method shown, before step 230, it also includes: the gateway device 300 determines to obtain the first software package based on the type of the second intranet device; the gateway device 300 selects the first intranet device from the first intranet device and the second intranet device, and sends the first indication message and the first software package to the first intranet device, but does not send the first indication message and the first software package to the second intranet device.
[0123] Similarly, in the attached Figure 6 In the method for processing network services shown in FIG. 1 , if the first software package determined for two or more different intranet devices is the same software package, one of the intranet devices can be selected for subsequent installation of the first software package based on the performance of the two intranet devices. In this case, the method for processing network services is as follows: Figure 7 shown.
[0124] Attached Figure 7 The method for processing a network service shown includes the following steps.
[0125] Please refer to the attached Figure 6 And related descriptions will not be repeated here.
[0126] Before step 230, the method further includes:
[0127] Step 710: The gateway device identifies the type of a second intranet device, where the second intranet device belongs to an internal network to which the network management device is connected.
[0128] Step 720: The gateway device determines the performance of the second intranet device according to the type of the second intranet device.
[0129] Step 730: The gateway device searches for the second software package in the correspondence between software packages and installation performance requirements based on the performance of the second intranet device, and the performance of the second intranet device meets the installation performance requirements of the second software package.
[0130] The implementation principles of steps 710 to 730 are respectively as follows: Figure 2 Step 210 and the attached Figure 6 Steps 610 and 620 are similar and will not be repeated here.
[0131] In step 240, the gateway device determines whether the first software package and the second software package are the same software package. If the first software package and the second software package are different software packages, steps 230 and 231 are executed. In step 231, the gateway device sends a second indication message and a second software package to the second intranet device, where the second indication message is used to instruct the second intranet device to install the second software package and execute the second additional function.
[0132] If the first software package and the second software package are the same software package, step 250 is executed.
[0133] Step 250 : The gateway device selects the first intranet device from the first intranet device and the second intranet device to install the first software package according to the performance of the first intranet device and the performance of the second intranet device and a predetermined selection strategy. Execute step 230 .
[0134] Optionally, the predetermined selection strategy includes selecting an intranet device with better performance.
[0135] Assume that the first intranet device is attached Figure 1 The type of the intranet device 201 is a personal computer and the model is H-TG01. Figure 1 The type of the intranet device 202 is a personal computer and the model is D-VOSTRO. After the gateway device 300 identifies the types of the intranet device 201 and the intranet device 202, it executes the attached Figure 6 The method shown determines that the intranet device 201 is used to install Firewall.exe, and the intranet device 201 is also used to install Firewall.exe. Since the performance of the intranet device 201 is better than that of the intranet device 202, the gateway device 300 selects the intranet device 201 from the intranet device 201 and the intranet device 202, and the gateway device 300 sends an instruction message to the intranet device 201, and the instruction message includes the Firewall.exe software package, which is used to instruct the intranet device 201 to install the Firewall.exe software package and execute the corresponding firewall function.
[0136] Optionally, attach Figure 1 The gateway device 300 in the example is used as the main body to control each intranet device to execute additional functions. Figure 2 , Attachment Figure 2 or attached Figure 7 The processing method of the network service shown in the figure. The above-mentioned multiple software packages for executing various additional functions can be stored in a centralized manner or in a distributed manner. Centralized storage means that the above-mentioned multiple software packages for executing various additional functions are stored in the memory of the gateway device. Distributed storage means that all or part of the multiple software packages for executing various additional functions are stored in other network devices accessible to the gateway device. Optionally, these network devices for storing all or part of the software packages can be deployed in the internal network 200 or in the external network 100. Figure 1 The "cloud server" solution shown is used as an example to describe the distributed storage situation. The present application embodiment provides three specific implementation methods of distributed storage.
[0137] Distributed storage solution 1
[0138] The individual software packages are stored in the Figure 1 The cloud server shown in the server 101 is not stored in the gateway device 300. The gateway device 300 does not need to store the corresponding relationship between the software package and the installation performance requirement, but stores the corresponding relationship between the software package identifier and the installation performance requirement. Figure 6 The implementation process of step 220 is as follows Figure 8 shown.
[0139] Attached Figure 8 The present invention describes a process in which a gateway device obtains the first software package according to the performance of a first intranet device.
[0140] Gateway device execution Figure 6 In step 610, after determining the performance of the first intranet device according to the type of the first intranet device, the server cooperates with the server to execute the attached Figure 8 Steps 810 to 840 in the above embodiment are used to replace the Figure 6 Step 620 in .
[0141] Step 810: The gateway device obtains the identifier of the first software package from the corresponding relationship between the identifier of the software package and the installation performance requirement according to the performance of the first intranet device, wherein the performance of the first intranet device meets the installation performance requirement corresponding to the identifier of the first software package.
[0142] Step 820: The gateway device sends the identifier of the first software package to the server.
[0143] Step 830: The server obtains the stored first software package according to the received identifier of the first software package.
[0144] Step 840: The server sends the acquired first software package to the gateway device. The gateway device receives the first software package returned by the server.
[0145] For example, assuming that the first intranet device is the intranet device 201, the type of the intranet device 201 is a personal computer, and the model is H-TG01. The gateway device 300 locally stores the corresponding relationship between the identifier of the software package and the installation performance requirement, as shown in Table 4.
[0146] Table 4
[0147]
[0148] The gateway device 300 determines that the performance of the first intranet device meets the installation performance requirements of the software package named Firewall. The gateway device 300 sends the identifier of the first software package "Firewall" to the server 101, and after receiving the software package Firewall.exe returned by the server 101, sends the first indication message and the software package Firewall.exe to the intranet device 201.
[0149] The separate storage solution provided in the embodiment of the present application can save storage resources of the gateway device 300.
[0150] Distributed storage solution 2
[0151] The individual software packages are stored in the Figure 1 The server 101 in FIG. 1 is stored in the cloud server shown in FIG. 101, rather than in the gateway device 300. The gateway device 300 does not need to store the corresponding relationship between the software package and the installation performance requirements, nor does it need to store the corresponding relationship between the software package identifier and the installation performance requirements. It only needs to store the corresponding relationship between the type and performance of the intranet device shown in Table 2. The server 101 not only stores each software package, but also needs to store the corresponding relationship between the software package and the installation performance requirements shown in Table 3. In this case, the attached Figure 6 The implementation process of step 220 is as follows Fig. 9 shown.
[0152] Attached Fig. 9 The present invention describes a process in which a gateway device obtains the first software package according to the performance of a first intranet device.
[0153] Gateway device execution Figure 6 In step 610, after determining the performance of the first intranet device according to the type of the first intranet device, the server cooperates with the server to perform steps 910 to 930 to replace the attached Figure 6 Step 620 in .
[0154] Step 910: The gateway device sends the performance of the first intranet device to the server.
[0155] Step 920: The server obtains the first software package from the correspondence between software packages and installation performance requirements according to the received performance of the first intranet device, wherein the performance of the first intranet device meets the installation performance requirements corresponding to the identifier of the first software package.
[0156] For example, the server saves the correspondence between the software packages and the installation performance requirements shown in Table 3. After receiving the performance of the first intranet device sent by the gateway device, the server compares the performance of the first intranet device with the installation performance requirements corresponding to each software package. If the main performance of the first intranet device is higher than the installation performance requirement of the first software package, it is determined that the performance of the first intranet device meets the installation performance requirements of the first software package.
[0157] Alternatively, the server stores not the correspondence between the software package and the installation performance requirement shown in Table 3, but the correspondence between the identifier of the software package and the installation performance requirement as shown in Table 4. After receiving the performance of the first intranet device, the server compares the performance of the first intranet device with the installation performance requirement corresponding to the identifier of each software package. If the main performance of the first intranet device is higher than the installation performance requirement corresponding to the identifier of the first software package, it is determined that the performance of the first intranet device meets the installation performance requirement of the first software package. The server then searches for the corresponding first software package according to the identifier of the first software package.
[0158] Step 930: The server sends the first software package to the gateway device. Correspondingly, the gateway device receives the first software package returned by the server, and then sends the first software package and the first indication message to the first intranet device.
[0159] For example, assume that the first intranet device is intranet device 201, and the type of intranet device 201 is a personal computer, and the model is H-TG01. The gateway device 300 determines that the performance of the intranet device 201 includes "CPU: 2GHz; Memory: 512MB; Hard disk capacity: 256GB" according to Table 2. The gateway device 300 sends the performance of the intranet device 201 "CPU: 2GHz; Memory: 512MB; Hard disk capacity: 256GB" to the server 101. The server 101 compares the received performance "CPU: 2GHz; Memory: 512MB; Hard disk capacity: 256GB" with the corresponding relationship between the software package and the installation performance requirements shown in Table 3, or the corresponding relationship between the identifier of the server-saved software package and the installation performance requirements shown in Table 4. The performance of the intranet device 201 of the server 101 meets the installation performance requirements of the software package Firewall.exe. The server 101 sends the software package Firewall.exe to the gateway device 300.
[0160] The separate storage solution provided in the embodiment of the present application can further save storage resources of the gateway device on the one hand, and on the other hand, since the step of obtaining the first software package is executed by the server according to performance, the processing resources of the gateway device are also saved.
[0161] Distributed storage solution 3
[0162] The individual software packages are stored in the Figure 1 The server 101 in FIG. 1 is stored in the cloud server shown in FIG. 101, rather than in the gateway device 300. The gateway device 300 does not need to store the correspondence between the software package and the installation performance requirements, nor does it need to store the correspondence between the software package identifier and the installation performance requirements, nor does it need to store the correspondence between the type and performance of the intranet device shown in Table 2. The server 101 not only stores each software package, but also needs to store the correspondence between the software package and the installation performance requirements shown in Table 3, and further needs to store the correspondence between the type and performance of the intranet device shown in Table 2. In this case, the attached Figure 2 The implementation process of step 220 is as follows Fig.10 shown.
[0163] Attached Fig.10 The present invention describes a process in which a gateway device obtains the first software package according to the performance of a first intranet device.
[0164] Gateway device execution Figure 2 , or attach Figure 6 In step 210, after identifying the type of the first intranet device, the server cooperates with the server to execute steps 110 to 130 to replace the attached Figure 2 Step 220 in the above, or alternatively Figure 6 Steps 610 to 620 in FIG.
[0165] Step 110: The gateway device sends the type of the first intranet device to the server.
[0166] Step 120: After receiving the type of the first intranet device sent by the gateway device, the server searches for the performance of the first intranet device in the corresponding relationship between the type of the intranet device and the performance shown in Table 2.
[0167] Step 130: The server searches for the first software package in the correspondence between software packages and installation performance requirements based on the performance of the first intranet device found, wherein the performance of the first intranet device meets the installation performance requirements corresponding to the identifier of the first software package.
[0168] For example, the server saves the correspondence between the software packages and the installation performance requirements shown in Table 3. After querying the performance of the first intranet device, the server compares the performance of the first intranet device with the installation performance requirements corresponding to each software package. If the main performance of the first intranet device is higher than the installation performance requirements of the first software package, it is determined that the performance of the first intranet device meets the installation performance requirements of the first software package.
[0169] Alternatively, the server stores not the correspondence between the software packages and the installation performance requirements shown in Table 3, but the correspondence between the identifiers of the software packages and the installation performance requirements shown in Table 4. After querying the performance of the first intranet device, the server compares the performance of the first intranet device with the installation performance requirements corresponding to the identifiers of each software package. If the main performance of the first intranet device is higher than the installation performance requirements corresponding to the identifier of the first software package, it is determined that the performance of the first intranet device meets the installation performance requirements of the first software package. The server then searches for the corresponding first software package according to the identifier of the first software package.
[0170] Alternatively, the server saves not the corresponding relationship between the software package and the installation performance requirement shown in Table 3 or the corresponding relationship between the identifier of the software package and the installation performance requirement shown in Table 4, but the corresponding relationship between the type of the intranet device and the software package shown in Table 1. In this case, step 120 and step 130 can be directly simplified to the server querying the software package corresponding to the type of the first device in the corresponding relationship between the type of the intranet device and the software package according to the received type of the intranet device. This is basically similar to step 220, except that the execution subject is different, and will not be described in detail here.
[0171] Step 140: The server sends a first software package to the gateway device. Correspondingly, the gateway device receives the first software package returned by the server, and then sends the first software package and a first indication message to the first intranet device.
[0172] The execution process of step 130 is similar to that of the attached Fig. 9 Similar to step 920 in FIG. 1 , the execution process of step 140 is similar to that of FIG. Fig. 9 The process is similar to step 930 in , and will not be described in detail here.
[0173] For example, it is assumed that the first intranet device is the intranet device 201, and the type of the intranet device 201 is a personal computer and the model is H-TG01. The gateway device 300 sends the type of the intranet device 201 "personal computer, H-TG01" to the server 101. After receiving the type of the intranet device 201 "personal computer, H-TG01", the server 101 finds out in the correspondence between the type and performance of the intranet device shown in Table 2 that the performance corresponding to the type "personal computer, H-TG01" is "CPU: 2GHz; memory: 512MB; hard disk capacity: 256GB". The server 101 further compares the performance "CPU: 2GHz; memory: 512MB; hard disk capacity: 256GB" with the corresponding relationship between the software package and the installation performance requirements shown in Table 3, or the corresponding relationship between the identifier of the server-stored software package and the installation performance requirements shown in Table 4, and determines that the performance "CPU: 2GHz; memory: 512MB; hard disk capacity: 256GB" meets the installation performance requirements of the software package Firewall.exe. The server 101 sends the software package Firewall.exe to the gateway device 300 .
[0174] The separate storage solution provided in the embodiment of the present application can, on the one hand, further save the storage resources of the gateway device. On the other hand, since the steps of querying the installation performance requirements according to the type of the first intranet device and obtaining the first software package according to the performance are both executed by the server, the processing resources of the gateway device are further saved.
[0175] Optionally, according to the attached Figure 2 , Attachment Figure 6 ~Attached Fig.10 In the method for processing network services, after the gateway device sends the first indication message and the first software package to the first intranet device, in order to facilitate the subsequent sending of the target data stream and / or the description information used to describe the target data stream to the first intranet device that implements the first additional function, the gateway device also needs to record the correspondence between the identifier of the first intranet device and the first additional function. The target data stream refers to the data stream to be executed for the first additional function. The purpose of the gateway device recording the correspondence between the identifier of the first intranet device and the first additional function is to correctly forward the target data stream in the future, so as to correctly execute the first additional function. For example, based on the correspondence between the identifier of the first intranet device and the first additional function, the gateway device subsequently sends the target data stream and / or the description information used to describe the target data stream to the first intranet device that implements the first additional function, and receives the corresponding processing result of the first intranet device. Optionally, for some additional functions, the gateway device performs an action corresponding to the processing result on the target data stream in the forwarded traffic based on the received processing result, and the action includes forwarding, alarming or blocking. The specific implementation process is as shown in the attached figure. Fig.11 and attached Fig.12 shown.
[0176] Based on the network service processing methods provided in the previous embodiments of the present application, the present application embodiment further provides a network service processing method, as shown in the attached Fig.11 Attached Fig.11 is a flow chart of a method for processing network services provided by an embodiment of the present application. Figure 1 The gateway device 300 in the example is executed when the Figure 2 , Attachment Figure 6 ~Attached Fig.10 After the step of sending the first indication message and the first software package to the first intranet device in the network service processing method, the attached Fig.11 The steps shown.
[0177] Step 111: The gateway device saves the correspondence between the identifier of the first intranet device and the first additional function.
[0178] Optionally, in order to ensure the implementation effect of the first additional function, after the gateway device sends the first indication message and the first software package to the first intranet device, it waits to receive a confirmation message returned by the first intranet device after the first software package is installed. After the gateway device receives the confirmation message from the first intranet device, the gateway device saves the corresponding relationship between the identifier of the first intranet device and the first additional function.
[0179] Step 112: The gateway device obtains the traffic to be forwarded, and obtains a target data flow from the traffic to be forwarded, where the target data flow refers to a data flow on which the first additional function is to be executed.
[0180] Which data flows are target data flows is related to the specific additional functions. For example, if the first additional function is the data flow security detection function, then the target data flow is the traffic to be detected that complies with the predetermined policy. The predetermined policy is set in advance according to the network scenario, which can be all bidirectional traffic, or unidirectional traffic sent from the external network to the internal network, etc.
[0181] For example, if the first additional function is a network cache function, the target data stream is a data stream carrying content to be cached. The type of content to be cached is preset, for example, the content to be cached is multimedia content and the like.
[0182] For example, if the first additional function is a security sandbox function, then the target data stream is a data stream that carries the content of the file to be detected. The format type of the file to be detected is pre-set, such as a portable document format (PDF) file, or an executable file (EXE) file, a portable executable (PE) file, etc. The gateway device can parse some messages in the forwarded data stream, such as a small number of messages in the initial stage of session establishment, to determine whether the data stream to which these messages belong is the target data stream. For example, a small number of messages in the initial stage of session establishment are subjected to protocol parsing to obtain the file header data carried in the message, and the content type carried by the session is obtained from the file header data.
[0183] Step 113: The gateway device sends the target data stream to the first intranet device according to the correspondence between the identifier of the first intranet device and the first additional function.
[0184] Step 114: The gateway device receives the processing result of the first intranet device on the target data flow.
[0185] Optionally, take the first additional function as a network cache function as an example. The first intranet device is an additional Figure 1 In the intranet device 201, the gateway device is attached Figure 1 The gateway device 300 in the network. The gateway device 300 sends a first indication message and a software package networkstorage.exe to the intranet device 201. After the intranet device 201 completes the installation of the software package Firewall.exe according to the first indication message, it executes the network cache function. The gateway device 300 records the correspondence between the intranet device 201 and the network cache function. The predetermined policy configured in the gateway device 300 is to cache video files exceeding 50M. That is, the target data stream is a data stream carrying video files exceeding 50M. After the gateway device 300 subsequently receives the data stream carrying video files exceeding 50M through the network interface, in addition to executing the original forwarding process, it also sends the data stream to the intranet device 201. The gateway device 300 receives the cache result of this part of the data stream from the intranet device 201, such as the cache result indicating that the video file is cached successfully or the cache result indicating that the video file fails to be cached.
[0186] Optionally, for some additional functions, after step 114 , the gateway device further performs step 115 .
[0187] Step 115: The gateway device performs an action corresponding to the processing result on the target data flow according to the processing result, and the action includes forwarding, warning or blocking.
[0188] Optionally, take the first additional function as a data flow security detection function as an example. The first intranet device is an additional Figure 1 In the intranet device 201, the gateway device is attached Figure 1 The gateway device 300 in the figure. The gateway device 300 sends a first indication message and a software package Firewall.exe to the intranet device 201. After the intranet device 201 completes the installation of the software package Firewall.exe according to the first indication message, it executes the data flow security detection function taking the firewall as an example. The gateway device 300 records the correspondence between the intranet device 201 and the data flow security detection function. The predetermined policy configured in the gateway device 300 is to perform security detection on the unidirectional traffic sent from the external network to the internal network. That is, the target data flow to be detected is the unidirectional traffic sent from the external network to the internal network. After the gateway device 300 subsequently receives the data flow sent from the external network 100 to the internal network 200 through the network interface, it sends the data flow to the intranet device 201. After the gateway device 300 receives the security detection result of the target data flow from the intranet device 201, if the security detection result indicates that the target data flow does not contain data that violates the firewall rules, the gateway device 300 forwards the target data flow to the internal network 200 through the network interface; if the security detection result indicates that the target data flow contains data that violates the firewall rules, the gateway device 300 blocks the target data flow and prohibits forwarding the target data flow to the internal network 200 through the network interface.
[0189] Based on the attached Fig.11 The processing method shown, in some application scenarios, in order to reduce the amount of data sent by the gateway device to the intranet device that performs additional functions, the gateway device first parses, analyzes, extracts or counts the target data stream to obtain description information for describing the target data stream. The description information is also called metadata. Metadata is data about data, mainly information that describes data properties, used to support functions such as indicating storage location, historical data, resource search, file records, etc. Optionally, there are multiple ways and formats for generating description information, including formats supported by standard organizations and existing mainstream manufacturers, or formats customized by administrators. For example, the IP Flow Information Export (IPFIX) protocol format defined by the Internet Engineering Task Force (IETF), the NetFlow format, the sflow format, and the like.
[0190] The gateway device sends description information rather than the target data stream itself to the intranet device that performs additional functions, thereby reducing the amount of data transmitted between the gateway device and the intranet device. The specific implementation process is as follows Fig.12shown.
[0191] Attached Fig.12 This is a method for processing network services provided by an embodiment of the present application. Figure 1 The gateway device 300 in the example is executed when the Figure 2 , Attachment Figure 6 ~Attached Fig.10 After the step of sending the first indication message and the first software package to the first intranet device in the network service processing method, the attached Fig.12 The steps shown.
[0192] Step 121: The gateway device saves the correspondence between the identifier of the first intranet device and the first additional function.
[0193] Step 122: The gateway device obtains the traffic to be forwarded, and obtains a target data flow from the traffic to be forwarded, where the target data flow refers to a data flow on which the first additional function is to be executed.
[0194] Attached Fig.12 Step 121 and step 122 in the attached Fig.11 Step 111 and step 112 are similar and will not be described again here.
[0195] Step 123: The gateway device determines description information, where the description information is used to describe the target data flow.
[0196] Step 124: The gateway device sends description information to the first intranet device according to the correspondence between the identifier of the first intranet device and the first additional function.
[0197] Step 125: The gateway device receives the processing result of the description information by the first intranet device.
[0198] Step 126: The gateway device performs an action corresponding to the processing result of the description information by the first intranet device on the target data flow, and the action includes forwarding, warning or blocking.
[0199] Optionally, take the first additional function as a data flow security detection function as an example. The first intranet device is an additional Figure 1 In the intranet device 201, the gateway device is attached Figure 1The gateway device 300 in the gateway device 300. The gateway device 300 sends a first indication message and a software package Firewall.exe to the intranet device 201. After the intranet device 201 completes the installation of the software package Firewall.exe according to the first indication message, it executes the data flow security detection function taking the firewall as an example. The gateway device 300 records the correspondence between the intranet device 201 and the data flow security detection function. The predetermined policy configured in the gateway device 300 is to perform security detection on the unidirectional traffic sent from the external network to the internal network. That is, the target data flow is the unidirectional traffic sent from the external network to the internal network. After the gateway device 300 subsequently receives the data flow (i.e., the target data flow) sent by the external network 100 to the internal network 200 through the network interface, it extracts the description information of the target data flow. The description information includes a five-tuple information consisting of a source address, a source port number, a destination address, a destination port number, and a protocol type. Optionally, the description information also includes the content of some specified fields in the message header, etc. The gateway device 300 sends the description information to the intranet device 201. After the gateway device 300 receives the security detection result of the description information from the internal network device 201, if the security detection result indicates that the description information does not contain data that violates the firewall rules, the gateway device 300 forwards the target data stream to the internal network 200 through the network interface; if the security detection result indicates that the description information contains data that violates the firewall rules, the gateway device 300 blocks the target data stream and prohibits forwarding the target data stream to the internal network 200 through the network interface.
[0200] Accordingly, an embodiment of the present application provides a gateway device for executing the network service processing method provided by each of the above embodiments. Fig.13 is a schematic diagram of the structure of a gateway device provided in an embodiment of the present application. Optionally, Fig.13 The gateway device shown is Figure 1 The gateway device 300 in the application scenario shown, Figure 2 , Figure 6 ~Attached Fig.12 The gateway device in the process shown in FIG.
[0201] The processor 131 may be one or more CPUs, and the CPU may be a single-core CPU or a multi-core CPU.
[0202] The memory 132 includes, but is not limited to, random access memory (RAM), read only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), flash memory, or optical memory, etc. The memory 132 stores operating system code.
[0203] The network interface 133 may be a wired interface, such as a fiber distributed data interface (FDDI) or a Gigabit Ethernet (GE) interface; the network interface 63 may also be a wireless interface. The network interface 133 is used to receive data streams from the internal network and / or the external network, and communicate with the internal network devices in the internal network according to the instructions of the processor 131, and communicate with the servers in the external network.
[0204] Optionally, the processor 131 implements the method in the above embodiment by reading instructions stored in the memory 132, or the processor 131 may also implement the method in the above embodiment through internally stored instructions. In the case where the processor 131 implements the method in the above embodiment by reading instructions stored in the memory 132, the memory 132 stores instructions for implementing the method provided in the above embodiment of the present application.
[0205] After the processor 131 executes the instructions stored in the memory 132, the gateway device performs the following operations: identifying the type of the first intranet device, the first intranet device belonging to the internal network to which the gateway device is connected; the gateway device obtains a first software package based on the type of the first intranet device, the first software package being used to implement a first additional function; and sending a first indication message and the first software package to the first intranet device through the network interface 133, the first indication message being used to instruct the first intranet device to install the first software package and execute the first additional function.
[0206] The at least one processor 131 further executes the network service processing method described in the above method embodiment according to the corresponding relationship tables (such as Table 1, Table 2, Table 3, and Table 4 in the previous embodiment) stored in the memory 132. For more details on how the processor 131 implements the above functions, please refer to the description in the previous method embodiments, which will not be repeated here.
[0207] Optionally, the gateway device further includes a bus 134 , and the processor 131 and the memory 132 are usually connected to each other via the bus 134 , and may also be connected to each other in other ways.
[0208] Optionally, the gateway device further includes an input / output interface 135, which is used to connect to an output device, output a prompt message to the administrator to notify the administrator that the first intranet device can execute the first additional function, and output an alarm according to the processing result of the intranet device under appropriate conditions, etc. The output device includes but is not limited to a display, a printer, etc.
[0209] The input / output interface 135 is also used to connect to an input device to receive a confirmation message returned by the administrator in response to the prompt message. The input device includes but is not limited to a keyboard, a touch screen, a microphone, a Bluetooth module, and the like.
[0210] Attached Fig.13 For other additional functions that the gateway device shown can implement, and the interaction process with other network element devices (such as intranet devices or servers), please refer to the description of the gateway device in the method embodiment, which will not be repeated here.
[0211] The gateway device provided in the embodiment of the present application is used to execute the processing method of the network service provided in each of the above method embodiments. The gateway device itself does not need to perform additional functions, but acts as a management and control subject for realizing additional functions, controlling appropriate intranet devices to share the task of realizing additional functions. The main function of the gateway device is to identify the type of intranet device, send a software package for realizing appropriate additional functions to the intranet device according to the type of the intranet device, and instruct the intranet device to realize the additional functions after successfully installing the software package.
[0212] Fig.14 1 is a schematic diagram of a network service processing device provided in an embodiment of the present application. The processing device 14 includes a processing module 141 and a sending module 142. The processing device 14 is coupled to the gateway device in each of the above method embodiments, for example, integrated in the gateway device, and is a software or hardware component in the gateway device. Fig.14 The processing device shown is applied to the method embodiment of the appended Figure 1 In the scenario shown, the function of the gateway device is implemented.
[0213] The processing module 141 is used to identify the type of a first intranet device, where the first intranet device belongs to an internal network to which the gateway device is connected; and obtain a first software package based on the identified type of the first intranet device, where the first software package is used to implement a first additional function.
[0214] The sending module 142 is used to send a first indication message and the first software package to the first intranet device, where the first indication message is used to instruct the first intranet device to install the first software package and execute the first additional function.
[0215] Optionally, the processing module 141 obtains a first software package according to the type of the first intranet device, including: determining the performance of the first intranet device according to the type of the first intranet device, the performance including software capabilities and hardware capabilities, the software capabilities including whether the installation of the software package is supported, and the hardware capabilities including processor performance values and / or storage space size; obtaining the first software package according to the performance of the first intranet device, the performance of the first intranet device meeting the installation performance requirements of the first software package.
[0216] Optionally, before the sending module 142 sends the first indication message and the first software package to the first intranet device, the processing module 141 is further used to identify the type of the second intranet device, and the second intranet device belongs to the internal network. The processing module 141 determines the performance of the second intranet device according to the type of the second intranet device; obtains the second software package, and the performance of the second intranet device meets the installation performance requirements of the second software package. If the first software package and the second software package are the same software package, the gateway device selects the first intranet device from the first intranet device and the second intranet device to install the first software package.
[0217] Optionally, the device further includes a receiving module 143 .
[0218] After the sending module 142 sends the first indication message and the first software package to the first intranet device, the processing module 142 saves the correspondence between the identifier of the first intranet device and the first additional function.
[0219] The processing module 141 obtains a target data stream from the traffic to be forwarded received by the receiving module 143, and the target data stream is a data stream to be executed with the first additional function. The processing module 142 sends the target data stream to the first intranet device through the sending module 142 according to the correspondence between the identifier of the first intranet device and the first additional function, and receives the processing result of the target data stream by the first intranet device through the receiving module 143.
[0220] For additional functions that can be implemented by the processing module 141, the sending module 142 and the receiving module 143, and more details on implementing the above functions, please refer to the descriptions in the previous method embodiments, which will not be repeated here.
[0221] Attached Fig.14The device embodiments described are merely illustrative. For example, the division of the modules is merely a logical function division. There may be other division methods in actual implementation. For example, multiple modules or components may be combined or integrated into another system, or some features may be ignored or not executed. The functional modules in the various embodiments of the present application may be integrated into a processing module, or each module may exist physically separately, or two or more modules may be integrated into one module. Fig.14 The above modules can be implemented in the form of hardware or software functional units. For example, when software is used, the processing module 141, the sending module 142 and the receiving module 143 can be implemented by the attached Fig.13 The processor 131 in the processor reads the program code stored in the memory and generates a software function module to implement it. Fig.14 The above modules can also be implemented by different hardware in the gateway device, for example, the sending module 142 and the receiving module 143 are implemented by the attached Fig.13 The network interface 133 is implemented in the embodiment, and the processing module 141 is implemented by the attached Fig.13 The processing module 141 is implemented by using some processing resources in the processor 133 (such as other cores in a multi-core processor), or by using a field programmable gate array (FPGA) or a coprocessor or other programmable device. Obviously, the above functional modules can also be implemented in a combination of software and hardware. For example, the sending module 142 and the receiving module 143 are implemented by the network interface 133, and the processing module 141 is a software functional module generated by the CPU after reading the instructions stored in the memory.
[0222] Attached Fig.14 For more details on other additional functions that can be implemented by the device, the interaction process with other network element devices (such as intranet devices or servers), the technical effects that can be achieved, and how the identification module 141, the acquisition module 142 and the sending module 143 implement the above functions, please refer to the description of the gateway device in the previous method embodiments, which will not be repeated here.
[0223] The embodiment of the present application also provides a network service processing system, which includes a gateway device and at least one intranet device. The gateway device is used to connect the external network and the internal network. The at least one intranet device belongs to the internal network. Optionally, when the software package adopts a distributed storage method, the processing system also includes a server, and the server is deployed in the internal network or the external network. For more details on the implementation of the respective functions of the gateway device, the intranet device and the server in the processing system, and more details on the interaction process between them, please refer to the description of the gateway device in the previous method embodiments, which will not be repeated here.
[0224] Each embodiment in this specification is described in a progressive manner, and the same or similar parts between the embodiments can be referred to each other, and each embodiment focuses on the differences from other embodiments. In particular, for the system embodiment, since it is basically similar to the method embodiment, the description is relatively simple, and the relevant parts can be referred to the partial description of the method embodiment.
[0225] Those skilled in the art will understand that when software is used to implement various aspects of the embodiments of the present application, or possible implementations of various aspects, the above-mentioned various aspects, or possible implementations of various aspects can be implemented in whole or in part in the form of a computer program product. A computer program product refers to computer-readable instructions stored in a computer-readable medium. When the computer instructions are loaded and executed on a computer, the process or function described in the embodiments of the present application is generated in whole or in part.
[0226] The computer-readable medium may be a computer-readable signal medium or a computer-readable storage medium. The computer-readable storage medium includes, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared or semiconductor systems, devices or apparatuses, or any appropriate combination of the foregoing. For example, the computer-readable storage medium is a random access memory (RAM), a read only memory (ROM), an erasable programmable read only memory (EPROM) or a portable read only memory (CD-ROM).
[0227] Obviously, those skilled in the art can make various changes and modifications to the present invention without departing from the scope of the present invention. Thus, if these modifications and variations of the present application fall within the scope of the claims of the present invention, the present invention is also intended to include these modifications and variations.
Claims
1. A method for processing network services, It is characterized in that include: The second device receives the indication information sent by the first device, the first device is a gateway device connecting an external network and an internal network, the second device belongs to the internal network, and the type of the second device includes: a personal computer, a server, a mobile terminal, a printer, or a smart home device; The second device installs a software package of a first additional function according to the instruction information, wherein the first additional function is an additional function of the first device.
2. The method according to claim 1, It is characterized in that Also includes: The second device receives the software package sent by the first device.
3. The method according to claim 1, It is characterized in that Also includes: The second device receives the software package sent by the third device.
4. The method according to any one of claims 1 to 3, It is characterized in that Also includes: The second device performs the first additional function.
5. The method according to claim 4, It is characterized in that The second device executing the first additional function includes: The second device receives first information from the first device, where the first information includes a target data stream and / or metadata of the target data stream; The second device processes the first information according to the first additional function to obtain a processing result; The second device sends the processing result to the first device.
6. The method according to any one of claims 1 to 3, It is characterized in that The performance of the second device matches the software package, and the performance includes software capability and hardware capability.
7. The method according to any one of claims 1 to 3, It is characterized in that The type of the second device matches the software package.
8. The method according to claim 7, It is characterized in that The type of the second device is determined according to a media access control MAC address of the second device.
9. The method according to claim 7, It is characterized in that The type of the second device is determined according to the data flow forwarded by the second device.
10. The method according to any one of claims 1 to 3, It is characterized in that The first additional function includes: a security detection function, a network cache function, or a security sandbox function.
11. A method for processing network services, It is characterized in that include: The first device generates a first indication message; The first device sends the first indication message to the second device, the first indication message instructing the second device to install a software package of a first additional function, the first device is a gateway device connecting an external network and an internal network, the second device belongs to the internal network, the types of the second device include: personal computer, server, mobile terminal, printer, or smart home device, and the first additional function is an additional function of the first device.
12. The method according to claim 11, It is characterized in that The software package matches the capabilities of the second device, the capabilities including software capabilities and hardware capabilities.
13. The method according to claim 11, It is characterized in that The software package matches a type of the second device.
14. The method according to any one of claims 11 to 13, It is characterized in that Also includes: The first device sends first information to the second device, where the first information includes a target data stream and / or metadata of the target data stream; The first device receives a processing result sent by the second device, where the processing result is obtained by the second device executing the first additional function to process the first information.
15. The method according to claim 14, It is characterized in that Also includes: The first device performs an action corresponding to the processing result on the target data flow according to the processing result, and the action includes forwarding, alarming or blocking.
16. A network service processing device, It is characterized in that The processing device is applied to a first device, and includes a processing module and a sending module. The processing module is used to generate a first indication message; The sending module is used to send the first indication message to the second device, where the first indication message is used to instruct the second device to install a software package of a first additional function, the first device is a gateway device connecting an external network and an internal network, the second device belongs to the internal network, and the type of the second device includes: a personal computer, a server, a mobile terminal, a printer, or a smart home device, and the first additional function is an additional function of the first device.
17. The device according to claim 16, It is characterized in that The software package matches the capabilities of the second device, the capabilities including software capabilities and hardware capabilities.
18. The device according to claim 16, It is characterized in that The software package matches a type of the second device.
19. The device according to any one of claims 16 to 18, It is characterized in that The device also includes a receiving module. The sending module is further used to send first information to the second device, where the first information includes a target data stream and / or metadata of the target data stream; The receiving module is used to receive a processing result sent by the second device, where the processing result is obtained by the second device executing the first additional function to process the first information.
20. The device according to claim 19, It is characterized in that The processing module is further used to perform an action corresponding to the processing result on the target data flow according to the processing result, and the action includes forwarding, alarming or blocking.
21. A computer device, It is characterized in that The computer device comprises a network interface, a memory and a processor connected to the memory, The memory is used to store instructions; The processor is used to execute the instructions so that the computer device executes the method according to any one of claims 1 to 10, or the method according to any one of claims 11 to 15.
22. A network service processing system, It is characterized in that comprising a first device and a second device, The first device is used to perform the method according to any one of claims 11 to 15; The second device is used to execute the method according to any one of claims 1 to 10.
23. A computer readable medium, It is characterized in that The invention comprises a computer program, which, when executed on a computer, enables the computer to execute the method according to any one of claims 1 to 10, or the method according to any one of claims 11 to 15.
