Cyber Security Report
Cyber Security Report
A
Mini Project Report
On
“CYBER SECURITY”
BACHELOR OF TECHNOLOGY
in
“Computer Science & Engineering”
Submitted by
Kritika Anand
(Roll No.2001200130022)
Under Guidance of
Mr. Nitin Dixit
(Assistant Professor, CSE Dept.)
Submitted To
DEPARTMENT OF COMPUTER SCIENCE & ENGINEERING
INSTITUTE OF TECHNOLOGY & MANAGEMENT, GIDA,
GORAKHPUR
SESSION: 2023-24
CERTIFICATE
DECLARATION
This is certified that the work which is being presented in the mini project entitled
authentic record of my own work carried out during the semester under the supervision of
“EDUNET FOUNDATION”
The matter presented in this mini project has not been submitted by me for the award of any
Kritika Anand
This is to certify that the above statement made by the candidate is correct to the best of my
knowledge.
Date:
Candidate Signature
ABSTRACT
The goal of steganography is to hide messages inside other “harmless” messages in a way
that does not allow any “enemy” to even detect that there is a second secret message present.
The only missing information for the “enemy” is the short easily exchangeable random
number sequence, the secret key, without the secret key, the “enemy” should not have the
communication, security through obscurity, and dual-layered protection, are highlighted. The
project also acknowledges the ethical considerations surrounding the use of steganography
ACKNOWLEDGEMENT
find my parents as my torch bearers. While completing this task, I realized from my inner
core that Rome was not built in day. I found a stack of mini project reports in the library of
ITM Gorakhpur library. Those reports are the landmarks for me on the way of this task. The
presented report is an effort of day and night works. Selection is always tough; undoubtedly I
I am sincerely thankful to Mr. Ashutosh Rao (HOD) & Mr. Nitin Dixit (Mini Project
Coordinator) for his support. I express my gratitude and thanks to all the faculties and staff
members of Computer Science & Engineering department for their sincere cooperation in
furnishing relevant information to complete this mini project report well in time successfully.
Finally, my greatest debt is to my parents, my family for their enduring love, support and
Kritika Anand
Roll No.2001200130022
LIST OF FIGURES
1.1 CIA Traid 1
1.2 Layers of Cyber Security 12
1.3 Cyber Attacker actions 12
2.1 Digital forensics lifecycle 13
3.1 Image steganography 13
3.2 Working of steganography 14
3.3 Types of steganography 15
4.1 Working of Image Steganography 15
4.1 Hiding text in Image 17
CHAPTER – 1
INTRODUCTION TO CYBER SECURITY
Confidentiality:
It's crucial in today's world for people to protect their sensitive, private information from
unauthorized access. Protecting confidentiality is dependent on being able to define and
enforce certain access levels for information.
In some cases, doing this involves separating information into various collections that are
organized by who needs access to the information and how sensitive that information is - i.e.
the amount of damage suffered if the confidentiality was breached.
Some of the most common means used to manage confidentiality include access control lists,
volume and file encryption, and Unix file permissions.
Integrity:
Data integrity is what the "I" in CIA Triad stands for. This is an essential component of the
CIA Triad and designed to protect data from deletion or modification from any unauthorized
party, and it ensures that when an authorized person makes a change that should not have
been made the damage can be reversed.
Availability:
This is the final component of the CIA Triad and refers to the actual availability of your data.
Authentication mechanisms, access channels and systems all have to work properly for the
information they protect and ensure it's available when it is needed.
10
The CIA Triad is all about information. While this is considered the core factor of most of the
IT security, it promotes a limited view of the security that ignores other important factors.
It's important to understand what the CIA Triad is, how it is used to plan and to implement a
quality security policy while understanding the various principles behind it. It's also
important to understand the limitations it presents. When you are informed, you can utilize
the CIA Triad for what it has to offer and avoid the consequences that may come along by
not understanding it.
11
7. The Human Layer – Humans are the weakest link in any cyber security posture. Human
security controls include phishing simulations and access management controls that protect
mission critical assets from a wide variety of human threats, including cyber criminals,
malicious insiders, and negligent users.
12
to attacks by cryptanalysis, whereby the attacker may obtain information or succeed in unencrypting
the traffic.
Software Attacks: Malicious code (sometimes called malware) is a type of software designed to take
over or damage a computer user's operating system, without the user's knowledge or approval. It can
be very difficult to remove and very damaging. Common malware examples are listed in the
following table.
14
CHAPTER - 2
CYBERSPACE AND THE LAW & CYBER FORENSICS
Cyberspace can be defined as an intricate environment that involves interactions
between people, software, and services. It is maintained by the worldwide distribution of
information and communication technology devices and networks. With the benefits carried
by the technological advancements, the cyberspace today has become a common pool used
by citizens, businesses, critical information infrastructure, military and governments in a
fashion that makes it hard to induce clear boundaries among these different groups. The
cyberspace is anticipated to become even more complex in the upcoming years, with the
increase in networks and devices connected to it.
2.2 REGULATIONS
There are five predominant laws to cover when it comes to cybersecurity:
Information Technology Act, 2000 The Indian cyber laws are governed by the Information
Technology Act, penned down back in 2000. The principal impetus of this Act is to offer
reliable legal inclusiveness to eCommerce, facilitating registration of real-time records with
the Government. But with the cyber attackers getting sneakier, topped by the human tendency
to misuse technology, a series of amendments followed.
The ITA, enacted by the Parliament of India, highlights the grievous punishments and
penalties safeguarding the e-governance, e-banking, and e-commerce sectors. Now, the scope
of ITA has been enhanced to encompass all the latest communication devices.
The IT Act is the salient one, guiding the entire Indian legislation to govern cybercrimes
rigorously:
Section 43 - Applicable to people who damage the computer systems without permission
from the owner. The owner can fully claim compensation for the entire damage in such cases.
Section 66 - Applicable in case a person is found to dishonestly or fraudulently committing
any act referred to in section 43. The imprisonment term in such instances can mount up to
three years or a fine of up to Rs. 5 lakh.
Section 66B - Incorporates the punishments for fraudulently receiving stolen communication
devices or computers, which confirms a probable three years imprisonment. This term can
also be topped by Rs. 1 lakh fine, depending upon the severity.
Section 66C - This section scrutinizes the identity thefts related to imposter digital
signatures, hacking passwords, or other distinctive identification features. If proven guilty,
imprisonment of three years might also be backed by Rs.1 lakh fine.
Section 66 D - This section was inserted on-demand, focusing on punishing cheaters doing
impersonation using computer resources.
15
The forensic examination of computers, and data storage media, is a complicated and highly
specialized process. The results of forensic examinations are compiled and included in
reports.
In many cases, examiners testify to their findings, where their skills and abilities are put to
ultimate scrutiny.
2.5 DIGITAL FORENSICS:
Digital Forensics is defined as the process of preservation, identification, extraction, and
documentation of computer evidence which can be used by the court of law. It is a science of
finding evidence from digital media like a computer, mobile phone, server, or network. It
provides the forensic team with the best techniques and tools to solve complicated digital
related cases.
Digital Forensics helps the forensic team to analyzes, inspect, identifies, and preserve the
digital evidence residing on various types of electronic devices. Digital forensic science is a
branch of forensic science that focuses on the recovery and investigation of material found in
digital devices related to cybercrime.
THE NEED FOR COMPUTER FORENSICS
Computer forensics is also important because it can save your organization money. ... From a
technical standpoint, the main goal of computer forensics is to identify, collect, preserve, and
analyze data in a way that preserves the integrity of the evidence collected so it can be used
effectively in a legal case.
17
Examination: After data has been collected, the next phase is to examine the data, which
involves assessing and extracting the relevant pieces of information from the collected data.
This phase may also involve bypassing or mitigating OS or application features that obscure
data and code, such as data compression, encryption, and access control mechanisms.
Analysis: Once the relevant information has been extracted, the analyst should study and
analyze the data to draw conclusions from it. The foundation of forensics is using a
methodical approach to reach appropriate conclusions based on the available data or
determine that no conclusion can yet be drawn.
Reporting: The process of preparing and presenting the information resulting from the
analysis phase. Many factors affect reporting, including the following:
a. Alternative Explanations: When the information regarding an event is incomplete, it may
not be possible to arrive at a definitive explanation of what happened. When an event has two
or more plausible explanations, each should be given due consideration in the reporting
process. Analysts should use a methodical approach to attempt to prove or disprove each
possible explanation that is proposed.
b. Audience Consideration. Knowing the audience to which the data or information will be
shown is important.
c. Actionable Information. Reporting also includes identifying actionable information
gained from data that may allow an analyst to collect new sources of information
18
CHAPTER – 3
STEGANOGRAPHY
The point that is chosen is Steganography Using Python, one explanation that gatecrashes can be
productive is most of the information they get from a system is in a construction that they can
scrutinize and comprehend. Intruders may uncover the information to others, change it to misshape
an individual or affiliation, or use it to dispatch an attack. One response for this issue is, utilizing
steganography. Steganography is a technique for disguising information in modernized media.
Rather than cryptography, it isn’t to safeguard others from knowing the covered information,
yet it is to protect others from envisioning that the information even exists. Steganography become
progressively significant as more individuals join the internet upheaval. Steganography is the craft of
hiding data in manners that forestalls the identification of shrouded messages. Steganography
incorporates a variety of mystery specialized strategies that conceal the message from being seen or
found
19
Steganography works by concealing information in a way that avoids suspicion. One of the
most prevalent techniques is called ‘least significant bit’ (LSB) steganography. This involves
embedding the secret information in the least significant bits of a media file.
For example:
● In an image file, each pixel is made up of three bytes of data corresponding to the colors red,
green, and blue. Some image formats allocate an additional fourth byte to transparency, or
‘alpha’.
● LSB steganography alters the last bit of each of those bytes to hide one bit of data. So, to hide
one megabyte of data using this method, you would need an eight-megabyte image file.
● Modifying the last bit of the pixel value doesn’t result in a visually perceptible change to the
picture, which means that anyone viewing the original and the steganographically-modified
images won’t be able to tell the difference.
The same method can be applied to other digital media, such as audio and video, where data
is hidden in parts of the file that result in the least change to the audible or visual output.
● E-commerce skimming
In 2020, Dutch e-commerce security platform Sansec published research which showed that
threat actors had embedded skimming malware inside Scalable Vector Graphics (SVG) on
e-commerce checkout pages. The attacks involved a concealed malicious payload inside
SVG images, and a decoder hidden separately on other parts of the webpages.
20
Users who entered their details on the compromised checkout pages didn’t notice anything
suspicious because the images were simple logos from well-known companies. Because the
payload was contained within what appeared to be the correct use of SVG element syntax,
standard security scanners searching for invalid syntax did not detect the malicious activity.
● SolarWinds
Also in 2020, a group of hackers hid malware inside a legitimate software update from
SolarWinds, maker of a popular IT infrastructure management platform. The hackers
successfully breached Microsoft, Intel and Cisco, in addition to various US government
agencies. Then, they used steganography to disguise the information they were stealing as
seemingly benign XML files served in HTTP response bodies from control servers. The
command data within those files was disguised as different strings of text.
● Industrial enterprises
Again in 2020, businesses in the United Kingdom, Germany, Italy, and Japan were hit by a
campaign using steganographic documents. Hackers avoided detection by using a
steganographic image uploaded on reputable image platforms, like Imgur, to infect an Excel
document. Mimikatz, a malware that steals Windows passwords, was downloaded via a
secret script included in the picture.
● Security Through Obscurity: The embedded information is concealed within the carrier
medium, making it less likely to attract attention. As a result, steganography can provide a
layer of security through obscurity, making it harder for unauthorized individuals to detect the
presence of hidden information.
21
1. Image Steganography: Concealing information within digital images is one of the most
common forms of steganography. This involves manipulating the pixel values of an image to
embed the hidden data. Techniques include least significant bit (LSB) embedding, spread
spectrum, and transform domain methods.
2. Audio Steganography: Like image steganography, audio steganography involves hiding
information within audio files. This can be achieved by manipulating the least significant bits
of audio samples or using frequency domain techniques.
3. Video Steganography: Concealing data within video files involves techniques such as
embedding information in frames or modifying the video stream. Video steganography
methods can be more complex due to the larger volume of data in video files.
4. Text Steganography: Embedding information within text is another form of steganography.
This can involve subtle changes to the text, such as using invisible characters or altering the
spacing between words.
5. Network Steganography: Concealing information within network protocols or traffic is
known as network steganography. This can involve modifying the timing or pattern of
network packets to encode hidden data.
23
CHAPTER – 4
IMAGE STEGANOGRAPHY
Fig.4.1
Working of Image steganography
1. Selection of Carrier Image: A carrier image is chosen as the medium to hide the
information. This image should ideally be a common image file (e.g., JPEG, PNG, BMP) and
should not attract suspicion.
2. Conversion to Binary: The carrier image is converted from its original format (e.g., RGB for
color images) into binary data. In digital systems, each pixel in an image is represented by a
set of binary values.
3. Selection of Message: The message or data that needs to be concealed is prepared. This can
be any form of digital data, such as text, files, or even another image.
4. Encoding the Message: The binary representation of the message is then embedded into the
carrier image's binary data. One common method is to modify the least significant bits (LSBs)
24
of the pixel values. The LSBs are the rightmost bits in the binary representation of each
colour channel.
5. Altering Pixel Values: The LSBs of selected pixels are altered to represent the bits of the
hidden message. Since the changes are small, they are generally not noticeable to the human
eye, and the visual quality of the image remains largely unchanged.
6. Reconstruction: To retrieve the hidden message, the recipient uses a steganography tool or
algorithm to extract the altered LSBs from the carrier image. The extracted binary data is then
converted back into the original message format.
1. Least Significant Bit (LSB) Embedding: This is the most straightforward method, where
the least significant bits of the pixel values are replaced with the bits of the hidden message.
This method is simple but may be vulnerable to statistical analysis.
2. Spread Spectrum Technique: This method distributes the hidden message across the entire
image, making it more resilient to detection. It involves modifying multiple pixels to
represent each bit of the hidden message.
3. Transform Domain Techniques: Techniques such as discrete cosine transform (DCT) or
discrete wavelet transform (DWT) are applied to the image before embedding the message.
This can provide better security and resistance to certain attacks.
25
Secrecy: The primary feature of image steganography is secrecy. The secret information
is hidden within the image in a way that is not easily detectable by an unauthorized
person.
Capacity: The capacity of an image to carry secret information depends on the size of the
image and the amount of information to be hidden. Generally, larger images have a higher
capacity to carry secret information.
Robustness: The image steganography technique should be robust, i.e., it should be able
to withstand image processing techniques like compression, cropping, and resizing
without affecting the hidden information.
Security: The security of the hidden information is of utmost importance. The image
steganography technique should be designed in such a way that it is resistant to attacks
like statistical analysis and brute force attacks.
Efficiency: The image steganography technique should be efficient, i.e., it should be able
to hide the secret information in the image quickly and effectively.
Concealment: The hidden information should be concealed in the image in a way that it
is not easily distinguishable from the original image.
26
CHAPTER – 5
PROJECT : IMAGE STEGANOGRAPHY USING PYTHON
5.1 OVERVIEW
Creating an image steganography project using Python involves selecting a suitable
steganographic technique, implementing the encoding and decoding processes, and
integrating the necessary functionalities. Here's an overview of the key steps you might take
in a basic image steganography project using Python:
7. Dynamic Typing:
Python uses dynamic typing, meaning variable types are determined at runtime. This can lead
to more flexibility in code but also requires careful consideration to prevent unexpected
behavior.
8. Support for Integration:
Python easily integrates with other languages, and it supports numerous integration
mechanisms, including C/C++ libraries and APIs. This feature allows developers to leverage
existing codebases in other languages.
9. Community and Ecosystem:
Python has a vibrant and active community of developers. The Python Package Index (PyPI)
hosts a vast collection of third-party libraries and frameworks that enhance Python's
capabilities.
Python's popularity continues to grow, driven by its simplicity, readability, and suitability for
diverse applications. It remains a go-to language for both beginners and experienced
developers working on a broad spectrum of projects.
5.4 CODE:
from tkinter import *
from tkinter import messagebox as mb
from PIL import Image
for i in data:
binary_data = format(ord(i), '08b')
data_in_binary.append(binary_data)
length_of_data = len(data_in_binary)
image_data = iter(pixels)
for a in range(length_of_data):
pixels = [val for val in image_data.__next__()[:3] + image_data.__next__()[:3] +
image_data.__next__()[:3]]
28
for b in range(8):
if (data_in_binary[a][b] == '1') and (pixels[b] % 2 != 0):
pixels[b] -= 1
elif (data_in_binary[a][b] == '0') and (pixels[b] % 2 == 0):
if pixels[b] == 0:
pixels[b] += 1
pixels[b] -= 1
if (length_of_data-1) == a:
if pixels[-1] % 2 == 0:
if pixels[-1] == 0:
pixels[-1] += 1
else:
pixels[-1] -= 1
pixels = tuple(pixels)
yield pixels[:3]
yield pixels[3:6]
yield pixels[6:9]
new_image = image.copy()
encryption(new_image, text)
29
new_image_name += '.png'
new_image.save(new_image_name, 'png')
data = ''
image_data = iter(image.getdata())
decoding = True
while decoding:
pixels = [value for value in image_data.__next__()[:3] + image_data.__next__()[:3] +
image_data.__next__()[:3]]
for i in pixels[:8]:
if i % 2 == 0:
binary_string += '0'
else:
binary_string += '1'
Label(encode_wn, text='Enter the path to the image(with extension):', font=("Times New Roman",
13),
bg='AntiqueWhite').place(x=10, y=50)
Label(encode_wn, text='Enter the data to be encoded:', font=("Times New Roman", 13),
bg='AntiqueWhite').place(
30
x=10, y=90)
Label(encode_wn, text='Enter the output file name (without extension):', font=("Times New
Roman", 13),
bg='AntiqueWhite').place(x=10, y=130)
def decode_image():
decode_wn = Toplevel(root)
decode_wn.title("Decode an Image")
decode_wn.geometry('600x300')
decode_wn.resizable(0, 0)
decode_wn.config(bg='Bisque')
Label(decode_wn, text='Enter the path to the image (with extension):', font=("Times New Roman",
12),
bg='Bisque').place(x=10, y=50)
text_strvar = StringVar()
Label(decode_wn, text='Text that has been encoded in the image:', font=("Times New Roman",
12), bg='Bisque').place(
x=180, y=130)
31
32
SCREENSHOT:
33
34
35
CONCLUSION
In conclusion, this cyber security mini project, centered around image steganography
implemented in Python, has successfully explored the intricacies of concealing messages
within digital images as a means of enhancing data security and confidentiality.
The application of steganographic techniques, particularly leveraging Python’s capabilities,
has provided valuable insights into the practical aspects of securing information through
covert channels.
The project underscored the significance of image steganography in cyber security,
showcasing its potential advantages such as convert communication, security through
obscurity, and dual- layered protection when combined with encryption. By employing the
least significant bit(LSB) embedding technique, we demonstrated the discrete integration of
messages within the pixels of images while maintaining the visual integrity of the carrier
images.
36