Network Security - Ver2

Download as pdf or txt
Download as pdf or txt
You are on page 1of 41

MKET1313

Communication and Computer


Networks
Network Security

Kamaludin Mohamad Yusof
[email protected]
Security Requirements and Attacks
Computer security and network security and cryptography
Three requirements:
AuthenAcaAon
CondenAality
Key management
Security threats
InterrupAon
IntercepAon
ModicaAon
FabricaAon
Security Threats
A Good Information System and Networks


InformaAon systems and networks oer aIracAve targets and should
be resistant to aIack from the full range of threat agents, from hackers
to naAon-states. A system must be able to limit damage and recover
rapidly when aIacks occur.
Types of Attacks
Passive AIack: A passive a(ack monitors unencrypted trac and looks for clear-
text passwords and sensiAve informaAon that can be used in other types of
aIacks. Passive a(acks include trac analysis, monitoring of unprotected
communicaAons, decrypAng weakly encrypted trac, and capturing
authenAcaAon informaAon such as passwords. Passive intercepAon of network
operaAons enables adversaries to see upcoming acAons. Passive aIacks result in
the disclosure of informaAon or data les to an aIacker without the consent or
knowledge of the user.
AcAve AIack: In an ac,ve a(ack, the aIacker tries to bypass or break into
secured systems. This can be done through stealth, viruses, worms, or Trojan
horses. AcAve aIacks include aIempts to circumvent or break protecAon
features, to introduce malicious code, and to steal or modify informaAon. These
aIacks are mounted against a network backbone, exploit informaAon in transit,
electronically penetrate an enclave, or aIack an authorized remote user during
an aIempt to connect to an enclave. AcAve aIacks result in the disclosure or
disseminaAon of data les, DoS, or modicaAon of data.
Distributed AIack: A distributed a(ack requires that the adversary
introduce code, such as a Trojan horse or back-door program, to a
trusted component or soTware that will later be distributed to many
other companies and users DistribuAon aIacks focus on the malicious
modicaAon of hardware or soTware at the factory or during distribuAon.
These aIacks introduce malicious code such as a back door to a product to
gain unauthorized access to informaAon or to a system funcAon at a later
date.
Insider AIack: An insider a(ack involves someone from the inside, such as
a disgruntled employee, aIacking the network Insider aIacks can be
malicious or no malicious. Malicious insiders intenAonally eavesdrop, steal,
or damage informaAon; use informaAon in a fraudulent manner; or deny
access to other authorized users. No malicious aIacks typically result from
carelessness, lack of knowledge, or intenAonal circumvenAon of security
for such reasons as performing a task
Close-in AIack: A close-in a(ack involves someone aIempAng to get
physically close to network components, data, and systems in order
to learn more about a network Close-in aIacks consist of regular
individuals aIaining close physical proximity to networks, systems, or
faciliAes for the purpose of modifying, gathering, or denying access to
informaAon. Close physical proximity is achieved through
surrepAAous entry into the network, open access, or both.
Security in what layer?
Depends on the purpose
What informaAon needs to be protected?
What is the aIack model?
Who shares keys in advance?
Should the user be involved?
E.g., a network-layer protocol cannot authenAcate two end-users to
each other
An applicaAon-layer protocol cannot protect IP header informaAon
Also aects eciency, ease of deployment, etc.
Generally
When security is placed as lower levels, it can provide automaAc,
blanket coverage
but it can take a long Ame before it is widely adopted

When security is placed at higher levels, individual users can choose


when to use it
but users who are not security-conscious may not take advantage of it
Application Layer Security
Example
PGP - Pretty Good Privacy
S/MIME
S-HTTP
HTTPS
SET
KERBEROS
Advantages:
- Most exible
- ExecuAng in the context of the user easy access to users credenAals
Complete access to data easier to ensure nonrepudaAon and small security granularity
ApplicaAon-based security
Disadvantages:
Most intrusive
Implemented in end hosts
Need for each applicaAon
Expensive
Greated probability of making mistake
SSL: Security at Transport Layer
Security at the Transport Layer
Secure Socket Layer (SSL)
Developed by Netscape to provide security in WWW browsers and
servers
SSL is the basis for the Internet standard protocol Transport Layer
Security (TLS) protocol (compaAble with SSLv3)
Key idea: Connec&ons and Sessions
A SSL session is an associaAon between two peers
An SSL connecAon is the set of mechanisms used to transport data in an SSL
session
Secure Socket Layer (SSL)
Each party keeps session informaAon
Session idenAer (unique)
The peers X.503(v3) cerAcate
Compression method used to reduce volume of data
Cipher specicaAon (parameters for cipher and message authenAcaAon code, MAC)
Master secret of 48 bits
ConnecAon informaAon
Random data for the server & client
Server and client keys (used for encrypAon)
Server and client message authenAcaAon code, MAC key
IniAalizaAon vector for the cipher, if needed
Server and client sequence numbers
Provides a set of supported cryptographic mechanisms that are setup during
negoAaAon (handshake protocol)
SSL Architecture

Provides a basis for


Secure communicaAon
CondenAality +
Message authenAcity
SSL Record Protocol Operation
e.g., HTTP messages

Message type, version, length of block


Three phases
Handshake
Key derivaAon
Data transfer
Handshake Protocol
The most complex part of SSL
Allows the server and client to authenAcate each other
Based on interchange cryptosystem (e.g., RSA)
NegoAate encrypAon, message authenAcaAon code (MAC) algorithm
and cryptographic keys
Four rounds
Used before any applicaAon data are transmiIed

INFSCI 2935: IntroducAon to Computer Security 19


Key Derivation
Client and server use K to establish four keys: encrypAon and
authenAcaAon, for each direcAon
Data Transfer
SSL breaks data stream into records; appends a MAC to each record;
and then encrypts the result
Mac-then-encrypt
What would have been a beIer choice?
The MAC is computed over the record plus a sequence number
Prevents replay, re-ordering, or dropping packets
Other protocols
SSL Change Cipher Spec Protocol
A single byte is exchanged
ATer new cipher parameters have been negoAated (renegoAated)
SSL Alert Protocol
Signals an unusual condiAon
Closure alert : sender will not send anymore
Error alert: fatal error results in disconnect
IPSec: Security at Network Layer
IPSec
Set of protocols/mechanisms
Encrypts and authenAcates all trac at the IP level
Protects all messages sent along a path
Intermediate host with IPSec mechanism (rewall, gateway) is called a security gateway
Use on LANs, WANs, public, and private networks
ApplicaAon independent (Transparent to user)
Web browsing, telnet, Tp
Provides at the IP level
Access control
ConnecAonless integrity
Data origin authenAcaAon
RejecAon of replayed packets
Data condenAality
Limited trac analysis condenAality
Cases where IPSec can be used

Internet/
Intranet

End-to-end security between two hosts

Internet/
SG SG
Intranet

End-to-end security between two security gateways


Cases where IPSec can be used (2)

Internet
SG SG

Intranet Intranet

End-to-end security between two hosts + two gateways

Internet
SG

Intranet

End-to-end security between two hosts during dial-up


IPSec Protocols
AuthenAcaAon header (AH) protocol
Message integrity
Origin authenAcaAon
AnA-replay services
EncapsulaAng security payload (ESP) protocol
CondenAality
Message integrity
Origin authenAcaAon
AnA-replay services
Internet Key Exchange (IKE)
Exchanging keys between enAAes that need to communicate over the Internet
What authenAcaAon methods to use, how long to use the keys, etc.
Security Association (SA)
UnidirecAonal relaAonship between peers (a sender and a receiver)
Species the security services provided to the trac carried on the SA
Security enhancements to a channel along a path
IdenAed by three parameters:
IP DesAnaAon Address
Security Protocol IdenAer
Species whether AH or ESP is being used
Security Parameters Index (SPI)
Species the security parameters associated with the SA
Security Association (2)
Each SA uses AH or ESP (not both)
If both required two are SAs are created
MulAple security associaAons may be used to provide required
security services
A sequence of security associaAons is called SA bundle
Example: We can have an AH protocol followed by ESP or vice versa
IPSec Modes
Two modes
Transport mode
Encapsulates IP packet data area
IP Header is not protected
ProtecAon is provided for the upper layers
Usually used in host-to-host communicaAons
Tunnel mode
Encapsulates enAre IP packet in an IPSec envelope
Helps against trac analysis
The original IP packet is untouched in the Internet
Authentication Header (AH)
parameters
Next header
IdenAes what protocol header follows Next Header
Payload length
Indicates the number of 32-bit words in the authenAcaAon Payload length
header
Security Parameters Index Security Parameters
Index
Species to the receiver the algorithms, type of keys, and
lifeAme of the keys used Sequence
Sequence number Number
Counter that increases with each IP packet sent from the same
host to the same desAnaAon and SA Authentication Data

AuthenAcaAon Data

31
Preventing replay
Using 32 bit sequence numbers helps detect replay of IP packets
The sender iniAalizes a sequence number for every SA
Each succeeding IP packet within a SA increments the sequence number
Receiver implements a window size of W to keep track of
authenAcated packets
Receiver checks the MAC to see if the packet is authenAc
Transport Mode AH

Internet/
Intranet

Original IP TCP Without IPSec


Payload Data
Header Header

Original IP Auth TCP


Payload Data
Header Header Header

Next Payload Seq.


SPI MAC
Header Length No.
Tunnel Mode AH

Internet
SG

Intranet

Original IP TCP Without IPSec


Payload Data
Header Header

New IP Auth Original IP TCP


Payload Data
Header Header Header Header

Next Payload Seq.


SPI MAC
Header Length No.
ESP Encapsulating Security Payload
Creates a new header in addiAon Security Parameters
to the IP header Index (SPI) 32 bits

Creates a new trailer Sequence Number


32 bits
Encrypts the payload data
Payload Data
AuthenAcates the security
associaAon
Padding/ Next Header
Prevents replay
Authentication Data

35
Details of ESP
Security Parameters Index (SPI)
Species to the receiver the algorithms, type of keys, and lifeAme of the keys used
Sequence number
Counter that increases with each IP packet sent from the same host to the same desAnaAon and SA
Payload
ApplicaAon data carried in the TCP segment
Padding
0 to 255 bytes of data to enable encrypAon algorithms to operate properly
To mislead sniers from esAmaAng the amount of data transmiIed
AuthenAcaAon Data
MAC created over the packet
Transport mode ESP

Original IP TCP Without IPSec


Payload Data
Header Header

Original IP ESP TCP ESP ESP


Payload Data
Header Header Header Trailer Auth
Encrypted

Authenticated
Tunnel mode ESP

Original IP TCP Without IPSec


Payload Data
Header Header

New IP ESP Original IP TCP ESP ESP


Payload Data
Header Header Header Header Trailer Auth

Encrypted

Authenticated
Firewall on The Networks
All previous security measures cannot prevent Eve from sending a harmful message to a
system. To control access to a system, we need firewalls. A firewall is a device installed
between the internal network of an organization and the rest of the Internet. It is designed
to forward some packets and filter (not forward) others.
Packet Filter Firewall

A packet-lter rewall lters at the network or transport layer.


Proxy Firewall

A proxy rewall lters at the applicaAon layer.

You might also like