An Image Steganography Method Hiding Secret Data into Coefficients of Integer Wavelet Transform Using Pixel Value Differencing Approach

The image steganography systems use either the spatial domain or the frequency domain to hide the secret information. The proposed technique uses spatial domain technique to hide secret information in the frequency domain. The cover image is transformed using integer wavelet transform to obtain four subbands: LL, LH,HL, andHH.Then, the PVD approach is used to hide the secret information in the wavelet coefficients of all the four subbands. For improving the security of the hidden information, the proposed method first modifies the difference between two wavelet coefficients of a pair and then uses the modified difference to hide the information.This makes extraction of secret data from the stego image difficult even if the steganography method fails. The result shows that the proposed technique outperforms other PVD based techniques in terms of security of secret information and hiding capacity of cover image.


Introduction
Now a day, it is easy to share the information which is in the form of text, image, audio, or video using the Internet as the communication channel.Since Internet is an open channel of communication, there is always a threat of stealing the information.Therefore, it is becoming more important to adopt security measures so that the information can be protected from being stolen by malicious user.The security measures include cryptography, steganography, and coding.Steganography involves hiding secret information in a multimedia object such as image, audio, or video in such a way that its existence in these documents cannot be noticed.Digital images are preferred for hiding the secret information.It is relatively easy to place information in digital images because of the availability of sufficient redundant area where valuable information could be placed in an imperceptive way.It is possible to use images, either in the spatial domain or in the frequency domain, to hide secret information.In the spatial domain, the pixel values are used for hiding the secret information and, in the frequency domain, the wavelet coefficients are used for hiding the secret information.
The organization of the paper is as follows.A review of necessary background of IWT and PVD based steganography is presented in this section.In Section 2, the proposed method is discussed.In Section 3, the results are discussed while the paper is concluded in Section 4.
In the PVD method, as suggested by Wu et al. [1,2], a gray-valued cover image is partitioned into nonoverlapping blocks composed with two consecutive pixels,   and  +1 .For each block, difference value   is calculated by subtracting   from  +1 .Since the pixel value ranges from 0 to 255, the difference value also ranges from −255 to 255.Therefore, |  | ranges from 0 to 255.The block is in smooth area if the difference value |  | is small; otherwise, it is in sharply edged area.A range table  is designed with  contiguous ranges (  where  = 1, 2, 3, . . ., ) and the table range is from 0 to 255.The lower and upper boundaries of   are denoted by   and   , respectively.Hence,   ∈ [  ,   ].The width   of   is calculated as   =   −  + 1.This width   is used to estimate pair of the block.Thus, in case of failure of the steganography system, it becomes difficult to estimate exact number of bits hidden in each pair of the block.Another level of security for the secret information is introduced by converting the secret information in its gray code form.For each pair in the block, the method converts bits of secret information in the gray code form and then embeds these bits in that pair.Thus, the security of the secret information is improved without involving the overhead of encryption and decryption.Gulve and Joshi [7] have proposed a steganography method to improve the security of the secret data embedded in the image.The cover image is divided in the blocks of 2 × 3 pixels to form five pairs.The location of the common pixel is decided using the image data.For this reason, data of last few rows are used.Since the common pixel is changed randomly based on the image data, it is difficult to extract the secret data from stego image even if the steganography method fails.
Integer wavelet transform maps an integer data set into another integer data set.Calderbank et al. [8] have explained the working of integer wavelet transform.Haar wavelet transform, in its unnormalized version involving pair wise averages and differences, is written as Its inverse is given by Because of division by two, this is not integer transform.The integer version can be built by omitting division by two in  1, and calculating the sum instead of the average.This is called  transform [8].Consider the following example: It is possible to define  1, as above because the sum and difference of two integers are either even or odd.Thus, it is safe to omit last bit of sum since it is similar to last bit of difference.The  transform [8] is invertible and it is given by A different way of writing Haar transform using "lifting" steps leads to natural generalizations.It is possible to write Haar and  transform using lifting schemes [8].
First, compute the difference and, then, use the difference in second step to compute the average: The inverse transform can be calculated in two steps.First, recover the even samples from the average and difference, and recover the odd samples from even and difference [8].It is given by the following equations: It is possible to write integer transform by truncating the division: Lifting can be used to compute the inverse transform.The equations follow from reversing the order and changing the sign of the forward transform [8]: Ramalingam et al. [9] have elaborated the process of separating four subbands using Haar IWT.The first stage IWT is given by where   represents pixels in odd column and   represents pixels in even column.In the next stage, the IWT coefficients are calculated using high pass and low pass filter banks.This process creates four subbands: low-low (LL), low-high (LH), high-low (HL), and high-high (HH).The second stage IWT is given by HH = H odd − H even , where H odd represents H band's odd row, L odd represents L band's odd row, H even represents H band's even row, and L even represents L band's even row [9].Ghasemi et al. [10,11] have proposed a novel steganography scheme based on integer wavelet transform and genetic algorithm.The scheme embeds data in integer wavelet transform coefficients by using a mapping function based on genetic algorithm.The methods use wavelet transform coefficients to embed secret data into the four subbands of two-dimensional wavelet transform.Genetic algorithm is used to find the mapping function.A chromosome is encoded as an array of 64 genes containing permutations 1 to 64 that point to pixel numbers in each block.OPAP is used to minimize the error between cover and stego image.
Xuan et al. [12] have suggested a lossless data hiding method for digital images using integer wavelet transform and threshold embedding technique.CDF (2.2) integer wavelet transform is used to obtain the wavelet coefficients.Histogram modification is applied to prevent possible underflow/overflow of pixel values.A predefined threshold value  is used to embed data in the wavelet coefficients.
El Safy et al. [13] have suggested an adaptive steganographic model which combines adaptive hiding capacity function that hides secret data in the integer wavelet coefficients of the cover image with the optimum pixel adjustment (OPA) algorithm.Histogram modification is applied to prevent possible underflow/overflow of pixel values.The cover image is divided into 8 × 8 nonoverlapping blocks.Each block is transformed using 2D Haar integer wavelet transform to obtain four subbands: LLI, LHI, HLI, and HHI.Hiding capacity of each coefficient is determined and the data is embedded in the coefficients.A pseudorandom number generation function is used to select the wavelet coefficients for increasing the security of the hidden data.The OPA algorithm is applied after embedding secret message to minimize the embedding error.The extraction procedure is a blind process since it requires only the secret key from the receiver.The secret key is used to identify the wavelet coefficients.Secret message bits are extracted from each selected wavelet coefficient.
Archana et al. [14] have proposed a method for hiding secret information in the discrete wavelet transform coefficients using GA and OPAP algorithm to provide optimum hiding capacity.The four subbands LL, HL, LH, and HH are used for hiding the data.Hiding capacity function is modified by using different ranges for k for the LH, HL, and HH subbands where its values range from 1 to 4. The length L of message bits to be hidden in wavelet coefficient is determined by using hiding capacity function.
Al-Asmari et al. [15] have proposed a method using discrete wavelet transform and pixel value differencing approach to hide the information.Using the discrete wavelet transform, the cover image is decomposed to obtain the four subbands (LL, HL, LH, and HH).Then, the LSB method is used to hide secret information in the LL subband by hiding two bits of secret information in each coefficient.The PVD approach is used to hide the information in the remaining three subbands.For hiding the information, two consecutive pixels in the vertical direction are grouped to form a pair.The method gives high performance in terms of capacity, human visual quality, and PSNR.

Proposed Method
The proposed method hides secret information in the gray scale images.It uses spatial domain technique to hide secret information in the frequency domain.In the frequency domain, the image is decomposed into four subbands using integer wavelet transform and then the spatial domain technique is used to hide secret information in the wavelet coefficients of the four subbands.
The cover image is transformed using 2D Haar integer wavelet transform to obtain four subbands: LL, LH, HL, and HH.The proposed method embeds data in the coefficients of four subbands by using the pixel value differencing approach.Figure 2 shows the arrangement of four subbands of the image lena.tiff after transforming it using 2D Harr integer wavelet transform.
A 2D array obtained by arranging the wavelet coefficients of four subbands is shown as follows: The difference operation in Haar transform may cause some of the wavelet coefficients in HL, LH, and HH subbands to have negative values.Since some of the wavelet coefficients have negative values, the 2D array shown in (11) cannot be used for hiding secret information using the pixel value differencing approach.Hence, absolute values are used for the coefficient ) . ( After hiding the secret information in the 2D array shown in (12), inverse wavelet transform is performed to obtain the stego image.To obtain good quality of stego image, the original sign of each wavelet coefficient, as shown in (11), is required.Hence, the 2D array shown in ( 11) is used to create a sign matrix of the size [, ] having elements with values 1 or −1.The sign matrix so created is shown as follows: ( The wavelet coefficients having positive values are represented by 1 whereas wavelet coefficients having negative values are represented by −1 in the sign matrix.

Embedding Process.
For hiding the data in the 2D array, the method suggested by Gulve [4,7] is used.In the method proposed by Chang [3], a block of 2 × 2 pixels is used to form 3 pairs which are then used to hide the secret information.The proposed method uses the block of 2 × 3 wavelet coefficients.The introduction of 2 wavelet coefficients in the 2 × 2 block forms two extra pairs.For a 512 × 512 image, it is possible to form 196608 pairs using the approach suggested by Chang [3] whereas, using the proposed approach, 217600 pairs can be formed.A greater number of pairs provide extra space for hiding the secret information.Thus, the proposed method improves the hiding capacity of the cover image.
The difference between two wavelet coefficients in the pair is used to hide the secret information.If the difference value is directly used to hide the information, it is easy to retrieve the embedded information in case the steganography system fails.To enhance the security of the secret information, the proposed algorithm modifies the difference between the two wavelet coefficients in the pair and this modified difference is used to hide the secret information.This imposes extra layer of security making harder extraction of original secret information from stego image using the difference values directly [4,7].
After embedding   bits of the message in the pair, new difference    is calculated as OD  + , + where  , represents lower boundary of the range  , in the range table  and  represents the decimal equivalent of   message bits hidden in that pair.
Embedding   bits in the pair modifies the values of both the wavelet coefficients in the pair.The new values of wavelet coefficients in each pair are different from their original values.Since new value is assigned to common wavelet coefficient PX 1 in each pair, five different values are obtained for the common wavelet coefficient PX 1 .However, the common wavelet coefficient PX 1 can have only one value in each bock.This requires values of other five wavelet coefficients PX 0 , PX 2 , PX 3 , PX 4 , and PX 5 to be adjusted such that the new difference    remains unchanged.Therefore, the pair, having new values of wavelet coefficients close to their original values, is selected as the reference pair.To find the reference pair, the difference  between   and    is calculated.Small value of || indicates that the new difference value    is close to the original difference value   .Thus, for the pair with minimum ||, the new values of wavelet coefficients are close to their original values.So the pair with minimum || is selected as the reference pair.The values of the two wavelet coefficients in the reference pair are used to adjust the values of wavelet coefficients in other pairs and construct a new 2×3 block.The embedded secret information in newly constructed block is unaffected because difference values for the pairs are unaltered [4,7].
During the extraction process, average value () is calculated using the same process adopted during embedding of the secret message.The average value  is used to calculate the revised difference    as    is remainder (  /2  ).Suitable range  , is identified using this revised difference.The secret message is extracted in the decimal form by subtracting   from |   |.Secret message is then converted into a binary stream with   (  = log 2  , ) bits [4,7].
The process of hiding secret information in the cover image is described below [4,7].
(1) Create the 2D array as shown in ( 12) by preprocessing the gray scale cover image.
(2) Partition the array into nonoverlapping blocks of 2×3 wavelet coefficients and group wavelet coefficient PX 1 with the remaining wavelet coefficients in the block to form five pairs. ( where   and  +1 represent two wavelet coefficients in the pair   and  is obtained by subtracting   from    .( 12) Select the pair with minimum || as the optimal reference pair and use this pair to adjust the values of wavelet coefficients of the other four pairs.The value of the common wavelet coefficient is given by    of the reference pair.Modify value of another wavelet coefficient   +1 of remaining four pairs such that the new difference    will remain unchanged.Thus, new values are assigned to remaining four wavelet coefficients in the block.(13) Check the new values of wavelet coefficients for falloff boundaries; that is, check whether all the values are within the range from 0 to 255.If not, modify the values preserving the difference between the values of two wavelet coefficients of each pair in the block.
(a) Find out the smallest of all the wavelet coefficients.If the smallest is less than 0 then add |smallest| in all the wavelet coefficients in that block.(b) Find out the largest of all the wavelet coefficients.If the largest is greater than 255, subtract largest − 255 from all the wavelet coefficients in that block.(c) If fall-off boundary problems still exist, the cover image is not suitable for hiding secret information.
(14) Now, reconstruct the block from all pairs with modified values of wavelet coefficients.
(15) Repeat steps (2) through ( 14) until the secret information is embedded in the cover image.

Postprocessing.
After the embedding process is over, original signs are assigned to the elements of 2D array using the sign matrix created during preprocessing phase.This is accomplished by one to one comparison of elements of 2D array with the elements of 2D sign matrix.The 2D array is then split to obtain the four subbands.Using inverse 2D Haar integer wavelet transform, the four subbands are combined to obtain the stego image of size [, ].All the pixel values of the stego image in the range from 0 to 255 indicate that secret data is safely hidden and can be extracted accurately.

Extraction Process.
The extraction process is blind.It does not require the existence of cover image for extracting hidden secret data from the stego image.The stego image is preprocessed to obtain the 2D array as shown in (12).The process of extraction of secret information from the stego image is described below [4,7].
(1) Create the 2D array as shown in ( 12) by preprocessing the gray scale stego image.
(2) Partition the array into nonoverlapping blocks of 2 × 3 wavelet coefficients and group wavelet coefficient PX 1 with the remaining wavelet coefficients in the block to form five pairs.Keep the partition order the same as that of the embedding.
(3) Calculate the difference values   for the five pairs in each block: (4) Use |  | where  = 0, 1, 2, 3, 4 to locate suitable range   in the designed range table.Use this range to calculate number of bits,   , which is hidden in each pair   .Then, calculate the average bits using (16).

Results
A set of gray scale TIFF images is used for the experimentation.This set consists of standard images as well as images taken from the camera.The standard images are obtained from the "the USC-SIPI image database (http://sipi.usc.edu/database/)".The images taken from Canon A45 camera  in JPG format are converted into gray scale tiff format.The text files are used as secret data.Since the proposed algorithm use PVD approach to hide information in wavelet coefficients, the data hiding capacity and PSNR values of the proposed method are compared with PVD method [1], TPVD [3] method, and Gulve's method [4].The comparison is shown in Table 1.The proposed method provides increased hiding capacity and improved PSNR values as compared to PVD and TPVD method.Although the PSNR is less as compared to Gulve's [4] method, there is an improvement in the security of secret data.The average payload of the proposed system is ∼2.48 bpp.The performance of the proposed method is analyzed using PSNR, Universal Quality Index (), and Structural Similarity Index Measure (SSIM). and SSIM are full reference image quality assessment models and require the cover image to be available [16,17].Table 2 shows the PSNR values, MSE, Universal Quality Index (), and Structural Similarity Index Measure (SSIM) for different images obtained using proposed method.The PSNR values are above the threshold of 36 dB [18] even after using more than 95% of the hiding capacity of the cover image.Also Universal Quality Index () values [16] and Structural Similarity Index Measure (SSIM) values [17] are close to 1, which proves that the stego images are visually indistinguishable from original cover images.
Figure 4 shows the cover image and the corresponding stego images obtained using the proposed method.As the figures show, distortions resulted from embedding are imperceptible to human vision.
Figure 5 shows the histogram of the cover and stego image obtained using the proposed method.From the figure, it can be observed that the shape of the histogram is preserved.
The cover image data is subtracted from stego image and plotted as histogram.Figure 6 shows the pixel difference histogram.From the figure, it can be observed that there are more numbers of bins which are close to 0 as compared to bins which are away from 0. Also the step pattern is not observed in the figure.This confirms that the method is robust against histogram analysis attack.
Histogram of cover image is represented as [ℎ 0 , ℎ 1 , . . ., ℎ 255 ] whereas histogram of stego image is represented as The change in histogram [19] is measured by The proposed method can hide at least 3 bits in each pair considering the smallest width of the subrange to be 8. Figure 7 shows the comparison of the value of  ℎ of the 3 bit LSB replacement method and the proposed method with different size of secret data embedded in the cover image, Lena.tiff.It can be observed that difference in histogram for the proposed method is less than that of 3 bit LSB method.The output images are tested under the  steganalysis [20].It is observed from Figure 8 that the difference between   and  − and   and  − is very small.The rules   ≅  − and   ≅  − are satisfied for the output images.This proves that the proposed method is secure against  attack.

Conclusion
In steganography, hiding capacity of cover image, quality of stego image, and security of secret data are three important factors.There is always a trade-off between data hiding capacity of cover image and security of secret data.The proposed algorithm provides improvements in the data hiding capacity as well as security of the secret data as compared to PVD [1] and TPVD [3] methods.Although Gulve's [4] method provides better PSNR values as compared to proposed method, the proposed method improves security of secret information.The secret information is securely hidden in the coefficients of integer wavelet transform.For the implementation purpose, the four subbands obtained after decomposing the cover image by integer wavelet transform are arranged as shown in Figure 1.But it is possible to arrange the four subbands in 4! = 24 different ways thereby improving the security of the steganography system since the exact arrangement of four subbands will be known to sender and receiver only.The algorithm revises the original difference between two wavelet coefficients in the pair and this revised difference is used for hiding the data in that pair.This makes estimation of exact number of bits hidden in the pair difficult.Image steganography techniques hiding textual information require 100% accuracy for successful retrieval of hidden information from stego image.If the steganography method fails, correct estimation of number of bits hidden for some of the pairs will be a challenge for the invader.Thus,
with negative values to create a new 2D array with positive elements as follows:

Figure 5 :
Figure 5: Histograms of cover and stego images.

( 4 )
Use |  | where  = 0, 1, 2, 3, 4 to locate suitable range   in the designed range table.Use this range to calculate number of bits   that can be hidden in each pair   .Then, calculate the average bits using Calculate the revised difference |  | where  = 0, 1, 2, 3, 4 as   is remainder (  /2 avg ) so that   <= 2 avg .Compute the number of bits   that can be embedded in each pair using the corresponding range given by   .The value   can be estimated from the width   of   , which is given by   = log 2   where width   =   −  +1 and   and   are upper and lower boundaries of the range   .OD  +  , +   , if   ≥ 0,    = − (OD  +  , +   ) , if   < 0.

( 7 )
After   is located,   is subtracted from |   | and    is obtained in decimal form.A binary sequence is generated from    with   bits where   = log 2   .

Table 1 :
Comparison of hiding capacity (in bytes).