Re: Changing the source IP of outgoing UDP packets on a socket

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

 



Quoting Seth Arnold <sarnold@wirex.com>:

> On Tue, Jan 28, 2003 at 06:41:30PM -0500, Kashif Shaikh wrote:
> > Currently, when I create the destination broadcast socket and send some
> > data, tcpdump shows the source IP to be 10.0.0.1.  But I need the source
> > IP to be 10.0.0.101!  
> 
> Does the bind(2) system call do what you need?
> 
> -- 
> "In time of war, the laws are silent." -- Chief Justice of the United
> States Supreme Court, William Rehnquist
> 


There is a type called SOCK_PACKET which you can specify when you create the 
socket.Using this you can create your own packets also. 
try reading up more information on this.
-sridhar
--
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