Problem using TCP transport

Support zone
Post Reply
yyzyyz
Posts: 5
Joined: Tue Jun 11, 2013 1:13 am

Problem using TCP transport

Post by yyzyyz » Wed Jun 19, 2013 4:21 pm

Hi,

I'm trying to use a SIP provider that exclusively supports TCP transport channel on a non-standard port. The channel between the user-agent and sipsorcery may be either UDP or TCP. I am able to successfully register with the provider by specifying the server name as follows:

Server: sip:hostname:port;transport=tcp

However, I'm unable to make any calls and get a 403 forbidden error. A google search for these symptoms revealed that others have also experienced similar problem because the INVITE messages were being sent over UDP, even though REGISTER was done over TCP. I can't say with certainty but this is what seems to be happening with sipsorcery as well. Even when I use TCP on the UA side to connect to sipsorcery.com (thus making it TCP throughout), I still see the following in the log when making a call:

DialPlan 11:15:27:209 sip1(5264): SIPClientUserAgent Call using alternate outbound proxy of udp:67.222.131.147:5060.
DialPlan 11:15:27:209 sip1(5264): Switching to sip:xyz@hostname:port via udp:67.222.131.147:5060.

It looks like UDP is still being used to send the INVITE to the provider, which responds with 403 forbidden.
Is there anyway to force TCP transport for all SIP messaging between sipsorcery and the provider?

Thanks!

Aaron
Site Admin
Posts: 4652
Joined: Thu Jul 12, 2007 12:13 am

Re: Problem using TCP transport

Post by Aaron » Thu Jun 20, 2013 9:59 am

Registrations and calls are completely separate so specifying a certain transport for your REGISTER requests will have no effect at all on your INVITE requests.

In order to get your INVITE requests to use TCP you need to use the same transport=tcp parameter in your dialplan.

Code: Select all

sys.Dial("1234@someprovider.com;transport=tcp")

yyzyyz
Posts: 5
Joined: Tue Jun 11, 2013 1:13 am

Re: Problem using TCP transport

Post by yyzyyz » Thu Jun 20, 2013 10:38 am

Thanks, that works!

raindropz
Posts: 1
Joined: Thu Sep 25, 2014 8:24 am

Re: Problem using TCP transport

Post by raindropz » Thu Sep 25, 2014 8:32 am

Thanks. I was facing issues with TCP transport and using the same transport=tcp parameter in the dial plan, fixed the problems for me. It was really confusing for me as I was not aware registrations and calls, are completely separate.



Thanks

Post Reply