A lightweight application recognition method and system

By acquiring and encoding the fingerprint features of network data streams on resource-constrained network devices, and combining this with CPU utilization for hierarchical identification, the problems of high resource consumption and low identification accuracy are solved, achieving efficient and real-time application identification.

CN123122840APending Publication Date: 2026-11-17ASPIRE TECH (SHENZHEN) LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611278999.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-08-21
Publication Date
2026-11-17

AI Technical Summary

Technical Problem

In existing technologies, the application of identification methods results in high resource consumption, poor identification accuracy, and low real-time performance on resource-constrained network devices, which cannot meet the network security needs of small businesses.

Method used

By acquiring the metadata, timing, and protocol fingerprints of network data streams, encoding is performed using lightweight sequence embedding networks, and layered identification is achieved by combining application signature libraries and CPU utilization. This enables lightweight application identification.

Benefits of technology

It improves the accuracy and real-time performance of application identification, reduces resource consumption, and is suitable for resource-constrained network devices, especially in network security scenarios for small businesses.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN123122840A_ABST
    Figure CN123122840A_ABST
Patent Text Reader

Abstract

This application discloses a lightweight application identification method and system, belonging to the field of network security technology. The method first acquires the network data stream of the target network device and extracts its metadata fingerprint, temporal fingerprint, and protocol fingerprint, where the temporal fingerprint includes at least a variable-length sequence fingerprint. Then, it encodes the variable-length sequence fingerprint using a lightweight sequence embedding network to obtain a corresponding fixed-length sequence fingerprint, and determines the temporal fingerprint after sequence embedding based on the fixed-length sequence fingerprint. Finally, based on the CPU utilization of the target network device, it uses a pre-stored application signature library, metadata fingerprint, protocol fingerprint, and the temporal fingerprint after sequence embedding to perform hierarchical identification processing on the target application corresponding to the network data stream, obtaining the identification result of the target application. When used on resource-constrained network devices, this method can effectively reduce application identification resource consumption, improve identification accuracy, and enhance the real-time performance of identification.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application belongs to the field of network security technology, specifically relating to a lightweight application identification method and system. Background Technology

[0002] Application identification is a key technology in the field of network security. It aims to identify and classify various network applications by analyzing network traffic data to support fine-grained traffic management, QoS control, and security protection. The need for application identification is growing, especially in small businesses with relatively low-configuration network equipment, where applications such as bandwidth management and application priority control require identification.

[0003] Currently, there are two main methods for application identification: the first is application identification based on deep packet inspection, which identifies the application type by parsing the application layer protocol content and using regular expressions to match feature strings. The second is application identification based on port numbers, which identifies the application type by the destination port number.

[0004] However, of the two methods mentioned above, the first method has high computational complexity, requiring packet-by-packet regular expression matching, typically resulting in 30%-50% CPU usage, high memory consumption, and frequent feature library updates. This makes it unsuitable for small businesses with relatively low-configuration network equipment, and the complex recognition process leads to insufficient real-time performance. The second method, while having lower resource consumption, suffers from the inability to distinguish between different applications on the same port (e.g., various web applications over HTTP) due to the widespread use of dynamic or standard ports, resulting in lower recognition accuracy. Therefore, there is an urgent need for an application recognition method that is suitable for scenarios with relatively low-configuration network equipment, has low resource consumption, high accuracy, and high real-time performance. Summary of the Invention

[0005] The purpose of this application is to provide a lightweight application recognition method and system that can solve the problems of high resource consumption, poor recognition accuracy, and low real-time performance in related technologies.

[0006] To solve the above-mentioned technical problems, this application is implemented as follows: In a first aspect, this application provides a lightweight application identification method for resource-constrained network devices, the method comprising: Obtain the network data stream of the target network device, and extract the metadata fingerprint, time sequence fingerprint and protocol fingerprint of the network data stream, wherein the time sequence fingerprint includes at least a variable-length sequence fingerprint; The variable-length sequence fingerprint is encoded using a lightweight sequence embedding network to obtain a corresponding fixed-length sequence fingerprint, and the temporal fingerprint after sequence embedding is determined based on the fixed-length sequence fingerprint. Based on the CPU utilization of the target network device, the target application corresponding to the network data stream is identified in a layered manner using the pre-stored application signature library, the metadata fingerprint, the protocol fingerprint, and the temporal fingerprint after sequence embedding processing, so as to obtain the identification result of the target application.

[0007] Secondly, this application provides a lightweight application identification system for resource-constrained network devices, the system comprising: A network data stream acquisition module is used to acquire the network data stream of a target network device and extract the metadata fingerprint, timing fingerprint, and protocol fingerprint of the network data stream, wherein the timing fingerprint includes at least a variable-length sequence fingerprint. The temporal fingerprint encoding processing module is used to encode the variable-length sequence fingerprint based on a lightweight sequence embedding network to obtain a corresponding fixed-length sequence fingerprint, and to determine the temporal fingerprint after sequence embedding based on the fixed-length sequence fingerprint. The identification module is used to perform hierarchical identification processing on the target application corresponding to the network data stream based on the CPU utilization rate of the target network device, using a pre-stored application signature library, the metadata fingerprint, the protocol fingerprint, and the temporal fingerprint after sequence embedding processing, to obtain the identification result of the target application.

[0008] Thirdly, this application provides an electronic device, including a processor, a memory, and a computer program stored in the memory and executable on the processor, wherein the computer program, when executed by the processor, performs the following steps: Obtain the network data stream of the target network device, and extract the metadata fingerprint, time sequence fingerprint and protocol fingerprint of the network data stream, wherein the time sequence fingerprint includes at least a variable-length sequence fingerprint; The variable-length sequence fingerprint is encoded using a lightweight sequence embedding network to obtain a corresponding fixed-length sequence fingerprint, and the temporal fingerprint after sequence embedding is determined based on the fixed-length sequence fingerprint. Based on the CPU utilization of the target network device, the target application corresponding to the network data stream is identified in a layered manner using the pre-stored application signature library, the metadata fingerprint, the protocol fingerprint, and the temporal fingerprint after sequence embedding processing, so as to obtain the identification result of the target application.

[0009] Fourthly, this application provides a computer-readable storage medium on which a computer program is stored, and which, when executed by a processor, performs the following steps: Obtain the network data stream of the target network device, and extract the metadata fingerprint, time sequence fingerprint and protocol fingerprint of the network data stream, wherein the time sequence fingerprint includes at least a variable-length sequence fingerprint; The variable-length sequence fingerprint is encoded using a lightweight sequence embedding network to obtain a corresponding fixed-length sequence fingerprint, and the temporal fingerprint after sequence embedding is determined based on the fixed-length sequence fingerprint. Based on the CPU utilization of the target network device, the target application corresponding to the network data stream is identified in a layered manner using the pre-stored application signature library, the metadata fingerprint, the protocol fingerprint, and the temporal fingerprint after sequence embedding processing, so as to obtain the identification result of the target application.

[0010] The technical solution provided in this application may include the following beneficial effects: This application provides a lightweight application identification method. The method first acquires the network data stream of the target network device and extracts its metadata fingerprint, temporal fingerprint, and protocol fingerprint, with the temporal fingerprint including at least a variable-length sequence fingerprint. Then, it encodes the variable-length sequence fingerprint using a lightweight sequence embedding network to obtain a corresponding fixed-length sequence fingerprint, and determines the temporal fingerprint after sequence embedding based on the fixed-length sequence fingerprint. Finally, based on the CPU utilization of the target network device, it uses a pre-stored application signature library, metadata fingerprint, protocol fingerprint, and the temporal fingerprint after sequence embedding to perform hierarchical identification of the target application corresponding to the network data stream, obtaining the identification result of the target application. By extracting three layers of fingerprint features, network data stream features can be obtained more comprehensively from different granularities, which is beneficial to improving the accuracy of subsequent application identification. Encoding the variable-length sequence fingerprint into a fixed-length sequence fingerprint using a lightweight sequence embedding network, with a total parameter size of less than 10KB, can significantly reduce CPU utilization. While effectively reducing resource consumption, it adapts to the input requirements of subsequent processes, which is beneficial to improving the data processing efficiency of application identification and enhancing the stability of feature representation. By employing layered identification processing, the depth of application identification can be dynamically adjusted according to system load, enabling multi-level collaborative identification. When network devices are under relatively high load, non-critical identification levels are reduced, thus ensuring the basic identification capability and stability of the method. Furthermore, based on the layered identification method of this application, the single-stream identification latency is less than 0.5ms, and concurrent processing capabilities are improved, meeting the requirements for identification accuracy and real-time performance. In addition, this application effectively improves the identification capability of encrypted traffic through protocol fingerprint feature extraction. Attached Figure Description

[0011] Figure 1 This is a flowchart illustrating a lightweight application identification method disclosed in an embodiment of this application; Figure 2 This is a schematic diagram illustrating the working principle of the lightweight sequence embedding network disclosed in the embodiments of this application; Figure 3 This is a schematic diagram illustrating the working principle of layered identification disclosed in the embodiments of this application; Figure 4 This is a schematic diagram illustrating the working principle of the adaptive multi-granularity locality-sensitive hash index disclosed in the embodiments of this application; Figure 5 This is a schematic diagram illustrating the working principle of the double-buffered hot update disclosed in the embodiments of this application; Figure 6 This is a schematic diagram of the structure of a lightweight application recognition system disclosed in an embodiment of this application; Figure 7 This is a schematic diagram illustrating the working principle of the lightweight application recognition system disclosed in the embodiments of this application; Figure 8 This is a schematic diagram of the structure of an electronic device disclosed in an embodiment of this application.

[0012] Explanation of reference numerals in the attached figures: 210: Network data stream acquisition module, 220: Time-series fingerprint encoding processing module, 230: Identification module, 301: Processor, 302: Memory, 303: Power supply, 304: Wired or wireless network interface, 305: Input / output interface, 306: Keyboard. Detailed Implementation

[0013] To make the objectives, technical solutions, and advantages of this application clearer, the technical solutions of this application will be clearly and completely described below in conjunction with specific embodiments and corresponding drawings. Obviously, the described embodiments are only a part of the embodiments of this application, and not all of them. All other embodiments obtained by those skilled in the art based on the embodiments of this application without creative effort are within the scope of protection of this application.

[0014] The technical solutions disclosed in the various embodiments of this application are described in detail below with reference to the accompanying drawings.

[0015] Example 1 like Figure 1 As shown in the embodiments of this specification, a lightweight application identification method is provided. The execution subject of this method can be a terminal device or a server. The terminal device can be a mobile terminal device such as a mobile phone or tablet computer, or a computer device such as a laptop or desktop computer. The server can be a single server or a server cluster composed of multiple servers. The method specifically includes the following steps: In step S1, the network data stream of the target network device is obtained, and the metadata fingerprint, timing fingerprint and protocol fingerprint of the network data stream are extracted. The timing fingerprint includes at least a variable-length sequence fingerprint.

[0016] In small business scenarios, network devices are typically configured with lower specifications due to cost constraints. However, enterprises have an increasing need for application identification, including bandwidth management, application priority control, and security policy enforcement, all of which require analysis of network data flows within network devices for application identification. Therefore, the method in this application is used for resource-constrained network devices, which can also be understood as low-configuration network devices. It is primarily used in the field of small business network security, specifically referring to network devices with a CPU frequency of less than or equal to 1 GHz and memory of less than or equal to 512 MB. These can be low-configuration hardware firewalls, edge gateways, IoT gateways, etc.

[0017] All performance indicators in this application are based on actual measurements in a standard test environment, namely: the CPU of the test network device has a main frequency of 800MHz and the memory is 256MB; the test network data stream contains more than 50 mainstream plaintext / encrypted applications, and the traffic covers all business hours in the morning, noon and evening.

[0018] The metadata fingerprint of a network data stream includes: a five-tuple of information about the network data stream, as well as a statistical summary of the number of packets, total bytes, and stream duration. The five-tuple information includes: source IP address, destination IP address, source port number, destination port number, and transport layer protocol.

[0019] The temporal fingerprint of a network data stream includes: size sequence pattern information and direction sequence pattern information of the first N data packets in the network data stream, where N is a natural number and its value is determined according to the characteristics of the network data stream. Specifically, the size sequence pattern information can be obtained by discretizing and encoding the data packet size, and the direction sequence pattern information can be obtained from the transmission direction of each data packet, including client-to-server and server-to-client directions.

[0020] In implementation, the value of N can be 4 ≤ N ≤ 16, and the specific value is adjusted according to the characteristics of the network data stream, with N=8 being the preferred value. When determining the size sequence pattern information of the first N data packets in the network data stream, the sizes of the first N data packets can be obtained by performing 8-level discretization encoding (3-bit binary). For example, the packet size uses 8-level discretization encoding, and the mapping table between the discretization interval and the 3-bit binary encoding is shown in Table 1 below.

[0021]

[0022]

[0023] When determining the direction sequence pattern information in a network data stream, the direction of the network data stream from the client to the server can be defined as 0, and the direction of the network data stream from the server to the client can be defined as 1.

[0024] The temporal fingerprint of the network data stream of the target network device extracted in this application includes at least a variable-length sequence fingerprint A, which is a temporal feature sequence extracted based on the network data stream in the time dimension and whose sequence length changes dynamically with the network data stream. It may also include a fixed-length sequence fingerprint B, which is a temporal feature sequence with a fixed length extracted based on the network data stream in the time dimension.

[0025] Protocol fingerprints for network data flows include: TLS (Transport Layer Security) handshake fingerprints, TCP / IP (Transmission Control Protocol / Internet Protocol) protocol stack fingerprints, and HTTP (HyperText Transfer Protocol) application layer fingerprints.

[0026] If the network data stream of the target network device is an encrypted data stream, the protocol fingerprint of the network data stream is extracted by extracting the TLS handshake features of the encrypted data stream. The TLS handshake features include: JA3 fingerprint, SNI (Server Name Indication) information, and ALPN (Application-Layer Protocol Negotiation) information.

[0027] If the network data stream of the target network device is an unencrypted data stream, then extracting the protocol fingerprint of the network data stream includes: extracting the TCP / IP protocol stack fingerprint or the HTTP application layer fingerprint of the network data stream, etc.

[0028] See also Figure 1 As can be seen, in step S2, the variable-length sequence fingerprint is encoded based on the lightweight sequence embedding network to obtain the corresponding fixed-length sequence fingerprint, and the temporal fingerprint after sequence embedding is determined based on the fixed-length sequence fingerprint.

[0029] Here, a lightweight sequence embedding network is used to encode the variable-length sequence fingerprint A to obtain the corresponding fixed-length sequence fingerprint A. 1 The temporal fingerprint determined by the sequence embedding process in step S2 includes: a fixed-length sequence fingerprint A corresponding to a variable-length sequence fingerprint A. 1 And fixed-length sequence fingerprint B from the original time-series fingerprint extracted based on network data streams.

[0030] In practice, variable-length sequence fingerprints can be truncated, padded, statistically aggregated, and encoded using models to obtain corresponding fixed-length sequence fingerprints, which can then be input into machine learning models for processing or comparison.

[0031] In step S3, based on the CPU utilization rate of the target network device, the target application corresponding to the network data stream is identified in a hierarchical manner using the pre-stored application signature library, metadata fingerprint, protocol fingerprint, and time sequence fingerprint after sequence embedding processing, so as to obtain the identification result of the target application.

[0032] In implementation, target applications within the target network device can be hierarchically identified based on the device's CPU utilization. For example, when CPU utilization is high (i.e., high load), pre-stored application signature libraries, metadata fingerprints, protocol fingerprints, and time-series fingerprints after sequence embedding can be used to perform fewer hierarchical identifications (e.g., level one or level two identification) to save resources and improve the real-time performance of application identification. When CPU utilization is low (i.e., low load), more hierarchical identifications can be performed, resulting in more refined identification results. This approach enables dynamic, multi-level collaborative hierarchical identification based on load awareness, which helps ensure basic identification capabilities, improve identification stability, and enhance real-time performance while maintaining accuracy.

[0033] Furthermore, the processing in step S2 above can take many forms. The following provides an optional processing method, which can be found in the following steps S21-S23: In step S21, the discretized encoded data packet size sequence pattern information in the variable-length sequence fingerprint is mapped to a specified low-dimensional vector space using a learnable embedding matrix.

[0034] An 8×16-dimensional learnable embedding matrix (approximately 512 bytes) can be used to map the discretized packet size encoding to a low-dimensional vector space (e.g., a 32-dimensional vector space). The embedding matrix is ​​orthogonally initialized, ensuring that the row vectors are pairwise orthogonal during initialization, thereby improving feature representation capabilities and thus enhancing the accuracy of application recognition.

[0035] In step S22, the embedding vectors at each position in the variable-length sequence fingerprint are weighted and accumulated based on the exponentially decaying position weights to obtain the accumulation result.

[0036] When performing position-aware accumulation processing in step S22, exponentially decaying position weights can be used to weight and accumulate the embedding vectors at each position in the variable-length sequence. The weighting formula is: Among them, the attenuation coefficient The value is 0.1. The direction correction factor is positive (+) for network data flow from the client to the server and negative (+) for network data flow from the server to the client.

[0037] In step S23, the accumulated result is mapped to a specified low-dimensional vector space by the lightweight activation function of the lightweight sequence embedding network to obtain a fixed-length sequence fingerprint corresponding to the variable-length sequence fingerprint.

[0038] The nonlinear transformation is performed in step S23, with a weight matrix of 16×32, approximately 2KB. The lightweight activation function can be a simplified version of Swish, which helps to further reduce resource consumption while ensuring the accuracy of the mapping results. In this embodiment, the total number of parameters in the lightweight sequence embedding network is less than 10KB, significantly reducing the resource consumption of resource-constrained network devices. Furthermore, orthogonal initialization effectively improves the expressive power of the embedding space.

[0039] A schematic diagram illustrating the working principle of the lightweight sequence embedding network disclosed in this application can be found in [reference needed]. Figure 2 As shown. By Figure 2 As can be seen, the variable-length sequence fingerprint is first input into the input layer of the lightweight sequence embedding network, and then processed by the position-aware accumulation of the position-aware embedding layer, the normalization layer, and the nonlinear transformation layer, which maps the accumulation result to the specified low-dimensional vector space through the lightweight activation function. Finally, the low-dimensional feature vector is output (the figure takes a 32-dimensional feature vector as an example). The total number of parameters of the lightweight sequence embedding network in the entire process is about 3KB, which is much smaller than that of traditional deep learning networks.

[0040] Furthermore, the processing in step S3 above can take many forms. The following is one optional processing method, which can be found in the following steps S31-S35: In step S31, based on the pre-stored application signature library, metadata fingerprint, protocol fingerprint, and time-series fingerprint after sequence embedding processing, the levels for hierarchical identification of the target application are determined. The levels, in ascending order of identification level, include: Level 1 based on port matching, Level 2 based on metadata classification, Level 3 based on time-series matching, and Level 4 based on protocol analysis. Corresponding to these ascending identification levels, the required latency for each level also increases progressively; that is, the identification latency increases at each level.

[0041] In implementation, the first level can be labeled as port matching level or P0 level, the second level can be labeled as metadata classification level or P1 level, the third level can be labeled as timing matching level or P2 level, and the fourth level can be labeled as protocol analysis level or P3 level.

[0042] In step S32, if the CPU utilization rate of the target network device is less than the first CPU utilization rate threshold, the target application is subjected to hierarchical identification processing from the first level to the fourth level to obtain the identification result of the target application.

[0043] In step S33, if the CPU utilization rate of the target network device is greater than or equal to the first CPU utilization rate threshold and less than the second CPU utilization rate threshold, then the target application is subjected to hierarchical identification processing from the first level to the third level to obtain the identification result of the target application.

[0044] In step S34, if the CPU utilization rate of the target network device is greater than or equal to the second CPU utilization rate threshold and less than the third CPU utilization rate threshold, then the target application is subjected to hierarchical identification processing from the first level to the second level to obtain the identification result of the target application.

[0045] In step S35, if the CPU utilization rate of the target network device is greater than or equal to the third CPU utilization rate threshold, the target application is subjected to the first level of hierarchical identification processing to obtain the identification result of the target application.

[0046] The first CPU utilization threshold can be set to 30%, the second CPU utilization threshold to 60%, and the third CPU utilization threshold to 80%. Based on steps S31-S35 above, when the CPU utilization is <30%, the target application undergoes all four levels of hierarchical identification processing (P0+P1+P2+P3); when 30% ≤ CPU utilization < 60%, the target application undergoes three levels of hierarchical identification processing (P0+P1+P2); when 60% ≤ CPU utilization < 80%, the target application undergoes two levels of hierarchical identification processing (P0+P1); and when the CPU utilization is ≥80%, the target application undergoes only P0 level hierarchical identification processing.

[0047] The final identification result of the target application is determined based on the identification results from Level 1 to Level 4. The identification result can include: application type, identification confidence level, and identification level. The identification level is the identification result obtained from Level 1. The confidence score can range from [0,1], rounded to two decimal places, or it can be converted to a score of 0-100. Subsequent processes can execute corresponding QoS (Quality of Service) policies (such as bandwidth limiting, priority adjustment, etc.) and security policies (such as access control, threat blocking, etc.) based on the identification results.

[0048] Further, step S31 includes the following process: In step S311, the destination port number of the network data stream is determined based on the metadata fingerprint of the network data stream. Based on the determined destination port number and the mapping relationship between the service ports pre-stored in the application signature library, the target application is identified at the first level.

[0049] If a service port matching the destination port number is identified in the pre-stored service port mapping relationship in the application signature library, it is considered a match, and the first-level recognition result is directly output. First-level application recognition can cover 30%-40% of traditional applications, with a measured accuracy of over 99% in a standard testing environment.

[0050] In step S312, the target application is identified at a second level based on the metadata fingerprint of the network data stream and the pre-trained lightweight decision tree. The identification results of the second level include the classification confidence of the target application.

[0051] In implementation, the depth of a lightweight decision tree can be set to 3-5, the number of nodes to less than 50, and the lightweight decision tree can use metadata fingerprint statistical features as input data and the Gini coefficient as the node splitting criterion.

[0052] In step S313, if the classification confidence level of the target application is less than the preset confidence threshold, the target application is identified at the third level based on the similarity between the temporal fingerprint of the network data stream and the temporal fingerprint of the application stored in the application signature library.

[0053] The preset confidence threshold is determined based on the specific application identification scenario and can be set to 0.75. According to steps S312 and S313, when the classification confidence of the target application is greater than or equal to the preset confidence threshold, the second-level identification result is directly output; when the classification confidence of the target application is less than the preset confidence threshold, the third-level identification is performed on the target application. When identifying applications based on the similarity between the temporal fingerprint of the network data stream and the temporal fingerprint of applications pre-stored in the application signature library, if the similarity between the two reaches a preset first similarity threshold, the third-level identification result is output.

[0054] In step S314, the target application is identified at the fourth level based on the similarity between the protocol fingerprint of the network data stream and the protocol fingerprint of the application pre-stored in the application signature library.

[0055] When identifying applications based on the similarity between the protocol fingerprint of the network data stream and the protocol fingerprint of the application pre-stored in the application signature library, if the similarity between the two reaches a preset second similarity threshold, the fourth level of identification result is output.

[0056] For encrypted data streams, the cumulative coverage of Level 4 application identification according to step S314 can reach 90%-95%, and the actual accuracy in the standard test environment is greater than 85%.

[0057] Furthermore, the processing in step S313 above can be varied. One optional processing method is provided below, which can be found in the following processing: Based on the adaptive multi-granularity locality-sensitive hash index, the temporal fingerprint of the network data stream is matched with the temporal fingerprint of the application pre-stored in the application signature library. The projection matrix in the adaptive multi-granularity locality-sensitive hash index is an optimized projection matrix generated based on discriminant analysis.

[0058] The cumulative coverage of Level 3 application identification based on adaptive multi-granularity locality-sensitive hash index can reach 80%-90%, and the measured accuracy in a standard test environment is greater than 90%.

[0059] Furthermore, the method for constructing an adaptive multi-granularity locality-sensitive hash index may include the following process: In step A1, an optimized projection matrix is ​​generated by using a pre-trained adaptive multi-granularity locality-sensitive hash index model based on the inter-class scatter matrix and intra-class scatter matrix of different application samples through discriminant analysis. The pre-trained adaptive multi-granularity locality-sensitive hash index model is a model trained on a variety of different application samples with labels and a preset loss function. The preset loss function makes the vectors of the same type of application close after projection, and the vectors of different types of applications far apart after projection.

[0060] In step A2, the hash code of each application signature template corresponding to the application signature library is determined based on the optimized projection matrix.

[0061] In step A3, the effective number of bits in the hash code is dynamically adjusted based on the frequency of occurrence of the application category to which each application signature template belongs, resulting in a dynamically adjusted hash code.

[0062] Dynamically adjusting the effective number of bits in a hash code allows you to control the use of more hash bits (i.e., finer hash buckets) for high-frequency applications and fewer hash bits (i.e., coarser hash buckets) for low-frequency applications. In implementation, 16 hash bits can be used when the frequency is greater than 1000 times; 14 hash bits can be used when the frequency is 100-1000 times; 12 hash bits can be used when the frequency is 10-100 times; and 10 hash bits can be used when the frequency is less than 10 times. For example, high-frequency applications can use 16 hash bits, and low-frequency applications can use 8 hash bits, thus achieving adaptive granularity scaling.

[0063] In step A4, an adaptive multi-granularity locality-sensitive hash index is generated based on the dynamically adjusted hash code, and the adaptive multi-granularity locality-sensitive hash index is stored using index buckets.

[0064] When performing third-level identification of target applications using the adaptive multi-granularity local sensitive hash index constructed based on steps A1-A4 above, a multi-probe query approach can be adopted. Specifically, firstly, the master hash code of the query feature vector is calculated. Then, based on this master hash code, a perturbation hash code with a Hamming distance less than or equal to a preset probe level is generated. Next, all candidate buckets are queried. Finally, the fine similarity of the candidate application signature templates is calculated, resulting in a preset number of application signature templates with high similarity ranking. The identification result is determined based on the application signature template with the highest similarity. The fine similarity of the candidate application signature templates can be obtained by weighting cosine similarity and normalized Euclidean distance. The preset number of application signature templates can be the top three ranked application signature templates.

[0065] The schematic diagram illustrating the working principle of the adaptive multi-granularity locality-sensitive hash index in this embodiment can be found in [link to previous document]. Figure 4 .

[0066] Furthermore, the method for determining CPU utilization can be as follows: The CPU utilization of the target network device is sampled based on a preset sampling period, and the current CPU utilization of the target network device is determined based on the results of M consecutive sampling periods. For example, the CPU utilization of the target network device can be sampled based on a sampling period of 1 second, and the average of the CPU utilization rates over three consecutive sampling periods can be used to obtain the current CPU utilization of the target network device. This method can further improve the accuracy of the obtained CPU utilization of the target network device, thereby improving the accuracy of application identification.

[0067] The schematic diagram illustrating the working principle of hierarchical identification of target applications in this embodiment can be found in [reference]. Figure 3 , Figure 3 The feature vector in the sequence refers to the temporal fingerprint feature vector after sequence embedding processing. Figure 3 It can be seen that, through P0-level application recognition, the test coverage can reach 30%-40%, the recognition latency is less than 1us, and the recognition accuracy is greater than 99%; through P1-level application recognition, the test coverage can be increased by 30%, the recognition latency is less than 5us, and the recognition accuracy is greater than 95%; through P2-level application recognition, the test coverage can be increased by 20%, the recognition latency is less than 20us, and the recognition accuracy is greater than 90%; through P3-level application recognition, the test coverage can be increased by 5%-10%, the recognition latency is less than 50us, and the recognition accuracy is greater than 85%.

[0068] Furthermore, the lightweight application identification method in this embodiment also includes step S4: incrementally updating the application signature library by maintaining the online real-time identification buffer and the offline update buffer in the application signature library and performing atomic pointer switching operations.

[0069] Specifically, step S5 may include the following process: In step S51, the online real-time recognition buffer and offline update buffer in the application signature library are maintained.

[0070] The online real-time recognition buffer in the application signature library is an active model used for real-time application recognition; the offline update buffer in the application signature library is a shadow model used for receiving updates to the application, thus achieving double buffering maintenance.

[0071] In step S52, the incremental update patch is received from the cloud.

[0072] The incremental update patch contains application signature template information (less than 100KB) that has been added, modified, or deleted. The patch is in JSON format and contains four types of fields: template ID, feature vector, hash code, and operation type.

[0073] In step S53, the incremental patch is applied to the shadow model, the hash index structure is updated, and the updated shadow model is obtained.

[0074] In step S54, the integrity of the updated shadow model is verified.

[0075] The MD5 hash verification algorithm can be used to verify the integrity of the updated shadow model. If the verification fails, the incremental patch should be discarded.

[0076] In step S55, an atomic switch is performed between the online real-time identification buffer and the offline update buffer.

[0077] This involves atomic switching between the active model and the shadow model. The atomic pointer switching operation, coupled with concurrent read-write locks, ensures that there is no data contention during the switching process. The switching latency is less than 1 millisecond, enabling zero-packet-loss updates and greatly improving the accuracy and reliability of application identification.

[0078] The schematic diagram illustrating the working principle of the double-buffered hot update disclosed in this application can be found in [reference needed]. Figure 5 As shown.

[0079] In summary, the lightweight application identification method in this embodiment, based on data processing steps such as network data stream reception, fingerprint extraction, sequence embedding, hierarchical identification, adaptive LSH index query, result output, and incremental hot updating, can achieve accurate and real-time identification of target applications on resource-constrained target devices. To meet the real-time identification requirements of applications, fast path processing can be implemented in the Linux kernel via eBPF / XDP in the software implementation.

[0080] Example 2 The above are lightweight application identification methods provided in the embodiments of this specification. Based on the same idea, the embodiments of this specification also provide a lightweight application identification system, such as... Figure 6 As shown.

[0081] This lightweight application recognition system includes: The network data stream acquisition module 210 is used to acquire the network data stream of the target network device and extract the metadata fingerprint, timing fingerprint and protocol fingerprint of the network data stream. The timing fingerprint includes at least a variable-length sequence fingerprint. The temporal fingerprint encoding processing module 220 is used to encode variable-length sequence fingerprints based on a lightweight sequence embedding network to obtain corresponding fixed-length sequence fingerprints, and to determine the temporal fingerprint after sequence embedding based on the fixed-length sequence fingerprints. The identification module 230 is used to perform hierarchical identification processing on the target application corresponding to the network data stream based on the CPU utilization rate of the target network device, using a pre-stored application signature library, metadata fingerprint, protocol fingerprint, and time sequence fingerprint after sequence embedding processing, to obtain the identification result of the target application.

[0082] In implementation, the network data stream acquisition module 210 is equipped with a data transmission interface for receiving network data streams from the target network device. This data transmission interface must meet standardized data formats and communication protocols to ensure the accuracy and compatibility of data transmission. It may include NetFlow / sFlow interfaces, mirrored traffic interfaces, and eBPF / XDP kernel interfaces. Based on these data transmission interfaces, information such as 5-tuples, packet statistics, and TLS characteristic standard fields are uniformly parsed.

[0083] Furthermore, if the network data stream of the target network device is an encrypted data stream, the protocol fingerprint of the network data stream extracted by the network data stream acquisition module 210 includes: extracting the TLS handshake features of the encrypted data stream, the TLS handshake features including: JA3 fingerprint, server name indication information and application layer protocol negotiation information.

[0084] Furthermore, the temporal fingerprint extracted by the network data stream acquisition module 210 includes: size sequence pattern information and direction sequence pattern information of the first N data packets in the network data stream, where N is a natural number and the value of N is determined according to the characteristics of the network data stream, and the size sequence pattern information is obtained by discretizing the data packet size.

[0085] Accordingly, the time-series fingerprint encoding processing module 220 includes: The encoding embedding unit uses a learnable embedding matrix to map the data packet size sequence pattern information after discretization and encoding in the variable-length sequence fingerprint to a specified low-dimensional vector space. The location-aware accumulation unit is used to perform weighted accumulation processing on the embedding vectors of each position in the variable-length sequence fingerprint based on the exponentially decaying location weights to obtain the accumulation result; The nonlinear transformation unit is used to map the accumulated result to a specified low-dimensional vector space through the lightweight activation function of the lightweight sequence embedding network, so as to obtain a fixed-length sequence fingerprint corresponding to the variable-length sequence fingerprint.

[0086] Furthermore, the identification module 230 includes: The hierarchical processing level determination unit is used to determine the level for hierarchical identification processing of the target application based on the pre-stored application signature library, metadata fingerprint, protocol fingerprint, and temporal fingerprint after sequence embedding processing. The levels are arranged in order from low to high according to the identification delay time: the first level based on port matching, the second level based on metadata classification, the third level based on temporal matching, and the fourth level based on protocol analysis. The hierarchical identification control unit is used to perform hierarchical identification processing of the target application from the first level to the fourth level when the CPU utilization rate of the target network device is less than the first CPU utilization rate threshold, so as to obtain the identification result of the target application. The hierarchical identification control unit is also used to perform hierarchical identification processing from the first level to the third level on the target application when the CPU utilization rate of the target network device is greater than or equal to the first CPU utilization rate threshold and less than the second CPU utilization rate threshold, so as to obtain the identification result of the target application. The hierarchical identification control unit is also used to perform hierarchical identification processing from the first level to the second level on the target application when the CPU utilization rate of the target network device is greater than or equal to the second CPU utilization rate threshold and less than the third CPU utilization rate threshold, so as to obtain the identification result of the target application. The hierarchical identification control unit is also used to perform first-level hierarchical identification processing on the target application when the CPU utilization rate of the target network device is greater than or equal to the third CPU utilization rate threshold, so as to obtain the identification result of the target application.

[0087] Furthermore, the hierarchical processing level determination unit includes: The port matching and determination subunit is used to determine the destination port number of the network data stream based on the metadata fingerprint of the network data stream, and to perform first-level identification of the target application based on the determined destination port number and the mapping relationship between the service ports pre-stored in the application signature library. The metadata classification determination subunit is used to perform second-level identification of the target application based on the metadata fingerprint of the network data stream and the pre-trained lightweight decision tree. The identification results of the second-level identification include the classification confidence of the target application. The temporal matching determination subunit is used to perform third-level identification of the target application based on the similarity between the temporal fingerprint of the network data stream and the temporal fingerprint of the application pre-stored in the application signature library when the classification confidence of the target application is less than the preset confidence threshold. The protocol analysis determines the sub-unit, which is used to perform fourth-level identification of the target application based on the similarity between the protocol fingerprint of the network data stream and the protocol fingerprint of the application pre-stored in the application signature library.

[0088] Furthermore, the temporal matching determination subunit is used to perform similarity matching between the temporal fingerprint of the network data stream and the temporal fingerprint of the application pre-stored in the application signature library based on the adaptive multi-granularity local sensitive hash index. The projection matrix in the adaptive multi-granularity local sensitive hash index is an optimized projection matrix generated based on discriminant analysis.

[0089] Furthermore, the time-series matching determination subunit includes: an adaptive multi-granularity locality-sensitive hash index construction unit. The adaptive multi-granularity locality-sensitive hash index construction unit includes: An optimized projection matrix generation subunit is used to generate an optimized projection matrix by using a pre-trained adaptive multi-granularity locality-sensitive hash index model based on the inter-class scatter matrix and intra-class scatter matrix of different application samples through discriminant analysis. The pre-trained adaptive multi-granularity locality-sensitive hash index model is a model trained on a variety of different application samples with labels and a preset loss function. The preset loss function makes the vectors of the same type of application close after projection, and the vectors of different types of applications far apart after projection. The hash encoding calculation subunit is used to determine the hash encoding of each application signature template corresponding to the application signature library based on the optimized projection matrix; The adaptive quantization subunit is used to dynamically adjust the effective number of bits in the hash code based on the frequency of occurrence of the application category to which each application signature template belongs, so as to obtain the dynamically adjusted hash code; The index generation and storage subunit is used to generate an adaptive multi-granularity locality-sensitive hash index based on the dynamically adjusted hash code, and to store the adaptive multi-granularity locality-sensitive hash index using index buckets.

[0090] Furthermore, this lightweight application recognition system also includes: The incremental update module is used to perform incremental updates to the application signature library by maintaining the online real-time recognition buffer and the offline update buffer in the application signature library and performing atomic pointer switching operations.

[0091] Furthermore, the incremental update module includes: A dual-buffer maintenance unit is used to maintain the online real-time recognition buffer and the offline update buffer in the application signature library; The incremental update patch receiving unit is used to receive incremental update patches distributed from the cloud. The shadow model update unit is used to apply incremental patches to the shadow model, update the hash index structure, and obtain the updated shadow model. The integrity verification unit is used to verify the integrity of the updated shadow model; The atomic switching unit is used to perform atomic switching between the online real-time identification buffer and the offline update buffer.

[0092] The schematic diagram illustrating the working principle of the lightweight application recognition system in this embodiment can be found in [reference needed]. Figure 7 For parts not described in detail in this embodiment, please refer to [link to relevant documentation]. Figures 1-5 The first embodiment shown can be used as a reference between the two embodiments, and will not be described in detail here.

[0093] Example 3 The above describes a lightweight application recognition system provided in the embodiments of this specification. Based on the same idea, the embodiments of this specification also provide an electronic device, such as... Figure 8 As shown. Electronic devices can vary considerably due to differences in configuration or performance, and may include one or more processors 301 and memory 302. Memory 302 may store one or more application programs or data. Memory 302 may be temporary or persistent storage. The application programs stored in memory 302 may include one or more modules (not shown), each module may include a series of computer-executable instructions for the electronic device. Furthermore, processor 301 may be configured to communicate with memory 302 and execute the series of computer-executable instructions in memory 302 on the electronic device. The electronic device may also include one or more power supplies 303, one or more wired or wireless network interfaces 304, one or more input / output interfaces 305, and one or more keyboards 306.

[0094] Specifically, in this embodiment, the electronic device includes a memory and one or more programs, wherein one or more programs are stored in the memory, and one or more programs may include one or more modules, and each module may include a series of computer-executable instructions for use in the electronic device, and is configured to be executed by one or more processors. The one or more programs include computer-executable instructions for performing the following: Obtain the network data stream of the target network device and extract the metadata fingerprint, time sequence fingerprint and protocol fingerprint of the network data stream. The time sequence fingerprint includes at least a variable-length sequence fingerprint. A lightweight sequence embedding network is used to encode variable-length sequence fingerprints to obtain corresponding fixed-length sequence fingerprints, and the temporal fingerprint after sequence embedding is determined based on the fixed-length sequence fingerprints. Based on the CPU utilization of the target network device, the target application corresponding to the network data stream is identified in a hierarchical manner by using the pre-stored application signature library, metadata fingerprint, protocol fingerprint, and time sequence fingerprint after sequence embedding processing, and the identification result of the target application is obtained.

[0095] Example 4 The above describes a lightweight application recognition system provided in the embodiments of this specification. Based on the same idea, the embodiments of this specification also provide a computer-readable storage medium storing a computer program, which, when executed by a processor, performs the following steps: Obtain the network data stream of the target network device and extract the metadata fingerprint, time sequence fingerprint and protocol fingerprint of the network data stream. The time sequence fingerprint includes at least a variable-length sequence fingerprint. A lightweight sequence embedding network is used to encode variable-length sequence fingerprints to obtain corresponding fixed-length sequence fingerprints, and the temporal fingerprint after sequence embedding is determined based on the fixed-length sequence fingerprints. Based on the CPU utilization of the target network device, the target application corresponding to the network data stream is identified in a hierarchical manner by using the pre-stored application signature library, metadata fingerprint, protocol fingerprint, and time sequence fingerprint after sequence embedding processing, and the identification result of the target application is obtained.

[0096] Those skilled in the art will understand that one or more embodiments of this specification can be provided as a method, system, or computer program product. Therefore, one or more embodiments of this specification may take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, one or more embodiments of this specification may take the form of a computer program product implemented on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0097] This specification describes one or more embodiments of methods, apparatus (systems), and computer program products according to embodiments of this specification with reference to flowchart illustrations and / or block diagrams. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, produce a machine for implementing the flowchart illustrations. Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.

[0098] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.

[0099] These computer program instructions may also be loaded onto a computer or other programmable data processing equipment to cause a series of operational steps to be performed on the computer or other programmable equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.

[0100] In a typical configuration, a computing device includes one or more processors (CPU), input / output interfaces, network interfaces, and memory.

[0101] Memory may include non-persistent storage in computer-readable media, such as random access memory (RAM) and / or non-volatile memory, such as read-only memory (ROM) or flash RAM. Memory is an example of computer-readable media.

[0102] Computer-readable media includes both permanent and non-permanent, removable and non-removable media that can store information by any method or technology. Information can be computer-readable instructions, data structures, modules of programs, or other data. Examples of computer storage media include, but are not limited to, phase-change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technologies, CD-ROM, digital versatile optical disc (DVD) or other optical storage, magnetic tape, magnetic disk storage or other magnetic storage devices, or any other non-transferable medium that can be used to store information accessible by a computing device. As defined herein, computer-readable media does not include transient computer-readable media, such as modulated data signals and carrier waves.

[0103] The embodiments of this application have been described above with reference to the accompanying drawings. However, this application is not limited to the specific embodiments described above. The specific embodiments described above are merely illustrative and not restrictive. Those skilled in the art can make many other forms under the guidance of this application without departing from the spirit and scope of the claims, and all of these forms are within the protection scope of this application.

Claims

1. A lightweight application identification method, characterized in that, The method is used for resource-constrained network devices, and the method includes: Obtain the network data stream of the target network device, and extract the metadata fingerprint, time sequence fingerprint and protocol fingerprint of the network data stream, wherein the time sequence fingerprint includes at least a variable-length sequence fingerprint; The variable-length sequence fingerprint is encoded using a lightweight sequence embedding network to obtain a corresponding fixed-length sequence fingerprint, and the temporal fingerprint after sequence embedding is determined based on the fixed-length sequence fingerprint. Based on the CPU utilization of the target network device, the target application corresponding to the network data stream is identified in a layered manner using the pre-stored application signature library, the metadata fingerprint, the protocol fingerprint, and the temporal fingerprint after sequence embedding processing, so as to obtain the identification result of the target application.

2. The method according to claim 1, characterized in that, If the network data stream of the target network device is an encrypted data stream, then extracting the protocol fingerprint of the network data stream includes: Extract the TLS handshake features of the encrypted data stream. The TLS handshake features include: JA3 fingerprint, server name indication information, and application layer protocol negotiation information.

3. The method according to claim 1, characterized in that, The temporal fingerprint includes: size sequence pattern information and direction sequence pattern information of the first N data packets in the network data stream, where N is a natural number and its value is determined according to the characteristics of the network data stream. The size sequence pattern information is obtained by discretizing the data packet size. The encoding of the variable-length sequence fingerprint based on a lightweight sequence embedding network to obtain the corresponding fixed-length sequence fingerprint includes: Using a learnable embedding matrix, the data packet size sequence pattern information after discretization and encoding in the variable-length sequence fingerprint is mapped to a specified low-dimensional vector space. The embedding vectors at each position in the variable-length sequence fingerprint are weighted and accumulated based on the exponentially decaying position weights to obtain the accumulation result; The accumulation result is mapped to the specified low-dimensional vector space by the lightweight activation function of the lightweight sequence embedding network to obtain a fixed-length sequence fingerprint corresponding to the variable-length sequence fingerprint.

4. The method according to claim 1, characterized in that, Based on the CPU utilization rate of the target network device, and utilizing a pre-stored application signature library, the metadata fingerprint, the protocol fingerprint, and the time-series fingerprint after sequence embedding processing, the target application corresponding to the network data stream is subjected to hierarchical identification processing to obtain the identification result of the target application, including: Based on the pre-stored application signature library, the metadata fingerprint, the protocol fingerprint, and the temporal fingerprint after sequence embedding processing, a level for hierarchical identification processing of the target application is determined. According to the order of identification delay time from low to high, the levels include: the first level based on port matching, the second level based on metadata classification, the third level based on temporal matching, and the fourth level based on protocol analysis. If the CPU utilization rate of the target network device is less than the first CPU utilization rate threshold, then the target application is subjected to hierarchical identification processing from the first level to the fourth level to obtain the identification result of the target application. If the CPU utilization rate of the target network device is greater than or equal to the first CPU utilization rate threshold and less than the second CPU utilization rate threshold, then the target application is subjected to hierarchical identification processing from the first level to the third level to obtain the identification result of the target application. If the CPU utilization rate of the target network device is greater than or equal to the second CPU utilization rate threshold and less than the third CPU utilization rate threshold, then the target application is subjected to hierarchical identification processing from the first level to the second level to obtain the identification result of the target application. If the CPU utilization rate of the target network device is greater than or equal to the third CPU utilization rate threshold, then the target application is subjected to the first level of hierarchical identification processing to obtain the identification result of the target application.

5. The method according to claim 4, characterized in that, The level for hierarchical identification of the target application is determined based on the pre-stored application signature library, the metadata fingerprint, the protocol fingerprint, and the temporal fingerprint after sequence embedding processing, including: The destination port number of the network data stream is determined based on the metadata fingerprint of the network data stream. Based on the determined destination port number and the mapping relationship between the service ports pre-stored in the application signature library, the target application is identified at the first level. Based on the metadata fingerprint of the network data stream and the pre-trained lightweight decision tree, the target application is identified at a second level. The identification result of the second level includes the classification confidence score corresponding to the target application. If the classification confidence level of the target application is less than the preset confidence threshold, then the target application is identified at the third level based on the similarity between the temporal fingerprint of the network data stream and the temporal fingerprint of the application stored in the application signature library. Based on the similarity between the protocol fingerprint of the network data stream and the protocol fingerprint of the application pre-stored in the application signature library, the target application is identified at the fourth level.

6. The method according to claim 5, characterized in that, The third-level identification of the target application is based on the similarity between the temporal fingerprint of the network data stream and the temporal fingerprint of the application pre-stored in the application signature database, including: Based on the adaptive multi-granularity local sensitive hash index, the temporal fingerprint of the network data stream is matched with the temporal fingerprint of the application pre-stored in the application signature library. The projection matrix in the adaptive multi-granularity local sensitive hash index is an optimized projection matrix generated based on discriminant analysis.

7. The method according to claim 6, characterized in that, The method for constructing the adaptive multi-granularity locality-sensitive hash index includes: Using a pre-trained adaptive multi-granularity locality-sensitive hash index model, an optimized projection matrix is ​​generated through discriminant analysis based on the inter-class scatter matrix and intra-class scatter matrix of different application samples. The pre-trained adaptive multi-granularity locality-sensitive hash index model is a model trained on a variety of different application samples with labels and a preset loss function. The preset loss function makes the vectors of the same type of application close after projection, and the vectors of different types of applications far apart after projection. The hash code of each application signature template corresponding to the application signature library is determined based on the optimized projection matrix. Based on the frequency of occurrence of each application category to which the application signature template belongs, the effective number of bits of the hash code is dynamically adjusted to obtain the dynamically adjusted hash code; An adaptive multi-granularity locality-sensitive hash index is generated based on the dynamically adjusted hash code, and the adaptive multi-granularity locality-sensitive hash index is stored using index buckets.

8. The method according to claim 1, characterized in that, The method further includes: incrementally updating the application signature library by maintaining the online real-time recognition buffer and the offline update buffer in the application signature library and performing atomic pointer switching operations.

9. A lightweight application recognition system, characterized in that, The system is used for resource-constrained network devices, and the system includes: A network data stream acquisition module is used to acquire the network data stream of a target network device and extract the metadata fingerprint, timing fingerprint, and protocol fingerprint of the network data stream, wherein the timing fingerprint includes at least a variable-length sequence fingerprint. The temporal fingerprint encoding processing module is used to encode the variable-length sequence fingerprint based on a lightweight sequence embedding network to obtain a corresponding fixed-length sequence fingerprint, and to determine the temporal fingerprint after sequence embedding based on the fixed-length sequence fingerprint. The identification module is used to perform hierarchical identification processing on the target application corresponding to the network data stream based on the CPU utilization rate of the target network device, using a pre-stored application signature library, the metadata fingerprint, the protocol fingerprint, and the temporal fingerprint after sequence embedding processing, to obtain the identification result of the target application.

10. An electronic device, characterized in that, It includes a processor, a memory, and a computer program stored in the memory and executable on the processor, wherein the computer program, when executed by the processor, implements the steps of the lightweight application identification method as described in any one of claims 1 to 8.