A data detection method based on a quantum neural discriminator using block ciphers

By using a quantum neural discriminator based on block ciphers and leveraging quantum computing and deep learning technologies, the shortcomings of existing data detection methods are addressed, enabling efficient and accurate detection of encrypted data and reducing the risk of data leakage and tampering.

CN119675923BActive Publication Date: 2025-10-31CHONGQING UNIV OF POSTS & TELECOMM
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202411731297.9
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-11-29
Publication Date
2025-10-31
Estimated Expiration
2044-11-29

AI Technical Summary

Technical Problem

Existing data detection methods are difficult to effectively detect encrypted traffic, lack adaptability and self-learning capabilities, are easily bypassed by attackers, heavily rely on manual intervention, and are difficult to cope with constantly changing attack patterns.

Method used

By employing a quantum neural discriminator based on block ciphers, and through the training set generation and training process of the quantum neural discriminator, the parallel processing capabilities of quantum computing and deep learning techniques are utilized to identify normal and abnormal encrypted data.

Benefits of technology

It improves the detection capability of encrypted data, reduces false alarms and false negatives, lowers the risk of data leakage and tampering, and improves the efficiency of security monitoring.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119675923B_ABST
    Figure CN119675923B_ABST
Patent Text Reader

Abstract

This invention discloses a data detection method based on a quantum neural discriminator using block ciphers, comprising: a sender encrypting specific plaintext using a block cipher algorithm to obtain ciphertext data and transmitting it to a receiver; the receiver generating a specific dataset, which consists of normal data conforming to certain characteristics and random anomalous data; then, the receiver constructing a quantum neural network, wherein the input data is encoded as quantum states, convolution is achieved through rotation gates and controlled gates, and residual connections are achieved by adding control bits to the identity matrix; the network is then trained and validated to obtain an efficient quantum neural discriminator; finally, the receiver inputs the received data into the quantum neural discriminator for detection. This method integrates the powerful parallel processing capabilities of quantum computing and the advanced nature of deep learning technology, effectively distinguishing between normal and anomalous data, thereby determining whether the data has been leaked or tampered with.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of quantum information security, and in particular relates to a data detection method based on a quantum neural discriminator using block ciphers. Background Technology

[0002] With the rapid development of information technology, data security has become a focal point for nations, businesses, and individuals. In the context of global informatization and networking, data breaches and tampering incidents occur frequently, posing serious threats to national security, corporate interests, and personal privacy. Traditional encryption algorithms may be compromised by increasingly powerful computing capabilities, especially as the development of quantum computers could render current non-quantum encryption algorithms insecure.

[0003] Currently, mainstream methods for detecting data breaches and tampering primarily rely on rule-based detection systems, traffic analysis, and signature matching. These methods typically require pre-defining a series of attack signatures and rules, then identifying potential threats by monitoring network traffic and system logs. However, these methods suffer from several significant problems: First, they struggle to detect encrypted traffic, and rule-based detection is easily bypassed by attackers using mutation attacks; second, they lack adaptability and self-learning capabilities, making them ill-equipped to handle constantly evolving attack patterns; and finally, these methods heavily depend on signature engineering, requiring substantial manual intervention to update and maintain the detection rules. Therefore, exploring new security protection methods and detection technologies has become an urgent need in the field of information security. Summary of the Invention

[0004] To address the problems existing in the background technology, this invention combines the advantages of quantum mechanics and neural networks, proposing a data detection method based on a quantum neural discriminator using block ciphers. The method includes: a sender encrypting a specific plaintext pair using a block cipher algorithm to obtain a ciphertext pair, and transmitting the ciphertext pair to a receiver; the receiver inputting the received ciphertext pair into a trained quantum neural discriminator for detection, obtaining the detection result; wherein the training process of the quantum neural discriminator is as follows:

[0005] S1: Randomly generate plaintext pairs with specific differences to construct a training set, and replace some plaintext pairs in the training set with random plaintext;

[0006] S2: Use a block cipher algorithm to encrypt the plaintext pairs in the training set to obtain ciphertext pairs; among them, the ciphertext pairs of plaintext pairs that have not been replaced in the training set are used as normal data samples, and the ciphertext pairs of replaced plaintext pairs are used as abnormal data samples.

[0007] S3: The quantum neural discriminator is trained based on the constructed normal data samples and abnormal data samples to obtain a trained quantum neural discriminator.

[0008] The present invention has at least the following beneficial effects

[0009] This invention leverages the superposition of qubits in quantum computers, enabling them to simultaneously represent multiple states and achieve true parallel computing. By utilizing the powerful parallel processing capabilities of quantum computing and combining it with the advancements in deep learning technology, this invention offers the following advantages:

[0010] 1. Utilize the high efficiency of quantum neural discriminators to improve the performance of data encryption and detection, and reduce the risk of data leakage and tampering.

[0011] 2. Improve the detection capability of encrypted data: By using a neural discriminator, a model can be trained to recognize the statistical characteristics of normal encrypted data, thereby detecting abnormal or tampered encrypted data without decryption.

[0012] 3. Reduce false alarms and false negatives: Through deep learning technology, neural discriminators can more accurately identify data patterns, reduce false alarms and false negatives, and improve the efficiency of security monitoring. Attached Figure Description

[0013] Figure 1 This is a flowchart of the method of the present invention. Detailed Implementation

[0014] The following specific examples illustrate the implementation of the present invention. Those skilled in the art can easily understand other advantages and effects of the present invention from the content disclosed in this specification. The present invention can also be implemented or applied through other different specific embodiments, and various details in this specification can be modified or changed based on different viewpoints and applications without departing from the spirit of the present invention. It should be noted that the illustrations provided in the following embodiments are only schematic representations of the basic concept of the present invention. Unless otherwise specified, the following embodiments and features can be combined with each other.

[0015] Please see Figure 1 This invention provides a data detection method based on a quantum neural discriminator using block ciphers, comprising: a sender encrypting a specific plaintext pair using a block cipher algorithm to obtain a ciphertext pair, and transmitting the ciphertext pair to a receiver; the receiver inputting the received ciphertext pair into a trained quantum neural discriminator for detection, and obtaining a detection result; wherein the training process of the quantum neural discriminator is as follows:

[0016] S1: Randomly generate plaintext pairs with specific differences to construct a training set, and replace some plaintext pairs in the training set with random plaintext;

[0017] S2: Use a block cipher algorithm to encrypt the plaintext pairs in the training set to obtain ciphertext pairs; among them, the ciphertext pairs of plaintext pairs that have not been replaced in the training set are used as normal data samples, and the ciphertext pairs of replaced plaintext pairs are used as abnormal data samples.

[0018] S3: The quantum neural discriminator is trained based on the constructed normal data samples and abnormal data samples to obtain a trained quantum neural discriminator.

[0019] Preferably, step S1 includes:

[0020] S11: Select a difference path α→β with high probability, where α represents the input difference and β represents the output difference;

[0021] S12: Use a random data generator to randomly generate plaintext pairs (P) with an input difference of α. i 0 ,P i 1 (i∈1,2,…,N) and binary label list Y i Y i ∈{0,1}, where N represents the number of plaintext pairs;

[0022] S13: Y i Plaintext pairs with =0 (P) i 0 ,P i 1 ) of P i 1 Using randomly generated plaintext P i 1* Replacement yields a new plaintext pair (P) i 0 ,P i 1* ).

[0023] Preferably, before the quantum neural discriminator processes the ciphertext pair, the ciphertext pair is preprocessed. The preprocessing includes: representing the ciphertext pair (C0, C1) of length m·n as a sequence of m n-bit words (w0, w1, ..., w...). i ,…,w m-1 ), where w i (i∈0,1,…,m-1) is a row vector of an m×n matrix.

[0024] Preferably, training the quantum neural discriminator includes:

[0025] S31: Divide the preprocessed ciphertext pair into t sub-parts, and encode each sub-part into an initial quantum state using a rotation gate RY(θ).

[0026] S32: Initial quantum state After passing through the controlled quantum convolutional network system U cir The processed state is represented as Then, an identity matrix I is added, and residual connections are achieved using auxiliary quantum control to obtain the quantum state |ψ>.

[0027] S33: For the initial quantum state Convolution is performed using unitary transform via quantum circuits to obtain quantum states.

[0028] S34: Transform the quantum state As input data, a quantum Boolean circuit U is applied. b To realize a nonlinear rectifier function and obtain a quantum state

[0029] S35: Quantum state As input data, a convolution step similar to S34 is performed, resulting in a second convolution to obtain the quantum state.

[0030] S36: Measure the quantum state |ψ> to obtain the classical output y of the residual convolution. i ;

[0031] S37: Repeat steps S32 to S36, performing residual convolution on each sub-part, and then measuring to obtain the complete output y = {y1, y2, ..., y t};

[0032] S38: Using quantum circuits instead of classical fully connected layers, the results of convolution are integrated and abstracted to obtain the quantum state |Q′>;

[0033] S39: Measure the quantum state |Q′> to obtain the output value s={s1,s2,…,s v};

[0034] S310: Finally, the output value s is input into the Sigmoid activation function to obtain the predicted value, and a mean squared error loss function is constructed based on the predicted value and the true label. The parameters of the quantum neural discriminator are then tuned based on the constructed mean squared error loss function to obtain the trained quantum neural discriminator.

[0035] Preferably, step S31 includes:

[0036] S311: Divide the preprocessed ciphertext pair into t sub-parts, each sub-part z d Its size is 3×3, and its classical value is represented as x={x1,x2,…,x i ,…,x9};

[0037] S312: Initialize 9 qubits, with the initial state of all 9 qubits being |0>;

[0038] S313: Use a rotating gate RY(θ) for each sub-part z d Encode the classic value of x i As the rotation angle corresponding to each value, the initial quantum state is obtained.

[0039]

[0040] in, Represents the initial quantum state. This represents the tensor product operation.

[0041] Preferably, step S32 includes:

[0042] S321: Set auxiliary qubit |0>, quantum state Change to |q>:

[0043]

[0044] S322: Apply a Hadamard gate to the auxiliary qubit, and the quantum state |q> evolves into |q1>:

[0045]

[0046] S323: Controlled by auxiliary qubits in the initial quantum state Upper-level controlled quantum convolutional network system U cir With the identity matrix I, we obtain the quantum state |q2>:

[0047]

[0048] S324: Apply a Hadamard gate again to the auxiliary qubit of quantum state |q2> to obtain quantum state |ψ>:

[0049]

[0050] Among them, U cir This represents a controlled quantum convolutional network system.

[0051] Preferably, step S33 includes:

[0052] S331: For the initial quantum state Each qubit is subjected to a rotation gate RX(θ), and the quantum state Evolved into |u>:

[0053]

[0054] S332: Apply CNOT gates between adjacent qubits of quantum state |u> to entangle the qubits and obtain the quantum state.

[0055]

[0056] Where, θ i CNOT represents the rotation angle of the i-th qubit. i,i+1 This represents a controlled NOT gate where the i-th qubit is the control qubit and the (i+1)-th qubit is the controlled qubit. This represents the tensor product operation.

[0057] Preferably, step S35 includes:

[0058] S351: Will Using the input data, perform a second convolution to obtain...

[0059]

[0060] S352: Application of quantum Boolean circuit U b To implement a nonlinear rectifier function:

[0061]

[0062] Where, θ′ i CNOT' represents the rotation angle of the i-th qubit. i,i+1 This represents a controlled NOT gate where the i-th qubit is the control qubit and the (i+1)-th qubit is the controlled qubit. Represents tensor product operation; RX(θ′) i ) indicates a revolving door.

[0063] Preferably, step S36 includes:

[0064] S361: Measure the auxiliary qubit in the quantum state |ψ>. When the auxiliary qubit is in the |0> state, the output is:

[0065]

[0066] Among them, U cir I represents a controlled quantum convolutional network system; I represents the identity matrix.

[0067] S362: Yes Measurements were performed to obtain the classical data y after residual convolution. i .

[0068] Preferably, step S38 includes:

[0069] S381: The output of the convolution is amplitude encoded and then converted back into a quantum state of v qubits |Q>:

[0070]

[0071] S382: A quantum circuit is used for transformation, and post-processing is performed to obtain higher-level features.

[0072]

[0073] CNOT i,i+1 This represents a controlled NOT gate where the i-th qubit is the control qubit and the (i+1)-th qubit is the controlled qubit. Represents tensor product operation, R y (θ i ) represents a revolving door, θ i This represents the rotation angle of the i-th qubit.

[0074] In summary, this invention utilizes the superposition state of qubits in quantum computers, which allows for the simultaneous representation of multiple states, thus achieving true parallel computing. This invention leverages the powerful parallel processing capabilities of quantum computing, combined with the advanced nature of deep learning technology, and offers the following advantages:

[0075] 1. Utilize the high efficiency of quantum neural discriminators to improve the performance of data encryption and detection, and reduce the risk of data leakage and tampering.

[0076] 2. Improve the detection capability of encrypted data: By using a neural discriminator, a model can be trained to recognize the statistical characteristics of normal encrypted data, thereby detecting abnormal or tampered encrypted data without decryption.

[0077] 3. Reduce false alarms and false negatives: Through deep learning technology, neural discriminators can more accurately identify data patterns, reduce false alarms and false negatives, and improve the efficiency of security monitoring.

[0078] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and are not intended to limit it. Although the present invention has been described in detail with reference to preferred embodiments, those skilled in the art should understand that modifications or equivalent substitutions can be made to the technical solutions of the present invention without departing from the spirit and scope of the present invention, and all such modifications or substitutions should be covered within the scope of the claims of the present invention.

Claims

1. A data detection method based on a quantum neural discriminator using a block cipher, characterized in that, include: The sender uses a block cipher algorithm to encrypt a specific plaintext pair to obtain a ciphertext pair, and then transmits the ciphertext pair to the receiver. The receiver inputs the received ciphertext pair into a trained quantum neural discriminator for detection and obtains the detection result. The training process for the quantum neural discriminator is as follows: S1: Randomly generate plaintext pairs with specific differences to construct a training set, and replace some plaintext pairs in the training set with random plaintext; S2: Use a block cipher algorithm to encrypt the plaintext pairs in the training set to obtain ciphertext pairs; among them, the ciphertext pairs of plaintext pairs that have not been replaced in the training set are used as normal data samples, and the ciphertext pairs of replaced plaintext pairs are used as abnormal data samples. S3: The quantum neural discriminator is trained based on the constructed normal data samples and abnormal data samples to obtain a trained quantum neural discriminator; The training of the quantum neural discriminator includes: S31: Divide the preprocessed ciphertext pair into t sub-parts, and apply a rotating door to each sub-part. Encode it as an initial quantum state ; S32: Initial quantum state Through a controlled quantum convolutional network system The processed state is represented as Then add unit array Furthermore, residual connections are achieved using auxiliary quantum control to obtain quantum states. ; S33: For the initial quantum state Convolution is performed using unitary transform via quantum circuits to obtain quantum states. ; S34: Transform the quantum state As input data, quantum Boolean circuits are applied. To realize a nonlinear rectifier function and obtain a quantum state ; S35: Quantum state Using the input data, a convolution step is performed, resulting in a second convolution to obtain the quantum state. ; S36: Measuring quantum states This yields the classic output of residual convolution. ; S37: Repeat steps S32-S36, performing residual convolution on each sub-part, and then measuring to obtain the complete output. ; S38: Using quantum circuits instead of classic fully connected layers, the results of convolution are integrated and abstracted to obtain quantum states. ; S39: Regarding quantum states Perform measurements and obtain output values. ; S310: Finally, output the value The predicted value is obtained by inputting the Sigmoid activation function. The mean squared error loss function is constructed based on the predicted values ​​and the true labels, and the parameters of the quantum neural discriminator are tuned based on the constructed mean squared error loss function to obtain the trained quantum neural discriminator.

2. The data detection method for a quantum neural discriminator based on a block cipher according to claim 1, characterized in that, Step S1 includes: S11: Select a difference path with high probability. ,in, Indicates the input difference. Indicates the output difference; S12: Use a random data generator to randomly generate the input difference. plaintext and binary tag list , N represents the number of plaintext pairs; S13: Will plaintext of Using randomly generated plaintext Replacement, resulting in a new plaintext pair .

3. The data detection method for a quantum neural discriminator based on a block cipher according to claim 1, characterized in that, Before the quantum neural discriminator processes the ciphertext pair, it undergoes preprocessing, which includes: dividing the ciphertext pair into pairs of lengths of... ciphertext pair Represented as a sequence of m words, each n-digit in length. ,in, It is The row vectors of the matrix.

4. The data detection method for a quantum neural discriminator based on a block cipher according to claim 1, characterized in that, Step S31 includes: S311: Divide the preprocessed ciphertext pair into... Each sub-part The size is Its classical value is expressed as ; S312: Initialize 9 qubits, the initial state of all 9 qubits is... ; S313: Using a revolving door For each sub-part Encode the classic values, As the rotation angle corresponding to each value, the initial quantum state is obtained. : in, Represents the initial quantum state. This represents the tensor product operation.

5. The data detection method for a quantum neural discriminator based on a block cipher according to claim 1, characterized in that, Step S32 includes: S321: Setting up auxiliary qubits quantum state Become : S322: Apply a Hadamard gate to the auxiliary qubit, quantum state Evolved into : S323: Controlled by auxiliary qubits in the initial quantum state Controlled quantum convolutional network system and unit array To obtain a quantum state : S324: Again, regarding quantum states Applying a Hadamard gate to the auxiliary qubit yields the quantum state. : in, This represents a controlled quantum convolutional network system.

6. The data detection method for a quantum neural discriminator based on a block cipher according to claim 1, characterized in that, Step S33 includes: S331: For the initial quantum state Apply a rotating gate to each qubit quantum state Evolved into : S332: In quantum state CNOT gates are applied between adjacent qubits to entangle them, thus obtaining quantum states. : in, This represents the rotation angle of the i-th qubit. This represents a controlled NOT gate where the i-th qubit is the control qubit and the (i+1)-th qubit is the controlled qubit. This represents the tensor product operation.

7. The data detection method for a quantum neural discriminator based on a block cipher according to claim 1, characterized in that, Step S35 includes: S351: Will Using the input data, perform a second convolution to obtain... : S352: Application of Quantum Boolean Circuits To implement the nonlinear rectified function (ReLU): in, This represents the rotation angle of the i-th qubit. This represents a controlled NOT gate where the i-th qubit is the control qubit and the (i+1)-th qubit is the controlled qubit. Represents tensor product operation; This refers to a revolving door.

8. The data detection method for a quantum neural discriminator based on a block cipher according to claim 1, characterized in that, Step S36 includes: S361: Regarding quantum states Measurements are performed using the auxiliary qubits in the qubits, when the auxiliary qubits are In this state, the output result is: in, This represents a controlled quantum convolutional network system; Represents the identity matrix; S362: Yes Measurements were performed to obtain the classical data after residual convolution. .

9. The data detection method for a quantum neural discriminator based on a block cipher according to claim 1, characterized in that, Step S38 includes: S381: The output of the convolution is amplitude encoded and then converted back into a quantum state of v qubits. : S382: A quantum circuit is used for transformation, and post-processing is performed to obtain higher-level features. in, This represents a controlled NOT gate where the i-th qubit is the control qubit and the (i+1)-th qubit is the controlled qubit. This represents the tensor product operation. Indicates a revolving door. This represents the rotation angle of the i-th qubit.

Citation Information

Patent Citations

  • Quantum discrimination line and model for progressive training

    CN114399053A

  • Block cipher differential analysis method and system based on quantum neural network, and storage medium

    CN117749350A