Method, device, equipment and medium for cross-equipment instruction reverse analysis

By preprocessing and feature extraction of the real-time power consumption data of the target chip, the deep learning model is used to implement reverse analysis of cross-device instructions, which solves the problem of reduced attack accuracy caused by feature differences between devices and improves analysis efficiency and accuracy.

CN118585752APending Publication Date: 2024-09-03WUHAN UNIV
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202410783885.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-06-18
Publication Date
2024-09-03

AI Technical Summary

Technical Problem

The existing technology fails to effectively consider the feature differences between devices in power consumption command attacks, making it difficult for the features learned by the neural network to be effectively returned between devices, resulting in a reduction in attack accuracy.

Method used

By obtaining real-time power consumption data of the target chip, using data preprocessing and feature preprocessing rules to generate samples to enhance the learnability of the data set, and inputting them into the pre-trained deep learning model to obtain instruction category information, realize cross-device instruction reversal analyze.

Benefits of technology

It improves the efficiency and accuracy of reverse analysis of chip instructions, reduces the number of feature dimensions, improves computing efficiency, and maintains stability in cross-device generalization.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118585752A
    Figure CN118585752A
Patent Text Reader

Abstract

The invention provides a method and device for reverse analysis of a cross-device instruction, equipment and a medium. The method comprises the following steps: acquiring real-time power consumption data of a target chip in an instruction running stage; wherein the target chip is a chip which needs to be subjected to instruction reverse analysis; preprocessing the real-time power consumption data by using a data preprocessing rule to obtain first data; processing the first data by using a feature preprocessing rule to obtain second data; and inputting the second data into a pre-training deep learning model, and outputting instruction category information corresponding to the real-time power consumption data by the pre-training deep learning model. By utilizing the method provided by the embodiment of the invention, the efficiency and the accuracy of reverse analysis of the chip instruction can be improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present disclosure relates to the technical field of chip security analysis, and in particular to a method, apparatus, electronic device, non-transitory computer-readable storage medium, and computer program product for cross-device instruction reverse analysis. Background Art

[0002] In the field of chip security analysis, power instruction attacks based on side-channel power leakage analysis have been widely used in various chip attack scenarios as a significant technical means. Specifically, side-channel power consumption information can be used to analyze the operating status of the chip computing system. Among them, an important method is to disassemble the code instructions when the chip is running, that is, to convert the side-channel power consumption information into assembly code consisting of instructions and operands (such as source registers or destination registers) in time sequence.

[0003] In related technologies, the power consumption instruction attack scheme mainly relies on the learning ability of the neural network itself, selecting the corresponding feature units on the original power consumption curve without considering the feature differences on more devices; and since different devices may have external resistance values, hardware differences will cause different numerical ranges of power consumption traces, which will make it difficult for the features learned by the neural network to be effectively returned between devices, resulting in reduced accuracy and ultimately leading to the failure of the attack on the target device. Summary of the invention

[0004] The present disclosure provides a method, apparatus, electronic device, non-transitory computer-readable storage medium, and computer program product for cross-device instruction reverse analysis to address deficiencies in the prior art.

[0005] The present disclosure provides a method for reverse analysis of cross-device instructions, comprising:

[0006] Acquire real-time power consumption data of a target chip during the instruction execution phase; wherein the target chip is a chip that needs to be subjected to instruction reverse analysis;

[0007] Preprocessing the real-time power consumption data using a data preprocessing rule to obtain first data;

[0008] Using a feature preprocessing rule, processing the first data to obtain second data;

[0009] The second data is input into a pre-trained deep learning model, and the pre-trained deep learning model outputs instruction category information corresponding to the real-time power consumption data.

[0010] The present disclosure also provides a device for reverse analysis of cross-device instructions, comprising:

[0011] The data acquisition module is configured to: acquire real-time power consumption data of a target chip during the instruction execution phase; wherein the target chip is a chip that needs to be subjected to instruction reverse analysis;

[0012] A data preprocessing module is configured to: preprocess the real-time power consumption data using a data preprocessing rule to obtain first data;

[0013] A feature preprocessing module is configured to: process the first data using a feature preprocessing rule to obtain second data;

[0014] The analysis module is configured to: input the second data into a pre-trained deep learning model, and the pre-trained deep learning model outputs instruction category information corresponding to the real-time power consumption data.

[0015] The present disclosure also provides an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the program, the method for reverse analysis of cross-device instructions as described in any one of the above is implemented.

[0016] The present disclosure also provides a non-transitory computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements any of the methods for cross-device instruction reverse analysis described above.

[0017] The present disclosure also provides a computer program product, including a computer program, wherein when the computer program is executed by a processor, the computer program implements any of the above methods for cross-device instruction reverse analysis.

[0018] As described above, the method for reverse analysis of cross-device instructions provided by the embodiments of the present disclosure, on the one hand, can use GAN to generate samples, data enhancement, and feature extraction operations before and after the power consumption trace is converted, so as to improve the learnability of the data set between devices; ultimately, the pre-trained deep learning model can obtain excellent recognition accuracy; on the other hand, the feature extraction can realize the calculation of inter-class differences and inter-device differences, and the obtained feature points are not only stable in cross-device generalization, but also can greatly reduce the number of feature dimensions, thereby improving computing efficiency.

[0019] In summary, the method for cross-device instruction reverse analysis provided by the embodiments of the present disclosure can improve the efficiency and accuracy of chip instruction reverse analysis, and provide a new solution for cross-device chip instruction reverse analysis. BRIEF DESCRIPTION OF THE DRAWINGS

[0020] In order to more clearly illustrate the technical solutions in the present disclosure or 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 some embodiments of the present disclosure. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.

[0021] Figure 1 This is one of the flowcharts of the method for reverse analysis of cross-device instructions provided by the embodiment of the present disclosure;

[0022] Figure 2 It is a waveform diagram of “source power consumption trace, target power consumption trace, and GAN generated power consumption trace” provided by an embodiment of the present disclosure;

[0023] Figure 3 This is the second flow chart of the method for reverse analysis of cross-device instructions provided by the embodiment of the present disclosure;

[0024] Figure 4 This is a third flow chart of a method for reverse analysis of cross-device instructions provided in an embodiment of the present disclosure;

[0025] Figure 5 It is a schematic diagram of “a two-dimensional time-frequency domain feature map extracted based on information entropy and other measurement methods” provided by an embodiment of the present disclosure;

[0026] Figure 6 It is a structural schematic diagram of an apparatus for reverse analysis of cross-device instructions provided by an embodiment of the present disclosure;

[0027] Figure 7 It is a schematic diagram of the structure of an electronic device provided by the present disclosure. DETAILED DESCRIPTION

[0028] In order to make the purpose, technical solutions and advantages of the present disclosure clearer, the technical solutions in the present disclosure will be clearly and completely described below in conjunction with the drawings in the present disclosure. Obviously, the described embodiments are part of the embodiments of the present disclosure, rather than all the embodiments. Based on the embodiments in the present disclosure, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present disclosure.

[0029] To solve the above-mentioned problems of the prior art, the inventors of the present disclosure have proposed, after research, a solution for reverse analysis of cross-device instructions as described in the following embodiment.

[0030] Example:

[0031] The following describes the implementation details of the solution for reverse analysis of cross-device instructions disclosed in the present invention in conjunction with the accompanying drawings.

[0032] Figure 1 1 is a flow chart of a method for reverse analysis of cross-device instructions provided by an exemplary embodiment of the present disclosure. This embodiment can be applied to electronic devices (for example, servers or cloud computing platforms), such as Figure 1 As shown, the method for reverse analysis of cross-device instructions includes the following steps:

[0033] S110, obtaining real-time power consumption data of the target chip during the instruction execution phase.

[0034] The target chip is a chip that needs to undergo instruction reverse analysis.

[0035] As an optional example, the real-time power consumption data may be a source power consumption trace; for example, Figure 2 The source power consumption trace shown in .

[0036] The real-time power consumption data is a side channel leakage information when a target chip (e.g., a chip in an encryption device) runs instructions; for example, it can be a physical character, which may include but is not limited to radio frequency, power consumption, and computing time. The side channel leakage information will leak sensitive intermediate value information of the target chip's working process.

[0037] The present disclosure does not limit the acquisition method. For example, an electronic device (eg, a server or a cloud computing platform) as an execution subject can directly collect the real-time power consumption data from the target chip.

[0038] S120 : Preprocess the real-time power consumption data using a data preprocessing rule to obtain first data.

[0039] Among them, preprocessing may include operations such as standardization, data cleaning, time-frequency domain conversion, etc., which will be described in detail in the following implementation method and will not be repeated here.

[0040] S130: Process the first data using feature preprocessing rules to obtain second data.

[0041] Among them, processing the first data may include operations such as GAN sample generation, data enhancement, and feature extraction, the purpose of which is to improve the learnability of power consumption data between devices, and ultimately enable the deep learning model in subsequent steps to obtain excellent instruction recognition and classification accuracy.

[0042] S140. Input the second data into a pre-trained deep learning model, and the pre-trained deep learning model outputs instruction category information corresponding to the real-time power consumption data.

[0043] The pre-trained deep learning model may include, but is not limited to, a convolutional neural network and a recurrent neural network structure. The specific structure and training steps will be described below and will not be repeated here.

[0044] As described above, the method for reverse analysis of cross-device instructions provided by the embodiments of the present disclosure, on the one hand, can use GAN to generate samples, data enhancement, and feature extraction operations before and after the power consumption trace is converted, so as to improve the learnability of the data set between devices; ultimately, the pre-trained deep learning model can obtain excellent recognition accuracy; on the other hand, the feature extraction can realize the calculation of inter-class differences and inter-device differences, and the obtained feature points are not only stable in cross-device generalization, but also can greatly reduce the number of feature dimensions, thereby improving computing efficiency.

[0045] In summary, the method for cross-device instruction reverse analysis provided by the embodiments of the present disclosure can improve the efficiency and accuracy of chip instruction reverse analysis, and provide a new solution for cross-device chip instruction reverse analysis.

[0046] exist Figure 1 Based on the embodiment, as an optional implementation method, refer to Figure 3 Step S120 "preprocessing the real-time power consumption data using a data preprocessing rule to obtain first data" can be implemented as follows:

[0047] S1210: Standardize the real-time power consumption data using preset standardization rules to obtain standardized power consumption data.

[0048] As an optional example, step S1210 may include aligning the real-time power consumption data. The alignment may include but is not limited to structure alignment, class member alignment, etc.

[0049] S1220. Clean the standardized power consumption data using preset data cleaning rules to obtain cleaned power consumption data.

[0050] As an optional example, step S1220 may include deleting abnormal data from the standardized power consumption data.

[0051] The abnormal data may include, but are not limited to, discontinuity, redundant peak points, etc. The reason for generating the abnormal data is usually that the chip or related equipment is touched during the process of collecting real-time power consumption data.

[0052] S1230. Convert the post-cleaning power consumption data using a preset time-frequency domain conversion rule to obtain converted power consumption data as the first data.

[0053] As an optional example, step S1230 may include performing “continuous wavelet transform (CWT) or fast Fourier transform (FFT)” on the post-cleaning power consumption data to obtain the post-conversion power consumption data.

[0054] exist Figure 1 Based on the embodiment, as an optional implementation method, refer to Figure 4 Step S130 "processing the first data using the feature preprocessing rule to obtain the second data" can be implemented as follows:

[0055] S1310, inputting the first data into a pre-trained generative adversarial network, and the pre-trained generative adversarial network outputs migration power consumption data corresponding to the first data (for example, referring to Figure 2 The migration power consumption trace generated by GAN shown in Figure 3).

[0056] In step 1310, a pre-trained Generative Adversarial Network (GAN) is used to generate migration power consumption data (m-dimensional data, i.e., the same dimension as the target power consumption data) using the first data (e.g., n-dimensional data) as input. Optionally, noise may also be added to the first data and then used as input.

[0057] As an optional example, the pre-trained generative adversarial network includes a generator and a discriminator. The generator includes a plurality of cascaded generation units, each of which includes a cascaded fully connected layer, a batch normalization layer BN, and an activation function layer; the discriminator network includes a plurality of cascaded identification units, each of which includes a cascaded fully connected layer, a batch normalization layer BN, and a nonlinear activation function layer.

[0058] Based on this example, the training steps of the pre-trained generative adversarial network include:

[0059] Step 1: Obtain the adversarial training dataset.

[0060] The adversarial training data set includes multiple groups of adversarial training data, each group of the adversarial training data includes first sample data and first sample true value; the first sample data is converted power consumption sample data obtained after performing data preprocessing on the power consumption sample data; the first sample true value is the target power consumption data corresponding to the first sample data (for example, refer to Figure 2 Target power consumption trace shown).

[0061] Step 2: input the first sample data in each group of adversarial training data into the to-be-trained generative adversarial network, and the to-be-trained generative adversarial network outputs migration power consumption prediction data corresponding to the first sample data.

[0062] Step 3: Using the adversarial loss function, based on the migration power consumption prediction data and the first sample true value in each corresponding set of adversarial training data, obtain the function value of the adversarial loss function.

[0063] Among them, the adversarial loss function can be characterized as calculating the difference between "the migration power consumption prediction data and the first sample true value in each corresponding set of adversarial training data" as the cross entropy.

[0064] Step 4: The function value of the adversarial loss function is fed back to the generative adversarial network to be trained, and the neural network to be trained adjusts the network parameters of each network layer according to the function value of the adversarial loss function.

[0065] Step 5, iteratively execute steps 3 to 4 until a preset training completion condition is met, and the pre-trained generative adversarial network is obtained from the generative adversarial network to be trained.

[0066] Among them, the preset training completion conditions are: the accuracy of the migration power consumption prediction data compared to the first sample data is greater than the preset accuracy threshold (that is, the accuracy is achieved as the optimization goal); or, the number of iterations is greater than the preset iterative training number threshold.

[0067] S1320: Process the migration power consumption data in a two-dimensional time-frequency domain by using a data enhancement rule to obtain enhanced power consumption data.

[0068] As an optional example, in step S1320, the "migration power consumption data" may be transformed in a two-dimensional time-frequency domain or a Gaussian noise disturbance may be added to obtain the enhanced power consumption data.

[0069] S1330: Measure the inter-sample effectiveness of the enhanced power consumption data by using feature extraction rules, and select effective power consumption data as the second data.

[0070] As an optional example, in step S1330, the inter-sample validity of the enhanced power consumption data may be measured by information entropy or cosine similarity, thereby selecting effective power consumption data as the second data.

[0071] Optionally, refer to Figure 5 The two-dimensional time-frequency domain feature map extracted based on information entropy and other measurement methods is the effective power consumption data.

[0072] exist Figure 1Based on the embodiment, as an optional implementation, the pre-trained deep learning model includes a cascaded first convolution unit, a first batch normalization processing layer BN, a first self-attention layer, a second convolution unit, a second batch normalization processing layer BN, a second self-attention layer and a fully connected layer. The first convolution unit includes a cascaded first convolution layer, an activation function layer and a pooling layer; the second convolution unit includes a cascaded second convolution layer, an activation function layer and a pooling layer.

[0073] Furthermore, the parameters of the first convolutional layer include: the number of input channels is 1, the number of output channels is 16, the convolution kernel size is 5, the step size is 1, and the edge padding is 2; the parameters of the second convolutional layer include: the number of input channels is 16, the number of output channels is 32, the convolution kernel size is 3, the step size is 1, and the edge padding is 1.

[0074] Based on the above implementation, as an optional example, the training step of the pre-trained deep learning model includes:

[0075] Step 1) Obtain the deep learning training data set.

[0076] Among them, the deep learning training data set includes multiple groups of deep learning training data, each group of the deep learning training data includes second sample data and second sample true value; the second sample data is the effective power consumption sample data obtained after performing data preprocessing and feature preprocessing on the power consumption sample data in sequence; the second sample true value is the label value corresponding to the second sample data (which can be used for comparison and calculation with the label prediction value in subsequent steps), and the label value is used to characterize the chip running instructions corresponding to the second sample data.

[0077] Step 2) Input the second sample data in each group of deep learning training data into the deep learning network to be trained, and the deep learning network to be trained outputs the label prediction value corresponding to the second sample data.

[0078] Step 3) Using the deep learning loss function, based on the label prediction value (ie, probability distribution) and the corresponding second sample true value in each set of deep learning training data, obtain the function value of the deep learning loss function.

[0079] Among them, the deep learning loss function can be characterized as calculating the difference between "the label prediction value and the corresponding second sample true value in each set of deep learning training data" as the cross entropy.

[0080] Step 4), the function value of the deep learning loss function is transmitted back to the deep learning network to be trained, and the neural network to be trained adjusts the network parameters of each network layer according to the function value of the deep learning loss function;

[0081] Step 5), iteratively execute step 3) to step 4) until the preset training completion condition is met, and the pre-trained deep learning network is obtained from the deep learning network to be trained.

[0082] Among them, the preset training completion conditions are: the accuracy of the label prediction value compared to the second sample true value is greater than the preset accuracy threshold (that is, the accuracy is achieved as the optimization goal); or, the number of iterations is greater than the preset iterative training number threshold.

[0083] The following is a description of the apparatus for cross-device instruction reverse analysis provided by the present disclosure. The apparatus for cross-device instruction reverse analysis described below and the method for cross-device instruction reverse analysis described above can be referenced to each other.

[0084] Figure 6 FIG. 1 is a schematic diagram of a structure of an apparatus for reverse analysis of cross-device instructions provided by an exemplary embodiment of the present disclosure. Figure 6 As shown, the device for reverse analysis of cross-device instructions includes:

[0085] The data acquisition module 610 is configured to: acquire real-time power consumption data of the target chip during the instruction execution stage; wherein the target chip is a chip that requires instruction reverse analysis; the data preprocessing module 620 is configured to: preprocess the real-time power consumption data using data preprocessing rules to obtain first data; the feature preprocessing module 630 is configured to: process the first data using feature preprocessing rules to obtain second data; the analysis module 640 is configured to: input the second data into a pre-trained deep learning model, and the pre-trained deep learning model outputs instruction category information corresponding to the real-time power consumption data.

[0086] Figure 7 An example of a physical structure diagram of an electronic device is shown in FIG. Figure 7As shown, the electronic device may include: a processor 710, a communication interface 720, a memory 730 and a communication bus 740, wherein the processor 710, the communication interface 720 and the memory 730 communicate with each other through the communication bus 740. The processor 710 may call the logic instructions in the memory 730 to execute a method for cross-device instruction reverse analysis, the method comprising: obtaining real-time power consumption data of the target chip during the instruction execution phase; wherein the target chip is a chip for which instruction reverse analysis is required; using data preprocessing rules, preprocessing the real-time power consumption data to obtain first data; using feature preprocessing rules, processing the first data to obtain second data; inputting the second data into a pre-trained deep learning model, and the pre-trained deep learning model outputs instruction category information corresponding to the real-time power consumption data.

[0087] In addition, the logic instructions in the above-mentioned memory 730 can be implemented in the form of a software functional unit and can be stored in a computer-readable storage medium when it is sold or used as an independent product. Based on such an understanding, the technical solution of the present disclosure is essentially or the part that contributes to the prior art or the part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including a number of instructions to enable a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present disclosure. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), disk or optical disk and other media that can store program codes.

[0088] On the other hand, the present disclosure also provides a computer program product, which includes a computer program, and the computer program can be stored on a non-transitory computer-readable storage medium. When the computer program is executed by a processor, the computer can execute the method for cross-device instruction reverse analysis provided by the above-mentioned methods, and the method includes: obtaining real-time power consumption data of the target chip during the instruction execution stage; wherein the target chip is a chip that needs to perform instruction reverse analysis; using data preprocessing rules, preprocessing the real-time power consumption data to obtain first data; using feature preprocessing rules, processing the first data to obtain second data; inputting the second data into a pre-trained deep learning model, and the pre-trained deep learning model outputs instruction category information corresponding to the real-time power consumption data.

[0089] On the other hand, the present disclosure also provides a non-transitory computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, is implemented to execute the method for cross-device instruction reverse analysis provided by the above-mentioned methods, the method comprising: obtaining real-time power consumption data of the target chip during the instruction execution stage; wherein the target chip is a chip that requires instruction reverse analysis; using data preprocessing rules, preprocessing the real-time power consumption data to obtain first data; using feature preprocessing rules, processing the first data to obtain second data; inputting the second data into a pre-trained deep learning model, and the pre-trained deep learning model outputs instruction category information corresponding to the real-time power consumption data.

[0090] The device embodiments described above are merely illustrative, wherein the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the scheme of this embodiment. Ordinary technicians in this field can understand and implement it without paying creative labor.

[0091] Through the description of the above implementation methods, those skilled in the art can clearly understand that each implementation method can be implemented by means of software plus a necessary general hardware platform, and of course, it can also be implemented by hardware. Based on this understanding, the above technical solution is essentially or the part that contributes to the prior art can be embodied in the form of a software product, and the computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, a disk, an optical disk, etc., including a number of instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in each embodiment or some parts of the embodiments.

[0092] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present disclosure, rather than to limit them. Although the present disclosure has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. 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 disclosure.

Claims

1. A method for reverse analysis of cross-device instructions, comprising: Acquire real-time power consumption data of a target chip during the instruction execution phase; wherein the target chip is a chip that needs to be subjected to instruction reverse analysis; Preprocessing the real-time power consumption data using a data preprocessing rule to obtain first data; Using a feature preprocessing rule, processing the first data to obtain second data; The second data is input into a pre-trained deep learning model, and the pre-trained deep learning model outputs instruction category information corresponding to the real-time power consumption data.

2. The method according to claim 1, characterized in that The preprocessing of the real-time power consumption data by using a data preprocessing rule to obtain first data includes: Using preset standardization rules, the real-time power consumption data is standardized to obtain standardized power consumption data; Using preset data cleaning rules, the standardized power consumption data is cleaned to obtain cleaned power consumption data; The post-cleaning power consumption data is converted using a preset time-frequency domain conversion rule to obtain converted power consumption data as the first data.

3. The method according to claim 1, characterized in that: The using a feature preprocessing rule to process the first data to obtain second data includes: Inputting the first data into a pre-trained generative adversarial network, and having the pre-trained generative adversarial network output migration power consumption data corresponding to the first data; Using data enhancement rules, the migration power consumption data is processed in a two-dimensional time-frequency domain to obtain enhanced power consumption data; The inter-sample validity of the enhanced power consumption data is measured by using feature extraction rules, and effective power consumption data is selected as the second data.

4. The method according to claim 3, characterized in that The pre-trained generative adversarial network includes a generator and a discriminator; The generator includes a plurality of cascaded generation units, each of which includes a cascaded fully connected layer, a batch normalization layer BN, and an activation function layer; The discriminator network includes a plurality of cascaded discriminator units, each of which includes a cascaded fully connected layer, a batch normalization layer BN, and a nonlinear activation function layer.

5. The method according to claim 4, characterized in that The training step of the pre-trained generative adversarial network comprises: Step 1: Obtain adversarial training data set; The adversarial training data set includes multiple groups of adversarial training data, each group of the adversarial training data includes first sample data and a first sample true value; the first sample data is converted power consumption sample data obtained after performing data preprocessing on the power consumption sample data; the first sample true value is the target power consumption data corresponding to the first sample data; Step 2: inputting the first sample data in each group of adversarial training data into the to-be-trained generative adversarial network, and the to-be-trained generative adversarial network outputs migration power consumption prediction data corresponding to the first sample data; Step 3: using the adversarial loss function, based on the migration power consumption prediction data and the first sample true value in each corresponding set of adversarial training data, obtain the function value of the adversarial loss function; Step 4: The function value of the adversarial loss function is transmitted back to the generative adversarial network to be trained, and the neural network to be trained adjusts the network parameters of each network layer according to the function value of the adversarial loss function; Step 5, iteratively execute steps 3 to 4 until a preset training completion condition is met, and the pre-trained generative adversarial network is obtained from the to-be-trained generative adversarial network.

6. The method according to claim 1, characterized in that The pre-trained deep learning model includes a cascaded first convolution unit, a first batch normalization processing layer BN, a first self-attention layer, a second convolution unit, a second batch normalization processing layer BN, a second self-attention layer and a fully connected layer; The first convolution unit includes a cascaded first convolution layer, an activation function layer, and a pooling layer; the second convolution unit includes a cascaded second convolution layer, an activation function layer, and a pooling layer.

7. The method according to claim 6, characterized in that The training steps of the pre-trained deep learning model include: Step 1) Obtain a deep learning training data set; The deep learning training data set includes multiple groups of deep learning training data, each group of the deep learning training data includes second sample data and second sample true value; the second sample data is effective power consumption sample data obtained after performing data preprocessing and feature preprocessing on the power consumption sample data in sequence; the second sample true value is a label value corresponding to the second sample data, and the label value is used to characterize the chip running instruction corresponding to the second sample data; Step 2), inputting the second sample data in each group of deep learning training data into the deep learning network to be trained, and the deep learning network to be trained outputs the label prediction value corresponding to the second sample data; Step 3), using the deep learning loss function, based on the label prediction value and the corresponding second sample true value in each set of deep learning training data, obtain the function value of the deep learning loss function; Step 4), the function value of the deep learning loss function is transmitted back to the deep learning network to be trained, and the neural network to be trained adjusts the network parameters of each network layer according to the function value of the deep learning loss function; Step 5), iteratively execute step 3) to step 4) until the preset training completion condition is met, and the pre-trained deep learning network is obtained from the deep learning network to be trained.

8. A device for reverse analysis of cross-device instructions, comprising: The data acquisition module is configured to: acquire real-time power consumption data of a target chip during the instruction execution phase; wherein the target chip is a chip that needs to be subjected to instruction reverse analysis; A data preprocessing module is configured to: preprocess the real-time power consumption data using a data preprocessing rule to obtain first data; A feature preprocessing module is configured to: process the first data using a feature preprocessing rule to obtain second data; The analysis module is configured to: input the second data into a pre-trained deep learning model, and the pre-trained deep learning model outputs instruction category information corresponding to the real-time power consumption data.

9. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein: When the processor executes the program, the method for cross-device instruction reverse analysis as described in any one of claims 1 to 7 is implemented.

10. A non-transitory computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the method for cross-device instruction reverse analysis as claimed in any one of claims 1 to 7 is implemented.

Citation Information

Patent Citations

  • Unsupervised cross-domain video action recognition method based on multi-discriminator cooperation and strong and weak sharing mechanism

    CN114973107A

  • Method, apparatus, device and readable medium for transfer learning in machine learning

    US20210065058A1