Frequency domain encryption method and device of medical image, computer device and storage medium

By combining folded real complex transform and fast Fourier transform with an improved Logistic chaotic system, frequency domain encryption of medical images is performed, solving the problems of high computational complexity and insufficient security of traditional methods, and achieving fast, secure encryption while maintaining image quality.

CN117319567BActive Publication Date: 2026-06-19JINAN UNIVERSITY

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
JINAN UNIVERSITY
Filing Date
2023-08-21
Publication Date
2026-06-19

AI Technical Summary

Technical Problem

Traditional medical image encryption methods are computationally complex and slow when processing large-scale medical images, and may lead to image quality loss, affecting diagnostic results. They are also sensitive to keys and lack security.

Method used

The image is transformed to the frequency domain using folded real complex transform and fast Fourier transform. A key is generated by combining an improved Logistic chaotic system. The frequency domain image is then adjusted and obfuscated. Encryption and decryption are performed using bitwise XOR operation and chaotic sequences to maintain image quality and improve security.

Benefits of technology

It achieves efficient and secure medical image encryption, maintains image quality, resists known-plaintext and chosen-plaintext attacks, and is suitable for practical application scenarios.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117319567B_ABST
    Figure CN117319567B_ABST
Patent Text Reader

Abstract

This invention discloses a frequency domain encryption method, apparatus, computer device, and storage medium for medical images. The frequency domain encryption method first applies folded real-complex transform and fast Fourier transform to convert the original medical image to the frequency domain space. Then, based on the characteristics of the frequency domain coefficients and the encryption algorithm, the frequency domain image is adjusted and obfuscated to achieve image encryption. During the encryption process, considering the sensitivity of medical images, a randomly generated key combined with an improved Logistic chaotic system is used to control the encryption process, increasing security. This invention provides an efficient, secure, and minimally impactful frequency domain-based medical image encryption method. By utilizing frequency domain characteristics and image histogram analysis, it achieves protection and privacy of medical images while maintaining visual quality and the integrity of diagnostic information. The encryption method disclosed in this invention can be widely applied to the secure transmission and storage of medical images.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of frequency domain encryption technology for images, and specifically to a method, apparatus, computer device, and storage medium for frequency domain encryption of medical images. Background Technology

[0002] With the widespread use of medical images in medical diagnosis and treatment, protecting the security and privacy of these images has become increasingly important. Medical images often contain sensitive patient privacy information, such as the patient's body parts, condition, and disease type. Therefore, encrypting medical images to prevent unauthorized access and information leakage is crucial.

[0003] Traditional medical image encryption methods are primarily based on conventional encryption algorithms such as DES and AES. While these algorithms provide a certain level of security during transmission, their high computational complexity and memory requirements result in slow encryption and decryption speeds when processing large-scale medical images. Furthermore, traditional encryption methods replace or permutate pixel values, which may cause the encrypted image to lose some important details, affecting the diagnostic accuracy of the medical image.

[0004] To overcome the limitations of traditional encryption methods, frequency-domain-based medical image encryption methods have received widespread attention in recent years. Frequency-domain encryption methods transform images into the frequency domain and utilize its characteristics for encryption, offering higher security and faster encryption speeds. Common frequency-domain encryption methods include those based on Fourier transform and wavelet transform. These methods achieve image encryption and decryption by adjusting and obfuscating frequency domain coefficients. However, these methods still have some problems, such as the loss of image quality after encryption, the complexity of the encryption algorithm, and sensitivity to the key.

[0005] Therefore, there is a need for an efficient, secure medical image encryption method that minimizes the impact on the quality of the original image. This method should provide strong protection while preserving the visual quality and diagnostic information of the medical images. Summary of the Invention

[0006] The purpose of this invention is to address the aforementioned deficiencies in traditional medical image encryption methods and to provide a frequency domain encryption method, apparatus, computer device, and storage medium for medical images to meet the requirements for medical image security and privacy.

[0007] The first objective of this invention is to provide a frequency domain encryption method for medical images, comprising the following steps:

[0008] S1. Preprocessing medical images: The original medical images are transformed into the frequency domain space through folding real-complex transformation and frequency domain transformation to obtain frequency domain images;

[0009] S2. Generate a key using a chaotic system: Generate a key using an improved Logistic chaotic system, and use this key to adjust and obfuscate the frequency domain image to obtain an encrypted frequency domain image;

[0010] S3. Transmission and decryption of encrypted images: Transmit the key and the encrypted image, and decrypt it at the receiving end to obtain the original image.

[0011] Furthermore, the preprocessing procedure for the medical images in step S1 is as follows:

[0012] S11, Transfer the original medical image H N×M The matrix H′ is obtained through folding real complex transformation. N / 2×M Where N and M are the original medical image matrix H N×M The number of rows and columns. This step compresses the original input image to half its original size, thus improving the efficiency of the conversion to the frequency domain;

[0013] S12. The matrix H′ obtained by the above folding real complex transformation. N / 2×M The matrix generated by converting to the frequency domain using the Fast Fourier Transform is S′. N / 2×M The Fast Fourier Transform (FFT) is used because of its efficiency and ease of use; compared to the Discrete Fourier Transform, it has a computational complexity of O(N). 2 The cost is reduced to O(NlogN), where N is the size of the image;

[0014] Furthermore, the key generation and encryption process using a chaotic system in step S2 is as follows:

[0015] S21. Improved Logistic Chaotic System. Using only frequency domain transformation makes encryption systems vulnerable to known-plaintext and chosen-plaintext attacks. Chaotic sequences exhibit deterministic characteristics and high sensitivity to initial conditions, displaying complex and unpredictable properties; therefore, their quasi-random chaotic sequences are suitable for encryption systems. The original Logistic chaotic system is defined as...

[0016] x n+1 =μx n (1-x n (3)

[0017] Where μ is an adjustable parameter and n is the time iteration step. When μ∈(3.57,4], and x nWhen x ∈ (0,1], the system exhibits chaotic characteristics. Studies have shown that the one-dimensional chaotic system Logistic can satisfy the security requirements of encryption systems, and because it consumes relatively few computational resources, it can also meet the real-time requirements of encryption and decryption. This invention improves the Logistic chaotic system to give it higher entropy, thereby enhancing security. The improvement process is as follows: Assume that the probability density functions of variables x and y are f(t) and g(t), respectively, which are greater than 0 in a given interval and satisfy the following equation:

[0018] ∫ a x f(t)dt=∫ c y g(t)dt (4)

[0019] Where a≤x≤b, c≤x≤d. Additionally, the following definitions are given:

[0020]

[0021] Suppose that f(t) follows a uniform distribution in the given interval [0,1] (i.e., a = 0, b = 1). The following equation can be derived:

[0022] p(x) = x = ∫ c y g(t)dt (6)

[0023] Where x∈[0,1]. By setting [c,d]=[0,1], we get:

[0024]

[0025] This means that if a function is used Transforming the samples in formula (1), i.e. formula (2), the generated sequence {z} n It follows a uniform distribution.

[0026] The first key of this medical image encryption system is K1 = {μ′, x′0}, and the second key is K2 = {μ″, x″0}. Substituting K1 and K2 into formula (1) respectively, let x n Given x′0 and x″0, and μ′ and μ″ respectively, we obtain x′1 and x″1. After iterating N×M / 2 and N×M steps respectively, we obtain two chaotic sequences of length N×M / 2 and N×M respectively. and x′ i and x″ i Let K1 and K2 represent the states of the Logistic chaotic system generated by the first key K1 and the second key K2 at the i-th time step, respectively. and Substitute into formula (2) respectively, and let x n be x′ i and x″i respectively, and the first chaotic sequence and the second chaotic sequence z′ i and z″ i represent the states of the improved Logistic chaotic system generated by the first key K1 and the second key K2 at the i-th time step respectively, and are used for subsequent adjustment and confusion operations, where π′ is the first parameter for constructing the first key K1, x′0 is the second parameter for constructing the first key K1, π″ is the first parameter for constructing the second key K2, and x″0 is the second parameter for constructing the second key K2;

[0027] S22. Adjust the dimension of the matrix S′ N / 2×M to obtain the matrix S′ 1×MN / 2 . Sort the states of the chaotic system in the first chaotic sequence , that is, the values of z′ i from small to large to obtain the sorted index sequence L, and the values of the index sequence L are the new subscripts of the corresponding elements of the matrix S′ 1×MN / 2 . The matrix S′ 1×MN / 2 regenerated after being permuted by the chaotic sequence Q1 is the matrix S″ N / 2×M . By associating each element with its corresponding position in the chaotic sequence, this step initially introduces randomness and complexity to the encrypted image;

[0028] S23. Use the inverse fast Fourier transform on the matrix S″ N / 2×M to obtain H″ N / 2×M , and convert the frequency-domain image to a spatial-domain image. Use the complex-to-real transformation to convert the matrix H″ N / 2×M into the medical image S of the original size N×M ;

[0029] S24. Adjust the dimension of the medical image S N×M to obtain the matrix S 1×NM . Perform self-confusion on the matrix S 1×NM . Perform a bitwise exclusive OR (XOR) operation on each element of the matrix S 1×NM with the next element to obtain the matrix S″′ 1×NM , that is: 1≤j<M×N, where ⊕ represents the bitwise exclusive OR operation, S 1,j represents the j-th element in the first row of the matrix S 1×NM , S 1,j+1 represents the next element of the j-th element in the first row of the matrix S 1×NM , and S″′ 1,j represents the matrix S″′ 1×NMThe j-th element in the first row. This operation introduces a form of diffusion into the medical image itself, where information from adjacent pixels is mixed together. By performing the self-diffusion operation, the correlation between adjacent pixels is destroyed, making it more difficult to discern any patterns or meaningful information in the image;

[0030] S25. Transform matrix S″′ 1×NM With the second chaotic sequence To perform image obfuscation, matrix S″″ 1×NM Each element in the matrix is ​​XORed with the corresponding element in the second chaotic sequence Q2 to obtain the matrix S″″. 1×NM ,Right now: 1≤j≤M×N, where, S″′ represents the bitwise XOR operation. 1,j Represents matrix S″′ 1×NM The j-th element in the first row, z″ j S″′ represents the j-th element of the second chaotic sequence Q2. 1,j Representation matrix S″″ 1×NM The j-th element in the first row, and finally the matrix S″″ 1×NM Dimensional adjustment yields the matrix This is the encrypted image. By applying image diffusion operations, the information in the image is further mixed and dispersed, making it more difficult for unauthorized users to extract any meaningful content.

[0031] Furthermore, step S3, the transmission and decryption process of the encrypted image, is as follows:

[0032] S31. Transmit encrypted images over a public channel. And a first key K1 = {μ′, x′0} and a second key K2 = {μ″, x″0} to ensure their secure sharing between the sender and receiver;

[0033] S32. The receiver substitutes the received first key K1 = {μ′, x′0} and second key K2 = {μ″, x″0} into formula (1), and lets x n Given x′0 and x″0, and μ′ and μ″ respectively, we obtain x′1 and x″1. After iterating N×M / 2 and N×M steps respectively, we obtain two chaotic sequences of length N×M / 2 and N×M respectively. and x′ i and x″ i Let K1 and K2 represent the states of the Logistic chaotic system generated by the first key K1 and the second key K2 at the i-th time step, respectively. and Substituting into formula (2) respectively, let xn are x′ i and x″ i , to obtain the first chaotic sequence and the second chaotic sequence z′ i and z″ i respectively represent the states of the improved Logistic chaotic system generated by the first key K1 and the second key K2 at the i-th time step;

[0034] S33. Adjust the dimensions of the encrypted image to obtain the matrix S″″ 1×NM . Each element of the matrix S″″ 1×NM is subjected to a bitwise exclusive OR (XOR) operation with the corresponding element of the second chaotic sequence Q2 to obtain the matrix S″′ 1×NM , that is: 1 ≤ j ≤ M×N, where represents the bitwise exclusive OR operation, S″′ 1,j represents the element in the first row and the j-th column of the matrix S″′ 1×NM , z″ j represents the j-th element of the second chaotic sequence Q2, and S″″ 1,j represents the element in the first row and the j-th column of the matrix S″″ 1×NM ;

[0035] S34. Each element of the matrix S″′ 1×NM is subjected to a bitwise exclusive OR (XOR) operation with the next element at the corresponding position of the S 1×NM matrix to obtain the matrix S 1×NM , that is: 1 ≤ j < M×N, where represents the bitwise exclusive OR operation, S 1,j represents the element in the first row and the j-th column of the matrix S 1×NM , S 1,j+1 represents the next element of the element in the first row and the j-th column of the matrix S 1×NM , S″′ 1,j represents the element in the first row and the j-th column of the matrix S″′ 1×NM . The matrix S 1×NM is dimensionally adjusted to obtain the matrix S N×M ;

[0036] S35. The matrix S N×M is transformed through complex-to-real transformation to obtain H″ N / 2×M . The inverse fast Fourier transform is used for the matrix H″ N / 2×M to obtain S″ N / 2×M ;

[0037] S36. The matrix S″ N / 2×M is dimensionally adjusted to obtain the matrix S″1×MN / 2 The first chaotic sequence The state of a chaotic system, i.e., z′ i Sort the values ​​in ascending order to obtain the sorted index sequence L. Then, place the index sequence L in S″. 1×MN / 2 The values ​​obtained from the index are arranged according to the corresponding indices of the first chaotic sequence Q1 to obtain the inverse permutation matrix S′. 1×MN / 2 , matrix S′ 1×MN / 2 Dimensional adjustment yields matrix S′ N / 2×M ;

[0038] S37, Matrix S′ N / 2×M H′ is obtained through Fast Fourier Transform. N / 2×M Matrix H′ N / 2×M The decrypted medical image H is obtained through folding real-complex transformation. N×M .

[0039] A second objective of this invention is to provide a frequency domain encryption device for medical images, the frequency domain encryption device comprising:

[0040] The preprocessing medical image module transforms the original medical image into a frequency domain image by using folded real-complex transformation and frequency domain transformation.

[0041] The chaotic system generates a key module that uses an improved Logistic chaotic system to generate a key. This key is then used to adjust and obfuscate the frequency domain image, resulting in an encrypted frequency domain image.

[0042] The encrypted image transmission and decryption module transmits the key and the encrypted image, and performs decryption on the receiving end to obtain the original image.

[0043] A third objective of the present invention is to provide a computer device including a processor and a memory for storing a processor-executable program, wherein when the processor executes the program stored in the memory, it implements a frequency domain encryption method for medical images.

[0044] A fourth objective of this invention is to provide a storage medium storing a program that, when executed by a processor, implements a frequency domain encryption method for medical images.

[0045] The present invention has the following advantages and effects compared with the prior art:

[0046] 1. High Security: Introducing a chaotic system into the image encryption system, the generated random sequences are used for adjustment and obfuscation operations, increasing the complexity of encryption and improving the security of medical images. Specifically, this invention uses an improved Logistic chaotic system, which has higher entropy than the traditional Logistic chaotic system, further enhancing security. Simultaneously, this chaotic system maintains the lower computational resource consumption of the original Logistic chaotic system.

[0047] 2. Fast and Efficient: This invention does not directly perform frequency domain transformation on spatial medical images, but instead uses a folded version of the real-valued image. Before performing the frequency domain transformation, N real-valued vectors of length N are compressed into N / 2 complex vectors of length N, thereby optimizing the adjustment steps. This technique allows us to scramble an N / 2×M matrix instead of an N×M matrix, significantly reducing computational complexity and resource requirements. Furthermore, the Fast Fourier Transform (FFT) is employed, which has lower time complexity than the Discrete Fourier Transform (DFT). These features enable the encryption and decryption processes to be completed quickly on a computer, making it suitable for practical applications.

[0048] 3. Privacy protection: The encrypted image is visually almost indistinguishable from the original image, effectively protecting the privacy information in medical images.

[0049] 4. Maintain image quality: During encryption and decryption, the image quality is almost unaffected, preserving the image details and clarity. Attached Figure Description

[0050] The accompanying drawings, which are included to provide a further understanding of the invention and form part of this application, illustrate exemplary embodiments of the invention and, together with their description, serve to explain the invention and do not constitute an undue limitation thereof. In the drawings:

[0051] Figure 1 This is a flowchart of the frequency domain-based medical image encryption and decryption method disclosed in this invention;

[0052] Figure 2 These are grayscale histograms of the original medical image and the encrypted medical image in this embodiment of the invention;

[0053] Figure 3 This is a schematic diagram of the original medical image, encrypted medical image, and decrypted medical image in an embodiment of the invention;

[0054] Figure 4 This is a structural block diagram of the frequency domain encryption device for medical images in Embodiment 2 of the present invention;

[0055] Figure 5 This is a structural block diagram of the computer device in Embodiment 3 of the present invention. Detailed Implementation

[0056] 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, 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.

[0057] Example 1

[0058] like Figure 1 As shown, this example discloses a frequency domain-based medical image encryption method, including: S1, preprocessing of the medical image: transforming the original medical image to the frequency domain space through folded real-complex transformation and frequency domain transformation to obtain a frequency domain image; S2, generating a key and encryption using a chaotic system: generating a key using an improved Logistic chaotic system for adjusting and obfuscating the frequency domain image to achieve image encryption; S3, transmitting and decrypting the encrypted image: transmitting the key and the encrypted image, and performing decryption at the receiving end to obtain the original image. The specific implementation process is as follows:

[0059] S1. Preprocessing medical images: The original medical image is transformed into a frequency domain image through folding real-complex transformation and frequency domain transformation. The process is as follows:

[0060] S11. Select six different medical images for illustration: CR-10-chest.dcm (hereinafter referred to as "chest"), CT-16-brain.dcm (hereinafter referred to as "brain"), CT-16-ort.dcm (hereinafter referred to as "ort"), and MR-16-knee.dcm (hereinafter referred to as "knee"). Transfer the original medical image H... N×M The matrix H′ is obtained through folding real complex transformation. N / 2×M Where N and M are the original medical image matrix H N×M The number of rows and columns;

[0061] S12. The matrix H′ obtained by the above folding real complex transformation. N / 2×M The matrix generated by converting to the frequency domain using the Fast Fourier Transform is S′. N / 2×M 。;

[0062] S2. Generating keys using a chaotic system: A key is generated using an improved Logistic chaotic system for adjusting and obfuscating frequency domain images, thereby encrypting the images.

[0063] Step S2 is as follows:

[0064] S21, Improved Logistic chaotic system as

[0065] x n+1 =μx n (1-x n (1)

[0066]

[0067] In formulas (1) and (2), μ is an adjustable parameter, n is the time iteration step, and x n Let z represent the state of the Logistic chaotic system at time step n. n Let represent the improved Logistic chaotic system state at the nth time step, where μ∈(3.57,4] and x n Substituting the first key K1 = {μ′, x′0} and the second key K2 = {μ″, x″0} into formula (1) respectively, let x n Given x′0 and x″0, and μ′ and μ″ respectively, we obtain x′1 and x″1. After iterating N×M / 2 and N×M steps respectively, we obtain two chaotic sequences of length N×M / 2 and N×M respectively. and x′ i and x″ i Let K1 and K2 represent the states of the Logistic chaotic system generated by the first key K1 and the second key K2 at the i-th time step, respectively. and Substituting into formula (2) respectively, let x n x′ i and x″ i The first chaotic sequence is obtained. Second chaotic sequence z′ i and z″ i Let μ′ and x′0 represent the improved Logistic chaotic system state generated by the first key K1 and the second key K2 at the i-th time step, respectively, for subsequent adjustment and scrambling operations. μ′ is the first parameter used to construct the first key K1, x′0 is the second parameter used to construct the first key K1, and μ″ is the first parameter used to construct the second key K2, x″0 is the second parameter used to construct the second key K2. Considering that the maximum value of the variable under the IEEE 754 32-bit floating-point standard is 3.4 × 10⁻⁶, this approach is not feasible. 38 Therefore, the key space of a cryptographic system based on the Logistic system is approximately 10. 37×4 ≈10 148. The huge key space makes this encryption system resistant to brute-force attacks, further ensuring its security. To detect the randomness of the first chaotic sequence Q1 and the second chaotic sequence Q2, the present invention uses the NIST test, and the results are shown in Table 1 below:

[0068] Table 1. NIST test results of chaotic sequences

[0069] NIST Test P-Value result Frequency Test 0.4872 success Block Frequency Test 0.6728 success Runs Test 0.2314 success Longest Run of Ones Test 0.9176 success Binary Matrix Rank Test 0.3053 success Discrete Fourier Transform Test 0.8121 success Non-overlapping Template Test 0.6512 success Overlapping Template Test 0.4269 success Universal Test 0.5398 success Linear Complexity Test 0.3765 success Serial Test 0.9463 success Approximate Entropy Test 0.7734 success Cumulative Sums Test 0.4136 success Random Excursions Test 0.6978 success Random Excursion Variant Test 0.5819 success

[0070] According to the p-values obtained from the NIST test, we can evaluate the randomness of the constructed chaotic sequences. Generally speaking, if the p-values are uniformly distributed between 0 and 1, it can be concluded that the sequences have high randomness. However, if any p-value is lower than a predetermined significance level (such as 0.05), the sequence can be considered to deviate from randomness. In the above results, all the p-values obtained from the NIST test are quite high, indicating that the constructed chaotic sequences have good randomness. These results show that the confusion step effectively increases the entropy of the encrypted image and enhances the security of the encryption scheme.

[0071] S22. Adjust the dimension of the matrix S′ N / 2×M to obtain the matrix S′ 1×MN / 2 . Sort the states of the chaotic system in the first chaotic sequence , that is, the numerical values of z″ i from small to large to obtain the sorted index sequence L. The values of the index sequence L are the new subscripts of the corresponding elements of the matrix S′ 1×MN / 2 . The matrix S′ 1×MN / 2 after being permuted using the chaotic sequence Q1 is regenerated as the matrix S″ N / 2×M ;

[0072] S23. The matrix S″ N / 2×M uses the inverse fast Fourier transform to obtain H″ N / 2×M , converting the frequency-domain image to the spatial-domain image. Use the complex-to-real transformation to convert the matrix H″ N / 2×M into the medical image S of the original size N×M ;

[0073] S24. Adjust the dimension of the medical image S N×M to obtain the matrix S 1×NM . Perform self-confusion on the matrix S 1×NM . Perform a bitwise exclusive OR (XOR) operation on each element of the matrix S 1×NM with the next element to obtain the matrix S″′ 1×NM , that is: 1 ≤ j < M × N, where represents the bitwise exclusive OR operation, and S 1,j represents the matrix S 1×NMThe j-th element in the first row, S 1,j+1 Representation matrix S 1×NM The element following the j-th element in the first row, S″′ 1,j Represents matrix S″′ 1×NM The j-th element in the first row;

[0074] S25. Transform matrix S″′ 1×NM With the second chaotic sequence To perform image obfuscation, matrix S″″ 1×NM Each element in the matrix is ​​XORed with the corresponding element in the second chaotic sequence Q2 to obtain the matrix S″″. 1×NM ,Right now: 1≤j≤M×N, where, S″′ represents the bitwise XOR operation. 1,j Represents matrix S″′ 1×NM The j-th element in the first row, z″ j S″″ represents the j-th element of the second chaotic sequence Q2. 1,j Representation matrix S″″ 1×NM The j-th element in the first row, and finally the matrix S″″ 1×NM Dimensional adjustment yields the matrix This is the encrypted image. By analyzing the grayscale histogram, we can understand the distribution of pixels in the image. A uniformly distributed histogram helps to hide the original statistical features. A comparison of the histograms of the original and encrypted images is shown below. Figure 2 As shown. Figure 2 The left column shows the histograms of the original Ort and Knee medical images, and the right column shows the histograms of the corresponding encrypted images. It can be observed that the pixels in the encrypted images are uniformly distributed, thus effectively hiding the features of the original images. Covariance analysis was used to analyze the correlation between adjacent pixels in the images. The results are shown in Table 2, with the correlation in each direction approaching zero.

[0075] Table 2. Correlation Comparison Table of Adjacent Pixels

[0076] direction Original image Encrypted images level 0.9373 0.0219 vertical 0.9693 0.0032 diagonal 0.9187 0.0111

[0077] S3. Transmission and decryption of encrypted images: Transmit the key and encrypted image, and decrypt them at the receiving end to obtain the original image;

[0078] The process of step S3 is as follows:

[0079] S31. Transmit encrypted images over a public channel. The first key K1 = {μ′, x′0} and the second key K2 = {μ″, x′0′} are used to ensure their secure sharing between the sender and receiver;

[0080] S32. The receiver substitutes the received first key K1 = {μ′, x′0} and second key K2 = {μ″, x″0} into formula (1), and let x n be x′0 and x″0 respectively, μ be μ′ and μ″ respectively, and obtain x1′ and x″1 respectively. Then iterate N×M / 2 and N×M steps to obtain two chaotic sequences with lengths of N×M / 2 and N×M respectively and x′ i and x″ i respectively represent the states of the Logistic chaotic system generated by the first key K1 and the second key K2 at the i-th time step. Then and are respectively substituted into formula (2), and let x n be x′ i and x″ i respectively, and obtain the first chaotic sequence and the second chaotic sequence z′ i and z″ i respectively represent the states of the improved Logistic chaotic system generated by the first key K1 and the second key K2 at the i-th time step;

[0081] S33. The encrypted image is dimensionally adjusted to obtain the matrix S″″ 1×NM . Each element of the matrix S″″ 1×NM is subjected to a bitwise exclusive OR (XOR) operation with the corresponding element of the second chaotic sequence Q2 to obtain the matrix S″′ 1×NM , that is: 1 ≤ j ≤ M×N, where represents the bitwise exclusive OR operation, S″′ 1,j represents the j-th element in the first row of the matrix S″′ 1×NM , z″ j represents the j-th element of the second chaotic sequence Q2, and S″″′ 1,j represents the j-th element in the first row of the matrix S″″ 1×NM ;

[0082] S34. Each element of the matrix S″′ 1×NM is subjected to a bitwise exclusive OR (XOR) operation with the next element at the corresponding position of the S 1×NM matrix to obtain the matrix S 1×NM , that is: 1 ≤ j < M×N, where represents the bitwise exclusive OR operation, S 1,j represents the j-th element in the first row of the matrix S 1×NM ; 1,j+1 Representation matrix S 1×NM The element following the j-th element in the first row, S″′ 1,j Represents matrix S″′ 1×NM The j-th element in the first row will transform matrix S. 1×NM Dimensional adjustment yields matrix SN ×M ;

[0083] S35, Matrix S N×M H″ is obtained through complex real transformation. N / 2×M For matrix H″ N / 2×M S″ is obtained using the inverse fast Fourier transform. N / 2×M ;

[0084] S36, Transform matrix S″ N / 2×M Dimensional adjustment yields matrix S″ 1×MN / 2 The first chaotic sequence The state of a chaotic system, i.e., z′ i Sort the values ​​in ascending order to obtain the sorted index sequence L. Then, place the index sequence L in S″. 1×MN / 2 The values ​​obtained from the index are arranged according to the corresponding indices of the first chaotic sequence Q1 to obtain the inverse permutation matrix S′. 1×MN / 2 , matrix S′ 1×MN / 2 Dimensional adjustment yields matrix S′ N / 2×M ;

[0085] S37, Matrix S′ N / 2×M H′ is obtained through Fast Fourier Transform. N / 2×M Matrix H′ N / 2×M The decrypted medical image H is obtained through folding real-complex transformation. N×M Comparison of original image, encrypted image, and decrypted image. Figure 3 As shown. Figure 3The left column shows the original medical images of the ort and knee, the middle column shows the corresponding encrypted images, and the right column shows the decrypted images. The encrypted images are visually almost indistinguishable from the original images, effectively protecting the privacy information in medical images. The superiority of this encryption algorithm will be illustrated using several metrics. First, NPRC (Number of Pixels Change Rate) and UACI (Unified Average Changing Intensity) will be used to demonstrate the invention's resistance to differential attacks. The benchmark comparison methods used were: A) a medical image encryption scheme using a high-dimensional hyperchaotic Lorentz system [Wang, Y., Wong, K., Liao, X., Chen, G.: A new chaos-based fast image encryption algorithm. Appl. Soft Comput. 11(1), 514–522 (2011).]; B) a medical image encryption scheme combining deep learning and chaotic systems [Sun, F., Liu, S., Li, Z., Lu, Z.: A novel image encryption scheme based on spatial chaos map. Chaos, Solitons & Fractals 38(3), 631–640 (2008)]. The experimental results are shown in Table 3.

[0086] Table 3. Performance Comparison of Encryption Schemes Against Differential Attacks

[0087]

[0088] Then, key sensitivity analysis was performed by calculating the normalized mean square error (NMSE) between the decrypted image and the original image. The initial parameters were set to (μ′,μ″,x′0,x″0)=(3.9,0.3256,3.91,0.4431). Then, the parameter μ was changed while keeping other parameters constant. Table 4 shows the experimental results, indicating that even slight parameter changes can lead to a decrease in the quality of the decrypted image, i.e., decryption failure.

[0089] Table 4. Key Sensitivity Test Results

[0090]

[0091]

[0092] Example 2

[0093] like Figure 4As shown, this embodiment provides a frequency domain encryption device for medical images. The device includes a preprocessing medical image module 401, a chaotic system key generation module 402, and an encrypted image transmission and decryption module 403. The specific functions of each module are as follows:

[0094] The preprocessing medical image module 401 transforms the original medical image into a frequency domain image by folding real-complex transformation and frequency domain transformation.

[0095] The chaotic system key generation module 402 uses an improved Logistic chaotic system to generate a key, and uses the key to adjust and confuse the frequency domain image to obtain an encrypted frequency domain image.

[0096] The encrypted image transmission and decryption module 403 transmits the key and the encrypted image, and performs a decryption operation at the receiving end to obtain the original image.

[0097] The specific implementation of each module in this embodiment can be found in Embodiment 1 above, and will not be repeated here. It should be noted that the device provided in this embodiment is only illustrated by the division of the above functional modules. In practical applications, the above functions can be assigned to different functional modules as needed, that is, the internal structure can be divided into different functional modules to complete all or part of the functions described above.

[0098] Example 3

[0099] This embodiment provides a computer device, which can be a computer, such as... Figure 5 As shown, the system bus 501 connects a processor 502, a memory, an input device 503, a display 504, and a network interface 505. The processor provides computing and control capabilities. The memory includes a non-volatile storage medium 506 and internal memory 507. The non-volatile storage medium 506 stores the operating system, computer programs, and a database. The internal memory 507 provides an environment for the operation of the operating system and computer programs in the non-volatile storage medium. When the processor 502 executes the computer programs stored in the memory, it implements the frequency domain encryption method for medical images proposed in Embodiment 1 above, as follows:

[0100] S1. Preprocessing medical images: The original medical images are transformed into the frequency domain space through folding real-complex transformation and frequency domain transformation to obtain frequency domain images;

[0101] S2. Generate a key using a chaotic system: Generate a key using an improved Logistic chaotic system, and use this key to adjust and obfuscate the frequency domain image to obtain an encrypted frequency domain image;

[0102] S3. Transmission and decryption of encrypted images: Transmit the key and the encrypted image, and decrypt it at the receiving end to obtain the original image.

[0103] Example 4

[0104] This embodiment provides a storage medium, which is a computer-readable storage medium, storing a computer program. When the computer program is executed by a processor, it implements a frequency domain encryption method for medical images according to Embodiment 1 above, as follows:

[0105] S1. Preprocessing medical images: The original medical images are transformed into the frequency domain space through folding real-complex transformation and frequency domain transformation to obtain frequency domain images;

[0106] S2. Generate a key using a chaotic system: Generate a key using an improved Logistic chaotic system, and use this key to adjust and obfuscate the frequency domain image to obtain an encrypted frequency domain image;

[0107] S3. Transmission and decryption of encrypted images: Transmit the key and the encrypted image, and decrypt it at the receiving end to obtain the original image.

[0108] The storage medium described in this embodiment can be a disk, optical disk, computer memory, random access memory (RAM), USB flash drive, portable hard drive, etc.

[0109] The above embodiments are preferred embodiments of the present invention, but the embodiments of the present invention are not limited to the above embodiments. Any changes, modifications, substitutions, combinations, or simplifications made without departing from the spirit and principle of the present invention shall be considered equivalent substitutions and shall be included within the protection scope of the present invention.

[0110] The above embodiments are preferred embodiments of the present invention, but the embodiments of the present invention are not limited to the above embodiments. Any changes, modifications, substitutions, combinations, or simplifications made without departing from the spirit and principle of the present invention shall be considered equivalent substitutions and shall be included within the protection scope of the present invention.

Claims

1. A frequency domain encryption method of a medical image, characterized by, The frequency domain encryption method includes the following steps: S1. Preprocessing medical images: The original medical image is transformed into a frequency domain image through folding real-complex transformation and frequency domain transformation; the process is as follows: S11, Transfer the original medical images The matrix is ​​obtained through folding complex transformation. Where N and M are the original medical image matrices, respectively. The number of rows and columns; S12, the matrix obtained by the above folding real complex conversion By fast Fourier transform to the frequency domain space, the generated matrix is ; S2. Generating a key using a chaotic system: A key is generated using an improved Logistic chaotic system. This key is then used to adjust and obfuscate the frequency domain image, resulting in an encrypted frequency domain image. The process is as follows: S21. Define the improved Logistic chaotic system as follows: , equation (1), , equation (2), In formulas (1) and (2), It is an adjustable parameter. For the iteration time step, Indicates the first The state of the Logistic chaotic system at each time step. Indicates the first The improved logistic chaotic system state at each time step, where, ,as well as , the first key Second Key Substitute them into formula (1) respectively, and let They are respectively and , They are respectively and , respectively obtained and Iterate separately Step, to obtain lengths respectively Two chaotic sequences and , and They represent the first Each time step is determined by the first key. Second Key The generated Logistic chaotic system state, then and Substitute them into formula (2) respectively, and let They are respectively and The first chaotic sequence is obtained. Second chaotic sequence , and They represent the first Each time step is determined by the first key. Second Key The generated improved logistic chaotic system state is used for subsequent adjustment and confusion operations, where It is used to construct the first key The first parameter, It is used to construct the first key The second parameter, Used to construct the second key The first parameter, It is used to construct the second key The second parameter; S22, Matrix Dimensional adjustment yields the matrix The first chaotic sequence The state of a chaotic system Sort the values ​​in ascending order to obtain the sorted index sequence. index sequence The value is the matrix. The new index of the corresponding element, matrix After using chaotic sequences The matrix regenerated after the permutation is ; S23, Regarding the matrix The matrix is ​​obtained using the inverse fast Fourier transform. Transform the frequency domain image to the spatial domain image using complex real transformations to convert the matrix. Convert medical images to their original size. ; S24, medical images Dimensional adjustment yields the matrix For the matrix Perform self-obfuscation, and convert the matrix Perform a bitwise XOR operation between each element and the next element to obtain the matrix. ,Right now: , ,in, This indicates a bitwise XOR operation. Representation matrix Line 1, page One element, Representation matrix Line 1, page The next element of the current element. Representation matrix Line 1, page One element; S25, Matrix With the second chaotic sequence Perform image obfuscation, and convert the matrix Each element in the second chaotic sequence Perform a bitwise XOR operation on the corresponding elements to obtain the matrix. ,Right now: , ,in, Representation matrix Line 1, page One element, Represents the second chaotic sequence The One element, Representation matrix Line 1, page Each element, finally the matrix Dimensional adjustment yields the matrix , This refers to the image obtained after encryption; S3. Transmission and decryption of encrypted images: Transmit the key and the encrypted image, and decrypt it at the receiving end to obtain the original image.

2. The frequency domain encryption method of medical images according to claim 1, characterized in that, The process of step S3 is as follows: S31, transmitting the encrypted image on a public channel and a first key and a second key to ensure its secure sharing between the sender and the recipient; S32, The receiver will receive the first key. Second Key Substitute into formula (1), let They are respectively and , They are respectively and , respectively obtained and Iterate separately Step, to obtain lengths respectively Two chaotic sequences and , and They represent the first Each time step is determined by the first key. Second Key The generated Logistic chaotic system state, then and Substitute them into formula (2) respectively, and let They are respectively and The first chaotic sequence is obtained. Second chaotic sequence , and They represent the first Each time step is determined by the first key. Second Key The generated improved Logistic chaotic system state; S33, Encrypt the image Dimensional adjustment yields the matrix ,matrix Each element and the second chaotic sequence Perform a bitwise XOR operation on the corresponding elements to obtain the matrix. ,Right now: , ,in, This indicates a bitwise XOR operation. Representation matrix Line 1, page One element, Represents the second chaotic sequence The One element, Representation matrix Line 1, page One element; S34, Matrix Each element and Perform a bitwise XOR operation on the next element at the corresponding position in the matrix to obtain the matrix. ,Right now: , ,in, Representation matrix Line 1, page One element, Representation matrix Line 1, page The next element of the current element. Representation matrix Line 1, page Elements, matrix Dimensional adjustment yields the matrix ; S35, matrix by complex real transform , matrix using inverse fast fourier transform ; S36, Matrix Dimensional adjustment yields the matrix The first chaotic sequence The state of a chaotic system Sort the values ​​in ascending order to obtain the sorted index sequence. , index sequence exist The value obtained based on the index is followed according to the first chaotic sequence. Arrange the corresponding indices to obtain the matrix of inverse permutations. , matrix ; S37, matrix by fast fourier transform , matrix obtained by folding real complex transform .

3. A frequency domain encryption device based on the frequency domain encryption method of medical images according to claim 1 or 2, characterized in that, The frequency domain encryption device includes: The preprocessing medical image module transforms the original medical image into a frequency domain image by using folded real-complex transformation and frequency domain transformation. The chaotic system generates a key module that uses an improved Logistic chaotic system to generate a key. This key is then used to adjust and obfuscate the frequency domain image, resulting in an encrypted frequency domain image. The encrypted image transmission and decryption module transmits the key and the encrypted image, and performs decryption on the receiving end to obtain the original image.

4. A computer device comprising a processor and a memory for storing a processor executable program, characterized in that, When the processor executes the program stored in the memory, it implements the frequency domain encryption method for medical images as described in claim 1 or 2.

5. A storage medium storing a program, characterized by comprising: When the program is executed by the processor, it implements the frequency domain encryption method for medical images as described in claim 1 or 2.