![]() There was a similar question answered not too long ago on this site. > # The time between ping and arp check must be small, as ARP may not cache long Knowing that, you do a little subprocess magic - otherwise you're writing ARP cache checking code yourself, and you don't want to do that: > from subprocess import Popen, PIPE That will place the target - as long as it's within your netmask, which it sounds like in this situation it will be - in your system's ARP cache. A small change to the regular expression will make it work in OS X.įirst, you must ping the target. I don't have Windows handy, so the following solution works on the Linux box I wrote it on. ![]() To answer the question with Python depends on your platform.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |