How to find remote MAC address from remote IP address

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

How to find remote MAC address from remote IP address

bandu
Hi,
 
How do I find out remote MAC address from remote IP address during TCP connection attempt?
I would like to implement MAC address filter on my application.
I'm using lwip 1.3.0 with a RAW API
 
thank you very much,

--
Bandu
[hidden email]

_______________________________________________
lwip-users mailing list
[hidden email]
http://lists.nongnu.org/mailman/listinfo/lwip-users
Reply | Threaded
Open this post in threaded view
|

RE: How to find remote MAC address from remote IP address

Bill Auerbach

Look at the function etharp_find_addr.  I think this will do it.

 

Bill

 

From: lwip-users-bounces+bauerbach=[hidden email] [mailto:lwip-users-bounces+bauerbach=[hidden email]] On Behalf Of Bandu
Sent: Wednesday, February 25, 2009 11:22 AM
To: Mailing list for lwIP users
Subject: [lwip-users] How to find remote MAC address from remote IP address

 

Hi,

 

How do I find out remote MAC address from remote IP address during TCP connection attempt?

I would like to implement MAC address filter on my application.

I'm using lwip 1.3.0 with a RAW API

 

thank you very much,

--
Bandu
[hidden email]


_______________________________________________
lwip-users mailing list
[hidden email]
http://lists.nongnu.org/mailman/listinfo/lwip-users
Reply | Threaded
Open this post in threaded view
|

Re: How to find remote MAC address from remote IP address

David Empson

ARP will only work if the remote IP address is on the same subnet and your network interface is Ethernet or similar (e.g. WiFi).
 
If the remote IP address might be further afield than the same LAN (i.e. there is a router between you and the remote IP address) then you can't find its MAC address. The same applies if your network interface is PPP, which doesn't use MAC addresses at all.
 
Trying to use the MAC address as authentication will limit you to a connection within the same LAN. If that is sufficient, then ARP is the correct solution, and LWIP should already have the MAC address in its ARP cache, because it will have used it to establish the TCP connection.
----- Original Message -----
Sent: Thursday, February 26, 2009 11:36 AM
Subject: RE: [lwip-users] How to find remote MAC address from remote IP address

Look at the function etharp_find_addr.  I think this will do it.

 

Bill

 

From: [hidden email] [mailto:lwip-users-bounces+bauerbach=[hidden email]] On Behalf Of Bandu
Sent: Wednesday, February 25, 2009 11:22 AM
To: Mailing list for lwIP users
Subject: [lwip-users] How to find remote MAC address from remote IP address

 

Hi,

 

How do I find out remote MAC address from remote IP address during TCP connection attempt?

I would like to implement MAC address filter on my application.

I'm using lwip 1.3.0 with a RAW API

 

thank you very much,

--
Bandu
[hidden email]


_______________________________________________
lwip-users mailing list
[hidden email]
http://lists.nongnu.org/mailman/listinfo/lwip-users
Reply | Threaded
Open this post in threaded view
|

Re: How to find remote MAC address from remote IP address

Mike Kleshov-2
MAC filtering can also be done in the ethernet interface driver.


_______________________________________________
lwip-users mailing list
[hidden email]
http://lists.nongnu.org/mailman/listinfo/lwip-users