1. By
Under the Guidance of
BACHELOR OF TECHNOLOGY
In
Electronics and Communication Engg.
DELHI TECHNOLOGICAL UNIVERSITY,
SHAHBAD DAULATPUR
MAIN BAWANA ROAD
DELHI-110042
Project report submitted in fulfilment of the Requirements for the Award of the
Degree of
Dr. Harikesh
Yash Gupta (2K20/EC/241)
CS PROJECT REPORT
2. Place: Delhi Technological University
Date: 24-04-2022
Yash Gupta
(2K20/EC/241)
I hereby declare that the dissertation entitled “Image Steganography” submitted for
the B.Tech Degree is my original work and the dissertation has not formed the basis
for the award of any degree, associateship, or fellowship, or any other similar titles.
DECLARATION
3. Yash Gupta (2K20/EC/241)
I express my sincere thanks to Prof. Jai Prakash Saini, Vice-Chancellor, Delhi
Technological University, Delhi. I pay my deep sense of gratitude to Prof. N. S.
Raghava (HOD) of the ECE Department, Delhi Technological University, Delhi to
encourage me to the highest peak and provide me with the opportunity to prepare the
project. I feel to acknowledge my indebtedness and a deep sense of gratitude to my
guide Dr. Harikesh whose valuable guidance and kind supervision is given to me
throughout the course and shaped the present work as shown. I am immensely
obliged to my friends for their elevating inspiration, encouraging guidance, and kind
supervision in the completion of this project.
NAME OF STUDENTS:
ACKNOWLEDGEMENT
4. ABSTRACT
Steganography is the process of hiding one file inside another such that others
can neither identify the meaning of the embedded object nor even the
embedded object nor even recognize its existence. Current trends favor using
digital image files as the cover file to hide other digital file that contains the
secret message or information. Steganography becomes more important as
more people join the cyberspace revolution. Steganography is the art of
concealing information in ways that prevent the detection of hidden
messages. The goal of steganography is to avoid drawing suspicion to the
existence of a hidden message. This approach of information hiding technique
has recently become important in a number of application areas. Digital
audio, video, and pictures are increasingly furnished with distinguishing but
imperceptible marks, which may contain a hidden copyright notice or serial
number or even help to prevent unauthorized copying directly. Military
communications systems make increasing use of traffic security techniques
that, rather than merely concealing the content of a message using encryption,
seek to conceal its sender, its receiver, or its very existence. Similar
techniques are used in some mobile phone systems and schemes proposed for
digital elections. One of the most common methods of implementation is
Least Significant Bit Insertion, in which the least significant bit of every byte
is altered by the bit-string representing the embedded file. This encryption
and decryption of the images will be done using MATLAB code.
5. S. NO. Page No.
NAME OF
EXPERIMENT
1. 1
2
3
4
5-7
8
8
8
9
Steganography & it types
LSB Methods
Block Diagram of Steganography
LSB execution with example
LSB Code & Implementation
Advantages
Applications
Future Scope & Conlusion
References
2.
3.
4.
5.
6.
7.
8.
9.
INDEX
6. b) Audio Steganography: Audio Steganography is the application of steganography to
audio files, in which we can hide information in an audio file. It's important that the
audio file is undetectable.
The use of multimedia digital signals has grown in popularity over the last decade as a
result of the proliferation of wireless Internet-based services, such as the introduction of
fourth-generation mobile communication systems that allow users to transfer data at
speeds of up to 1Gbps. Digital data can be easily copied, modified, and retransmitted in
the network by any user thanks to the availability of low-cost editing tools. It is critical
to developing tools that protect and authenticate digital information in order to
effectively support the growth of multimedia communications. We present a novel
embedding scheme based on the LSB technique in this contribution. It has no effect if
the value of a pixel in an image is changed by a value of '1'.
STEGANOGRAPHY is derived from the Greek words STEGANOS, which means
"covered," and GRAPHIE, which means "writing." In most cases, the sender composes a
seemingly innocuous message before concealing a hidden message on the same piece of
paper. The main goal of steganography is to communicate securely while remaining
completely undetectable, avoiding suspicion of hidden data transmission. It's not so
much to keep others from knowing the hidden information as it is to keep them from
believing it exists. Data can be hidden in a variety of formats, including audio, video,
text, and images. The following are examples of steganography:
a) Image Steganography: Image steganography is the process of concealing data within
an image so that the original image does not appear to have changed. The LSB
embedding algorithm is a common
image steganography algorithm.
Introduction
Steganography types
Image Steganography
c) Video Steganography: Steganography can also be used to hide information in video
files. Video Steganography is the process of concealing information in a video file. An
attacker should be unable to detect the video file.
d) Steganography for text files: Steganography can also be used for text files. Text
steganography is the process of concealing information in a text file.
Page no. - 1
7. The graph below shows all 256 Gray-scale colors. A two-digit hex value is used to
define up to 256 shades of grey in the gray-scale color naming scheme. A grayscale
digital image is one in which each pixel's value is a single sample, carrying only
intensity information in photography and computing. Images of this type, also known as
black-and-white, are made up entirely of shades of grey, ranging from black to white at
their most intense. Grayscale images are distinct from one-bit bi-tonal black- and-white
images, which are images with only two colors, black and white, in the context of
computer imaging (also called bi-level or binary images). There are many shades of grey
in grayscale images. Grayscale images are frequently the result of measuring the
intensity of light at each pixel in a single band of the electromagnetic spectrum (e.g.,
infrared, visible light, ultraviolet, etc.), and they are monochromatic proper when only
one frequency is captured in such cases Figure shows the grayscale shading strengths
(0=no colour; 15=full colour).
Each pixel in a grayscale image is represented by 8 bits. The last bit in a pixel is known
as the Least Significant bit because its value has only a "1" effect on the pixel value. As
a result, this property is used to hide the image's data. If the last two bits are considered
LSB bits, they will only affect the pixel value by "3." This aids in the storage of
additional data. He only increased the pixel value by "3." This aids in the storage of
additional data. Least Significant Bit (LSB) steganography is a type of steganography in
which the image's least significant bit is replaced with data bits. Because this method is
vulnerable to steganalysis, we encrypt the raw data before embedding it in the image to
make it more secure. While the encryption process adds to the complexity of the process,
it also adds to the security. This method is very straightforward. The least significant
bits of some or all of the bytes in an image are replaced with bits of the secret message
using this method. Many techniques for hiding messages within multimedia carrier data
are based on the LSB embedding approach. LSB embedding can even be used in specific
data domains, such as embedding a hidden message in the RGB bitmap data's color
values or the frequency coefficients of a JPEG image. LSB embedding can be used with
a wide range of data formats and types. As a result, LSB embedding is one of the most
commonly used steganography techniques today..
Gray scale
LSB METHODS
Fig 1.1 Pixel Density of grey scale image [0-255]
Page no. - 2
8. The stego system encoder embeds a message into the image using a secret key or
password. This password, also known as a secret key, should be kept private. The
resulting stego image is sent to the receiver over a channel. The stego image will be
decoded by the stego system at the decoder end, using the same key or password. The
figure shows a block diagram.
Block Diagram of Steganography
Fig 1.2 Working Procedure of LSB Steganography
In the data hiding technique, there are two important components: cover image and
hiding data. The first image on the cover is an 8-bit grayscale image. The cover image is
mn pixels in size. H is a g-bits bitstream that hides data in Image. To express image C,
data D, and each pixel separately, we use the equation below. The Least Significant Bit
method is one of the simplest methods for embedding digital data into a digital cover.
Consider an NM image in which each pixel value is represented by a decimal number
within the range dictated by the number of bits used. Each pixel in a gray-scale image
with 8-bit precision assumes a value between [0, 255]. By separating an image into n bit
planes, this property allows it to be decomposed into a collection of binary images. The
secret message is either directly replaced or inserted into the least-significant bit plane
of the cover image in traditional LSB embedding methods. Depending on the number of
pixels chosen, the amount of data to be embedded may be fixed or variable in size. The
main benefit of such a technique is that changing the LSB plane has no effect on human
perception of overall image quality because the amplitude variation of pixel values is
limited
to 1.
LSB Decomposition
Page no. - 3
9. Under normal viewing conditions, the Human Visual System's masking properties allow
significant amounts of embedded information to go unnoticed by the average observer.
The phenomenon of "masking" occurs when a signal is imperceptible to an observer in
the presence of another signal. In, a thorough examination of these techniques is
provided. High embedding capacity and low computational complexity were also
advantages of LSB data hiding. The weaknesses in terms of robustness, tampering,
geometric attacks, filtering, and compression are the most significant drawbacks.
The least significant bits of the cover media's digital data are used to conceal the
message in LSB steganography. LSB replacement is the most basic of the LSB
steganography techniques. The last bit of each pixel value is changed in LSB
replacement steganography to reflect the message that needs to be hidden. Consider an
8-bit grayscale bitmap image, in which each pixel is represented by a byte with a
grayscale color value. Assume the following grey color values for the first eight pixels
of the original image:
01010010
01001010
10010111
11001100
11010101
01010111
00100110
We would replace the LSBs of these pixels with the following new values to hide the
letter Z, whose ASCII code binary value is 10110101:
01010011
01001010
10010111
11001101
11010100
01010111
00100110
01000011
LSB method with an example
It's worth noting that only half of the LSBs need to be changed on average. The
difference between the cover (original) image and the stego image will be almost
imperceptible to the naked eye. One of its major drawbacks is the small amount of data
that can be embedded in such images using only LSB. Attacks on LSB are extremely
common. In contrast to 8-bit formats, LSB techniques applied to 24-bit formats for
colour images are difficult to detect.
Page no. - 4
10. %Encoding the message
original=imread('cat.jpg');
cover=rgb2gray(original);
[row,column]=size(cover);
L=256;
stego=cover;
message=input('Enter the message to be hidden: ','s'); len=strlength(message)*8; %Each character will take 8 bits so total
number of bits in the message will be len
ascii=uint8(message); %ascii is a vector having the ascii value of each character
binary_separate=dec2bin(ascii,8); %binary_separate is an array having the decimal representation of each ascii value
binary_all=''; %binary_all will have the entire sequence of bits of the message
for i=1:strlength(message)
binary_all=append(binary_all,binary_separate(i,:));
end
count=1; %initializing count with 1
for i=1:row
for j=1:column
%Convert%for every character in the message
if count<=len
%Obtain the LSB of the grey level of the pixel LSB=mod(cover(i,j),2);
disp(['The original message is: ',original_message]);
the bit from the message to numeric form a=str2double(binary_all(count));
%Perform XOR operation between the bit and the LSB temp=double(xor(LSB,a));
%Change the bit of the stego image accordingly stego(i,j)=cover(i,j)+temp;
count=count+1;
end
end
end
subplot(1,2,1);
imshow(cover);
title('Cover Image');
subplot(1,2,2);
imshow(stego);
title('Stego Image');
%Decoding the message
count=1;
message_in_bits='';
for i=1:row
for j=1:column
%For all the characters in the message
if count<=len
%Retrieve the LSB of the intensity level of the pixel LSB=mod(stego(i,j),2);
%Append into message_in_bits to get bit sequence of message
message_in_bits=append(message_in_bits,num2str(LSB));
count=count+1;
end
end
end
Code
Page no. - 5
11. The image that will be used for steganography will be shown first.
Implementation
Fig 1.3 Original Colored Image for LSB Steganography
%Converting the bit sequence into the original message
i=1;
original_message='';
while i<=len
%Take a set of 8 bits at a time
%Convert the set of bits to a decimal number
%Convert the decimal number which is the ascii value to its corresponding character
%Append the obtained character into the resultant string
original_message=append(original_message,char(bin2dec(message_in_b its(1,i:i+7))));
i=i+8;
end
After that, the user should type in the message to be hidden.
After that, the code will be executed, and the hidden message would be embedded using
the LSB method, with the output being a grayscale and stego image.
Fig 1.4 Input entered by the user
Page no. - 6
12. Finally, the decoding program will be run to uncover the stego image's hidden message.
Fig 1.5 Cover and Stego Image for LSB Steganography
Fig 1.6 Decoded message after LSB Steganography
Page no. - 7
13. For net-espionage agents, steganography has a number of advantages. Even if a file is
known or suspected to contain Steganographic software, extracting the information is
nearly impossible without the correct password. Steganography is useful for
encrypting sensitive data, such as system passwords or keys, and hiding them within
other files. Steganography can be used for covert data transmission in places where
standard cryptography and encryption are prohibited.
Steganography is a technique that can be used in addition to cryptography,
watermarking, and fingerprinting. In military applications, steganography can be used to
conceal and transfer an encrypted document containing some acquired information.
LSB and DWT approaches have been used to successfully develop image steganography.
This report also highlighted its merits and disadvantages. Despite this, efforts must be
made to increase embedding capacity while maintaining secrecy. We can use this method
to hide text files that are the same size as the image. It is possible to hide text files that
are larger than the image size. Both the sender and the receiver must be aware of the
secret keys. The keys are not included in the cover images and must be requested
separately. These keys can be generated and distributed invisibly using a technique that
has yet to be developed. If you need more security, you can use the Transform Domain
method. When Steganography is combined with Cryptography, it becomes an unbeatable
tool for establishing secure communication links. Advanced cryptography techniques can
improve the scheme's security, while data compression techniques can improve its
efficiency.
Advantages
Applications
Future Scope & Conclusion
Page no. - 8
14. Mujtiba, Syed & Yousu, Salihah & Bisma, Syed & Siddiqi, Mehvish & Khaki,
Zahidgulzar. (2017). COMPARISION OF LSB AND DWT STEGANOGRAPHY
TECHNIQUES. 10.21090/IJAERD.ETIECE08.
Macit, Hüseyin & Koyun, Arif & Güngör, Orhan. (2018). A REVIEW AND
COMPARISON OF STEGANOGRAPHY TECHNIQUES.
Fahim Irfan et. Al. ‘s (2011) “An Investigation into Encrypted Message Hiding
through Images Using LSB ”, International Journal of EST,
Rajkumar Yadav, (2011) “A Novel Approach For Image Steganography In Spatial
Domain Using Last Two Bits of Pixel Values”, International Journal of Security, Vol.5
Iss. 2 pp. 51-61.
Refernces
Page no. - 9