Find the answer to your Linux question:
Results 1 to 4 of 4
Can someone tell me if I tweak the destination field in an arp request for TCP connection to match it with the the mac addresses of different recivers in an ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    rks
    rks is offline
    Just Joined!
    Join Date
    Aug 2005
    Location
    India
    Posts
    5

    multiple arp replies


    Can someone tell me if I tweak the destination field in an arp request for TCP connection to match it with the the mac addresses of different recivers in an ethernet as the packet passes through in short each one catches the arp request and replies, what would happen I mean will the sender of arp request (reciever for arp reply) try to connect each one.

  2. #2
    Linux Guru sarumont's Avatar
    Join Date
    Apr 2003
    Location
    /dev/urandom
    Posts
    3,682
    I believe it would reply to whichever address it received back first. Do both of these machines have the same IP address, though?
    "Time is an illusion. Lunchtime, doubly so."
    ~Douglas Adams, The Hitchhiker's Guide to the Galaxy

  3. #3
    rks
    rks is offline
    Just Joined!
    Join Date
    Aug 2005
    Location
    India
    Posts
    5
    thanks sarumont,
    It really did so. But I would like to ask a related question.
    I have two systems with IP addresses 192.168.81.1 & 81.2. Now I in my program I used an class D IP address 224.0.81.3 for the multicast group containing both the machines. Next I created a packet socket on each machine listening to all ARP request made at the multicast IP address and sent a reply from each machine, now as u said it cared only for the first reply and a mapping was shown in ARP cache of client requesting (The mapping was 224.0.81.3 ---> 01:00:5e:00:51:03).
    Now according to mapping packet for connection was sent to each of the machines. But here I want to make just one of them to accept the connection according to my algorithm. Now can u tell me how can I achieve that.
    I tried using IPTables but found that they don't give that much of flexibility to decide upon the connection the fate of a packet according to one's own algorithm (if I'm wrong plz. tell me how can I use IPTables to determine the fate of a packet on the basis of the output of some C program or atleast shell script.). So now can u guide me wherein I should put my code to achieve the same.
    Hope u reply as quickly as u did last time & thanx again.

  4. #4
    Linux Guru sarumont's Avatar
    Join Date
    Apr 2003
    Location
    /dev/urandom
    Posts
    3,682
    So both the PCs in the multicast are receiving packets directed at the mcast IP, but you only want one to actually reply? I'm not sure if there's anyway to do this other than having the program that's capturing communicate amongst themselves on the LAN.
    "Time is an illusion. Lunchtime, doubly so."
    ~Douglas Adams, The Hitchhiker's Guide to the Galaxy

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •