Fundamentals of Computer Networks

undefined
Networking Potpourri:
Plug-n-Play, Next Gen
14-740: Fundamentals of Computer Networks
Credit: 
Bill Nace
traceroute
DHCP
NAT
IPv6
2
DHCP
Dynamic Host Configuration Protocol
Client-server mechanism to get config data
IP address, DNS server, etc
Client is usually a recently-booted host
RFC 1531 (1993) replaced BOOTP
Obsoleted by RFC 2131(1997)
DHCPv6, an IPv6 version in RFC 3315
3
Principle of Operation
Newly booted client needs configuration
details
Most important: its own IP address
Others: next-hop gateway, subnet mask,
DNS server, time servers, static routes,
TCP TTL value, etc
Broadcasts requests
Server, somewhere, responds with details
4
DHCP Server
Controls a pool of IP addresses
And a repository of network details
Provides these details upon request or
by default
Multiple servers possible
Also, a single server may serve multiple
subnets
5
Server: IP Allocation
Automatic allocation:
 A permanent IP
address is assigned to the client
Dynamic allocation:
 IP address is
assigned for a limited period of time
Allows for automatic reuse
Manual allocation:
 Sys admin decides
which IP addresses will be assigned to
each client
6
Leases
Used for dynamic allocation
Solution for control of when an address
can be given to another client
Because most clients won’t tell the
server when they disappear
Server allows use of addr for a set period
Client will need to reacquire permission
before lease period expires
7
undefined
DHCP Client
How does a client who doesn’t know
anything about the network (like its own
IP address) send messages to a DHCP
server?
8
undefined
DHCP Client
How does a client who doesn’t know
anything about the network (like its own
IP address) send messages to a DHCP
server?
9
 
 
 
 
B
r
o
a
d
c
a
s
t
!
 
S
e
n
d
 
t
o
 
2
5
5
.
2
5
5
.
2
5
5
.
2
5
5
U
s
e
s
 
U
D
P
,
 
p
o
r
t
 
6
7
M
a
y
 
g
e
t
 
r
e
s
p
o
n
s
e
s
 
f
r
o
m
 
m
u
l
t
i
p
l
e
 
s
e
r
v
e
r
s
DHCP Messages
Fields include
type: discover, offer, request, ack, release
xid: Random transaction value
chaddr: client hardware identifier
MAC or other opaque key
siaddr: server’s IP address
yiaddr: “your” address
options: lots of optional parameters
10
undefined
Discovery
Process
All communication is
broadcast
Thus the funky arrows in
our sequence diagram
Multiple servers may
respond
Client chooses
whichever offer it wishes
DHCP Request / Ack is
repeated to renew a lease
Security or lack thereof
Unauthorized server
Can get client to use your configuration
values (i.e. malicious DNS server)
Unauthorized client
Can get access to the network
Can get server to exhaust IP address
pool, and thus DOS the subnet
12
The Bottom Line
DHCP is critical for “plug and play”
network capabilities
Saves administrative hassles
... and errors from mis-configured values
Finding which host is re-using an IP
address can be a struggle, for instance
13
traceroute
DHCP
NAT
IPv6
14
Network Address Translation
Mechanism to simplify IP address allocation
Basic idea: Router appears as a single IP
address to the world, but manages a
complete subnet with many hosts
Maps one address space into another
Also called 
IP masquerading 
or
 IP spoofing
15
NAT Benefits
Work-around to the impending exhaustion of IP
addresses
Entire networks can operate with an allocation
of just a single IP address
Also allows for simple address allocation for
the subnet
No need to contact the ISP to add additional
end hosts
“Security”: internal network structure obscured
16
Mechanics
Hosts on private network use “non-routable”
IP addresses
Defined in RFC 1918
10.0.0.0/8 prefix
172.16.0.0/12 prefix
192.168.0.0/16 prefix
Packets restricted to the private subnet
Why?
17
xkcd.com/742
Mechanics (2)
Router shows a single external IP address
Translation table maps external IP / port
combinations to internal IP / port
Rewrites all packets in each direction,
changing IP / port based on translation
table
Other fixes also needed to the packet
18
Example
19
Operations vary based on contents of table --
other possibilities exist!
NAT Versions
Depending on contents of the table, may get differing
effects
Basic NAT: IP address translation only
Port Address Trans: IP and port translations
Source NAT: rewrites sender’s IP/Port
Dest NAT: rewrites destination’s IP/Port
Symmetric NAT: mapping corresponds to {send, rcvr}
pair
Requests sent from same sender but to different
destinations get different mappings 
 only an external
receiver can reply
20
Packet Fix-up
Router must do more than simply change
address/port values
Fix checksums
Some application protocols need fixing
FTP and SIP send IP/port values in the data
stream of the control channel
Must reassemble fragmented packets
Especially problematic if encryption has been
applied
21
Port Forwarding
Translation table is normally initialized by internal
traffic
Which means no external host can initiate
communication
One solution: 
connection reversal
, involves
ongoing communication with external server
Port forwarding
 specifies values ahead of time
Example: BitTorrent traffic will be handled by a
particular internal host with addr intIP, so forward
all traffic to extIP:6881 to intIP:6881
22
UPnP
Universal Plug and Play
1
 allows internal
hosts to discover NAT devices
... and then request particular mapping
... which can then be advertised to
external devices
UPnP is becoming universal
Requires client and NAT router to
understand the protocol
23
1
is a humungous standard that does lots of other stuff too
Purists love this, right?
Objection 1: IPv6 should be used to solve
addressing problem
Believe NAT has staved off adoption of IPv6
Objection 2: Violates end-to-end principle
Objection 3: Routers shouldn’t process
packets higher than network layer
Objection 4: Using port numbers to address
hosts
24
IPv6
Purpose
Addressing
Autoconfiguration
25
Purpose: More Addresses
Early 90s: "IP addr exhaustion coming"
How can that be?  2
32
 is 4 Billion hosts?
1996: 100% Class A, 62% Class B, 37%
Class C addresses assigned
2011: IANA allocated last remaining
blocks to regional registries
26
While we're at it...
Bigger addresses mean breaking the IPv4
header, so may as well do some other stuff at
the same time...
Streamline the header
Improve option processing
Self-configuration
BTW, breaking the header format means
everyone (all hosts and all routers) needs to
change -- leading to slow adoption rate
27
IPv6 Addresses
128 bit addresses
340 billion, billion, billion, billion addrs
2
128
 = 3.4 x 10
38
That should be enough for a while
28
xkcd.com/865/
Address Notation
Write IPv6 addresses using 4 hex digit
groups, separated by colons
Leading zeros are dropped, largest string
of contiguous zeros are not written
29
1987:A456:2B2B:1234:BEEF:5678:CAFE:D82F
124:A245::1:23
0124:A245:0000:0000:0000:0000:0001:0023
Address Classes
IPv6 Addresses are classless, like CIDR
Some addresses are special
:: (all zeros) is special (unspecified)
::1 is for loopback
Starts with 1111 1111 
 multicast
Starting with 1111 1110 10 
 link-local
more on this in a minute
30
undefined
Header Changes
IPv4 Header
IPv6 Header
Version 
 0110 (i.e. 6)
Traffic Class, Flow Label
Used to distinguish (give
priority to) "flows" of data
No definition of how to
use
Payload Length (in bytes)
32
IPv6 Header
Next Header: specifies the type of the
data
Is it UDP? 
 17
,
 TCP? 
 6
Same values and purpose as IPv4's
Upper Layer Protocol field
Or, is it an options field?
Specifies the type of an 
options
header
 placed at the beginning of
payload
Options headers may be chained,
last one specifies next header value
for payload
33
IPv6 Header
Hop Limit: Renamed
version of IPv4's TTL
Src, Dest Addresses
128 bit, so they take up a
large portion of header
Total header size: 40 bytes
34
IPv6
Purpose
Addressing
Autoconfiguration
35
Configuration
Process of getting an IP address (and
other data) to a newly booted end host
IP address needs to be unique
Often has no other requirement
A printer, for instance
Autoconfiguration is then possible
36
Autoconfiguration
Host wishing configuration can choose an
IPv6 address for themselves...
... as long as they can guarantee it is
unique
But, most hosts already have a
"guaranteed to be unique number" built
into their link-layer
Ethernet MAC address, for instance
37
IPv6 Autoconfiguration
Stateless Autoconfiguration
Use Link-local address prefix (1111 1110 10), ...
... followed by some zeros, ...
... followed by Ethernet MAC (48 bits)
Can be followed with Neighbor Discovery Protocol
(NDP) broadcast messages (RFC 4861)
to find network prefix IP addresses, next-hop
routers, DNS servers, etc
Stateful Configuration: DHCPv6 exists (RFC 3315)
38
undefined
Lesson Objectives
Now, you should be able to:
describe DHCP, including information
carried, methods of communication, leases,
message format and the discovery process
describe NAT, including benefits /
objections, operations and port forwarding
describe situations where NAT needs to
modify values other than IP address and
TCP/UDP port fields
39
undefined
You should be able to:
describe IPv6, including differences
with IPv4, benefits, datagram format,
and address notation
describe IPv6 address
autoconfiguration
Slide Note
Embed
Share

Explore the essentials of computer networks, covering topics such as DHCP, NAT, IPv6, server operations, and IP address allocation. Understand how DHCP servers control IP address pools and provide network configurations to clients. Learn about address leases for dynamic allocation and how DHCP clients communicate with servers using broadcasts. Delve into the principles of network configurations and the mechanisms behind DHCP protocols.

  • Computer Networks
  • DHCP
  • IPv6
  • Network Configurations
  • Server Operations

Uploaded on Sep 19, 2024 | 0 Views


Download Presentation

Please find below an Image/Link to download the presentation.

The content on the website is provided AS IS for your information and personal use only. It may not be sold, licensed, or shared on other websites without obtaining consent from the author. Download presentation by click this link. If you encounter any issues during the download, it is possible that the publisher has removed the file from their server.

E N D

Presentation Transcript


  1. Networking Potpourri: Plug-n-Play, Next Gen 14-740: Fundamentals of Computer Networks Credit: Bill Nace Material from Computer Networking: A Top Down Approach, 6thedition. J.F. Kurose and K.W. Ross

  2. traceroute DHCP NAT IPv6 14-740: Spring 2017 2

  3. DHCP Dynamic Host Configuration Protocol Client-server mechanism to get config data IP address, DNS server, etc Client is usually a recently-booted host RFC 1531 (1993) replaced BOOTP Obsoleted by RFC 2131(1997) DHCPv6, an IPv6 version in RFC 3315 14-740: Spring 2017 3

  4. Principle of Operation Newly booted client needs configuration details Most important: its own IP address Others: next-hop gateway, subnet mask, DNS server, time servers, static routes, TCP TTL value, etc Broadcasts requests Server, somewhere, responds with details 14-740: Spring 2017 4

  5. DHCP Server Controls a pool of IP addresses And a repository of network details Provides these details upon request or by default Multiple servers possible Also, a single server may serve multiple subnets 14-740: Spring 2017 5

  6. Server: IP Allocation Automatic allocation: A permanent IP address is assigned to the client Dynamic allocation: IP address is assigned for a limited period of time Allows for automatic reuse Manual allocation: Sys admin decides which IP addresses will be assigned to each client 14-740: Spring 2017 6

  7. Leases Used for dynamic allocation Solution for control of when an address can be given to another client Because most clients won t tell the server when they disappear Server allows use of addr for a set period Client will need to reacquire permission before lease period expires 14-740: Spring 2017 7

  8. DHCP Client How does a client who doesn t know anything about the network (like its own IP address) send messages to a DHCP server? Broadcast! Send to 255.255.255.255 Uses UDP, port 67 May get responses from multiple servers 14-740: Spring 2017 9

  9. DHCP Messages Fields include type: discover, offer, request, ack, release xid: Random transaction value chaddr: client hardware identifier MAC or other opaque key siaddr: server s IP address yiaddr: your address options: lots of optional parameters 14-740: Spring 2017 10

  10. Discovery Process All communication is broadcast Thus the funky arrows in our sequence diagram Multiple servers may respond Client chooses whichever offer it wishes DHCP Request / Ack is repeated to renew a lease

  11. Security or lack thereof Unauthorized server Can get client to use your configuration values (i.e. malicious DNS server) Unauthorized client Can get access to the network Can get server to exhaust IP address pool, and thus DOS the subnet 14-740: Spring 2017 12

  12. The Bottom Line DHCP is critical for plug and play network capabilities Saves administrative hassles ... and errors from mis-configured values Finding which host is re-using an IP address can be a struggle, for instance 14-740: Spring 2017 13

  13. Network Address Translation Mechanism to simplify IP address allocation Basic idea: Router appears as a single IP address to the world, but manages a complete subnet with many hosts Maps one address space into another Also called IP masquerading or IP spoofing 14-740: Spring 2017 15

  14. NAT Benefits Work-around to the impending exhaustion of IP addresses Entire networks can operate with an allocation of just a single IP address Also allows for simple address allocation for the subnet No need to contact the ISP to add additional end hosts Security : internal network structure obscured 14-740: Spring 2017 16

  15. Mechanics Hosts on private network use non-routable IP addresses Defined in RFC 1918 10.0.0.0/8 prefix 172.16.0.0/12 prefix 192.168.0.0/16 prefix Packets restricted to the private subnet Why? xkcd.com/742 14-740: Spring 2017 17

  16. Mechanics (2) Router shows a single external IP address Translation table maps external IP / port combinations to internal IP / port Rewrites all packets in each direction, changing IP / port based on translation table Other fixes also needed to the packet 14-740: Spring 2017 18

  17. Example Operations vary based on contents of table -- other possibilities exist! 14-740: Spring 2017 19

  18. NAT Versions Depending on contents of the table, may get differing effects Basic NAT: IP address translation only Port Address Trans: IP and port translations Source NAT: rewrites sender s IP/Port Dest NAT: rewrites destination s IP/Port Symmetric NAT: mapping corresponds to {send, rcvr} pair Requests sent from same sender but to different destinations get different mappings only an external receiver can reply 14-740: Spring 2017 20

  19. Packet Fix-up Router must do more than simply change address/port values Fix checksums Some application protocols need fixing FTP and SIP send IP/port values in the data stream of the control channel Must reassemble fragmented packets Especially problematic if encryption has been applied 14-740: Spring 2017 21

  20. Port Forwarding Translation table is normally initialized by internal traffic Which means no external host can initiate communication One solution: connection reversal, involves ongoing communication with external server Port forwarding specifies values ahead of time Example: BitTorrent traffic will be handled by a particular internal host with addr intIP, so forward all traffic to extIP:6881 to intIP:6881 14-740: Spring 2017 22

  21. Purists love this, right? Objection 1: IPv6 should be used to solve addressing problem Believe NAT has staved off adoption of IPv6 Objection 2: Violates end-to-end principle Objection 3: Routers shouldn t process packets higher than network layer Objection 4: Using port numbers to address hosts 14-740: Spring 2017 24

  22. Purpose: More Addresses Early 90s: "IP addr exhaustion coming" How can that be? 232is 4 Billion hosts? 1996: 100% Class A, 62% Class B, 37% Class C addresses assigned 2011: IANA allocated last remaining blocks to regional registries 14-740: Spring 2017 26

  23. While we're at it... Bigger addresses mean breaking the IPv4 header, so may as well do some other stuff at the same time... Streamline the header Improve option processing Self-configuration BTW, breaking the header format means everyone (all hosts and all routers) needs to change -- leading to slow adoption rate 14-740: Spring 2017 27

  24. IPv6 Addresses 128 bit addresses 340 billion, billion, billion, billion addrs 2128= 3.4 x 1038 That should be enough for a while xkcd.com/865/ 14-740: Spring 2017 28

  25. Address Notation Write IPv6 addresses using 4 hex digit groups, separated by colons Leading zeros are dropped, largest string of contiguous zeros are not written 1987:A456:2B2B:1234:BEEF:5678:CAFE:D82F 0124:A245:0000:0000:0000:0000:0001:0023 124:A245::1:23 14-740: Spring 2017 29

  26. Address Classes IPv6 Addresses are classless, like CIDR Some addresses are special :: (all zeros) is special (unspecified) ::1 is for loopback Starts with 1111 1111 multicast Starting with 1111 1110 10 link-local more on this in a minute 14-740: Spring 2017 30

  27. Header Changes IPv4 Header

  28. IPv6 Header Version 0110 (i.e. 6) Traffic Class, Flow Label Used to distinguish (give priority to) "flows" of data No definition of how to use Payload Length (in bytes) 14-740: Spring 2017 32

  29. IPv6 Header Next Header: specifies the type of the data Is it UDP? 17, TCP? 6 Same values and purpose as IPv4's Upper Layer Protocol field Or, is it an options field? Specifies the type of an options header placed at the beginning of payload Options headers may be chained, last one specifies next header value for payload 14-740: Spring 2017 33

  30. IPv6 Header Hop Limit: Renamed version of IPv4's TTL Src, Dest Addresses 128 bit, so they take up a large portion of header Total header size: 40 bytes 14-740: Spring 2017 34

  31. Configuration Process of getting an IP address (and other data) to a newly booted end host IP address needs to be unique Often has no other requirement A printer, for instance Autoconfiguration is then possible 14-740: Spring 2017 36

  32. Autoconfiguration Host wishing configuration can choose an IPv6 address for themselves... ... as long as they can guarantee it is unique But, most hosts already have a "guaranteed to be unique number" built into their link-layer Ethernet MAC address, for instance 14-740: Spring 2017 37

  33. IPv6 Autoconfiguration Stateless Autoconfiguration Use Link-local address prefix (1111 1110 10), ... ... followed by some zeros, ... ... followed by Ethernet MAC (48 bits) Can be followed with Neighbor Discovery Protocol (NDP) broadcast messages (RFC 4861) to find network prefix IP addresses, next-hop routers, DNS servers, etc Stateful Configuration: DHCPv6 exists (RFC 3315) 14-740: Spring 2017 38

  34. Lesson Objectives Now, you should be able to: describe DHCP, including information carried, methods of communication, leases, message format and the discovery process describe NAT, including benefits / objections, operations and port forwarding describe situations where NAT needs to modify values other than IP address and TCP/UDP port fields 14-740: Fall 2017 39

  35. You should be able to: describe IPv6, including differences with IPv4, benefits, datagram format, and address notation describe IPv6 address autoconfiguration

More Related Content

giItT1WQy@!-/#giItT1WQy@!-/#giItT1WQy@!-/#giItT1WQy@!-/#giItT1WQy@!-/#