[Kamailio-Users] switch to TCP when UDP message is bigger than MTU

Klaus Darilion klaus.mailinglists at pernau.at
Sun Apr 26 22:13:42 CEST 2009


Stanisław Pitucha wrote:
> 2009/4/25 Andreas Heise <aheise at gmx.de>:
>> Klaus Darilion schrieb:
>>> Practically this paragraph from RFC 3261 is non-sense as it brakes
>>> communication with SIP clients.
>>>
>>> Residential customers SIP clients are mostly behind NAT and often do not
>>> even support TCP. Thus, automatic switching to TCP will cause problems
>>> as you can not reach the clients anymore.
>>>
>> you are right, but RFC 3261 says also...
>>
>> 18.2.1 Receiving Requests
>>
>> "For any port and interface that a server listens on for UDP, it MUST
>> listen on that same port and interface for TCP.
>> This is because a message may need to be sent using TCP, rather than
>> UDP, if it is too large."
>>
>> ... so the SIP clients you mentioned are not conform with RFC 3261!
> 
> Even if they do, the NATting node will simply reject the connection.
> You will have 50/50 chances that it's the client starting the
> connectino (works), and server starting the connection (fails on nat).
> It's not a nat-friendly standard, so it's safer to just ignore it.
> Also if your udp packet is bigger than MTU, it will simply get
> fragmented and transmitted anyways. If you have packets bigger than
> max udp size, then that's your main problem ;) If your equipment can't
> handle fragmentation, you will get a lot of strange problems one way
> or another.

That's correct. Switching from UDP to TCP is correct with the standard 
but does not work.

regards
klaus




More information about the sr-users mailing list