Hi, using Kamailio 3.2.0-dev5 (x86_64/linux) 552425.
Related conf:
------------------------------ modparam("registrar", "use_path", 1) modparam("registrar", "path_mode", 1)
modparam("nathelper", "natping_interval", 10) modparam("nathelper", "sipping_method", "OPTIONS") # No flag is set for NAT pinging... ------------------------------
REGISTER arrives coming from an outbound proxy which added Path header:
------------------ REGISTER sip:REGISTRAR SIP/2.0 Path: sip:PROXY;transport=udp;lr Contact: sip:pepe@192.168.1.232:23652;transport=udp;expires=3600 -----------------
Registration is performed, and since that, Kamailio starts sending ugly UDP datagrams to the Contact URI of the REGISTER:
U 2011/08/31 13:32:21.558022 REGISTRAR -> 192.168.1.232:45329 \x00\x00\x00\x00
So first question is: why is the UDP "ping" sent to the REGISTER Contact URI instead of sending it to the Path URI? NOTE: I know that I can add custom/propietary ";received" param in Path URI and set in the registrar server:
modparam("registrar", "path_use_received", 1)
but honestly that should be non needed.
Second question. Wouldn't be better if the UDP "ping" contains CRLF+CRLF rather than \x00\x00\x00\x00 ? At least, CRLF+CRLF is already defined as a SIP TCP ping.
Regards.
2011/8/31 Iñaki Baz Castillo ibc@aliax.net:
Second question. Wouldn't be better if the UDP "ping" contains CRLF+CRLF rather than \x00\x00\x00\x00 ? At least, CRLF+CRLF is already defined as a SIP TCP ping.
This is indeed documented:
UDP package - 4 bytes (zero filled) UDP packages are sent to the contact address.
On Wednesday 31 August 2011, Iñaki Baz Castillo wrote:
Hi, using Kamailio 3.2.0-dev5 (x86_64/linux) 552425.
Related conf:
modparam("registrar", "use_path", 1) modparam("registrar", "path_mode", 1)
modparam("nathelper", "natping_interval", 10) modparam("nathelper", "sipping_method", "OPTIONS")
# No flag is set for NAT pinging...
REGISTER arrives coming from an outbound proxy which added Path header:
REGISTER sip:REGISTRAR SIP/2.0 Path: sip:PROXY;transport=udp;lr Contact: sip:pepe@192.168.1.232:23652;transport=udp;expires=3600
Registration is performed, and since that, Kamailio starts sending ugly UDP datagrams to the Contact URI of the REGISTER:
U 2011/08/31 13:32:21.558022 REGISTRAR -> 192.168.1.232:45329 \x00\x00\x00\x00
So first question is: why is the UDP "ping" sent to the REGISTER Contact URI instead of sending it to the Path URI?
Hi Iñaki,
well, why is this UDP ping sended at all? Do you've anything in the logfiles about a timer that is run, ping sending etc..
Second question. Wouldn't be better if the UDP "ping" contains CRLF+CRLF rather than \x00\x00\x00\x00 ? At least, CRLF+CRLF is already defined as a SIP TCP ping.
Sounds indeed better.
Best regards,
Henning
2011/8/31 Henning Westerholt henning.westerholt@1und1.de:
Hi Iñaki,
well, why is this UDP ping sended at all? Do you've anything in the logfiles about a timer that is run, ping sending etc..
Basically yes (I've realized of that later). I didn't set the bflag just to ping natted clients, so UDP ping is used "always".
Second question. Wouldn't be better if the UDP "ping" contains CRLF+CRLF rather than \x00\x00\x00\x00 ? At least, CRLF+CRLF is already defined as a SIP TCP ping.
Sounds indeed better.
Just for curiosity, I've been for a while checking nathelper code and I cannot find where exactly those \x00\x00\x00\x00 bytes are set XDDD