Professional Documents
Culture Documents
شبكات مدمج
شبكات مدمج
Computer Networks
▪ Course Syllabus
▪ Course overview
➢ Course Syllabus
▪ Course overview
▪ Course Syllabus
➢ Course overview
1-9
Week 1/Ch. 1: roadmap
1.1 what is the Internet?
1.2 network edge
▪ end systems, access networks, links
1.3 network core
▪ packet switching, circuit switching, network structure
1.4 delay, loss, throughput in networks
1.5 protocol layers, service models
1.6 networks under attack: security
1.7 history
Introduction 1-10
Chapter 1: Introduction
our goal: overview:
▪ get “feel” and ▪ what’s the Internet?
terminology ▪ what’s a protocol?
▪ network edge; hosts, access net,
▪ more depth, detail physical media
later in course ▪ network core: packet/circuit
▪ approach: switching, Internet structure
• use Internet as ▪ performance: loss, delay,
throughput
example
▪ security
▪ protocol layers, service models
▪ history
Introduction 1-11
Week 1/Ch. 1: roadmap
1.1 what is the Internet?
1.2 network edge
▪ end systems, access networks, links
1.3 network core
▪ packet switching, circuit switching, network structure
1.4 delay, loss, throughput in networks
1.5 protocol layers, service models
1.6 networks under attack: security
1.7 history
Introduction 1-12
What’s the Internet: “nuts and bolts” view
PC
▪ billions of connected mobile network
server computing devices:
wireless
laptop
• hosts = end systems global ISP
Introduction 1-13
“Fun” Internet-connected devices
Web-enabled toaster +
weather forecaster
IP picture frame
http://www.ceiva.com/
Tweet-a-watt:
Slingbox: watch, monitor energy use
control cable TV remotely
sensorized,
bed
mattress
Internet
refrigerator Internet phones
Introduction 1-14
What’s the Internet: “nuts and bolts” view
mobile network
▪ Internet: “network of networks”
• Interconnected ISPs
global ISP
▪ protocols control sending, receiving
of messages
• e.g., TCP, IP, HTTP, Skype, 802.11 home
network
▪ Internet standards regional ISP
• RFC: Request for comments
• IETF: Internet Engineering Task Force
institutional
network
Introduction 1-15
What’s the Internet: a service view
mobile network
▪ infrastructure that provides
services to applications: global ISP
Introduction 1-16
CS232
Computer Networks
▪ Course Syllabus
▪ Course overview
Hi TCP connection
request
Hi TCP connection
response
Got the
time? Get http://www.awl.com/kurose-ross
2:00
<file>
time
Introduction 1-5
A closer look at network structure:
▪ network edge: mobile network
▪ network core:
• interconnected routers
• network of networks institutional
network
Introduction 1-6
Access networks and physical media
Introduction 1-7
Access network: digital subscriber line (DSL)
central office telephone
network
DSL splitter
modem DSLAM
ISP
voice, data transmitted
at different frequencies over DSL access
dedicated line to central office multiplexer
server,
PC sendswith
bits linkpipe
capacity
that can carry
file of F bits
(fluid) into pipe Rs bits/sec
fluid at rate
to send to client R bits/sec)
https://scied.ucar.edu/learning-zone/earth-system/electromagnetic-spectrum
Introduction 1-10
Access network: cable network
cable headend
cable splitter
modem
C
O
V V V V V V N
I I I I I I D D T
D D D D D D A A R
E E E E E E T T O
O O O O O O A A L
1 2 3 4 5 6 7 8 9
Channels
to/from headend or
central office
often combined
in single box
Introduction 1-13
Enterprise access networks (Ethernet)
institutional link to
ISP (Internet)
institutional router
Introduction 1-14
Wireless access networks
▪ shared wireless access network connects end system to router
• via base station aka “access point”
to Internet
to Internet
Introduction 1-15
Chapter 1: roadmap
1.1 what is the Internet?
1.2 network edge
▪ end systems, access networks, links
1.3 network core
▪ packet switching, circuit switching, network structure
1.4 delay, loss, throughput in networks
1.5 protocol layers, service models
1.6 networks under attack: security
1.7 history
Introduction 1-16
Circuit switching
end-end resources allocated
to, reserved for “call”
between source & dest:
▪ in diagram, each link has four
circuits.
• call gets 2nd circuit in top
link and 1st circuit in right
link.
▪ dedicated resources: no sharing
• circuit-like (guaranteed)
performance
▪ circuit segment idle if not used
by call (no sharing)
▪ commonly used in traditional
telephone networks
Introduction 1-17
Circuit switching
15+16+15+10=56
Suppose that every connection requires 2 consecutive hops, and calls are
connected clockwise. For example, a connection can go from A to C, from B to D,
from C to A, and from D to B. With these constraints, what is the is the maximum
number of connections that can be ongoing in the network at any one time?
Suppose that every connection requires 2 consecutive hops, and calls are
connected clockwise. For example, a connection can go from A to C, from B to D,
from C to A, and from D to B. With these constraints, what is the is the maximum
number of connections that can be ongoing in the network at any one time?
18+2+11=31
frequency
time
TDM
frequency
time
Introduction 1-22
CS232
Computer Networks
• Interactive exercises:
http://gaia.cs.umass.edu/kurose_ross/interactive/
* Animations:
https://media.pearsoncmg.com/ph/esm/ecs_kurose_compn
etwork_8/cw/#interactiveanimations
Introduction 1-2
The network core: Packet Switching
▪ mesh of interconnected
routers
▪ packet-switching: hosts
break application-layer
messages into packets
• forward packets from one
router to the next, across
links on path from source
to destination
• each packet transmitted at
full link capacity
Introduction 1-3
Chapter 1: roadmap
1.1 what is the Internet?
1.2 network edge
▪ end systems, access networks, links
1.3 network core
▪ packet switching, circuit switching, network structure
1.4 delay, loss, throughput in networks
1.5 protocol layers, service models
1.6 networks under attack: security
1.7 history
https://www.javatpoint.com/computer-network-switching-techniques
Introduction 1-5
Four sources of packet delay
transmission
A propagation
B
nodal
processing queueing
Introduction 1-6
Four sources of packet delay
transmission
A propagation
B
nodal
processing queueing
Speed: 100Km/Hour
Time taken?
Introduction 1-8
Poll Everywhere
https://pollev.com/sayeedghani483
9
Introduction 1-10
Introduction 1-11
Propagation Delay : d(prop)
Speed: 100Km/Hour
Propagation delay
d(prop) = distance/speed = d/s
= 200km / 100km/hr
= 2 hours
Introduction 1-12
Propagation delay example:
▪ Propagation delay example:
• How long would it take a packet to go around the
world on a fiber optic cable?
• Circumference of Earth = 40,000km
• Assume propagation speed is at speed of light
about 300,000 km/sec
Introduction 1-13
Propagation delay example:
▪ Propagation delay example:
• How long would it take a packet to go around the
world on a fiber optic cable?
• Circumference of Earth = 40,000km
• Assume propagation speed is at speed of light
about 300,000 km/sec
Introduction 1-14
“Real” Internet delays, routes
E.g. mit.edu = domain name
95.100.239.225 is the IP address
3 probes 3 probes
3 probes
Introduction 1-17
“Real” Internet delays, routes
mit.edu = domain name
Introduction 1-19
“Real” Internet delays, routes
▪ How far is a 200ms router?
▪ d(prop) = distance / speed
▪ Distance = d(prop) * speed
= 200ms * 300,000 Km/sec
= 0.2 sec * 300,000 km/sec
= 60,000 km round trip
Introduction 1-20
“Real” Internet delays, routes
▪ How far is a 200ms router?
▪ d(prop) = distance / speed
▪ Distance = d(prop) * speed
= 200ms * 300,000 Km/sec
= 0.2 sec * 300,000 km/sec
= 60,000 km round trip
Introduction 1-21
Animation
https://media.pearsoncmg.com/ph/esm/ecs_kurose_compnetwork_8/cw/content/interactiveanimatio
ns/transmission-vs-propogation-delay/transmission-propagation-delay-ch1/index.html
Introduction 1-22
2. Transmission Delay: d(trans)
1000 bits
R = 10 bps
L bits
per packet
3 2 1
source destination
R bps R bps
Introduction 1-25
Animation
https://media.pearsoncmg.com/ph/esm/ecs_kurose_compnetwork_8/cw/content/interactiveanimatio
ns/transmission-vs-propogation-delay/transmission-propagation-delay-ch1/index.html
Transmission delay
d(trans) = Length of packet / bit Rate = L/R
= 100bytes x 8 bits/byte / 1Mb/s
= 800/1000 b/ms
= 0.8msec
Introduction 1-26
CS232
Computer Networks
Topics:
Summer 2024
• What is the Internet (Cont.)?
Sayeed Ghani • Protocol Layers
Lecture 9 • Security
Introduction 1-2
Protocol “layers”
Networks are complex,
with many “pieces”:
▪ hosts Question:
▪ routers is there any hope of
▪ links of various organizing structure of
media network?
▪ applications
▪ protocols …. or at least our
▪ hardware, discussion of networks?
software
Introduction 1-3
Organization of air travel
ticket (purchase) ticket (complain)
▪ a series of steps
Introduction 1-4
Layering of airline functionality
airplane routing airplane routing airplane routing airplane routing airplane routing
Introduction 1-5
Internet protocol stack
▪ application: supporting network
applications
• FTP, SMTP, HTTP application
▪ transport: process-process data
transfer transport
• TCP, UDP
network
▪ network: routing of datagrams from
source to destination
link
• IP, routing protocols
▪ link: data transfer between physical
neighboring network elements
• Ethernet, 802.111 (WiFi), PPP
▪ physical: bits “on the wire”
Introduction 1-6
Another view of the layers
1-7
Encapsulation / De-encapsulation
https://www.youtube.com/watch?v=FJIFfkpUO7o
https://www.youtube.com/watch?v=AH-09WaUK-4
Introduction 1-8
PDU=Protocol Data Unit
message M
source
application
Encapsulation
segment Ht M transport
datagram Hn Ht M network
frame Hl Hn Ht M link
physical
link
physical
switch
Datagram = Packet
destination Hn Ht M network
M application Hl Hn Ht M link Hn Ht M
Ht M transport physical
Hn Ht M network
Hl Hn Ht M link router
physical
https://www.youtube.com/watch?v=FJIFfkpUO7o
Introduction 1-9
https://www.youtube.com/watch?v=AH-09WaUK-4
PDU=Protocol Data Unit
message M
source
application
Encapsulation
segment Ht M transport
datagram Hn Ht M network
frame Hl Hn Ht M link
physical
Hl Hn Ht M link
physical
Note: The link layer Hl Hn Ht M switch
address (MAC address) will
change on each link
destination Hn Ht M network
M application Hl Hn Ht M link Hn Ht M
Ht M transport physical
Hn Ht M network
Hl Hn Ht M link router
physical
https://www.youtube.com/watch?v=FJIFfkpUO7o
Introduction 1-10
https://www.youtube.com/watch?v=AH-09WaUK-4
Encapsulation Analogy
Sending a letter
Introduction 1-11
Encapsulation Analogy
Transporting a car from Madinah to Riyadh
Madinah Riyadh
Car Car
Car on Car on
a truck a truck
Car on Car on
a truck on a truck on
a train a train
Introduction 1-12
Why layering?
dealing with complex systems:
▪ explicit structure allows identification,
relationship of complex system’s pieces
• layered reference model for discussion
▪ modularization eases maintenance, updating of
system
• change of implementation of layer’s service
transparent to rest of system
• e.g., change in gate procedure doesn’t affect rest of
system
▪ layering considered harmful?
Introduction 1-13
ISO/OSI reference model
▪ presentation: allow applications
to interpret meaning of data, application
e.g., encryption, compression,
machine-specific conventions presentation
▪ session: synchronization, session
checkpointing, recovery of data transport
exchange
network
▪ Internet stack “missing” these
layers! link
• these services, if needed, must be physical
implemented in application
• needed?
Introduction 1-14
Chapter 1: roadmap
1.1 what is the Internet?
1.2 network edge
▪ end systems, access networks, links
1.3 network core
▪ packet switching, circuit switching, network structure
1.4 delay, loss, throughput in networks
1.5 protocol layers, service models
1.6 networks under attack: security
1.7 history
Introduction 1-15
Network security
▪ field of network security:
• how bad guys can attack computer networks
• how we can defend networks against attacks
• how to design architectures that are immune to attacks
▪ Internet not originally designed with (much)
security in mind
• original vision: “a group of mutually trusting users
attached to a transparent network” ☺
• Internet protocol designers playing “catch-up”
• security considerations in all layers!
Introduction 1-16
Bad guys: put malware into hosts via Internet
▪ malware can get in host from:
• virus: self-replicating infection by receiving/executing
object (e.g., e-mail attachment)
• worm: self-replicating infection by passively receiving
object that gets itself executed
▪ spyware malware can record keystrokes, web
sites visited, upload info to collection site
▪ infected host can be enrolled in botnet, used for
spam. DDoS attacks
Introduction 1-17
Bad guys: attack server, network infrastructure
Denial of Service (DoS): attackers make resources
(server, bandwidth) unavailable to legitimate traffic
by overwhelming resource with bogus traffic
1. select target
2. break into hosts around
the network (see botnet)
3. send packets to target from
compromised hosts
target
Introduction 1-18
Bad guys can sniff packets
packet “sniffing”:
▪ broadcast media (shared Ethernet, wireless)
▪ promiscuous network interface reads/records all packets
(e.g., including passwords!) passing by
A C
Introduction 1-20
CS232
Computer Networks
Topics:
Summer 2024
• Application Layer (Ch. 2)
Sayeed Ghani • Overview (Cont.)
Lecture 11 • Protocol
• Transport Service Requirements
Thursday, July 4th
An application-layer protocol defines:
▪ types of messages exchanged, open protocols:
• e.g., request, response ▪ defined in RFCs, everyone
▪ message syntax: has access to protocol
• what fields in messages & definition
how fields are delineated ▪ allows for interoperability
▪ message semantics ▪ e.g., HTTP, SMTP
• meaning of information in proprietary protocols:
fields
▪ e.g., Skype, Zoom
▪ rules for when and how
processes send & respond to
messages
Application Layer: 2-2
What transport service does an app need?
data reliability throughput
▪ some apps (e.g., file transfer, ▪ some apps (e.g., multimedia)
web transactions) require require minimum amount of
100% reliable data transfer throughput to be “effective”
▪ other apps (e.g., audio) can ▪ other apps (“elastic apps”)
tolerate some loss make use of whatever
throughput they get
timing
▪ some apps (e.g., Internet security
telephony, interactive games) ▪ encryption, data integrity,
require low delay to be “effective” …
Application Layer: 2-3
Transport service requirements: common apps
application data loss throughput time sensitive?
Topics:
Summer 2024
• Application Layer (Ch. 2)
Sayeed Ghani • Overview (Cont.)
Lecture 12 • Traffic Calculations
• TCP vs UDP
Thursday, July 4th • TLS
Bits vs Bytes
• 1 Byte = 8 bits
1-2
Real-time Application Throughput requirements
2. Video conferencing:
sending 1 message (image) of size 1000 bytes every msec
Throughput required = ?
1-3
Real-time Application Throughput requirements
2. Video conferencing:
sending 1 message (image) of size 1000 bytes every msec
Throughput required = 1000x8 / 0.001 sec = 8 Mbps
1-4
Non-real time Applications
Non-real time application:
1. File download (no timing issue)
downloading MP3 file of size 100 Mbytes
Assume throughput is 1 Mbps, how long will it take?
Time = ?
1-5
Non-real time Applications
Non-real time application:
1. File download (no timing issue)
downloading MP3 file of size 100 Mbytes
Assume throughput is 1 Mbps, how long will it take?
Time = Size / throughput = 100x8 Mbits / 1 Mb/sec = 800 seconds
1-6
Throughput vs Delay
L=5000 bits s=200,000 km/s
R = 1 Mbps
d=2000 km
A B
Throughput = ?
1-7
Throughput vs Delay
L=5000 bits s=200,000 km/s
R = 1 Mbps
d=2000 km
A B
Throughput from A to B = ?
1-8
Throughput vs Delay
L=5000 bits s=200,000 km/s
R = 1 Mbps
d=2000 km
A B
1-9
Throughput vs Delay
Rs = 1 Mbps, R = 100 Mbps, Rc = 0.1 Mbps A
i.e. throughput from A to B = 0.1 Mbps
1-10
Throughput vs Delay
Topics:
Summer 2024
• Application Layer (Ch. 2)
Sayeed Ghani • Web & HTTP
Lecture 13 • Persistent vs Non-persistent HTTP
A1
Utilization
= fraction of used bandwidth
= throughput / Link bandwidth
Bottleneck
Throughput (A1-B1) 400 Mbps / 4
= Min (60, 100, 90) = 60 Mbps = 100 Mbps
HTML file
Lots of
images
1-6
An application-layer protocol defines:
▪ types of messages exchanged, open protocols:
• e.g., request, response ▪ defined in RFCs, everyone
▪ message syntax: has access to protocol
• what fields in messages & definition
how fields are delineated ▪ allows for interoperability
▪ message semantics ▪ e.g., HTTP, SMTP
• meaning of information in proprietary protocols:
fields
▪ e.g., Skype, Zoom
▪ rules for when and how
processes send & respond to
messages
Application Layer: 2-7
HTTP overview
HTTP: hypertext transfer protocol
▪ Web’s application-layer protocol
▪ client/server model: PC running
• client: browser that requests, Firefox browser
receives, (using HTTP protocol) and
“displays” Web objects
server running
• server: Web server sends (using Apache Web
HTTP protocol) objects in response server
to requests
iPhone running
Safari browser
switch
destination Hn Ht M network
M application Hl Hn Ht M link Hn Ht M
Ht M transport physical
Hn Ht M network
Hl Hn Ht M link router
physical
1-10
UDP Packets
1-11
Introduction
TCP Connection
access access
4321 access
net net
net
access
access net
net
access
access net
net
global
access
net
ISP access
net
access
net
access
net
access
net
access
net
access access
net access
net
net 4321
1-12
TCP connection = All packets will travel over same route
HTTP connections: two types
Non-persistent HTTP
1. TCP connection opened
2. at most one object sent
over TCP connection
3. TCP connection closed
downloading multiple
objects required multiple
connections
time time
Non-persistent HTTP response time = 2RTT+ file transmission time
Application Layer: 2-16
Animation
https://media.pearsoncmg.com/ph/esm/ecs_kurose_compnetwork_8/cw/content/interactiveanimat
ions/http-delay-estimation/index.html
~
~ entity body ~
~ body