1. Introduction
With the increasing transmission of multimedia information over the internet, it has become essential to protect against unauthorized access. Digital images are a widely used data format for storing more vivid information. Image encryption mainly involves converting a meaningful image into a meaningless one through two fundamental techniques, namely, scrambling and diffusion, thereby rendering it inaccessible to unauthorized individuals. Scrambling involves the modification of the positioning or ordering of pixels within an image. On the other hand, diffusion modifies pixel values to achieve a randomized effect. These techniques can be applied independently or combined to create more complex encryption schemes.
Numerous image encryption algorithms have been put forward recently, with chaos-based ones garnering significant attention in this field due to their distinctive properties [
1,
2,
3]. Chaotic systems are nonlinear dynamical systems that exhibit complex and unpredictable behavior, making them suitable for cryptographic systems due to their ergodicity, sensitivity to initial conditions, non-periodicity and non-convergence. However, attackers can exploit regions of regularity or low chaos within these systems to break encryption schemes, particularly if they possess knowledge of the plaintext used in encryption or can select it. Therefore, chaotic systems are frequently employed in conjunction with other technologies to enhance their level of security, such as DNA [
4,
5,
6,
7], genetic operations [
8,
9,
10], compressive sensing [
11,
12,
13], fractal sorting matrix [
14], bit matrix [
15], combinatorial design structures [
16,
17,
18,
19,
20,
21,
22,
23], and others.
Most concepts in combinational design theory are directly defined on finite sets, which can compensate for the limitations of applying chaos theory to cryptography. To date, many combinational design structures have been implemented in the field of cryptography, including Latin squares [
16,
17,
18], orthogonal arrays [
19], Latin cubes [
20,
21,
22], Hadamard matrices [
24], etc. Latin squares are commonly utilized in image encryption thanks to their distinctive properties of dispersion, uniformity, and abundance. These algorithms initially employ Latin squares to generate 1D maps for scrambling, then perform XOR operations directly on 2D images. However, they suffer from the drawbacks of low scrambling efficiency and susceptibility to specific attacks. The utilization of orthogonal Latin squares enables the direct construction of a 2D map, resulting in an enhanced scrambling efficiency [
25]. Orthogonal arrays can be utilized to select appropriate rows for generating a pair of orthogonal Latin squares, albeit at the cost of requiring a relatively large storage space. Latin cubes are particularly useful in encryption, especially when dealing with more complex scenarios. Therefore, here we adopt another typical combinatorial design structure: the difference matrix. With its discreteness and approximate uniformity, it requires only a small storage space, making it an ideal candidate to serve as a pseudo-random sequence. Moreover, each difference matrix possesses a crucial property in that selecting any nonzero row generates a Latin square, while choosing any two non-zero rows produces a pair of orthogonal Latin squares. Therefore, a difference matrix can provide multiple pseudo-random sequences and a variety of scrambling methods, making it highly suitable for image encryption.
In recent years, the utilization of genetic algorithms (GA) in encryption technology has emerged as a prominent research frontier within the realm of image encryption. GAs are a type of optimization algorithm that operate on the principle of natural selection and evolution. Advantages such as simplicity, robustness, intrinsic parallelism, and self-adaptation have made them a popular choice in various fields, including cryptography, combinatorial optimization, and more. In 2012, Abdullah et al. put forward a hybrid model combining a GA and a chaotic function [
8]. It employed the correlation coefficient as the fitness function. This approach has weaknesses against certain attacks, however, primarily due to its reliance on plaintext images and the utilization of identical chaotic sequences to encrypt different images. Thus far, various enhanced genetic algorithms have emerged for image encryption by leveraging the optimization capabilities of GAs to generate high-quality ciphertext images [
26,
27,
28,
29], optimizing chaotic sequences [
30], and employing genetic operations directly for encryption [
10,
31,
32]. Additionally, some approaches have integrated novel technologies along with GAs to improve the security and efficiency of the resulting cryptosystem [
33,
34,
35]. In 2018, Pashakolaee et al. put forward a novel image encryption algorithm (IEA) named Hyper-chaotic Feeded GA (HFGA) [
26]. This algorithm mainly uses a GA in combination with a hyperchaotic system to optimize cryptographic images and provide a secure decryption mechanism for authorized recipients. In the same year, Mozaffari proposed a parallel IEA on the basis of bit-plane decomposition [
27]. In this approach, a GA was utilized to perform permutation and replacement steps through crossover and mutation operations. The resulting algorithm enables parallel processing of multi-bit-plane encryption, thereby enhancing the encryption speed and rendering it suitable for real-time applications. In 2019, Premkumar et al. put forward a secure composite 3D chaos-based image encryption algorithm utilizing a GA [
31]. The algorithm was implemented by arithmetic crossover, multi-point crossover, and permutation of combinatorial mutation operators. In 2021, Zhang put forward a new IEA integrating genetic mutation and MLNCML [
34]. The proposed encryption scheme employs DNA mutation and crossover operations by chaotic sequences. By integrating chaotic systems into the DNA operations, the scheme can effectively counter man-in-the-middle attacks, which are prevalent in traditional DNA addition and subtraction operations. In 2022, Qobbi proposed a novel encryption scheme combining a 2D logical mapping and genetic manipulations [
10]. The algorithm’s security was guaranteed through the use of CBC with genetic manipulations. In 2022, Liang proposed an image cryptosystem combining the Fibonacci-Q matrix and GA [
29]. The four-layer encryption framework employed to bolster the encryption security of this cryptosystem consists of diffusion, scrambling, diffusion, and optimization. In 2023, Bhowmik put forward an IEA employing a modified chaotic system integrated with DE and GA [
30]. The GA was used to generate a unique key-string that was employed for the transposition process in the confusion stage. In summary, GAs represent a meta-heuristic optimization technique that can be applied to enhance the behavior of chaotic sequences or to improve the stochastic properties of ciphertext images during the encryption process. By introducing a GA into image encryption, it is possible to achieve a highly secure and efficient method for encrypting images.
To realize the advantageous properties of a difference matrix together with the optimization capabilities of a GA, we propose an efficient image cryptosystem utilizing both techniques. Difference matrices can serve as generators for Latin squares or pseudo-random sequences, while GA operations of crossover and mutation are employed to generate new individuals. This is followed by local optimization to achieve overall image optimization. The proposed cryptosystem first generates a difference matrix, which is then utilized for initial encryption. Subsequently, genetic operations are employed to cross and mutate the encrypted image blocks, followed by multiple rounds of optimal preservation to enhance the randomness of the final ciphertext image. The novel contributions of this research are summarized below.
We introduce a novel combinatorial structure for image encryption consisting of a difference matrix. It can be utilized to generate Latin squares or serve as a pseudo-random sequence while maintaining simplicity and requiring only a small amount of memory.
The above structure is used to generate a novel row-scrambling method using a pair of orthogonal Latin squares.
We define the formula for a single-point mutation. New individuals are then generated through crossover and mutation operations. Multiple rounds of local optimization using the optimal preservation strategy are used to further enhance the output.
Our simulation results demonstrate the effectiveness of this cryptosystem in both encryption and decryption processes, exhibiting both robustness and practicality against conventional attacks.
The remaining sections of this paper are organized as follows:
Section 2 presents a concise overview of the definitions for the difference matrix and the GA;
Section 3 is dedicated to presenting the detailed processes for encryption and decryption; our simulation results and security analyses are presented in
Section 4; finally,
Section 5 serves to summarize this article.
3. The Proposed Cryptosystem
We now introduce several symbols that are utilized in the rest of this paper. The symbol
n represents a prime power,
Q denotes an
grayscale image,
C signifies the corresponding ciphertext image, and
refers to the initial encryption key. This cryptosystem is comprised of the following three parts. In Algorithm I, a difference matrix
M defined on a finite field is generated using
. Algorithm II is utilized to perform the initial encryption, which consists of three layers: large-scale mutation, scrambling, and diffusion. This results in the formation of the initial encrypted image
. In Algorithm III, both crossover and mutation operations are applied block-by-block to
, and the final ciphertext image
C is obtained over multiple iterations through the optimal preservation strategy. The encryption diagram of this cryptosystem is shown in
Figure 1.
3.1. Generation of a Difference Matrix M
We generate a difference matrix M on a finite field. Initially, is utilized to produce an n-length chaotic sequence, which is employed to construct a finite field of order n. Subsequently, the difference matrix M is generated.
Algorithm I: The generation of M
Input: .
Output: An -difference matrix M.
Step 1: Generate a logistic sequence of length
using (
1) with system parameter
and initial value
. The sequence obtained by excluding the initial 1000 values is denoted as
. Use the function
to sort
X in ascending order and obtain a new sequence
, and corresponding index subscript vector
.
Step 2: Redefine the addition and multiplication operations on
, then construct a finite field
[
23]. generate an
-difference matrix
M with
.
3.2. Generation of the Initial Ciphertext Image
This section describes the generation of the initial ciphertext image . First, a new encryption key is generated by adopting the information of the plaintext image. Then, a new n-length chaotic sequence is generated to construct the second finite field according to the method of generating a finite field from a sequence, as described in Algorithm I. Subsequently, a pair of orthogonal Latin squares is generated by selecting two nonzero rows from M. Finally, is generated through three steps: large-scale mutation, scrambling, and diffusion.
Algorithm II: Generate the initial ciphertext image .
Input: An grayscale image Q, , M and a public parameter a.
Output: The initial ciphertext image .
Step 1: Read
Q and calculate the sum of all the pixel values, denoted as
. Letting
compute
. Using
as the system parameter and
as the initial value, generate the second
n-length chaotic sequence, then form the second finite field
using the method in Algorithm I.
Step 2: Obtain an
-difference matrix by removing the zero row of matrix
M. Select rows
(
) and
(
) to generate two
orthogonal Latin squares
and
via
. By transforming these squares into row vectors, denoted as
and
, respectively, two index indicators
and
can be constructed based on their uniformity using the following formula:
Step 3: Large-scale mutation. Transform
Q into a row vector
. Based on the parity of
, distinct index indicators can be selected to sequentially mutate each element of
and generate a new row vector
using the mutation formula provided below.
Step 4: Image scrambling. Utilize the orthogonality of
and
to scramble
and
(The row vector formed by the transposition of
M), resulting in the scrambled row vector
and an approximately uniform vector
.
Step 5: Image diffusion. The initial ciphertext image
is formed using
,
and
as pseudo-random sequences for auxiliary diffusion.
where
represents a temporary variable,
and ⊕ represents an XOR operation.
3.3. Optimization Process Using GA
In this section, we use a GA to optimize in order to enhance the randomness of the final encrypted image. First, owing to the inherent randomness of GAs, multiple indexes are determined in order to restore the original plaintext image. Then, local crossover and mutation operations on blocks are used to construct a large number of encrypted images, which significantly increases the level of randomness. Finally, after multiple rounds of genetic operations and using the optimal preservation strategy, the final encrypted image C and secondary key are generated.
Algorithm III: The optimization process using GA.
Input: , , , , the number of crossover blocks , the number of mutation blocks , and the number of iterations .
Output: The final encrypted image C and the secondary key .
Step 1: Process
as follows to acquire the third index indicator
:
Step 2: Crossover operation. Divide
into
parts from left to right and intersect each part according to
and
to form 2 ×
new individuals. These individuals are then stored in the matrix
. Using entropy as the fitness function, select the best individual, denoted as
, through the optimal preservation strategy. Simultaneously, record the corresponding index value
in the first row component of
. The Algorithm 1 is presented below, where crossover represents the compiled crossover function (
2).
Algorithm 1 Local crossover operation |
- 1:
for all do - 2:
for all do - 3:
crossover - 4:
crossover - 5:
end for - 6:
end for - 7:
- 8:
return
|
Step 3: Mutation operation. Divide
into
parts from left to right; each part undergoes mutation according to
and
, resulting in the formation of 2 ×
new individuals that are stored in the matrix
. Use the optimal preservation strategy to select the best individual as
and record the corresponding index value
in the second row component of
. The Algorithm 2 is presented below, where mutation represents the compiled mutation function (
3).
Algorithm 2 Local mutation operation |
- 1:
for all do - 2:
for all do - 3:
mutation - 4:
mutation - 5:
end for - 6:
end for - 7:
- 8:
return
|
Step 4: Let . Continue with Steps 2 and 3 until the number of iterations or and match that of the previous column in , then terminate the calculation and record final iteration number as .
Step 5: Transpose , the vector obtained after the iteration, into an matrix in order to obtain C and output .
3.4. Image Decryption Process
The proposed cryptosystem employs asymmetric processes for both encryption and decryption. To decrypt
C, the receiver requires
and
along with the characteristic value
and the public parameter
a. The decryption diagram of this cryptosystem is illustrated in
Figure 2.
The steps are described in detail below.
Step 1: First, is utilized to generate M following Algorithm I. Then, three row vectors , , and are generated using and a.
Step 2: C is transformed into a row vector and the pre-optimized image is decrypted using . This step is asymmetric with regard to the optimization process, and can be decrypted directly by using . Initially, mutation is performed according to the second index block of the last column of , then crossover is conducted according to the first index block, iterating times to obtain .
Step 3: The original image R is recovered from . First, reverse diffusion is performed on to obtain , then reverse scrambling to obtain , followed by reverse large-scale mutation to acquire . Finally, the result is transposed into an matrix in order to obtain the decrypted image R. This step is a complete reversal of the initial encryption process, and is not repeated.
4. Simulation Results and Safety Analyses
To validate the security and efficacy of the cryptosystem proposed in this paper, a set of grayscale images from the USC-SIPI2 image set were selected as test samples. The initial key was set to , and , whilehe public parameters were set to , , , and .
In the process of utilizing GAs for image encryption, fitness functions such as entropy and correlation coefficients are commonly employed for assessing the quality of ciphertext images. However, due to the stochastic nature of correlation coefficients, in this paper we have instead adopted the information entropy of the encrypted image as the fitness function.
We evaluated our proposed cryptosystem through simulation experiments from various aspects, including key space and sensitivity analyses, statistical analyses, resistance to differential attacks, and more. To demonstrate its superiority over recent algorithms, a comparison is provided in terms of security and efficiency.
4.1. Simulation Results
Our cryptosystem is highly effective in converting a grayscale image into a meaningless encrypted image, thereby ensuring the confidentiality and privacy of the original. Additionally, the decrypted image remains unchanged, with no loss or distortion, guaranteeing its integrity and authenticity.
Figure 3a shows the several plaintext images,
Figure 3c depicts the corresponding ciphertext images, and
Figure 3e illustrates the lossless decrypted images. In this cryptosystem, the initial encryption process ensures that any image meets the requirements for encryption, while the optimization stage further enhances the overall randomness. The second keys and the iteration numbers required for optimization are displayed in
Table 3. For a majority of the images, the optimization process can be completed within 20 generations, resulting in relatively higher-quality ciphertext images.
4.2. Key Analyses
4.2.1. Key Space Analysis
The key space of a cryptosystem is a metric describing its resistance against brute-force attacks. A larger key space results in increased resistance to such attacks, making it more difficult for attackers to determine the correct key. The initial key
has a precision of
for each real number. Therefore, the key space can reach at least
, which is significantly larger than
[
40,
41]. In addition, each image has a unique
value during decryption, and there is a public parameter that can be selected. Therefore, the key space of the proposed cryptosystem is of sufficient size to defend against brute-force attacks.
4.2.2. Key Sensitivity Analyses
Key sensitivity is a crucial property of an image cryptosystem, ensuring that even the slightest alteration in the encryption or decryption key will result in two entirely distinct datasets. In regard to the proposed cryptosystem, the key sensitivity can be analyzed from two perspectives: during the encryption stage and during the decryption stage.
To analyze the key sensitivities of the proposed cryptosystem, we selected Lena as the test image. The resulting ciphertext image when encrypting Lena with the initial key
is denoted as
. A minute value of
was subsequently added to each element of
, resulting in
as the ciphertext image obtained by encrypting Lena with the altered key. A comparison of the results of two encrypted images under three sets of parameters is shown in
Figure 4, revealing that while both images contain noise, they differ significantly from each other.
Table 4 calculates the percentages of different pixels in the two contrasting images after encryption, with the results surpassing
. This fully demonstrates the exceptional sensitivity of the proposed cryptosystem during encryption.
For the sensitivity analysis performed during decryption, we again used Lena as the test image. Utilizing
and
to decrypt
C, the original image can be obtained; however, even a slight alteration of
in each value of
results in a meaningless and completely different decryption compared to the original image. The contrasting results are presented in
Figure 5. Further,
Table 4 lists the percentages of different pixels between
Q and the decryption using the modified key, reaching more than 99.52%. This fully demonstrates that the proposed cryptosystem is highly sensitive to
. Additionally, there is an equally strong sensitivity to
, which need not be reiterated here.
4.3. Histogram Analyses
In the context of image encryption algorithms, the randomness and uniformity of the encrypted image are important for protecting against statistical attacks. The more random and uniform the ciphertext image is, the more challenging it becomes for attackers to identify correlations or patterns that can be exploited to break the encryption [
40]. Typically, the variance
S is employed as to describe the uniformity of the pixel distribution. Its calculation formula is
where
represents the occurrence of the
ith grayscale value in the image and
denotes the mean value of
. A smaller value of
S implies a more homogeneous distribution of grayscale pixels in the encrypted image, posing a challenge for attackers to exploit any statistical patterns and break the encryption.
Figure 3 illustrates the changes in the histograms of multiple images pre- and post-encryption. The histograms of the ciphertext images display a more homogeneous distribution in comparison to that of the original image, indicating an approximately equal frequency of occurrence for each grayscale value.
Table 5 presents the variance values of multiple images pre- and post-encryption. The data indicate that after encryption, the variance values decrease significantly and are all smaller than the standard value
, which meets the encryption requirement. Notably, the variance of the encrypted Lena image is as low as 101.133, indicating the effectiveness of our proposed cryptosystem in resisting histogram analyses.
4.4. Correlation Coefficient Analyses
In a plaintext image, adjacent pixels exhibit a strong correlation, which can be exploited by attackers to break the encryption using statistical patterns or correlations. Therefore, an effective encryption algorithm should eliminate the correlation of adjacent pixels in order to increase resistance against statistical analyses. Typically, correlation coefficients are commonly computed to assess the strength of correlations using the formula
where
u and
v represent the gray values of two adjacent pixels,
denotes the expected value of
u,
represents its variance, and
N denotes the quantity of samples randomly selected from the image.
In this study, we selected 4000 pairs of adjacent pixels in a stochastic manner from the vertical, horizontal, and diagonal directions in the image. The coefficients in the three directions
x,
y, and
z were then calculated according to Equations (
12) and (
13) and the average coefficients were obtained using Equation (
14).
The resulting coefficients are presented in
Table 5. In the table, the correlation coefficient of each plaintext image is highly proximate to 1 in three distinct directions, indicating a strong correlation between adjacent pixels. Conversely, the correlation coefficient of every ciphertext image approaches 0, signifying a weakened correlation. To demonstrate the optimization effect of our cryptosystem, we compared the correlation coefficients of the encrypted Lena image with those obtained from several recently proposed algorithms. The contrasting results of the coefficients are displayed in
Table 6. As can be seen, the average correlation coefficient when using our cryptosystem is larger than the results for those in [
29,
42], but smaller than those in the other seven papers. This indicates that our approach can effectively mitigate the pixel correlation.
To obtain a more intuitive visual comparison,
Figure 6 displays the pre- and post-encryption distribution of neighboring pixels in three directions for three different images when using our proposed cryptosystem. The midpoint of the original grayscale image is effectively scattered along the diagonal line, whereas that of the corresponding ciphertext image is more uniformly distributed within the entire scope. This demonstrates that the proposed cryptosystem is capable of achieving superior confounding effects and successfully passing the correlation test.
4.5. Entropy Analyses
Information entropy is another crucial measure for testing the uncertainty or randomness of ciphertext images, and can also be used to assess the efficacy of encryption algorithms. Its symbolic representation is H, and the calculation formula can be expressed as follows:
where
l is the number of gray values and
and
are the gray values and their occurrence probabilities, respectively. In cryptography, a secure cryptosystem should produce ciphertext images with uniform gray values in order to increase randomness and security. The ideal value of information entropy for an image with 256 gray levels is 8 [
46].
Following Equation (
15), we calculated the information entropy values of multiple encrypted images.
Table 5 displays the results, while
Table 6 lists the contrasting results obtained for Lena with different algorithms. As can be seen, all entropy values are very close to 8; the information entropy for the encrypted Lena image reaches 7.99888, which is a larger value than most of the other algorithms. Therefore, the proposed image cryptosystem is capable of generating ciphertext images with a more random and uniform distribution of pixel values, resulting in increased security and confidentiality.
4.6. Differential Attack Analyses
In order to be resistant to differential attacks, a secure cryptosystem should guarantee that even minor alterations to the plaintext will lead to large changes in the encrypted image. In general, two criteria, NPCR and UACI, are used to evaluate resistance to differential attacks. The respective formulas are provided below.
where
In the above formulas, and are two ciphertext images that correspond to plaintext images with only one different pixel, while M and N represent the width and height of the encrypted image, respectively.
For each plaintext image, 100 pixels at different positions are randomly selected and increased by 1.
Table 7 displays the maximum, lowest, and average values of NPCR and UACI. The significance level was set to 0.05, and the ideal expected values of NPCR and UACI for grayscale images with a size of
were obtained from [
47]. The average NPCR values in
Table 7 exceed the ideal values. Moreover, the average values of UACI are found to fall within the interval [
,
]. This testifies that the proposed image cryptosystem exhibits high resistance to differential attacks with respect to pixel modifications.
4.7. Cutting and Noise Attack Analyses
Signal loss or noise pollution can compromise the security and confidentiality of transmitted ciphertext images. To test a ciphertext image’s resilience against data loss and noise attacks, experiments can simulate such conditions to assess the encryption algorithm’s ability to maintain data integrity [
48].
Cutting parts of the ciphertext image can cause information loss and hinder the successful recovery of the original plaintext message. Taking the Plane image as an example, the corresponding decryptions are shown in
Figure 7 when cutting 1/16, 1/8, 1/4, and 1/2 at the upper left corner of the encrypted image. As can be seen, even when up to 50% of the encrypted image is cut, the proposed cryptosystem is still able to recover a visually recognizable image of the original message using the correct key. In addition, it demonstrates strong robustness against various types of noise attacks, including salt and pepper noise (SPN) with densities of 0.05 and 0.1 and Gaussian noise (GN) with a mean value of 0 and variances of 0.01 and 0.1. Despite the introduction of such noise types into the ciphertext image, the deciphering process utilizing the correct encryption key remains discernible, as demonstrated in
Figure 8. Overall, these results demonstrate the good robustness of our cryptosystem against both cutting attacks and different types of noise attacks.
Additionally, the PSNR index is usually employed for assessing the quality of decrypted images after attacks. The formula is
where
P and
denote the original decrypted image of size
and the decrypted image after attacks, respectively. A higher PSNR value indicates better image quality.
Table 8 displays the PSNR values of various images that have undergone cutting and noise attacks using the proposed encryption cryptosystem. The data in the table suggest that the PSNR values under these cutting attacks are greater than 7.7 dB, while those for the noise attack are greater than 7.2 dB. These findings suggest that the decrypted images exhibit relatively low levels of distortion compared to their original counterparts even after being attacked, and continue to maintain a high level of visual quality. Therefore, these results indicate that our cryptosystem is robust against both cutting and noise attacks.
4.8. Computational Complexity and Encryption Speed Analyses
Computational complexity (CC) and encryption speed are crucial factors to consider when evaluating the validity of an image cryptosystem. First, Algorithm I generates a chaotic sequence with length n, with computational complexity O, followed by constructing a difference matrix with computational complexity O. In Algorithm II, there are three layers of encryption structure: large-scale mutation, scrambling, and diffusion; thus, the CC is O. Algorithm III is an optimization process, including crossover and mutation operations, meaning that the CC is also O. Therefore, the CC of our cryptosystem is O.
The experimental environment was MATLAB R2019b, Microsoft Windows 10, Intel i5-1135G7, a 2.40 GHz processor, and 16 GB RAM. Based on 100 calculations,
Table 9 presents the average time taken to perform encryption and decryption of six representative images. The results indicate that each image takes approximately 5.86 s to encrypt and about 0.43 s to decrypt, suggesting the effectiveness of our image cryptosystem for instant encryption. The proposed cryptosystem employs an asymmetric process for encryption and decryption that involves multi-segment and multi-round crossover and mutation operations during encryption, which can be computationally expensive and result in longer optimization and encryption times compared to other algorithms. However, the decryption time is significantly shorter when using the secondary secret key to decrypt the ciphertext image directly. The comparison results reported in
Table 9 demonstrate that our GA-based encryption cryptosystem is faster in both encryption and decryption compared to other contrasting algorithms, with the exception of the algorithm presented in [
29], reflecting the efficient optimization process of the proposed cryptosystem.
4.9. Analysis of Resistance to Chosen-Plaintext Attacks
Chosen-plaintext attacks are a potent method of attacking encryption schemes. In such an attack, the attacker has access to the encryption scheme, and can select plaintext images and encrypt them to obtain the key’s information. If a cryptosystem is able to withstand chosen-plaintext attacks, this usually indicates that the encryption approach is secure against three other classical attacks as well: ciphertext-only attacks, known-plaintext attacks and chosen-ciphertext attacks [
21,
53].
In the proposed cryptosystem, the same difference matrix is used for all images in image encryption. This matrix only needs to be generated once, and can be reused to encrypt multiple images. However, employing the information of plaintext images in the key ensures that the encrypted data remain unique and secure for every individual image even if the difference matrix is identical. Specifically, the entire cryptosystem is extremely sensitive to both and to the plaintext image. If even a single pixel is altered, the resulting , , and will be completely distinct. Additionally, our encryption cryptosystem utilizes two Latin squares and leverages the approximate uniformity of the difference matrix during diffusion. With just one round of encryption processing required to achieve a secure result, our cryptosystem is resistant to chosen-plaintext attacks, as well as other forms of intrusion.
Additionally, all-black or all-white images are frequently utilized by hackers to launch attacks on encryption algorithms. These special images were also subjected to experiments.
Table 5 shows the resulting correlation coefficients of approximately 0, variance values of approximately 100, and entropies of approximately 8 for two encrypted ciphertext images. These results fully demonstrate that the proposed cryptosystem can resist statistical attacks.
Table 7 shows that both of the encrypted images pass the differential attack tests successfully.
Table 8 displays that all PSNR values related to both encrypted images exceed 7.2 dB, demonstrating our cryptosystem’s robustness. Moreover, our cryptosystem exhibits resistance against chosen-plaintext attacks as well as other classical attack methods.