The solution I came up with is the following: given that two hosts already "know" (i.e. pinged) each other at least once you can perform the command
ping `arp -n | grep -i 00:17:C8:3B:81:94 | grep -o -E "\b[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\b"`
The only issue here is that the two hosts MUST have already "met" at least once.
This is because of the kernel ARP cache used by the "arp" command.
Useful?
No comments:
Post a Comment