Sending large SIP packets over UDP?

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

 



Hi all

I have a two questions regarding TCP/UDP transports, the first one is 
probably simple:

1. How do I force pjsip to use TCP for outgoing requests. I have 
configured two transports, one for TCP and one for UDP. Both calls to 
pjsua_transport_create(..) return successfully but all messages are 
always sent on UDP. I found some old posts on that ;transport=tcp should 
be added so I did this and it can be seen in the Request-Line. However 
the INVITE packet is always sent over UDP anyway. What do I need to do 
to properly force usage of TCP for outgoing requests?

2. We have encountered a problem which we have most likely narrowed down 
to payload size when transmitting over UDP. From a Windows Mobile phone 
connected over WiFi sending arbitrary INVITES always work but when we 
connect over 3G the successrate is random once the packet size gets to 
large. RFC 3261 states that TCP should be used for packages larger then 
1300 bytes so one guess here is that somewhere in the 3G network our 
packages are discarded when they get to large. I need assistance with if 
the problem is due to my TCP transport is not properly configured or if 
18.1.1. below is not handled by pjsip they way I interpret it. Does 
pjsip cater for switching to TCP like specified below?

RFC 3261 states the following:
 (18.1.1 Sending Requests) :  If a request is within 200 bytes of the 
path MTU, or if it is larger
   than 1300 bytes and the path MTU is unknown, the request MUST be sent
   using an RFC 2914 [43] congestion controlled transport protocol, such
   as TCP. If this causes a change in the transport protocol from the
   one indicated in the top Via, the value in the top Via MUST be
   changed.  This prevents fragmentation of messages over UDP and
   provides congestion control for larger messages.  However,
   implementations MUST be able to handle messages up to the maximum
   datagram packet size.  For UDP, this size is 65,535 bytes, including
   IP and UDP headers.

Thanks

Johan



[Index of Archives]     [Asterisk Users]     [Asterisk App Development]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [Linux API]
  Powered by Linux