Constructive Steganography Using Texture Synthesis

ABSTRACT This paper proposes a constructive steganography approach using texture synthesis. With a source texture pattern, we first generate a reference pattern using a point-based texture synthesis. The reference pattern is further extended using a patch-based synthesis algorithm. We crop the extended pattern to generate an intermediate pattern. The reference pattern is then divided into overlapping patches. With a secret key, the reference patches are pseudo-randomly painted onto a blank canvas. To hide secret messages, we identify appropriate patches from the intermediate pattern to represent secret bits, and fulfill the blank regions with these patches using image quilting. The proposed method has a better performance than previous works. As we extend the source pattern to generate more candidate patches, more secret bits can be hidden into the stego image, and the quality of the synthesized image is better. Meanwhile, the proposed method has a capability of resisting a specified attack designed for texture synthesis-based steganography.


INTRODUCTION
The word steganography is a Greek word which means the covered writing. Steganography has a long history of over 2500 years since the birth. The earliest record of steganography can be traced back to ancient Greece such as writing messages on a wooden board and then waxing it to hide information. Steganography is a technology that conceals information into digital carriers to realize the covert transmissions [1,2]. Modern research on steganography began with the famous "prisoner's problem" raised by Simmons. Since the late 1990s, steganography technique has attracted much attention of the academia.
Generally, a steganography system includes two parts: messages embedding and messages extraction. A sender uses an embedding algorithm to hide secret messages into a public multimedia to generate a stego, and transmits the stego to a receiver through a public channel. A receiver uses the extraction algorithm to recover the secret messages from the stego. In the past decades, many steganography methods have been proposed to embed information into images. LSB replacement [3] is a common and simple approach to embed information into an image. This algorithm replaces the least significant bits of the image coefficients with the secret bits. F5 is an algorithm that embeds secret information by reducing the absolute value of the DCT coefficient [4], in which the matrix coding and random scrambling are used to embed the secret information evenly into different cells. ZZW proposed a binary coding method by combining matrix coding and wet paper code, which can approach the theoretical bound of data hiding [5]. Filler et al. proposed an STC encoding framework that uses various distortion functions [6]. For a defined distortion function and the secret messages, the STC code can minimize the embedded distortion and enable a receiver extracting the messages without the synchronization distortion information. In these methods, secret messages are hidden into the images by modifying the pixels or coefficient values.
In recent years, a kind of steganography based on texture synthesis has been proposed. Different from the modification-based methods, some new approaches hide information during the procedures of image construction. We name this kind of data hiding as constructive steganography to distinguish it from the modificationbased steganography. Pioneering works were done by Otori and Kuriyama [7,8]. They use the colored dots picked from a texture sample to represent the secret bits. After painting these dots onto a canvas, an image containing secret messages is generated by synthesizing the blank regions. Another constructive steganography algorithm was proposed in [9], in which the hidden messages written on a canvas are deformed to a texture image by a technique of Marbling [10]. In [11], Wu and Wang propose a steganography method using reversible texture synthesis. This method provides a much larger embedding payload than previous works in [7] and [8]. Meanwhile, the extraction error can also be avoided. However, due to the mirror symmetry operations used during texture synthesis, an algorithm was proposed in [12] to combat this steganography. With this adversary method, the steganography behavior can be detected and the secret messages can be extracted. Another constructive steganography was proposed in [13], using texture synthesis to construct a robust data hiding. It is securer than the previous work at the expense of fewer payloads.
In this paper, we propose a new steganography method using texture synthesis. Different from the traditional works, we propose to construct an intermediate texture before data hiding. With the intermediate texture, more candidate patches can be used to carry more secret bits during texture synthesis. The proposed method has three achievements. First, the embedding payload is higher than previous arts. Second, the synthesized texture containing secret messages has a better quality. Third, the proposed approach has the capability of combating the attack proposed in [12]. This paper is organized as follows. In Section 2, we briefly introduce the related works. In Section 3, we detail the proposed method of constructive steganography. Section 4 provides the experimental results. The whole paper is concluded in Section 5.

RELATED WORKS
Texture synthesis is a technology that uses a texture pattern with limited contents to generate a larger sized image with similar appearance. The exemplar-based texture synthesis is a popular idea that resamples the source pattern to produce a synthesized image [14][15][16]. In [14] and [15], pixels in the source pattern are used to propagate the synthesis content. The pixel by pixel algorithm requires a lot of time to synthesize each region. In [16], Efros and Freeman propose a fast synthesis algorithm named "image quilting". This approach constructs the new texture by finding appropriate patches from the source pattern. Accordingly, the neighboring patches are quilted by an optimal cut. An example of texture synthesis using the method in [16] is shown in Figure 1, in which (a) is a source pattern and (b) a synthesized image with a larger size.
Inspired by these methods, some steganography algorithms based on texture synthesis emerge. One representative work was presented by Wu and Wang in [11]. The main idea is to hide secret messages during the procedure of texture synthesis. With a source texture, the data hider first divides the pattern into non-overlapping blocks, which are named as kernels. Each kernel is then expanded into a patch, containing the kernel region and a boundary region. In the process of expansion, the boundary pixels are directly extracted from the source pattern. If a kernel is located at the boundary of the source texture, it should be expanded by mirror symmetry.
The data hider further pastes all kernels onto a blank canvas that is to be synthesized. The pasting positions are identified by a secret key. Next, the data hider uses the algorithm proposed in [16] to synthesize the rest regions in blank. Meanwhile, the secret messages are hidden during the process. He/she divides the source pattern into overlapping blocks using the raster scan. These blocks are used as candidates for synthesis. When synthesizing each blank block, the data hider calculates the mean square error (MSE) of the overlapped region between a candidate and a synthesized patch, and further ranks the MSE values. Accordingly, the index of each candidate is used to represent several bits of the secret messages. Hence, the secret bits can be embedded into the synthesized texture after texture synthesis.
Data extraction is a reverse procedure of the embedding. With the secret key, the receiver first extracts the kernels from the stego image and reconstructs the original texture pattern. Subsequently, the patches and candidates can be divided from the source again. After calculating and indexing the MSE values, the secret bits can be extracted exactly.
The steganography approach in [11] can provide a large embedding capacity. However, there is a security limitation, which was found by Zhou et al. [12]. Since the kernels on the boundary of the source texture are expanded by mirror symmetry, Zhou et al. [12] found that the original texture can be recovered by an adversary even the secret key is not available. After comparing the similarity of an expanded boundary area with an inside boundary area, the adversary can search patches in the synthetic image and identify the patches from the four corners and boundaries of source pattern. Therefore, the boundary patches of original pattern can be recovered by identifying the optimal patch from left to right and top to bottom. Once the adversary padded a ring-shaped boundary of the source image, the remaining patches can be identified and pasted until the full source texture is recovered. Using the same way of data hiding, the adversary can extract the hidden messages.

General Framework
The general framework of the proposed constructive steganography is depicted in Figure 2. The data hider first chooses a small texture pattern P as the source image. This texture pattern is then extended to construct a larger pattern E. The data hider first constructs a reference pattern R, which contains the content of P. The reference pattern is then divided into overlapping patches. With an encryption key K the data hider pseudo-randomly paints these patches onto a blank canvas to generate an initial image I. The data hider further crops some content from the extended pattern E to generate an intermediate pattern C. With the candidate patches from C, the data hider hides the secret message M during the procedure of synthesizing the blank regions on image I. Finally, a stego image S is generated.

Texture Extension
Given a source pattern P, we first construct a reference pattern R by extending the boundaries of P using a pixel-based texture synthesis. Let the size of P be w × h. The original pattern P is extended to a texture pattern sized w × h , where w = w + 2d, h = h + 2d, and d > 0. As shown in Figure 3, the original pattern P is first painted onto the center of the blank canvas.
With the pixel-based synthesis algorithm in [15], we paint the blank region on the canvas. To synthesize each point o on the blank boundary, we choose a block π(o) around this point, in which o is centered at π (o). Next, we find an optimal candidate block π b from the original pattern P using Equation (1), such that the block π(o) is close to the optimal candidate. π b = arg min π c g * d(π (o), π c ).
( 1 )  In Equation (1), g is a Gaussian kernel, "*" the convolution operator, d(·) the function calculating the Euclid distance, and π b the optimal candidate block. The central pixel in π b is then painted onto the position of o. After synthesizing all pixels on the blank region, we obtain a reference pattern R.
We further create a new blank canvas and paint the reference R onto the center of the canvas. Denote the size of the new canvas as w e × h e , where w e and h e are much larger than w and h , respectively. Next, we divide the original pattern P into overlapping patches in raster scan order. Let the sizes of each patch be a × b. Hence, there are m = (w − a + 1)(h − b + 1) patches. We use these patches as candidates for patch-based texture synthesis.
With the block-based synthesis algorithm in [16], we fulfill the blank regions on the new canvas using the candidates. For every location of the blank regions, we search from all m candidates for an optimal one.
For example, when synthesizing the blank region next to a painted block A (the left rectangle), as shown in Figure  4(a), we find a patch B (the right rectangle) from m candidates such that the mean square error of the overlap (MSEO) is the smallest. The MSEO between two patches can be calculated by where A o and B o represent the overlapped regions in A and B, respectively, c stands for the channels red, green, and blue of the overlapped regions, and ||·|| 2 is the L 2 norm operator.
Subsequently, we calculate the cumulative minimum error on the overlap using Equation (1) in [16] to find the minimum cost path, i.e. the boundary cut. This path of the cut is used as the boundary of a new patch, which is then pasted onto the blank region. As the example shown in Figure 4(b), the content in B on the right hand of the boundary cut forms a new patch. After synthesizing all blank regions in the new canvas, we generate the extended pattern E. With an encryption key K, we pseudo-randomly crop a part of contents from E to generate a new pattern C. Using the reference pattern R and the intermediate pattern C, we hide the secret message M during the procedure of synthesizing a new texture image S.

Data Hiding and Extraction
In the proposed method, data hiding is realized during the process of constructing a new texture image. We first divide the reference image R into overlapping reference patches. The division manner is shown in Figure 5. Each reference patch (e.g. the content enclosed by solid lines) contains a kernel (enclosed by dash lines) and a boundary. The boundaries are overlapped with neighbor patches.
Denote the reference patch size as p w × p h , and the overlapping width as b, where b = d. Therefore, there are m r reference patches, where We construct a new blank canvas sized w s × h s , and divide the canvas into overlapping blocks using the same way as Figure 5. The block size is also specified as p w × p h . Accordingly, there are m s 's such blank blocks, where and m s is much larger than m r . With a secret key, all reference patches are then pseudo-randomly painted onto some m r blank blocks on the canvas. As a result, an initial image I is generated.
We also divide the intermediate C into overlapping patches {p 1 , p 2 , . . . , p m } in raster scan order, each of which is also sized p w × p h . Assuming that the size of C is w c × h c , there would be m c such patches, where We use these patches as candidates to paint the m s − m r blank blocks in I, and hide the secret messages during the process.
At each position of the blank block to be synthesized, we calculate MSEO between the painted patch with each one in {p 1 , p 2 , . . . , p m }. Without loss of generality, we suppose there has been a painted block A on I. When painting a blank block next to A, we calculate the MSEO between A and each p i . Denote the maximum MSEO value as where MSEO stands for the MSE of the overlap.
As described in [16], we define an error tolerance δ, where 0 < δ ≤ 1. This parameter is used to generate diverse appearances for different synthesizers. With the parameter, we find l patches {p s(1) , p s (2) , . . . , p s(l) } from These patches are used to represent secret bits. Since there are l candidates, we can hide log 2 l bits when painting the blank block next to A. According to the secret bits to be hidden, we choose the corresponding candidate from {p s(1) , p s(2) , . . . , p s(l) } and fulfill the blank block next to A using the boundary cut-based synthesis algorithm in [16].
In this way, the secret message M is hidden into the stego image S after sequentially synthesizing all blank blocks in I. The synthesis of each blank block is realized by finding the boundary cut on the overlap. Assuming that each blank block on I has l i candidates (i = 1, 2, . . . , m s − m r ), the embedding capacity is therefore equal to After receiving the stego image S, a recipient can extract the hidden message using the shared key K, which is a reverse process of data hiding. With the secret key, the recipient identifies m r reference patches located inside the stego image. With these extracted patches, the recipient reconstructs the reference image R using the way depicted in Figure 5. The image R is slightly different from R on the borders because of image quality during data hiding. However, contents of the kernels in all reference patches do not change during data hiding.
Therefore, the original source texture P can be losslessly recovered.
Using the same algorithm depicted in the last subsection, the recipient can extend P into R and generate the image C. The recipient further divides the C into overlapping blocks {p 1 , p 2 , . . . , p m } in raster scan order. From the stego image S, the recipient also identifies m s − m r patches containing secret messages. For each patch, the recipient generates a category of candidate patches from {p 1 , p 2 , . . . , p m } using the error tolerance δ. Accordingly, the relationships between the secret bits and candidates can be generated. Consequently, the recipient can extract the hidden message from the synthesized patches.

EXPERIMENTAL RESULTS
We have conducted a series of experiments to verify the proposed method. Figure 6 shows an example of experimental results, in which (a) is the original texture pattern sized 128 × 128, and (b) the extended pattern sized 228 × 228 and the intermediate pattern is sized 191 × 191, as shown in Figure 6(c). Figure 6(d) is a 528 × 528 stego image containing 1519 secret bits, in    Figure 7 shows another group of results using the same parameters as Figure 6. The stego image contains 1824 secret bits. Figure 8 shows A smaller MMSEO value represents a better quality of texture synthesis. We also define the embedding rate (bpp, bit-per-patch) as where C e is the amount of hidden bits and n b the number of patches.   [11]. The results show that the proposed method outperforms [11].
With the same embedding rate, the stego image generated by the proposed method has a smaller MMSEO value. Figure 11 provides four groups of experimental results to compare the proposed method with [11]. The original pattern is sized 128 × 128, the extended pattern 228 × 228, the intermediate pattern 191 × 191, and the stego 528 × 528. The results show that the proposed method provides a better payload than [11] when using the same embedding rates.
The parameter δ also impacts the efficiency of data hiding. The embedding capacity is also related to the resolution of the stego image. Table 2 provides a group of results, in   Figure 12: Comparison of embedding capacity with respect to the threshold which we use the original pattern is 128 × 128, the intermediate pattern is 191 × 191, and δ = 0.4. We also use 30 source patterns to implement the data hiding. The results show that the embedding capacity gets higher when the image size is larger.
The size of the intermediate pattern also affects the embedding capacity. We also use 30 images to calculate the average capacity. Figure 12 shows that embedding capacity is higher when the intermediate pattern is larger, when using a fixed parameter δ. While the method in [11] can be attacked by [12] according to the mirror symmetry, the proposed method can resist this attack. We use 4176 synthetic images from Brodatz Texture Database and the same settings as [12] to verify the security of information hiding. Table 3 shows the attacking results using [12], indicating that without the key the source patterns cannot be extracted from each stego using the proposed method. Therefore, an adversary cannot detect the information hiding behavior during texture synthesis.

CONCLUSION
This paper presents a constructive algorithm based on texture synthesis. We extend a source pattern to generate a reference pattern and an intermediate pattern.
With these patterns, a stego image is constructed to carry secret messages. Experimental results show that the proposed method has three achievements, including a higher embedding capacity, the better quality of the synthesized image, and the capability of resisting attacks. In the future works, we will extend the constructive embedding into real images.

DISCLOSURE STATEMENT
No potential conflict of interest was reported by the authors.