Security and Communication Networks

Volume 2017 (2017), Article ID 5397082, 14 pages

https://doi.org/10.1155/2017/5397082

## A Secure Steganographic Algorithm Based on Frequency Domain for the Transmission of Hidden Information

^{1}Department of Basic Sciences, Granma University, Bayamo, Cuba^{2}Departamento de Ciencias Matemáticas y Físicas, Casilla 15 D, Universidad Católica de Temuco, Temuco, Chile

Correspondence should be addressed to A. Soria-Lorente; uc.oc.gdu@lairosa

Received 13 September 2016; Revised 1 December 2016; Accepted 20 December 2016; Published 1 March 2017

Academic Editor: Barbara Masucci

Copyright © 2017 A. Soria-Lorente and S. Berres. This is an open access article distributed under the Creative Commons Attribution License, which permits unrestricted use, distribution, and reproduction in any medium, provided the original work is properly cited.

#### Abstract

This contribution proposes a novel steganographic method based on the compression standard according to the Joint Photographic Expert Group and an Entropy Thresholding technique. The steganographic algorithm uses one public key and one private key to generate a binary sequence of pseudorandom numbers that indicate where the elements of the binary sequence of a secret message will be inserted. The insertion takes eventually place at the first seven AC coefficients in the transformed DCT domain. Before the insertion of the message the image undergoes several transformations. After the insertion the inverse transformations are applied in reverse order to the original transformations. The insertion itself takes only place if an entropy threshold of the corresponding block is satisfied and if the pseudorandom number indicates to do so. The experimental work on the validation of the algorithm consists of the calculation of the peak signal-to-noise ratio (PSNR), the difference and correlation distortion metrics, the histogram analysis, and the relative entropy, comparing the same characteristics for the cover and stego image. The proposed algorithm improves the level of imperceptibility analyzed through the PSNR values. A steganalysis experiment shows that the proposed algorithm is highly resistant against the Chi-square attack.

#### 1. Introduction

##### 1.1. Motivation

Nowadays, there is a risk that confidential information may be acceded by nonauthorized people, being consulted, divulged, modified, destroyed, or sabotaged, affecting its availability and legal access. Evidently, the information that transits through insecure channels can be easily intercepted. Therefore, the use of Cryptography and Steganography plays a significant role in information security management [1].

Cryptography is the science of protecting information by encryption techniques. As cryptography on its own does not hide the fact that a message is secret, to provide this steganography is used.

The ability to protect sensible information from adversaries, especially during their transmission through channels that are opposed to have leaks, is crucial in a world of emerging cyberwar. Nowadays, all electronic communications are being continuously and automatically monitored by both private and state-owned intelligent systems that have an enormous computer power. In particular, every transmission of cipher-text calls the attention of any of these systems and certainly is chosen to be analyzed, among others, by competitors and any sort of opposing forces. The use of electronic transmission media requires a method that calls less attention of the supervisory automatic systems. Modern Steganography offers a level of service that includes privacy, authenticity, integrity, and confidentiality of the transmitted data.

##### 1.2. State of the Art

Steganography is the art of hiding information by impeding the detection of hidden messages [2]. Steganography involves communicating secret data in an appropriate multimedia carrier, like image [3], audio [4], or video files [5]. The media with or without hidden information are called Stego Media and Cover Media, respectively. Thus, the cover image with the secret message embedded is called the stego image.

###### 1.2.1. Embedding Capacity

The performance of steganographic algorithms can be measured by two main criteria, embedding capacity and detectability. Thus, novel steganographic algorithms are expected to increase the image capacity and the encryption strength of the message. The image capacity can be increased by adaptive strategies which decide where to insert best the message. For example, the Pixel-Value Differencing method [6] proposes to embed more data in edged areas than in smooth areas.

In steganography the* embedding capacity* is defined as the maximum number of bits that can be embedded in a given cover image. However, the* steganographic capacity* is the maximum number of bits that can be embedded in a given cover image with a negligible probability of detection by an adversary. Therefore, the embedding capacity is larger than the steganographic capacity [7].

###### 1.2.2. Methods of Embedding Data

There are two common methods of embedding data, which can be classified into two categories, namely, spatial-domain and frequency-domain methods. In the spatial domain method, the secret message is inserted directly into the least significant bit (LSB) of image pixels [8, 9]. In the frequency-domain method [10] the cover image is first transformed from the spatial to a frequency-domain using transformation methods such as discrete cosine transform (DCT) [11, 12], discrete Fourier transform (DFT) [13], or discrete wavelet transform (DWT) [13–15]. Then the secret message is embedded in the transformed coefficients [16], and finally the data are transformed back from the frequency-domain to the spatial domain.

There are different strategies to additionally encrypt hidden steganographic data, like permutation [17] or by a statistical threshold [18]. One should not confuse cryptography with steganography: Cryptography modifies the data to make them incomprehensible, while steganography on its own simply hides them between other data. In many instances the combination of both techniques provide a high level security to the protected information; see, for instance, [3, 19–23].

In this contribution we adopt the two-dimensional discrete cosine transform [11] as the most common frequency domain method used in image processing. For a recent survey on steganography see [24], where our approach can be classified within DCT based steganography. A frequent method that uses the DCT is the Jpeg-Jsteg embedding method [25], where the secret message is embedded in those LSB of the quantized DCT coefficients whose values are not 0, 1, or −1.

###### 1.2.3. Design Principles That Counter Steganalysis

Westfeld [26] introduced the F5 steganographic algorithm, where, instead of replacing the LSB of the quantized DCT coefficients by the secret bits, the absolute value of the coefficients is reduced by 1. Since the F5 algorithm randomly chooses DCT coefficients to embed the secret bits it is strong against the Chi-square attack.

To counter the Chi-square attack, Provos [25, 27] proposed the OutGuess steganographic algorithm. This method embeds data by a similar way as Jpeg-Jsteg, though its embedding capacity is much lower than that of Jpeg-Jsteg.

There are general design principles for less detectable stegosystems [28]. However, some steganalyis concepts are specialized in the detection of data hidden in the least significant bits of a natural image [29]. For recent improvements in LSB steganography approaches see [28, 30].

In [31], Chang et al. presented a new steganography method based upon Joint Photographic Expert-Group (JPEG) and a quantization table modification. In this case, the secret message is first encrypted and then embedded in the 26 coefficients located in the middle-frequency area of the cover image. In [32], Noda et al. proposed two JPEG steganography schemes using a quantization index modulation in DCT domain.

In [33], Wong et al. presented a novel DCT based on a blind Mod4 steganography method for still images. In [34], Chang et al. proposed a lossless and reversible embedding of secret data in each block of DCT coefficients based on the compressed image technique JPEG. In this scheme, two successive zero coefficients of the medium-frequency components in each block are used to hide the secret data. Li and Wang [35] proposed a novel steganographic method, based on JPEG and the Particle Swarm Optimization algorithm. Here, the transformed messages are embedded in the 36 coefficients located in the middle-frequency components of the quantized DCT coefficients of the cover-image.

###### 1.2.4. Embedding Strategies

In [36], Velasco-Bautista et al. present the Entropy Thresholding method, where the secret message is inserted in the DCT domain. In [37], Lin and Shiu suggest a high capacity data hiding scheme, where the secret data are embedded in the middle frequency of the DCT coefficients. Narayana and Prasad [21] introduce two new methods wherein cryptography and steganography are combined to encrypt the secret message that is hidden. In [38], Lin proposes a reversible data hiding method which is based on the DCT of the cover image. The cover image is decomposed into different frequencies, where the secret messages are embedded into the high-frequency parts. Mali et al. propose a novel image steganographic method using a block level Entropy Thresholding technique where the secret message is embedded in the 26 coefficients located in the middle-frequency area of the cover image [16]. Amin et al. present an efficient data hiding technique based on the DCT, where secret bits are embedded in all frequency components of the quantized DCT coefficient [11]. Jaheel and Beiji combine two steganography algorithms, namely, Jpeg-Jsteg and OutGuess algorithms, with the purpose of enhancing a major security level [39]. In [1], Soria et al. propose a new steganographic algorithm in the frequency domain. This method uses a private key of 64 bits that suggest the positions where the secret bits are inserted after applying the Entropy Thresholding method; the experimental analysis accomplishes a comparison of the results with respect to the Entropy Thresholding method proposed by Velasco-Bautista et al. [36].

In the present work, we show an experimental comparison of the proposed method with respect to the two previous methods. All three approaches use the Entropy Thresholding method. The Velasco-Bautista method does not use keys, the Soria method uses a private key of 64 bits, and the proposed method uses two keys, one public key and one private key of 64 bits.

##### 1.3. Transformation of the Blocks

A digital image is represented in computer systems as an array of pixels. In this paper, we work with a steganography algorithm for embedding a secret message into a RGB 24-bit color image, where each pixel has three color components: Red, Green, and Blue (RGB). Each RGB component is represented by a byte. The values range from 0 to 255, where zero represents the darkest and 255 the brightest shade of a color.

Since we consider a RGB 24-bit color image as three blocks of bytes corresponding to each color component, in the proposed method the cover image of size is divided into different blocks of bytes such that the DCT transformation can be performed on each one of them. Here we assume that and are divisible by .

Let be the th block of bytes of the image, with , and let be its two dimensional discrete cosine transform, with . The relationship between and its inverse is given by where for and otherwise. A DCT of a integer matrix becomes a matrix of real numbers. By definition, the coefficient is the DC coefficient (zero frequency) and all others are called the AC coefficients.

##### 1.4. This Contribution

In this paper, two steganography methods are combined, namely, the JPEG steganography method and the Entropy Thresholding technique [36, 39]. This combination allows to hide secret messages in images while maintaining a high visual quality and a low detectability. The JPEG method divides the cover image into nonoverlapping blocks of bytes and then applies the discrete cosine transform with the purpose of hiding the secret message in the DCT domain by modifying certain coefficients located in the low-frequency area of the cover image.

The Entropy Thresholding method decides whether or not to embed the secret message in a certain matrix of order of transformed coefficients, depending on the entropy within that matrix.

#### 2. Determination of Location of Message

In this section we describe how to determine the encrypted random locations where the secret message is inserted. It is assumed that is the length of the binary sequence of the secret message where is a bit containing or . The locations where the secret message is hidden is determined by a pseudorandom sequence defined by We denote by the number of bits of an array of bits which are equal to . We continue to concatenate the pseudorandom sequence as long as we reach a cardinality ; that is, the length of the message is covered.

In the next subsections, first, we describe the generation of 15 subkeys, and then how the subkeys are used to determine a pseudorandom sequence of locations where the secret bits are inserted.

##### 2.1. Creation of 15 Subkeys

There are two types of cryptography techniques, namely, private key and public key cryptography. Public key cryptography is an asymmetric cryptography technique which encrypts the message with a private key and decrypts the message with a public key. Private key cryptography is a symmetric cryptography technique which encrypts and decrypts a message with the same key. The DES (Data Encryption Standard) algorithm [40] is the most widely used symmetric encryption algorithm in the world and its design idea is still used in numerous block ciphers.

In this paper we use steps similar to those developed for the Data Encryption Standard (DES) algorithm to generate subkeys, but we only generate 15 new subkeys of 96 bits, with , using compressions (permutations) of 112 and 96 bits, respectively.

The 128-bit key is permuted according to the following permutation:

42 | 37 | 53 | 51 | 33 | 123 | 128 | 114 |

27 | 107 | 38 | 29 | 74 | 17 | 92 | 64 |

104 | 58 | 45 | 60 | 103 | 23 | 63 | 7 |

85 | 8 | 39 | 117 | 65 | 13 | 2 | 101 |

35 | 124 | 31 | 97 | 44 | 41 | 110 | 25 |

120 | 3 | 105 | 61 | 50 | 70 | 102 | 95 |

113 | 77 | 115 | 59 | 75 | 21 | 48 | 125 |

20 | 47 | 99 | 100 | 90 | 32 | 19 | 9 |

4 | 94 | 68 | 122 | 109 | 89 | 28 | 83 |

111 | 82 | 12 | 54 | 84 | 73 | 14 | 78 |

62 | 88 | 57 | 55 | 79 | 91 | 10 | 121 |

93 | 108 | 98 | 30 | 127 | 87 | 34 | 24 |

49 | 1 | 11 | 40 | 71 | 43 | 80 | 69 |

15 | 119 | 112 | 22 | 52 | 5 | 81 | 67 |

In order to finish, we generate keys of 96 bits, with , by applying the following permutation to each of the concatenated pairs :

44 | 14 | 77 | 49 | 45 | 111 | 68 | 37 |

23 | 47 | 81 | 31 | 32 | 67 | 9 | 12 |

102 | 73 | 69 | 29 | 88 | 3 | 27 | 62 |

75 | 15 | 89 | 34 | 11 | 10 | 97 | 58 |

105 | 104 | 84 | 70 | 5 | 103 | 100 | 78 |

87 | 21 | 83 | 63 | 1 | 71 | 17 | 30 |

65 | 13 | 50 | 4 | 112 | 53 | 41 | 20 |

8 | 109 | 54 | 61 | 38 | 94 | 40 | 80 |

74 | 42 | 55 | 101 | 110 | 79 | 64 | 92 |

22 | 85 | 91 | 107 | 59 | 24 | 35 | 98 |

2 | 33 | 52 | 93 | 99 | 19 | 28 | 51 |

90 | 48 | 43 | 82 | 7 | 95 | 25 | 57 |

In summary, this procedure uses one key of 128 bits, to determine 15 subkeys of 96 bits, which, through the procedure that is described in continuation, generates a pseudorandom sequence that determines the location to insert the secret bits.

##### 2.2. Generation of Pseudorandom Sequence of Locations

Apply the permutation.

41 | 60 | 75 | 61 | 7 | 68 | 77 | 71 |

1 | 87 | 23 | 31 | 87 | 27 | 57 | 87 |

65 | 62 | 5 | 48 | 92 | 24 | 22 | 36 |

93 | 5 | 80 | 10 | 13 | 87 | 7 | 6 |

72 | 85 | 96 | 76 | 63 | 7 | 19 | 9 |

26 | 4 | 66 | 4 | 55 | 42 | 53 | 79 |

86 | 2 | 7 | 64 | 33 | 4 | 39 | 35 |

58 | 54 | 32 | 70 | 77 | 12 | 27 | 34 |

89 | 5 | 15 | 52 | 5 | 46 | 44 | 27 |

56 | 82 | 81 | 73 | 57 | 78 | 43 | 20 |

77 | 59 | 83 | 8 | 45 | 67 | 77 | 77 |

27 | 88 | 77 | 77 | 29 | 40 | 11 | 51 |

94 | 3 | 49 | 14 | 4 | 21 | 14 | 37 |

90 | 47 | 14 | 84 | 38 | 30 | 50 | 91 |

57 | 5 | 87 | 17 | 69 | 5 | 74 | 7 |

77 | 16 | 57 | 28 | 18 | 95 | 25 | 77 |

#### 3. Proposed Algorithm

In this section we propose a new algorithm for steganography. Given a procedure for the determination of the possible locations of the sub-keys (as described in Section 2.2), the algorithm is mainly about the effective insertion of the message according to a threshold. The embedding algorithm has a sandwich structure, where first several transformations are applied subsequently. In the core of the algorithm the secret message is inserted respectively extracted whenever an entropy threshold criterion is satisfied. Finally, inverse transformations are applied in reverse order. See Algorithm 1 for a pseudocode, where the operating mode is switched to embedding or extraction by setting the parameter mode to EMBEDDING or EXTRACTION, respectively.