tcp/ip networking

28
1 TCP/IP Networking Yue Cui 06/13/02

Upload: rian

Post on 26-Jan-2016

34 views

Category:

Documents


1 download

DESCRIPTION

TCP/IP Networking. Yue Cui 06/13/02. Presentation Outline. Introduction Packets and Encapsulation IP Addresses, Routing ARP, DHCP and PPP Security Issue Addition of Machines. Introduction. TCP/IP and the Internet A brief history ARPARNET(1969 by DARPA) Internet Management ICANN - PowerPoint PPT Presentation

TRANSCRIPT

Page 1: TCP/IP Networking

1

TCP/IP Networking

Yue Cui06/13/02

Page 2: TCP/IP Networking

2

Presentation Outline Introduction Packets and Encapsulation IP Addresses, Routing ARP, DHCP and PPP Security Issue Addition of Machines

Page 3: TCP/IP Networking

3

Introduction TCP/IP and the Internet

A brief history ARPARNET(1969 by DARPA)

Internet Management ICANN IETF ISOC

Standards and Documentation RFCs, FYIs, STDs and BCPs

Page 4: TCP/IP Networking

4

Introduction TCP/IP protocol suite

IP – routes data packets from one machine to another

ICMP – provides lower-level support for IP, including error messages, routing assistance and debugging help

ARP – translates IP address to hardware address (a.k.a. MAC address)

UDP and TCP – deliver data to specific applications on the destination machine

Page 5: TCP/IP Networking

5

Introduction TCP/IP family

Page 6: TCP/IP Networking

6

Presentation Outline Introduction Packets and Encapsulation IP Addresses, Routing ARP, DHCP and PPP Security Issue Addition of Machines

Page 7: TCP/IP Networking

7

Packets and Encapsulation Packet

Header—tells where the packet came from and where it’s going

Payload—actual data to be transferred

Page 8: TCP/IP Networking

8

Encapsulation

Layer

5

4

3

2

1

M

H4 M

H4

H4

H3

H3H2

M

M

M

H4 M

H4

H4

H3

H3H2

M

M

source machine

destination

machine

Page 9: TCP/IP Networking

9

Presentation Outline Introduction Packets and Encapsulation IP Addresses, Routing ARP, DHCP and PPP Security Issue Addition of Machines

Page 10: TCP/IP Networking

10

IP Addresses Historical Internet address classes

IP addresses were grouped into “classes” Class A,B and C denote regular IP

addresses. Class D and E are used for multicasting and research purpose.

Subnet masks Part of the host portion of an address is

“borrowed” to extend the network portion. Use ifconfig command to configure IP

address and subnet masks

Page 11: TCP/IP Networking

11

IP Addresses IP address crisis

We were going to run out of class B addresses by mid-1995

The routing tables of Internet backbone sites were growing so large that they would not fit in the memory of available routers

IP addresses were being allocated with no locality of reference

Page 12: TCP/IP Networking

12

IP Addresses Solution to the IP address crisis

CIDR (Classless Inter-Domain Routing) A short-term solution Manage the existing 4-byte address space that

uses the available addresses more efficiently and allows routing tables to be simplified by taking numerical adjacencies into account

IPv6 A long-term solution A revision of the IP protocol that expands the

address space to 16 bytes

Page 13: TCP/IP Networking

13

Routing Meaning

Looking up a network address in the routing table to forward a packet toward its destination

Building the routing table in the first place

Configure netstat route get (on BSD-based system)

Page 14: TCP/IP Networking

14

Presentation Outline Introduction Packets and Encapsulation IP Addresses, Routing ARP, DHCP and PPP Security Issue Addition of Machines

Page 15: TCP/IP Networking

15

ARP, DHCP and PPP ARP: Address Resolution Protocol

Discovers the hardware address(MAC address) associated with a IP address

Usage:Redhat% /sbin/arp –axor.com(192.108.21.1) at 08:00:20:77:5E:A0[ether] on eth0earth.xor.com(192.108.21.180) at 00:50:DA:12:4E:E5[ether]

on eth0

Page 16: TCP/IP Networking

16

ARP, DHCP and PPP DHCP: Dynamic Host Configuration

Protocol Dynamically assigns network parameters to

hosts Leasable parameters include:

IP addresses and netmasks Gateways(default routes) DNS name servers Syslog hosts WINS servers, proxy servers TFTP servers(for loading a boot image)

Page 17: TCP/IP Networking

17

ARP, DHCP and PPP PPP: Point-to-Point Protocol

Serial line encapsulation protocol that specifies how IP packets must be encoded for transmission on a slow serial line

Sometimes used with home technologies such as Dial-up, DSL and cable modem

Page 18: TCP/IP Networking

18

ARP, DHCP and PPP

System Commands Config files

Red Hat /usr/sbin/pppd /etc/ppp/options /usr/sbin/chat /etc/ppp/ppp.conf /etc/ppp/allow

Free BSD /usr/sbin/pppd /etc/ppp/options /usr/sbin/chat /etc/ppp/options.ttyserver /etc/ppp/chat.ttyserver

PPP-related commands and configuration files example

Page 19: TCP/IP Networking

19

Presentation Outline Introduction Packets and Encapsulation IP Addresses, Routing ARP, DHCP and PPP Security Issue Addition of Machines

Page 20: TCP/IP Networking

20

Security Issues IP forwarding ICMP redirects Source routing Broadcast pings and other forms of

directed broadcast UNIX-based firewalls Virtual private networks(VPN) IPSEC: secure IP

(Refer to Chapter 21 for details)

Page 21: TCP/IP Networking

21

Presentation Outline Introduction Packets and Encapsulation IP Addresses, Routing ARP, DHCP and PPP Security Issue Addition of Machines

Page 22: TCP/IP Networking

22

Addition of machines Basic steps

Assign an IP address and hostname Set up the new host to configure its

network interfaces at boot time Set up a default route Point to a DNS name server, to allow

access to the rest of the Internet

Page 23: TCP/IP Networking

23

Assign an IP address and hostname

/etc/hosts file Example from text book127.0.0.1 localhost192.108.21.48 lollipop.xor.com lollipop loghost192.108.21.254 chimchim-gw.xor.com chimchim-gw192.168.21.1 ns.xor.com ns192.225.33.5 licenses.xor.com license-server

hostname command Assigns a hostname to a machine Typically runs at boot time

Page 24: TCP/IP Networking

24

Configure network interface ifconfig command

Common form: ifconfig interface address options…

up/down For example:

Ifconfig en0 128.138.240.1 netmask 255.255.255.0 up

Options Netmask

Sets the subnet mask for the interface Broadcast

Specifies the IP broadcast address for the interface

Page 25: TCP/IP Networking

25

Configure static routes

route command Format:

route [-f] op [type] destination gateway [hop-count]

Options Add, delete, (get, change, flush, monitor)

Default routesroute add default gateway-IP-address

Page 26: TCP/IP Networking

26

Configure DNS

/etc/resolv.conf file All systems require to modify it Sample:

Search cs.colorado.edu colorado.eduNameserver 128.138.242.1Nameserver 128.138.243.151Nameserver 192.108.21.1

Page 27: TCP/IP Networking

27

Configure DNS “service switch” file

Some systems do not use DNS by default, these systems use “service switch” file to resolve hostname-to IP- address mapping

Service switch files by system

System Switch files Default for hostname lookups

Solaris /etc/nsswitch.conf

nis [NOTFOUND=return] files

HP-UX /etc/nsswitch.conf

dns [NOTFOUND=return] nis [NOTFOUND=return] files

Red Hat

/etc/nsswitch.conf/etc/host.conf

db files nisplus dnshosts, bind

FreeBSD

/etc/host.conf host,bind

Page 28: TCP/IP Networking

28

Thank you!

Questions?