Cyber Security Notes
Cyber Security Notes
UNIT I INTRODUCTION
Cyber Security – History of Internet – Impact of Internet – CIA Triad; Reason for Cyber Crime –
Need for Cyber Security – History of Cyber Crime; Cybercriminals – Classification of Cybercrimes –
A Global Perspective on Cyber Crimes; Cyber Laws – The Indian IT Act – Cybercrime and
Punishment.
The virus, named after a Scooby Doo villain, “Creeper,” was designed to move across ARPANET
(Advanced Research Projects Agency Network) – the forerunner to what we now call the internet.
ARPANET was established by the U.S. Department of Defense.
Thomas created the computer worm to be a non-harmful self-replicating experimental program. It was
intended to illustrate how mobile applications work, but instead, it corrupted the DEC PDP-10
mainframe computers at the Digital Equipment Corporation, interfering with the teletype computer
screens which were connected. All the users could see on the screen were the words “I’m the creeper,
catch me if you can!”
In response, Ray Tomlinson, Thomas’ colleague created the Reaper Program. It was similar to the
Creeper. It moves through the internet, replicating itself, and finds copies of the Creeper. When it
locates the copies, it logs them out, so they are rendered impotent. The Reaper was the first attempt at
cybersecurity – the first antivirus software program.
Impact of Internet
The internet has had an incredible impact on society since its inception. It has changed the way we
communicate, do business, learn, and even think. The internet has brought people from different parts
of the world together and has made information accessible to everyone with an internet connection.
One of the biggest impacts of the internet is on communication. Social media platforms like
Facebook, Twitter, and Instagram have made it easy for people to connect with others from anywhere
in the world. People can share their thoughts, ideas, and experiences instantly with their friends and
family. Video conferencing tools like Zoom have revolutionized remote communication, making it
possible for people to work and learn from anywhere in the world.
The internet has also had a significant impact on business. E-commerce websites like Amazon and
eBay have made it possible for people to shop from the comfort of their own homes. Small businesses
can now reach a global audience by creating an online presence. The internet has also made it easier
for people to work from home, which has become increasingly important during the COVID-19
pandemic.
Education is another area that has been greatly impacted by the internet. Online courses and tutorials
have made it possible for people to learn new skills from anywhere in the world. Massive open online
courses (MOOCs) like Coursera and edX have made higher education more accessible to people who
may not have the opportunity to attend a traditional university.
However, the internet has also had some negative impacts. Cyberbullying, online harassment, and
identity theft have become increasingly common. The internet has also made it easier for people to
access inappropriate content, which can have a negative impact on young children.
In conclusion, the internet has had a tremendous impact on society. It has changed the way we
communicate, do business, learn, and even think. While there are some negative impacts, the benefits
of the internet far outweigh the negatives. As the internet continues to evolve, it will be interesting to
see how it will shape our society in the future.
CIA Triad
When talking about network security, the CIA triad is one of the most important models which is
designed to guide policies for information security within an organization.
CIA stands for :
1. Confidentiality
2. Integrity
3. Availability
These are the objectives that should be kept in mind while securing a network.
Confidentiality
Confidentiality means that only authorized individuals/systems can view sensitive or classified
information. The data being sent over the network should not be accessed by unauthorized
individuals. The attacker may try to capture the data using different tools available on the Internet and
gain access to your information. A primary way to avoid this is to use encryption techniques to
safeguard your data so that even if the attacker gains access to your data, he/she will not be able to
decrypt it. Encryption standards include AES(Advanced Encryption Standard) and DES (Data
Encryption Standard). Another way to protect your data is through a VPN tunnel. VPN stands for
Virtual Private Network and helps the data to move securely over the network.
Integrity
The next thing to talk about is integrity. Well, the idea here is to make sure that data has not been
modified. Corruption of data is a failure to maintain data integrity. To check if our data has been
modified or not, we make use of a hash function.
We have two common types: SHA (Secure Hash Algorithm) and MD5(Message Direct 5). Now MD5
is a 128-bit hash and SHA is a 160-bit hash if we’re using SHA-1. There are also other SHA methods
that we could use like SHA-0, SHA-2, and SHA-3.
Let’s assume Host ‘A’ wants to send data to Host ‘B’ to maintain integrity. A hash function will run
over the data and produce an arbitrary hash value H1 which is then attached to the data. When Host
‘B’ receives the packet, it runs the same hash function over the data which gives a hash value of H2.
Now, if H1 = H2, this means that the data’s integrity has been maintained and the contents were not
modified.
Availability
This means that the network should be readily available to its users. This applies to systems and to
data. To ensure availability, the network administrator should maintain hardware, make regular
upgrades, have a plan for fail-over, and prevent bottlenecks in a network. Attacks such as DoS or
DDoS may render a network unavailable as the resources of the network get exhausted. The impact
may be significant to the companies and users who rely on the network as a business tool. Thus,
proper measures should be taken to prevent such attacks.
Reasons behind cyber attacks
Every business, regardless of its size, is a potential target of cyber attack. That is because every
business has key assets (financial or otherwise) that criminals may seek to exploit. By recognising the
common motives behind cyber attacks, you can build a better understanding of the risks you may
face, and understand how best to confront them.
Why do cyber attacks happen?
Most often, cyber attacks happen because criminals want your:
business' financial details
customers' financial details (eg credit card data)
sensitive personal data
customers' or staff email addresses and login credentials
customer databases
clients lists
IT infrastructure
IT services (eg the ability to accept online payments)
intellectual property (eg trade secrets or product designs)
Cyber attacks against businesses are often deliberate and motivated by financial gain. However, other
motivations may include:
making a social or political point - eg through hacktivism
espionage - eg spying on competitors for unfair advantage
intellectual challenge - eg 'white hat' hacking
The key point is that cyber security threats don't always come from anonymous hackers or online
criminal groups. Vulnerabilities can arise within your own business too.
How are cyber criminals motivated?
1. Financial Gain
The primary motivation of a hacker is money, and getting it can be done with a variety of methods.
They could directly gain entry to a bank or investment account; steal a password to your financial
sites and then transfer the assets over to one of their own; swindle an employee into completing a
money transfer through a complicated spear phishing technique, or conduct a ransomware attack on
your entire organization.
The possibilities are endless, but most hackers are out to make a profit.
2. Recognition & Achievement
Some hackers are motivated by the sense of achievement that comes with cracking open a major
system. Some may work in groups or independently, but, on some scale, they would like to be
recognized.
This also ties into the fact that cyber criminals are competitive by nature, and they love the challenge
their actions bring. In fact, they often drive one another to complete more complicated hacks.
3. Insider Threats
Individuals who have access to critical information or systems can easily choose to misuse that access
—to the detriment of their organization.
These threats can come from internal employees, vendors, a contractor or a partner—and are viewed
as some of the greatest cyber security threats to organizations.
However, not all insider threats are intentional, according to an Insider Threat Report from Crowd
Research Partners. Most (51%) are due to carelessness, negligence, or compromised credentials, but
the potential impact is still present even in an unintentional scenario.
4. Political Motivation – “Hacktivism”
Some cyber criminal groups use their hacking skills to go after large organizations. They are usually
motivated by a cause of some sort, such as highlighting human rights or alerting a large corporation to
their system vulnerabilities. Or, they may go up against groups whose ideologies do not align with
their own.
These groups can steal information and argue that they are practicing free speech, but more often than
not, these groups will employ a DDoS (Distributed Denial of Service) attack to overload a website
with too much traffic and cause it to crash.
5. State Actors
State-sponsored actors receive funding and assistance from a nation-state. They are specifically
engaged in cyber crime to further their nation’s own interests. Typically, they steal information,
including “intellectual property, personally identifying information, and money to fund or further
espionage and exploitation causes.”
However, some state-sponsored actors do conduct damaging cyberattacks and claim that their
cyberespionage actions are legitimate activity on behalf of the state.
6. Corporate Espionage
This is a form of cyber attack used to gain an advantage over a competing organization.
Conducted for commercial or financial purposes, corporate espionage involves:
Acquiring property like processes or techniques, locations, customer data, pricing, sales,
research, bids, or strategies
Theft of trade secrets, bribery, blackmail, or surveillance.
Preserving Privacy:
In an era where personal information is increasingly collected, stored, and shared digitally,
cybersecurity is crucial for preserving privacy. Protecting personal data from unauthorized access,
surveillance, and misuse helps maintain individuals’ privacy rights and fosters trust in digital services.
cybercriminals
A cybercriminal is a person who conducts some form of illegal activity using computers or other
digital technology such as the Internet. The criminal may use computer expertise, knowledge of
human behavior, and a variety of tools and services to achieve his or her goal.
Types of Cyber Criminals:
1. Hackers: The term hacker may refer to anyone with technical skills, however, it typically refers to
an individual who uses his or her skills to achieve unauthorized access to systems or networks so as to
commit crimes. The intent of the burglary determines the classification of those attackers as white,
grey, or black hats. White hat attackers burgled networks or PC systems to get weaknesses so as to
boost the protection of those systems. The owners of the system offer permission to perform the
burglary, and they receive the results of the take a look at. On the opposite hand, black hat attackers
make the most of any vulnerability for embezzled personal, monetary or political gain. Grey hat
attackers are somewhere between white and black hat attackers. Grey hat attackers could notice a
vulnerability and report it to the owners of the system if that action coincides with their agenda.
(a). White Hat Hackers – These hackers utilize their programming aptitudes for a good and
lawful reason. These hackers may perform network penetration tests in an attempt to
compromise networks to discover network vulnerabilities. Security vulnerabilities are then
reported to developers to fix them and these hackers can also work together as a blue team.
They always use the limited amount of resources which are ethical and provided by the
company, they basically perform pentesting only to check the security of the company from
external sources.
(b). Gray Hat Hackers – These hackers carry out violations and do seemingly deceptive
things however not for individual addition or to cause harm. These hackers may disclose a
vulnerability to the affected organization after having compromised their network and they
may exploit it .
(c). Black Hat Hackers – These hackers are unethical criminals who violate network security
for personal gain. They misuse vulnerabilities to bargain PC frameworks. theses hackers
always exploit the information or any data they got from the unethical pentesting of the
network.
2. Organized Hackers: These criminals embody organizations of cyber criminals, hacktivists,
terrorists, and state-sponsored hackers. Cyber criminals are typically teams of skilled criminals
targeted on control, power, and wealth. These criminals are extremely subtle and organized, and
should even give crime as a service. These attackers are usually profoundly prepared and well-
funded.
3. Internet stalkers: Internet stalkers are people who maliciously monitor the web activity of their
victims to acquire personal data. This type of cyber crime is conducted through the use of social
networking platforms and malware, that are able to track an individual’s PC activity with little or no
detection.
4. Disgruntled Employees: Disgruntled employees become hackers with a particular motive and also
commit cyber crimes. It is hard to believe that dissatisfied employees can become such malicious
hackers. In the previous time, they had the only option of going on strike against employers. But with
the advancement of technology there is increased in work on computers and the automation of
processes, it is simple for disgruntled employees to do more damage to their employers and
organization by committing cyber crimes. The attacks by such employees brings the entire system
down.
Classification of cybercrimes
It can be classified in to 4 major categories as
1. Cyber crime against Individual
2. Cyber crime Against Property
3. Cyber crime Against Organization
4. Cyber crime Against Society
1. Against Individuals
1. Email spoofing :
A spoofed email is one in which e-mail header is forged so that mail appears to
originate from one source but actually has been sent from another source
2. Spamming :
Spamming means sending multiple copies of unsolicited mails or mass e-mails such
as chain letters.
3. Cyber Defamation :
This occurs when defamation takes place with the help of computers and / or the
Internet. E.g. someone publishes defamatory matter about someone on a website or
sends e-mails containing defamatory information.
4. Harassment & Cyber stalking :
Cyber Stalking Means following the moves of an individual’s activity over internet. It
can be done with the help of many protocols available such at e- mail, chat rooms,
user net groups.
2. Against Property:
1. Credit Card Fraud : As the name suggests, this is a fraud that happens by the use of
a credit card. This generally happens if someone gets to know the card number or the
card gets stolen.
Cyber laws
Cyber law, also known as internet law or digital law, signifies the legal regulations and frameworks
governing digital activities. It covers a large range of issues, including online communication, e-
commerce, digital privacy, and the prevention and prosecution of cybercrimes.
Types of Cyber Law
Privacy Laws:
Privacy laws focus on protecting individuals' personal information from unauthorized access and use.
They establish guidelines for the responsible handling of personal data by organizations, ensuring
individuals' privacy rights are upheld.
Cybercrime Laws:
Cybercrime laws define and penalize various cybercrimes, ensuring legal consequences for offenders.
These laws play a crucial role in deterring individuals from engaging in illegal online activities and
provide a legal framework for prosecuting cybercriminals.
Intellectual Property Laws:
Intellectual property laws in the digital domain protect patents, copyrights, and trademarks from
unauthorized use. They provide a legal foundation for creators and innovators to protect their digital
assets.
E-commerce Laws:
E-commerce laws regulate online business transactions, defining rules for contracts, transactions, and
consumer protection. These laws contribute to the establishment of a secure and fair online
marketplace.
Cyber Defamation Laws:
Cyber defamation laws address libel and slander in the digital space. They provide legal remedies for
individuals or entities whose reputations may be tarnished by false or damaging information
circulated online.
Cybersecurity Laws:
Cybersecurity laws establish standards for securing digital systems and data. These laws mandate
organizations to implement measures to protect against cyber threats, contributing to the overall
resilience of digital infrastructure.
Social Media Laws:
Social media laws address legal issues related to social media platforms, including user rights and
content regulations. These laws aim to strike a balance between freedom of expression and the
prevention of online abuse or misinformation.
Cyber Contracts and E-signature Laws:
Governing the validity and enforceability of contracts formed online, cyber contracts and e-
signature laws provide legal certainty for electronic transactions. They facilitate the growth of online
commerce by ensuring the legal recognition of digital agreements.
International Cyber Laws:
With the increasing prevalence of cross-border cybercrimes, international cyber laws address the need
for cooperation between nations. These laws facilitate collaboration in investigating and prosecuting
cybercriminals operating across borders.
Data Breach Notification Laws:
Mandating organizations to inform individuals and authorities in the event of a data breach of data
breach notification laws enhances transparency and accountability. They ensure prompt action in
response to security incidents, minimizing the potential impact on individuals and businesses.
What is OWASP?
The Open Web Application Security Project, or OWASP, is an international non-profit organization
dedicated to web application security. One of OWASP’s core principles is that all of their materials be
freely available and easily accessible on their website, making it possible for anyone to improve their
own web application security. The materials they offer include documentation, tools, videos, and
forums. Perhaps their best-known project is the OWASP Top 10.
What is the OWASP Top 10?
The OWASP Top 10 is a regularly-updated report outlining security concerns for web application
security, focusing on the 10 most critical risks. The report is put together by a team of security experts
from all over the world. OWASP refers to the Top 10 as an ‘awareness document’ and they
recommend that all companies incorporate the report into their processes in order to minimize and/or
mitigate security risks.
Security breach
A security breach is any incident that results in unauthorized access to computer data, applications,
networks or devices. It results in information being accessed without authorization. Typically, it
occurs when an intruder is able to bypass security mechanisms.
Technically, there's a distinction between a security breach and a data breach. A security breach is
effectively a break-in, whereas a data breach is defined as the cybercriminal getting away with
information. Imagine a burglar; the security breach is when he climbs through the window, and the
data breach is when he grabs your pocketbook or laptop and takes it away.
Confidential information has immense value. It's often sold on the dark web; for example, names and
credit card numbers can be bought, and then used for the purposes of identity theft or fraud. It's not
surprising that security breaches can cost companies huge amounts of money. On average, the bill is
nearly $4m for major corporations.
It's also important to distinguish the security breach definition from the definition of a security
incident. An incident might involve a malware infection, DDOS attack or an employee leaving a
laptop in a taxi, but if they don't result in access to the network or loss of data, they would not count
as a security breach.
Examples of a security breach
When a major organization has a security breach, it always hits the headlines. Security breach
examples include the following:
Equifax - in 2017, a website application vulnerability caused the company to lose the personal
details of 145 million Americans. This included their names, SSNs, and drivers' license
numbers. The attacks were made over a three-month period from May to July, but the security
breach wasn't announced until September.
Yahoo - 3 billion user accounts were compromised in 2013 after a phishing attempt gave
hackers access to the network.
eBay saw a major breach in 2014. Though PayPal users' credit card information was not at
risk, many customers' passwords were compromised. The company acted quickly to email its
users and ask them to change their passwords in order to remain secure.
Dating site Ashley Madison, which marketed itself to married people wishing to have affairs,
was hacked in 2015. The hackers went on to leak a huge number of customer details via the
internet. Extortionists began to target customers whose names were leaked; unconfirmed
reports have linked a number of suicides to exposure by the data breach.
Facebook saw internal software flaws lead to the loss of 29 million users' personal data in
2018. This was a particularly embarrassing security breach since the compromised accounts
included that of company CEO Mark Zuckerberg.
Marriott Hotels announced a security and data breach affecting up to 500 million customers'
records in 2018. However, its guest reservations system had been hacked in 2016 - the breach
wasn't discovered until two years later.
Perhaps most embarrassing of all, being a cybersecurity firm doesn't make you immune
- Czech company Avast disclosed a security breach in 2019 when a hacker managed to
compromise an employee's VPN credentials. This breach didn't threaten customer details but
was instead aimed at inserting malware into Avast's products.
A decade or so ago, many companies tried to keep news of security breaches secret in order not to
destroy consumer confidence. However, this is becoming increasingly rare. In the EU, the GDPR
(General Data Protection Regulations) require companies to notify the relevant authorities of a breach
and any individuals whose personal data might be at risk. By January 2020, GDPR had been in effect
for just 18 months, and already, over 160,000 separate data breach notifications had been made - over
250 a day.
Types of security breaches
There are a number of types of security breaches depending on how access has been gained to the
system:
An exploit attacks a system vulnerability, such as an out of date operating system. Legacy
systems which haven't been updated, for instance, in businesses where outdated and versions
of Microsoft Windows that are no longer supported are being used, are particularly vulnerable
to exploits.
Weak passwords can be cracked or guessed. Even now, some people are still using the
password 'password', and 'pa$$word' is not much more secure.
Malware attacks, such as phishing emails can be used to gain entry. It only takes one
employee to click on a link in a phishing email to allow malicious software to start spreading
throughout the network.
Drive-by downloads use viruses or malware delivered through a compromised or spoofed
website.
Social engineering can also be used to gain access. For instance, an intruder phones an
employee claiming to be from the company's IT helpdesk and asks for the password in order
to 'fix' the computer.
In the security breach examples we mentioned above, a number of different techniques were used to
gain access to networks — Yahoo suffered a phishing attack, while Facebook was hacked by an
exploit.
Though we've been talking about security breaches as they affect major organizations, the same
security breaches apply to individuals' computers and other devices. You're probably less likely to be
hacked using an exploit, but many computer users have been affected by malware, whether
downloaded as part of a software package or introduced to the computer via a phishing attack. Weak
passwords and use of public Wi-Fi networks can lead to internet communications being compromised.
What to do if you experience a security breach
As a customer of a major company, if you learn that it has had a security breach, or if you find out that
your own computer has been compromised, then you need to act quickly to ensure your safety.
Remember that a security breach on one account could mean that other accounts are also at risk,
especially if they share passwords or if you regularly make transactions between them.
If a breach could involve your financial information, notify any banks and financial
institutions with which you have accounts.
Change the passwords on all your accounts. If there are security questions and answers or
PIN codes attached to the account, you should change these too.
You might consider a credit freeze. This stops anyone using your data for identity theft and
borrowing in your name.
Check your credit report to ensure you know if anyone is applying for debt using your
details.
Try to find out exactly what data might have been stolen. That will give you an idea of the
severity of the situation. For instance, if tax details and SSNs have been stolen, you'll need to
act fast to ensure your identity isn't stolen. This is more serious than simply losing your credit
card details.
Don'trespond directly to requests from a company to give them personal data after a
data breach; it could be a social engineering attack. Take the time to read the news, check the
company's website, or even phone their customer service line to check if the requests are
legitimate.
Be on your guard for other types of social engineering attacks. For instance, a criminal
who has accessed a hotel's accounts, even without financial data, could ring customers asking
for feedback on their recent stay. At the end of the call, having established a relationship of
trust, the criminal could offer a refund of parking charges and ask for the customer's card
number in order to make the payment. Most customers probably wouldn't think twice about
providing those details if the call is convincing.
Monitor your accounts for signs of any new activity. If you see transactions that you don't
recognize, address them immediately.
Types of Malware
1. Viruses – A Virus is a malicious executable code attached to another executable file. The
virus spreads when an infected file is passed from system to system. Viruses can be harmless
or they can modify or delete data. Opening a file can trigger a virus. Once a program virus is
active, it will infect other programs on the computer.
2. Worms – Worms replicate themselves on the system, attaching themselves to different files
and looking for pathways between computers, such as computer network that shares common
file storage areas. Worms usually slow down networks. A virus needs a host program to run
but worms can run by themselves. After a worm affects a host, it is able to spread very
quickly over the network.
3. Trojan horse – A Trojan horse is malware that carries out malicious operations under the
appearance of a desired operation such as playing an online game. A Trojan horse varies from
a virus because the Trojan binds itself to non-executable files, such as image files, and audio
files.
4. Ransomware – Ransomware grasps a computer system or the data it contains until the victim
makes a payment. Ransomware encrypts data in the computer with a key that is unknown to
the user. The user has to pay a ransom (price) to the criminals to retrieve data. Once the
amount is paid the victim can resume using his/her system
5. Adware – It displays unwanted ads and pop-ups on the computer. It comes along with
software downloads and packages. It generates revenue for the software distributer by
displaying ads.
6. Spyware – Its purpose is to steal private information from a computer system for a third
party. Spyware collects information and sends it to the hacker.
7. Logic Bombs – A logic bomb is a malicious program that uses a trigger to activate the
malicious code. The logic bomb remains non-functioning until that trigger event happens.
Once triggered, a logic bomb implements a malicious code that causes harm to a computer.
Cybersecurity specialists recently discovered logic bombs that attack and destroy the
hardware components in a workstation or server including the cooling fans, hard drives, and
power supplies. The logic bomb overdrives these devices until they overheat or fail.
8. Rootkits – A rootkit modifies the OS to make a backdoor. Attackers then use the backdoor to
access the computer distantly. Most rootkits take advantage of software vulnerabilities to
modify system files.
9. Backdoors – A backdoor bypasses the usual authentication used to access a system. The
purpose of the backdoor is to grant cyber criminals future access to the system even if the
organization fixes the original vulnerability used to attack the system.
10. Keyloggers – Keylogger records everything the user types on his/her computer system to
obtain passwords and other sensitive information and send them to the source of the
keylogging program.
RootKits:
Collection of tools that allow an attacker to take control of a system.
Can be used to hide evidence of an attacker’s presence and give them backdoor access.
Can contain log cleaners to remove traces of attacker.
Can be divided as:
– Application or file rootkits: replaces binaries in Linux system
– Kernel: targets kernel of OS and is known as a loadable kernel module (LKM)
Gains control of infected m/c by:
– DLL injection: by injecting malicious DLL (dynamic link library)
– Direct kernel object manipulation: modify kernel structures and directly target trusted part
of OS
– Hooking: changing applicant’s execution flow
Advanced Persistent Threat:
Created by well funded, organized groups, nation-state actors, etc. Desire to compromise government
and commercial entities, e.g. Flame: used for reconnaissance and information gathering of system.
Spyware and Adware:
Normally gets installed along with free software downloads. Spies on the end-user, attempts to
redirect the user to specific sites. Main tasks: Behavioral surveillance and advertising with pop up ads
Slows down the system.
A social engineering attack is a cybersecurity attack that relies on the psychological manipulation of
human behavior to disclose sensitive data, share credentials, grant access to a personal device or
otherwise compromise their digital security.
Social engineering attacks pose a great threat to cybersecurity since many attacks begin on a personal
level and rely on human error to advance the attack path. By invoking empathy, fear and urgency in
the victim, adversaries are often able to gain access to personal information or the endpoint itself. If
the device is connected to a corporate network or contains credentials for corporate accounts, this can
also provide adversaries with a pathway to enterprise-level attacks.
With cyber criminals devising ever-more manipulative methods for tricking people and employees,
organizations must stay ahead of the game. In this post, we will explore ten of the most common types
of social engineering attacks:
1. Phishing
2. Whaling
3. Baiting
4. Diversion Theft
5. Business Email Compromise (BEC)
6. Smishing
7. Quid Pro Quo
8. Pretexting
9. Honeytrap
10. Tailgating/Piggybacking
Pretexting. One party lies to another to gain access to privileged data. For example, a
pretexting scam could involve an attacker who pretends to need financial or personal data to
confirm the identity of the recipient.
Scareware. This involves tricking the victim into thinking their computer is infected with
malware or has inadvertently downloaded illegal content. The attacker then offers the victim a
solution that will fix the bogus problem; in reality, the victim is simply tricked into
downloading and installing the attacker's malware.
Watering hole. The attacker attempts to compromise a specific group of people by infecting
websites they are known to visit and trust with the goal of gaining network access.
Diversion theft. In this type of attack, social engineers trick a delivery or courier company
into going to the wrong pickup or drop-off location, thus intercepting the transaction.
Quid pro quo. This is an attack in which the social engineer pretends to provide something in
exchange for the target's information or assistance. For instance, a hacker calls a selection
of random numbers within an organization and pretends to be a technical support specialist
responding to a ticket. Eventually, the hacker will find someone with a legitimate tech issue
whom they will then pretend to help. Through this interaction, the hacker can have the target
type in the commands to launch malware or can collect password information.
Honey trap. In this attack, the social engineer pretends to be an attractive person to interact
with a person online, fake an online relationship and gather sensitive information through that
relationship.
Tailgating. Sometimes called piggybacking, tailgating is when a hacker walks into a secured
building by following someone with an authorized access card. This attack presumes the
person with legitimate access to the building is courteous enough to hold the door open for
the person behind them, assuming they are allowed to be there.
Rogue security software. This is a type of malware that tricks targets into paying for the fake
removal of malware.
Dumpster diving. This is a social engineering attack whereby a person searches a company's
trash to find information, such as passwords or access codes written on sticky notes or scraps
of paper, that could be used to infiltrate the organization's network.
Pharming. With this type of online fraud, a cybercriminal installs malicious code on a
computer or server that automatically directs the user to a fake website, where the user may
be tricked into providing personal information.
Harvester
Harvester is an information-gathering tool that is built by the guys at edge security and is included by
default in Kali Linux. The goal of this tool is to find and gather all email
addresses, subdomains, hosts, ports, employee names, and banners that can provide information about
the
target. This tool is intended to help Penetration testers in the early stages of the penetration test in orde
r to understand the customer footprint on the Internet. It is also useful for anyone that wants to know
what an attacker can see about their organization.
Note: But the unique part is that Harvester doesn’t use any advanced algorithms to crack passwords, t
est firewalls, or sniff data on networks. Instead, it gathers public information available on the internet
automatically.
# Why do we gather information?
Well, in any pentesting task, the first thing you need to do is know your target. The more information
we have about the target, the easier it is to hack the target victim. We can find useful information like t
he email address to target for phishing or which domains are vulnerable on the company network. We
can also use this information for social engineering attacks which are at the top of every hacker’s
arsenal By using this tool critical information that companies knowing or unknowingly disclose can
be obtained legally and used to understand the target.
This tool is designed to help the penetration tester on an earlier stage; it is effective, simple and easy
to use. The sources supported are:
1. Google – emails, subdomains
2. Google profiles – Employee names
3. Bing search – emails, subdomains/hostnames, virtual hosts
4. Pgp servers – emails, subdomains/hostnames
5. LinkedIn – Employee names
6. Exalead – emails, subdomains/hostname
# Usage of The Harvester Tool in linux with examples:
1.For finding Email Ids:
Command:
:
Result:
Whois Lookup
In this section, we are going to have a look at is Whois Lookup. It is a protocol that is used to find the
owners of internet resources, for example, a domain, a server, an IP address. In this, we are not
actually hacking, we are just retrieving information from a database about owners of stuff on the
internet. For example, if we wanted to register a domain name like zaid.com we have to supply
information about the person who is signing in like address, and then the domain name will be stored
in our name and people will see that Zaid owns the domain name. That is all we are going to do.
Port scanning
A port scan is a common technique hackers use to discover open doors or weak points in a network. A
port scan attack helps cyber criminals find open ports and figure out whether they are receiving or
sending data. It can also reveal whether active security devices like firewalls are being used by an
organization.
When hackers send a message to a port, the response they receive determines whether the port is
being used and if there are any potential weaknesses that could be exploited.
Businesses can also use the port scanning technique to send packets to specific ports and analyze
responses for any potential vulnerability. They can then use tools like IP scanning, network mapper
(Nmap), and Netcat to ensure their network and systems are secure.
Port scanning can provide information such as:
1. Services that are running
2. Users who own services
3. Whether anonymous logins are allowed
4. Which network services require authentication
What is a Port?
A port is a point on a computer where information exchange between multiple programs and the
internet to devices or other computers takes place. To ensure consistency and simplify programming
processes, ports are assigned port numbers. This, in conjunction with an IP address, forms vital
information that each internet service provider (ISP) uses to fulfill requests.
Port numbers range from 0 through to 65,536 and are ranked in terms of popularity. Ports numbered 0
to 1,023 are called “well-known" ports, which are typically reserved for internet usage but can also
have specialized purposes. These ports, which are assigned by the Internet Assigned Numbers
Authority (IANA), are held by leading businesses and Structured Query Language (SQL) services.
Ports are generally managed by the Transmission Control Protocol (TCP), which defines how to
establish and maintain a network conversation between applications, and User Datagram Protocol
(UDP), which is primarily used for establishing low-latency and loss-tolerating connections between
applications. Some of the most popular and most frequently used ports include:
1. Port 20 (UDP): File Transfer Protocol (FTP) used for transferring data
2. Port 22 (TCP): Secure Shell (SSH) protocol used for FTP, port forwarding, and secure logins
3. Port 23 (TCP): The Telnet protocol used for unencrypted communication
4. Port 53 (UDP): The Domain Name System (DNS), which translates internet domain names
into machine-readable IP addresses
5. Port 80 (TCP): The World Wide Web Hypertext Transfer Protocol (HTTP)
Ports numbered from 1,024 to 49,151 are considered “registered ports,” and they are registered by
software companies. The ports numbered from 49,152 to 65,536 are considered dynamic and private
ports, which can be used by almost everyone on the internet.
What type of port scan results can you get from port scanning?
Port scan results reveal the status of the network or server and can be described in one of three
categories: open, closed, or filtered.
Open ports: Open ports indicate that the target server or network is actively accepting
connections or datagrams and has responded with a packet that indicates it is listening. It also
indicates that the service used for the scan (typically TCP or UDP) is in use as well.
Finding open ports is typically the overall goal of port scanning and a victory for a
cybercriminal looking for an attack avenue. The challenge for IT administrators is trying to
barricade open ports by installing firewalls to protect them without limiting access for
legitimate users.
Closed ports: Closed ports indicate that the server or network received the request, but there
is no service “listening” on that port. A closed port is still accessible and can be useful in
showing that a host is on an IP address. IT administrators should still monitor closed ports as
they could change to an open status and potentially create vulnerabilities. IT administrators
should consider blocking closed ports with a firewall, where they would then become
“filtered” ports.
Filtered ports: Filtered ports indicate that a request packet was sent, but the host did not
respond and is not listening. This usually means that a request packet was filtered out and/or
blocked by a firewall. If packets do not reach their target location, attackers cannot find out
more information. Filtered ports often respond with error messages reading “destination
unreachable” or “communication prohibited.”
Network Scanning
Network scanning is the process of troubleshooting the active devices on your system for
vulnerabilities. It identifies and examines the connected devices by deploying one or more features in
the network protocol. These features pick up vulnerability signals and give you feedback on the
security status of your network.
Network scanning facilitates system maintenance, monitoring, and security assessments. When
implemented effectively, network scanning gives you insights into some of the best ways to protect
your network against cyberattacks.
How Does Network Scanning Work?
Network scanning is simplified with innovative solutions. One way to implement network scanning
without breaking your back is the use of network administrators.
Network administrators scan your network to evaluate IP addresses and detect live hosts connected to
it.
Keep in mind that cybercriminals use the same technique to spot weaknesses in your network. The
idea is to identify the loopholes before the bad guys discover them.
For network administrators to identify how IP addresses are mapped in the network, they may need to
use tools such as Nmap.
Nmap is an effective network scanning tool that uses IP packets to detect devices attached to a
network. It helps to simplify the mapping of IP addresses.
You can use network scanners to inspect where the network is stronger or weaker in your workplace
with the help of network administrators.
A basic working rule of network scanning is to identify all devices on a network and map their IP
addresses. To do this, you must use the network scanner to forward a packet to all available IP
addresses connected to the network.
After sending this ping, you need to wait for their response. Once the feedback arrives, the network
scanner uses them to measure the status and inconsistencies of the host or application. During this
process, the responding devices are active while the non-responding devices are inactive.
Network administrators can also use Address Resolution Protocol (ARP) scan to evaluate the system
manually. But if the goal of the network administrator is to reach all active hosts, it's advisable to use
tools that support automatic running scans.
One of the best tools that you can use to attain such a milestone is the Internet Control Message
Protocol (ICMP) scan. It helps you map the network accurately without failure.
Many security-conscious companies allocate high budgets to advanced network scanning tools to
secure their networking systems. But they may not get the desired results if they make the wrong
choice. The effective scanning tools you should consider include, Acunetix, Nikto, Spyse, Swascan, IP
Address Manager, and SolarWinds Network Performance Monitor.
Types of Network Scanners
Scanning your network properly requires using the right tools and methods. Each method is
determined by what you want to achieve with your scanning. There are two major kinds of network
scanning—port scanning and vulnerability scanning.
1. Port Scanning
Port scanning enables you to identify open ports in a network that can receive or send data. You can
use it to send packets to targeted ports on a device. This process highlights loopholes and analyzes
performance feedback.
Before implementing port scanning, you have to identify the list of active devices and maps to their IP
addresses.
The primary goal of port scanning is to use the data it acquires from active devices to diagnose
security levels.
2. Vulnerability Scanning
Vulnerability scanning helps you to detect vulnerabilities that exist on your network. Running a check
on your system exposes threats that were hidden away from you.
In most organizations, vulnerability scanning is conducted by the IT department. But if you want to
get thorough feedback, consider hiring a third-party security expert. Since they aren't familiar with
your network, they'll conduct an objective analysis from an outsider's perspective.
Vulnerability scanning can also be performed by cyberattackers intending to identify weak spots in
your network. Beat them to it by identifying and closing the weak links.
Besides identifying loopholes, vulnerability scanning also evaluates the security capacity of your
network against cyberattacks. It uses a database to analyze possible attacks. This database provides
the vulnerability scanner with packet construction anomalies, flaws, default configurations, paths to
sensitive data, and coding bugs that can enable cyber attackers to exploit your network.
What Are the Benefits of Network Scanning?
Like most innovative solutions, network scanning offers several benefits. One thing is certain—it
gives your system a better footing. In what ways exactly, though? Let's take a look.
1. Increased Network Performance
Network scanning plays a key role in increasing network performance and maximizing the speed of
network operations.
In a complex organizational network, multiple subnets of various IP addresses are assigned to several
devices to improve their performance on the system. Scanning these devices helps to remove clogs
and creates a free flow for optimal performance.
2. Protection Against Cyberattacks
Network scanning is so useful that cybercriminals also use it to discover vulnerabilities in a network.
When you fail to scan your network for threats and vulnerabilities, you're indirectly inviting attackers
for a visit.
Carrying out regular network scanning is an effective way to keep your system free from
cyberattacks. It's similar to implementing intrusion detection systems to spot emerging threats.
3. Save Time and Money
Scanning your network manually is tedious and time-consuming. The scanning process could linger
for long. Your work is on hold, making you lose money in the long run.
Network scanning is an automated process. It evaluates tons of data within a short time. You get it
over with as soon as possible and keep your workflow moving.
The purpose of network scanning is as follows:
Recognize available UDP and TCP network services running on the targeted hosts
Recognize filtering systems between the user and the targeted hosts
Determine the operating systems (OSs) in use by assessing IP responses
Evaluate the target host’s TCP sequence number predictability to determine sequence
prediction attack and TCP spoofing
Scanning methodology
1. Check for live systems. Something as simple as a ping can provide this. This gives you a list of
what’s actually alive on your network subnet.
2. Check for open ports. Once you know which IP addresses are active, find what ports
they’re listening on.
3. Scan beyond IDS. Sometimes your scanning efforts need to be altered to avoid those
pesky intrusion detection systems.
4. Perform banner grabbing. Banner grabbing and OS fingerprinting will tell you what operating
system is on the machines and which services they are running.
5. Scan for vulnerabilities. Perform a more focused look at the vulnerabilities these machines haven’t
been patched for yet.
6. Draw network diagrams. A good network diagram will display all the logical and physical
pathways to targets you might like.
Source: https://www.safaribooksonline.com
Nmap command: nmap -sS -v <TargetIp>
XMAS scan: This is also called as inverse TCP scanning. This works by sending packets set with
PSH, URG, FIN flags. The targets do not respond if the ports are open and send a reset response if
ports are closed.
Source: https://www.information-security.fr
FIN scan: Fin flag is set in the TCP packets sent to the target. open ports doe does not respond while
closed ports send a reset response.
Source: https://securitcrs.wordpress.com
Nmap command: nmap -SF <targetIp>
ACK scan: Here the attacker sets the ACK flag in the TCP header and the target's port status is
gathered based on window size and TTL value of RESET packets received from the target.
Source: https://www.hackingloops.com
Nmap command: nmap -SA -v <targetip>
Null Scan: Works by sending TCP packets with no flags set to the target. Open ports do not respond
while closed ports respond with a RESET packet.
Source: https://en.wikipedia.org/wiki/Idle_scan
Nmap command : nmap -Pn -sI ZombieIp TargetIp
Banner Grabbing
Banner grabbing is a process of collecting information like operating system details, the name of the
service running with its version number etc.
Vulnerability scanning:
Mainly automated tools are used for this purpose. These automated scanners scan the target to find out
vulnerabilities or weakness in the target organization which can be exploited by the attackers.
Vulnerabilities include application vulnerabilities, configuration vulnerabilities, network
vulnerabilities, operating system vulnerabilities etc.
Some examples include operating system is not updated, default passwords used, plain text protocols
used, vulnerable protocols running etc.
Tools: Nessus, Acunetix
Draw Network Diagrams
With the information gathered, the attacker can come up with a network diagram which might give
him information about network and architecture of the target organization helping him to identify the
target easily
Tools: Network View, Opmanager etc
Prepare Proxies
Proxies can use to maintain the anonymity of the attacker by masking the IP address. It can capture
information passing through it since it acts as an intermediary between client and server and the
attacker can access the resources remotely using the proxies.
Eg: TOR browsers, Onion sites etc, Proxify, Psiphon etc
Countermeasures:
Configure IDS and firewall to block probes.
Keep firewall, routers, IDS firmware update
Run port scanners to verify the security of the target.
Add rules in firewall restricting access to ports.
Disable ICMP based scanning at firewall.
XMAS - XMAS scans send a packet with the FIN, URG, and PSH flags set. If the port is open, there
is no response; but if the port is closed, the target responds with a RST/ACK packet. XMAS scans
work only on target systems that follow the RFC 793 implementation of TCP/IP and don’t work
against any version of Windows.
FIN - A FIN scan is similar to an XMAS scan but sends a packet with just the FIN flag set. FIN scans
receive the same response and have the same limitations as XMAS scans. FIN A FIN scan is similar
to an XMAS scan but sends a packet with just the FIN flag set. FIN scans receive the same response
and have the same limitations as XMAS scans.
NULL - A NULL scan is also similar to XMAS and FIN in its limitations and response, but it just
sends a packet with no flags set.
IDLE - An IDLE scan uses a spoofed IP address to send a SYN packet to a target. Depending on the
response, the port can be determined to be open or closed. IDLE scans determine port scan response
by monitoring IP header sequence numbers.
IPEye is a TCP port scanner that can do SYN, FIN, Null, and XMAS scans. It’s a commandline tool.
IPEye probes the ports on a target system and responds with closed, reject, drop, or open. Closed
means there is a computer on the other end, but it doesn’t listen at the port. Reject means a firewall is
rejecting the connection to the port (sending a reset back). Drop means a firewall is dropping
everything to the port, or there is no computer on the other end. Open means some kind of service is
listening at the port. These responses help a hacker identify what type of system is responding.
IPSecScan is a tool that can scan either a single IP address or a range of addresses looking for systems
that are IPSec enabled.
NetScan Tools Pro, hping2, KingPingicmpenum, and SNMP Scanner are all scanning tools and can
also be used to fingerprint the operating system (discussed later).
Icmpenum uses not only ICMP Echo packets to probe networks, but also ICMP Timestamp and ICMP
Information packets. Furthermore, it supports spoofing and sniffing for reply packets. Icmpenum is
great for scanning networks when the firewall blocks ICMP Echo packets but fails to block
Timestamp or Information packets.
The hping2 tool is notable because it contains a host of other features besides OS fingerprinting such
as TCP, User Datagram Protocol (UDP), ICMP, and raw-IP ping protocols, traceroute mode, and the
ability to send files between the source and target system.
SNMP Scanner allows you to scan a range or list of hosts performing ping, DNS, and Simple Network
Management Protocol (SNMP) queries.
Banner grabbing
Banner grabbing is a method used by attackers and security teams to obtain information about
network computer systems and services running on open ports. A banner is a text displayed by a host
that provides details such as the type and version of software running on the system or server. The
screen displays the software version number on the network server and other system information,
giving cybercriminals an advantage in cyber attacks. Banner grabbing considers collecting software
banner information such as name and version. Hackers can use the OSINT tool to get the banners
manually or automatically. Banner capture is one of the essential steps in both offensive and defensive
penetration testing environments.
Types of Banner Grabbing:
1. Active Banner Grabbing: In this method, Hackers send packets to a remote server and
analyze the response data. The attack involves opening a TCP or similar connection between
the origin and the remote server. An Intrusion Detection System (IDS) can easily detect an
active banner.
2. Passive Banner Capture: This method allows hackers and security analysts to get the same
information while avoiding disclosing the original connection. In passive banner grabbing, the
attackers deploy software and malware as a gateway to prevent direct connection when
collecting data from the target. This technique uses third-party network tools and services to
capture and analyze packets to identify the software and version being used. run on the server.
Usage:
Hackers can perform a banner-grabbing attack against various protocols to discover insecure and
vulnerable applications and exploits. There are many services, protocols, and types of banner
information that you can collect using banner grabbing. You can develop various methods and tools
for the discovery process. In general, banner grab allows an attacker to discover network servers and
services running along with their instances on open ports, as well as the operating system. Given the
type and version of an application, a hacker, or pen tester, can quickly scan for known and exploitable
vulnerabilities in that version.
Service Ports:
Port 80 is running on Hypertext Transfer Protocol (HTTP) service.
Port 21 is running on the File Transfer Protocol (FTP) service.
Port 25 runs on the Simple Mail Transfer Protocol (SMTP) service.
Important Points:
Banner Grabbing is used in Ethical Hacking to gather information about a target system
before launching an attack.
In order to gather this information, the Hacker must choose a website that displays banners
from affiliate sites and navigate from the banner to the site served by the affiliate website.
Banner Grabbing can be done through manual means or through the use of automated tools
such as web crawlers, which search websites and download everything on them, including
banners and files.
OS Fingerprinting
If a hacker can determine what type of operating system a targeted computer is running, he or she can
work to exploit the vulnerabilities present in that operating system. OS Fingerprinting is used by
security professionals and hackers for mapping remote networks and determining which
vulnerabilities might be present to exploit. In fact, it is a tactic used by cyber-criminals and even
ethical hackers to figure out what type of operating system is being used by a target computer on a
network. In fact, by analyzing certain protocol flags, options, and data in the packets a device sends
onto the network, hackers can make relatively accurate guesses about the OS that sent those packets.
OS Fingerprinting works only for packets that contain a full-fledged TCP connection; that is the TCP
connection should have a SYN, SYN/ACK, and ACK connection.
There are two Fingerprinting:
Active
Passive
Active OS Fingerprinting
Active OS fingerprinting involves actively determining a targeted PC’s OS by sending carefully
crafted packets to the target system and examining the TCP/IP behavior of received responses. The
main reason why an attacker may prefer a passive approach is to reduce the risk of being caught by an
IDS, IPS, or a firewall. Properly configured, implemented, and maintained IDSes, IPSes,
and firewalls can mitigate active fingerprinting. In other words, active fingerprinting is challenging
the target machine to see what happens.
Active fingerprinting works by sending packets to a target and analyzing the packets that are sent
back. Almost all active fingerprinting these days is done with Nmap.
Nmap is usually used by network administrators to monitor the security of their networks. In fact,
Nmap is an effective application for both admins and attackers. Nmap sends probes to lots of different
TCP/IP ports, and analyzes what returned. Nmap utilizes scripting that analyzes that data to print out
results that are useful for OS fingerprinting. Running an OS fingerprinting scan in Nmap is as simple
as typing:
“nmap -A ip_address_or_domain_name_of_target”.
Source: infosecinstitute.com
Passive OS Fingerprinting
Passive OS fingerprinting is a more effective way of avoiding detection or being stopped by a firewall
and it examines of passively collected sample of packets from a host. Passive fingerprinting uses a
pcap (packet capture) API. In GNU/Linux and BSD/Unix operating systems, pcap can be found in the
libpcap library, and for Windows, there’s a port of libpcap called WinPcap. Passive fingerprinting can
make a guess of a target’s OS, because different OSes have different TCP/IP implementations.
Passive OS fingerprinting is less accurate than active OS fingerprinting, but may be a technique
chosen by an attacker or penetration tester who wants to avoid detection. Passive fingerprinting can be
mitigated by assuring that NICs (network interface cards) don’t operate in promiscuous mode.
There are following four important elements that we will look at to determine the operating system
TTL: What the operating system sets the Time-To-Live on the outbound packet.
Window Size: What the operating system sets the Window Size at.
DF: Does the operating system set the Don’t Fragment bit?
TOS: Does the operating system set the type of Service?
Source: zerosuniverse.com and infosecinstitute.com
Types of HIDS
Host-Based Intrusion Detection Systems can be broken into two main categories based on how they
are deployed:
Agent-based HIDS: An agent-based HIDS relies on software agents that are installed on each
host to collect information from the host. This is a “heavier-weight” approach because
running agents on hosts increases the resource utilization of the hosts.
Agentless HIDS: With an agentless HIDS, information from hosts is collected without
relying on agents, such as by streaming the data over the network. This type of HIDS is more
complex to implement, and agentless HIDS sometimes can’t access as much data as agent-
based solutions, but the agentless approach offers the benefit of consuming fewer resources.
HIDS components
No matter which type of HIDS you deploy, your HIDS solution will typically include three main
components:
Data collectors: Using either agents or an agentless approach, your HIDS deploys sensors
that collect data from hosts.
Data storage: After being collected, the data is usually aggregated and stored in a central
location. The data is retained at least as long as is necessary to analyze it, although
organizations may also choose to keep the data on hand so they can reference it at a later time
if desired.
Analytics engine: The HIDS uses an analytics engine to process and evaluate the various data
sources that it collects. The purpose of analytics is to look for patterns or anomalies, then
assess the likelihood that they are the result of security risks or attacks.
HIDS capabilities
After a HIDS detects potential security problems, it can do three main things.
Alerting
The first is alerting. Alerting is the process of informing IT and/or security teams about a potential
security issue.
Ideally, HIDS alerting features should be capable of assessing the severity of each security risk the
HIDS identifies, then generating alerts accordingly. For example, low-risk security events should be
labeled as such so that engineers are aware that those alerts are not likely to require immediate
attention.
Reporting
HIDS platforms can generate reports about the overall state of security within an IT environment. The
data included in reports can vary, but it may include the number and types of security risks identified
by a HIDS over time, for instance, or how security issues vary across different types of hosts (such as
Windows-based hosts versus Linux-based systems).
Reporting is useful for assessing security trends over time, as well as for demonstrating the security
posture of an organization.
Response
In some cases, HIDS tools are capable of carrying out certain automated response activities to help
remediate risks. For example, if a HIDS determines that a particular external endpoint is trying to
probe a company’s servers, it could automatically generate firewall rules to block the probes.
Automated remediation like this not only saves time and effort on the part of engineers, but also
ensures that security risks can be blocked immediately.
HIDS security considerations and best practices
To get the most value out of a HIDS, consider best practices like the following:
Monitor all hosts: A HIDS is of limited value if it only monitors some hosts. To gain the
broadest possible context on security risks, your HIDS should monitor all hosts. That way,
you’ll know whether and how quickly security issues spread among hosts, as well as how
many of your hosts are targeted by attacks. You’ll also be able to detect attacks that target just
one host rather than attempts to reach many hosts at once.
Contextualize data: As noted above, the more data sources your HIDS analyzes collectively,
the greater the context it has on potential security risks. Context is critical for distinguishing
actual risks from false positives and generating accurate alerts.
Configure smart alerts: To avoid distracting engineers with “alert fatigue,” a HIDS should
be configured to alert only on events that require a response. Alerts should also be categorized
based on severity level so that engineers know which ones to prioritize.
Consider agentless HIDS: While an agent-based HIDS has its advantages (such as easier
access to host-based data), agentless HIDS solutions are easier to deploy and manage in many
respects because they don’t require installing software agents on each host. They are also
lighter on resource consumption.
These practices help ensure that your HIDS delivers the most actionable security insights at the lowest
total cost.
Limitations and challenges of HIDS
While a HIDS provides one layer of defense against security threats, it’s just that – one layer.
Since HIDS platforms specialize only in host-based security, they’re of limited use for addressing
other types of threats, such as vulnerabilities within application source code or public cloud
workloads.
That’s why it’s important to deploy additional security tools and services alongside a HIDS in order to
gain comprehensive protection against potential security risks across all facets of your environment.
What is NIDS?
NIDS is a security tool designed to detect, monitor, and analyze traffic for suspicious activity or
malicious attacks. It is essential to a larger security infrastructure and prevents network breaches and
data theft.
As mentioned, NIDS (Network Intrusion Detection System) is a security technology that monitors and
analyzes network traffic for signs of malicious activity, unauthorized access, or security policy
violations. The primary function of a NIDS is to detect and alert network administrators of any
potential or ongoing attacks on the network.
NIDS works by examining data packets for specific patterns and behaviors that indicate the presence
of an attack. It can detect and alert network administrators of attacks such as DoS (Denial of Service),
port scanning, virus and malware infections, and unauthorized access attempts.
NIDS is an essential component of a comprehensive network security strategy. It helps to identify and
respond to threats quickly before they can cause significant damage or compromise sensitive data.
How Does NIDS Work?
Network-based Intrusion Detection System analyzes the network traffic and looks for behavior
patterns indicative of an intrusion or attack. It typically operates in a passive or inline mode, and they
use different detection methods to identify network intrusions.
In passive mode, the NIDS monitors outgoing network traffic without interfering with it. In inline
mode, the NIDS can modify network traffic to detect intrusions or block malicious activities.
However, the active mode may increase the risk of disrupting legitimate network traffic, and it is
usually not recommended.
When a NIDS detects a potential network threat, it generates an alert. The alert includes information
such as the type of attack, the source and destination IP addresses, and the time of the attack. The
NIDS may also take action to prevent the attack, such as blocking the source IP address or modifying
current network traffic.
Methods of NIDS Detection
Network Intrusion Detection Systems are designed to detect network-based attacks and intrusions.
They use different detection methods to identify suspicious traffic and abnormal behavior. There are
three primary detection methods used by NIDS: signature-based detection, anomaly-based detection,
and hybrid detection.
1. Signature-Based Detection
This method compares traffic passing through the network against known attack signatures or
patterns. Attack signatures are predefined network traffic patterns associated with specific types of
attacks.
The NIDS alerts the network administrator if the traffic matches a known signature. Signature-based
detection is effective at identifying known attacks, but it cannot detect new or unknown attacks.
2. Anomaly-Based Detection
This method involves detecting traffic that deviates from the normal network behavior. NIDS
monitors network traffic and generates an alert if it detects any activity outside the expected range.
Anomaly-based detection is useful in detecting new or unknown attacks but can generate many false
positives.
3. Hybrid Detection
This method combines signature-based and anomaly-based detection methods. The NIDS first uses
signature-based detection to identify known attacks and then anomaly-based detection to identify
unknown attacks. By combining both methods, hybrid detection can provide high accuracy and
minimize the false positive rate.
Others
In addition to these three primary methods, NIDS can use other techniques, such as protocol and
heuristic analysis. Protocol analysis involves examining network traffic to detect protocol violations
and abnormal behavior. The heuristic analysis involves identifying patterns of behavior that are
associated with attacks.
Technologies That a Network-Based Intrusion Detection System Can Monitor
NIDS systems can monitor network technologies and protocols to detect potential security breaches.
Here are some of the technologies that these systems can monitor:
1. Network Protocols
NIDS systems can monitor network protocols such as TCP/IP, HTTP, FTP, DNS, SMTP, and SNMP to
detect anomalous behavior that might indicate a network attack. For example, the system can detect
any attempts to exploit vulnerabilities in the protocol to gain unauthorized access.
2. Network Devices
NIDS systems can monitor network devices such as routers, switches, and firewalls to detect
unauthorized access or configuration changes. The system can also detect any attempts to exploit
vulnerabilities in the devices to gain access to the network.
3. Applications
NIDS systems can monitor network applications such as email servers, web servers, and databases to
detect any unusual activity that might indicate a security breach. For example, the system can detect
attempts to access sensitive information or execute malicious code.
4. Operating Systems
NIDS systems can monitor the operating systems of network devices and servers to detect any
security vulnerabilities or malicious activity. The system can detect any attempts to exploit
vulnerabilities in the operating system to gain unauthorized access.
5. Wireless Networks
NIDS can monitor wireless networks to detect any unauthorized access or malicious activities. The
system can monitor the wireless traffic and identify rogue access points, unauthorized connections, or
denial of service attacks.
Advantages of Network Intrusion Detection System
Network Intrusion Detection Systems (NIDS) are essential to network security infrastructure. Here are
some of the vital advantages of using NIDS:
1. Prevention of Network Attacks
NIDS actively monitors the network traffic for any suspicious activities and potential threats. It can
detect and block any unauthorized attempts to access the network, such as port scanning, password
guessing, and other attacks. By preventing these attacks, NIDS can help maintain network security
and prevent data breaches.
2. Identification of Vulnerabilities
NIDS can scan for vulnerabilities in the network, such as misconfigured devices, outdated software,
and unsecured network connections. Once these vulnerabilities are detected, they can be addressed
before attackers can exploit them, preventing potential security breaches.
3. Protection of Sensitive Information
NIDS can help protect sensitive information, such as customer data, financial records, and intellectual
property, by monitoring the network for any unauthorized access attempts. If an attempt is detected,
NIDS can alert security personnel, who can take appropriate action to prevent data loss or theft.
4. Real-Time Monitoring
NIDS provides real-time network monitoring, allowing security personnel to respond to any threats or
attacks quickly. This quick response can help prevent any potential damage caused by the attack and
minimize downtime.
5. Compliance with Regulations
NIDS can help organizations comply with various regulations such as HIPAA, PCI-DSS, and GDPR,
which require organizations to have proper security measures to protect sensitive data.
Limitations of Network Intrusion Detection Systems
1. Need for Frequent Updating
This is because new attack methods are constantly being developed, and NIDS must be able to detect
these new threats. NIDS typically uses signature-based detection methods, which must be updated
with new signatures to detect new attacks. If the system is not updated regularly, it may miss new
threats.
2. Time-Consuming Process
NIDS requires extensive configuration to ensure it is tailored to the organization’s needs. The
configuration of NIDS includes defining the types of traffic that should be monitored, setting the
detection thresholds, and configuring the alerting and reporting mechanisms.
This can be time-consuming and requires a skilled technician to ensure the system is optimized for the
organization’s needs.
3. Regular Maintenance
NIDS requires maintenance to ensure that it is functioning properly. This includes monitoring the
system to ensure it generates alerts correctly, responds promptly, and addresses any issues. Regular
maintenance is essential to ensure that the system functions at peak performance and provides the
level of protection the organization requires.
Who is NIDS For?
Network Intrusion Detection Systems are for any individual, organization, or business that needs to
ensure the security of their network. This includes government agencies, large and small businesses,
educational institutions, and individuals with sensitive information on their networks.
NIDS is essential for organizations that handle sensitive data, such as personal, financial, or
confidential business information. It can detect and alert system administrators to potential threats,
allowing them to take action to prevent or minimize damage to the network.
Moreover, NIDS can be used by security professionals, network administrators, and IT teams to
monitor network traffic and identify potential security issues before they can cause harm. It can also
help with compliance requirements for certain industries, such as healthcare or financial services,
which are required to protect sensitive data.
Honeypot
Honeypot is a network-attached system used as a trap for cyber-attackers to detect and study the
tricks and types of attacks used by hackers. It acts as a potential target on the internet and informs the
defenders about any unauthorized attempt to the information system.
Honeypots are mostly used by large companies and organizations involved in cybersecurity. It helps
cybersecurity researchers to learn about the different type of attacks used by attackers. It is suspected
that even the cybercriminals use these honeypots to decoy researchers and spread wrong information.
The cost of a honeypot is generally high because it requires specialized skills and resources to
implement a system such that it appears to provide an organization’s resources still preventing attacks
at the backend and access to any production system.
A honeynet is a combination of two or more honeypots on a network.
Types of Honeypot:
Honeypots are classified based on their deployment and the involvement of the intruder.
Based on their deployment, honeypots are divided into :
1. Research honeypots- These are used by researchers to analyze hacker attacks and deploy
different ways to prevent these attacks.
2. Production honeypots- Production honeypots are deployed in production networks along
with the server. These honeypots act as a frontend trap for the attackers, consisting of false
information and giving time to the administrators to improve any vulnerability in the actual
system.
Based on interaction, honeypots are classified into:
1. Low interaction honeypots:Low interaction honeypots gives very little insight and control to
the hacker about the network. It simulates only the services that are frequently requested by
the attackers. The main operating system is not involved in the low interaction systems and
therefore it is less risky. They require very fewer resources and are easy to deploy. The only
disadvantage of these honeypots lies in the fact that experienced hackers can easily identify
these honeypots and can avoid it.
2. Medium Interaction Honeypots: Medium interaction honeypots allows more activities to
the hacker as compared to the low interaction honeypots. They can expect certain activities
and are designed to give certain responses beyond what a low-interaction honeypot would
give.
3. High Interaction honeypots:A high interaction honeypot offers a large no. of services and
activities to the hacker, therefore, wasting the time of the hackers and trying to get complete
information about the hackers. These honeypots involve the real-time operating system and
therefore are comparatively risky if a hacker identifies the honeypot. High interaction
honeypots are also very costly and are complex to implement. But it provides us with
extensively large information about hackers.
Advantages of honeypot:
1. Acts as a rich source of information and helps collect real-time data.
2. Identifies malicious activity even if encryption is used.
3. Wastes hackers’ time and resources.
4. Improves security.
Disadvantages of honeypot:
1. Being distinguishable from production systems, it can be easily identified by experienced
attackers.
2. Having a narrow field of view, it can only identify direct attacks.
3. A honeypot once attacked can be used to attack other systems.
4. Fingerprinting(an attacker can identify the true identity of a honeypot ).
Types of Honeypots
Honeypots can also be broken down by the type of activity they detect.
Email trap or spam trap
An email or spam trap will implant a fictitious email address in a hidden field that can only be
detected by an automated address harvester or site crawler. Since the address is not visible to
legitimate users, the organization can categorize all correspondence delivered to that inbox as spam.
The organization can then block that sender and its IP address, as well as any messages that match its
content.
Decoy Database
A decoy database is an intentionally vulnerable fictitious data set that helps organizations monitor
software vulnerabilities, architecture insecurities or even nefarious internal actors. The decoy database
will gather information about injection techniques, credential hijacking or privilege abuse used by an
attacker that can then be built into system defenses and security policies.
Malware Honeypot
A malware honeypot mimics a software app or an application programming interface (API) in an
attempt to draw out malware attacks in a controlled, non-threatening environment. In doing so, the
infosec team can then analyze the attack techniques and develop or enhance anti-malware solutions to
address these specific vulnerabilities, threats or actors.
Spider Honeypot
Similar to the spam honeypot, a spider honeypot is designed to trap web crawlers, sometimes called
spiders, by creating web pages and links only accessible to automated crawlers. Identifying these
spiders can help organizations understand how to block malicious bots, as well as ad-network
crawlers.
SNORT Definition
SNORT is a powerful open-source intrusion detection system (IDS) and intrusion prevention
system (IPS) that provides real-time network traffic analysis and data packet logging. SNORT
uses a rule-based language that combines anomaly, protocol, and signature inspection methods to
detect potentially malicious activity.
Using SNORT, network admins can spot denial-of-service (DoS) attacks and distributed DoS (DDoS)
attacks, Common Gateway Interface (CGI) attacks, buffer overflows, and stealth port scans. SNORT
creates a series of rules that define malicious network activity, identify malicious packets, and send
alerts to users.
SNORT is a free-to-use open-source piece of software that can be deployed by individuals and
organizations. The SNORT rule language determines which network traffic should be collected and
what should happen when it detects malicious packets. This snorting meaning can be used in the same
way as sniffers and network intrusion detection systems to discover malicious packets or as a full
network IPS solution that monitors network activity and detects and blocks potential attack vectors.
What Are the Features of SNORT?
There are various features that make SNORT useful for network admins to monitor their systems and
detect malicious activity. These include:
Real-time Traffic Monitor
SNORT can be used to monitor the traffic that goes in and out of a network. It will monitor traffic in
real time and issue alerts to users when it discovers potentially malicious packets or threats on Internet
Protocol (IP) networks.
Packet Logging
SNORT enables packet logging through its packet logger mode, which means it logs packets to the
disk. In this mode, SNORT collects every packet and logs it in a hierarchical directory based on the
host network’s IP address.
Analysis of Protocol
SNORT can perform protocol analysis, which is a network sniffing process that captures data in
protocol layers for additional analysis. This enables the network admin to further examine potentially
malicious data packets, which is crucial in, for example, Transmission Control Protocol/IP
(TCP/IP) stack protocol specification.
Content Matching
SNORT collates rules by the protocol, such as IP and TCP, then by ports, and then by those with
content and those without. Rules that do have content use a multi-pattern matcher that increases
performance, especially when it comes to protocols like the Hypertext Transfer Protocol (HTTP).
Rules that do not have content are always evaluated, which negatively affects performance.
OS Fingerprinting
Operating system (OS) fingerprinting uses the concept that all platforms have a unique TCP/IP stack.
Through this process, SNORT can be used to determine the OS platform being used by a system that
accesses a network.
Can Be Installed in Any Network Environment
SNORT can be deployed on all operating systems, including Linux and Windows, and as part of all
network environments.
Open Source
As a piece of open-source software, SNORT is free and available for anyone who wants to use
an IDS or IPS to monitor and protect their network.
Rules Are Easy to Implement
SNORT rules are easy to implement and get network monitoring and protection up and running. Its
rule language is also very flexible, and creating new rules is pretty simple, enabling network admins
to differentiate regular internet activity from anomalous or malicious activity.
What Are the Different SNORT Modes?
There are three different modes that SNORT can be run in, which will be dependent on the flags used
in the SNORT command.
Packet Sniffer
SNORT’s packet sniffer mode means the software will read IP packets then display them to the user
on its console.
Packet Logger
In packet logger mode, SNORT will log all IP packets that visit the network. The network admin can
then see who has visited their network and gain insight into the OS and protocols they were using.
NIPDS (Network Intrusion and Prevention Detection System)
In NIPDS mode, SNORT will only log packets that are considered malicious. It does this using the
preset characteristics of malicious packets, which are defined in its rules. The action that SNORT
takes is also defined in the rules the network admin sets out.
What Are the Uses of SNORT Rules?
The rules defined in SNORT enable the software to carry out a range of actions, which include:
Perform Packet Sniffing
SNORT can be used to carry out packet sniffing, which collects all data that transmits in and out of a
network. Collecting the individual packets that go to and from devices on the network enables
detailed inspection of how traffic is being transmitted.
Debug Network Traffic
Once it has logged traffic, SNORT can be used to debug malicious packets and any configuration
issues.
Generate Alerts
SNORT generates alerts to users as defined in the rule actions created in its configuration file. To
receive alerts, SNORT rules need to contain conditions that define when a packet should be
considered unusual or malicious, the risks of vulnerabilities being exploited, and may violate the
organization’s security policy or pose a threat to the network.
Create New Rules
SNORT enables users to easily create new rules within the software. This allows network admins to
change how they want SNORT conversion to work for them and the processes it should carry out. For
example, they can create new rules that tell SNORT to prevent backdoor attacks, search for specific
content in packets, show network data, specify which network to monitor, and print alerts in the
console.
Differentiate Between Normal Internet Activities and Malicious Activities
Using SNORT rules enables network admins to easily differentiate between regular, expected internet
activity and anything that is out of the norm. SNORT analyzes network activity in real time to sniff
out malicious activity, then generates alerts to users.
A firewall is a network security device, either hardware or software-based, which monitors all
incoming and outgoing traffic and based on a defined set of security rules it accepts, rejects or drops
that specific traffic. Accept : allow the traffic Reject : block the traffic but reply with an “unreachable
error” Drop : block the traffic with no reply A firewall establishes a barrier between secured internal
networks and outside untrusted network, such as the Internet.
Before Firewalls, network security was performed by Access Control Lists (ACLs) residing on
routers. ACLs are rules that determine whether network access should be granted or denied to specific
IP address. But ACLs cannot determine the nature of the packet it is blocking. Also, ACL alone does
not have the capacity to keep threats out of the network. Hence, the Firewall was introduced.
Connectivity to the Internet is no longer optional for organizations. However, accessing the Internet
provides benefits to the organization; it also enables the outside world to interact with the internal
network of the organization. This creates a threat to the organization. In order to secure the internal
network from unauthorized traffic, we need a Firewall.
How does Firewall work?
Firewall match the network traffic against the rule set defined in its table. Once the rule is matched,
associate action is applied to the network traffic. For example, Rules are defined as any employee
from HR department cannot access the data from code server and at the same time another rule is
defined like system administrator can access the data from both HR and technical department. Rules
can be defined on the firewall based on the necessity and security policies of the organization. From
the perspective of a server, network traffic can be either outgoing or incoming. Firewall maintains a
distinct set of rules for both the cases. Mostly the outgoing traffic, originated from the server itself,
allowed to pass. Still, setting a rule on outgoing traffic is always better in order to achieve more
security and prevent unwanted communication. Incoming traffic is treated differently. Most traffic
which reaches on the firewall is one of these three major Transport Layer protocols- TCP, UDP or
ICMP. All these types have a source address and destination address. Also, TCP and UDP have port
numbers. ICMP uses type code instead of port number which identifies purpose of that
packet. Default policy: It is very difficult to explicitly cover every possible rule on the firewall. For
this reason, the firewall must always have a default policy. Default policy only consists of action
(accept, reject or drop). Suppose no rule is defined about SSH connection to the server on the firewall.
So, it will follow the default policy. If default policy on the firewall is set to accept, then any
computer outside of your office can establish an SSH connection to the server. Therefore, setting
default policy as drop (or reject) is always a good practice.
Generation of Firewall
Firewalls can be categorized based on their generation.
1. First Generation- Packet Filtering Firewall: Packet filtering firewall is used to control
network access by monitoring outgoing and incoming packets and allowing them to pass or
stop based on source and destination IP address, protocols, and ports. It analyses traffic at the
transport protocol layer (but mainly uses first 3 layers). Packet firewalls treat each packet in
isolation. They have no ability to tell whether a packet is part of an existing stream of traffic.
Only It can allow or deny the packets based on unique packet headers. Packet filtering
firewall maintains a filtering table that decides whether the packet will be forwarded or
discarded. From the given filtering table, the packets will be filtered according to the
following rules:
Need of firewall
A firewall is a firmware or software that is an essential part of a computer network’s security system.
In simple terms, it acts as an intermediary or wall of separation between the insecure internet and
secure internal network which may be a computer, company network, or home network. Separating
the internet from your internal network traffic is the default function of most firewalls. However, you
can change the default settings to allow selected trustworthy networks through the firewall thus
creating controlled openings that don’t compromise the network’s safety but at the same time allow
the passage of certain network traffic.
Importance of Using a Firewall :
The following points listed below are the most relevant in explaining the importance of firewalls is as
follows.
Feature-1 :
Monitoring Network Traffic –
Firewall security starts with effective monitoring of network traffic based on pre-established rules and
filters to keep the systems protected. Monitoring of network traffic involves the following security
measures.
1. Source or destination-based blocking of incoming network traffic –
This is the most common feature of most firewalls, whereby the firewalls block the incoming
traffic by looking into the source of the traffic.
Characteristics of Firewall
1. Physical Barrier: A firewall does not allow any external traffic to enter a system or a
network without its allowance. A firewall creates a choke point for all the external data trying
to enter the system or network and hence can easily block access if needed.
2. Multi-Purpose: A firewall has many functions other than security purposes. It configures
domain names and Internet Protocol (IP) addresses. It also acts as a network address
translator. It can act as a meter for internet usage.
3. Flexible Security Policies: Different local systems or networks need different security
policies. A firewall can be modified according to the requirement of the user by changing its
security policies.
4. Security Platform: It provides a platform from which any alert to the issue related to security
or fixing issues can be accessed. All the queries related to security can be kept under check
from one place in a system or network.
5. Access Handler: Determines which traffic needs to flow first according to priority or can
change for a particular network or system. specific action requests may be initiated and
allowed to flow through the firewall.
Types of Firewalls
1.Packet-filtering firewall
A Packet-filtering firewall filters all incoming and outgoing network packets. It tests them based on a
set of rules that include IP address, IP protocol, port number, and other aspects of the packet. If the
packet passes the test, the firewall allows it to proceed to its destination and rejects those that do not
pass it.
Benefits of a Packet-filtering
Quick and inexpensive
Oldest and most fundamental firewall
Protection against advanced threats is limited
2. Stateful Multi-Layer Inspection (SMLI)
Stateful Multi-Layer Inspection firewall employs packet inspection technology and TCP handshake
verification to provide protection. These firewalls, also known as dynamic packet filtering, examine
each network packet to determine whether it belongs to an existing TCP or another network session.
The SMLI firewall creates a state table to store session information like source and destination IP
address, port number, destination port number, etc.
Benefits of Stateful inspection
Reduced traffic flow
High-level protection
Consumed significant system resources
Provides extensive logging capabilities
3. Stateless firewall
Stateless firewalls monitor the network traffic and analyze each data packet’s source, destination, and
other details to determine whether a threat is present. These firewalls can recognize packet state and
TCP connection stages, integrate encryption, and other essential updates.
Benefits of Stateless firewall
Less complex
Easy to implement
Fast performance delivery
Performs effectively in heavy traffic situations
4. Application-level gateway (Proxy firewall)
Application-level gateway, also called Proxy firewall, is used to protect data at the application level. It
protects from potential internet hackers by not disclosing our computer’s identity (IP address). Proxy
firewalls analyze the context and content of data packets and compare them to a set of previously
defined rules using stateful and deep packet inspection. They either permit or reject a package based
on the outcome. Because this firewall checks the payload of received data packets, it is much slower
than a packet-filtering firewall.
Benefits of Application-level gateways
Safest firewall
Deep packet inspection
Significant slowdowns
Safeguard resource identity and location
5. Circuit-level gateway
Circuit-level gateway validates established Transmission Control Protocol (TCP) connections. These
firewalls typically operate at the OSI model’s session level, verifying Transmission Control Protocol
(TCP) and User Datagram Protocol (UDP) connections and sessions. These firewalls are implemented
as security software or as pre-installed firewalls. Like packet filtering firewalls, these firewalls do not
examine the actual data packet but observe the information about the transaction.
Benefits of Circuit-level gateway
Simple and inexpensive
A single form of protection is insufficient
Setup and management are simple
6. Next-Generation Firewall (NGFW)
The most common type of firewall available today is the Next-Generation Firewall (NGFW), which
provides higher security levels than packet-filtering and stateful inspection firewalls. An NGFW is a
deep-packet inspection firewall with additional features such as application awareness and control,
integrated intrusion prevention, advanced visibility of their network, and cloud-delivered threat
intelligence. This type of firewall is typically defined as a security device that combines the features
and functionalities of multiple firewalls. NGFW monitors the entire data transaction, including packet
headers, contents, and sources.
Benefits of Next-Generation Firewall
Block malware
Recognizing Advanced Persistent Threats (APTs)
Less expensive
Financially beneficial
7. Cloud firewall
A Cloud firewall, also known as FaaS (firewall-as-service), is a firewall that is designed using a cloud
solution for network protection. Third-party vendors typically manage and operate cloud firewalls on
the internet, and they are configured based on the requirements. Today, most businesses use cloud
firewalls to protect their private networks or overall cloud infrastructure.
Benefits of Cloud firewall
Unified security policy
Flexible deployment
Simplified deployment and maintenance
Improved scalability
Automatic updates
1. Packet Filters –
It is a technique used to control network access by monitoring outgoing and incoming packets
and allowing them to pass or halt based on the source and destination Internet Protocol (IP)
addresses, protocols, and ports. This firewall is also known as a static firewall.
4. Next-generation Firewalls –
These firewalls are called intelligent firewalls. These firewalls can perform all the tasks that
are performed by the other types of firewalls that we learned previously but on top of that, it
includes additional features like application awareness and control, integrated intrusion
prevention, and cloud-delivered threat intelligence.
5. Circuit-level gateways –
A circuit-level gateway is a firewall that provides User Datagram Protocol (UDP) and
Transmission Control Protocol (TCP) connection security and works between an Open
Systems Interconnection (OSI) network model’s transport and application layers such as the
session layer.
6. Software Firewall –
The software firewall is a type of computer software that runs on our computers. It protects
our system from any external attacks such as unauthorized access, malicious attacks, etc. by
notifying us about the danger that can occur if we open a particular mail or if we try to open a
website that is not secure.
7. Hardware Firewall –
A hardware firewall is a physical appliance that is deployed to enforce a network boundary.
All network links crossing this boundary pass-through this firewall, which enables it to
perform an inspection of both inbound and outbound network traffic and enforce access
controls and other security policies.
8. Cloud Firewall –
These are software-based, cloud-deployed network devices. This cloud-based firewall
protects a private network from any unwanted access. Unlike traditional firewalls, a cloud
firewall filters data at the cloud level.
FIREWALL BASING
It is common to base a firewall on a stand-alone machine running a common oper- ating system,
such as UNIX or Linux. Firewall functionality can also be imple- mented as a software module in a ro
uter or LAN switch. In this section, we look at some additional firewall basing considerations.
Bastion Host
A bastion host is a system identified by the firewall administrator as a critical strong
point in the network’s security. Typically, the bastion host serves as a platform for an application-
level or circuit-level gateway. Common characteristics of a bastion host are as follows:
• The bastion host hardware platform executes a secure version of its operating
system, making it a hardened system.
• Only the services that the network administrator considers
essential are installed on the bastion host. These could include proxy applications for DNS, FTP, HTT
P, and SMTP.
• The bastion host may require additional authentication before a user is allowed
access to the proxy services. In addition, each proxy
service may require its own authentication before granting user access.
• Each proxy is configured to support only a subset of the standard application’s
command set.
• Each proxy is configured to allow access only to specific host systems. This
means that the limited command/feature set may be applied only to a subset of systems on the
protected network.
• Each proxy maintains detailed audit information by logging all traffic, each
connection, and the duration of each connection. The audit log is an essential
tool for discovering and terminating intruder attacks.
• Each proxy module is a very small software package specifically designed for network
security. Because of its relative simplicity, it is easier to check such
modules for security flaws. For example, a typical UNIX mail application may contain over 20,000
lines of code, while a mail proxy may contain fewer than 1000.
• Each proxy is independent of other proxies on the bastion host. If there is a
problem with the operation of any proxy, or if a future vulnerability is discov- ered, it can be
uninstalled without affecting the operation of the other proxy applications. Also, if the user population
requires support for a new service, the network administrator can easily install the required
proxy on the bastion host.
• A proxy generally performs no disk access other than to read its initial config-
uration file. Hence, the portions of the file system containing executable code
can be made read only. This makes it difficult for an intruder to install Trojan horse sniffers or other d
angerous files on the bastion host.
• Each proxy runs as a nonprivileged user in a private and secured directory on the
bastion host.
Host-Based Firewalls
A host-based firewall is a software module used to secure an individual host. Such modules are
available in many operating systems or can be provided as an add-on package. Like conventional
stand-alone firewalls, host-resident firewalls filter and restrict the flow of packets. A common location
for such firewalls is a server. There are several advantages to the use of a server-based or
workstation- based firewall:
• Filtering rules can be tailored to the host environment. Specific corporate security
policies for servers can be implemented, with different
filters for servers used for different application.
• Protection is provided independent of topology. Thus both internal and exter-
nal attacks must pass through the firewall.
• Used in conjunction with stand-alone firewalls, the host-based firewall pro- vides an
additional layer of protection. A new type of server can be added to the network, with its own firewall,
without the necessity of altering the net- work firewall configuration.
Personal Firewall
A personal firewall controls the traffic between a personal computer or workstation on one side and
the Internet or enterprise network on the other side. Personal fire-
wall functionality can be used in the home environment and on corporate intranets. Typically, the pers
onal firewall is a software module on the personal computer. In a home environment with multiple
computers connected to
the Internet, firewall functionality can also be housed in a router that connects all of the home comput
ers to a DSL, cable modem, or other Internet interface.
Personal firewalls are typically much less complex than either server-based firewalls or stand-
alone firewalls. The primary role of the personal firewall is to deny
unauthorized remote access to the computer. The firewall can also monitor outgoing
activity in an attempt to detect and block worms and other malware.
An example of a personal firewall is the capability built in to the Mac OS X operating
system. When the user enables the personal firewall in Mac OS X, all inbound connections are denied
except for those the user explicitly permits. Figure 22.2 shows this simple interface.
The list of inbound services
that can be selectively reenabled, with their port numbers, includes the following:
• Personal file sharing (548, 427)
• Windows sharing (139)
• Personal Web sharing (80, 427)
• Remote login - SSH (22)
• FTP access (20-21, 1024-64535 from 20-21)
• Remote Apple events (3031)
• Printer sharing (631, 515)
• IChat Rendezvous (5297, 5298)
• ITunes Music Sharing (3869)
• CVS (2401)
• Gnutella/Limewire (6346)
• ICQ (4000)
• IRC (194)
• MSN Messenger (6891-6900)
• Network Time (123)
• Retrospect (497)
• SMB (without netbios-445)
• Timbuktu (407)
• VNC (5900-5902)
• WebSTAR Admin (1080, 1443)
When FTP access is enabled, ports 20 and 21 on the local machine are opened for FTP; if others
connect to this computer from ports 20 or 21, the ports 1024 through 64535 are open.
For increased protection, advanced firewall features are available through easy-to-
configure checkboxes. Stealth mode hides the Mac on the Internet by drop- ping unsolicited
communication packets, making it appear as though no Mac is present. UDP packets can be blocked,
restricting network traffic to TCP packets only for open ports. The fire
wall also supports logging, an important tool for checking on unwanted activity.
DMZ Networks
Figure 22.3 suggests the most common distinction, that between an internal and an external firewall.
An external firewall is placed at the edge of a local or enterprise
network, just inside the boundary router that connects to the Internet or some wide area
network (WAN). One or more internal firewalls protect the bulk of the enter- prise network. Between
these two types of firewalls are one or more networked devices in a region referred to as a DMZ
(demilitarized zone) network. Systems that are externally accessible but need some
protections are usually located on DMZ networks. Typically, the systems in the DMZ require or foster
external con- nectivity, such as a corporate Web site, an e-mail server, or a DNS (domain name
system) server.
The external firewall provides a measure of access control and protection for
the DMZ systems consistent with their need for external connectivity. The external
firewall also provides a basic level of protection for the remainder of the enterprise
network. In this type of configuration, internal firewalls serve three purposes:
1. The internal firewall adds more stringent filtering capability, compared to the
external firewall, in order to protect enterprise servers and workstations from external attack.
2. The internal firewall provides two-
way protection with respect to the DMZ. First, the internal firewall protects the remainder of the netw
ork from attacks launched
from DMZ systems. Such attacks might originate from worms, rootkits, bots, or other malware lodged
in a DMZ system. Second, an internal firewall can protect the DMZ systems from attack from the inte
rnal protected network.
3. Multiple internal firewalls can be used to protect portions of the internal network from
each other. For example, firewalls can be configured so that internal servers are protected from
internal workstations and vice versa. A common practice is to place the DMZ on a different network
interface on the external firewall from that used to access the internal networks.
Virtual Private Networks
In today’s distributed computing environment, the virtual private network (VPN) offers an attractive
solution to network managers. In essence, a VPN consists of a set of computers that interconnect by
means of a relatively unsecure network and that
make use of encryption and special protocols to provide security. At each corporate site, workstations,
servers, and databases are linked by one or more local area net-
works (LANs). The Internet or some other public network can be used to intercon-
nect sites, providing a cost savings over the use of a private network and offloading
the wide area network management task to the public network provider. That same public network
provides an access
path for telecommuters and other mobile employees to log on to corporate systems from remote sites.
But the manager faces a fundamental requirement: security. Use of a public
network exposes corporate traffic to eavesdropping and provides an entry point for unauthorized
users. To counter this problem, a VPN is needed. In essence, a VPN
uses encryption and authentication in the lower protocol layers to provide a secure
connection through an otherwise insecure network, typically the Internet. VPNs are generally cheaper
than real private networks using private lines but rely on having
the same encryption and authentication system at both ends. The encryption may be
performed by firewall software or possibly by routers. The most common protocol
mechanism used for this purpose is at the IP level and is known as IPsec.
An organization maintains LANs at dispersed locations. A logical means of implementing an IPsec is
in a firewall, as shown in Figure 22.4, which essentially repeats Figure 19.1. If IPsec is implemented
in a separate box behind (internal to) the firewall, then VPN traffic passing
through the firewall in both directions is encrypted. In this case, the firewall is unable to perform its
filtering function or other security functions, such as access control, logging, or scanning for viruses.
IPsec could be implemented in the boundary router, outside the firewall. However, this device is
likely to be less secure than the firewall and thus less desirable as an IPsec platform.
Distributed Firewalls
A distributed firewall configuration involves stand-alone firewall devices plus host-
based firewalls working together under a central administrative control. Figure 22.5 suggests a
distributed firewall configuration. Administrators can configure host- resident
firewalls on hundreds of servers and workstations as well as configure personal firewalls on local and
remote user systems. Tools let the network adminis- trator set policies and monitor security across the
entire network. These firewalls
protect against internal attacks and provide protection tailored to specific machines
and applications. Stand-alone firewalls provide global protection, including internal
firewalls and an external firewall, as discussed previously.
With distributed firewalls, it may make sense to establish both an internal and an external
DMZ. Web servers that need less protection because they
have less critical information on them could be placed in an external DMZ, outside the exter-
nal firewall. What protection is needed is provided by host-based firewalls on these servers.
An important aspect of a distributed firewall configuration is security moni- toring. Such monitoring
typically includes log aggregation and analysis, firewall statistics, and fine-grained remote monitoring
of individual hosts if needed.
• Single bastion T: Similar to single bastion inline but has a third network interface on bastion to a
DMZ where externally visible servers are placed. Again, this is a common appliance
configuration for medium to large organizations.
• Double bastion inline: Figure 22.3 illustrates this configuration, where the DMZ is sandwiched bet
ween bastion firewalls. This configuration is common
for large businesses and government organizations.
• Double bastion T: The DMZ is on a separate network interface on the bastion
firewall. This configuration is also common for large businesses and govern- ment organizations and
may be required. For example, this configuration is
required for Australian government use (Australian Government Information Technology Security Ma
nual - ACSI33).
• Distributed firewall configuration: Illustrated in Figure 22.5. This configura- tion is used by some
large businesses and government organizations.
IPS Types of
Scope per
Technology Malicious Activity Strengths
Sensor
Type Detected
Multiple
Network, transport, network Only IDPS which can analyze the
Network- subnets
and application widest range of application
Based
TCP/IP layer activity and groups protocols;
of hosts