Hi,
Don't know whether this is the most appriopriate forum to ask, but I'll risk
it :)
I'm developping a linux networking app. (kernel 2.2.0+), using the default
sockets implementation offered by linux. I'm using C, and TCP/IP.
Two questions (somewhat overlapping, but I'm not sure if it is necessary to
know all of 2 to know 1):
1. how can I (=what is the best way to) know if a given IPv4 address is the
IP address of one of the local network interfaces (, or that is is not a
local IP address).
To get this information I do not want to make a TCP connection to any remote
machine (because I am not necessarily able to do so at the time I want this
to know), I do not want to peek in '/proc', and I do not want to run a
program from my program (like ifconfig).
2. how can I create a list of all local IP addresses.
Thanks,
--
Vik