What I do not understand is how do you know the ephemeral source port number when creating the message? If idea is to reuse the existing connection for responses/further requests from other UA, connection-reuse draft provides solution
>-----Original Message----- >From: [EMAIL PROTECTED] >[mailto:[EMAIL PROTECTED] On Behalf Of >Russ Daigle >Sent: Wednesday, November 08, 2006 11:26 AM >To: sip-implementors@cs.columbia.edu >Subject: [Sip-implementors] Source port in Via/Contact headers >for TCP/TLS > >It appears that for non-UDP transports, one needs to use an >ephemeral source port number for the socket (even if reuseaddr >socket option is used). Like for UDP, I first tried always >using 5060 (or config >port) as source port for TCP/TLS. No big deal, I can use ephemeral >source port. > >Now for the question: > >In the Via and Contact headers, for UDP I would always put the >configured source port of my UDP socket. For TCP/TLS, should >I do the same of putting my ephemeral source port number of >the current socket that I am sending the request on? > >My guess is that people will say I should put the socket >source port in the Via header, and the Contact header should >have the port that >I'm listening on for new TCP/TLS connection requests. However, I >currently don't have a listening socket where I'm waiting for >new incoming requests, as I expect all communication to use >the same socket. (We are a test product that tries to break >SIP stacks.) > >While I'm on a roll here..... what is you thought about using >source ports in the From: header. (I know the RFC strongly >recommends against it. I'm currently putting the same thing >in From and Contact header, and all products I've tested with >(a fair number) don't care.) > >Regards, >-Russ >_______________________________________________ >Sip-implementors mailing list >Sip-implementors@cs.columbia.edu >https://lists.cs.columbia.edu/cucslists/listinfo/sip-implementors > _______________________________________________ Sip-implementors mailing list Sip-implementors@cs.columbia.edu https://lists.cs.columbia.edu/cucslists/listinfo/sip-implementors