Re: UDP sockets bound to ANY send answers with wrong src ip address

From: Herbert Xu
Date: Fri Jun 11 2004 - 05:40:39 EST


Denis Vlasenko <vda@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx> wrote:
>
> I looked into sendmsg(). Looks like ther is no way to
> indicate source ip.
>
> Shall I use some other technique?

IP_PKTINFO works just as well there. Look at the ip_cmsg_send call
in udp_sendmsg.

Cheers,
--
Visit Openswan at http://www.openswan.org/
Email: Herbert Xu ~{PmV>HI~} <herbert@xxxxxxxxxxxxxxxxxxx>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
-
To unsubscribe from this list: send the line "unsubscribe linux-net" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html