An Improved Image Steganography Scheme with High Visual Image Quality Sumit Laha, Rinita Roy Department of Computer Science and Engineering Future Institute of Engineering and Management Kolkata, India
[email protected],
[email protected] Abstract—With the advent of internet, secured transmission of data over networks offers a great challenge. This problem of secrecy of information has drawn a lot of attention due to its immense demand in real life applications such as information security systems. The objective of this study consist of three-fold. In the first phase, we propose an embedding algorithm to hide a secret image within the cover image. In the second phase, the stego image quality is optimized using GA. Then, in the third phase, we have presented the procedure to extract the secret image from the optimized stego image with 100% data lossless. The experimental results demonstrate that the proposed method significantly outperforms the five state-of-the-art steganography techniques known to date in terms of enhanced peak signal to noise ratio (PSNR) of the stego image. Keywords—Image Steganography; Embedding algorithm; XOR; Genectic Algorithm; 8-connected neighbor; Peak Signal to Noise Ratio
I.
INTRODUCTION
With the development of internet, secured transmission of data over networks provides a great challenge to the researchers and practitioners. This problem of secrecy of information has long drawn a lot of attention due to its immense demand in real life applications such as information security systems and rapid development of communication and network. There are two methods, namely, cryptography and steganography in order to keep the data secret. Cryptography comprises two phases - encryption and decryption of data. However the existence of the data cannot be hidden from the third party. On the other hand, steganography aims to keep the existence of the data (in the format of image, video, audio or text) secret in the cover image [1]. The steganography procedure [2] consists of three important elements: the data to be hidden (here, image), the cover image, and the resulting stego image (after embedding the secret image into the cover file). Two important steganography approaches frequently in the literature, namely spatial domain-based [3-6] and frequency domain-based [7, 8]. In case of spatial domain approach, embedding of data is carried out using Least Significant Bit (LSB) substitution method, whereas in the frequency domain, the data is embedded in the frequency coefficient of images. This paper deals with the problem of embedding of the secret image, optimizing this stego image as close as to the cover image without altering the embedded bits and extracting
978-1-4673-9354-6/15/$31.00 ©2015 IEEE
the original secret image from the stego image. Although there have been several studies on the embedding of secret images, most of them deals with normal LSB substitution. But the LSB substitution approach suffers from certain drawbacks. For example, if a third party tries to read the LSB positions from the stego image, a secret image hidden using this technique can easily be intercepted. Moreover, this method completely replaces the original values in the LSB positions, while substituting the secret image. This results in low visual quality of the stego image as compared to the original cover image. Inspired by this motivation, in this paper, we propose an embedding algorithm to hide a secret image within the cover image. Then, the stego image quality is optimized using GA and finally, we have presented the procedure to extract the secret image from the optimized stego image. As a result, the secret image is obtained with 100% data lossless and also, provides a high visual image quality with respect to the cover image. The remainder of the paper is organized as follows: Section II gives a brief description of a literature review of previous solution methods; Section III presents the proposed embedding technique, GA and the extraction procedure; Section IV provides the experimental results and finally, the conclusions are drawn in Section V. Nomenclature pc ps ip C S MAXI k
cover image pixel stego image pixel initial population array cover image represented as 2D matrix stego image represented as 2D matrix maximum intensity of a pixel, i.e., 255 population size of GA II.
LITERATURE REVIEW
Recently, there have been growing number of research on steganography methods especially, based on soft computing methods like GA and particle swarm optimization in both spatial and frequency domains. In the spatial domain, embedding of message is done by LSB substitution method, whereas in the frequency domain, the message is embedded in the frequency coefficient of images. In this section, we focus
on a review of the previous studies on the steganography methods.
and authentication bit conditions and showed its improved performance compared with the recent steganography schemes.
Kanan and Nazeri [9] presented a novel steganography technique based on GA to obtain high embedding capacity and enhanced PSNR of the stego image. The high embedding capacity is achieved by modifying secret bits and then finding the best place for embedding it into the cover image based on GA.
Yang, Chen, Yu and Wang [18] proposed an improved image secret sharing scheme by hashing the four-pixel block, block ID and image ID to increase the authentication ability and by arranging the bits in the for-pixel square block to improve the stego image and finally, by using the GF (28) to obtain a lossless version without requiring additional pixels.
Roy and Laha [10] proposed a GA to optimize the stego image based on a fitness function using 8-connected neighbor of each pixel. They have shown that the proposed scheme is found to be relatively better than some existing steganography techniques. Li and Wang [11] presented a stenographic scheme to hide data JPEG images securely along with high message capacity and good image quality in two phases. In the first phase, particle swarm optimization algorithm is applied to improve the stego image quality by deriving the optimal substitution matrix for transforming the secret images. In the next phase, the hiding the secret image into the cover image using a modified JPEG quantization table. Tseng, Chan, Ho and Chu [12] proposed an effective steganography scheme to enhance the quality of stego image by using an improved GA and optimal pixel adjustment process. The experimental results show that the mean square error of the stego image of the proposed scheme is much lower than those produced by the existing methods.
III.
PROPOSED WORK
In this section the proposed work comprises three phases. The first phase deals with a new embedding algorithm to hide the secret image, the second phase addresses the proposed GA that uses a heuristic approach to find superior solution and the third phase provides the extraction algorithm and these are presented in subsequent sections. A. Embedding of data In this section, we have proposed a new embedding technique to hide the secret image. In the conventional LSB substitution method, the LSBs of the cover image are just replaced with the bits of the secret image. But there is a flaw in terms of security. If an intruder scans the LSBs, he can easily intercept the secret image. Furthermore, this approach yields low PSNR values.
Wang, Lin and Lin [13] developed a steganography method based on GA to embed the secret message in the moderately significant bit of the cover image. They also applied a global substitution step and a local pixel adjustment process for improvement of the quality of the stego image. Later, in another research work, Wang, Lin and Lin [14] proposed optimal LSB substitution to embed the data secret in the host image. They also proposed GA to the data hiding problem in the k LSBs of the host image. Recently, there have been some noteworthy studies in connection with the development of image sharing scheme with steganography and authentication ability to protect the integrity stego images from dishonest participants [15-18]. Lin and Tsai [15] proposed a technique for the secret image sharing by applying Shamir method. Their proposed scheme consists of three levels of security protection, namely, sharing the secret among the participants, embedding the data hiding, and authentication capability, resulting in high security and efficiency of the system. Chang, Hsieh and Lin [16] developed a novel image sharing scheme considering both steganography and authentication based on Chinese remainder theorem. The performance of this scheme is shown to be superior to the existing methods in respect of both high authentication ability and good stego image quality. Wu and Kao [17] presented a secret image sharing scheme by employing optimal pixel adjustment process to obtain enhanced stego image quality under different payload capacity
Fig. 1. Embedding of secret image into cover image.
So a new approach has been proposed, where instead of simply substituting the secret image bits, XOR operation is performed between the cover image bits and the secret image bits. This is illustrated in Fig. 1. The proposed algorithm (considering 2 bits per pixel for embedding secret bits) is given as follows: Input: Cover and secret grey scale images of sizes m×m and n×n, respectively, where n ≤ m/2 Output: Stego image of size m×m Step 1: Read the cover and secret image files. Step 2: 2 bits from the MSB side of first pixel of the secret image are taken and XOR-ed respectively with the 6th and 7th bit of the each pixel of the cover image and the results are copied into the 6th and 7th bit positions of the corresponding pixel of the stego image. Step 3: Step 2 is repeated for all the pixels of the secret image, taking 2 bits at a time of the pixel of the secret image. Step 4: Write the output stego into the output file.
The proposed approach has proved to be better than normal LSB substitution. Since the embedded bit positions of the stego image does not contain real values of secret image, it is difficult to intercept the secret message. In order to extract the secret image, the original cover image is needed. This is explained further in subsection C. Furthermore, the PSNR value of the stego image obtained is also higher. B. Optimization using GA Genetic algorithms (GAs) originally developed by John Holland [19] are robust structured stochastic global search algorithm based on biologically inspired computational intelligence that have been employed to a wide range of problems in the areas of science, engineering, business and other fields [20-23]. These algorithms can be successfully applied for generating efficient solutions from large, complex and multi-modal search space. While implementing GA for solving a particular problem, one has to amend the coding of the solution in the search space along with the appropriate tuning of parameters pertaining to GA to make use of the problem specific available information effectively. The important components of GA consists of an initial population of candidate solutions (chromosomes), selection of new population based on a suitable fitness function, recombination based on the genetic operator as crossover and randomly perturbation of candidate solution using mutation operator. The GA is repeated in subsequent generations until it reaches the maximum number of generations as the stopping criterion. While applying the selection operator, it attempts to evolve good quality solutions based on the fitness function and also picking some inferior quality solutions so that the diversity of the solution quality in the population is retained. In this paper, we present a modification of the GA [10]. In the proposed GA, initial population, fitness function, selection, crossover, mutation, evaluation and termination are described as follows. 1) Initial Population We select each pixel of the stego image (say, ps) individually and ps is optimized using GA. Let pc represent the corresponding pixel (having the same coordinates as ps) of the cover image. The population size is taken as 30. It is generated based on 20% of the individuals using heuristic approach and 80% of the individuals randomly. In the proposed GA, for the heuristic initialization part, we take the embedded pixel, and flip the i) 2nd -7th bits, ii) 2nd - 6th bits, iii) 2nd – 5th bits, iv) 2nd – 4th bits, v) 2nd and 3rd bits, and vi) 2nd bit respectively, so as to obtain the six individuals of the initial population. In order to illustrate the heuristic consider a pixel (say, 186). The binary equivalent of this pixel is 10111010. The six most significant bits are flipped to obtain 01000110 (decimal equivalent being 70) as the first candidate solution of the initial population. Similarly, 198, 134, 166, 182 and 190 become rest of the population generated from the heuristic initialization. This is illustrated in Fig. 2.
Fig. 2. Heuristic Initialization for a single pixel.
Similarly, in the random initialization phase, the remaining part of the initial population is generated randomly using random permutation from the entire range of possible solutions (0 – 255), while retaining the embedding in the two LSBs unaltered. The solutions generated are unique from the solutions obtained heuristically in the initial population. 2) Fitness Function and Selection In this GA, the fitness function based on 8-connected PSNR [10] is obtained from the following equations: ⎡ x +1 y +1 2⎤ 2 2 mse '(k ) = ⎢ ∑ ∑ {C (i, j ) − S (i, j )} − {C (x, y) − S (x, y)} + {C (x, y) − i p (k)} ⎥ / 9 ⎣i = x −1 j = y −1 ⎦
⎛ MAX I 2 ⎞ psnr '(k ) = 10 log10 ⎜ ⎟ ⎝ mse '(k ) ⎠
(1)
(2)
Using Equation (1), we compute the MSE of the stegoimage for each of the solutions in the population with respect to the corresponding pixel of the cover image. Next ewe compute the fitness values in terms of PSNR from Equation (2). Based on the above fitness function, roulette wheel selection is used to choose two parents from the initial population. 3) Crossover and Mutation In this study, the one-point crossover operator is employed to combine good portions of different individuals to generate diverse solutions. Depending on the crossover probability, it is decided whether new offspring will be generated or not. Selection of the random crossover point and swapping of bits on either side is done without altering the embedded bits. In mutation, mutation probability is used to have diverse solution so that local optimum does not get stuck. Unlike crossover probability, the mutation probability is set very low value. The mutation operator used in the proposed GA randomly swaps 2 bits excluding the embedded bits. 4) Evaluation and Termination In each generation evaluation is performed by updating the best-so-far solution amongst the two offspring and the best-sofar solution obtained from the previous generation. The termination criterion is reached after executing a predefined number of generations. At the end of the GA, we obtain the optimized value for each pixel from the best-so-far array.
C. Extraction of secret image As explained in subsection A, the stego image contains the secret image in encrypted form. So in order to extract the secret image, the original cover image is required. The extraction procedure is same as the embedding one. This is illustrated in Fig. 3.
Fig. 5. Histogram of Stego Lena image (simple LSB embedding).
Fig. 3. Extraction of secret image from stego image.
Once again XOR operation is performed individually between the stego and cover image bits respectively. The extraction algorithm is given as follows: Input: Optimized stego and cover gray scale images of sizes m×m each. Output: Secret grey scale image of size n×n. Step 1: Read the optimized stego image and the cover image files. Step 2: The 6th and 7th bits of each pixel of the stego image is XOR-ed with that of the corresponding bits of the cover and the two resultant bits are kept in the output array. Step 3: Step 2 is repeated for all the pixels of the stego image so as to get the all the pixels of the secret image. Step 4: Write the output array into the output file.
IV.
Fig. 6. Histogram of Stego Lena image (XOR embedding).
In simple LSB embedding, PSNR is 43.797 and that in case of XOR embedding is 45.076. It is evident from the experimental results that the new embedding approach not only ensures security of secret data, but also guarantees better visual quality (high PSNR value) with respect to the cover image. B. Proposed Genetic Algorithm In this study, we have taken three 512×512 standard gray scale images (8-bits per pixel), “Lena”, “Jet”, “Pepper”, “Sailboat” and “Baboon” as cover images as shown in Fig. 7. The secret message is a 256×256 gray scale “General test pattern” image in each case. The program was implemented using C running on 2.3 GHz i3 core processor under Windows 7.
EXPERIMENTAL RESULTS
A. Embedding Algorithm To explain the effectiveness of the new embedding technique, an experiment has been carried out. A 512×512 grayscale “Lena” image and a 256×256 “General test pattern” is taken as cover and secret images respectively. Fig. 4 represents the histogram of the original “Lena” image, while Fig. 5 and Fig. 6 represent that of the stego images.
a
b
c
d
e
f
Fig. 7. Secret image – (a) General test pattern; Cover images – (b) Lena, (c) Jet, (d) Peppers, (e) Sailboat, (f) Baboon.
MSE = Fig. 4. Histogram of original Lena image.
1 m −1 n −1 2 ∑∑ {C (i, j ) − S (i, j )} mn i = 0 j = 0
(3)
⎛ MAX I 2 ⎞ PSNR = 10 log10 ⎜ ⎟ ⎝ MSE ⎠
(4)
The comparisons of the above methods are done on the basis of the PSNR values (from equations (3) and (4)) of the optimized images obtained by applying the proposed GA with respect to the corresponding cover images. The GA parameters has been summarized in table 1. TABLE I.
GA PARAMETERS
Parameter
Value
Number of generations
100
Population size
30
Crossover rate
0.9
Mutation rate
0.05
ACKNOWLEDGMENT We are grateful to Professor Amrita Khamrui for her helpful comments and suggestions in writing this paper.
REFERENCES
Table 2 compares the PSNR values of different grey scale images for the proposed method as against the Lin and Tsai’s method [15], Yang, Chen, Yu and Wang’s method [18], Chang, Hsieh and Lin’s method [16], Wu and Kao’s method [17] and Kanan and Nazeri’s method [9]. TABLE II.
Methods
There are some issues important for future research consideration. First, an attempt can be made to develop better embedding algorithm that can produce high visual quality while keeping the secret message intact. Second, as an alternative to the existing soft computing algorithm, other algorithms such as cuckoo search algorithm and bacteria foraging optimization algorithm can be implemented to obtain accurate modeling of steganography. Finally, the proposed scheme can also be tried for color images.
[1]
[2]
[3]
COMPARISON OF PROPOSED METHOD WITH DIFFERENT STEGANOGRAPHY TECHNIQUES [4]
Images
Avg.
Lena
Jet
Peppers
Sailboat
Baboon
39.2
39.25
39.17
39.16
39.18
39.19
40.37
40.73
39.3
38.86
39.94
39.84
41.6
41.66
41.56
41.51
41.55
41.58
43.54
43.53
43.56
43.55
43.54
43.54
45.12
45.18
45.13
45.1
45.12
45.13
47.03
47.037
47.033
47.039
47.029
47.034
[8]
It is revealed from the results of Table 2 that the proposed method yields average PSNR value of 47.034 which is considerably higher in comparison with those produced by all other algorithms.
[9]
Lin and Tsai [15] Chang, Hsieh and Lin [16] Yang, Chen, Yu and Wang [18] Wu and Kao [17] Kanan and Nazeri [9] Proposed method
[5]
[6]
V.
CONCLUSIONS
In this paper, the problem of steganography is considered to optimize the stego image close to the cover image without affecting the secret image embedded within it. We proposed an embedding algorithm to hide a secret image within the cover image and then, the stego image quality is optimized using GA. Finally, we have presented the procedure to extract the secret image from the optimized stego image with 100% data lossless. The proposed scheme optimizes some benchmark images taken from USC-SIPI image database to get images with higher PSNRs and these PSNRs are greater than those produced by the existing algorithms.
[7]
[10]
[11]
[12]
[13]
[14]
A. Cheddad, J. Condell, K. Curran, and P. McKevitt, “Digital image steganography: Survey and analysis of current methods,” Signal Processing, vol. 90, pp. 727-752, 2010. L.M. Marvel, C.G. Boncelet, and C.T. Retter, “Spread spectrum image steganography,” IEEE Trans. Image Process, vol. 8, pp. 1075-1083, 1999. H. Sajedi, and M. Jamzad, “BSS: Boosted steganography scheme with cover image processing,” Expert Systems with Applications, vol. 37, pp. 7703-7710, 2010. W.-J. Chen, C.-C. Chang, and T. Le, “High payload steganography mechanism using hybrid edge detector,” Expert Systems with Applications, vol. 37, pp. 3292-3301, 2010. A. Ioannidou, S.T. Halkidis, and G. Stephanides, “A novel technique for image steganography based on a high payload method and edge detection,” Expert Systems with Applications, vol. 39, pp. 11517-11524, 2012. B.E. Carvajal-Gamez, F.J. Gallegos-Funes, and A.J. Rosales-Silva, “Color local complexity estimation based steganographic (CLCES) method,” Expert Systems with Applications, vol. 40, pp. 1132-1142, 2013. W.-Y. Chen, “Color image steganography scheme using DFT, SPIHT codec, and modified differential phase – shift keying techniques,” Applied Mathematics and Computation, vol. 196, pp. 40-54, 2008. R. Jafari, D. Ziou, and M.M. Rashidi, “Increasing image compression rate using steganography,” Expert Systems with Applications, vol. 40, pp. 6918-6927, 2013. H.R. Kanan, and B. Nazeri, “A novel image steganography scheme with high embedding capacity and tunable visual image quality based on a genetic algorithm,” Expert Systems with Applications, vol. 41, pp. 6123–6130, 2014. R. Roy, and S. Laha, “Optimization of Stego Image Retaining Secret Information Using Genetic Algorithm with 8-connected PSNR,” Procedia Computer Science, vol. 60, pp. 468-477, 2015. X. Li, and J. Wang, “A steganographic method based upon JPEG and particle swarm optimization algorithm,” Information Sciences, vol. 177, pp. 3099–3109, 2007. L.-Y. Tseng, Y.-K. Chan, Y.-A. Ho, and Y.-P. Chu, “Image hiding with an improved genetic algorithm and an optimal pixel adjustment process,” In Intelligent Systems Design and Applications, ISDA'08. Eighth International Conference on, IEEE, vol. 3, pp. 320-325, 2008. R.Z. Wang, C.F. Lin, and J.C. Lin, “Hiding data in images by optimal moderately significant-bit replacement,” IEEE Electronics Letters, vol. 36, pp. 2069-2070, 2000. R.Z. Wang, C.F. Lin, and J.C. Lin, “Image hiding by optimal LSB substitution and genetic algorithm,” Pattern Recognition, vol. 34, pp. 671-683, 2001.
[15] C.-C. Lin, and W.-H. Tsai, “Secret image sharing with steganography and authentication,” The Journal of Systems and Software, vol. 73, pp. 405-414, 2004. [16] C.-C. Chang, Y.-P. Hsieh, and C.-H. Lin, “Sharing secrets in stego images with authentication,” Pattern Recognition, vol. 41, pp. 31303137, 2008. [17] C.-C. Wu, S.-J. Kao, and M.-S. Hwang, “A high quality sharing with steganography and adaptive authentication scheme,” The Journal of Systems and Software, vol. 84, pp. 2196-2207, 2011. [18] C.-N. Yang, T.-S. Chen, K.H. Yu, and C.-C. Wang, “Improvements of image sharing with steganography and authentication,” The Journal of Systems and Software, vol. 80, pp. 1070-1076, 2007. [19] J. Holland, “Adaptation in natural and artificial systems: an introductory analysis with applications in biology, control, and artificial intelligence,” Ann Arbor, MI: University of Michigan Press, 1975.
[20] D.E. Goldberg, “Genetic algorithms in search, optimization and machine learning,” Addison-Wesley Longman Publishing Co., Inc., Boston, MA, 1989. [21] M. Gen, and R. Cheng, “Genetic algorithms and engineering design,” NY: John Wiley & Sons, 1997. [22] T.D. Gwiazda, “Genetic algorithms reference. Crossover for singleobjective numerical optimization problems (Vol I),” Berlin: Springer; 2006. [23] T.D. Gwiazda, “Genetic algorithms reference. Mutation operator for single-objective numerical optimization problems (Vol II),” Lomianki, Poland: Tomasz Gwiazda, 2007.