The fast development of image encryption requires performance evaluation metrics. Traditional metrics like entropy do not consider the correlation between local pixel and its neighborhood. These metrics cannot estimate encryption based on image pixel coordinate permutation. A novel effectiveness evaluation metric is proposed in this paper to address the issue. The cipher text image is transformed to bit stream. Then, Poker Test is implemented. The proposed metric considers the neighbor correlations of image by neighborhood selection and clip scan. The randomness of the cipher text image is tested by calculating the chi-square test value. Experiment results verify the efficiency of the proposed metrics.
The accelerating growth of personal smart devices and Internet makes it easy to distribute, share, and exchange digital image data via various sorts of open networks. It is simple to access these image data when they are transmitted via open networks. In this case, image data security has become a crucial issue because some of the image content needs to be kept confidential. Image encryption is an effective solution to guarantee image data security. The encryption process converts the original image into another incomprehensible image. The ideal cipher text image is not intelligible. Such a cipher text image could be stored or transmitted across insecure networks without content leaking to anyone except the intended recipient. Since images have certain characteristics such as bulk data size and high intercorrelation, image encryption schemes focus on destroying the correlation between neighbor pixels. This requires that cipher text image should appear as meaningless noises.
Since image encryption has attracted extensive attention, various encryption schemes have been proposed in recent years. As a result, efficient image encryption performance evaluation is desired. To evaluate the encryption performance helps optimizing parameter setting as well as improving encryption scheme [
This paper proposes a nonreference objective metric to evaluate the image encryption performance. The novel metric is based on Poker Test with consideration of pixel neighborhood relationships. First traditional objective criterions are discussed. Then, Poker Test is introduced. The novel metric is described. Finally, performance of the metric is evaluated to check the effectiveness in Section
When an image encryption scheme is proposed, several performance analyses will be implemented to estimate the effectiveness of novel encryption scheme. The most widely used evaluation criterions include encryption quality and Shannon entropy.
The encryption quality is designed to measure the change rate of pixel values when encryption is applied to an image [
Let
The encryption quality could not estimate encryption based on image pixel coordinate permutation. The pixel positions shuffle without values changing makes no difference between
Shannon entropy or information entropy is a measurement of uncertainty. The greater value of entropy indicates the system is more random. When a random variable’s probability distributes equally, the Shannon entropy will be the biggest. If the Shannon entropy of a cipher text image approaches the theoretical peak value, the encryption will be considered as effective [
Assume the probability of pixel value
Autocorrelation is the cross-correlation of a signal with itself at different points in time [
The gap test is used for testing randomness of a sequence. It is concerned with the number of gaps in any particular class of digits [
Poker Test is a randomness test. It treats numbers grouped together as a poker’s hand. The hands obtained are compared to what is expected. The classical Poker Test consists of using all possible categories obtained from poker that uses hands of five numbers. In practice, Poker Test can be applied without being restricted to hands of five numbers. For cryptography application, four numbers are more convenient to deal with bit streams [
National Institute of Standards and Technology designed randomness test FIP 140-2 with Poker Test as the second test [
Image encryption destroys the correlation between neighbor pixels. Cipher text image should appear like meaningless noise as much as possible. Effective image encryption should generate randomness like cipher text image. The novel encryption performance evaluation metric is based on randomness test of cipher text image and pixel neighborhood correlations. Figure
Flowchart of encryption performance evaluation of proposed metric.
The cipher text image consists of pixels with integer decimal values. The values need to be binarized for Poker Test because there are too many possible combinations for pixel values. The cipher text image can be converted into a binary image by tossing coin formula [
After the binarization, an image with binary pixel values is obtained.
The binarized cipher text image is divided into small cells that have the same size. One cell covers a local neighborhood. The size of cell is flexible, which is related to the neighborhood selection. Generally using 8-neighborhood of current pixel corresponds to a
The size of neighborhood selection affects the bit segment of bit stream. Different size generates different length of bit segment. The possible combination numbers of the bit segments are also different. This will lead to the difference of chi-square value because the number of possible occurrences influences the value. In this case, the evaluation procedure should be kept consistent with neighborhood selection when estimating encryption schemes. Otherwise, the results make no sense.
After neighborhood selection, small cells with the same size are acquired. The cell is two-dimensional in most cases. Thus, it is required to convert these cells into bit stream for Poker Test. The cells are clip scanned to produce bit segments. Figure
Clip scan.
The bit stream consists of bit segments. These bit segments have the same length of
The observed occurrence of possible value
Arnold’s cat map is a chaotic map. It could be employed to encrypt image by transforming pixel positions [
In this section, the classical Arnold’s cat map image encryption algorithm is adopted to verify the proposed performance evaluation metric. The pixel in position
Encryption results with Arnold’s cat map.
Original
Iteration 1
Iteration 2
Iteration 3
Iteration 4
Iteration 5
Iteration 6
Iteration 7
Iteration 8
Iteration 9
Iteration 10
Iteration 11
Iteration 12
Iteration 13
Iteration 14
Iteration 15
Because there is no pixel value confusion processing in this encryption, the histogram of any ciphered image in Figure
The proposed metric is affected by the neighborhood selection as mentioned in former section. Table
The evaluation results of Figure
Iteration |
|
|
|
|
|
|
|
|
|
|
|
---|---|---|---|---|---|---|---|---|---|---|---|
1 |
|
1.196775 |
|
|
11.63813 |
|
|
413.79 |
|
|
58423.71 |
2 | 0.734746 | 0.360651 | 1.543533 | 4.922365 | 3.755407 | 19.79392 | 92.41148 | 79.89103 | 793.5749 | 8690.154 | 6602.61 |
3 | 0.120514 |
|
0.304063 | 1.000514 | 0.659406 | 3.073698 | 14.45406 | 9.230866 | 117.1537 | 1612.963 | 2851.851 |
4 | 0.0273 | 0.043753 | 0.039836 | 0.191264 | 0.15016 | 0.906664 |
|
5.184159 | 79.54323 |
|
1525.824 |
5 | 0.047465 | 0.035306 | 0.048886 | 0.216916 | 0.163809 | 1.072634 | 5.757189 | 5.579702 | 80.82056 | 1540.979 | 1597.809 |
6 | 0.027789 | 0.028205 |
|
|
0.221175 | 0.975154 | 5.873823 | 6.071595 |
|
1703.891 | 1828.916 |
7 | 0.027089 | 0.264011 | 0.283531 | 0.470944 | 0.695101 | 1.582503 | 5.62027 | 7.268365 | 87.91688 | 1707.679 | 1696.313 |
8 | 0.043775 | 0.057244 | 0.203925 | 0.426553 | 0.518664 | 1.632874 | 7.273436 | 7.253152 | 96.00669 | 1919.844 | 2014.56 |
9 |
|
0.038816 | 0.055798 | 0.137621 | 0.208002 | 0.896879 | 8.510775 |
|
79.82708 | 1616.752 | 2294.92 |
10 | 0.055899 | 0.032103 | 0.061117 | 0.228405 |
|
1.015378 | 5.736905 | 5.255154 | 80.82056 | 1525.824 | 1514.458 |
11 | 0.027194 | 0.027806 | 0.045033 | 0.141306 | 0.161313 |
|
5.336291 | 5.564489 | 82.38175 | 1575.077 |
|
12 | 0.033834 | 0.121355 | 0.291464 | 0.564086 | 0.934649 | 2.592457 | 9.190297 | 10.09295 | 96.43247 | 1798.607 | 1559.922 |
13 | 0.301445 | 0.672199 | 1.310661 | 3.284809 | 4.448776 | 17.09745 | 61.50843 | 80.58577 | 577.9887 | 4556.741 | 5522.846 |
14 | 1.023181 |
|
3.282402 | 10.75702 |
|
72.00784 | 391.0057 |
|
4649.005 | 54479.73 |
|
Evaluation result value curve with different neighborhood selection.
2 × 3 and 3 × 2
2 × 2
1 × 3 and 3 × 1
3 × 3
3 × 4 and 4 × 3
4 × 4
4 × 5 and 5 × 4
The novel metric ranks these cipher images performance by evaluation results’ descending order as in Table
Performance ranking of cipher text image by descending order in Figure
Ranking number |
|
|
|
|
|
|
|
|
|
|
|
---|---|---|---|---|---|---|---|---|---|---|---|
1 | 9 | 3 | 6 | 6 | 10 | 11 | 4 | 9 | 6 | 4 | 11 |
2 | 7 | 11 | 4 | 9 | 4 | 9 | 11 | 4 | 4 | 10 | 10 |
3 | 11 | 6 | 11 | 11 | 11 | 4 | 7 | 10 | 9 | 5 | 4 |
4 | 4 | 10 | 5 | 4 | 5 | 6 | 10 | 11 | 10 | 11 | 12 |
5 | 6 | 5 | 9 | 5 | 9 | 10 | 5 | 5 | 5 | 3 | 5 |
6 | 12 | 9 | 10 | 10 | 6 | 5 | 6 | 6 | 11 | 9 | 7 |
7 | 8 | 4 | 8 | 8 | 8 | 7 | 8 | 8 | 7 | 6 | 6 |
8 | 5 | 8 | 7 | 7 | 3 | 8 | 9 | 7 | 8 | 7 | 8 |
9 | 10 | 12 | 12 | 12 | 7 | 12 | 12 | 3 | 12 | 12 | 9 |
10 | 3 | 7 | 3 | 3 | 12 | 3 | 3 | 12 | 3 | 8 | 3 |
11 | 13 | 2 | 13 | 13 | 2 | 13 | 13 | 2 | 13 | 13 | 13 |
12 | 2 | 13 | 2 | 2 | 13 | 2 | 2 | 13 | 2 | 2 | 2 |
13 | 14 | 1 | 14 | 14 | 1 | 14 | 14 | 1 | 14 | 14 | 1 |
14 | 1 | 14 | 1 | 1 | 14 | 1 | 1 | 14 | 1 | 1 | 14 |
As the selection of neighborhood varies, the processing time for evaluation changes. Table
Time cost of
Time cost (s) |
|
|
|
|
|
|
|
|
|
|
|
---|---|---|---|---|---|---|---|---|---|---|---|
0.7323 | 0.708 | 0.597 | 0.4365 | 0.4407 | 0.3298 | 0.2946 | 0.2897 | 0.2613 | 0.2598 | 0.2486 |
Normalized autocorrelation values with one-pixel shift on different directions are employed to measure the encryption performance in Figure
The evaluation results of Figure
Iteration | Horizontal | Vertical | Diagonal |
---|---|---|---|
1 | 0.77962 | 0.729447 | 0.865807 |
2 | 0.57696 | 0.423958 | 0.706407 |
3 | 0.214836 | 0.064253 | 0.415315 |
4 | 0.026138 | −0.06878 | 0.062199 |
5 | −0.04489 | −0.00844 | −0.06562 |
6 | −0.03496 | 0.026926 | −0.00918 |
7 | 0.01608 | 0.364424 | 0.025746 |
8 | 0.101325 | 0.091398 | 0.349932 |
9 | 0.024626 | −0.06663 | 0.094174 |
10 | −0.04724 | −0.00661 | −0.06211 |
11 | −0.01579 | 0.018661 | −0.00866 |
12 | 0.080648 | 0.25252 | 0.01943 |
13 | 0.419839 | 0.577335 | 0.243791 |
14 | 0.672049 | 0.819787 | 0.55581 |
Performance ranking of cipher text image by descending order in Figure
Ranking number | Horizontal | Vertical | Diagonal |
---|---|---|---|
1 | 10 | 11 | 11 |
2 | 5 | 6 | 7 |
3 | 11 | 12 | 9 |
4 | 6 | 7 | 4 |
5 | 3 | 10 | 6 |
6 | 9 | 4 | 5 |
7 | 4 | 5 | 10 |
8 | 8 | 9 | 12 |
9 | 12 | 13 | 8 |
10 | 7 | 8 | 3 |
11 | 2 | 3 | 13 |
12 | 13 | 14 | 2 |
13 | 1 | 2 | 14 |
14 | 14 | 1 | 1 |
Another comparison is presented by the gap test. The cipher text images are stretched to a vector column by column to perform the gap test. As the cipher text images in Figure
The evaluation results of Figure
Iteration | 20% | 50% | 70% |
---|---|---|---|
1 | 52503.25 | 7808.829 | 367.5231 |
2 | 47752.74 | 4465.835 | 209.8415 |
3 | 43252.68 | 1820.068 | 259.5888 |
4 | 41304.9 | 1747.163 | 451.1019 |
5 | 44715.45 | 1527.501 | 468.2339 |
6 | 43627.67 | 1364.194 | 362.027 |
7 | 48866.78 | 3543.446 | 162.4724 |
8 | 43643.1 | 2268.268 | 249.9645 |
9 | 41271.27 | 1787.271 | 459.0743 |
10 | 44687.99 | 1501.879 | 476.4293 |
11 | 43458.54 | 1339.975 | 367.6016 |
12 | 46925.5 | 2605.323 | 217.2968 |
13 | 50898.11 | 5734.178 | 265.2439 |
14 | 54496.37 | 8954.634 | 479.1238 |
Performance ranking of cipher text image by descending order in Figure
Ranking number | 20% | 50% | 70% |
---|---|---|---|
1 | 9 | 11 | 7 |
2 | 4 | 6 | 2 |
3 | 3 | 10 | 12 |
4 | 11 | 5 | 8 |
5 | 6 | 4 | 3 |
6 | 8 | 9 | 13 |
7 | 10 | 3 | 6 |
8 | 5 | 8 | 1 |
9 | 12 | 12 | 11 |
10 | 2 | 7 | 4 |
11 | 7 | 2 | 9 |
12 | 13 | 13 | 5 |
13 | 1 | 1 | 10 |
14 | 14 | 14 | 14 |
In this section, image encryptions with pixel value scrambling and position shuffle are used to verify the novel evaluation metric. The plain text image is first encrypted by Vigenere cipher to scramble its pixel grey level, and then the pixel positions are shuffled. Coupled logistic map is employed to produce the pseudorandom sequences for the encryption [
Encryption results with pixel value scrambling and position shuffle.
Original
Pixel position shuffle
Pixel value scrambling
Both
The evaluation results for Figures
Evaluation results of the cipher text image in Figure
The proposed metric | Normalized autocorrelation | Gap test | Entropy | |||||||
---|---|---|---|---|---|---|---|---|---|---|
|
|
|
Horizontal | Vertical | Diagonal | 20% | 50% | 70% | ||
Figure |
0.337 | 325.96 | 322.42 | 0.0627 | −0.075 | −0.061 | 172290 | 2504.5 | 2221.7 | 7.4442 |
Figure |
0.071 | 320.85 | 321.63 | 0.0009 | −0.006 | 0.0023 | 91872 | 2666.9 | 17.1381 | 7.9967 |
Figure |
0.066 | 320.45 | 320.25 | −0.003 | 0.0028 | 0.0081 | 94411 | 2823.1 | 14.51 | 7.9967 |
This paper proposes a nonreference objective metric to evaluate the image encryption performance. The novel metric considers pixel neighborhood relationships. Poker Test is employed to test the randomness of the cipher text image. The metric can efficiently estimate encryption based on image pixel coordinate permutation. The experiment recommends several neighborhood selections.
The authors declare that there is no conflict of interests regarding the publication of this paper.
The project is supported by National Natural Science Foundation of China (Grant nos. 61402051 and 51278058), the 111 Project (no. B14043), Natural Science Basic Research Plan in Shaanxi Province of China (Program no. 2016JM6076), and the Young Scientists Fund of Natural Science Foundation of Shaanxi Province (Program no. 2015JQ6239).