A network intrusion detection method, device, electronic device and storage medium

By preprocessing and feature extraction of network traffic data, combined with deep learning models and CatBoost algorithms, network intrusion types are identified, solving the problems of traditional technology being difficult to deal with complex threats and high false alarm rates, and achieving more efficient network intrusion detection.

CN117792737BActive Publication Date: 2024-09-10GUANGZHOU RONGLIANZHI INFORMATION TECHNOLOGY CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202311808264.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-12-26
Publication Date
2024-09-10
Estimated Expiration
2043-12-26

AI Technical Summary

Technical Problem

Traditional network intrusion detection technology is difficult to effectively deal with complex and changing network threats, and suffers from high false alarm rates and insufficient data processing capabilities.

Method used

By obtaining network traffic data, preprocessing and feature extraction are performed, and feature importance scores are calculated. The pre-trained deep learning model is combined with the CatBoost algorithm to identify network intrusion types and improve detection accuracy.

Benefits of technology

It significantly improves the accuracy and real-time response capabilities of network intrusion detection, reduces the false alarm rate, and can effectively identify complex network attack patterns.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117792737B
    Figure CN117792737B
Patent Text Reader

Abstract

The present invention discloses a network intrusion detection method, device, electronic device and storage medium, which are used to improve the accuracy of network intrusion detection. The present invention comprises: obtaining network flow data; preprocessing the network flow data to obtain preprocessed data; extracting network features from the preprocessed data; calculating the importance score of the network features, and determining key features according to the importance score; inputting the key features into a pre-trained deep learning model to identify the type of network intrusion.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of network detection technology, and in particular to a network intrusion detection method, device, electronic equipment and storage medium. Background Art

[0002] As a key component of network security, the development of network intrusion detection has undergone a transformation from rule-based systems to anomaly-based systems.

[0003] In the early days, rule-based systems relied on fixed pattern matching to identify attacks, but this approach could not effectively cope with increasingly complex and changing network threats. With the continuous evolution of the network environment and the increasing sophistication of attack methods, traditional intrusion detection technology faces more and more challenges.

[0004] Anomaly-based detection systems attempt to address this problem by identifying abnormal patterns in network behavior, but these systems often have high false positive rates and limited ability to identify new or complex attack patterns. In addition, with the surge in network traffic and data volume, the ability of these systems to process data and respond in real time has been severely tested. Summary of the invention

[0005] The present invention provides a network intrusion detection method, device, electronic equipment and storage medium, which are used to improve the accuracy of network intrusion detection.

[0006] The present invention provides a network intrusion detection method, comprising:

[0007] Get network traffic data;

[0008] Preprocessing the network traffic data to obtain preprocessed data;

[0009] extracting network features from the preprocessed data;

[0010] Calculating importance scores of the network features, and determining key features based on the importance scores;

[0011] The key features are input into a pre-trained deep learning model to identify the type of network intrusion.

[0012] Optionally, the step of calculating the importance score of the network feature and determining the key feature according to the importance score includes:

[0013] Calculate the importance score of the network feature by using CatBoost algorithm;

[0014] According to the magnitude of the importance scores, a preset number of key features are extracted from the network features in descending order.

[0015] Optionally, the step of preprocessing the network traffic data to obtain preprocessed data includes:

[0016] Normalizing the network traffic data to obtain normalized data;

[0017] Regularization processing is performed on the normalized data to obtain preprocessed data.

[0018] Optionally, it also includes:

[0019] Acquire historical network traffic data; the historical network traffic data includes historical network features and corresponding labels;

[0020] Convert the format of the label to obtain a numerical label;

[0021] Splitting the historical network features and corresponding numerical labels into a training set and a test set;

[0022] Inputting the training set into a preset deep learning model to obtain a classification result;

[0023] Using the test set to verify the error rate of the classification result;

[0024] The deep model is adjusted according to the error rate until the error rate meets a preset condition, thereby obtaining a pre-trained deep learning model.

[0025] The present invention also provides a network intrusion detection device, comprising:

[0026] A network flow data acquisition module is used to acquire network flow data;

[0027] A preprocessing module, used for preprocessing the network flow data to obtain preprocessed data;

[0028] A network feature extraction module, used to extract network features from the preprocessed data;

[0029] A key feature determination module, used to calculate the importance score of the network feature and determine the key feature according to the importance score;

[0030] The network intrusion type identification module is used to input the key features into a pre-trained deep learning model to identify the network intrusion type.

[0031] Optionally, the key feature determination module includes:

[0032] An importance score calculation submodule, used to calculate the importance score of the network feature by using a CatBoost algorithm;

[0033] The key feature extraction submodule is used to extract a preset number of key features from the network features in descending order according to the importance scores.

[0034] Optionally, the preprocessing module includes:

[0035] A normalization submodule, used for normalizing the network traffic data to obtain normalized data;

[0036] The regularization submodule is used to perform regularization processing on the normalized data to obtain preprocessed data.

[0037] Optionally, it also includes:

[0038] A historical network traffic data acquisition module is used to acquire historical network traffic data; the historical network traffic data includes historical network features and corresponding labels;

[0039] A format conversion module, used to convert the format of the label to obtain a numerical label;

[0040] A splitting module, used for splitting the historical network features and the corresponding numerical labels into a training set and a test set;

[0041] A classification module, used to input the training set into a preset deep learning model to obtain a classification result;

[0042] A verification module, used to verify the error rate of the classification result using the test set;

[0043] An adjustment module is used to adjust the deep model according to the error rate until the error rate meets a preset condition to obtain a pre-trained deep learning model.

[0044] The present invention also provides an electronic device, the device comprising a processor and a memory:

[0045] The memory is used to store program code and transmit the program code to the processor;

[0046] The processor is used to execute any one of the above network intrusion detection methods according to the instructions in the program code.

[0047] The present invention also provides a computer-readable storage medium, wherein the computer-readable storage medium is used to store program code, and the program code is used to execute the network intrusion detection method as described in any one of the above items.

[0048] It can be seen from the above technical scheme that the present invention has the following advantages: the present invention obtains network traffic data; pre-processes the network traffic data to obtain pre-processed data; extracts network features from the pre-processed data; calculates the importance score of the network features, and determines the key features according to the importance score; inputs the key features into the pre-trained deep learning model to identify the network intrusion type. This improves the accuracy of network intrusion detection. BRIEF DESCRIPTION OF THE DRAWINGS

[0049] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative labor.

[0050] Figure 1 A flowchart of a network intrusion detection method provided by an embodiment of the present invention;

[0051] Figure 2 A flowchart of a network intrusion detection method provided by another embodiment of the present invention;

[0052] Figure 3 A structural block diagram of a network traffic detection device provided by an embodiment of the present invention. DETAILED DESCRIPTION

[0053] The embodiments of the present invention provide a network intrusion detection method, device, electronic device and storage medium, which are used to improve the accuracy of network intrusion detection.

[0054] In order to make the purpose, features and advantages of the present invention more obvious and easy to understand, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the embodiments described below are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0055] See also Figure 1 , Figure 1 A flowchart of the steps of a network intrusion detection method provided by an embodiment of the present invention.

[0056] The present invention provides a network intrusion detection method, which may specifically include the following steps:

[0057] Step 101, obtaining network traffic data;

[0058] In the embodiment of the present invention, the network traffic data may include normal network traffic and various network attacks (eg, DoS, SQL injection, etc.).

[0059] Step 102, preprocessing the network traffic data to obtain preprocessed data;

[0060] After obtaining the network traffic data, you can perform preliminary cleaning on the network traffic data, remove irrelevant or missing data points, convert non-numerical features into numerical features, and perform one-hot encoding, minimum and maximum value normalization processing to obtain the preprocessed network traffic data.

[0061] Step 103, extracting network features from network traffic data;

[0062] After completing data preprocessing, network features can be extracted from the preprocessed network traffic data.

[0063] Among them, network characteristics can include packet size, traffic duration, source and destination IP addresses, etc.

[0064] Step 104, calculating the importance scores of the network features, and determining the key features according to the importance scores;

[0065] After obtaining the network features, the importance score of each network feature is calculated, and the key features are determined based on the importance score.

[0066] Step 105: input the key features into the pre-trained deep learning model to identify the type of network intrusion.

[0067] Deep learning is the process of learning the internal laws and representation levels of sample data. The information obtained in the learning process is very helpful for interpreting data such as text, images, and sounds. Its ultimate goal is to enable machines to have analytical learning capabilities like humans and to recognize data such as text, images, and sounds.

[0068] After obtaining the key features, the key features can be input into a preset pre-trained deep learning model to identify the type of network intrusion.

[0069] The present invention obtains network traffic data; pre-processes the network traffic data to obtain pre-processed data; extracts network features from the pre-processed data; calculates the importance scores of network features and determines key features according to the importance scores; inputs the key features into a pre-trained deep learning model to identify network intrusion types, thereby improving the accuracy of network intrusion detection.

[0070] See also Figure 2 , Figure 2 A flowchart of a network intrusion detection method provided by another embodiment of the present invention. Specifically, the following steps may be included:

[0071] Step 201, obtaining network traffic data;

[0072] Step 202, preprocessing the network traffic data to obtain preprocessed data;

[0073] In this embodiment of the present invention, step 202 may include the following sub-steps:

[0074] S21, normalizing the network traffic data to obtain normalized data;

[0075] S22, performing regularization processing on the normalized data to obtain preprocessed data.

[0076] Normalization is to scale the values ​​of network traffic data to [0, 1] to ensure that the values ​​of different network traffic data are on a similar scale. For each data x to be normalized, the normalization is performed using the following formula:

[0077]

[0078] Among them, x' is the normalized data, max(x) is the maximum value in the network traffic data, and min(x) is the minimum value in the network traffic data.

[0079] After normalization, the normalized data is regularized. For example, L2 regularization is used. The corresponding formula for the loss term of L2 regularization is as follows:

[0080]

[0081] Among them, L(W) represents the loss without regularization, λ is the hyperparameter of regularization strength, Represents the square of the weight parameter. The role of this square term is to penalize the absolute value of the parameter in the model that is too large.

[0082] Step 203, extracting network features from the preprocessed data;

[0083] Step 204, calculating the importance score of the network feature by using the CatBoost algorithm;

[0084] The CatBoost algorithm is a GBDT framework based on oblivious trees, which has fewer parameters, supports categorical variables and has high accuracy. The main pain point it solves is to handle categorical features in a funny and reasonable way. CatBoost consists of Catgorical and Boosting. In addition, CatBoost also solves the problems of gradient bias and prediction shift, thereby reducing the occurrence of overfitting and improving the accuracy and generalization ability of the algorithm.

[0085] In an embodiment of the present invention, the CatBoost algorithm may be used to calculate the importance score of network features. The relevant formula is as follows:

[0086]

[0087] Where N is the number of trees, that is, the number of iterations, and T n The label of the tree. Represents the global importance of network feature j.

[0088]

[0089] Where L is the number of leaf nodes in the tree, L-1 is the number of non-leaf nodes in the tree, and f t is the function associated with node t, is the reduction in squared loss after node t is split. The more times it is reduced, The greater the gain from the split, Represents the importance score of network feature j in decision tree T.

[0090] Step 205, extracting a preset number of key features from the network features in descending order according to the importance scores;

[0091] After obtaining the importance score of each network feature, the network features may be sorted according to the importance score, and a preset number of network features with high importance scores may be obtained as key features.

[0092] Step 206: input the key features into the pre-trained deep learning model to identify the type of network intrusion.

[0093] After obtaining the key features, the key features can be input into a preset pre-trained deep learning model to identify the type of network intrusion.

[0094] In one example, the training process of the pre-trained deep learning model may include the following steps:

[0095] S1, obtaining historical network traffic data; the historical network traffic data includes historical network features and corresponding labels;

[0096] S2, convert the format of the label to obtain a numerical label;

[0097] S3, split the historical network features and the corresponding numerical labels into training sets and test sets;

[0098] S4, input the training set into the preset deep learning model to obtain the classification result;

[0099] S5, the error rate of the classification results verified using the test set;

[0100] S6, adjusting the deep learning model according to the error rate until the error rate meets the preset conditions, thereby obtaining a pre-trained deep learning model.

[0101] In a specific implementation, pre-processed historical network traffic data may be loaded, wherein the historical network traffic data may include a variety of historical network features and their corresponding labels.

[0102] Then use LabelEncoder to convert the string-formatted labels into numeric labels that the model can handle.

[0103] After completing the initial processing of the features and labels of the historical network traffic data, the historical network features and their corresponding numerical labels can be split into training sets and test sets. In an example, the train_test_split method can be used to divide the test set at a ratio of 20% to ensure the distribution consistency of the training set and the test set on various samples.

[0104] Then, feature selection is performed on the data of the data set to select key features to reduce the complexity of the model. The specific process can refer to the above steps 203-204.

[0105] The extracted key features are then input into the deep learning model for model training.

[0106] In one example, the deep learning model can select the CNN Inception V1 model. The CNN Inception V1 model learns complex patterns and associations in the data through 2 combined layers formed by 3 convolutional layers, separate convolutional layers, fully connected layers, and flat layers. The model training further adjusts multiple parameters (such as the number and size of convolutional layers, activation function types, etc.) to optimize model performance. The basis of the CNN Inception V1 model is its multi-layer convolutional network structure, in which each layer of convolution operation can be expressed as:

[0107] a i =g(wi *a i-1 +b i )

[0108] Among them, a i represents the activation value of the i-th layer, w i and b i are the weight and bias of the i-th layer, g is the activation function, and * represents the convolution operation. Then, the softmax function is used for multi-classification and the sigmoid function is used for binary classification to obtain the classification results.

[0109] After completing model training, the performance of the model on different data subsets can be evaluated through cross-validation. Specifically, the dataset is divided into K subsets, and K training and validation are performed, each time using a different subset as the validation set. The performance of cross-validation can be evaluated by the following formula, where Errork is the error rate of the kth validation:

[0110]

[0111] According to the verification results, adjust parameters such as learning rate σ and batch size to further improve accuracy and reduce false positives. The learning rate adjustment can refer to the following formula, where L is the loss function, and They are the gradients of the loss function with respect to weights and biases:

[0112]

[0113] The present invention obtains network traffic data; pre-processes the network traffic data to obtain pre-processed data; extracts network features from the pre-processed data; calculates the importance scores of network features and determines key features according to the importance scores; inputs the key features into a pre-trained deep learning model to identify network intrusion types, thereby improving the accuracy of network intrusion detection.

[0114] See also Figure 3 , Figure 3 A structural block diagram of a network traffic detection device provided by an embodiment of the present invention.

[0115] An embodiment of the present invention provides a network intrusion detection device, including:

[0116] The network flow data acquisition module 301 is used to acquire network flow data;

[0117] A preprocessing module 302 is used to preprocess the network traffic data to obtain preprocessed data;

[0118] A network feature extraction module 303 is used to extract network features from preprocessed data;

[0119] A key feature determination module 304 is used to calculate the importance scores of network features and determine key features according to the importance scores;

[0120] The network intrusion type identification module 305 is used to input key features into the pre-trained deep learning model to identify the network intrusion type.

[0121] In the embodiment of the present invention, the key feature determination module 304 includes:

[0122] The importance score calculation submodule is used to calculate the importance score of network features through the CatBoost algorithm;

[0123] The key feature extraction submodule is used to extract a preset number of key features from the network features in descending order according to the importance scores.

[0124] In this embodiment of the present invention, the preprocessing module 302 includes:

[0125] A normalization submodule is used to normalize the network traffic data to obtain normalized data;

[0126] The regularization submodule is used to perform regularization processing on the normalized data to obtain preprocessed data.

[0127] In an embodiment of the present invention, it also includes:

[0128] A historical network traffic data acquisition module is used to acquire historical network traffic data; the historical network traffic data includes historical network features and corresponding labels;

[0129] The format conversion module is used to convert the format of the label to obtain a numerical label;

[0130] Splitting module, used to split historical network features and corresponding numerical labels into training set and test set;

[0131] The classification module is used to input the training set into the preset deep learning model to obtain the classification results;

[0132] A verification module is used to verify the error rate of the classification results using a test set;

[0133] The adjustment module is used to adjust the deep model according to the error rate until the error rate meets the preset conditions to obtain a pre-trained deep learning model.

[0134] An embodiment of the present invention further provides an electronic device, the device comprising a processor and a memory:

[0135] The memory is used to store the program code and transmit the program code to the processor;

[0136] The processor is used to execute the network intrusion detection method of the embodiment of the present invention according to the instructions in the program code.

[0137] The embodiment of the present invention further provides a computer-readable storage medium, which is used to store program codes, and the program codes are used to execute the network intrusion detection method of the embodiment of the present invention.

[0138] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working processes of the systems, devices and units described above can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.

[0139] The various embodiments in this specification are described in a progressive manner, and each embodiment focuses on the differences from other embodiments. The same or similar parts between the various embodiments can be referenced to each other.

[0140] It will be appreciated by those skilled in the art that the embodiments of the present invention may be provided as methods, devices, or computer program products. Therefore, the embodiments of the present invention may take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Moreover, the embodiments of the present invention 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 codes.

[0141] The embodiments of the present invention are described with reference to the flowcharts and / or block diagrams of the methods, terminal devices (systems), and computer program products according to the embodiments of the present invention. It should be understood that each process and / or block in the flowchart and / or block diagram, as well as the combination of the processes and / or blocks in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing terminal device to generate a machine, so that the instructions executed by the processor of the computer or other programmable data processing terminal device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.

[0142] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing terminal device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce a manufactured product including an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1A function specified in one or more boxes.

[0143] These computer program instructions can also be loaded onto a computer or other programmable data processing terminal device so that a series of operating steps are executed on the computer or other programmable terminal device to produce a computer-implemented process, thereby providing instructions for executing on the computer or other programmable terminal device to implement the process. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.

[0144] Although the preferred embodiments of the present invention have been described, those skilled in the art may make additional changes and modifications to these embodiments once they have learned the basic creative concept. Therefore, the appended claims are intended to be interpreted as including the preferred embodiments and all changes and modifications that fall within the scope of the embodiments of the present invention.

[0145] Finally, it should be noted that, in this article, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or terminal device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or terminal device. In the absence of further restrictions, the elements defined by the sentence "comprise a ..." do not exclude the existence of other identical elements in the process, method, article or terminal device including the elements.

[0146] As described above, the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit the same. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that the technical solutions described in the aforementioned embodiments may still be modified, or some of the technical features thereof may be replaced by equivalents. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present invention.

Claims

1. A network intrusion detection method, characterized in that: include: Get network traffic data; Preprocessing the network traffic data to obtain preprocessed data; extracting network features from the preprocessed data; Calculating importance scores of the network features, and determining key features based on the importance scores; Inputting the key features into a pre-trained deep learning model to identify the type of network intrusion; Among them, it also includes: Acquire historical network traffic data; the historical network traffic data includes historical network features and corresponding labels; Convert the format of the label to obtain a numerical label; Splitting the historical network features and corresponding numerical labels into a training set and a test set; Inputting the training set into a preset deep learning model to obtain a classification result; Using the test set to verify the error rate of the classification result; Adjusting the deep learning model according to the error rate until the error rate meets a preset condition, thereby obtaining a pre-trained deep learning model; The calculation formula of error rate is as follows: Among them, Errork is the error rate of the kth verification, and K is the number of verification sets; The step of calculating the importance score of the network feature and determining the key feature according to the importance score includes: Calculate the importance score of the network feature by using CatBoost algorithm; According to the magnitude of the importance score, extracting a preset number of key features from the network features in descending order; The CatBoost algorithm is used to calculate the importance score of network features; the relevant formula is as follows: Where N is the number of trees, that is, the number of iterations, and T n The label of the tree. Represents the global importance of network feature j; Where L is the number of leaf nodes in the tree, L-1 is the number of non-leaf nodes in the tree, and f t is the function associated with node t, is the reduction in squared loss after node t is split. The more times it is reduced, The greater the gain from the split, Represents the importance score of network feature j in decision tree T; The deep learning model selected is the CNN InceptionV1 model. The CNN InceptionV1 model learns complex patterns and associations in data through 2 combined layers formed by 3 convolutional layers, a single convolutional layer, a fully connected layer, and a flat layer. The basis of the CNNInceptionV1 model is its multi-layer convolutional network structure, in which each layer of convolution operation can be expressed as: a i =g(w i *a i-1 +b i ) Among them, a i represents the activation value of the i-th layer, w i and b i are the weight and bias of the i-th layer respectively, g is the activation function, and * represents the convolution operation; then multi-classification is performed through the softmax function, and binary classification is performed through sigmoid to obtain the classification results.

2. The method according to claim 1, characterized in that The step of preprocessing the network traffic data to obtain preprocessed data includes: Normalizing the network traffic data to obtain normalized data; Regularization processing is performed on the normalized data to obtain preprocessed data.

3. A network intrusion detection device, characterized in that: include: A network flow data acquisition module is used to acquire network flow data; A preprocessing module, used for preprocessing the network flow data to obtain preprocessed data; A network feature extraction module, used to extract network features from the preprocessed data; A key feature determination module, used to calculate the importance score of the network feature and determine the key feature according to the importance score; A network intrusion type identification module, used to input the key features into a pre-trained deep learning model to identify the network intrusion type; Among them, it also includes: A historical network traffic data acquisition module is used to acquire historical network traffic data; the historical network traffic data includes historical network features and corresponding labels; A format conversion module, used to convert the format of the label to obtain a numerical label; A splitting module, used for splitting the historical network features and the corresponding numerical labels into a training set and a test set; A classification module, used to input the training set into a preset deep learning model to obtain a classification result; A verification module, used to verify the error rate of the classification result using the test set; An adjustment module, used for adjusting the deep learning model according to the error rate until the error rate meets a preset condition, thereby obtaining a pre-trained deep learning model; The calculation formula of error rate is as follows: Among them, Errork is the error rate of the kth verification, and K is the number of verification sets; Wherein, the key feature determination module includes: An importance score calculation submodule, used to calculate the importance score of the network feature by using a CatBoost algorithm; A key feature extraction submodule, used to extract a preset number of key features from the network features in descending order according to the importance scores; The CatBoost algorithm is used to calculate the importance score of network features; the relevant formula is as follows: Where N is the number of trees, that is, the number of iterations, and T n The label of the tree. Represents the global importance of network feature j; Where L is the number of leaf nodes in the tree, L-1 is the number of non-leaf nodes in the tree, and f t is the function associated with node t, is the reduction in squared loss after node t is split. The more times it is reduced, The greater the gain from the split, Represents the importance score of network feature j in decision tree T; The deep learning model selected is the CNN InceptionV1 model. The CNN InceptionV1 model learns complex patterns and associations in data through 2 combined layers formed by 3 convolutional layers, a single convolutional layer, a fully connected layer, and a flat layer. The basis of the CNNInceptionV1 model is its multi-layer convolutional network structure, in which each layer of convolution operation can be expressed as: a i =g(w i *a i-1 +b i ) Among them, a i represents the activation value of the i-th layer, w i and b i are the weight and bias of the i-th layer respectively, g is the activation function, and * represents the convolution operation; then multi-classification is performed through the softmax function, and binary classification is performed through sigmoid to obtain the classification results.

4. The device according to claim 3, characterized in that The preprocessing module comprises: A normalization submodule, used for normalizing the network traffic data to obtain normalized data; The regularization submodule is used to perform regularization processing on the normalized data to obtain preprocessed data.

5. An electronic device, characterized in that: The device comprises a processor and a memory: The memory is used to store program code and transmit the program code to the processor; The processor is used to execute the network intrusion detection method according to any one of claims 1-2 according to the instructions in the program code.

6. A computer-readable storage medium, characterized in that: The computer-readable storage medium is used to store program code, and the program code is used to execute the network intrusion detection method according to any one of claims 1-2.