Solved

ARP,RARP

Posted on 2004-10-26
7,569 Views
Last Modified: 2013-11-29
Please can anyone describe for me what is a ARP, RARP and where and in which way they are useful.

Please don`t mention the definition used in Webopedia. I studied them but didn`t got the exact point. Please describe them in detial.

thanks in advance.
0
Question by:dineshb_2001
    8 Comments
     
    LVL 95

    Expert Comment

    by:Lee W, MVP
    A MAC address is something like an electronic serial number.  Whenever info is sent from your computer, the packet contains the MAC Address.  ARP (Address Resolution Protocol) resolves the MAC address to an IP Address.  In a sense this identifies the calling computer connecting to your computer.  Think of it in terms of a car - the MAC is like a Vehicle Identification Number (VIN) and the license plate like an IP Address.  You can easy change the license plate and pass it to someone else, in theory, you can't do that easily with the VIN/MAC address.

    RARP is simply the reverse of ARP.  It effectively finds the MAC address of the device with an IP Address.

    It's important to note that network switches and routers can mask the correct MAC address of something as they can effectively replace it with their own as the packet travels through them
    0
     

    Expert Comment

    by:shaolee
    0
     
    LVL 2

    Expert Comment

    by:nettowa
    from the CCNA-

    The Address Resolution Protocol (ARP) is an Internet layer protocol that helps TCP/IP devices find other devices in the same broadcast domain. ARP uses a local broadcast to discover neighboring devices. Basically, ARP resolves an IP address of a destination to theMACaddress of the destination on the same data link layer medium. Remember that for two devices to talk to each other in Ethernet, the data link layer uses MAC addresses to differentiate the machines on the segment. And that when devices talk to each other at the data link layer, they need to know the destination’s MAC address.


    RARP-
    RARP is sort of the reverse of an ARP. In an ARP, the device knows the layer-3 address, but not the data-link layer address. With a RARP, the device doesn’t have an IP address and wants to acquire one. The only address that this device has is a MAC address. Common protocols that use RARP are BOOTP and the Dynamic Host Configuration Protocol (DHCP).

    0
     
    LVL 2

    Accepted Solution

    by:
    Hello,

    Well I will take it from you (and anyways I wasn't going to quote the definition.)

    ARP (Address Resolution Protocol) and R (Reverse) ARP are two different protocols performing two complementory operations. I hv given some live examples of ARP and RARP in operation (tho the example used to exaplain a form of ARP (Proxy ARP) will never occur in real life, but it gets the point accros.)

    note tho: NIC = Network Interface Card = LAN card

    ARP
    ----

    Taking that you are aware of the OSI model of internetworking, you might be knowing that the "Networking Layer" communicates using IP addresses. Suppose my computer (with IP address 10.109.1.1/24) wanted to send a packet to 10.109.1.2 then this would be the brief process:

    (1) - Since my IP address lies in the same subnet as 10.109.1.2 (more on this later) assume that the target IP address is physically connected to me. (or rather my NIC hving IP addr 10.109.1.2)

    The same subnet decision is made very easily. As you might be aware of, a IP address consists of a Network ID part and a Host ID part. If the Network IDs of two IP addresses are same, then they are considered to be physically reachable (connected to the same ethernet segment.)

    So the CIDR (Classless Inter-Domain Routing) /24 specifies that 10.109.1.1/24 has a host ID of 10.109.0.0 which is the same as that of 10.109.1.2.

    (2) - The packet is handed down to the Datalink layer without any modification.

    (3) - The datalink layer need to deliver the packet to the corresponding datalink layer on the destination machine. To do this, it will hv to hand appropiate information to the physical layer of the TCP/IP or OSI model. This appropiate machine consists of "the physical address of the target NIC" rather than the IP address. There fore, there must exist a way of mapping the IP address => to the physical address.

    The physical address in this case is the MAC (Medium Access Control) address which is unique for each manufactured NIC (Lan Card) in the world. Basically it is nothing but like the plot numbers assigned to each house which the mailman uses to deliver the snail mail. Very similar.

                             IP addr                                MAC addr
    (Upper layers) =======> (Data link layer) =========> (Physical layer), Source NIC
                                                                                                    |||
    (Upper layers) <======= (Data link layer) <========= (Physical layer), Dest NIC

    The three bars represent the actual connection, whether it be a cross over cable, connection via hub, switch or any other interface (like FDDI ring.)

    So this mapping of IP address to MAC address within a subnet "i.e. NICs hving same host id" is done using ARP.

    A typical ARP exchange is like so (taking our example above):

    10.109.1.1 > 10.109.1.255 (broadcast addr): arp who-has 10.109.1.2 tell 10.109.1.1
    10.109.1.2 > 10.109.1.1: arp reply 10.109.1.2 is-at 0:c:29:6c:d7:63

    one subtle point is that ARP REQUESTS are broadcast (delivered to all NICs within a subnet (physically connected)) but ARP REPLIES are Point-to-Point.

    now the 10.109.1.1 node is aware of the MAC address associated with 10.109.1.2 and thus passes the packets and the dest. MAC address to the :Physical layer: which delivers the packet.

    Proxy ARP: Suppose a bridge separated two different subnets. One 10.109.1.0/24 and other 10.109.2.0/24. ARP will be adequate for packet delivery within the respective subnets. But if a host , say H1(10.109.1.1), wants to send soming to host H2 (10.109.2.1) then what to do:

    1 - we could specify the IP address of the bridge/router as the default gateway for the subnet 10.109.1.0 so that if it wanted to communicate with some machine outside the subnet it would send the packets to the gateway which would do the routing.

    otherwise, 2 - trick the first subnet and make the bridge "reply" its mac address as the IP -- > MAC mapping during ARP process.

    10.109.1.1 > arp who-has 10.109.1.2 tell 10.109.1.1
    10.109.1.254 (the router) > arp reply 10.109.1.1 is-at (MAC ADDR)

    so the H1 will send its packet to the router and it will be handled appropiately. This is the use of proxy arp.

    R-ARP
    -------

    R-ARP was used earlier (now it has been replaced by technologies like BOOTP or DHCPD) to support diskless-workstation (a.k.a. thin clients)

    Suppose a machine was booted of a ROM medium with no facility of any configuration file to set a IP address, how would it obtain the parameters (in this case the IP Address.)

    to solve this problem, RARP was invented so that a thin client would broadcast its MAC address (which is embedded into the NIC (lan card) and dosent require any configuration expect putting in a required hardware) and a designated server would reply Point-to-Point to the MAC address that it should take its IP address to be whatever the sysadmin desided while performing the mapping.

    Better technologies hv replaced the need for RARP and its use has declined.

    Hope this gives a indepth view of the functioning of ARP and its less used sibling RARP.

    Kidoman
    0
     
    LVL 2

    Expert Comment

    by:kidoman
    Hi again,

    I was going through posts before mine, and I would like to contradict by saying that BOOTP and DHCP replaced the aging RARP protocol and dont use it in any way.

    Regds,

    Karan
    0
     
    LVL 4

    Expert Comment

    by:thribhu
    ARP is a layer 3 protocol  resolves MAC Address (Hexadecimal or NIC card address or Physical address) to IPaddress or logical address.Arp mailtains a table of Mac vs Ip address called as ARP cache...............

    at command prompt type arp -a   u can see what all hapens.....
    RARP does the reverse of this...........

    if u go in depth, allthough ARP is a layer 3 protocol it does not use an IP header, it has its own packet format and is a broadcast on the local LAN within the data field of a layer 2 frame without needing to be routed. The Ethernet Type field has the value 0x0806 to indicate an ARP.
     
    0
     
    LVL 2

    Expert Comment

    by:kidoman
    Hi thribhu,

    Sorry, but I think you are wrong about ARP resolving "MAC Address (Hexadecimal or NIC card address or Physical address) to IPaddress or logical address"

    ARP does exactly the opposite: maps IP addresses to MAC addresses because the physical addresses are what the physical layer understands and thus mandates to be able to succesfully send the frames.

    RARP obviously does the reverse but does not see the same frequency of use (if at all) as ARP does.

    Kidoman
    0
     
    LVL 2

    Expert Comment

    by:kidoman
    Thanks a lot.
    0

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone. Privacy Policy Terms of Use

    Featured Post

    Learn The Basics of Ethical Hacking & Pen Testing

    Computer and network security is one of the fastest growing and most essential industries in technology, meaning companies will pay big bucks for ethical hackers. This is the perfect course to leap into this lucrative career, learning how to use ethical hacking to reveal ...

    Article by: IanTh
    Hi Guys After a whole weekend getting wake on lan over the internet working, I thought I would share the experience. Your firewall has to have a port forward for port 9 udp to your local broadcast x.x.x.255 but if that doesnt work, do it to a …
    Please see preceding article here: http://www.experts-exchange.com/Networking/Operating_Systems/A_11209-Root-Bridge-Election.html Figure 1 After Root Bridge has been elected, then what?..... Let's start by defining a Root Port in la…
    Viewers will learn how to connect to a wireless network using the network security key. They will also learn how to access the IP address and DNS server for connections that must be done manually. After setting up a router, find the network security…
    Viewers will learn how to properly install and use Secure Shell (SSH) to work on projects or homework remotely. Download Secure Shell: Follow basic installation instructions: Open Secure Shell and use "Quick Connect" to enter credentials includi…

    875 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    10 Experts available now in Live!

    Get 1:1 Help Now