ARP Protocol - PowerPoint PPT Presentation

1 / 29
About This Presentation
Title:

ARP Protocol

Description:

Amateur Radio AX.25. 3. Experimental Ethernet. 2. Ethernet. 1. Description. Type ... MAC: 00:00:2e:15:cb:0c. ???????????????? Router ???????? ARP Cache ???? ... – PowerPoint PPT presentation

Number of Views:418
Avg rating:3.0/5.0
Slides: 30
Provided by: Tang64
Category:
Tags: arp | cb | protocol | radio

less

Transcript and Presenter's Notes

Title: ARP Protocol


1
ARP Protocol ( Address Resolution Protocol )
RARP Protocol ( Reverse Address Resolution
Protocol )
2
ARP Protocol( Address Resolution Protocol )
  • ARP Message Format
  • ?????????? ARP
  • ARP Request
  • ARP Reply
  • ARP Proxy
  • ARP Cache

3
ARP Protocol(Address Resolution Protocol)
Physical address
Logical address
ARP
Ethernet address
IP address
Address Resolution Protocol
4
ARP Protocol( Address Resolution Protocol )
  • ???????????? IP Protocol
  • ????????????? IP Address ??????? MAC Address
  • ???????????????????????????????????? MAC Address
    ????????????????????
  • ??????????????????????????????????????????????
    router ?????????????????? gateway ?????????? MAC
    Address ??? router ???????????????

5
ARP Protocol( Address Resolution Protocol )
  • ARP query packet (Request) ???????????????? IP
    Address ????????????????????? ????? Broadcast
    ?????????????? MAC Address
  • ????????????????????????? MAC ?????????????? ARP
    Response packet

6
ARP/RARP packet
ARP/RARP packet
MAC header
ARP/RARP packet
15 16
0
31
Hardware type
Protocol type
Opcode
Prot address length
Hw. address length
Source hardware address
Source protocol address
Destination hardware address
Destination protocol address
7
Hardware Type ( 16 bits )
8
Hardware Type ( 16 bits )
9
ARP/RARP packet
Protocol Type ( 16 bits )
Hardware Address Length ( 8 bits )
Length of the hardware address in bytes.
Protocol Address Length ( 8 bits )
Length of the protocol address in bytes.
10
ARP/RARP packet
Opcode ( 8 bits )
11
ARP/RARP packet
Source Hardware Address ( 32 bits ) Variable
Length.
Source Protocol Address ( 32 bits ) Variable
Length.
Destination Hardware Address ( 32 bits
) Variable Length.
Destination Protocol Address ( 32 bits
) Variable Length.
12
ARP Message Format
  • Ethernet Destination
  • Address 6

Hard Type 2
Frame Type 2
  • Ethernet Source
  • Address 6

Prot Type 2
Hard Size 1
OP Field 2
Prot Size 1
  • Sender Ethernet
  • Address 6
  • Sender IP
  • Address 4
  • Target Ethernet
  • Address 6
  • Target IP Address 4

- Ethernet Destination Address (byte 0-5)
?????????? MAC Address ??????? ?????????????
ARP ????????????????????? broadcast
???????????????????????? 1 ???? FF FF FF FF FF FF
- Ethernet Source Address (byte 6-11) ??????????
MAC Address ??? ??????
13
ARP Message Format
  • Ethernet Destination
  • Address 6

Hard Type 2
Frame Type 2
  • Ethernet Source
  • Address 6

Prot Type 2
Hard Size 1
OP Field 2
Prot Size 1
  • Sender Ethernet
  • Address 6
  • Sender IP
  • Address 4
  • Target Ethernet
  • Address 6
  • Target IP Address 4
  • - Frame Type (byte 12-13) ???????????????????????
    ??
  • - Hard Type (byte 14-15) ????????????? hardware
    address ??? ARP ??????
  • Prot Type (byte 16-17) ?????????????????????????
    ???
  • Hard Size (byte 18) ???? address ??? hardware
  • Prot Size (byte 19) ???? address
    ???????????????????????????

14
ARP Message Format
  • Ethernet Destination
  • Address 6

Hard Type 2
Frame Type 2
  • Ethernet Source
  • Address 6

Prot Type 2
Hard Size 1
OP Field 2
Prot Size 1
  • Sender Ethernet
  • Address 6
  • Sender IP
  • Address 4
  • Target Ethernet
  • Address 6
  • Target IP Address 4

- OP Field (byte 20-21) ??????????? ARP ???????
1 ARP Request ? 2 ARP Reply
? 3 RARP Request
?
4 RARP Reply - Sender Ethernet Address (byte
22-27) ?????????? ARP Reply ?????????
15
ARP Message Format
  • Ethernet Destination
  • Address 6

Hard Type 2
Frame Type 2
  • Ethernet Source
  • Address 6

Prot Type 2
Hard Size 1
OP Field 2
Prot Size 1
  • Sender Ethernet
  • Address 6
  • Sender IP
  • Address 4

Target IP Address 4
Target Ethernet Address 6
  • - Sender IP Address (byte 28-31) ?????????? IP
    Address ?????????
  • - Target Ethernet Address (byte 32-37)
    ????????????? ARP Request
  • Target IP Address (byte 38-41) ?????????? IP
    ???????????? ARP Reply

16
?????????? ARP
  • ???????????????????????????????????????? ARP
    ????????? ARP Request ????????????????????? IP
    ????????????????? MAC Address ????? host
    ?????????????????????? ??????????? broadcast
  • ????? host ???????????? IP ???????????????? ARP
    Request ??????????????????????????? ARP Reply
  • ????? host ?????? ARP Request ?????? ARP Reply
    ?????? ??????????? MAC Address ??? host ???????

17
ARP Packet
MAC HEADER Destination FFFFFFFFFFFF Source 02
068c2eb58b
IP HEADER Destination 158.108.1.5 Source 158.108.1
.2
ARP REQUEST MESSAGE What is your MAC address ?
18
ARP in Operation
158.108.1.5 0800207a4968
158.108.1.2 02068c2eb58b
ARP Request
ARP Reply
Who is 158.108.1.5? TO everyone From
158.108.1.2 (02068c2eb58b)
Its me 158.108.1.5 (0800207a4968) TO
158.108.1.2 (02068c2eb58b)
19
ARP Request Packet
Sample ARP Request Ethernet Packet
Des MAC (broadcast)
FF FF FF FF FF FF
Source MAC
08 00 20 7a 49 68
ARP frame type
0x806
Ethernet / IP
0x001
0x800
0x01
0x06
0x04
MAC6 / IP4 / request
Source MAC
08 00 20 7a 49 68
Source IP
158.108.1.2
dest MAC (unknown)
0 0 0 0 0 0
dest IP
158.108.1.5
20
ARP Reply Ethernet Packet
Sample ARP Request Ethernet Packet
Des MAC (broadcast)
8 0 20 7a 49 68
Source MAC
00 10 4B 13 0ABC
ARP frame type
0x806
Ethernet / IP
0x001
0x800
MAC6 / IP4 / reply
0x02
0x06
0x04
Source MAC
8 0 20 7a 49 68
Source IP
158.108.1.2
dest MAC (unknown)
00 10 4B 13 0A BC
dest IP
158.108.1.5
21
ARP Proxy
IP158.108.40.54 MAC 00002e15cb0c
Y
X
IP158.108.33.1 MAC 00000c06134a
IP158.108.40.1 MAC 00000c067790
Router
Router request Y
X to Y ARP request to Router
???????????????? Router ???????? ARP Cache
???? (???? ??????????????????? Router
????????????)?????????????????????????????????????
???????????? Host X ??????????? MAC Address ???
Host Y ???????????????? Router
22
ARP Proxy
IP158.108.40.54 MAC 00002e15cb0c
Y
X
IP158.108.33.1 MAC 00000c06134a
IP158.108.40.1 MAC 00000c067790
Router
R send 158.108.40.1 with 00000c06134a
Y send 158.108.40.1 with 00002e15cb0c
???????????????? Router ???????? ARP Cache
???? (???? ??????????????????? Router
????????????)?????????????????????????????????????
???????????? Host X ??????????? MAC Address ???
Host Y ???????????????? Router
23
ARP Proxy
  • ?????????????????????????????????????????????
    ???????????? Subnet ????? Host X ????????? Subnet
    ??????????? Host Y ?????? Subnet ????????
  • In case when the source know subnetmask, what is
    the operation?

24
ARP Cache

Y
X
Router
X to Y request
R send 158.108.40.1 with 00000c06134a
ARP Cache ??? ???????????????????????????? MAC
address ??? IP address ??????????????????????????
ARP Cache ????????????????????????? ARP Cache
??????????? ARP Request ??????????? ARP Cache
?????????????????????????????????????????
?????????????????????? 20 ????
25
RARP (Reverse Address Resolution Protocol )
Logical address
Physical address
RARP
Ethernet address
IP address
Reverse Address Resolution Protocol
26
RARP Packet
MAC HEADER Destination FFFFFFFFFFFF Source 08
00207a4968
IP HEADER Destination 111111111 Source ????????
RARP REQUEST MESSAGE What is my IP Address ?
27
RARP (Reverse Address Resolution Protocol )
  • ?????????????????? MAC Address ??????? IP
    Address
  • ?????? RARP Server ???????????????????? IP
    ????????????? diskless workstation
  • ???????????????????? ARP
  • 0x0835 for Ethernet RARP request
  • operation 0x003 RARP request
  • 0x004 RARP reply

28
Assignment
  • What is the purpose of ARP protocol?
  • Why we need ARP protocol, only network address is
    sufficient for communication?
  • If the destination IP node is not in the same
    subnetwork of the source IP node, how the packet
    would be send to the destination by the service
    of data-link layer and network layer?

29
THE END
???????? ??.??????? ????????????? 44010304
??.????? ?????????? 44010316 ?????????
?????? 44010410 ???????? ???????????
44010510
Write a Comment
User Comments (0)
About PowerShow.com