-   Linux - Networking (
-   -   Finding active computer in local network. (

greyblake 10-10-2011 04:09 PM

Finding active computer in local network.
Hi guys!
How can I find out what computers in my local network? I need to implement something similar to this:

nmap -sP
But need to implement it using pure C code without calling system().

nmap works pretty fast it doesn't look like it uses usual ping.


sunnydrake 10-10-2011 06:09 PM

grab source code of nmap and dig..
probably multicast ICMP packet or just inject bunch of ARP 223 12.449143 Casa_01:a9:4f Broadcast ARP Who has Tell
grab wireshark and look

macemoneta 10-10-2011 06:12 PM

You can just read /proc/net/arp and ignore entries with 00:00:00:00:00:00.

All times are GMT -5. The time now is 11:08 PM.