ICMPv6-DDoS attack detection method and system based on feature optimization

By constructing a feature selection method with high discriminative feature subsets and recall gating, the problems of insufficient feature expression and weak security constraints in ICMPv6-DDoS detection are solved, realizing efficient and reliable ICMPv6-DDoS attack detection, which is suitable for security monitoring of IPv6 LANs, campus networks and data center networks.

CN122372309APending Publication Date: 2026-07-10GUANGZHOU UNIVERSITY
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202610626305.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-05-08
Publication Date
2026-07-10

Smart Images

  • Figure CN122372309A_ABST
    Figure CN122372309A_ABST
Patent Text Reader

Abstract

The application provides an ICMPv6- DDoS attack detection method and system based on feature optimization, belongs to the technical field of cyberspace security, and solves the core problems of insufficient feature representation ability, missing security target constraint and high feature space redundancy of the existing detection method. The application first performs traffic aggregation and basic feature data extraction on ICMPv6 traffic, constructs an extended feature set, removes redundant features to obtain a low-redundancy candidate feature set, then completes two-stage feature selection through information gain rate filtering and an improved binary particle swarm optimization algorithm with recall rate constraint, outputs an optimal feature subset, and finally constructs a detection model based on the optimal feature subset to complete attack detection. The application significantly improves the attack detection rate, balances the detection accuracy and model lightweight, and can be widely applied to various IPv6 network security monitoring scenes.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of cyberspace security and network traffic anomaly detection technology, and in particular to a feature-optimized ICMPv6-DDoS attack detection method and system, which can be applied to IPv6 LANs, campus networks, data center networks and other network security monitoring scenarios that use the ICMPv6 neighbor discovery mechanism. Background Technology

[0002] With the large-scale deployment of IPv6, basic control functions such as address resolution, neighbor discovery, and route advertisement have been integrated into ICMPv6 and its neighbor discovery protocol mechanism. ICMPv6 has become a key control protocol for ensuring the normal operation of IPv6 networks. Attackers can launch flooding, resource-consuming, or covert distributed denial-of-service (DDoS) attacks by forging control messages such as neighbor requests, neighbor advertisements, and route advertisements, or by constructing malformed ICMPv6 messages. This can rapidly exhaust the computing, cache, and link resources of target hosts, switching devices, or security devices, affecting network availability.

[0003] Existing ICMPv6-DDoS detection methods mainly include rule-based detection methods, traditional machine learning-based detection methods, and feature selection methods combining metaheuristic algorithms. Existing rule-based methods generally rely on fixed thresholds, protocol constants, or manual empirical rules, resulting in poor adaptability and difficulty in dealing with variant attacks constructed by attackers through rate control, packet length perturbation, and message type spoofing. Existing machine learning methods mostly rely directly on coarse-grained raw flow statistics, such as flow duration, total number of packets, total number of bytes, and message length statistics; these features have a certain ability to characterize the macroscopic scale of traffic, but are insufficient for representing deep behavioral patterns such as short-term bursts, structural regularities, and contextual deviations. Especially when ICMPv6 attack flows and normal burst flows are highly similar at the statistical level, existing feature spaces are prone to semantic blind spots, making it difficult for classifiers to form clear decision boundaries.

[0004] Furthermore, existing feature selection and model optimization methods typically use overall accuracy, F1 score, or general classification error as optimization targets, assuming that the costs of false positives and false negatives are approximately symmetrical. However, in ICMPv6-DDoS defense scenarios, a false negative means that a malicious attack stream has successfully penetrated the detection mechanism and entered the network control plane, potentially causing neighbor anomaly detection, routing maintenance failure, and critical service interruption, resulting in security consequences far exceeding those of false positives. If an accuracy-driven optimization logic is still adopted, the model may sacrifice recall to reduce false positives, making it difficult to meet the practical protection requirements of "security first."

[0005] Therefore, there is an urgent need to propose an ICMPv6-DDoS attack detection method that can construct highly discriminative semantic features from raw fields of limited flow levels, and explicitly guarantee high recall while taking into account false positive rate and feature size during feature selection. Summary of the Invention

[0006] The purpose of this invention is to provide a feature-optimized ICMPv6-DDoS attack detection method and system, which aims to solve the key problems of current ICMPv6-DDoS attack detection methods, such as insufficient feature representation ability, weak security target constraints, and high feature space redundancy.

[0007] According to one objective of the present invention, the present invention provides a feature-optimized ICMPv6-DDoS attack detection method, comprising the following steps: S1. Traffic Aggregation and Basic Feature Data Extraction: Collect raw ICMPv6 traffic in an IPv6 network environment, perform traffic aggregation processing on data packets according to preset traffic aggregation identifiers, group data packets with the same traffic aggregation identifier into a traffic record within a preset time window, and extract the basic feature data corresponding to each traffic record. S2. Extended Feature Generation: Based on the basic feature data obtained in step S1, perform feature dimension extension processing to generate an extended feature set for identifying ICMPv6-DDoS attack behavior. S3. Redundant feature removal: Redundancy removal is performed on the extended feature set obtained in step S2. The correlation coefficient matrix between all extended features is calculated. The upper triangular region of the correlation coefficient matrix is ​​traversed to remove highly correlated redundant features and obtain a low-redundancy candidate feature set. S4. First-stage feature selection: The information gain ratio is used to score and rank the features in the candidate feature set obtained in step S3, and the top k high-discrimination features are selected to form a subset of candidate features. S5. Feature Evaluation Rule Configuration: Construct a segmented feature evaluation function with recall constraints, and set a minimum threshold constraint for recall for feature search; when the detection recall of the feature combination is lower than the preset safety threshold, the score is reduced only based on the recall; when the recall reaches or exceeds the preset safety threshold, a comprehensive score is applied based on the recall, false positive rate and feature size. S6. Second stage feature optimization: Using the candidate feature subset obtained in step S4 as the optimization range, the improved binary particle swarm optimization algorithm is used to optimize the feature combination. During the optimization process, a dynamic inertia weight adjustment strategy and a random escape mutation strategy are introduced. Combined with the piecewise feature evaluation function in step S5, iterative optimization is performed, and the globally optimal feature combination is output as the optimal feature subset. S7. Model Training and Attack Detection: In the feature optimization stage, the first classification configuration is used to complete the rapid scoring of the feature combination corresponding to the particle. After the optimization is completed, the second classification configuration is used to train the model and verify the performance of the optimal feature subset to obtain the ICMPv6-DDoS attack detection model. After the ICMPv6 traffic to be tested is processed through steps S1 to S3, it is input into the detection model, and the output traffic is the detection result of normal traffic or attack traffic.

[0008] Further, in step S1, the traffic aggregation identifier includes at least the source IPv6 address, the destination IPv6 address, and the ICMPv6 message type; the basic feature data includes at least one or more of the following: total number of packets, total number of bytes, traffic duration, average packet length, packet length statistics, packet arrival time statistics, and ICMPv6 message type.

[0009] Further, in step S2, the extended feature set includes at least rate dynamic features, structural regularity features, context deviation features, and unsupervised anomaly identification features; wherein, the rate dynamic features are used to characterize the instantaneous transmission intensity and dynamic changes of the load of traffic, the structural regularity features are used to characterize the fixed transmission pattern and burst transmission characteristics of attack traffic, the context deviation features are used to characterize the differences in traffic behavior corresponding to the same ICMPv6 message type, and the unsupervised anomaly identification features are used to improve the ability to identify unknown attack patterns.

[0010] Furthermore, in step S3, a feature correlation coefficient matrix is ​​constructed using the Pearson correlation coefficient, with a preset correlation threshold of 0.85-0.95; when the absolute value of the correlation coefficient between any two features is greater than the preset correlation threshold, the features that are traversed first are retained, and the redundant features that are traversed later are deleted.

[0011] Furthermore, in step S5, during the comprehensive scoring process, a parabolic linear weighting is set for the number of features to avoid redundant features being selected into the optimal feature subset.

[0012] Furthermore, in step S6, a binary vector is used to represent the feature selection of the particle, and each bit of the binary vector corresponds to a candidate feature; the dynamic inertial weight adjustment strategy is that the weight decreases linearly with the number of iterations, and the random escape mutation strategy is: when the particle is in a state of all zeros, the optimization result has no updated state, or the 5% random trigger probability is met, the state flip operation is performed on the three randomly selected feature bits.

[0013] Furthermore, in step S7, the first classification configuration is a lightweight classifier parameter configuration, which is used to improve the scoring efficiency in the feature optimization process; the second classification configuration is a full classifier parameter configuration, which is used to ensure the classification accuracy of the final detection model.

[0014] A feature-optimized ICMPv6-DDoS attack detection system is provided to implement the aforementioned feature-optimized ICMPv6-DDoS attack detection method. The system includes a data acquisition module, a traffic aggregation and basic feature extraction module, an extended feature generation module, a redundant feature removal module, a two-stage feature screening module, a feature evaluation rule configuration module, a feature combination optimization module, and a model training and traffic detection module, which are connected in sequence. The data acquisition module is used to collect raw ICMPv6 traffic in the IPv6 network environment; The traffic aggregation and basic feature extraction module is used to generate corresponding traffic records according to preset traffic aggregation identifiers and time windows, and extract basic feature data for each traffic record. The extended feature generation module is used to generate an extended feature set for identifying ICMPv6-DDoS attack behavior based on the basic feature data. The redundant feature removal module is used to remove highly correlated redundant features in the extended feature set and output a low-redundancy candidate feature set. The two-stage feature filtering module is used to complete the first-stage feature filtering by information gain ratio and generate a subset of candidate features. The feature evaluation rule configuration module is used to configure a segmented feature evaluation function with recall constraints and set a minimum recall threshold constraint. The feature combination optimization module is used to complete the second stage of feature combination optimization using an improved binary particle swarm optimization algorithm and output the optimal feature subset. The model training and traffic detection module is used to complete model training and performance verification based on the optimal feature subset, and to classify and detect normal traffic and attack traffic in the ICMPv6 traffic under test.

[0015] Furthermore, the feature combination optimization module incorporates an inertial weight adjustment unit and a random mutation execution unit. The inertial weight adjustment unit is used to perform a dynamic inertial weight adjustment operation that decreases linearly with the number of iterations, and the random mutation execution unit is used to perform a random escape mutation operation.

[0016] A computer device includes a processor and a memory, the memory storing a computer program, and the processor executing the computer program to implement the above-described feature-optimized ICMPv6-DDoS attack detection method.

[0017] The technical solution of this invention addresses the shortcomings of traditional coarse-grained flow statistical features in representing covert ICMPv6-DDoS attacks through flow-level aggregation and semantic enhancement feature construction, significantly improving the separability of attack flows from normal burst flows. Through correlation compression and two-stage feature selection, highly redundant features are effectively eliminated, reducing the feature space dimensionality and model computational overhead. A rigid security constraint of recall rate gating is introduced to prioritize attack detection capabilities, adapting to the needs of cybersecurity practice. Simultaneously, it balances low false positive rates and lightweight models, greatly improving the reliability, real-time performance, and engineering applicability of ICMPv6-DDoS attack detection. Attached Figure Description

[0018] To more clearly illustrate the specific embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the specific embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of the present invention. For those skilled in the art, other drawings can be obtained from these drawings without creative effort.

[0019] Figure 1 This is a schematic diagram of the overall framework of the method in an embodiment of the present invention; Figure 2 This is a flowchart illustrating an embodiment of the present invention; Figure 3 This is a schematic diagram of the multi-target feature screening process based on recall rate gating in an embodiment of the present invention. Detailed Implementation

[0020] The technical solution of the present invention will be clearly and completely described below with reference to the embodiments. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0021] Example 1 This embodiment provides a feature-optimized ICMPv6-DDoS attack detection method, the complete process of which is as follows: Figure 1 As shown, the specific steps are as follows: Step 1: Obtain raw traffic data and generate traffic records In IPv6 LAN, campus network, data center network, or other IPv6 network environments, collect ICMPv6 related traffic data through mirrored ports, traffic acquisition probes, or offline traffic files. This includes ICMPv6 control messages such as neighbor requests, neighbor advertisements, route advertisements, and redirects, as well as common ICMPv6 messages such as echo requests / responses.

[0022] The collected data packets are aggregated according to the source IPv6 address, destination IPv6 address, and ICMPv6 message type as traffic aggregation identifiers. A predetermined time window of 1 second is set, and data packets that meet the aggregation conditions within the same time window are grouped into one traffic record. Basic feature data is extracted from each traffic record, including total number of packets, total number of bytes, traffic duration, average packet length, maximum / minimum / standard deviation of packet length, average / standard deviation of packet arrival interval, and ICMPv6 message type.

[0023] Step 2: Generate an expanded feature set Based on the basic feature data extracted in step 1, feature dimension expansion processing is performed to generate a high-dimensional extended feature set for ICMPv6-DDoS attack detection, specifically including: (1) Rate dynamic characteristics: including packets per second (PPS), bytes per second (BPS), the coefficient of variation of packet arrival rate, and the peak to mean ratio of packet rate within the flow, which are used to reflect the dynamic changes in the number of packets and bytes per unit time and to characterize the short-term pulse characteristics of attack traffic; (2) Load characteristics: including the entropy value of message length distribution, the proportion of messages with the same packet length, and the proportion of consistent load content, which are used to reflect the differences in the length distribution of abnormal control messages and the mechanical characteristics of the load; (3) Structural regularity characteristics: including the coefficient of variation of message arrival interval, the proportion of burst interval, and the ratio of traffic duration to total number of packets, which are used to reflect the mechanical regularity, fluctuation and sudden change of attack flow, and to distinguish between traffic generated by automated attack tools and traffic generated by normal manual operation. (4) Context deviation features: including the deviation of the current flow average packet length from the normal baseline of the same message type, and the deviation of the current flow rate from the normal traffic of the same message type in the same network segment, used to characterize the behavioral differences under different ICMPv6 message types and identify disguised attack traffic; (5) Unsupervised anomaly identification features: The isolated forest model is used to perform unsupervised anomaly scoring on the full traffic records to generate anomaly scoring features, which are used to supplement the generalization ability to identify unknown attack patterns.

[0024] Through the above processing, the limited original flow-level basic feature data is expanded to form a complete extended feature set with strong discriminative ability in 42 dimensions.

[0025] Step 3: Perform redundant feature removal to obtain a set of candidate features with low redundancy. Calculate the Pearson correlation coefficient for any two features in the extended feature set generated in step 2, and construct a 42×42 feature correlation matrix. Traverse the upper triangular region of the correlation matrix to avoid duplicate feature pair calculations. Set a preset correlation threshold of 0.90. When the absolute value of the correlation coefficient between any subsequently traversed feature and the already retained features exceeds 0.90, the subsequently traversed feature is determined to be a redundant feature and deleted.

[0026] In this embodiment, after compression, 11 highly redundant features are removed, resulting in a 31-dimensional set of low-redundancy candidate features. This significantly reduces the subsequent optimization dimensionality and computational complexity. The specific compression process is as follows: Figure 2 As shown.

[0027] Step 4: Perform two-stage feature filtering First, the features in the 31-dimensional low-redundancy candidate feature set obtained in step 3 are scored and ranked using the information gain ratio. The higher the information gain ratio, the stronger the ability of the feature to distinguish between normal traffic and attack traffic. The top 20 high-discrimination features are selected to form a subset of candidate features.

[0028] Subsequently, using the 20-dimensional candidate feature subset as the optimization range, an improved binary particle swarm optimization algorithm with recall constraints is used for encapsulated optimization to obtain the optimal feature subset that balances detection performance and feature compactness.

[0029] Step 5: Perform the second stage of feature optimization. A 20-dimensional binary vector is used to represent the feature selection of each particle. Each bit in the vector corresponds to a candidate feature, with a value of 1 indicating that the candidate feature is selected and a value of 0 indicating that the candidate feature is not selected. The particle swarm size is initialized to 30, the maximum number of iterations is 50, and the particle position, velocity, individual optimal position, and global optimal position are initialized.

[0030] During the iteration process, a dynamic inertia weight adjustment strategy is executed according to the current iteration progress. The inertia weight decreases linearly from 0.9 to 0.4, balancing the global exploration capability in the early stage of iteration and the local convergence capability in the later stage of iteration. Subsequently, the particle state is updated according to the particle velocity update formula and the current position. When the particle reaches a state of all zeros, the optimization result has no update state after 5 consecutive iterations without improvement in score, or the 5% random trigger probability is met, a random escape mutation strategy is activated. The state flip operation is performed on the three random feature selection positions of the particle to improve the algorithm's ability to escape local optima.

[0031] Step 6: Perform segmented feature scoring with recall constraints The feature combination represented by the current particle is input into the random forest classifier (with 10 decision trees) configured for the first classification for rapid evaluation, obtaining the recall, false positive rate, and feature size. A safe threshold of 99.5% for recall is set, and segmented scoring is performed. When the recall rate is below 99.5%, the score after the score reduction is calculated based solely on the recall rate. The score = recall rate. Priority is given to ensuring the detection capability of attack traffic and guiding the particle swarm to converge towards the high recall rate area. When the recall rate reaches or exceeds 99.5%, a comprehensive score is calculated based on the recall rate, false positive rate, and feature size, using the following formula: Overall score = 0.6 × Recall rate - 0.3 × False positive rate - 0.1 × (Number of selected features / Total number of features) By using a parabolic linear weighting method to reduce the number of features, excessive redundant features are avoided, thus achieving a balance between detection performance and model lightweighting.

[0032] Based on the scoring results of each iteration, the individual optimal position and global optimal position of the particles are updated. The specific selection process is as follows: Figure 3 As shown.

[0033] Step 7: Construct the final detection model and output the detection results. After reaching the maximum number of iterations (50 rounds), the feature subset corresponding to the globally optimal particle is selected as the optimal feature subset. In this embodiment, the optimal feature subset is the 8-dimensional core features. A random forest classifier with a second classification configuration (100 decision trees) is used to complete the final model training and 5-fold cross-validation.

[0034] During actual detection, the traffic to be tested is processed according to steps 1 to 3 to generate a feature representation consistent with that of the training phase. Then, corresponding features are selected based on the optimal feature subset and input into the finally trained ICMPv6-DDoS attack detection model. The output shows whether the traffic is normal or attacking. When attacking traffic is detected, alarm information and blocking suggestions can be simultaneously output to the security operations and maintenance platform.

[0035] Through the above steps, the test results of this embodiment on the public ICMPv6-DDoS attack dataset are as follows: recall rate 99.72%, false positive rate 0.31%, and accuracy 99.68%. Compared with traditional detection methods, the recall rate is increased by 1.2 percentage points while the false positive rate is reduced by 0.8 percentage points and the feature dimension is reduced by more than 70%, which significantly improves detection performance and operating efficiency.

[0036] Example 2 This embodiment provides an ICMPv6-DDoS attack detection system to implement the detection method described in Embodiment 1. The system includes: The data acquisition module is used to acquire raw ICMPv6 packets in an IPv6 network environment through network mirroring ports, traffic acquisition probes, or offline files. The traffic aggregation and basic feature extraction module communicates with the data acquisition module and is used to generate corresponding traffic records based on the source IPv6 address, destination IPv6 address, ICMPv6 message type and preset time window rules, and extract the basic feature data of each traffic record. An extended feature generation module is communicatively connected to the traffic aggregation and basic feature extraction module. It is used to perform feature dimension expansion processing based on the basic feature data to generate an extended feature set composed of dynamic rate, structural regularity, context deviation and unsupervised anomaly recognition features. The redundant feature removal module communicates with the extended feature generation module to construct the feature correlation coefficient matrix, perform upper triangular greedy redundant feature removal, and output a set of candidate features with low redundancy. The two-stage feature selection module, which is connected to the redundant feature removal module, includes an IGR filtering unit, a particle swarm optimization unit, a feature scoring unit, and an optimal subset output unit. It is used to sequentially perform information gain rate filtering and improved binary particle swarm optimization with recall constraints, and output the optimal feature subset. The feature evaluation rule configuration module communicates with the two-stage feature selection module and is used to configure the segmented feature evaluation function with recall constraints and set the minimum recall threshold constraint. The feature combination optimization module communicates with the feature evaluation rule configuration module and has a built-in inertial weight adjustment unit and random mutation execution unit, which are used to perform the second-stage feature combination optimization. The model training and traffic detection module communicates with the feature combination optimization module. It is used to train a supervised learning classification model based on the optimal feature subset, build an ICMPv6-DDoS attack detection model, and perform binary classification of the ICMPv6 traffic to be tested as normal traffic / attack traffic. The results output module communicates with the model training and traffic detection modules and is used to output detection results, attack alarm information, traffic statistics information or traffic blocking suggestions to the security management platform, firewall protection platform or operation and maintenance alarm platform.

[0037] In this embodiment, the above modules can be integrated and deployed on the same detection server, or they can be distributed and deployed on traffic acquisition devices, edge computing nodes, core detection servers and security management platforms. The modules interact with each other through the intranet, which can adapt to IPv6 network deployment environments of different sizes.

[0038] Example 3 This embodiment provides an alternative implementation of the present invention. Without changing the core idea of ​​the present invention, the following flexible adjustments can be made: (1) The time window size can be configured and adjusted within the range of 100ms to 5s according to the traffic characteristics of the network environment; the correlation threshold can be adjusted within the range of 0.85-0.95; the information gain ratio screening scale Top-k can be configured within the range of 10-30 according to the dimension of the candidate feature set; the recall rate security threshold can be adjusted within the range of 99%-99.9% according to the protection level requirements; the particle swarm size, maximum number of iterations, dynamic inertial weight adjustment strategy and the trigger probability of random escape mutation strategy can all be adapted and adjusted according to the computing resources of the deployment environment; (2) In addition to being generated by the isolated forest model, the unsupervised anomaly detection features can also be generated by the local outlier (LOF) model, single-class support vector machine, autoencoder or other unsupervised anomaly detection algorithms. (3) In addition to using random forest, the final detection model can also be implemented using radial basis support vector machine, extreme random tree, XGBoost gradient boosting tree or other supervised learning models; (4) In the redundant feature removal process, in addition to Pearson correlation coefficient, Spearman correlation coefficient can also be used to calculate correlation. The upper triangular greedy deletion strategy can be replaced by a redundant removal strategy based on feature importance ranking. As long as the compression of highly correlated redundant features can be achieved, they are all equivalent replacement schemes of the present invention. (5) In addition to ICMPv6-DDoS attack detection, this invention can also be extended to other IPv6 control plane abnormal traffic identification, neighbor discovery anomaly detection, routing advertisement anomaly identification and similar network traffic anomaly detection scenarios.

[0039] Compared with the prior art, the present invention has at least the following beneficial effects: (1) This invention expands the feature dimension of the original flow level basic feature data to construct multiple extended features such as rate dynamics, structural regularity, context deviation and unsupervised anomaly recognition features, which can more fully reveal the behavioral characteristics of ICMPv6-DDoS attacks, solve the problem that traditional coarse-grained statistical features are insufficient for representing covert attacks, and significantly improve the separability of covert attack flow and normal burst flow. (2) In the feature selection process, the present invention introduces a segmented feature evaluation mechanism with recall rate constraint, which upgrades the recall rate from a common evaluation index to a rigid security constraint condition. This can prioritize the attack capture capability, reduce the risk of key malicious flows being missed, solve the problem of mismatch between traditional optimization goals and network security practical needs, and better meet the actual needs of IPv6 network control plane protection. (3) The present invention combines a three-level feature screening mechanism of redundant feature removal, information gain rate filtering and improved binary particle swarm optimization, which can effectively remove irrelevant and redundant features while ensuring detection effect, greatly reduce the feature space dimension, reduce model training overhead and deployment complexity, and improve the real-time performance and generalization performance of the detection system. (4) This invention effectively solves the problems of traditional binary particle swarm optimization algorithm being prone to getting trapped in local optima and having large iterative computation overhead by using dynamic inertia weight adjustment strategy, random escape mutation strategy and hierarchical evaluation strategy, thereby improving the optimization efficiency and stability of particle swarm in high-dimensional discrete feature space. (5) The method of the present invention has a clear implementation path and a high degree of modularity. It can be deployed as a software method on existing IPv6 security monitoring platforms, or embedded in hardware devices such as intrusion detection systems, border security gateways, and traffic analysis platforms. It has good engineering application value and promotion prospects.

[0040] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, and not to limit them; although the present invention 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; and these 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 the present invention.

Claims

1. A feature-optimized ICMPv6-DDoS attack detection method, characterized in that, Includes the following steps: S1. Traffic Aggregation and Basic Feature Data Extraction: Collect raw ICMPv6 traffic in an IPv6 network environment, perform traffic aggregation processing on data packets according to preset traffic aggregation identifiers, group data packets with the same traffic aggregation identifier into a traffic record within a preset time window, and extract the basic feature data corresponding to each traffic record. S2. Extended Feature Generation: Based on the basic feature data obtained in step S1, perform feature dimension extension processing to generate an extended feature set for identifying ICMPv6-DDoS attack behavior; S3. Redundant feature removal: Redundancy removal is performed on the extended feature set obtained in step S2. The correlation coefficient matrix between all extended features is calculated. The upper triangular region of the correlation coefficient matrix is ​​traversed to remove highly correlated redundant features and obtain a low-redundancy candidate feature set. S4. First-stage feature selection: The information gain ratio is used to score and rank the features in the candidate feature set obtained in step S3, and the top k high-discrimination features are selected to form a subset of candidate features. S5. Feature Evaluation Rule Configuration: Construct a segmented feature evaluation function with recall constraints, and set a minimum threshold constraint for recall for feature search; when the detection recall of the feature combination is lower than the preset safety threshold, the score is reduced only based on the recall; when the recall reaches or exceeds the preset safety threshold, a comprehensive score is applied based on the recall, false positive rate and feature size. S6. Second stage feature optimization: Using the candidate feature subset obtained in step S4 as the optimization range, the improved binary particle swarm optimization algorithm is used to optimize the feature combination. During the optimization process, a dynamic inertia weight adjustment strategy and a random escape mutation strategy are introduced. Combined with the piecewise feature evaluation function in step S5, iterative optimization is performed, and the globally optimal feature combination is output as the optimal feature subset. S7. Model Training and Attack Detection: In the feature optimization stage, the first classification configuration is used to complete the rapid scoring of the feature combination corresponding to the particle. After the optimization is completed, the second classification configuration is used to train the model and verify the performance of the optimal feature subset to obtain the ICMPv6-DDoS attack detection model. After the ICMPv6 traffic to be tested is processed through steps S1 to S3, it is input into the detection model, and the output traffic is the detection result of normal traffic or attack traffic.

2. The ICMPv6-DDoS attack detection method based on feature optimization according to claim 1, characterized in that, In step S1, the traffic aggregation identifier includes at least the source IPv6 address, the destination IPv6 address, and the ICMPv6 message type; the basic feature data includes at least one or more of the following: total number of packets, total number of bytes, traffic duration, average packet length, packet length statistics, packet arrival time statistics, and ICMPv6 message type.

3. The ICMPv6-DDoS attack detection method based on feature optimization according to claim 1, characterized in that, In step S2, the extended feature set includes at least rate dynamic features, structural regularity features, context deviation features, and unsupervised anomaly identification features; wherein, the rate dynamic features are used to characterize the instantaneous transmission intensity and dynamic changes of the load of traffic, the structural regularity features are used to characterize the fixed transmission pattern and burst transmission characteristics of attack traffic, the context deviation features are used to characterize the differences in traffic behavior corresponding to the same ICMPv6 message type, and the unsupervised anomaly identification features are used to improve the ability to identify unknown attack patterns.

4. The ICMPv6-DDoS attack detection method based on feature optimization according to claim 1, characterized in that, In step S3, a feature correlation coefficient matrix is ​​constructed using the Pearson correlation coefficient, with a preset correlation threshold of 0.85-0.

95. When the absolute value of the correlation coefficient between any two features is greater than the preset correlation threshold, the features that are traversed first are retained, and the redundant features that are traversed later are deleted.

5. The ICMPv6-DDoS attack detection method based on feature optimization according to claim 1, characterized in that, In step S5, during the comprehensive scoring process, a parabolic linear weighting is set for the number of features to avoid redundant features being selected into the optimal feature subset.

6. The ICMPv6-DDoS attack detection method based on feature optimization according to claim 1, characterized in that, In step S6, a binary vector is used to represent the feature selection of the particle, and each bit of the binary vector corresponds to a candidate feature. The dynamic inertial weight adjustment strategy is that the weight decreases linearly with the number of iterations. The random escape mutation strategy is that when the particle is in a state of all zeros, the optimization result has no updated state, or the 5% random trigger probability is met, a state flip operation is performed on the three randomly selected feature bits.

7. The ICMPv6-DDoS attack detection method based on feature optimization according to claim 1, characterized in that, In step S7, the first classification configuration is a lightweight classifier parameter configuration, which is used to improve the scoring efficiency in the feature optimization process; the second classification configuration is a full classifier parameter configuration, which is used to ensure the classification accuracy of the final detection model.

8. A feature-optimized ICMPv6-DDoS attack detection system, used to implement the feature-optimized ICMPv6-DDoS attack detection method according to any one of claims 1 to 7, characterized in that, It includes a data acquisition module, a traffic aggregation and basic feature extraction module, an extended feature generation module, a redundant feature removal module, a two-stage feature screening module, a feature evaluation rule configuration module, a feature combination optimization module, and a model training and traffic detection module, which are connected in sequence. The data acquisition module is used to collect raw ICMPv6 traffic in the IPv6 network environment; The traffic aggregation and basic feature extraction module is used to generate corresponding traffic records according to preset traffic aggregation identifiers and time windows, and extract basic feature data for each traffic record. The extended feature generation module is used to generate an extended feature set for identifying ICMPv6-DDoS attack behavior based on the basic feature data. The redundant feature removal module is used to remove highly correlated redundant features in the extended feature set and output a low-redundancy candidate feature set. The two-stage feature filtering module is used to complete the first-stage feature filtering by information gain ratio and generate a subset of candidate features. The feature evaluation rule configuration module is used to configure a segmented feature evaluation function with recall constraints and set a minimum recall threshold constraint. The feature combination optimization module is used to complete the second stage of feature combination optimization using an improved binary particle swarm optimization algorithm and output the optimal feature subset. The model training and traffic detection module is used to complete model training and performance verification based on the optimal feature subset, and to classify and detect normal traffic and attack traffic in the ICMPv6 traffic under test.

9. The ICMPv6-DDoS attack detection system based on feature optimization according to claim 8, characterized in that, The feature combination optimization module has a built-in inertial weight adjustment unit and a random mutation execution unit. The inertial weight adjustment unit is used to perform a dynamic inertial weight adjustment operation that decreases linearly with the number of iterations, and the random mutation execution unit is used to perform a random escape mutation operation.

10. A computer device comprising a processor and a memory, the memory storing a computer program, characterized in that, When the processor executes the computer program, it implements the feature-optimized ICMPv6-DDoS attack detection method according to any one of claims 1 to 7.