Skip to main content
Advertisement
Browse Subject Areas
?

Click through the PLOS taxonomy to find articles in your field.

For more information about PLOS Subject Areas, click here.

  • Loading metrics

Secure image communication based on two-layer dynamic feedback encryption and DWT information hiding

  • Jinlong Zhang,

    Roles Conceptualization, Methodology, Writing – original draft, Writing – review & editing

    Affiliation School of Information Technology and Management, Hunan University of Finance and Economics, Changsha, China

  • Heping Wen

    Roles Data curation, Formal analysis, Funding acquisition, Investigation, Project administration, Resources, Software, Supervision, Validation, Writing – original draft, Writing – review & editing

    wenheping@uestc.edu.cn

    Affiliations Zhongshan Institute, University of Electronic Science and Technology of China, Zhongshan, China, University of Electronic Science and Technology of China, Chengdu, China

Abstract

In response to the vulnerability of image encryption techniques to chosen plaintext attacks, this paper proposes a secure image communication scheme based on two-layer dynamic feedback encryption and discrete wavelet transform (DWT) information hiding. The proposed scheme employs a plaintext correlation and intermediate ciphertext feedback mechanism, and combines chaotic systems, bit-level permutation, bilateral diffusion, and dynamic confusion to ensure the security and confidentiality of transmitted images. Firstly, a dynamically chaotic encryption sequence associated with a secure plaintext hash value is generated and utilized for the first round of bit-level permutation, bilateral diffusion, and dynamic confusion, resulting in an intermediate ciphertext image. Similarly, the characteristic values of the intermediate ciphertext image are used to generate dynamically chaotic encryption sequences associated with them. These sequences are then employed for the second round of bit-level permutation, bilateral diffusion, and dynamic confusion to gain the final ciphertext image. The ciphertext image hidden by DWT also provides efficient encryption, higher level of security and robustness to attacks. This technology offers indiscernible secret data insertion, rendering it challenging for assailants to spot or extract concealed information. By combining the proposed dynamic closed-loop feedback secure image encryption scheme based on the 2D-SLMM chaotic system with DWT-based hiding, a comprehensive and robust image encryption approach can be achieved. According to the results of theoretical research and experimental simulation, our encryption scheme has dynamic encryption effect and reliable security performance. The scheme is highly sensitive to key and plaintext, and can effectively resist various common encryption attacks and maintain good robustness. Therefore, our proposed encryption algorithm is an ideal digital image privacy protection technology, which has a wide range of practical application prospects.

Introduction

In recent years, the advancements in computer communication and network technologies have facilitated the frequent, widespread, and rapid dissemination of various types of data and information through networks [13]. As a result, there has been a growing need for a secure transmission environment to accommodate the diverse forms of data exchanged [46]. Among these, images stand out as a highly visual and commonly shared form of data that typically contains a significant amount of private and sensitive information [79]. Therefore, the application of image encryption techniques has emerged as a valuable approach to safeguarding important data from potential leakage during transmission [1012]. By employing such techniques, the confidentiality and integrity of transmitted images can be effectively maintained [1315], ensuring the preservation of privacy and the mitigation of unauthorized access or malicious attacks [1618]. Numerous encryption techniques have been suggested, such as chaos theory [1921], frequency domain encryption [2224], bit-level coding [2527], DNA coding [2830], compressed sensing [3133], thumbnail-preserving encryption [34, 35] and so on [2, 36, 37]. Furthermore, the utilization of chaos in image encryption algorithms has gained immense popularity due to its inherent characteristics of unpredictability, pseudo-randomness, and sensitivity to initial values [38, 39]. These properties make chaos not only highly effective but also exceptionally suitable for ensuring the security and confidentiality of image data. By leveraging the unpredictable and sensitive nature of chaos, image encryption algorithms can provide robust protection against potential attacks or unauthorized access, making them a preferred choice in the field of image security.

Throughout the international status, many researchers have attained a range of significant theoretical [4042] and practical outcomes [4345] when employing chaotic system for image encryption. In 2022, Ref. [36] introduces an image encryption scheme that relies on a memristive chaotic system, combining cyclic shift and dynamic DNA-level diffusion. Simulation tests and analyses show that this scheme is highly secure and resistant to various attacks. In 2023, Ref. [46] presented a dynamic RNA-encoded color image encryption scheme that utilizes a chain feedback structure. The color image is encrypted using a chaotic sequence based on plaintext correlation for each color component and the color-coded image is obtained through RNA dynamic encoding and other operations. The results of the experiment demonstrate that the encryption algorithm exhibits outstanding encryption effectiveness and security performance in the face of different attacks [4749]. In the realm of chaotic image encryption research, the performance of chaotic systems and algorithms significantly influences the security and efficiency of cryptographic systems. It is particularly important and urgent to explore an image encryption algorithm that uses chaotic mapping constructs to resist various illegal attacks.

In this paper, a dynamic closed-loop feedback secure image encryption scheme based on 2D-SLMM chaotic system is suggested. The algorithm uses the chaotic encryption sequence associated with the plaintext image to perform the first round of encryption, and then uses the chaotic sequence associated with the intermediate ciphertext to perform the second round of encryption. A color image encryption scheme based on chaotic system, bit-level permutation, bilateral diffusion and dynamic confusion is proposed. The experimental findings demonstrate that the algorithm exhibits exceptional encryption effectiveness and efficient encryption performance. Furthermore, the suggested image encryption algorithm can effectively withstand various unauthorized attacks.

The main innovations and contributions of this paper can be outlined as follows.

  • Image encryption using DWT hiding method offers efficient encryption, a higher level of security, and robustness against attacks. DWT-based hiding allows for effective encryption by decomposing the image into frequency sub-bands, enabling secret data to be hidden in high-frequency sub-bands without compromising the visual quality in low-frequency sub-bands. This technique provides indistinguishable embedding of secret data, making it challenging for attackers to detect or extract the hidden information. Additionally, DWT-based hiding ensures the integrity of embedded secret data even when the encrypted image is subjected to common attacks like noise addition or compression. Overall, DWT hiding is an effective approach for securely protecting sensitive information in images while preserving their visual quality.
  • A majority of the current encryption methodologies rely on pixel-level encryption, which offers inadequate encryption granularity, thereby posing a security risk. However, this secure image encryption algorithm addresses these issues by utilizing bit-level permutation, bilateral diffusion, and dynamic confusion. It combines various encryption technologies, such as chaotic encryption, to enhance the security and robustness of the algorithm. As a result, it effectively improves the security, making it more resistant to attack and ensuring the confidentiality of the transmitted image.
  • Numerous existing encryption algorithms feature flawed structures. In the absence of plaintext correlation or ciphertext feedback, they are susceptible to known plaintext attacks or chosen plaintext attacks. This secure image encryption scheme uses a dynamic feedback mechanism to update the encryption key according to the encrypted data. This feedback mechanism enhances the security and resistance of attacks such as chosen plaintext attacks and chosen ciphertext attacks.
  • The existing low-dimensional chaotic systems have the risk of being estimated or identified due to their insufficient security. The color image encryption algorithm uses a 2D-SLMM chaotic system combining Logistic map and sine map to generate pseudo-random sequences for encryption. The 2D-SLMM system enhances the nonlinearity and randomness of the encryption process and ensures the confidentiality and integrity of the transmitted image.

The rest of this article is organized as follows. Section 1 briefly introduces the 2D-SLMM chaotic system and the related theory of dynamic image eigenvalue extraction. Section 2 presents the encryption algorithm designed in this paper. In section 3, the experimental results and simulation results are given. The last part is the conclusion of the paper.

Related theories

The used chaotic system

Chaotic systems find extensive application in image encryption algorithms due to their notable features, including high sensitivity to initial values, non-divergence, non-convergence, non-periodicity, and the consequent generation of highly random sequences. The chaotic system used in this paper is 2D Sine Logistic Modulation Map, which can be defined by the following Eq (1): (1) where a and b are control parameters. When a ∈ [0, 1] and b ∈ [0, 3], the system is in a chaotic state. The Logistic map and the Sine map are nonlinear transformations of simple structures, so their orbits are easy to predict. The 2D-SLMM used in this paper is derived from logical mapping and sinusoidal mapping. The integration of sine mapping with the parameter b is employed to modulate the output of the Logistic mapping, thereby enhancing its nonlinearity and randomness. Subsequently, these outcomes are extended from the one-dimensional domain to the two-dimensional domain to create the 2D-SLMM system.

NIST test.

The NIST 800-22 test suite serves as a comprehensive statistical toolbox comprising 16 distinct tests meticulously designed for the assessment of random binary sequences. These sequences can vary in length, making the suite an invaluable tool for evaluating the output of both hardware and software-based cryptographic random or pseudorandom number generators.

In this particular evaluation, all the sequences employed in encryption processes have successfully met the rigorous criteria set by the NIST 800-22 test suite. The meticulous examination of these sequences resulted in a series of partial test results, which are thoughtfully summarized in Table 1. This achievement signifies the robustness and reliability of the cryptographic random or pseudorandom number generators utilized in the encryption procedures.

It is worth noting that such comprehensive testing procedures are critical in the realm of cryptography, where the unpredictability and statistical quality of random sequences are of paramount importance. The successful passage of these tests not only provides confidence in the cryptographic system’s security but also assures users that the generated random or pseudorandom numbers adhere to the high standards set by NIST, reinforcing the integrity of the encryption process.

Discrete wavelet transform

The DWT is a powerful mathematical tool used in signal processing and image compression. It decomposes a signal or an image into different frequency components, allowing for both time and frequency domain analysis. DWT is widely applied in various fields, including image processing, data compression, and denoising.

The wavelet transform operates by iteratively refining the signal across multiple scales, achieving this through a series of scaling and translation operations. This progressive refinement process culminates in a remarkable outcome: a high-frequency time division and a low-frequency frequency division of the signal. This unique characteristic enables the wavelet transform to automatically adapt to the intricate demands of time-frequency signal analysis. The schematic diagram of the image wavelet decomposition is shown in Fig 1. The DWT can be represented by Eq (2) as: (2) where W(e, q) represents the transformed coefficient, with a and b denoting the scale and translation parameters, respectively. These parameters are utilized to control the shape and position of the wavelet function. x(n) corresponds to the discrete sample values of the input signal. ψe,q(n) represents the wavelet function, which is dependent on the scale parameter e and translation parameter q.

The proposed encryption algorithm

Compared with the traditional algorithm, this paper adopts the plaintext correlation mechanism, and uses the MD5 hash function to make the key dynamically update with the encrypted data. Using the key, the sequence is generated by 2D-SLMM chaos. The sequence is used to perform bit-level permutation, bilateral diffusion and dynamic confusion on the image. And innovatively use the ciphertext feedback method to perform two-round encryption, so that the algorithm not only has computational complexity, but also has the ability to resist the chosen plaintext attacks and the chosen ciphertext attacks. The comprehensive block diagram of the algorithm design is presented in Fig 2.

thumbnail
Fig 2. Block diagram of the overall design of the cryptosystem.

https://doi.org/10.1371/journal.pone.0300228.g002

Take the matrix as an example to encrypt a single channel, and the specific encryption process is shown in Fig 3.

Initial value perturbation

Taking the image P of size H × W × 3 as an example, the eigenvalue of the image is read, and the MD5 hash function is used to generate the hexadecimal scrambling values m(x), x ∈ [1, 32], and processed by Eq (3) to generate the key parameters. This is the specific equation definition: (3) where a and b are key parameters, x1(0) and x2(0) are initial values of chaotic sequence. Whereby, the initial values of a and b are set to 0.5 and 2, respectively, to ensure their variation remains within the parameter range.

Encryption process

Step 1: Sequence Generation and Preprocessing

The keys a, b, x1(0) and x2(0) generated based on the plaintext image are substituted into the 2D-SLMM chaotic system to generate three chaotic sequences S1, S2 and S3, and the sequences S2 and S3 are processed by Eq (4), so that they are suitable for the sequences required by the algorithm. The explicit equation definition is as follows: (4) where floor(⋅) is the downward integer function and mod(·) is the modulo operation function.

Step 2: Bit-level Permutation

The chaotic sequence S1 is used to scramble the bit row and column of the plaintext image. Firstly, the sequence S1 is sorted, and two sorting sequences RK and CK are obtained. Then, the image is expanded at the bit level, and the image size is adjusted to H × 8W. Finally, the sorted sequence is used to operate the layered image. The specific operation is processed by Eq (5). Here is the precise equation definition: (5) where sort(⋅) function indicates that each bit in the input sequence is sorted from low to high. w1, w2 represents the result of reordering the sequence. i, j denote the sort index, i = 1, 2, 3, …, H, j = 1, 2, 3, …, W. C1 is the image after bit-level permutation.

Step 3: Bilateral Diffusion

Using the pre-processed pseudo-random sequence S2, and setting the first pixel C2(0) = 0 of the ciphertext image, then calculating the sum of C2(0), S2(0), and C1(1), and performing modular operations on the sum to obtain the second cipher pixel C2(1). Where C1(1) is the first pixel to be encrypted in the permuted image, and S2(0) is the first pixel of the pseudo-random sequence S2. The encrypted pixel C2(1) can be obtained by iterative relationship. In order to make the plaintext information completely hidden in the password pixels, reverse diffusion is needed to obtain the image after bilateral diffusion. The specific formulas of the two diffusions can be represented by Eq (6). The equation’s specific definition is outlined below: (6) where mod(·) is the modulo operation function, C2 is the image after the forward diffusion of the modulus, and is the image after the reverse diffusion.

Step 4: Dynamic Confusion

Dynamic confusion allows each pixel to interact to achieve the avalanche effect. The pseudo-random sequence S3 is used to generate two key matrices Kd1 and Kd2, and then the diffusion path is established between the pixels and the key matrices Kd1 and Kd2 are added to the diffusion process. The ciphertext pixels diffuse along this path to other pixels to generate an intermediate ciphertext image C3. The confusion encryption generation equation of the first pixel value C3(1) of the image C3 after dynamic confusion is defined by Eq (7). The specific definition of the equation is given below: (7) where the operation symbol is defined as . Kd1 and Kd2 are the key matrices composed of diffusion encryption sequences. The variable sum represents the cumulative sum of all the pixels in the image C2, and this sum is then used in an iterative process to generate the ciphertext image C3. The specific formula is processed by Eq (8). The equation is defined in the following manner: (8)

Step 5: Two-round Encryption of Intermediate Ciphertext

In order to enhance the ability of the algorithm to resist the chosen ciphertext attack, this paper innovatively refers to the ciphertext feedback mechanism, and uses the intermediate ciphertext image C3 to generate the key through the MD5 hash function. Then the key is substituted into the 2D-SLMM chaotic system to generate a chaotic sequence. Finally, the sequence is used to perform bit-level permutation, bilateral diffusion and dynamic confusion on the intermediate ciphertext image C3 to obtain the final ciphertext image C4.

Embedding a mask image

To convert a random ciphertext image into a meaningful output image, a DWT is used in the proposed of the proposed encryption scheme. The masking of the new image onto the the ciphertext image according to the following steps:

  1. 1) Take a mask image having meaningful information of size 2M × 2N × 3.
  2. 2) Apply DWT to each color component of a mask image and extract four frequency sub-bands.
  3. 3) Now, split each pixel value of the pre-ciphertext image into its groups: (a) LSB-group and (b) MSB-group. For example, a pixel value having a grayscale value equal to 152 (Graydec = 152), its binary version will be Graybin = 10011000. The LSB and MSB group of the binary value will be G1 = 1001 and G2 = 1000, respectively.
  4. 4) Operate on each pixel until it reaches the position (M, N) for each color component. The LSB-group (LG) and MSB-group (MG) matrices are given in Eqs (9) and (10): (9) (10)
  5. 5) The extracted high-frequency sub-bands (HL and HH) will be replaced with the two binary groups (LG and MG).
  6. 6) After replacing the sub-bands, take the inverse DWT (IDWT) to restore the original mask image (). This image will be transmitted as a meaningful encrypted image. The block diagram of the proposed embedding process is displayed in Fig 4.

Decryption process

The decryption process is the inverse operation of encryption. Firstly, the sequence required for decryption is generated by the 2D-LSMM chaotic system. Then, the final ciphertext image is subjected to inverse dynamic confusion, inverse bilateral diffusion and inverse bit-level permutation to obtain the intermediate ciphertext image. Finally, after a round of decryption operation, the original image can be obtained. The specific decryption flow chart example is shown in the Fig 5.

Experimental results and analysis discussion

Experimental environment

We utilized a personal computer as the experimental platform, equipped with MATLAB R2023a experimental software. The PC is powered by an AMD Ryzen™ 7 CPU running at 3.2 GHz, with 32GB of memory and a 512GB hard disk. The operating system employed is Windows 10. Additionally, we selected USC-SIPI as the image data for the experiment.

Cryptographic attacks

In the realm of cryptography, the well-established Kerckhoffs’ principle asserts that the encryption algorithm of a secure cryptosystem should be openly known to attackers, with only the key remaining unknown [50]. The four commonly employed cryptanalysis methods, ranging from weak to strong, are as follows:

  • Ciphertext-only attack
    Assuming that the attacker has access to only some ciphertext, their objective is to deduce the plaintext or the encryption key by analyzing the statistical properties of the ciphertext.
  • Known-plaintext attack
    Assuming the attacker possesses partial plaintext and the corresponding ciphertext, their objective is to decipher or crack the associated encryption key and encryption algorithm.
  • Chosen-plaintext attack
    Assuming the attacker has temporary access to the encryption machine, they can select plaintext that facilitates deciphering, obtain the corresponding ciphertext, and then launch an attack against the target algorithm.
  • Chosen-ciphertext attack
    Assuming the attacker has temporary access to the decryption machine, they can select ciphertext that facilitates deciphering, obtain the corresponding plaintext, and then launch an attack against the target algorithm.

In the analysis of color image cryptosystems, chosen plaintext attacks and chosen ciphertext attacks are considered the most potent methods of cryptographic attack. The primary concept behind these attacks involves the careful selection of specific attack images, such as all-black or all-white images, followed by the application of algebraic analysis to deduce the original cryptosystem’s equivalent key. In this paper, for instance, we utilize the digital image sets depicted in Fig 6(a)–6(d) and 6(m)–6(p) to decipher the target algorithm. Utilizing a comparable attack strategy, we undertake a security assessment of our proposed image encryption algorithm.

thumbnail
Fig 6. Specific chosen plaintext images and their corresponding attack outcomes.

https://doi.org/10.1371/journal.pone.0300228.g006

Taking the chosen-plaintext attack as an example, we designate Fig 6(a)–6(d) as the plaintext attack images, with the corresponding intermediate and final password images presented in Fig 6(e)–6(h). As demonstrated in Fig 6(i)–6(l), their histogram characteristics exhibit a noise-like pattern, which differs significantly from Fig 6(a)–6(d). To ensure generality, we also select the specific plaintext Fig 6(m)–6(p), with its corresponding ciphertext images displayed in Fig 6(q)–6(t). Also, the histogram plots in Fig 6(u)–6(x), for these ciphertexts exhibit a noisy pattern and differ significantly from the original text. Consequently, this approach makes it challenging for attackers to carry out penetration attacks. Similarly, achieving selective ciphertext attacks is also difficult.

The main source of these challenges arises from the incorporation of the diffusion-permutation-diffusion structure and the plaintext correlation mechanism. Concurrently, the use of the diffusion-permutation-diffusion structure and the intermediate ciphertext correlation mechanism effectively bolsters the algorithm’s avalanche effect and security.

Robustness analysis

This section aims to experimentally examine the robustness of the decryption algorithm against noise interference and image cropping attacks, while providing a detailed analysis of the algorithm’s performance. This experiment involves introducing salt-and-pepper noise interference and image cropping attacks to encrypted ciphertext images, with the intention of simulating potential sources of interference in the decryption process. After subjecting the ciphertext to these attacks, the decryption process is initiated to assess whether the algorithm can effectively recover the compromised ciphertext images. Furthermore, the performance and stability of the algorithm in the face of noise interference and image cropping attacks will be evaluated.

Salt-and-pepper noise analysis.

In this experiment, an analysis of salt-and-pepper noise was conducted on the encrypted ciphertext images, with the objective of assessing the influence of varying intensities of salt-and-pepper noise on the decryption algorithm. This study explored three distinct levels of salt-and-pepper noise, namely 0.005, 0.01, and 0.03, to evaluate the performance of ciphertext recovery. The test results are depicted in Fig 7. The experimental findings indicate that the encryption algorithm exhibits excellent noise resistance.

thumbnail
Fig 7.

Salt and pepper noise test: (a) 0.005 noise; (b) 0.01 noise; (c) 0.015 noise.

https://doi.org/10.1371/journal.pone.0300228.g007

Cropping attack analysis.

In this experiment, different degrees of cropping were applied to the ciphertext images, followed by decryption and subsequent analysis of the cropped ciphertext images. The experimental results are presented in Fig 8. The research findings demonstrate that despite the information cropping undergone by the ciphertext images prior to decryption, the content of the images remains clear and recognizable. This discovery highlights the excellent robustness of the proposed decryption algorithm when faced with information cropping attacks, successfully restoring the ciphertext images.

thumbnail
Fig 8.

Cropping attack test: (a) Cropping of 32 × 32; (b) Cropping of 32 × 64; (c) Cropping of 64 × 64.

https://doi.org/10.1371/journal.pone.0300228.g008

Experimental results and analysis

Statistics histogram.

The histogram serves as a visual representation of the grayscale levels and their respective frequencies in an image. Typically, the histogram of a plaintext image showcases specific statistical patterns, whereas the histogram of an encrypted image portrays a distribution resembling random noise. Hence, a superior encryption algorithm can effectively transform the image into a distribution resembling noise, effectively concealing the essential information within the image. In Fig 9, we present the 3-D visual histograms of both plaintext and ciphertext channels. It is evident that the encrypted image effectively conceals the vital information present in the plaintext image, diminishing the likelihood of attackers decrypting the ciphertext image through statistical analysis. This ensures that adversaries are practically unable to reconstruct the original image based on the statistical characteristics of the encrypted image, thus preventing them from obtaining any valuable information.

thumbnail
Fig 9.

3-D histogram comparison: (a) Plaintext image and ciphertext image; (b) R channel; (c) G channel; (d) B channel.

https://doi.org/10.1371/journal.pone.0300228.g009

The coefficient of adjacent pixels.

A high degree of correlation among neighboring pixels suggests that the plaintext image is vulnerable to statistical analysis. Therefore, it is essential to reduce the correlation between adjacent pixels. Exceptional encryption algorithms can effectively lower the correlation among neighboring pixels. For our analysis, we randomly selected 3000 pixels from both the plaintext and ciphertext images and computed the horizontal, vertical, diagonal, and anti-diagonal correlations between adjacent pixels using Eq (11). The formula is defined as follows: (11) where xi and yi constitute the i-th pair of horizontal/vertical/diagonal/anti-diagonal neighboring pixels, N is the total number of horizontal/vertical/diagonal/anti-diagonal neighboring pixels, cov(x, y) is the covariance between pixel values x and y, D(x) and D(y) are the pixel value x and pixel value y mean-square error, E(x) and E(y) are the expected values of pixel value x and pixel value y, respectively. rxy is the correlation coefficient of pixel values x and y. Fig 10 illustrates the correlations between pixels in different directions for the “Lena” image before and after encryption. It is apparent from the experimental data presented in Table 2 that the correlation coefficients for regular images are close to 1, whereas the correlation coefficients for encrypted images are close to 0. This underscores that the approach proposed in this paper exhibits robust resistance to statistical attacks.

thumbnail
Fig 10.

Comparing pixel correlations in different directions before and after encryption: (a) R channel; (b) G channel; (c) B channel.

https://doi.org/10.1371/journal.pone.0300228.g010

thumbnail
Table 2. The comparison results of the correlation coefficients of adjacent pixels.

https://doi.org/10.1371/journal.pone.0300228.t002

Differential statistical analysis.

Differential attack is a common type of plaintext attack in which the attacker initially introduces minor alterations to a plaintext image and subsequently encrypts both variations of the plaintext image individually. Ultimately, the attacker gains information by comparing these two encrypted images. Normalized Pixel Change Rate (NPCR) and Unified Average Changing Intensity (UACI) are key metrics for evaluating the effectiveness of a differential attack. Their calculation formulas are defined as Eq (12), as follows: (12) where H × W is the size of the image, and v1,v2 are the ciphertext images before and after changing one pixel of the plaintext image, respectively. D can be defined by Eq (13): (13) Tables 3 and 4 shows the results of the algorithm calculated according to Eq (12). Fig 11 illustrates that even a minor disparity in the plaintext image when using the encryption scheme proposed in this paper can yield outcomes that deviate significantly from the ideal. Consequently, it can be inferred that the encryption scheme presented in this paper exhibits strong resistance to differential attacks.

thumbnail
Fig 11.

Test values of plaintext and ciphertext: (a) NPCR test values; (b) UACI test values.

https://doi.org/10.1371/journal.pone.0300228.g011

Information entropy

The entropy value is used to assess the randomness and disorderliness of an information source, and when the entropy value approaches 8, it indicates a more random distribution of pixel values. We conducted a comparison of the information entropy of images before and after encryption, and the experimental results are presented in Table 5. It is evident from Table 5 that the experimental results are approximately close to 8, indicating that the proposed algorithm possesses favorable information entropy characteristics. The calculation method for the information entropy H(m) of the information source m is as follows: (14) where L is the total number of symbols m(i) ∈ m and p(mi) denotes the probability of the symbols.

Key space analysis

The size of the key space plays a crucial role in determining the encryption algorithm’s resilience against brute-force attacks. It is determined by the length of the secure key and is a critical feature in determining the strength of a cryptographic system. The image encryption algorithm designed in this paper uses a 2D-SLMM chaotic system, whose key space can be represented as S ∈ {x1, x2, a, b, MD5}, where x1, x2, a, b are the key parameter with the precision of 10−16 and MD5 is the hash value introduced to enhance the key space, which can generate a 128bit hash value. Upon calculation, the key space size of this encryption scheme is approximately 104×16 × 2128 ≈ 2340, surpassing the 2100 requirement of the cryptographic system. This highlights that the algorithm presented in this paper can effectively withstand aggressive attacks. The key space comparison is detailed in Table 6.

Sensitivity analysis

In this section, we evaluate the algorithm’s performance using two criteria: key sensitivity and plaintext sensitivity. A robust algorithm should demonstrate a high degree of sensitivity, meaning that even slight modifications in either the encryption key or the plaintext image data during the encryption or decryption process can significantly influence the resulting encryption results.

Analysis of sensitivity to the key.

Key sensitivity is assessed by encrypting the same image using two slightly different keys and analyzing the resulting ciphertexts. In this section, we encrypt the plaintext image using the original key, referred to as key, and a perturbed key, denoted as key + 10−14. Subsequently, we assess the disparity between the resulting encrypted ciphertexts by computing the NPCR and UACI, as defined in Eq (12). The results are presented in Table 7 and Fig 12. It is evident that introducing a slight perturbation to the key leads to a significant difference between the two ciphertext images, with their NPCR and UACI values closely approaching the ideal values of 99.6094% and 33.4635%.

thumbnail
Fig 12.

Key sensitivity test values: (a) NPCR test values; (b) UACI test values.

https://doi.org/10.1371/journal.pone.0300228.g012

thumbnail
Table 7. Key sensitivity test of NPCR and UACI.

https://doi.org/10.1371/journal.pone.0300228.t007

Analysis of plaintext sensitivity.

Plaintext sensitivity gauges the degree of alteration in the associated ciphertext when the pixels of the plaintext are modified. When an algorithm lacks plaintext sensitivity, it becomes susceptible to decryption attempts that analyze discrepancies between plaintext and ciphertext pairs. Therefore, the algorithm’s plaintext sensitivity is vital for its robustness against plaintext attacks. In this section, we assess the algorithm’s sensitivity to alterations in the plaintext image by incrementing the pixel values at specific coordinates by 1: (H/3, W/3), (H/3, 2 × W/3), (2 × H/3, W/3), and (2 × H/3, 2 × W/3). We then compare the resulting NPCR and UACI values. The outcomes are presented in Table 8 and Fig 13. These results illustrate that the ciphertext image has undergone significant alterations, rendering it impractical for an attacker to undermine the algorithm through ciphertext comparison. Hence, the algorithm proposed in this paper demonstrates substantial resistance against plaintext attacks.

thumbnail
Fig 13.

Plaintext sensitivity test values: (a) NPCR test values; (b) UACI test values.

https://doi.org/10.1371/journal.pone.0300228.g013

thumbnail
Table 8. The plaintext sensitivity test of NPCR and UACI.

https://doi.org/10.1371/journal.pone.0300228.t008

Running efficiency

Operational efficiency stands as a pivotal marker for evaluating the feasibility and practicality of compression encryption algorithms. Algorithms with shorter runtimes are typically preferred. Within this experimental environment, we processed images sized at 256 × 256 and 512 × 512 individually, measuring the time consumption of two primary steps, bit-level permutation and bilateral diffusion. For comparative purposes, we referenced the operational efficiency from the literature, as demonstrated in Table 9. Compared to other algorithms, our findings indicate a leading speed in bit permutation and bidirectional diffusion, underscoring the effectiveness and satisfaction of our algorithm in practical terms. In addition, we have also conducted a comparative measurement of the algorithm’s runtime against other studies. Table 10 shows that our algorithm possesses good encryption efficiency.

thumbnail
Table 9. Comparison results with some algorithms.

https://doi.org/10.1371/journal.pone.0300228.t009

Compression performance analysis

In the field of image processing, Peak Signal-to-Noise Ratio (PSNR) and Structural Similarity Index (SSIM) are two important metrics widely used for evaluating the quality of image encryption. PSNR involves the concept of Mean Squared Error (MSE), and its calculation is based on the inverse proportion of MSE to assess image quality. Specifically, MSE measures the average difference in pixel intensity between two images, while PSNR evaluates the ratio of this difference to the strength of the image signal, thereby providing a quantitative indicator of image quality loss. The MSE and PSNR are defined by: (15) where H and W are the height and width of the plaintext image P and the ciphertext image C, while Q represents the pixel level of the image. SSIM is a measure of the similarity between two images, defined as (16) where μp and μc represent the mean value of the plaintext image P and the ciphertext image C, respectively, σp and σc denote the standard deviation of the images P and C, respectively, and L represents the dynamic range of the pixel value. The values of PSNR and SSIM are calculated using the formulas mentioned above, and the specific experimental data are shown in Table 11. Compared with other algorithms, as shown in Table 12, the encryption effect of this scheme shows better performance.

thumbnail
Table 12. Comparison of the average PSNR of different compression algorithms.

https://doi.org/10.1371/journal.pone.0300228.t012

Conclusion

In this paper, a secure image communication scheme based on two-layer dynamic feedback encryption and discrete wavelet transform information hiding is proposed. The scheme introduces a dynamic feedback mechanism to ensure the security and confidentiality of the transmitted image, and implements it with the help of 2D-SLMM chaotic system combined with a variety of encryption technologies. By using various evaluation indicators to evaluate the algorithm, the experimental results fully prove the effectiveness of the scheme in resisting attacks and ensuring the confidentiality of transmitted images. DWT hidden cipher image also provides efficient encryption, higher levels of security and robustness to attacks. These encryption methods provide the scheme with excellent robust protection against various attacks and ensure the confidentiality of transmitted images. From the experimental results, the secure image encryption scheme proposed in this paper provides good encryption results and will provide a reliable and innovative solution for securing transmitted images. Meanwhile, in the future, we will focus on the performance, security and scalability of the algorithm in practical applications, and seek further improvement and optimisation.

References

  1. 1. Lin Z, Yu S, Feng X, Lü J. Cryptanalysis of a Chaotic Stream Cipher and Its Improved Scheme. International Journal of Bifurcation and Chaos. 2018;28(07):1850086.
  2. 2. Feng W, Zhao X, Zhang J, Qin Z, Zhang J, He Y. Image Encryption Algorithm Based on Plane-Level Image Filtering and Discrete Logarithmic Transform. Mathematics. 2022;10(15):2751.
  3. 3. Wen H, Lin Y, Xie Z, Liu T. Chaos-based block permutation and dynamic sequence multiplexing for video encryption. Scientific Reports. 2023;13(1):14721. pmid:37679414
  4. 4. Kocak O, Erkan U, Toktas A, Gao S. PSO-based image encryption scheme using modular integrated logistic exponential map. Expert Systems with Applications. 2024;237:121452.
  5. 5. Feng W, Qin Z, Zhang J, Ahmad M. Cryptanalysis and Improvement of the Image Encryption Scheme Based on Feistel Network and Dynamic DNA Encoding. IEEE Access. 2021;9:145459–145470.
  6. 6. Toktas A, Erkan U, Gao S, Pak C. A robust bit-level image encryption based on Bessel map. Applied Mathematics and Computation. 2024;462:128340.
  7. 7. Erkan U, Toktas A, Memiş S, Lai Q, Hu G. An image encryption method based on multi-space confusion using hyperchaotic 2D Vincent map derived from optimization benchmark function. Nonlinear Dynamics;.
  8. 8. Zhou S, Wang X, Zhang Y. Novel image encryption scheme based on chaotic signals with finite-precision error. Information Sciences. 2023;621:782–798.
  9. 9. Zhou S, Qiu Y, Wang X, Zhang Y. Novel image cryptosystem based on new 2D hyperchaotic map and dynamical chaotic S-box. Nonlinear Dynamics. 2023;111(10):9571–9589.
  10. 10. Erkan U, Toktas A, Lai Q. 2D hyperchaotic system based on Schaffer function for image encryption. Expert Systems with Applications. 2023;213:119076.
  11. 11. Wen H, Xie Z, Wu Z, Lin Y, Feng W. Exploring the future application of UAVs: Face image privacy protection scheme based on chaos and DNA cryptography. Journal of King Saud University—Computer and Information Sciences. 2024;36(1):101871.
  12. 12. Liu S, Li C, Hu Q. Cryptanalyzing Two Image Encryption Algorithms Based on a First-Order Time-Delay System. IEEE MultiMedia. 2022;29(1):74–84.
  13. 13. Wen H, Lin Y. Cryptanalyzing an image cipher using multiple chaos and DNA operations. Journal of King Saud University—Computer and Information Sciences. 2023;35(7):101612.
  14. 14. Wen H, Chen R, Yang J, Zheng T, Wu J, Lin W, et al. Security analysis of a color image encryption based on bit-level and chaotic map. Multimedia Tools and Applications. 2023;.
  15. 15. Wen H, Lin Y. Cryptanalysis of an image encryption algorithm using quantum chaotic map and DNA coding. Expert Systems with Applications. 2023; p. 121514.
  16. 16. Lu X, Xie EY, Li C. Periodicity Analysis of Logistic Map over Ring Z3n. International Journal of Bifurcation and Chaos. 2023;33(5):art. no. 2350063.
  17. 17. Ma Y, Li C, Ou B. Cryptanalysis of an Image Block Encryption Algorithm Based on Chaotic Maps. Journal of Information Security and Applications. 2020;54:art. no. 102566.
  18. 18. Chen L, Li C, Li C. Security measurement of a medical communication scheme based on chaos and DNA coding. Journal of Visual Communication and Image Representation. 2022;83:103424.
  19. 19. Wen H, Lin Y, Kang S, Zhang X, Zou K. Secure image encryption algorithm using chaos-based block permutation and weighted bit planes chain diffusion. iScience. 2024;27(1):108610. pmid:38205238
  20. 20. Cao C, Cen Z, Feng X, Wang Z, Zhu Y. Straightforward Guess and Determine Analysis Based on Genetic Algorithm. Journal of Systems Science and Complexity. 2022;35(5):1988–2003.
  21. 21. Bao B, Wang Z, Hua Z, Chen M, Bao H. Regime transition and multi-scroll hyperchaos in a discrete neuron model. Nonlinear Dynamics. 2023;111(14):13499–13512.
  22. 22. Wen H, Huang Y, Lin Y. High-quality color image compression-encryption using chaos and block permutation. Journal of King Saud University—Computer and Information Sciences. 2023;35(8):101660.
  23. 23. Luo Y, Zhang C, Wang X, Liang X, Qiu K. Robust Key Update With Controllable Accuracy Using Support Vector Machine for Secure OFDMA-PON. Journal of Lightwave Technology. 2023;41(14):4663–4671.
  24. 24. Liang X, Zhang C, Luo Y, Wang X, Qiu K. Secure Encryption and Key Management for OFDM-PON Based on Chaotic Hilbert Motion. Journal of Lightwave Technology. 2023;41(6):1619–1625.
  25. 25. Lai Q, Zhang H, Kuate PDK, Xu G, Zhao XW. Analysis and implementation of no-equilibrium chaotic system with application in image encryption. Applied Intelligence. 2022;52(10):11448–11471.
  26. 26. Tang Z, Chai X, Lu Y, Wang B, Tan Y. An end-to-end screen shooting resilient blind watermarking scheme for medical images. Journal of Information Security and Applications. 2023;76:103547.
  27. 27. Jiang N, Zhao A, Liu S, Zhang Y, Peng J, Qiu K. Injection-locking chaos synchronization and communication in closed-loop semiconductor lasers subject to phase-conjugate feedback. Optics Express. 2020;28(7):9477. pmid:32225554
  28. 28. Chen X, Mou J, Cao Y, Yan H, Jahanshahi H. A chaotic color image encryption scheme based on improved Arnold scrambling and dynamic DNA encoding. Multimedia Tools and Applications. 2023;.
  29. 29. Lin Y, Xie Z, Chen T, Cheng X, Wen H. Image privacy protection scheme based on high-quality reconstruction DCT compression and nonlinear dynamics. Expert Systems with Applications. 2024; p. 124891.
  30. 30. Wen H, Liu Z, Lai H, Zhang C, Liu L, Yang J, et al. Secure DNA-Coding Image Optical Communication Using Non-Degenerate Hyperchaos and Dynamic Secret-Key. Mathematics. 2022.
  31. 31. Chai X, Fu J, Gan Z, Lu Y, Zhang Y, Han D. Exploiting Semi-Tensor Product Compressed Sensing and Hybrid Cloud for Secure Medical Image Transmission. IEEE Internet of Things Journal. 2023;10(8):7380–7392.
  32. 32. Ye G, Liu M, Yap WS, Goi BM. Reversible image hiding algorithm based on compressive sensing and deep learning. Nonlinear Dynamics. 2023;111(14):13535–13560.
  33. 33. Li C, Shen X, Liu S. Cryptanalyzing an Image Encryption Algorithm Underpinned by 2D Lag-Complex Logistic Map. IEEE MultiMedia. 2024;31(1).
  34. 34. Chai X, Wang Y, Chen X, Gan Z, Zhang Y. TPE-GAN: Thumbnail Preserving Encryption Based on GAN With Key. IEEE Signal Processing Letters. 2022;29:972–976.
  35. 35. Zhang Y, Zhou W, Zhao R, Zhang X, Cao X. F-TPE: Flexible Thumbnail-Preserving Encryption Based on Multi-Pixel Sum-Preserving Encryption. IEEE Transactions on Multimedia. 2022; p. 1–15.
  36. 36. Qian K, Feng W, Qin Z, Zhang J, Luo X, Zhu Z. A novel image encryption scheme based on memristive chaotic system and combining bidirectional bit-level cyclic shift and dynamic DNA-level diffusion. Frontiers in Physics. 2022;10.
  37. 37. Feng W, Wang Q, Liu H, Ren Y, Zhang J, Zhang S, et al. Exploiting Newly Designed Fractional-Order 3D Lorenz Chaotic System and 2D Discrete Polynomial Hyper-Chaotic Map for High-Performance Multi-Image Encryption. Fractal and Fractional. 2023;7(12):887.
  38. 38. Qian K, Xiao Y, Wei Y, Liu D, Wang Q, Feng W. A Robust Memristor-Enhanced Polynomial Hyper-Chaotic Map and Its Multi-Channel Image Encryption Application. Micromachines. 2023;14(11):2090. pmid:38004947
  39. 39. Li H, Yu S, Feng W, Chen Y, Zhang J, Qin Z, et al. Exploiting Dynamic Vector-Level Operations and a 2D-Enhanced Logistic Modular Map for Efficient Chaotic Image Encryption. Entropy. 2023;25(8):1147. pmid:37628177
  40. 40. Wen H, Wu J, Ma L, Liu Z, Lin Y, Zhou L, et al. Secure Optical Image Communication Using Double Random Transformation and Memristive Chaos. IEEE Photonics Journal. 2023;15(1):1–11.
  41. 41. Ahmad M, Alkanhel R, El-Shafai W, Algarni AD, El-Samie FEA, Soliman NF. Multi-Objective Evolution of Strong S-Boxes Using Non-Dominated Sorting Genetic Algorithm-II and Chaos for Secure Telemedicine. IEEE Access. 2022;10:112757–112775.
  42. 42. Wen H, Chen Z, Zheng J, Huang Y, Li S, Ma L, et al. Design and Embedded Implementation of Secure Image Encryption Scheme Using DWT and 2D-LASM. Entropy. 2022;24(10):1332. pmid:37420352
  43. 43. Teng L, Wang X, Yang F, Xian Y. Color image encryption based on cross 2D hyperchaotic map using combined cycle shift scrambling and selecting diffusion. Nonlinear Dynamics. 2021;105(2):1859–1876.
  44. 44. Lai Q, Hu G, Erkan U, Toktas A. A novel pixel-split image encryption scheme based on 2D Salomon map. Expert Systems with Applications. 2023;213:118845.
  45. 45. Wu T, Zeng W, Liu Y, Song S, Zhao L, Chen C, et al. Secure turbulence-resistant coherent free-space optical communications via chaotic region-optimized probabilistic constellation shaping. Opt Lett. 2023;48(3):684–687. pmid:36723563
  46. 46. Wen H, Kang S, Wu Z, Lin Y, Huang Y. Dynamic RNA Coding Color Image Cipher Based on Chain Feedback Structure. Mathematics. 2023;11(14):3133.
  47. 47. Wen H, Lin Y, Feng Z. Cryptanalyzing a bit-level image encryption algorithm based on chaotic maps. Engineering Science and Technology, an International Journal. 2024;51:101634.
  48. 48. Wen H, Lin Y, Yang L, Chen R. Cryptanalysis of an image encryption scheme using variant Hill cipher and chaos. Expert Systems with Applications. 2024; p. 123748.
  49. 49. Wen H, Feng Z, Bai C, Lin Y, Zhang X, Feng W. Frequency-domain image encryption based on IWT and 3D S-box. Physica Scripta. 2024;.
  50. 50. Kerckhoffs A. La cryptographie militaire. J Sci Militaires. 1883;9(4):5–38.
  51. 51. Wang X, Zhang H, Bao X. Color image encryption scheme using CML and DNA sequence operations. Biosystems. 2016;144:18–26. pmid:27026385
  52. 52. Li Q, Chen L. An image encryption algorithm based on 6-dimensional hyper chaotic system and DNA encoding. Multimedia Tools and Applications. 2023; p. 1–18.
  53. 53. Ye G, Pan C, Dong Y, Shi Y, Huang X. Image encryption and hiding algorithm based on compressive sensing and random numbers insertion. Signal Processing. 2020;172:107563.
  54. 54. Chai X, Bi J, Gan Z, Liu X, Zhang Y, Chen Y. Color image compression and encryption scheme based on compressive sensing and double random encryption strategy. Signal Processing. 2020;176:107684.
  55. 55. Mansouri A, Wang X. A novel block-based image encryption scheme using a new Sine powered chaotic map generator. Multimedia Tools and Applications. 2021;80(14):21955–21978.
  56. 56. Shafique A, Ahmed F. Image Encryption Using Dynamic S-Box Substitution in the Wavelet Domain. Wirel Pers Commun. 2020;115(3):2243–2268.
  57. 57. Wang X, Yang J, Guan N. High-sensitivity image encryption algorithm with random cross diffusion based on dynamically random coupled map lattice model. Chaos, Solitons & Fractals. 2021;143:110582.
  58. 58. Zhou Y, Li C, Li W, Li H, Feng W, Qian K. Image encryption algorithm with circle index table scrambling and partition diffusion. Nonlinear Dynamics. 2021;103(2):2043–2061.
  59. 59. Luo Y, Ouyang X, Liu J, Cao L. An Image Encryption Method Based on Elliptic Curve Elgamal Encryption and Chaotic Systems. IEEE Access. 2019.
  60. 60. Guesmi R, Farah MAB. A new efficient medical image cipher based on hybrid chaotic map and DNA code. Multimedia Tools and Applications. 2020;80(2):1925–1944.
  61. 61. Xiao M, Tan R, Ye H, Gong L, Zhu Z. Double-Color-Image Compression-Encryption Algorithm Based on Quaternion Multiple Parameter DFrAT and Feature Fusion with Preferable Restoration Quality. Entropy. 2022;24(7):941. pmid:35885163