Transcript Document
Chapter 1
Networking Theory
1
Prepared By E.Musa Alyaman
Chapter 1 Outline
•
•
•
What Is a Network?
How Do Networks Communicate?
Network Components
- Data flow
- Addressing
•
Network Layers
–
–
•
Internet Architecture
–
–
•
•
2
IP Datagram format
ICMP
Major protocols
1. IP
2. ICMP
3. TCP
4. UDP
Security Issues
–
–
•
TCP/IP Protocol Suite Layers
OSI Layers
Firewalls
Proxy Servers
Chapter 1 Highlights
Prepared By E.Musa Alyaman
What Is a Network ?
• Data communication is the transfer of data
from one device to another via some form
of transmission medium.
• A Network: is a set of communication
devices connected by media links.
3
Prepared By E.Musa Alyaman
What Is a Network ?
• Network card – hardware needed for a computer
to talk to a network. The most common network
card in use is the Ethernet card
• Router – machines that act as switches. Direct
packets of data to the next “hop” across a
network
• Hub – provides connections that allow multiple
computers to access a network
• Gateway – connects one network to another
4
Prepared By E.Musa Alyaman
How Do Networks Communicate?
Connections between computers and devices:
1. Wires and cables – electricity sent
2. Infrared and RF (wireless)
3. Fiber-optics cable – use light
Through this connection, data is carried
between one point in the network to another,
data represented as bits of information (“on” or
“off”)
5
Prepared By E.Musa Alyaman
Network Components
• Components: message, sender, receiver,
medium, and protocol.
6
Prepared By E.Musa Alyaman
Data flow
• Data flow between two devices can occur
in one of three ways: simplex, half-duplex,
or full-duplex.
7
Prepared By E.Musa Alyaman
Simplex
8
Prepared By E.Musa Alyaman
Half-duplex
9
Prepared By E.Musa Alyaman
Full-duplex
10
Prepared By E.Musa Alyaman
Addressing
• Each node represented by an address just
as home address
• Manufacturer of NIC installed in every
devices connected to network is
responsible to ensure that no two card
carry the same address and chooses a
suitable addressing scheme
11
Prepared By E.Musa Alyaman
Addressing
• Commonly used term for physical address:
– Hardware address
– Ethernet address
– MAC address
– NIC address
• Addresses are used to send information to
the appropriate node
• Ethernet network cards are assigned a
unique 48-bit number
12
Prepared By E.Musa Alyaman
Sending a letter
13
Prepared By E.Musa Alyaman
Data Transmission Using Packets
• Data will be divided into smaller packets and
sent through network to reach its destination
• Packets may take different routes to reach the
destination depending on the routing approach
and congestion level of the network
• Mechanism to ensure no packets lost is
available depending on the protocol used to
send the data
14
Prepared By E.Musa Alyaman
Data Transmission Using Packets
• Packets consist of header and data
segment
• Header contains addressing information,
checksum to ensure no error and other
useful information needed for transmission
over the network
15
Prepared By E.Musa Alyaman
OSI model
16
Prepared By E.Musa Alyaman
Advantages of Layering
The Advantages of layering:
1. Simplify networking protocol by breaking them into
smaller and manageable
2. Offers better flexibility
The protocols that make up the TCP/IP suite have been
carefully designed with the following major
achievement:
1.
2.
3.
4.
17
Resource sharing between networks
Hardware and software independence
Reliability and robustness
“Good” protocols that are efficient and simple
Prepared By E.Musa Alyaman
Internet layers
The five-layer model provides guidelines for the development of
universally compatible networking protocols.
18
Prepared By E.Musa Alyaman
Summary of duties
19
Prepared By E.Musa Alyaman
Major protocols
1. Internet Protocol (IP)
•
•
•
•
•
•
•
20
Layer 3 protocol (network layer)
Used to transmit data packet over the Internet
The most widely used networking protocol in the world
All networking hardware support IP
Acts as a bridge between networks of different types
Packet-switching network protocol – no “connections
between” machines
Information exchanged between 2 host in the form of IP
packets – IP datagrams
Prepared By E.Musa Alyaman
IPv4 Datagram Format
21
Prepared By E.Musa Alyaman
Back
IP Address
• To map between a physical network address and an IP address,
Address Resolution Protocol (ARP) is used
• Four-byte (32 bits) address expressed in dotted decimal format
192.10.1.1
• Classful IP Addresses (first octet)
– Class A (1 - 126)
– Class B (128 – 191)
– Class C (192 - 223)
• What are IP addresses for yahoo/google/metalab?
• IP address are not designed with people in mind. Imagine textualbased name vs number-based name
• Mechanism to associate an easy-to-remember textual name with an
IP address – hostname
• DNS (Domain Name System)
22
Prepared By E.Musa Alyaman
Major Protocols
2. Internet Control Message Protocol (ICMP)
•
ICMP (RFC 792) is used by hosts and routers to
communicate network-layer information
– Error reporting
– Router signaling
•
•
One of the mechanisms to ensure Internet Protocol
runs error-free since IP provides no guarantee of
datagram delivery.
Example:
– “Destination network unreachable” is a message sent when a
host with a certain IP address cannot be found.
– This message originated from a router and is sent when it was not
able to find a path to the host.
23
Prepared By E.Musa Alyaman
ICMP
•
•
ICMP defines five error messages
1. Destination Unreachable
2. Parameter Problems
3. Redirect
4. Source Quench
5. Time Exceeded
ICMP also supports informational message:
•
•
•
24
Echo Request/Echo Reply
ICMP is a useful protocol, however only few network
application make use of it since its functionality is
limited to diagnostic and error notification
Famous application is ping which is used to determine
if host is alive or inaccessible and the delay between
sending a packet and receiving a response
Prepared By E.Musa Alyaman
Major Protocols
3. Transmission Control Protocol
–
–
–
–
–
25
Layer 4 protocol that provides guaranteed delivery
and ordering of bytes
Uses IP to send TCP segments
Contains additional information that allows it to order
packets and resend them if error occurs
Has extra layer of abstraction, by using a
communication port
Communication port – a numerical value ( 0 – 65535)
used to distinguish one application or service from
another
Prepared By E.Musa Alyaman
Major Protocols
4. User Datagram Protocol (UDP)
–
–
–
–
–
–
26
Layer 4 protocol to send packets of data
Raw access to IP datagram is not really easy to
determine which application a packet is for
Supports port number
Does not guarantee delivery of packets or will arrive
in the correct order
Faster data delivery but without error checking
feature
Video streaming etc.
Prepared By E.Musa Alyaman
TCP/IP Suite
HTTP
SMTP
TCP
FTP
POP3
UDP
Internet Protocol
27
Prepared By E.Musa Alyaman
ICMP
Internet Application Protocols
•
•
•
•
•
•
•
28
Telnet (port 23)
File Transfer Protocol (port 20 & 21)
Post Office Protocol Version 3 (POP3) (port 110)
Internet Message Access Protocol (IMAP) (port 150)
Simple Mail Transfer Protocol (SMTP) (port 25)
HyperText Transfer Protocol (HTTP) (port 80)
Network News Transport Protocol (NNTP) (port 119)
Prepared By E.Musa Alyaman
Firewalls for Developers
• Firewalls good for network administrators
but not to network developers
• Most corporate firewalls block direct UDP
and TCP access and making these
protocol unusable
• Hence, developers must make a choice –
either use standard Internet protocols and
ignore user who work behind firewalls or
adapt software to proxy requests using
protocols such a HTTP
29
Prepared By E.Musa Alyaman
Chapter Highlights
In this chapter, you have learned:
• What a network is
• How networks transmit information using packets and
addresses
• The layers of the OSI Reference Model
• The major protocols of the Internet, including the Internet
Protocol (IP),
• Internet Control Message Protocol (ICMP), Transmission
Control Protocol
• (TCP), and User Datagram Protocol (UDP)
• The effect of firewalls and proxy servers on users and
developers
30
Prepared By E.Musa Alyaman