getting local host address

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,
       I want to send ICMP pkts with my own IP header  (somewhat 
similar to traceroute) through a raw socket, but how do I get the 
local host address to fill the IP header's src address field. 
Since, my process is a daemon process I can't provide it myself 
everytime the address and then using gethostbyname() etc. which 
themselves require the host address in string or dotted form.
 	I welcome ur suggestions.

Murgan
_________________________________________________________
Click below to visit monsterindia.com and there is always a
better job for you at http://monsterindia.rediff.com/jobs

--
Kernelnewbies: Help each other learn about the Linux kernel.
Archive:       http://mail.nl.linux.org/kernelnewbies/
FAQ:           http://kernelnewbies.org/faq/


[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux