Abstract
Cryptography is the most peculiar way to secure data and most of the encryption algorithms are mainly used for textual data and not suitable for transmission data such as images. It is seen that the generation of secure key in Image cryptography has been a challenging task in the way of providing secured key generation for the transmitted data. In order to aid secured key generation in this context, an optimized secret key generation based on Chebyshev polynomial with Adaptive Firefly (FF) optimization technique is proposed. The optimized key is utilized with process of shuffling, diffusion, and swapping to get a better encrypted image. At the receiver end, reverse process is applied with optimized key to retrieve the original input image. The efficiency of our proposed method is assessed by the exhaustive experimental study. The results show that the proposed methodology provided correlation coefficient of 0.21, Number of Pixels Change Rate (NPCR) of 0.996, Unified Average Changing Intensity (UACI) of 0.3346 and Information Entropy of 7.995 as compared with the existing methods.
Keywords
Introduction
Advances in image processing in today’s world leads to the problem of security. Security is one of the major issues during the transformation of image as it can be tracked by the attackers. To avoid this, image should be protected before the transmitting it from sender to the recipient [1]. Encryption is the process of converting a normal plain text/image into cipher text/cipher image. It contains two important attributes confusion and diffusion. Confusion is the process of performing swapping operation whereas diffusion is the process of performing scrambling operation [2]. Cryptography and Stenography both plays an important role in encryption. The process of representing hidden information is done by means of cryptography. It is the process of encrypting a message/image and the third party cannot be able to see it, without knowing the exact key [3]. Where as in stenography, the data/picture isn’t hard to decipher yet the vast majority can’t ready to distinguish the nearness of message. Whenever cryptography and stenography is consolidated, two levels of anchored encryption will be given [4].
An encryption instrument goes for keeping the data steady or secure while it is being transmitted or kept on a medium that is possibly subject to unapproved get to. In order to keep the picture grouped between users, it is major that no one have the ability to decode the photo without the best possible decryption key. To address this trouble, a grouping of standard encryption calculations, for example, Advanced Encryption Standard (AES) and data encryption standard (DES) are utilized [5]. The picture encryption has certain attributes, for example, the solid relationship among neighboring pixels, repetition of data, being less delicate when contrasted with the content data [6]. For the transmission of pictures, the encryption technique is relying upon Two Stage Random Matrix Affine Cipher which is connected with Discrete Wavelet Transformation (DWT) [7].
There are two types of encryption algorithms symmetric and asymmetric. Symmetric algorithm makes use of single key at both sender and receiver side but asymmetric algorithm use different keys at sender and receiver end [8]. Some symmetric algorithms such as DES, triple DES, blow fish, two fish, three fish, etc. are discussed as well as few asymmetric algorithms like Diffie-Hellman, RSA, ECC, ELGamal, DSA, etc. are also discussed in [9–11]. T. Gopalakrishnan et al proposed that encryption is done in bitwise manner also where mixing process is presented to modify the pixel intensity values earlier to encryption process [12]. Many researchers use either cryptography or steganography to improve security, but a combination of both the techniques provides better security [13]. CAO Guang-hui et al discussed about an algorithm where bit permutation in image is performed assuming that the output of chaotic system is very unpredictable. They analyzed algorithm’s key space as well as digital characteristics of cipher-image [14]. In other work L. Xu et al explained about a novel chaotic image encryption calculation which incorporates a square image scrambling plan and another powerful file based dispersion plot [15]. Effectiveness of chaotic image cryptosystem utilizing bit-level stage experiences its high computational many-sided quality. To enhance the productivity, a novel piece level chaotic image figure in view of query table is proposed in [16]. Image encryption is by one means or another not quite the same as content encryption because of some natural highlights of image, for example, mass information limit and high connection among pixels, which are for the most part hard to deal with by ordinary calculations [17, 18]. A novel image encryption conspire in light of pivot framework bit-level stage and square dispersion were additionally utilized. In this plain images are partitioned into non-covering obstructs, on which stage is performed by increasing the 3-D network pursued by square dispersion to change the attributes [19]. Piecewise straight chaotic maps (PWLCM) are utilized to control the swapping of components in the groupings. In this the plain image is changed over into two double arrangements of same size, on which another dispersion plot is acquainted with diffuse the two successions commonly [20]. In other work, spatiotemporal bedlam is locked in to rearrange the squares and additionally to change the pixel esteems [21]. In light of the high-measurement Lorenz chaotic framework and perceptron demonstrate inside a neural system, a chaotic image encryption framework with a perceptron show is proposed in [22]. In light of the unusual idea of chaotic successions it has been utilized as key and afterward actualize the computerized shading image encryption with high private security [23]. Guanrong Chen et al use the 3D feline guide to rearrange the places of pixels and with the assistance of another chaotic guide to confound the connection between the figure image and the plain-image. So it fundamentally builds the protection from factual and differential assaults [24]. Tiegang Gaoet al proposed another encryption plot, which utilizes rearranging grid to rearrange the places of image pixels and after that uses a hyper-chaotic framework to confound the connection between the plain-image and the cipher image [25].
Generation of secure key has been a challenging task in image cryptography. In this paper, a unique key is generated using Chebyshev polynomial and Adaptive firefly algorithm. Chebyshev polynomial gives a sequence which is chaotic in nature. Thus the optimized key can be obtained with the help of adaptive Firefly algorithm and which ensures the security of the transmission of image data by tackling more unauthorized problems. Section 2 describes the proposed methodology. In section 3 we discussed about the results. Finally section 4 contains the conclusion.
Proposed methodology
Image security is the key point in image transformation. Major problems in image transformation are unauthorized attacks, security, time complexity, and quality of image. Images constitute a large portion of information. Most of the image encryption algorithms are complex and uncompromised on the quality of image. So in order to get rid of insecurity while transmission of image bits in this framework a new technique for optimized key generation technique is formulated in this paper, a unique encryption scheme is proposed for providing better level of security. The flow of the proposed methodology is shown Fig. 1.

The proposed methodology for image security.
At first, the input image is converted into gray scale image by the employment of efficient conversion technique. After that, DWT process is applied to this gray scale image for making the encryption process much more efficient. This transformation is preferred in such a way that it is easy to perform the inverse operation. This transformed image will be added with optimized key, which we obtain using Chebyshev polynomial and Adaptive Firefly algorithm. In the next step, shuffling will be performed by means of permutation. After the process of shuffling, diffusion will be performed by the introduction of improved ROT technique and swapping is done in diagonal order. At the receiver end, Inverse transformation is applied and the same keys are used to retrieve the original input image. Therefore, this proposed scheme will provide more security for image communication.
Discrete Wavelet Transform is a technique used to divide the gray scale image g i into sub bands and subsampled. The discrete wavelet transform (DWT) refers to wavelet transforms for which the wavelets are discretely sampled. The discrete wavelet transform of the computerized image pursued by down sampling process produces four part of the image every one of 1/4 size of unique image. The initial segment is named as the decimal segment which comprises of most data of image and other three section are fractional or horizontal.
If the above wavelets are applied to an image, image sub bands will be produced as LL, LH, HL, and HH format. LL is the decimal component is also called as mother component in DWT. LH, HL, HH are the fractional component. In proposed approach only the decimal component is used because encryption and decryption process is more difficult in fractional component compare to decimal component. The structure of Discrete Wavelet Transformation decomposition of an image is shown in Fig. 2.

Structure of DWT decomposition.
DWT are functions generated from one single function φ by enlargements and interpretations. The fundamental idea of the discrete wavelet change is to speak to any discretionary capacity as a superposition of wavelets. Any such superposition disintegrates the given capacity into various scale levels where each level is moreover deteriorated with a goals adjusted to that level.
Gray scale image g
i
is additionally decomposed by utilizing the discrete wavelet transform and detail coefficients LLj at scale j are given by

Locations of current pixel around pixels.
Encryption is the most efficient way to achieve image security for the image encryption in behalf of the shuffling, diffusion or rotation and swapping. This phase takes as input from DWT (Di) and encrypts it using chebyshev polynomial of the order as defined by the key generation process. The image is given as pixel wise, and each pixel is given as input to the encryption function described earlier as input image. After every pixel of the decomposed image has been encrypted, the encrypted pixels are again converted back to image form hence giving the final encrypted image.
Key generation with Chebyshev polynomial
Here, the decomposed image Di is subjected to the key generation process. In Chebyshev polynomial key generation is described in below equation:
Where, C0 (x) =1, C1 (x) = x, C n (x) - Chebyshev map, n - Position of Key, x - Key current value.
In Chebyshev polynomial, values are selected randomly for the key generation. Consequently, the Adaptive Firefly algorithm is used to select the optimized key, which is explained in below section.
The optimized secret key generated randomly through the aforementioned process is done with the help of optimization technique called Adaptive Firefly algorithm. Adaptive firefly algorithm has been utilized in various applications and demonstrated its accuracy and efficiency. The concept of the FF algorithm is detailed below.
The Adaptive FF is mapping behavior of fireflies in natural conditions. Individuals are described by several organic characters like specific way of flashing, specific way of moving and specific perception of the others. These are mathematically modeled in implementation of Adaptive FF as
α - Light absorption coefficient in given circumstances, β - Firefly random motion factor, γ
pop
- Firefly attractiveness factor.
Which implement behavior of different species of fireflies and natural conditions of the environment. Firefly goes to the other one by measuring the intensity of flickers over the distance between them is characterized by a suitable metric. In Adaptive FF, an average distances C ij between any two fireflies i and j maps the inverse square law. Attractiveness of individuals decreases with increasing distance C ij between them.
Distance between any two fireflies i and j located at key points (x
i
, x
j
) and (y
i
, y
j
) in image can be define using Chebyshev metric
Here attractiveness of fireflies i to j decreases with increasing distance. Attractiveness is proportional to intensity of light seen by surrounding individuals and defined as,
Where, notations are:
α – light absorption factor mapping natural conditions,∥ γ
pop
– Firefly attractiveness factor.
Firefly i moves toward the more attractive and clearer flashing individual j using information about other individuals in the population denotes by formula,
Where notations are,
β – coefficient mapping natural random motion of fireflies, e
i
– randomized vector changing position of firefly on each axis.
Adaptive FF is utilized for searching image key-areas. Each firefly is representing a single pixel. In each iteration, move entire population to search between all image points. Fireflies move from pixel to pixel and search for specific areas according to a given criterion. In this work, we used simplified fitness function which reflects brightness and sharpness of the input image points,
Where, ψ – denotes quality of evaluated pixel, a, b, c, d – Random value.
The optimized key from the Adaptive FF are then used by decomposed image Di for encryption. Adaptive FF implementation is presented in below algorithm.
The decomposed image Di, is subjected to the shuffling process and shuffled image S i is obtained. The optimized key is utilized for the shuffling procedure. Images have solid connections among nearby pixels, so keeping in mind the end goal to bother the high relationship among pixels of an image, shuffling network is utilized to rearrange the situation of the plain-image. Without loss of generality, the dimension of the plain image N × M, the position matrix of pixels is pi,j where, i = 0, 1 . . . . . M - 1 and j = 0, 1 . . . . . N - 1 the procedure of generation for shuffling matrix is described in below figure,
Rotation technique
The shuffled image S i is exposed to rotation technique, which alters the image pixel value from top to bottom, right to left and vice versa. The rotated image R i is then swapped. Figure 4 describes the original pixels and their change location in rotation.

Original pixels location and their modified location after rotation.
In swapping process, the pixels are swamped without modifying the values from the rotated image R i . For instance replacement of pixel in the position (i, j) is replaced by diagonal order as shown in Fig. 5.The resultant image P i from the swapping process is given to the encryption stage. The generated secret key is used with the swapping image to produce the cipher image C i . The encrypted image is employed for the decryption process to yield the decrypted image D i .

Swapping process.
Decryption is the reverse process of encryption procedure and the input for the decryption is encrypted image E i and the key with length of 128 bits. The encrypted image is allowing to the swapping process to interchange the diagonal order and rotation technique to perform the reverse process of top to bottom and left to right. Afterwards the result of the previous stage is passing to the shuffling process to perform the reverse operation of shuffling and then the reverse process is accepted for the key generation. The output of the resultant image is decrypted image as D i .The below section illustrates the result of the proposed framework and comparison analysis of existing works.
Experimental results discussion
The experimental results for the proposed method illustrate the image security using encryption and decryption process. For transmitted information the Images constitute a main area. Most of the image encryption algorithms are complex and uncompromised on the quality of image. So in order to get rid of insecurity while transmission of image bits in this framework a new technique for optimized key generation technique is formulated in this paper, a unique encryption scheme is proposed for providing better level of security.
Results of proposed system
As per the proposed method, the input image is change into gray scale image. Initially the sample input (gray scale image) is taken and resized this to 768 × 1024. The gray scale image g i is in the form of pixel values ranges from 0 to 255. Figures 6 and 7 show the result of input image and gray scale image.

Original image.

Gray scale image.
Discrete Wavelet Transform is a technique used to divide the gray scale image g i into sub bands and sub sampled. The results attained as of the DWT are illustrated in Fig. 8.

Image after wavelet transform.
For the DWT image the secret key will be generated using the Chebyshev polynomial and the best key is selected using the Adaptive FF. Figure 9 shows the output image after applying the optimized key. This output image is then passes to the shuffling stage. Figure 10 shows the result of shuffling process.

Image appended with optimized key value.

Shuffled image.
Shuffled image is then passes to the rotation stage where original pixel changes the pixel from top to bottom and left to right. The result obtained from the rotation is illustrated in Fig. 11. The output of rotation process is delivered to the confusion or swapping stage to produce the cipher image. The image produced after swapping operation is illustrated in Fig. 12. This swapped image is then XORed with a fixed value to get an output which will not give any visual idea about the original image (as shown in Fig. 14 (h).

Rotated image.

Swapped image.
Finally the image will be decrypted and illustrate in Fig. 13. The performance evaluation of the proposed method is described in the succeeding section.

Decrypted image.

(a) Original Image (b) Grayscale Image (c) Image after DWT (d) Appended Image (e) Shuffled Image (f) Rotated Image(g) Swapped Image (h) Encrypted Image (i) Decrypted Image.
The performance of the proposed method is evaluated in terms of Correlation coefficient, NPCR, UACI, Encryption speed and Information Entropy analysis.
Correlation coefficient (CC)
The correlation coefficient is indicated as
Where, E (σ) – Encrypted plain text,
σ l – length of plain text,
C – Cipher text
Now, calculate covariance between σ and
Then the standard deviations of σ and
Finally
It is to be noted that depending on the value of
The comparative analysis is discussed between the existing and the proposed method by the parameter of Correlation Coefficient is shown in Table 1.
Comparative analysis of CC
Correlation Coefficient (CC) value is smaller than the existing method which proved the performance improvement of proposed work such that the correlation coefficient of the proposed method is said to be 0.2100 whereas all the existing work values are about 0.227, 0.91765, and 0.92401 which are far higher than the proposed one due to the best encryption efficiency the correlation coefficient is far much reduced.
To check the impact of one-pixel change all in all image scrambled by the proposed approach, two regular measures were utilized: Number of Pixels Change Rate (NPCR) and Unified Average Changing Intensity (UACI).
The NPCR estimates the level of various pixel numbers between the two pictures. It is utilized to distinguish the alteration of the changes in the figure picture to identify the affectability of the image crypto framework. NPCR is defined as,
Where, W and H are width and height of C1 or C2. Grey scale values of the pixels at grid (i, j) of C1 and C2 are represented by C1 (i, j) and C2 (i, j) respectively. Define a bipolar array D with the same size as image C1 or C2. Then D (i, j) is determined by C1 (i, j) and ‘C2 (i, j) if C1 (i, j) = C2 (i, j) then the D (i, j) =1, otherwise D (i, j) =0.
UACI estimates the normal force of the contrasts between the first picture and the scrambled picture. This parameter is utilized to recognize the progressions of pixels in various figure pictures.
The UACI is defined as,
The comparative analysis is discussed between the existing and the proposed method by the parameters NPCR and UACI as shown in Table 2.
Comparative analysis of NPCR and UACI
The proposed method gets the value of 0.9960 for NPCR and 0.3346 for UACI whereas for the existing work it is said to be 0.9231, 0.706 and 0.502 for NPCR and 0.3921, 0.3347 and 0.252 for UACI according to the existing works which is compared in the table and since it has better estimation efficiency between two pictures.
The encryption speed is used to analyze the time of encryption process for the cryptosystem. The encryption speed is specified in seconds. Table 3 describes the analysis of encryption speed with various methods.
Comparative analysis of encryption speed
Comparative analysis of encryption speed
In the proposed work, encryption speed will be less than the existing work. Encryption speed is than the existing method which proved the performance improvement of proposed work such that the proposed method is said to be 0.1420 whereas all the existing work values are about 0.33, 0.391, 0.43 which are far higher than the proposed one due to the best encryption efficiency the Encryption speed is far much reduced.
Information entropy is Mathematical entropy to measure the estimation of confusion of the capacity and the information correspondence. Assume is the measure of pixels of the encrypted image at that point esteems are and furthermore the aggregate sum of pixels of the encrypted image is P. The data entropy of the encrypted image is characterized as
The entropy value of the proposed work is 7.995 which are closer to standard value of 8.
From the Table 4 it is stated that information Entropy is smaller than the existing method which proved the performance improvement of proposed work such that the proposed method is said to be 7.995 whereas all the existing work values are about 7.975,7.98710 and 7.98724 which are far higher than the proposed one due to the best encryption efficiency the Information Entropy is far much increased.
Comparative analysis of information entropy
The MSE of an estimator a∧ with respect to an unknown parameter a is defined as,
From the Table 5 it is stated that mean square error is smaller than the existing method which proved the performance improvement of proposed work such that the correlation coefficient of the proposed method is said to be 0.241 whereas all the existing work values are about 0.271, 0.34, 0.45 which are far higher than the proposed one due to the best encryption efficiency the correlation coefficient is far much reduced.
Comparison analysis of mean square error
Comparison analysis of mean square error
In this work, a novel method is presented to encrypt images based on unique key with shuffling, rotation and swamping processes. We presented an adaptive firefly algorithm which is applied on chebyshev polynomial for the generation of optimized key. The proposed methodology shows encouraging result in terms of less Correlation Coefficient, high NPCR, better UACI, less encryption speed and high Information Entropy. In addition, the method shown to be resistive to differential attacks as well as comprehensive attacks. This framework can be used for real time image encryption and transmission.
