컴퓨터네트워크 #ARP

eunhak·2022년 10월 16일
0

컴퓨터네트워크

목록 보기
2/3

Ethernet Frame Structure


CRC(Cyclic Redundancy Checking): Check 후 error 발견되면 frame is simply dropped

Ethernet Address & Resolution

Ethernet frame is sent from one to another, it is the 48-bit Ehternet address that determines the destination

  • First 24-bits: Organization that made the Ethernet card
  • Second 24-bits: Randomly assigned by the manufacturer

ARP Table

IP address: 10.125.65.1
MAC address: 64 9e .. ..
-> manage this info for some period(usually 20 minutes) -> memory unit cache
Type: Dynamic(ARP cache)

ARP(Address Resolution Protocol)

ARP: Protocol used to do address resolution in the TCP/IP protocol suite(RFC826-IETF)

  • ARP provides a dynamic mapping from IP address to MAC address/Ethernet address

  • Manual mapping -> update가 필요하고, tedious함. -> Dynamic mapping 필요

Why ARP?

Dynamic mapping

  • not concern for application&user
  • not concern for system administrator

Any network layer protocol

  • not IP-specific

Supported protocol in data-link layer

  • not a data-link layer protocol

Need data-link with broadcasting capability

ARP -> Dynamic mapping, Broadcast *

RARP(Reverse Address Resolution Protocol)

Old computer -> No secondary storage(HDD, USB, ..) -> We cannot save on IP address permanently

ARP packet

ARP packet

ARP packet's data

ARP Request

ARP Reply

ARP Request/Reply

Incapsulation in Ethernet Frame

ARP Request/Reply Format

  • Hardware type: 1(Ethernet)
  • Protocol type: 0x0800(IP)
  • Hardware length: 6bytes(For ethernet)
  • Protocol length: 4bytes(For IP)
  • ARP operation: 1(Request), 2(Reply), 3,4(RARP Request, Reply)

ARP Request/Reply example

ARP Table

How to determine MAC address of B given B's IP address?

Each IP node(Host, Router) on LAN has ARP table.

ARP table: IP/MAC address mappings for some LAN nodes
<IP address;MAC address;TTL>

  • TTL(Time To Live): Time after which address mapping will be forgotten(typically 20 minutes)

Cases using ARP

Case 1. Host와 Receiver이 모두 same network(LAN)

Case 2. LAN의 Host가 another network의 다른 Receiver에게 전송

Case 3. Host와 Receiver이 모두 another network(LAN)

Case 4. another network의 Host가 LAN의 Receiver에게 전송

ARP cache

The efficient operation of ARP needs the maintenance of a cache on each host.
ARP replies are often boradcast so that all hosts can update their caches.

0개의 댓글