"Standard" would be SNMP MIB entry .1.3.6.1.2.1.4.22
(.iso.org.dod.internet.mgmt.mib-2.ip.ipNetToMediaTable).
$ snmpwalk -v 2c fog.home .1.3.6.1.2.1.4.22
IP-MIB::ipNetToMediaIfIndex.1.192.168.1.94 = INTEGER: 1
...
IP-MIB::ipNetToMediaPhysAddress.1.192.168.1.94 = STRING: 0:13:d4:f4:2b:c4
...
IP-MIB::ipNetToMediaNetAddress.1.192.168.1.94 = IpAddress: 192.168.1.94
...
IP-MIB::ipNetToMediaType.1.192.168.1.94 = INTEGER: dynamic(3)
...
If your router does not support SNMP, your next option would be to connect using SSH or Telnet, run ip neigh
or arp -n
, then parse the output. (The "expect" tool is useful for automating Telnet logins and subsequent command-line interaction.)
If that isn't available either, you'll have to hack something up to scrape the web interface.