CSIT561 Module8 Network Security
CSIT561 Module8 Network Security
Bharath K. Samanthula
Department of Computer Science
Montclair State University
Slides are adopted from Chapter 12, Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043)..
2
Objectives
• Networking basics
• Network threats and vulnerabilities
• WiFi security
• Denial-of-service attacks
• Network encryption concepts and tools
• Types of firewalls and what they do
• Intrusion detection and prevention systems
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
3
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
4
LAN
Imposter
Receiver
This picture shows different touch points where attackers can take
advantage of communication media: wiretaps, sniffers and rogue
receivers, interception, and impersonation.
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
5
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
6
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
7
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
8
Security Perimeters
Security
perimeter
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
9
Unknown Perimeter
Network C Network B
Network A
Network D
Network E
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
11
Unknown Path
Host C
Network A Network B
Host A1
Host B3
Host D
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
12
• Substitution
• Replacement of one piece of a data stream with another
• Insertion
• A form of substitution in which data values are inserted into a
stream
• Replay
• Legitimate data are intercepted and reused
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
13
Software
flaw Transmission
problem Hacker Human
activity mistake
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
14
Interception
ID
ID Password (encrypted)
PW Encryption
Server
ID
Password (encrypted)
Replay
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
15
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
16
Port Scanning
Port scanning tells an attacker which standard ports are running, what
applications and their versions are present
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
17
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
18
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
21
WEP Weaknesses
• Weak encryption key
• WEP allows to be either 64- or 128-bit, but 24 of those bits are
reserved for initialization vectors (IV), thus reducing effective key
size to 40 or 104 bits
• Keys were either alphanumeric or hex phrases that users typed in
and were therefore vulnerable to dictionary attacks
• Static key
• Since the key was just a value the user typed in at the client and
AP, and since users rarely changed those keys, one key would be
used for many months of communications
• Weak encryption process
• A 40-bit key can be brute forced easily. Flaws that were eventually
discovered in the RC4 encryption algorithm WEP uses made the
104-bit keys easy to crack as well
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
22
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
23
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
24
WPA (cont.)
• Strong encryption
• WPA adds support for AES, a much more reliably strong encryption
algorithm
• Integrity protection
• WPA includes a 64-bit cryptographic integrity check
• Session initiation
• WPA sessions begin with authentication and a four-way handshake
that results in separate keys for encryption and integrity on both
ends
• While there are some attacks against WPA, they are
either of very limited effectiveness or require weak
passwords
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
25
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
26
Attacker Victim
(a) Attacker has greater bandwidth
Attacker Victim
(b) Victim has greater bandwidth
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
27
Attacker
Attacker sends
broadcast ECHO Victim is saturated
request to network, All network hosts with ECHO replies
with victim’s return address reply to victim from entire network
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
28
Victim A Victim B
Echoing what you just sent me
10
20
30
40
60
70
80
90
100
...
Fragment start = 40 len = 30
Reassembly Buffer
Packet Fragments
7.0.1.1
207.46.197.32
Received too
late; ignored
The attacker acts as the DNS server in order to redirect the user to
malicious sites.
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
31
20.0.0.0 B
…
30.0.0.0 C
10.0.0.0 dist 3
20.0.0.0 dist 2
30.0.0.0 dist 1
This picture doesn’t show anything malicious happening. It just shows how one
router, C, advertises the routes it knows about to the routers adjacent to it.
Routers rely on these advertising messages to be accurate; when they aren’t,
DoS can ensue.
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
32
Victim
1. Attacker plants
Trojan horse in
zombies 2. Zombies attack
victim simultaneously
on command
DDoS attacks are much more effective than traditional DoS attacks, employing a multiplied
version of the same methods.
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
33
Botnets
Attacker Attacker
Victim
Botnets are networks of machines running malicious code under remote control. They often go undetected
because they do little harm to the machines they run on. Botnets are often used to execute DDoS attacks.
The image above shows how Botnet command and control (C&C) updates occur. The attacker is separated
from the bots by multiple layers, making the attacker difficult to trace. Multiple redundant systems are built in
so that if one master or C&C node is taken down, the bots can continue to connect to the botnet.
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
34
Security Countermeasures
• Cryptography in Network Security
• Network Encryption – Key points
• Encryption protects only what is encrypted and during the session
• Designing encryption algorithms is left for professionals
• Encryption is no more secure than key management
• Encryption is not a silver bullet – A flawed system with good
encryption scheme is still a flawed system design
• Modes of Encryption:
• Link Encryption
• End-to-End Encryption
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
35
Link Encryption
7 M M 7
6 M M 6
5 M M 5
4 M M 4
3 M 3 M M 3 M 3
2 M 2 M M 2 M 2
1 M 1 M M 1 M 1
M Encrypted
M Plaintext
In link encryption, data are encrypted just before the system places them on the physical
communications link and are decrypted just as they arrive at the destination system. In this
graphic, we see that the data is encrypted only at layer 1 of the previously discussed OSI stack.
If the data is communicated through an intermediate node, that intermediate node will decrypt
the data when it arrives, and then may re-encrypt it for the next link. Link encryption is
appropriate when the transmission line is the point of greatest vulnerability, such as in wireless
scenarios.
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
36
End-to-End Encryption
7 M M 7
6 M M 6
5 M M 5
4 M M 4
3 M 3 M M 3 M 3
2 M 2 M M 2 M 2
1 M 1 M M 1 M 1
M Encrypted
M Plaintext
In contrast with the previous slide, this end-to-end encryption diagram shows our data encrypted all the way
up to OSI layer 7, the application layer. The important element is that intermediate nodes cannot decrypt the
data. End-to-end encryption is appropriate whenever sending sensitive data through untrustworthy
intermediate nodes, such as over the Internet.
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
37
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
38
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
39
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
40
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
41
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
42
In this dialog, we see that the site is verified, who the certificate authority is,
and the choice of encryption algorithm.
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
43
SSL Certificate
In this dialog, we see the certificate details: the domain name being certified, the
company that owns the site, the CA that issued the certificate, and the relevant
dates.
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
44
Onion Routing
• Onion routing prevents an eavesdropper from learning
source, destination, or content of data in transit in a
network
• This is particularly helpful for evading authorities, such as
when users in oppressive countries want to communicate
freely with the outside world
• Uses asymmetric cryptography, as well as layers of
intermediate hosts, so that
• The intermediate host that sends the message to the ultimate
destination cannot determine the original sender, and
• The host that received the message from the original sender
cannot determine the ultimate destination
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
45
Office A
Firewall A
B1 B2 B3 B4
Office B
Firewall B
Encrypted
In this picture, a VPN—an encrypted tunnel that provides confidentiality and integrity for communication
between two sites over public networks—connects Office A to Office B over the Internet so they appear
to their users as one seamless, private network. The VPN is terminated by firewalls at both ends, which
is often the case in the real world.
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
46
Firewalls
• A device that filters all traffic between a protected or
“inside” network and less trustworthy or “outside” network
• Most firewalls run as dedicated devices
• Easier to design correctly and inspect for bugs
• Easier to optimize for performance
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
47
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
48
Types of Firewalls
• Packet filtering gateways or screening routers
• Stateful inspection firewalls
• Application-level gateways, also known as proxies
• Circuit-level gateways
• Guards
• Personal or host-based firewalls
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
49
Packet-Filtering Gateways
HTTP
Telnet
A packet-filtering gateway controls access on the basis of packet address and specific transport protocol
type (e.g., HTTP traffic). The example firewall configuration table on a previous slide was in relation to a
packet-filtering gateway. In the image on this slide, the firewall is filtering out Telnet traffic but allowing
HTTP traffic in. There is a second packet-filtering gateway image on the next slide.
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
50
In this image, the firewall is filtering traffic on the basis of source IP rather than port. Filtering rules can
also be based on combinations of addresses and ports/protocols.
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
51
10.1.3.1
Further
10.1.3.1:x
traffic
Packet-filtering gateways maintain no state from one packet to the next. They simply look at each packet’s IP
addresses and ports and compare them to the configured policies. Stateful inspection firewalls, on the other
hand, maintain state information from one packet to the next.
In the example in the image, the firewall is counting the number of systems coming from external IP 10.1.3.1;
after the external system reaches out to a fourth computer, the firewall hits a configured threshold and begins
filtering packets from that address. In real life, it can be difficult to define rules that require state/context and
that attackers cannot circumvent.
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
52
Application Proxy
Filtered
commands
Results
Logging
File
cache
An application proxy simulates the behavior of an application at OSI layer 7 so that the real application
receives only requests to act properly. Application proxies can serve a number of purposes:
• Filtering potentially dangerous application-layer requests
• Log requests/accesses
• Cache results to save bandwidth
Perhaps the most common form of application proxies in the real world is a web proxy, which companies
often use to monitor and filter employee Internet use.
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
53
Circuit-Level Gateway
100.1.1.x network
Circuit
gateway
To Yes
200.1.1.x?
Encryption
No
Main
firewall
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
54
Guard
• A sophisticated firewall that, like an application proxy, can
interpret data at the protocol level and respond
• The distinction between a guard and an application proxy
can be fuzzy; the more protection features an application
proxy implements, the more it becomes like a guard
• Guards may implement any programmable set of rules;
for example:
• Limit the number of email messages a user can receive
• Limit users’ web bandwidth
• Filter documents containing the word “Secret”
• Pass downloaded files through a virus scanner
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
55
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
56
DMZ
Firewall
Database
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
57
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
60
(E)
Ra ev
Events
w en
or t d
lo ata
w-
lev
el
(A) (S)
Analysis Storage
in
te Hig
rp h-
re le
te ve
d
ev l
en
ts
Reactions to
(C) events
Countermeasures
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
61
Types of IDS
• Detection method
• Signature-based
• Heuristic
• Location
• Front end
• Internal
• Scope
• Host-based IDS (HIDS)
• Network-based IDS (NIDS)
• Capability
• Passive
• Active, also known as intrusion prevention systems (IPS**)
** https://ubiquity.acm.org/article.cfm?id=1071927
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.
62
Summary
• Networks are threatened by attacks aimed at interception,
modification, fabrication, and interruption
• WPA2 has many critical security advantages over WEP
• DoS attacks come in many flavors, but malicious ones are
usually either volumetric in nature or exploit a bug
• Network encryption can be achieved using specialized tools—
some for link encryption and some for end-to-end—such as
VPNs, SSH, and the SSL/TLS protocols
• A wide variety of firewall types exist, ranging from very basic
IP-based functionality to complex application-layer logic, and
both on networks and hosts
• There are many flavors of IDS, each of which detects different
kinds of attacks in very different parts of the network
From Security in Computing, Fifth Edition, by Charles P. Pfleeger, et al. (ISBN: 9780134085043). Copyright 2015 by Pearson Education, Inc. All rights reserved.