A Deep Learning-Based Physical Layer Spoofing Attack Detection Method

By extracting CSI phase difference data in the IoT environment using WGAN and Encoder models and converting it into a heatmap, the problem of CSI features being affected by time-varying factors and insufficient prior information from illegal devices in existing technologies is solved, thus achieving efficient and stable detection of spoofing attacks.

CN118741526BActive Publication Date: 2025-10-28NAT UNIV OF DEFENSE TECH
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202410935748.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-07-12
Publication Date
2025-10-28
Estimated Expiration
2044-07-12

AI Technical Summary

Technical Problem

In existing wireless communication technologies, spoofing attack detection methods based on CSI are difficult to adapt to the influence of time-varying factors and require a large amount of prior information about illegal devices, resulting in poor detection performance. In particular, it is difficult to achieve efficient near real-time authentication on devices with limited computing power.

Method used

By employing Wasserstein Generative Adversarial Network (WGAN) and an Encoder model, we extract the CSI phase difference data of legitimate devices in the IoT environment, convert it into a heatmap, use the WGAN model for spoofing attack detection, and use the Encoder model to find the optimal latent space variables to generate a dataset of legitimate devices, thus achieving efficient spoofing attack detection.

Benefits of technology

In situations where the received signal is time-varying and prior knowledge of the illegal device is lacking, effective detection of spoofing attacks is achieved, improving the accuracy and stability of detection while reducing the computational requirements of the device.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118741526B_ABST
    Figure CN118741526B_ABST
Patent Text Reader

Abstract

This invention proposes a deep learning-based physical layer spoofing attack detection method, belonging to the field of attack detection technology. This method extracts CSI phase difference data from the channel impulse response (CSI) features, converts it into a heatmap, and then uses a Wasserstein Generative Adversarial Network (WGAN) model and an encoder model for spoofing attack detection. This invention primarily addresses the limitations of existing technologies, such as the time-varying interference in CSI feature extraction and the need for extensive prior information from illegal devices, making them unsuitable for complex real-world environments.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of attack detection technology, and in particular to a method for detecting physical layer deception attacks based on deep learning. Background Technology

[0002] Due to the open broadcast nature of wireless signals, wireless communication is easily vulnerable to spoofing attacks. For example, in wireless network applications such as the Internet of Things (IoT), sensor networks, and industrial wireless edge networks, attackers can launch spoofing attacks by forging MAC / IP addresses to obtain legitimate device IDs and key information, thereby interfering with the normal operation of the entire wireless network system. Detection of spoofing attacks typically relies on device authentication technologies. Although cryptographic authentication technologies are widely used, they face increasing challenges with technological advancements and the proliferation of wireless devices. While more complex key mechanisms are generally more secure, they require wireless devices with significant computing power. This is especially true for wireless devices with limited computing power, power supplies, memory, and latency requirements, making efficient near-real-time authentication even more crucial. Channel State Information (CSI) contains information such as the amplitude and phase of the wireless channel between transmitting and receiving devices, providing fine-grained wireless channel characteristics that cannot be forged by attackers. Therefore, CSI-based physical layer spoofing attack detection provides a reliable means to enhance the security of wireless network communication systems.

[0003] The closest existing technologies to this invention are "a multi-user physical layer authentication method based on deep learning" and "a physical layer spoofing detection method based on deep reinforcement learning". The "multi-user physical layer authentication method based on deep learning" detects spoofing attacks by collecting CSI data from legitimate users and attackers and performing deep learning; the "physical layer spoofing detection method based on deep reinforcement learning" designs a deep reinforcement learning model to dynamically adjust the decision threshold for detecting spoofing attacks.

[0004] like Figure 1 As shown, "A multi-user physical layer authentication method based on deep learning" uses the receiver to collect CSI data from each terminal node to train a convolutional neural network, and finally inputs the user data to be tested into the convolutional neural network to determine whether it comes from an illegal user in order to detect spoofing attacks.

[0005] During the testing phase, both legitimate and illegitimate users first send message signals to the receiving end, which receives message signals from multiple time slots from each terminal user. Next, the message signals are denoised and preprocessed to extract CSI feature vectors, which consist of channel coherence time, channel frequency response, and signal autocorrelation function. These feature vectors are then combined with label vectors to construct a training set, which is then used for deep learning via a convolutional neural network.

[0006] During the testing phase, message signals from unknown users are first collected, and data processing is used to extract CSI (Content Signature Indicator) features. The CSI is then input into a trained convolutional neural network for model authentication. If the determination results in an illegitimate user, it indicates that the receiving end has been subjected to a spoofing attack. Conversely, if the result is negative, it indicates a legitimate user.

[0007] like Figure 2 As shown, "A Physical Layer Deception Detection Method Based on Deep Reinforcement Learning" is based on a deep reinforcement learning deterministic policy gradient framework, which enables dynamic and continuous selection of the detection threshold and has adaptability to dynamic unknown environments, effectively detecting physical layer deception attacks.

[0008] First, the Channel Frequency Response (CFR) of the CSI data between the sender and receiver is extracted to characterize the physical layer fingerprint features, and a hypothesis testing model is established. Then, state values ​​are constructed using the dynamic physical layer fingerprint features, and behavior values ​​are constructed using the detection threshold value. A state-behavior-benefit triple is established using the Bayesian risk function as the instantaneous benefit function. Finally, based on the Deep Deterministic Policy Gradient (DDPG) framework, a dynamic detection threshold selection algorithm is proposed, which can adaptively select the detection threshold in a dynamic and unknown environment to detect physical layer spoofing attacks.

[0009] The proposed "Deep Learning-Based Multi-User Physical Layer Authentication Method" fails to consider the susceptibility of CSI features to time-varying fluctuations. Furthermore, the assumption that prior data on illegitimate users is known is unreasonable. Even if prior data on illegitimate users could be obtained, the data could become invalid due to the movement of the illegitimate device. This could lead to severe misjudgments by the detection model.

[0010] The proposed physical layer spoofing detection method based on deep reinforcement learning requires dynamic threshold updates based on the value gains after decision-making. This method necessitates frequent signal transmissions between legitimate devices and the receiver to maintain effective threshold updates, significantly increasing the energy consumption of low-power communication devices. Furthermore, the threshold updates are based on the results of policy actions. If the CSI (Critical Identification Status) of illegitimate users changes frequently, the effectiveness and timeliness of the method will be affected. Summary of the Invention

[0011] From the perspective of practical social applications, this invention proposes a solution for detecting multi-device spoofing attacks in the Internet of Things (IoT) environment, namely a physical layer spoofing attack detection method (and system) based on deep learning.

[0012] The first aspect of this invention discloses a method for detecting physical layer deception attacks based on deep learning. The method includes:

[0013] Step S1: Collect channel state information of legitimate devices in the Internet of Things environment, extract phase difference data from the channel state information, and convert the phase difference data into a heat map to form a legitimate device dataset;

[0014] Step S2: Train a spoofing attack detection model based on the legitimate device dataset, and use the trained spoofing attack detection model to perform physical layer spoofing attack detection on the location device based on deep learning.

[0015] The deception attack detection model is the WGAN-Encoder model, which includes a Wasserstein generative adversarial network (WGAN) and an encoder.

[0016] In a preferred embodiment, in step S1, the acquisition of Channel State Information (CSI) is performed by a receiver, and the received signal is represented as follows:

[0017] Y = HX + N

[0018] Where Y represents the received signal, X represents the transmitted signal, N represents Gaussian white noise, and H is the channel frequency response. The frequency response of each channel is a complex value, expressed as:

[0019] H i =|H i |exp{j∠H i}

[0020] Among them, H i Represents the CSI of the i-th subcarrier, |H i | represents the amplitude of the i-th subcarrier, ∠H i Let represent the phase of the i-th subcarrier. The receiver is a multi-antenna device with r receiving antennas and 1 transmitting antenna. Then, the CSI phase acquired by the receiver is represented as:

[0021]

[0022] Among them, ∠H j , where i represents the CSI phase of the i-th subcarrier of the j-th antenna.

[0023] In a preferred embodiment, step S1 involves extracting phase difference data and converting it into a heatmap, specifically including:

[0024] The received CSI phase is unwound to prevent a jump at phase π, thus reflecting the true phase change. For each data packet, the phase information of the i-th subcarrier received by the j-th antenna is represented as:

[0025] Ph i,i =unwrap(∠H j,i )

[0026] Where unwrap(·) represents the phase unwrap operation, ∠H j,i The CSI phase of the i-th subcarrier of the j-th antenna is represented as follows: When the receiver has 3 receiving antennas, the corresponding CSI phase difference is expressed as:

[0027] PD 1,i =|∠H 1,i -∠H 2,i |, i = 1, 2, ..., N c

[0028] PD 2,i =|∠H 1,i - ∠ H 3,i |, i = 1, 2, ..., N c

[0029] PD 3,i =|∠H 2,i -∠H 3,i |, i = 1, 2, ..., N c

[0030] Where |·| represents taking the absolute value;

[0031] Data is visualized using a heatmap, where the horizontal axis represents the index of each subcarrier and the vertical axis represents PD1,i, PD2,i, and PD3,i.

[0032] In a preferred embodiment, in step S2:

[0033] The generator in the Wasserstein Generative Adversarial Network (WGAN) transforms a 1×100-dimensional latent space variable z into 3×64×64-dimensional CSI phase heatmap data, which involves an upsampling operation to transform low-dimensional data into high-dimensional data.

[0034] The batch normalization layer in the generator performs standardization processing, and then the data enters the LeakyReLU activation function layer, which is represented as:

[0035]

[0036] Where 'a' represents the angle controlling the negative slope when x is negative;

[0037] In WGAN, a batch normalization layer and a LeakyReLU activation function layer are connected after the convolutional layer. During training, Wasserstein distance is used to measure the distribution distance. The loss functions of the generator and discriminator are expressed as follows:

[0038] Loss G =-E z~p(z) D(G(z))

[0039]

[0040] Where λ represents the gradient penalty coefficient, and x represents the actual data. The discriminator sample distribution is represented as:

[0041]

[0042] Where represents a random number that follows a uniform distribution from 0 to 1;

[0043] Subsequently, a Dropout layer was added to WGAN to prevent overfitting during generator training, and a 1×1 dimensional vector was obtained through a fully connected layer.

[0044] In a preferred embodiment, in step S2:

[0045] The encoder is used to find the optimal latent space variable z, which helps the generator in the WGAN model generate the CSI phase difference heatmap that best matches the input image in the legitimate device dataset.

[0046] During the training of the encoder, the trained WGAN is used, and the parameters of the generator and discriminator in the WGAN remain unchanged, while only the parameter weights of the encoder are updated.

[0047] The loss function of the encoder consists of two parts: one part is the image reconstruction error between the reconstructed image and the original input image, and the other part is the feature residual between the reconstructed image and the original input image calculated by using the 1×2048 vector of the last fully connected layer of the generator in WGAN as the feature vector.

[0048] The loss function of the encoder is expressed as:

[0049]

[0050] Where f(˙) represents the feature vector extracted by the discriminator in WGAN, and n and n d κ represents the dimension of the data, and κ represents the weighting factor; the loss function is the anomaly score used for detecting deception attacks.

[0051] For the Encoder, s represents the stride size during convolution, p represents the padding size during convolution, and LeakyReLU activation function layer and Dropout layer are connected after convolution to prevent overfitting;

[0052] The input image is 3×64×64 in size. It goes through four convolutional layers. The last three convolutional layers use a batch normalization layer to standardize the features. Then, a fully connected layer transforms it into a vector of size 1×100 and outputs it through the Than activation function.

[0053] A second aspect of this invention discloses a physical layer deception attack detection system based on deep learning. The system includes a processing unit configured to perform:

[0054] Collect channel state information of legitimate devices in the Internet of Things environment, extract phase difference data from the channel state information, and convert the phase difference data into a heat map to form a legitimate device dataset;

[0055] The deception attack detection model is invoked and trained based on the legitimate device dataset. The trained deception attack detection model is then used to perform deep learning-based physical layer deception attack detection on the location device.

[0056] The deception attack detection model is the WGAN-Encoder model, which includes a Wasserstein generative adversarial network (WGAN) and an encoder.

[0057] In a preferred embodiment, the acquisition of Channel State Information (CSI) is performed by a receiver, and the received signal is represented as follows:

[0058] Y = HX + N

[0059] Where Y represents the received signal, X represents the transmitted signal, N represents Gaussian white noise, and H is the channel frequency response. The frequency response of each channel is a complex value, expressed as:

[0060] H i =|H i |exp{j∠H i}

[0061] Among them, H i Represents the CSI of the i-th subcarrier, |H i | represents the amplitude of the i-th subcarrier, ∠Hi Let represent the phase of the i-th subcarrier. The receiver is a multi-antenna device with r receiving antennas and 1 transmitting antenna. Then, the CSI phase acquired by the receiver is represented as:

[0062]

[0063] Among them, ∠H j , where i represents the CSI phase of the i-th subcarrier of the j-th antenna.

[0064] In a preferred embodiment, extracting the phase difference data and converting it into a heatmap specifically includes:

[0065] The received CSI phase is unwound to prevent a jump at phase π, thus reflecting the true phase change. For each data packet, the phase information of the i-th subcarrier received by the j-th antenna is represented as:

[0066] Ph i,i =unwrap(∠H j,i )

[0067] Where unwrap(·) represents the phase unwrap operation, ∠H j,i The CSI phase of the i-th subcarrier of the j-th antenna is represented as follows: When the receiver has 3 receiving antennas, the corresponding CSI phase difference is expressed as:

[0068] PD 1,i =|∠H 1,i -∠H 2,i |, i = 1, 2, ..., N c

[0069] PD 2,i =|∠H 1,i -∠H 3,i |, i = 1, 2, ..., N c

[0070] PD 3,i =|∠H 2,i -∠H 3,i |, i = 1, 2, ..., N c

[0071] Where |·| represents taking the absolute value;

[0072] Data is visualized using a heatmap, where the horizontal axis represents the index of each subcarrier and the vertical axis represents PD1,i, PD2,i, and PD3,i.

[0073] In a preferred embodiment, the generator in the Wasserstein Generative Adversarial Network (WGAN) transforms the 1×100-dimensional latent space variable z into 3×64×64-dimensional CSI phase heatmap data, which involves an upsampling operation to transform low-dimensional data into high-dimensional data.

[0074] The batch normalization layer in the generator performs standardization processing, and then the data enters the LeakyReLU activation function layer, which is represented as:

[0075]

[0076] Where 'a' represents the angle controlling the negative slope when x is negative;

[0077] In WGAN, a batch normalization layer and a LeakyReLU activation function layer are connected after the convolutional layer. During training, Wasserstein distance is used to measure the distribution distance. The loss functions of the generator and discriminator are expressed as follows:

[0078] Loss G =-E z~p(z) D(G(z))

[0079]

[0080] Where λ represents the gradient penalty coefficient, and x represents the actual data. The discriminator sample distribution is represented as:

[0081]

[0082] Where represents a random number that follows a uniform distribution from 0 to 1;

[0083] Subsequently, a Dropout layer was added to WGAN to prevent overfitting during generator training, and a 1×1 dimensional vector was obtained through a fully connected layer.

[0084] In a preferred embodiment, the encoder is used to find the optimal latent space variable z, which helps the generator in the WGAN model generate the CSI phase difference heatmap that best matches the input image in the legitimate device dataset.

[0085] During the training of the encoder, the trained WGAN is used, and the parameters of the generator and discriminator in the WGAN remain unchanged, while only the parameter weights of the encoder are updated.

[0086] The loss function of the encoder consists of two parts: one part is the image reconstruction error between the reconstructed image and the original input image, and the other part is the feature residual between the reconstructed image and the original input image calculated by using the 1×2048 vector of the last fully connected layer of the generator in WGAN as the feature vector.

[0087] The loss function of the encoder is expressed as:

[0088]

[0089] Where f(˙) represents the feature vector extracted by the discriminator in WGAN, and n and n d κ represents the dimension of the data, and κ represents the weighting factor; the loss function is the anomaly score used for detecting deception attacks.

[0090] For the Encoder, s represents the stride size during convolution, p represents the padding size during convolution, and LeakyReLU activation function layer and Dropout layer are connected after convolution to prevent overfitting;

[0091] The input image is 3×64×64 in size. It goes through four convolutional layers. The last three convolutional layers use a batch normalization layer to standardize the features. Then, a fully connected layer transforms it into a vector of size 1×100 and outputs it through the Than activation function.

[0092] In summary, this invention extracts CSI phase difference data from the channel impulse response in CSI features, converts it into a heatmap, and then uses a Wasserstein Generative Adversarial Network (WGAN) model and an encoder model for spoofing attack detection. This invention primarily addresses the limitations of existing technologies in CSI feature extraction, such as interference from time-varying factors and the need for extensive prior information from illegal devices, making them unsuitable for complex real-world environments. Attached Figure Description

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

[0094] Figure 1 This is a flowchart of an existing technical solution.

[0095] Figure 2This is a flowchart illustrating another existing technical solution.

[0096] Figure 3 This is a flowchart illustrating the detection of physical layer deception attacks based on deep learning according to an embodiment of the present invention.

[0097] Figure 4 This is a schematic diagram of the unwinding process according to an embodiment of the present invention.

[0098] Figure 5 This is a logical schematic diagram of the WGAN model according to an embodiment of the present invention.

[0099] Figures 6a-6d ROC curves are used to detect deception attacks with different CSI features according to embodiments of the present invention. Detailed Implementation

[0100] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. 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.

[0101] Spoofing attack detection plays a crucial role in the physical layer security of wireless networks, especially in the Internet of Things (IoT) with its massive number of devices. This technology can detect unauthorized users impersonating legitimate users to launch spoofing attacks, sending incorrect data to the IoT and disrupting the normal operation of the entire network. This patent achieves effective detection of spoofing attacks even under conditions of time-varying received signals and a lack of prior knowledge about the unauthorized devices. The technical solution is as follows: Figure 3 As shown.

[0102] 1. CSI Data Acquisition

[0103] CSI reflects channel information during propagation, such as multipath effects, signal fading, and distortion, providing more granular information than RSS. This information can be used as a fingerprint for training models and feature extraction. CSI extraction is performed by the receiver, and the received signal is represented as...

[0104] Y = HX + N (1)

[0105] Where Y represents the received signal, X represents the transmitted signal, N represents Gaussian white noise, and H is the channel frequency response, i.e., the channel gain matrix. The frequency response of each channel is expressed in complex numerical form as follows:

[0106] H i =|H i |exp{j∠H i} (2)

[0107] Among them, H i Represents the CSI of the i-th subcarrier, |H i | represents the amplitude of the i-th subcarrier, ∠H i Let represent the phase of the i-th subcarrier. Assuming the receiver is a multi-antenna device with r receiving antennas and 1 transmitting antenna, the CSI phase extracted by the receiver is represented as:

[0108]

[0109] Among them, ∠H j , where i represents the CSI phase of the i-th subcarrier of the j-th antenna.

[0110] 2. Phase difference extraction and heatmap conversion

[0111] The CSI phase exhibits strong randomness, which varies over time and therefore cannot be directly used for packet verification. To eliminate this randomness, this patent considers the phase difference between two adjacent antennas. First, the received CSI phase is unwound to prevent a jump at phase π, thus reflecting the true phase change. The unwound process is as follows: Figure 4 As shown.

[0112] For each data packet, the phase information of the i-th subcarrier received by the j-th antenna is represented as follows:

[0113] Ph j,i =unwrap(∠H j,i (4)

[0114] Where unwrap(·) represents the phase unwrap operation, ∠H i,i This represents the CSI phase extracted by formula (3). Assuming the receiver has three receiving antennas, the corresponding CSI phase difference is expressed as...

[0115] PD 1,i =|∠H 1,i - ∠ H 2,i |, i = 1, 2, ..., N c

[0116] PD 2,i =| ∠ H 1,i - ∠ H 3,i |, i = 1, 2, ..., N c

[0117] PD3, i = |∠H 2,i -∠H 3,i|, i = 1, 2, ..., N c (5)

[0118] Where |·| represents taking the absolute value. The data is visualized in the form of a heatmap, where the horizontal axis represents the index of each subcarrier, and the vertical axis represents PD1,i, PD2,i, and PD3,i in formula (5).

[0119] 3. Establishment of WGAN-Encoder Model

[0120] (1) WGAN model

[0121] The established WGAN model is as follows Figure 5 As shown.

[0122] The generator in the WGAN model transforms the 1×100-dimensional latent space variable z into 3×64×64-dimensional CSI phase heatmap data, which involves upsampling. In contrast to downsampling, upsampling transforms low-dimensional data into high-dimensional data. To address the numerical instability problem in deep neural networks and ensure similar feature distributions within the same batch, making the network easier to train, this patent uses a BatchNormalization (BN) layer for standardization in the generator. This prevents the network model's performance from becoming unstable due to excessively large datasets before LeakyReLU is applied. The LeakyReLU output has a slight slope for negative inputs. Since the derivative is always non-zero, this reduces the occurrence of silent neurons, allowing gradient-based learning and solving the problem of neurons not learning after the ReLU function enters the negative interval. The activation function LeakyReLU is expressed as:

[0123]

[0124] Where 'a' represents the angle controlling the negative slope when x is negative. In the WGAN model, a Batch Normalization (BN) layer and a LeakyReLU activation function are applied after the convolutional layers. During training, the WGAN model uses Wasserstein distance to measure distribution distance; therefore, the loss functions for the generator and discriminator are expressed as follows:

[0125] Loss G =-E z~p(z) D(G(z)) (7)

[0126]

[0127] Where λ represents the gradient penalty coefficient, and x represents the actual data. The discriminator sample distribution is represented as:

[0128]

[0129] This represents a random number that follows a uniform distribution from 0 to 1. A Dropout layer is then added to the model to prevent overfitting during generator training, and finally, a 1×1 dimensional vector is obtained through a fully connected layer.

[0130] (2) Encoder Model

[0131] The Encoder model can quickly find the optimal latent space variable z, enabling the generator in the WGAN model to rapidly generate the CSI phase difference heatmap that best matches the input image in the legitimate device dataset. During the training of the Encoder model, although a pre-trained WGAN model is used, the model parameters in the generator and discriminator of the WGAN model remain unchanged during the training of the Encoder model. Therefore, only the Encoder model updates its parameter weights. The loss function in the Encoder model consists of two parts: one is the image reconstruction error between the reconstructed image and the original input image, and the other is the feature residual calculated using the 1×2048 vector from the last fully connected layer of the generator in the WGAN model as a feature vector. Finally, the loss function of the Encoder network model is expressed as follows:

[0132]

[0133] Where f(˙) represents the feature vector extracted by the discriminator in the WGAN model. n and n d κ represents the dimension of the data. This loss function is also the anomaly score subsequently used for spoofing attack detection. Specific details of the Encoder model are shown in Table 1. Here, s represents the stride size during convolution, and p represents the padding size. A LeakyReLU activation function and a Dropout layer follow the convolution to prevent overfitting. The input image size is 3×64×64. After passing through four convolutional layers, a BN layer is used between the last three convolutional layers to standardize the features. Then, a fully connected layer transforms the image into a 1×100 vector, and finally, the image is output through the Than activation function.

[0134] Table 2: Encoder Model Parameters

[0135]

[0136]

[0137] (I) Evaluation Indicators

[0138] 1.Receiveroperatingcharacteristic(ROC) curve

[0139] The ROC curve is a graphical tool used to represent the performance of a classification model. It depicts the classifier's performance at different thresholds by using the True Positive Rate (TPR) and False Positive Rate (FPR) as the horizontal and vertical axes. Anomaly scores are obtained by comparing FPR and TPR for each different threshold. The Area Under the Curve (AUC) is the area under the ROC curve and measures classifier performance. A closer AUC value to 1 indicates better detection performance; conversely, a closer AUC value to 0 indicates worse detection performance. The Equal Error Rate (EER) is the point on the ROC curve where FPR equals (1-TPR); a smaller EER value is better. A lower EER value indicates higher system detection accuracy.

[0140] 2. Precision-Recall (PR)

[0141] The construction of Precision (PR) is basically the same as that of ROC, except that Precision and Recall need to be calculated separately. For the same model, the larger the Recall, the smaller the Precision. PR-AUC refers to the area under the PR curve; the larger this value, the better the system's detection performance.

[0142] (II) Technical Effects

[0143] 1. Experimental Scenario Construction

[0144] To fully consider the complexity of real-world environments, this patent selects a real indoor IoT application scenario of 11.5m × 13m for data collection. The IoT transmission signal is an OFDM-modulated Wi-Fi signal generated based on the IEEE 802.11n protocol, with 30 subcarriers and a bandwidth of 20MHz. Indoor environments are complex, especially during data collection, as people move around and talk to each other, which can be considered interference. Signal propagation may be impaired due to obstacles. The data collection environment, with interference from people moving around, more closely resembles the actual communication environment of IoT. Five legitimate devices were randomly selected at each location, and five illegitimate devices were deployed at each location for CSI data collection.

[0145] 2. Effect Analysis

[0146] The experiment collected data from 60 time points from legitimate devices for model training. Subsequently, CSI data from legitimate and illegitimate devices were collected at different time points for detection.

[0147] (1) Comparison of different CSI features

[0148] To demonstrate that using CSI phase difference yields better detection results, this paper compares it with CSI amplitude, CSI amplitude difference, and CSI phase. Figures 6a-6d As shown, the system will detect CSIs received at times 550, 750, 950, and 1150, respectively, for a total of 30 consecutive moments, including CSIs from both legitimate and illegitimate devices. Figure 5 It can be seen that both CSI phase and CSI phase difference have excellent performance. However, although the AUC value of CSI phase is above 0.95 at times 750, 950 and 1150, the AUC value is only 0.8 at time 550. CSI phase difference has a more stable effect, with the AUC value remaining above 0.99 and the EER value only increasing from 0.027 to 0.073.

[0149] (2) Comparison of different models

[0150] To better demonstrate the performance of the model proposed in this patent, Patent 1 and Patent 2 were selected for comparison. The comparison metrics were AUC, EER, and PR. The system will detect CSI received at time 1150 for 30 consecutive time steps for each of the different schemes, including CSI from both legitimate and illegitimate devices. Table 2 shows that the AUC, PR, and EER values ​​of the model proposed in this patent are superior to the other two models.

[0151] Table 2: Comparison of Models

[0152] Technical solution AUC EER PR Prior Art 1 0.734 0.333 0.790 Existing technology 2 0.439 0.547 0.468 The solution proposed in this patent 0.990 0.073 0.991

[0153] In summary, this invention extracts CSI phase difference data from the channel impulse response in CSI features, converts it into a heatmap, and then uses a Wasserstein Generative Adversarial Network (WGAN) model and an encoder model to detect spoofing attacks. This invention primarily addresses the technical challenges of existing technologies, such as the interference from time-varying factors and the need for extensive prior information from illegal devices, making them unsuitable for complex real-world environments.

[0154] Please note that the technical features of the above embodiments can be combined arbitrarily. For the sake of brevity, not all possible combinations of the technical features in the above embodiments have been described. However, as long as the combination of these technical features does not contradict each other, it should be considered within the scope of this specification. The above embodiments only illustrate several implementation methods of this application, and their descriptions are relatively specific and detailed, but they should not be construed as limiting the scope of the invention patent. It should be pointed out that for those skilled in the art, several modifications and improvements can be made without departing from the concept of this application, and these all fall within the protection scope of this application. Therefore, the protection scope of this patent application should be determined by the appended claims.

Claims

1. A method for detecting physical layer deception attacks based on deep learning, characterized in that, The method includes: Step S1: Collect channel state information of legitimate devices in the Internet of Things environment, extract phase difference data from the channel state information, and convert the phase difference data into a heat map to form a legitimate device dataset; In step S1, the acquisition of Channel State Information (CSI) is performed by the receiver, and the received signal is represented as follows: Y = HX + N Where Y represents the received signal, X represents the transmitted signal, N represents Gaussian white noise, and H is the channel frequency response. The frequency response of each channel is a complex value, expressed as: H i =|H i |exp{j∠H i } Among them, H i Represents the CSI of the i-th subcarrier, |H i | represents the amplitude of the i-th subcarrier, ∠H i Let represent the phase of the i-th subcarrier. The receiver is a multi-antenna device with r receiving antennas and 1 transmitting antenna. Then, the CSI phase acquired by the receiver is represented as: Among them, ∠H j,i This represents the CSI phase of the i-th subcarrier of the j-th antenna; Step S2: Train a spoofing attack detection model based on the legitimate device dataset, and use the trained spoofing attack detection model to perform physical layer spoofing attack detection on the location device based on deep learning. The deception attack detection model is a WGAN-Encoder model, which includes a Wasserstein generative adversarial network (WGAN) and an encoder. In step S2: The generator in the Wasserstein Generative Adversarial Network (WGAN) transforms the 1×100-dimensional latent space variable z into 3×64×64-dimensional CSI phase heatmap data, which involves upsampling operations to transform low-dimensional data into high-dimensional data. The batch normalization layer in the generator is standardized, and then the data enters the LeakyReLU activation function layer; In WGAN, a batch normalization layer and a LeakyReLU activation function layer are connected after the convolutional layer, and Wasserstein distance is used to measure the distribution distance during training. Subsequently, a Dropout layer was added to WGAN to prevent overfitting during generator training, and a 1×1 dimensional vector was obtained through a fully connected layer. In step S2: The encoder is used to find the optimal latent space variable z, which helps the generator in the WGAN model generate the CSI phase difference heatmap that best matches the input image in the legitimate device dataset. During the training of the encoder, the trained WGAN is used, and the parameters of the generator and discriminator in the WGAN remain unchanged, while only the parameter weights of the encoder are updated. The loss function of the encoder consists of two parts: one part is the image reconstruction error between the reconstructed image and the original input image, and the other part is the feature residual between the reconstructed image and the original input image calculated by using the 1×2048 vector of the last fully connected layer of the generator in WGAN as the feature vector. For the Encoder, s represents the stride size during convolution, p represents the padding size during convolution, and LeakyReLU activation function layer and Dropout layer are connected after convolution to prevent overfitting; The input image is 3×64×64 in size. It goes through four convolutional layers. The last three convolutional layers use a batch normalization layer to standardize the features. Then, a fully connected layer transforms it into a vector of size 1×100 and outputs it through the Than activation function.

2. The method for detecting physical layer deception attacks based on deep learning according to claim 1, characterized in that, In step S1, the phase difference data is extracted and converted into a heat map, specifically including: The received CSI phase is unwound to prevent a jump at phase π, thus reflecting the true phase change. For each data packet, the phase information of the i-th subcarrier received by the j-th antenna is represented as: Ph j,i =unwrap(∠H j,i ) Where unwrap(˙) represents the phase unwrap operation, ∠H j,i The CSI phase of the i-th subcarrier of the j-th antenna is represented as follows: When the receiver has 3 receiving antennas, the corresponding CSI phase difference is expressed as: PD 1,i =|∠H 1,i -∠H 2,i |,i=1,2,…,N c PD 2,i =|∠H 1,i -∠H 3,i |,i=1,2,…,N c PD 3,i =|∠H 2,i -∠H 3,i |,i=1,2,…,N c Where |˙| represents taking the absolute value; Data visualization is performed using a heatmap, where the horizontal axis represents the index of each subcarrier and the vertical axis represents the PD (Power Distribution Detector). 1,i PD 2,i PD 3,i .

3. The physical layer deception attack detection method based on deep learning according to claim 2, characterized in that, In step S2: LeakyReLU is represented as: Where 'a' represents the angle controlling the negative slope when x is negative; In WGAN, the loss functions for the generator and discriminator are expressed as follows: Loss G =-E z~p(z) D(G(z)) Where λ represents the gradient penalty coefficient, and x represents the actual data. The discriminator sample distribution is represented as: Where ∈ represents a random number that follows a uniform distribution from 0 to 1.

4. The physical layer deception attack detection method based on deep learning according to claim 3, characterized in that, In step S2: The loss function of the encoder is expressed as: Where f(·) represents the feature vector extracted by the discriminator in WGAN, and n and n d κ represents the dimension of the data, and κ represents the weighting factor; the loss function is the anomaly score used for detecting deception attacks.

5. A physical layer deception attack detection system based on deep learning, characterized in that, The system includes a processing unit configured to perform: Collect channel state information of legitimate devices in the Internet of Things environment, extract phase difference data from the channel state information, and convert the phase difference data into a heat map to form a legitimate device dataset; The acquisition of Channel State Information (CSI) is performed by the receiver, and the received signal is represented as follows: Y = HX + N Where Y represents the received signal, X represents the transmitted signal, N represents Gaussian white noise, and H is the channel frequency response. The frequency response of each channel is a complex value, expressed as: H i =|H i |exp{j∠H i } Among them, H i Represents the CSI of the i-th subcarrier, |H i | represents the amplitude of the i-th subcarrier, ∠H i Let represent the phase of the i-th subcarrier. The receiver is a multi-antenna device with r receiving antennas and 1 transmitting antenna. Then, the CSI phase acquired by the receiver is represented as: Among them, ∠H j,i This represents the CSI phase of the i-th subcarrier of the j-th antenna; The deception attack detection model is invoked and trained based on the legitimate device dataset. The trained deception attack detection model is then used to perform deep learning-based physical layer deception attack detection on the location device. The deception attack detection model is a WGAN-Encoder model, which includes a Wasserstein generative adversarial network (WGAN) and an encoder. In the Wasserstein Generative Adversarial Network (WGAN), the generator transforms the 1×100-dimensional latent space variable z into 3×64×64-dimensional CSI phase heatmap data, which involves upsampling operations to transform low-dimensional data into high-dimensional data. The batch normalization layer in the generator is standardized, and then the data enters the LeakyReLU activation function layer; In WGAN, a batch normalization layer and a LeakyReLU activation function layer are connected after the convolutional layer, and Wasserstein distance is used to measure the distribution distance during training. Subsequently, a Dropout layer was added to WGAN to prevent overfitting during generator training, and a 1×1 dimensional vector was obtained through a fully connected layer. Among them, the encoder is used to find the optimal latent space variable z, which helps the generator in the WGAN model generate the CSI phase difference heatmap that best matches the input image in the legitimate device dataset; During the training of the encoder, the trained WGAN is used, and the parameters of the generator and discriminator in the WGAN remain unchanged, while only the parameter weights of the encoder are updated. The loss function of the encoder consists of two parts: one part is the image reconstruction error between the reconstructed image and the original input image, and the other part is the feature residual between the reconstructed image and the original input image calculated by using the 1×2048 vector of the last fully connected layer of the generator in WGAN as the feature vector. For the Encoder, s represents the stride size during convolution, p represents the padding size during convolution, and LeakyReLU activation function layer and Dropout layer are connected after convolution to prevent overfitting; The input image is 3×64×64 in size. It goes through four convolutional layers. The last three convolutional layers use a batch normalization layer to standardize the features. Then, a fully connected layer transforms it into a vector of size 1×100 and outputs it through the Than activation function.

6. The method for detecting physical layer deception attacks based on deep learning according to claim 5, characterized in that, Extracting phase difference data and converting it into a heatmap includes: The received CSI phase is unwound to prevent a jump at phase π, thus reflecting the true phase change. For each data packet, the phase information of the i-th subcarrier received by the j-th antenna is represented as: Ph j,i =unwrap(∠H j,i ) Where unwrap(˙) represents the phase unwrap operation, ∠H j,i The CSI phase of the i-th subcarrier of the j-th antenna is represented as follows: When the receiver has 3 receiving antennas, the corresponding CSI phase difference is expressed as: PD 1,i =|∠H 1,i -∠H 2,i |,i=1,2,…,N c PD 2,i =|∠H 1,i -∠H 3,i |,i=1,2,…,N c PD 3,i =|∠H 2,i -∠H 3,i |,i=1,2,…,N c Where |˙| represents taking the absolute value; Data visualization is performed using a heatmap, where the horizontal axis represents the index of each subcarrier and the vertical axis represents the PD (Power Distribution Detector). 1,i PD 2,i PD 3,i .

7. The method for detecting physical layer deception attacks based on deep learning according to claim 6, characterized in that: LeakyReLU is represented as: Where 'a' represents the angle controlling the negative slope when x is negative; In WGAN, the loss functions for the generator and discriminator are expressed as follows: Loss G =-E z~p(z) D(G(z)) Where λ represents the gradient penalty coefficient, and x represents the actual data. The discriminator sample distribution is represented as: Where ∈ represents a random number that follows a uniform distribution from 0 to 1.

8. The physical layer deception attack detection system based on deep learning according to claim 7, characterized in that: The loss function of the encoder is expressed as: Where f(˙) represents the feature vector extracted by the discriminator in WGAN, and n and n d κ represents the dimension of the data, and κ represents the weighting factor; the loss function is the anomaly score used for detecting deception attacks.

Citation Information

Patent Citations

  • Physical layer deception detection method based on deep reinforcement learning

    CN114845304A