Images Steganography using Pixel Value Difference and Histogram Analysis
-
Upload
northeastern-university -
Category
Technology
-
view
244 -
download
0
Transcript of Images Steganography using Pixel Value Difference and Histogram Analysis
1
Images Steganography using Pixel Value
Difference and Histogram Analysis
A PROJECT REPORT
Submitted in partial fulfillment of the
Requirement for the award of the
Degree of
BACHELOR OF TECHNOLOGY
In
ELECTRONICS AND COMMUNICATION ENGINEERING
By
SHIVAM NEGI (11BEC0240) AND RITIZ JAAT(11BEC0421)
Under the Guidance of
DR.THANIKAISELVAN V. (Associate professor, VIT)
SCHOOL OF ELECTRONICS ENGINEERING
VIT University
VELLORE. (TN) 632014
WINTER 2015
2
CERTIFICATE
This is to certify that the Project work titled “Images Steganography using Pixel Value
Difference and Histogram Analysis” that is being submitted by SHIVAM NEGI (11BEC0240)
AND RITIZ JAAT(11BEC0421) is in partial fulfillment of the requirements for the award of
Bachelor of Technology, is a record of bonafide work done under my guidance. The contents of this Project work, in full or in parts, have neither been taken from any other source nor have been
submitted to any other Institute or University for award of any degree or diploma and the same is certified.
Dr. Thanikaiselvan V.
Guide
The thesis is satisfactory / unsatisfactory
I n t e r n a l E x a m i n e r E x t e r n a l E x a m i n e r
Approved by
Program Chair
3
ACKNOWLEDGEMENTS
I express the deepest gratitude to our chancellor, Dr.G.Viswanathan for providing excellent
infrastructure and lab facilities.
I are very grateful to our dean, Dr. Ramachandra Reddy, SENSE for his unwavering support
during the entire course of this project. I are deeply indebted to him for providing virtuous lab
environment in Embedded and Networking division which was helpful to attain practical
knowledge.
I are very thankful to our Program chair, Assistant Dean, Dr. P. Arulmozhivarman , SENSE
for his kind support during the entire course of this project.
I wish to thank my guide Dr. Thanikaiselvan V. , Sr. Associate Professor for his exemplary
guidance, immense help, motivation and guidance throughout the tenure of my project in spite of
his hectic schedule, which truly remained driving spirit in my project and their experience helped
me in clarifying abstruse concepts and in understanding the objective of my project.
I would also like to thank VIT University for giving us the opportunity to do this thesis work.
Finally, I take this opportunity to extend our deep appreciation to our family members and
friends, for all that they meant to us during the crucial times of the course of our project .
4
Table of Contents
List of Figures
List of Tables
1. Introduction
1.1 Introduction to Steganography
1.2 Need of Information Security
1.3 Image Stegnography
1.4 Steaganalysis
1.5 Data Security and Its need
1.6 Advantages and Disadvantages
2. Literature Review
3. Related Work
5
Abstract
A new data hiding method is proposed in this project , which can increase the
steganographic security of a data hiding scheme .In this method a cover image is first
mapped into a 1D pixels sequence by Hilbert filling curve and then it has been divided
into non-overlapping embedding units .The division is made such that it gives two
consecutive pixel values .As human eye has limited tolerance when it comes to texture
and edge areas than in smooth areas , and as the difference between the pixel pairs in those
areas are larger , therefore the method exploites pixel value difference (PVD) to solve out
overflow underflow problem .
The digits in any bases can be embedded according to the local complexity of the cover
image and through this way it solves the problems which are faced by existent EMD
method . Overflow, Underflow or falling-off boundary problem can be reduced by this
proposed method henceforth solves the detectable artifacts caused by them . The
experimental results show our method not only to enhance embedding rate but also keep
stego image quality .
6
Chapter 1
Introduction
With the change in the world and advent of digital media , there are new methods which
are evolved and adopted for communication . The advancement in the digital world lead to
increase in the requirement of digital security and protection of digital data . As the time
progressed it has been observed that digital media and information/data transfer suffered a
lot from the lack of digital security through cyber attacks , hacking and became prey to
cyber crimes . Criminals and technicians developed softwares which can hack into other’s
system and can extract information through that .On the other hand many of the methods
are also invented to make the network secure and prevent these type of hacking .
Among many of the things which are invented , it has been been observed that
stegnography and cryptography are one of the finest and easiest method which can be used
for protection of digital data .It has also been detected that , both of them work together to
maximize the protection level or security of the data compared to the cases when they are
used solely .Cryptography , basically scramble the data and twist the data in such a way
that it gets turned into a cryptic message . While stegnography do the hiding of digital data
, the cryptography make it impossible to decrypt and get the original value of the message
.
A detailed description of steganography , cryptography and steganalysis is given and their
necessity for security purposes are given below :
7
1.1 Introduction to Steganography :
In greek , the word “ Stego “ stands for “ roof “ or “ covered/hidden “ and “graphia “
means writing . So the literal meaning of steganography is hiding a data in another data ,
message or information . The cover may be in the form of any other digital image , video
or audio and this is an ancient method which is dated back to ancient roman times where a
message is concealed in several other cover equipments just to hide that and make it
undetectable .In some of the cases the messages are tattooed on the heads of the
messenger and then the hairs of the messenger are allowed to grow so as to conceal the
message .
Over the years vast range of stegnography methods have been used which have been
proven successful and failure according to their ability to hold and concele the message .
A lot of research is still going on to develop more security and reduce the detectability of
the concealed message .In the same direction , the computers and networks use several
methods to hide data . Some of these include , hiding text within the web pages , hiding
data in plain pages , using ciphers and encrypted messages to conceal more complicated
single message which may contain the direction to find out the real hidden message in a
cryptic way .Therefore in modern times , a large amount of data is stored in images and a
lot of efforts are put in to increase the capacity of data hiding in various available covers .
Protection against detection can be needed if someone wants to ensure that the embedded
message is not detected by a third unauthorized party. For example, a user wants to
prevent others from finding out that an image contains a secret message hidden by the
"Least-bit insertion method". This aim of data hiding is achieved by using schemes that do
not modify the original object in a visible way; all changes should be indiscernible to the
human eye or the computer. Protection against removal, on the other hand, tries to prevent
the removal of hidden data without making it useless or degrading its quality. There are
8
many types of steganography methods that support almost all the digital file formats. The
high degrees of redundancy formats are most suitable for this type of techniques.
Redundancy can be defined as the bits of an object that provide accuracy far greater than
necessary for the object’s use and display .
In this project we are focusing on the image steganography where a secret message is
concealed in the cover image . The secret message is generally converted into its numeric
form and then its then embedded into the pixels of cover image via various existing
methods like LSB substitution , histogram shifting , pixel differentiation etc .
At the present time, the Internet has turn out to be a public communication channel.
Exchange of data / information in public system means that some complications need to
be confronted, which include data security and protection of copy writes. Ciphering is a
well-known method for security protection, but it has the drawbacks of making a message
incomprehensible and therefore attracts the attention of observers and hackers . And this is
one of the biggest difference which helps steganography to become one of the best
method for data transfer secretly and securely.
1.2 Need Of Information Security
In modern times , technology security is one of the biggest concern . As the cyber crime is
on rise , not only a secured network is needed but also it is necessary to provide security to
images like blue print of company projects and their product designs , confidential data
and images related to army or country’s security , using image stegnography .As the
messeges are encrypted by several algorithms , its difficult to find them in the image .
9
1.3 Image Steganography
When the principles of steganography are applied over the images for getting an output
which have data/ information concealed in them , then its called image steganography
.Here the data is hidden in the form of text in the images which generally camouflage the
secret data .
10
1.4 Data Security and Its need
Data security means protecting data and any important information, from negative forces
and from the undesirable actions of unauthorized users and hackers .As the society
evolved and advanced , we started depending more and more on the digital way of
communication and transfer of data . As this methods are really prevalent in our technical
and modern ecosystem , it calls for a more secure and accountable way for these
communication methods . Cryptography is generally used for protection of password ,
banking information , emails and other information of sensitive nature .And henceforth ,
cryptography helps the government to protect these types of information from getting in
the hands of enemies .
Many of the terrorist organizations as well as security agencies use this method to hide the
data to communicate confidentially .This include use of local media or internet to send the
information in cryptic manner .Steagnography can be misused and therefore the process
of steaganalysis has been brought to curb the growing use of such methods for detecting
information which has been sent by such terrorist organizations .
11
1.5 Steganalysis
It has been observed that , digital watermarking and the steganography are one of the most
secure method for digital data communication . This has led to development of methods
which can find out the digital data which is hidden in the audio or image or video
.Steganalysis is one of the method which has played an important role in detection if such
hidden data which has been sent using steganography .As terrorists or other criminal
organization use this method to have their covert exchange of data and even for
communication purpose , the method of steganalysis is used to detect and extract the
hidden messages from the cover .
In the method of steganalysis it is priory assumed that , the data is hidden in the images
and the entire method is designed on the basis of theory of statistics .The process works in
such a way that it narrows down to file which has hidden data from the original set of files
. Due to abundant amount of images and a large variety of encoding algorithms ,
steaganalysis is a challenge .An algorithm named general steaganalysis method don’t
depend on cover image or the encoding algorithm type , thus many obstacles incurred in
obtaining the original cover image and the method used are avoided .
1.6 Data hiding techniques
Lossless data hiding techniques is a method of compressing data in a way such that the
original data is retrieved without any data loss. The image obtained is the exact replica of
the original image. The quality of the data that is compressed is not degraded and the
exact data is obtained without any loss. Lossless compression methods may be categorized
according to the type of data they are designed to compress. Some main types of targets
for compression algorithms are text, executables, images, and sound. Whilst, in principle,
any general-purpose lossless compression algorithm (general-purpose means that they can
handle all binary input) can be used on any type of data, many are unable to achieve
12
significant compression on data that is not of the form that they are designed to deal with.
Sound data, for instance, cannot be compressed well with conventional text compression
algorithms. Most lossless compression programs use two different kinds of algorithms:
one which generates a statistical model for the input data, and another which maps the
input data to bit strings using this model in such a way that "probable" (e.g. frequently
encountered) data will produce shorter output than "improbable" data. Often, only the
former algorithm is named, while the second is implied (through common use,
standardization etc.) or unspecified.
1.6.1 Advantages of Steganography :
1. It is robust method .
2. It provide a secret and safe method for transmission of data .
3. As the file show no physical change after steganography , it go undetected .
4. The method is also used in holding the digital data in images , not discreetly but
purposely and is being used in medical technology to
5. It has larger data hiding capacity .
13
1.6.2 Disadvantages of Steagnography :
1. Staganalysis can be used to extract the data and it gets easy when the image is
subjected to staganalysis attacks .
2. The extracted data can be easily be understood as the data is not be in the cryptic
form and the important information which is supposed to be hidden can be easily
perceived by the person who checks that .
3. Message is hard to recover if image is subject to attack such as translation and
rotation.
4. Significant damage to picture appearance. Message difficult to recover.
5. Image is distorted. Message easily lost if picture subject to compression such as
JPEG.
HUMAN VISUAL SYSTEM MODEL
To balance transparency and robustness, an effective watermarking scheme should exploit
HVS masking characteristics. Here, the luminance masking, texture masking and edge
masking features of the cover image was used to develop a spatial HVS model in a better
way.
PEAK SIGNAL TO NOISE RATIO
The word peak signal-to-noise ratio (PSNR) is an expression for the ratio between the
maximum possible value (power) of a signal and the power of distorting noise that affects
the quality of its representation. As many signals have a very wide dynamic range, (ratio
between the largest and smallest possible values of a changeable quantity) the PSNR is
usually expressed in terms of the logarithmic decibel scale.
14
Improving the visual value of a digital image can be subjective and telling that one
particular method provides a better quality image could vary from person to person. For
this reason, it is necessary to establish quantitative/empirical measures to compare the
effects of image enhancement techniques on image quality.
Different image enhancement algorithms can be compared systematically to identify
whether a particular algorithm produces better results. If we can show that an algorithm
or set of algorithms can enhance a degraded known image to more closely resemble the
original, then we can more accurately conclude that it is a better algorithm.
The mathematical representation of the PSNR is as follows:
where the MSE (Mean Squared Error) is:
This can also be represented in a text based format as:
MSE = (1/(m*n))*sum(sum((f-g).^2))
PSNR = 20*log(max(max(f)))/((MSE)^0.5)
Legend:
f represents the matrix data of our original image g represents the matrix data of our degraded image in question
m represents the numbers of rows of pixels of the images and i represents the index of that row
n represents the number of columns of pixels of the image and j represents the index of that column
MAXf is the maximum signal value that exists in our original “known to be good” image
15
Basically , the MSE represents the average of the squares of the "errors" between actual image and the noisy image. The mean squared error (MSE) for our practical purposes
allows us to compare the “true” pixel values of our original image to our degraded image. The error is the amount by which the values of the original image differ from the degraded
image.
The target is to achieve higher PSNR, for that , the better degraded image has been reconstructed to match the original . This would occur because the objective is to
minimize the MSE between images with respect the maximum signal value of the image.
It has been derived that:
• a lower value for MSE means less error, and as considered in Eq , the inverse
relationship between the MSE and PSNR translates to a high value of PSNR.
• higher value of PSNR is good and signifies that the ratio of signal-to-noise is higher
.
16
Literature Review
As explained above , steganography is the art of hiding digital data into an image , various
techniques have been employed to achieve the same . Logically , it can be said that ,
embedding of data may lead to noise in the output results and may distort the pixel value
of existing image .As this slight change will not be perceivable by human eye , it makes
steganography one of the most powerful tool for this purpose.
1.Chin-Chen Chang, The Duc Kieu and Wen-Chuan Wu implemented a lossless data
embedding technique by joint neighboring coding.The proposed method presents new
reversible information hiding method for vector quantization (VQ) and used joint
neighboring coding (JNC) technique over a compressed grey scale image . This way ,in
this method , the data is successfully embedded secretly by using the difference of current
VQ- Compressed index and upper neighboring indices .It has been found that , the
proposed method achieves the best visual quality reconstructed image when it is compared
with the two related work .
The time duration for execution of this method is also limited to make it one of the fastest
method and only Yang et Al’s method is above it when it comes to speed , followed by
the Lin and Chang’s method . But this method is having the higher bit rate as compared to
the other method . The experimental fallouts show that the proposed method of Chin-Chen
Chang, The Duc Kieu and Wen-Chuan Wu achieves the best visual quality of
reconstructed images (i.e. highest PSNR) and very less distortion . In addition, the
proposed method has as high embedding capacity as Lin and Chang's method, followed by
Yang et al.'s method.
17
Therefore the method proposed is applicable to some steganographic applications such as
secret communications where the network bandwidth and the execution speed are areas of
which demanded more research at that time.
The tradeoff among image distortion, embedding capacity, and efficiency varies from
application to application. As, different techniques are employed for different
applications. Three embedding classes are information hiding techniques in spatial
domain, in transformed domain (e.g. using DCT, DFT, or DWT) , and in compressed
domain .
2.Chin-Chen Chan , The Duc Kieu ,Yung-Chen Chou later came up with a new
research in the field of Reversible information hiding for Vector Quantization (VQ)
indices based on locally adaptive coding . They proposed a different reversible
information hiding technique for vector quantization (VQ) compressed images built on
locally adaptive coding method. The proposed steganographic method embeds the
message into Vector quantization indices in an already present index table during the
process of compressing the index table in the block-by-block manner.
The suggested method by this paper is superior to the one proposed by Yang et al.’s and
Lin and Chang’s when it comes to visual quality of reconstructed images .The embedding
rate is also found out to be better tgen Yang Et al’s method .With regard to the
compression rate and the encoding execution time, Yang et al.’s method is the best,
followed by the proposed method, and then Lin and Chang’s method. Thus, we can
conclude that method proposed by them is applicable to stenographic applications such as
online content distribution systems.
Designing a novel steganography method is mostly concentrated on achieving good visual
quality, high hiding capacity, robustness, and steganographic security . An information
18
hiding scheme with low image distortion is more secure than that with high distortion
because it does not raise any suspicions. Therefore, image quality factor is the first
important one. The second important factor is embedding capacity (called capacity for
short). An information hiding scheme with high payload is preferred because more secret
data can be transferred. In nature, embedding capacity is inversely proportional to visual
quality. That is, if capacity is increased then visual quality is reduced. The tradeoff
between the two factors above is made by users, depending on users' purposes and
application fields.
3. Fridrich J and Goljan M, Du R came up with a method of reliable detection of
LSB steganography in color and grayscale Images. A large number of
steganographic projects use the method of embedding of Least Significant Bit (LSB)
for message hiding in colored cover images and grayscale cover images. In the method
proposed by Fridrich and Goljan , a very accurate and reliable algorithm is designed
that can detect LSB embedding in randomly scattered pixels in both 24-bit color
images and 8-bit grayscale .
Least-significant bit (LSB) based approach has become one of the most popular approach
for application of steganographic algorithms in the spatial domain. However, before the
proposition of paper by Weiqi Luo ( Member, IEEE ) , Fangjun Huang ( Member, IEEE) ,
and Jiwu Huang ( Senior Member, IEEE) , in most existing approaches, the choice of
embedding positions contained by a cover image mainly be contingent on a pseudo
random number generator without considering the correlation between the image content
itself and the size of the secret message.
The paper proposed to expand the LSB matching revisited image steganography and
came up with an edge adaptive scheme which can select the embedding regions based on
19
the size of the secret message and the difference between two consecutive pixels in the
cover image. When it comes to the lower embedding rates, only sharper edge regions are
used while keeping the other smoother regions as they are. When the embedding rate
increases, more edge regions can be released adaptively for data hiding by adjusting just a
few parameters. In this method the experimental results evaluated on 6000 natural images
with three specific and four universal steganalytic algorithms show that the new scheme
can enhance the security significantly compared with typical LSB-based approaches as
well as their edge adaptive ones while preserving higher visual quality of stego images .
Firstly the secret message is embedded into the sharper edge regions adaptively according
to a threshold determined by the size of the secret message and the gradients of the content
edges. It is expected that this adaptive idea can be extended to other steganographic
methods such as audio/video steganography in the spatial or frequency domains when the
embedding rate is less than the maximal amount.
Pixel-value differencing (PVD) scheme
The pixel-value differencing (PVD) scheme uses the difference value between two
consecutive pixels in a block to determine how many secret bits should be embedded.
There are two types of the quantization range table given by Wu and Tasi . The first one
was based on selecting the range widths of [8, 8, 16, 32, 64, 128], to provide large
capacity. The second was based on selecting the range widths of [2, 2, 4, 4, 4, 8, 8, 16, 16,
32, 32, 64, 64], to provide high imperceptibility. This work designs a new quantization
range table based on the perfect square number to decide the payload by the difference
value between the consecutive pixels.
The data hiding techniques is carried out in three domains , namely spatial domain,
compress domain, and frequency domain. The domains specified has their own
advantages amd disadvantages when it comes to the hiding capacity , execution time and
20
the payload capacity. Recently in the research field in this domain , many researchers are
more enthusiastic to improve the embedding efficiency and decrease the possibility of
detection. Least-significant-bit matching is the conventional effective steganography
method, and it is proved much more problematic to detect than simple LSB replacement.
4. Zhang and Wang (2006) proposed to fully exploit different modification directions for
secret data embedding . The proposed method can achieve various hiding capacities and
good visual qualities compared to two recently published works, namely Mie-likainen's
method (Mielikainen, 2006), Zhang and Wang's method (Zhang and Wang, 2006).
5.Hong, W. and Chen, T. S. came up with a new data-hiding method based on pixel pair
matching (PPM). Pixel Pair Matching used the idea of the use of the values of pixel pair
as a reference coordinate, and search a coordinate in the neighborhood (vicinity) set of this
pixel pair according to a given message bit. The pixel pair is then replaced by the searched
coordinate to embed the secret message bit. Based on PPM, two data-hiding methods have
been proposed recently that is Exploiting modification direction (EMD) and diamond
encoding (DE) . The maximum capacity of EMD is 1.161 bpp and DE has higher capacity
than EMD. The proposed method offers lower distortion than DE by providing more
compact neighborhood sets and allowing embedded digits in any notational system.
Compared with the optimal pixel adjustment process (OPAP) method, the proposed
method always has lower distortion for various payloads. Experimental result shows that
the proposed method provides better performance and better security than those of OPAP
and DE.
6. Chao et al. (2009) , got inspired by EMD method and proposed a diamond encoding
(DE) method to greatly improve the payload of EMD. Extraction function is used to
generate diamond characteristic values (DCV) in DE method , and the payload is
controlled by using the embedding parameter . Despite of the advantages of DE method
21
, it still does not allow embedding digits in multiple bases , which is the essential
requirement for an embedding method with the consideration of human visual system
(HVS) . If pixel values are exceeding 0 or 255 then it will be added or subtracted by B to
retain the pixel values within the range [0, 255] so as to prevent the overflow or underflow
condition . This adjustment may cause a large alteration, and may lead to generation of
image noise when the embedding parameter is large.
The other groups which evolved took embedding strategies like HVS into consideration,
namely these methods embed more data in edge areas to acquire more payload whereas
embed less data in smooth areas to preserve the visual quality.
7.Wuand Tsai (2003) , worked in the same direction and recommended a data embedding
method based on pixel value differencing (PVD). Due to pixel pairs with larger difference
are often located in complex regions, PVD embeds more data into pixel pairs with larger
differences. But the PVD method may lead to considerable distortion and digression in the
image quality due to presence of noise.
8. Kazem Qazanfari, Reza Safabakhsh , proposed a method to prevent the cover image
from steganalysis methods . He found out that LSB and outguess are two steganography
approaches which preserve the cover histogram to a large extent and are highly successful
. In these methods , some extra bits are embedded to retain the cover histogram. But
these techniques adversely affect the statistical and perceptual attributes of the cover
image. LSB was proposed to improve LSB by prohibiting some pixels from changing,
resulting in the reduction of the extra bits. In this method , the LSB is improved. The
method talks about distinguishing sensitive pixels and protecting them from extra bit
embedding, which causes lower distortion in the co-occurrence matrices. In addition, it
also extend LSB to preserve the DCT coefficients histogram of jpeg images and
generalize the method to the case where more than one bit of the cover elements are used.
22
The experimental results show that the improved LSB method produces fewer traces in
the co-occurrence matrices than the LSB method. Furthermore, the histogram based
attacks cannot detect stego images produced by their method with or without extra bits
embedding.
By providing an embedding secret to improve on these short comings, in this paper, two
pixels are adopted as an embedding unit and PVD method is employed on them . 1D pixel
sequence is mapped by using the Hilbert Filling curve .The proposed method not only
consider human visual system (HVS) and the correlation of local consecutive pixels but
also avoid storing the search matrix data and therefore adds value to the existing research
going on the improvement of the data hiding schemes .
23
Chapter Three
Related Work
LSB Matching and Replacement
In a binary number system ,the bit at the one’s place , the right most bit is called LSB or
the least significant bit .Least significant bit encoding is one of the most utilized
technique which is quite famously used for steganography. The method focuses on
altering the least significant bit and therefore embed the data in the same way . To defeat
the histogram based steganalysis methods, many efforts have been made by researchers to
protect the histograms of images. One of the first solutions to defeat these attacks was
LSB matching. LSB matching increases or decreases the pixel values with the same
probabilities when the least significant bit of the pixel value is not equal to the message
bit.
This method can be used in embedding of fixed length of message .But only three bits are
embedded by this method as embedding more bits may cause distortion of the image and
cause failure. Different adaptive methods are used to minimize the distortion.
When we apply an optimal pixel adjustment process to the stego image obtained by the
simple LSB substitution technique, the image quality of the stegoimage can be improved
by a large extent with low extra computational difficulty. The worst case mean-square-
error between the stego image and the cover image is derived. Experimental results show
that the stego image is visually indistinguishable from the original cover image. The
obtained results also show a significant improvement with respect to a previous work.
24
Exploiting modification direction (EMD)
Least-significant-bit (LSB) matching is one of the most conventional as well as efficient
steganography method, and after extreme experimentations , it is examined that it is
much more difficult to detect than simple LSB replacement . To fully exploit different
modification directions for secret data embedding - Zhang and Wang in year 2006 ,
proposed the exploiting modification direction (EMD) method. In this method , ‘n’
pixels are taken as embedding unit , and the digits are embedded in (2n+1) base. Its
maximum payload is 1=2 log2 5 = 1:161 bpp when n=2. Zhang and Wang claimed that
the modification directions of Mielikainen's scheme are not explored fully. Specifically,
the PSNR value of the EMD method is slightly smaller than that of Mielikainen's scheme
at hiding capacity of 1 bpp. In addition, forn¼2, Zhang and Wang's method only utilizes
four modification directions.Kieu and Chang (2011) (FEMD) proposed a novel extraction
function (also called the modified extraction function) by modifying the extraction
function proposed by Zhang and Wang (2006). The modified extraction function allows
the proposed method to exploit eight modification directions for embedding secret data,
restrict the embedding distortion into a square of various sizes (e.g. 22, 33, and so on) and
use the minimum distortion embedding (MDE) process. By this way, the proposed method
can achieve various hiding capacities and good visual quali-ties compared to two recently
published works, namely Mie-likainen's method (Mielikainen, 2006), Zhang and Wang's
method (Zhang and Wang, 2006). To solve the irreversibility of the EMD method in
(Zhang and Wang, 2006; Qin et al. 2014) proposed a novel data hiding scheme based on
EMD with reversibility by using two steganographic images, which can also achieve
satisfactory performances of the hiding capacity and the stego image quality.
25
Chapter 4
Proposed Methodology
A new data hiding method is proposed in this project , which can increase the
steganographic security of a data hiding scheme .In this method a cover image is first
mapped into a 1D pixels sequence by Hilbert filling curve and then it has been divided
into non-overlapping embedding units .The division is made such that it gives two
consecutive pixel values .As human eye has limited tolerance when it comes to texture
and edge areas than in smooth areas , and as the difference between the pixel pairs in those
areas are larger , therefore the method exploites pixel value difference (PVD) to solve out
overflow underflow problem .
The digits in any bases can be embedded according to the local complexity of the cover
image and through this way it solves the problems which are faced by existent EMD
method . Overflow, Underflow or falling-off boundary problem can be reduced by this
proposed method hensforth solves the detectable artifacts caused by them . The
experimental results show our method not only to enhance embedding rate but also keep
stego image quality.
26
Embedding
• An image with size MxN is taken, and the image is brought to Hilbert 1D sequence.
• Partition the sequence into non-overlapping (M x N) /2 embedding units with two
consecutive pixels .Calculate the differences of the adjacent pixel values .
• Design a range table which consists of the contiguous sub-ranges Wj=(j=1,2,3…, 6)
W={Wj=[lj,uj]}={[0, 7],[8, 15],[16,31],[32, 63],[64, 127],[128, 255]}
For wj=uj-lj+1
• If di belong the range of Wj calculate the value of si and ki :Compute si and ki
• Read the Next Ki seperate bit from the binary secret data . Convert them into
decimal number . Now compute extraction function .
• Now compare, extraction function with M (I), based on the comparison we will
modify pixel pair and compute the difference between the modified pixel value
and determine if it falls in the same range of Wj.
• If the range is same as older calculation , the new pixel value replaces the older one
.But if its not then we will select the candidate pixel pair such that it falls in the
range and meets the conditions .
Block Diagram Embedding
Cover Image Partitioning Get secret bits.
Convert Bin to
Decimal
Embedding
Process
Optimization
Problem –
Overflow /
Underflow
Stego Image
27
Generation of Secret Data
Using the random bit generator , 4 lakhs binary random bits are generated . Those bits are
later stored in an array format so that it can be used . Each set of generated bits are used
only once , and are called secret message . The secret message bits are converted to its
decimal value (mi) . The secret message bits are used for embedding and helps in
determining the payload capacity of the cover image.
Data Extraction
• To extract the embedded message digits, pixel pairs are scanned in the same order
as in the embedding procedure. The embedded message digits are the values of
extraction function of the scanned pixel pair.Do exactly the same things as Step 1 in
data embedding.
• Calculate difference of adjacent pixels.From the wj division, find out the range in
which the difference belongs.Now calculate mi* exactly the same way as in data
embedding
•
28