Methods, devices, and equipment for identifying intranet web applications based on behavioral patterns

By constructing a multi-level conversation graph and utilizing self-attention networks and multilayer perceptron models to dynamically adjust feature weights, the problems of high false alarm rate and high operation and maintenance cost in existing Web application identification technologies are solved, achieving more efficient Web application identification.

CN120433968BActive Publication Date: 2026-11-17NSFOCUS INFORMATION TECHNOLOGY CO LTD +1
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202510501692.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-04-21
Publication Date
2026-11-17
Estimated Expiration
2045-04-21

AI Technical Summary

Technical Problem

Existing web application identification technologies rely on static fingerprint databases, resulting in high false alarm rates and high maintenance costs, and are unable to adapt to the frequent updates of web applications.

Method used

By collecting session information from web applications, a multi-level session graph is constructed. Using self-attention networks and multilayer perceptron models, feature weights are dynamically adjusted to identify the behavioral patterns of web applications.

Benefits of technology

It improves the accuracy of Web application identification, reduces false alarm rate and operation and maintenance costs, and adapts to the dynamic changes of Web applications.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120433968B_ABST
    Figure CN120433968B_ABST
Patent Text Reader

Abstract

This application relates to the field of network security technology, and in particular to a method, apparatus, device, and medium for identifying intranet web applications based on behavioral patterns. The method collects any session information of a web application; the session information includes at least one round of request-response interaction; a multi-level session graph of the session information is constructed, wherein each bottom-level node represents a first feature of the corresponding round of interaction; each intermediate-level node represents a second feature between dependent bottom-level nodes; and the top-level node represents a third feature of the entire session information; the weight of any side in the session graph is determined based on the features of the connected nodes; the determined graph feature matrix is ​​input into a self-attention network to obtain adaptive weighted features of the session information, which are then input into a multilayer perceptron model to output the identification result of the web application, thereby improving the accuracy of web application identification.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of network security technology, and in particular to a method, apparatus, device and medium for identifying intranet web applications based on behavioral patterns. Background Technology

[0002] With the development of the internet, the complexity of network environments and web applications is gradually increasing, leading to a growing demand for web application identification. Most existing web application identification technologies rely on pre-set static identification rules and actively probe based on specific fingerprint databases. These methods have certain limitations in practice. First, active probing requires sending specific requests to the target component, which may affect its normal operation. Second, due to frequent web application updates, static fingerprint databases are prone to becoming outdated or invalid, resulting in a high false positive rate and high maintenance costs, requiring significant manpower to maintain and update the identification rules.

[0003] Therefore, there is an urgent need for a behavior-pattern-based method for identifying intranet web applications to improve the accuracy of web application identification. Summary of the Invention

[0004] This application provides a method, apparatus, device, and medium for identifying intranet web applications based on behavioral patterns, which can improve the accuracy of web application identification.

[0005] In a first aspect, this application provides a method for identifying intranet web applications based on behavioral patterns, the method comprising:

[0006] Collect any session information of a web application; the session information includes at least one round of requests and responses.

[0007] A conversation graph of the conversation information is constructed, wherein the conversation graph includes bottom-level nodes, intermediate-level nodes, and top-level nodes; each bottom-level node represents a first feature of the corresponding round of interaction; each intermediate-level node represents a second feature between bottom-level nodes that have a dependency relationship; the top-level node represents a third feature of the entire conversation information; the weight of any side in the conversation graph is determined based on the features of the connected nodes;

[0008] Determine the graph feature matrix of the conversation graph;

[0009] The graph feature matrix is ​​input into a self-attention network to obtain the adaptive weighted features of the session information;

[0010] The adaptive weighted features are input into the multilayer perceptron model, and the recognition result of the Web application is output. The multilayer perceptron model is obtained by training session information with different behavioral patterns and corresponding Web application types.

[0011] In one possible implementation, the first feature includes the response latency feature of the corresponding round of interaction and the structural feature of the response data packet;

[0012] For any first edge between a bottom-level node and an intermediate-level node, the time weight of the first edge is determined based on the response latency characteristics of the bottom-level node connected to the first edge; the size weight of the first edge is determined based on the data size of the response data packet of the bottom-level node connected to the first edge; and the weight of the first edge is determined based on the size weight and the time weight.

[0013] In one possible implementation, the second feature includes the response success rate of the intermediate layer node and / or the request frequency of the intermediate layer node.

[0014] For any second edge between an intermediate layer node and a top layer node, determine the frequency weight of the second edge based on the request frequency of the intermediate layer node connected to the second edge; determine the success rate weight of the second edge based on the response success rate of the intermediate layer node connected to the second edge; and determine the weight of the second edge based on the success rate weight and / or the frequency weight.

[0015] In one possible implementation, the third feature includes the first response time of the session information and / or the request frequency of the session information.

[0016] In one possible implementation, before determining the graph feature matrix of the session graph, the method further includes:

[0017] The weight of any first edge in the session graph is exponentially decayed; the exponential decay is determined by the difference between the current time and the interaction time of the underlying node connected to the first edge.

[0018] In one possible implementation, determining the graph feature matrix of the session graph includes:

[0019] For any first node in the conversation graph, based on the weight of the edge between the first node and the second node and the features of the second node, the aggregated features between the first node and the second node are obtained, thereby forming an aggregated feature matrix between nodes; the second node is any node in the conversation graph other than the first node;

[0020] The aggregated feature matrix is ​​subjected to at least two convolution operations using multi-scale convolution kernels to obtain the graph feature matrix of the conversation graph.

[0021] In one possible implementation, the graph feature matrix is ​​input into a self-attention network to obtain adaptive weighted features of the session information, including:

[0022] The graph feature matrix is ​​mapped to generate a query vector Q, a key vector K, and a value vector V for any feature;

[0023] For any feature, the similarity between different features is obtained by taking the inner product of the query vector Q and the key vector K of the feature. The similarity is then normalized using the softmax function to obtain the weight ratio of the feature. The value vector V of the feature is then weighted according to the weight ratio to obtain an adaptive weighted feature.

[0024] Secondly, this application provides a web application identification device, the device comprising:

[0025] The acquisition module is used to acquire any session information of a web application; the session information includes at least one round of interaction between requests and responses;

[0026] A construction module is used to construct a session graph of the session information, wherein the session graph includes bottom-level nodes, intermediate-level nodes, and top-level nodes; each bottom-level node represents a first feature of the corresponding round of interaction; each intermediate-level node represents a second feature between bottom-level nodes that have a dependency relationship; the top-level node represents a third feature of the entire session information; the weight of any side in the session graph is determined based on the features of the connected nodes; and the graph feature matrix of the session graph is determined.

[0027] The recognition module is used to input the graph feature matrix into a self-attention network to obtain the adaptive weighted features of the session information; input the adaptive weighted features into a multilayer perceptron model to output the recognition result of the Web application; the multilayer perceptron model is obtained by training session information with different behavioral patterns and corresponding Web application types.

[0028] In one possible implementation, the first feature includes the response latency feature of the corresponding round of interaction and the structural feature of the response data packet;

[0029] The construction module is specifically used to determine the time weight of any first edge between the bottom layer node and the intermediate layer node based on the response latency characteristics of the bottom layer node connected to the first edge; determine the size weight of the first edge based on the data size of the response data packet of the bottom layer node connected to the first edge; and determine the weight of the first edge based on the size weight and the time weight.

[0030] In one possible implementation, the second feature includes the response success rate of the intermediate layer node and / or the request frequency of the intermediate layer node.

[0031] The construction module is specifically used to determine the frequency weight of any second side between an intermediate layer node and a top layer node based on the request frequency of the intermediate layer node connected to the second side; determine the success rate weight of the second side based on the response success rate of the intermediate layer node connected to the second side; and determine the weight of the second side based on the success rate weight and / or the frequency weight.

[0032] In one possible implementation, the third feature includes the first response time of the session information and / or the request frequency of the session information.

[0033] In one possible implementation, the building module is further configured to exponentially decay the weight of any first edge in the session graph; the exponential decay is determined by the difference between the current time and the interaction time of the underlying nodes connected to the first edge.

[0034] In one possible implementation, the construction module is specifically used to obtain aggregated features between the first node and the second node for any first node in the session graph, based on the weight of the edge between the first node and the second node and the features of the second node, thereby forming an aggregated feature matrix between nodes; the second node is any node in the session graph other than the first node; and the aggregated feature matrix is ​​subjected to at least two convolution operations using multi-scale convolution kernels to obtain the graph feature matrix of the session graph.

[0035] In one possible implementation, the identification module is specifically used to map the graph feature matrix to generate a query vector Q, a key vector K, and a value vector V for any feature; for any feature, the similarity between different features is obtained based on the inner product of the query vector Q and the key vector K of the feature; the similarity is normalized using a softmax function to obtain the weight ratio of the feature; and the value vector V of the feature is weighted according to the weight ratio to obtain an adaptively weighted feature.

[0036] Thirdly, this application provides an electronic device comprising at least a processor and a memory, wherein the processor is configured to execute a computer program stored in the memory to implement the steps of the method as described in any of the first aspects.

[0037] Fourthly, this application provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements the steps of the method as described in any of the first aspects.

[0038] Fifthly, this application provides a computer program product comprising: computer program code, which, when run on a computer, causes the computer to perform the steps of any of the methods described in the first aspect.

[0039] In this embodiment, any session information of a Web application is collected; the session information includes at least one round of interaction between requests and responses; a multi-level session graph of the session information is constructed, wherein each bottom-level node represents a first feature of the corresponding round of interaction; each intermediate-level node represents a second feature between bottom-level nodes with dependencies; and the top-level node represents a third feature of the entire session information; the weight of any side in the session graph is determined based on the features of the connected nodes; the determined graph feature matrix is ​​input into a self-attention network to obtain adaptive weighted features of the session information, which are then input into a multilayer perceptron model to output the recognition result of the Web application, thereby improving the accuracy of Web application recognition. Attached Figure Description

[0040] To more clearly illustrate the implementation methods in the embodiments of this application or related technologies, the accompanying drawings used in the description of the embodiments or related technologies will be briefly introduced below. Obviously, the accompanying drawings described below are some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings.

[0041] Figure 1 A schematic diagram of a web application identification process is provided for some embodiments of this application;

[0042] Figure 2 A schematic diagram of a conversation graph provided for some embodiments of this application;

[0043] Figure 3 Another schematic diagram of a web application identification process provided for some embodiments of this application;

[0044] Figure 4 A schematic diagram of the structure of a Web application identification device provided for some embodiments of this application;

[0045] Figure 5This is a schematic diagram of the structure of an electronic device provided for some embodiments of this application. Detailed Implementation

[0046] To make the objectives, technical solutions, and advantages of this application clearer, a further detailed description of this application will be provided below with reference to the accompanying drawings. Obviously, the embodiments described in this application are merely some embodiments, not all embodiments. Based on the embodiments in this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.

[0047] It should be noted that the brief descriptions of terms in this application are only for the convenience of understanding the embodiments described below, and are not intended to limit the embodiments of this application. Unless otherwise stated, these terms should be understood in their ordinary and common meaning.

[0048] The terms "first," "second," "third," etc., used in the specification, claims, and accompanying drawings of this application are used to distinguish similar or related objects or entities, and do not necessarily imply a specific order or sequence, unless otherwise specified. It should be understood that such terms are interchangeable where appropriate.

[0049] The terms “comprising” and “having”, and any variations thereof, are intended to cover but not exclude inclusion, for example, a product or device that includes a range of components is not necessarily limited to all of the components that are clearly listed, but may include other components that are not clearly listed or that are inherent to such product or device.

[0050] The term "module" refers to any known or subsequently developed hardware, software, firmware, artificial intelligence, fuzzy logic, or combination of hardware and / or software code that is capable of performing the functions associated with that element.

[0051] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of this application, and are not intended to limit them. Although this application has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some or all of the technical features therein. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of this application.

[0052] The following description, in conjunction with the accompanying drawings, illustrates exemplary embodiments of this application, including various details to aid understanding. These embodiments should be considered merely exemplary. Therefore, those skilled in the art should recognize that various changes and modifications can be made to the embodiments described herein without departing from the scope of this application. Similarly, for clarity and brevity, descriptions of well-known functions and structures are omitted in the following description. It should be noted that in the embodiments of this application, certain existing industry solutions such as software, components, and models may be mentioned. These should be considered exemplary, intended only to illustrate the feasibility of implementing the technical solutions of this application, and do not imply that the applicant has already used or necessarily used such solutions.

[0053] Before introducing the intranet web application identification method based on behavior patterns provided in the embodiments of this application, the technical background of the embodiments of this application will be introduced first for ease of understanding.

[0054] With the development of the internet, the complexity of network environments and web applications is gradually increasing, leading to a growing demand for web application identification. Most existing web application identification technologies rely on pre-set static identification rules and actively probe based on specific fingerprint databases. These methods have certain limitations in practice. First, active probing requires sending specific requests to the target component, which may affect its normal operation. Second, due to frequent web application updates, static fingerprint databases are prone to becoming outdated or invalid, resulting in a high false positive rate and high maintenance costs, requiring significant manpower to maintain and update the identification rules.

[0055] Based on this, this application provides a method, apparatus, device, medium, and computer program product for identifying intranet web applications based on behavioral patterns. In this method, any session information of a web application is collected; the session information includes at least one round of request-response interaction; a session graph of the session information is constructed, wherein the session graph includes bottom-level nodes, intermediate-level nodes, and top-level nodes; each bottom-level node represents a first feature of the corresponding round of interaction; each intermediate-level node represents a second feature between bottom-level nodes with dependencies; the top-level node represents a third feature of the entire session information; the weight of any side in the session graph is determined based on the features of connected nodes; a graph feature matrix of the session graph is determined; the graph feature matrix is ​​input into a self-attention network to obtain adaptive weighted features of the session information; the adaptive weighted features are input into a multilayer perceptron model to output the identification result of the web application; the multilayer perceptron model is obtained by training session information with different behavioral patterns and corresponding web application types.

[0056] Example 1:

[0057] Figure 1 This is a schematic diagram illustrating a web application identification process provided for some embodiments of this application. For example... Figure 1 As shown, the process includes the following steps:

[0058] S101: Collect any session information of the Web application; the session information includes at least one round of interaction between requests and responses.

[0059] The behavior pattern-based intranet web application identification method in this application embodiment is applied to electronic devices, wherein the electronic devices may be servers or PCs, etc.

[0060] A web application refers to a standalone web application or middleware that provides web services. To accurately identify a web application, session information is collected for any given instance of the application's interaction, including at least one round of request-response interactions. Specifically, a session is established when a user accesses the web application's server and ends when one party disconnects. A single session can contain multiple rounds of request-response interactions. Session information may include response latency characteristics, response packet structure characteristics, response success rate, and request frequency, among other things.

[0061] For example, for any session information collected from a web application, the session information can include time-series features, frequency features, and response structure features. Time-series features include, but are not limited to, response latency between each round of requests and responses, the time interval between interactions between different rounds of requests and responses, and the first response time. Response latency can be determined based on a request-response time matching algorithm, using a hash map to record the sending time of each request packet, and retrieving a matching request packet from the map when a response packet is received to calculate the response latency. For multi-round interactions, the earliest response time is used as the first response time feature, reflecting the startup response speed of the web application. Frequency features can use a sliding time window algorithm to calculate the frequency distribution of requests and responses within a specific time range. Time-series data is divided into fixed time windows, and the number of requests within each window is counted to generate the frequency distribution of the time series. This effectively captures changes in traffic density over a short period, identifying the interaction density and rhythm of the web application. Response structure features can be obtained using a response structure parser to obtain the data length, hierarchical structure, and data format of the data packets for each interaction.

[0062] In one possible implementation, network traffic capture and classification can be performed to collect session information. The system receives parsed and reconstructed data from a traffic acquisition system. The data access for the traffic acquisition system originates from mirrored traffic from a switch. Each data packet contains header information, such as the source IP of the request, the destination IP of the response, port, and protocol. The system uses a traffic parser module to classify the data and establishes a unique identifier for each session, which is stored in the session information.

[0063] S102: Construct a session graph of the session information, wherein the session graph includes bottom-level nodes, intermediate-level nodes and top-level nodes; each bottom-level node represents a first feature of the corresponding round of interaction; each intermediate-level node represents a second feature between bottom-level nodes that have a dependency relationship; the top-level node represents a third feature of the entire session information; the weight of any side in the session graph is determined based on the features of the connected nodes.

[0064] To more accurately and comprehensively obtain the interaction characteristics between requests and responses in different rounds of session information, a session graph can be constructed based on the session information. Unlike traditional graph structures that only focus on single request-response relationships, in this embodiment, the session graph is a multi-level graph structure. Figure 2 This is a schematic diagram of a conversation graph provided for some embodiments of this application. For example... Figure 2 As shown, this session graph includes bottom-level nodes, middle-level nodes, and top-level nodes. Bottom-level nodes represent request-response relationships, including request-response A, request-response B, and request-response C. Middle-level nodes represent dependency relationships between bottom-level nodes, including dependencies AB and AC. Top-level nodes are the global session nodes.

[0065] Each bottom-level node represents the first feature of the interaction in the corresponding round. For example, each intermediate-level node represents the second feature between bottom-level nodes that have dependencies. For example, the second feature includes the third feature represented by the top-level node, which represents the entire session information. The weight of any side in the session graph is determined based on the features of the connected nodes.

[0066] Multi-layered conversation graph construction methods can visually reflect complex interaction relationships and accurately capture the hierarchical structure in multiple interactions of a web application, so as to analyze the entire conversation flow.

[0067] S103: Determine the graph feature matrix of the conversation graph.

[0068] Graph embedding is used to determine the graph feature matrix of the conversation graph.

[0069] Graph embedding is a method that converts nodes, edges, or subgraphs in a graph structure into vector representations, preserving the graph's structure and feature information for processing and analysis in machine learning algorithms.

[0070] S104: Input the graph feature matrix into a self-attention network to obtain the adaptive weighted features of the session information.

[0071] Adaptive feature weighting refers to dynamically adjusting the weights of features during model training or processing based on their importance to the task, assigning different influences to different features to improve the model's accuracy and generalization ability. This weight allocation is automatically learned and can adapt to different datasets or task requirements.

[0072] Dynamic weight allocation for multimodal features is achieved through a self-attention mechanism. This mechanism automatically adjusts the weights based on the relative importance of each feature within a specific context, ensuring that the system captures the most critical features in complex interactive environments. This adaptive weight allocation mechanism is based on a self-attention network, dynamically determining weights by calculating the similarity between the fused input features. The self-attention mechanism can adaptively adjust the weight allocation of features such as temporal sequence, frequency, and response structure based on dynamic changes in network traffic, effectively handling multidimensional features in complex network environments.

[0073] S105: Input the adaptive weighted features into the multilayer perceptron model and output the recognition result of the Web application; the multilayer perceptron model is obtained by training session information with different behavioral patterns and corresponding Web application types.

[0074] To accurately identify web applications, a Multilayer Perceptron (MLP) model is trained on session information with different behavioral patterns and corresponding web application types. This model is trained on a large dataset of traffic data labeled with different behavioral patterns and web application types. The pre-training process enables the model to learn the unique behavioral patterns and features of various web applications, allowing for fast and efficient identification in practical applications.

[0075] In one possible implementation, the multilayer perceptron model structure includes an input layer, hidden layers, and an output layer. The input layer receives a multimodal feature vector weighted by a self-attention mechanism. This feature vector includes temporal features, frequency features, and response structure features. The hidden layer uses a four-layer design: Hidden Layer 1 is a multimodal feature processing layer, primarily responsible for normalizing and nonlinearly mapping the input temporal, frequency, and response features. Hidden Layer 2 is a multimodal feature fusion layer, primarily responsible for aligning and fusing the input features, ensuring that temporal, frequency, and response structure features contained in the same batch are placed in the same dimensional space. Hidden Layer 3 is a deep feature abstraction layer, primarily responsible for extracting higher-order patterns from the fused features, eliminating redundant features, reducing computational overhead, and using a hyperbolic tangent (tanh) nonlinear activation function to nonlinearly process the fused features. To avoid the gradient vanishing problem during this process, a residual connection mechanism is used to directly pass some feature information to higher layers, ensuring that important features from earlier layers are not lost. Then, dimensionality reduction is performed layer by layer to eliminate redundant features and reduce computational overhead. Hidden layer 4 is the feature optimization layer. Its main function is to ensure uniform feature distribution and reduce the risk of overfitting through L2 regularization. A dynamic dropout mechanism is introduced in this process. Based on the relevance of features, the probability of dropout is dynamically determined. Only highly correlated features or features that may cause overfitting are randomly dropped out, while important features with weaker relationships to other features are retained. The weights of the retained important features are then readjusted to ensure that key features are maximized, suppress noise, and improve the model's generalization ability. During the inference phase, the high-dimensional feature vector input from the upper layers is fed into the output layer, where the Softmax function is used for classification. The output layer outputs the probability distribution of the current web application, completing the recognition.

[0076] In this embodiment, any session information of a Web application is collected; the session information includes at least one round of interaction between requests and responses; a multi-level session graph of the session information is constructed, wherein each bottom-level node represents a first feature of the corresponding round of interaction; each intermediate-level node represents a second feature between bottom-level nodes with dependencies; and the top-level node represents a third feature of the entire session information; the weight of any side in the session graph is determined based on the features of the connected nodes; the determined graph feature matrix is ​​input into a self-attention network to obtain adaptive weighted features of the session information, which are then input into a multilayer perceptron model to output the recognition result of the Web application, thereby improving the accuracy of Web application recognition.

[0077] Example 2:

[0078] To further improve the accuracy of Web application identification, based on the above embodiments, in this application embodiment, the first feature includes the response latency feature of the corresponding round of interaction and the structural feature of the response data packet;

[0079] For any first edge between a bottom-level node and an intermediate-level node, the time weight of the first edge is determined based on the response latency characteristics of the bottom-level node connected to the first edge; the size weight of the first edge is determined based on the data size of the response data packet of the bottom-level node connected to the first edge; and the weight of the first edge is determined based on the size weight and the time weight.

[0080] The first feature includes response latency features for corresponding rounds of interaction and structural features of the response data packets. For example, the response latency feature could be the time interval between the request and the response, and the structural features of the data packets could be the packet length, hierarchical structure, and data format. In one possible implementation, the text features in the first feature can be vectorized using the TF-IDF algorithm, and then concatenated through a fully connected layer to form a high-dimensional joint feature vector, thus creating multimodal features. The specific steps of feature concatenation can be performed through a fully connected layer to generate a unified high-dimensional feature vector. A Dropout mechanism is used to avoid overfitting and ensure the effectiveness of feature fusion. This results in a session graph after graph embedding that includes both static text payload features and dynamic graph features.

[0081] To accurately determine the weight of each first edge, for any first edge between the bottom layer node and the intermediate layer node, the time weight of the first edge is determined based on the response latency characteristics of the bottom layer node connected to the first edge; the size weight of the first edge is determined based on the data size of the response data packet of the bottom layer node connected to the first edge; and the weight of the first edge is determined based on the size weight and the time weight.

[0082] In one possible implementation, the time weight of the first side can be calculated using the Exponentially Weighted Moving Average (EWMA) method to ensure dynamic capture of changes in time intervals and other features. Specifically:

[0083] w time (i)=α·Δt(i)+(1-α)·w time (i-1)

[0084] Where α is the attenuation coefficient and Δt(i) is the response delay of the i-th interaction.

[0085] In one possible implementation, the weight of the first side can be determined using the following formula:

[0086]

[0087] The maximum response data size can be the maximum response data size collected within a preset time period, or it can be a maximum response data size that can be freely set according to requirements. This application does not limit this.

[0088] After determining the magnitude weight and time weight of the first side, the weight of the first side can be determined based on the sum of the two, or the magnitude weight and time weight can be set with corresponding weight values ​​respectively, and the calculated weight sum can be used as the weight of the first side.

[0089] In this embodiment, for any first side between the bottom layer node and the intermediate layer node, the time weight of the first side is determined based on the response latency of the bottom layer node connected to the first side, and the size weight of the first side is determined based on the data size of the response data packet of the bottom layer node connected to the first side. Based on the size weight and the time weight, the weight of the first side is determined, thereby enabling more flexible and accurate determination of the weight of the first side based on various characteristics of session interaction, and further improving the accuracy of Web application identification.

[0090] Example 3:

[0091] To further improve the accuracy of Web application identification, based on the above embodiments, in this application embodiment, the second feature includes the response success rate of the intermediate layer node and / or the request frequency of the intermediate layer node;

[0092] For any second edge between an intermediate layer node and a top layer node, determine the frequency weight of the second edge based on the request frequency of the intermediate layer node connected to the second edge; determine the success rate weight of the second edge based on the response success rate of the intermediate layer node connected to the second edge; and determine the weight of the second edge based on the success rate weight and / or the frequency weight.

[0093] To accurately determine the weight of the second side, for any second side between an intermediate-level node and a top-level node, the frequency weight of the second side can be determined based on the request frequency of the intermediate-level nodes connected to it; the success rate weight of the second side can be determined based on the response success rate of the intermediate-level nodes connected to it. Finally, the total weight of the second side is determined based on the success rate weight and / or the frequency weight.

[0094] Specifically, in one possible implementation, the frequency weight of the second side can be determined based on the ratio of the request frequency of the intermediate layer node connected to the second side to a preset maximum request frequency.

[0095] In one possible implementation, the success rate weight of the second side can be determined according to the following formula:

[0096]

[0097] The total number of responses can be the total number of responses collected within a preset time period or the set total number of responses. It can be freely set according to actual needs, and this application does not limit it.

[0098] The weight of the second side can be determined based on the success rate weight or the frequency weight, or it can be determined based on the sum of the success rate weight and the frequency weight. Alternatively, weight values ​​can be set for the success rate weight and the frequency weight respectively, and then a weighted sum can be performed to determine the weight of the second side.

[0099] In this embodiment, for any second side between an intermediate layer node and a top layer node, the frequency weight of the second side is determined based on the request frequency of the intermediate layer node connected to the second side; the success rate weight of the second side is determined based on the response success rate of the intermediate layer node connected to the second side; and the weight of the second side is determined based on the success rate weight and / or the frequency weight. This allows for a more flexible and accurate determination of the weight of the second side based on various characteristics of session interaction, further improving the accuracy of Web application identification.

[0100] Example 4:

[0101] To further improve the accuracy of Web application identification, based on the above embodiments, in this application embodiment, the third feature includes the first response time of the session information and / or the request frequency of the session information.

[0102] To further improve the accuracy of web application identification, the third feature of the entire session information represented by the top-level node may include the first response time of the session information and / or the request frequency of the requests contained in the session information.

[0103] In this embodiment, the third feature of the entire session information represented by the top-level node includes the first response time and / or the request frequency of the session information, thereby reflecting the overall characteristics of the session information.

[0104] Example 5:

[0105] To further improve the accuracy of Web application identification, based on the above embodiments, in this embodiment, before determining the graph feature matrix of the session graph, the following steps are also included:

[0106] The weight of any first edge in the session graph is exponentially decayed; the exponential decay is determined by the difference between the current time and the interaction time of the underlying node connected to the first edge.

[0107] Since the number of underlying nodes may be too large, using all underlying nodes to extract the graph feature matrix may result in an excessively large graph feature matrix and redundant information. In this embodiment, before determining the graph feature matrix of the session graph, an adaptive weight decay mechanism can be used to exponentially decay the weight of any first edge of the session graph in order to select a better first edge and the underlying nodes it connects.

[0108] Specifically, time series analysis can be used to identify the correlation between historical time-series characteristics and current request-response interactions, and the weights of the first side can be dynamically updated and decayed. In one possible implementation, an exponential decay function based on a time window can be used:

[0109]

[0110] Among them, t current Here, t is the current time, t(i) is the time of the i-th interaction, and τ is a time constant used to control the decay rate. Using an exponential decay function based on a time window ensures that historical data gradually becomes invalid, effectively decaying the weights of the first side of historical interactions and preventing them from interfering with the current recognition result.

[0111] In this embodiment of the application, the weight of any first side in the session graph is exponentially decayed, and the graph feature matrix is ​​determined based on the decayed session graph, thereby further improving the accuracy of Web application recognition.

[0112] Example 6:

[0113] To further improve the accuracy of Web application identification, based on the above embodiments, in this embodiment, determining the graph feature matrix of the session graph includes:

[0114] For any first node in the conversation graph, based on the weight of the edge between the first node and the second node and the features of the second node, the aggregated features between the first node and the second node are obtained, thereby forming an aggregated feature matrix between nodes; the second node is any node in the conversation graph other than the first node;

[0115] The aggregated feature matrix is ​​subjected to at least two convolution operations using multi-scale convolution kernels to obtain the graph feature matrix of the conversation graph.

[0116] Traditional Graph Convolutional Neural Networks (GCNs) only focus on a node's direct neighbors. To more accurately determine the graph feature matrix of the session graph, this embodiment employs context-aware graph embedding operations to form an aggregated feature matrix between nodes. By introducing a context-aware mechanism, global context embedding is achieved. Specifically, the global context pool construction includes building a global context pool for each node, aggregating the features of its non-directly adjacent nodes. The global context pool can summarize the features of other nodes within a specific time window to form more expressive node features.

[0117] Specifically, for any node in the conversation graph, the aggregated features between the first node and the second node are obtained based on the weight of the edge between the first node and the second node and the features of the second node, thus forming an aggregated feature matrix between nodes, where the second node is any node in the conversation graph other than the first node.

[0118] In one possible implementation, to reduce computational complexity, a context caching mechanism and an attention mechanism can be used to assist the operation. The feature aggregation formula in the context pool is:

[0119]

[0120] Where, α ij h is the weight of the edge between the first node i and the second node j. j It is the feature embedding vector of the second node j.

[0121] Multi-scale convolution and at least two convolution operations on the aggregated feature matrix are used to obtain the graph feature matrix of the conversation graph. For example, 3x3 convolution kernels can be used to extract local interaction features, and 7x7 convolution kernels can be used to extract global context features, ensuring that the global background information of the conversation graph can be fully utilized in complex interactions.

[0122] In this embodiment, for any first node in the session graph, based on the circle of the edge between the first node and the second node and the features of the second node, the aggregated features between the first node and the second node are obtained, thereby forming an aggregated feature matrix between nodes; the aggregated feature matrix is ​​subjected to at least two convolution operations using multi-scale convolution kernels to obtain the graph feature matrix of the session graph, making full use of the feature information of the session graph to further improve the accuracy of Web application recognition.

[0123] Example 7:

[0124] To further improve the accuracy of Web application recognition, based on the above embodiments, the graph feature matrix is ​​input into a self-attention network to obtain adaptive weighted features of the session information, including:

[0125] The graph feature matrix is ​​mapped to generate a query vector Q, a key vector K, and a value vector V for any feature;

[0126] For any feature, the similarity between different features is obtained by taking the inner product of the query vector Q and the key vector K of the feature. The similarity is then normalized using the softmax function to obtain the weight ratio of the feature. The value vector V of the feature is then weighted according to the weight ratio to obtain an adaptive weighted feature.

[0127] To obtain more accurate adaptive weighted features of session information, this application employs an adaptive weight allocation method, using a self-attention mechanism to dynamically assign weights to multimodal features. The self-attention mechanism automatically adjusts the weights based on the relative importance of each feature in a specific context, ensuring that the system captures the most critical features in complex interactive environments. This adaptive weight allocation mechanism is based on a self-attention network, dynamically determining weights by calculating the similarity between the input fused features. For each input graph feature matrix, a query vector Q, a key vector K, and a value vector V are generated for any feature. By calculating the inner product between the query vector Q and the key vector K, the system obtains the similarity between different features. Weighting is then calculated based on the similarity, and these similarities are normalized using a softmax function to obtain the feature weights. Finally, the feature values ​​are weighted according to the weights to obtain the adaptively weighted features. The attention mechanism can adaptively adjust the weight allocation of features such as temporal sequence, frequency, and response structure based on dynamic changes in network traffic, enabling the system to effectively handle multidimensional features in complex network environments.

[0128] The input to this stage is the multimodal graph feature matrix output from the upper layer. Each row of the graph feature matrix represents a node, and each column represents a feature. A weight matrix is ​​used to linearly map the input matrix, mapping the input features to a query vector Q, a key vector K, and a value vector V, respectively. The inner product between the query vector and the key vector is used to measure the degree of matching between them; a larger inner product value indicates a higher relevance. The inner product score can be positive or negative, so softmax normalization is used to generate weights. Then, the value vectors are weighted and summed to obtain the weighted result, i.e., the adaptive weighted features.

[0129] In this embodiment, the graph feature matrix is ​​input into a self-attention network to obtain adaptive weighted features of the session information, thereby further improving the accuracy of Web application recognition.

[0130] The following example will further illustrate the entire process of Web application identification in the embodiments of this application. Figure 3 This is a schematic diagram illustrating another web application identification process provided for some embodiments of this application. For example... Figure 3 As shown, the process includes:

[0131] Data is input through a traffic access parsing device, processed by a protocol behavior extraction module, a session graph construction and embedding module, a feature fusion module, and an inference and recognition model, to obtain the final output of Web application recognition. Specifically, the implementation process of each module can be referred to the methods in the above embodiments, and will not be repeated here.

[0132] In this embodiment, any session information of a Web application is collected; the session information includes at least one round of interaction between requests and responses; a multi-level session graph of the session information is constructed, wherein each bottom-level node represents a first feature of the corresponding round of interaction; each intermediate-level node represents a second feature between bottom-level nodes with dependencies; and the top-level node represents a third feature of the entire session information; the weight of any side in the session graph is determined based on the features of the connected nodes; the determined graph feature matrix is ​​input into a self-attention network to obtain adaptive weighted features of the session information, which are then input into a multilayer perceptron model to output the recognition result of the Web application, thereby improving the accuracy of Web application recognition.

[0133] Example 8:

[0134] Based on the same inventive concept, and building upon the above embodiments, this application provides an information disclosure system. Figure 4 This is a schematic diagram of the structure of a web application identification device provided for some embodiments of this application. For example... Figure 4 As shown, the device includes:

[0135] The acquisition module 401 is used to acquire any session information of a Web application; the session information includes at least one round of interaction between requests and responses;

[0136] Construction module 402 is used to construct a session graph of the session information, wherein the session graph includes bottom-level nodes, intermediate-level nodes, and top-level nodes; each bottom-level node represents a first feature of the corresponding round of interaction; each intermediate-level node represents a second feature between bottom-level nodes that have a dependency relationship; the top-level node represents a third feature of the entire session information; the weight of any side in the session graph is determined based on the features of the connected nodes; and the graph feature matrix of the session graph is determined.

[0137] The recognition module 403 is used to input the graph feature matrix into a self-attention network to obtain the adaptive weighted features of the session information; input the adaptive weighted features into a multilayer perceptron model to output the recognition result of the Web application; the multilayer perceptron model is obtained by training session information with different behavioral patterns and corresponding Web application types.

[0138] In one possible implementation, the first feature includes the response latency feature of the corresponding round of interaction and the structural feature of the response data packet;

[0139] The construction module is specifically used to determine the time weight of any first edge between the bottom layer node and the intermediate layer node based on the response latency characteristics of the bottom layer node connected to the first edge; determine the size weight of the first edge based on the data size of the response data packet of the bottom layer node connected to the first edge; and determine the weight of the first edge based on the size weight and the time weight.

[0140] In one possible implementation, the second feature includes the response success rate of the intermediate layer node and / or the request frequency of the intermediate layer node.

[0141] The construction module 402 is specifically used to determine the frequency weight of any second side between the intermediate layer node and the top layer node based on the request frequency of the intermediate layer node connected to the second side; determine the success rate weight of the second side based on the response success rate of the intermediate layer node connected to the second side; and determine the weight of the second side based on the success rate weight and / or the frequency weight.

[0142] In one possible implementation, the third feature includes the first response time of the session information and / or the request frequency of the session information.

[0143] In one possible implementation, the construction module 402 is further configured to exponentially decay the weight of any first edge in the session graph; the exponential decay is determined by the difference between the current time and the interaction time of the underlying nodes connected to the first edge.

[0144] In one possible implementation, the construction module 402 is specifically used to obtain aggregated features between the first node and the second node for any first node in the session graph, based on the weight of the edge between the first node and the second node and the features of the second node, thereby forming an aggregated feature matrix between nodes; the second node is any node in the session graph other than the first node; and the aggregated feature matrix is ​​subjected to at least two convolution operations using a multi-scale convolution kernel to obtain the graph feature matrix of the session graph.

[0145] In one possible implementation, the identification module 403 is specifically used to map the graph feature matrix to generate a query vector Q, a key vector K, and a value vector V for any feature; for any feature, the similarity between different features is obtained based on the inner product of the query vector Q and the key vector K of the feature; the similarity is normalized using a softmax function to obtain the weight ratio of the feature; and the value vector V of the feature is weighted according to the weight ratio to obtain an adaptively weighted feature.

[0146] In this embodiment, any session information of a Web application is collected; the session information includes at least one round of interaction between requests and responses; a multi-level session graph of the session information is constructed, wherein each bottom-level node represents a first feature of the corresponding round of interaction; each intermediate-level node represents a second feature between bottom-level nodes with dependencies; and the top-level node represents a third feature of the entire session information; the weight of any side in the session graph is determined based on the features of the connected nodes; the determined graph feature matrix is ​​input into a self-attention network to obtain adaptive weighted features of the session information, which are then input into a multilayer perceptron model to output the recognition result of the Web application, thereby improving the accuracy of Web application recognition.

[0147] Example 9:

[0148] Based on the same inventive concept and the above embodiments, this application provides an electronic device that can realize the function of the Web application identification device described above. Figure 5 This is a schematic diagram of the structure of an electronic device provided for some embodiments of this application. For example... Figure 5 As shown, the electronic device includes: a processor 501, a communication interface 502, a memory 503, and a communication bus 504, wherein the processor 501, the communication interface 502, and the memory 503 communicate with each other through the communication bus 504.

[0149] The memory 503 stores a computer program that, when executed by the processor 501, causes the processor 501 to perform the steps included in any of the behavioral pattern-based intranet web application identification methods described in the above embodiments.

[0150] The communication bus mentioned in the above electronic devices can be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus, etc. This communication bus can be divided into address bus, data bus, control bus, etc. For ease of illustration, only one thick line is used to represent it in the diagram, but this does not mean that there is only one bus or one type of bus.

[0151] Communication interface 502 is used for communication between the above-mentioned electronic device and other devices.

[0152] The memory may include random access memory (RAM) or non-volatile memory (NVM), such as at least one disk storage device. Optionally, the memory may also be at least one storage device located remotely from the aforementioned processor.

[0153] The processors mentioned above can be general-purpose processors, including central processing units, network processors (NPs), etc.; they can also be digital signal processors (DSPs), application-specific integrated circuits, field-programmable gate arrays or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc.

[0154] In this embodiment, any session information of a Web application is collected; the session information includes at least one round of interaction between requests and responses; a multi-level session graph of the session information is constructed, wherein each bottom-level node represents a first feature of the corresponding round of interaction; each intermediate-level node represents a second feature between bottom-level nodes with dependencies; and the top-level node represents a third feature of the entire session information; the weight of any side in the session graph is determined based on the features of the connected nodes; the determined graph feature matrix is ​​input into a self-attention network to obtain adaptive weighted features of the session information, which are then input into a multilayer perceptron model to output the recognition result of the Web application, thereby improving the accuracy of Web application recognition.

[0155] Example 10:

[0156] Based on the same inventive concept, and building upon the above embodiments, this application provides a computer-readable storage medium storing a computer program executable by a processor. When the program runs on the processor, it causes the processor to execute the steps included in the behavior pattern-based intranet web application identification method described in any of the above embodiments.

[0157] The aforementioned computer-readable storage medium can be any available medium or data storage device that can be accessed by the processor in an electronic device, including but not limited to magnetic storage such as floppy disks, hard disks, magnetic tapes, magneto-optical disks (MO), optical storage such as CDs, DVDs, BDs, HVDs, etc., and semiconductor storage such as ROMs, EPROMs, EEPROMs, non-volatile memory (NAND flash), solid-state drives (SSDs), etc.

[0158] Based on the same inventive concept, this application also provides a computer program product, which includes computer program code. When the computer program code is run on a computer, it causes the computer to perform the steps of the intranet web application identification method based on behavioral patterns as described above. Since the principle of the problem solved by the above-described computer program product is similar to that of the above-described intranet web application identification method based on behavioral patterns, the implementation of the above-described computer program product can refer to the implementation of the method, and repeated details will not be described again.

[0159] In this embodiment, any session information of a Web application is collected; the session information includes at least one round of interaction between requests and responses; a multi-level session graph of the session information is constructed, wherein each bottom-level node represents a first feature of the corresponding round of interaction; each intermediate-level node represents a second feature between bottom-level nodes with dependencies; and the top-level node represents a third feature of the entire session information; the weight of any side in the session graph is determined based on the features of the connected nodes; the determined graph feature matrix is ​​input into a self-attention network to obtain adaptive weighted features of the session information, which are then input into a multilayer perceptron model to output the recognition result of the Web application, thereby improving the accuracy of Web application recognition.

[0160] Those skilled in the art will understand that embodiments of this application can be provided as methods, systems, or computer program products. Therefore, this application can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, this application can take the form of a computer program product embodied 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.

[0161] This application is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to this application. It should 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, generate instructions 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.

[0162] 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.

[0163] 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.

[0164] Obviously, those skilled in the art can make various modifications and variations to this application without departing from the spirit and scope of this application. Therefore, if such modifications and variations fall within the scope of the claims of this application and their equivalents, this application also intends to include such modifications and variations.

Claims

1. A method for identifying intranet web applications based on behavior patterns, characterized in that, The method includes: Collect any session information of a web application; the session information includes at least one round of requests and responses. A conversation graph of the conversation information is constructed, wherein the conversation graph includes bottom-level nodes, intermediate-level nodes, and top-level nodes; each bottom-level node represents a first feature of the corresponding round of interaction; each intermediate-level node represents a second feature between bottom-level nodes that have a dependency relationship; the top-level node represents a third feature of the entire conversation information; the weight of any side in the conversation graph is determined based on the features of the connected nodes; Determine the graph feature matrix of the conversation graph; The graph feature matrix is ​​input into a self-attention network to obtain the adaptive weighted features of the session information; The adaptive weighted features are input into the multilayer perceptron model, and the recognition result of the Web application is output; the multilayer perceptron model is obtained by training session information with different behavioral patterns and corresponding Web application types; The step of determining the graph feature matrix of the conversation graph includes: For any first node in the conversation graph, based on the weight of the edge between the first node and the second node and the features of the second node, an aggregated feature between the first node and the second node is obtained, thereby forming an aggregated feature matrix between nodes; the second node is any node in the conversation graph other than the first node; the aggregated feature matrix is ​​subjected to at least two convolution operations using a multi-scale convolution kernel to obtain the graph feature matrix of the conversation graph.

2. The method according to claim 1, characterized in that, The first feature includes the response latency feature of the corresponding round of interaction and the structural feature of the response data packet; For any first edge between a bottom-level node and an intermediate-level node, the time weight of the first edge is determined based on the response latency characteristics of the bottom-level node connected to the first edge; the size weight of the first edge is determined based on the data size of the response data packet of the bottom-level node connected to the first edge; and the weight of the first edge is determined based on the size weight and the time weight.

3. The method according to claim 1, characterized in that, The second feature includes the response success rate of the intermediate layer nodes and / or the request frequency of the intermediate layer nodes; For any second edge between an intermediate layer node and a top layer node, determine the frequency weight of the second edge based on the request frequency of the intermediate layer node connected to the second edge; The success rate weight of the second side is determined based on the response success rate of the intermediate layer nodes connected to the second side. The weight of the second side is determined based on the success rate weight and / or the frequency weight.

4. The method according to claim 1, characterized in that, The third feature includes the first response time of the session information and / or the request frequency of the session information.

5. The method according to any one of claims 1 to 4, characterized in that, Before determining the graph feature matrix of the conversation graph, the method further includes: The weight of any first edge in the session graph is exponentially decayed; the exponential decay is determined by the difference between the current time and the interaction time of the underlying node connected to the first edge.

6. The method according to any one of claims 1 to 4, characterized in that, The graph feature matrix is ​​input into a self-attention network to obtain adaptive weighted features of the session information, including: The graph feature matrix is ​​mapped to generate a query vector for any feature. Key vector Sum value vector ; For any feature, based on the query vector of the feature Key vector of the aforementioned features The inner product of the features is used to obtain the similarity between different features. The similarity is then normalized using the softmax function to obtain the weight ratio of each feature. The value vector of each feature is then adjusted according to this weight ratio. We then perform weighting to obtain adaptive weighted features.

7. A Web application identification device, characterized in that, The device includes: The acquisition module is used to acquire any session information of a web application; the session information includes at least one round of interaction between requests and responses; A construction module is used to construct a session graph of the session information, wherein the session graph includes bottom-level nodes, intermediate-level nodes, and top-level nodes; each bottom-level node represents a first feature of the corresponding round of interaction; each intermediate-level node represents a second feature between bottom-level nodes that have a dependency relationship; the top-level node represents a third feature of the entire session information; the weight of any side in the session graph is determined based on the features of the connected nodes; and the graph feature matrix of the session graph is determined. The recognition module is used to input the graph feature matrix into a self-attention network to obtain the adaptive weighted features of the session information; input the adaptive weighted features into a multilayer perceptron model to output the recognition result of the Web application; the multilayer perceptron model is obtained by training session information with different behavioral patterns and corresponding Web application types; The construction module is specifically used to obtain aggregated features between the first node and the second node for any first node in the session graph, based on the weight of the edge between the first node and the second node and the features of the second node, thereby forming an aggregated feature matrix between nodes; the second node is any node in the session graph other than the first node; and the aggregated feature matrix is ​​subjected to at least two convolution operations using multi-scale convolution kernels to obtain the graph feature matrix of the session graph.

8. An electronic device, characterized in that, include: Memory, used to store program instructions; A processor is configured to invoke program instructions stored in the memory and execute the steps of the method according to any one of claims 1-6.

9. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a computer program, the computer program including program instructions that, when executed by a computer, cause the computer to perform the method as described in any one of claims 1-6.

Citation Information

Patent Citations

  • Dialogue recommendation method, system and equipment based on knowledge graph and time sequence characteristics

    CN113360615A

  • Graph neural network-based session recommendation method and system fused with self-attention mechanism

    CN114971784A