[sr-dev] [tracker] Task opened: nathelper path support with registrar on private network.

sip-router admin at sip-router.org
Mon May 16 13:10:29 CEST 2011


THIS IS AN AUTOMATED MESSAGE, DO NOT REPLY.

A new Flyspray task has been opened.  Details are below. 

User who did this - Bruce McAlister (asgaroth) 

Attached to Project - sip-router
Summary - nathelper path support with registrar on private network.
Task Type - Bug Report
Category - Core
Status - Assigned
Assigned To - Andrei Pelinescu-Onciul
Operating System - Linux
Severity - Low
Priority - Normal
Reported Version - 3.1
Due in Version - Undecided
Due Date - Undecided
Details - Hi

I have a multihomed proxy that has one nic facing the "internet" and one nic on a private network segment. I then have a registrar server sitting only on the private segment. All registration requests are sent to the proxy to be dealt with. I would like to enable nat ping support on the registrar server. When I do this the nathelper module is unable to contact the end device. I have enabled path support on the registrar, the proxy sends on the path information and the registrar module successfully saves this information to the database. When the nathelper module tries to ping a device it is not using the path information to send the INFO/OPTIONS message out via the correct path. 

On the proxy, I execute the following route for registration requests:

route[REGISTRAR] {
        if (is_method("REGISTER")) {
                add_path_received();

                if(!ds_select_dst("2", "1")) {
                        sl_send_reply("500", "No destination available");
                        exit;
                }

                t_on_failure("DEST_INTERNAL");

                if(!t_relay()) {
                        sl_reply_error();
                }

                exit;
        }
}

on the registrar I have the following route defined:

route {
        if (is_method("REGISTER")) {

                ###
                ### Register Requests Only
                ###

                if (from_uri==myself) {
                        if (!www_authorize("$td", "subscriber")) {
                                www_challenge("$td", "0");
                                exit;
                        };
                        if ($au!=$tU) {
                                sl_send_reply("403","Forbidden auth ID");
                                exit;
                        };

                        consume_credentials();

                        setbflag(NAT_BFLAG);

                        if (!save("location","0x4")) {
                                sl_reply_error();
                                exit;
                        }
                }
        };
        exit;

}

I can see the "Path" header being set on the proxy and then sent to the registrar. That appears to be working normally. It's only when I enable nat pinging that I receive the following error in the logs:

ERROR: <core> [udp_server.c:586]: ERROR: udp_send: sendto(sock,0xf31a22,4,0,151.42.41.67:5062,16): Network is unreachable(101) 
ERROR: nathelper [nathelper.c:1722]: udp_send failed 

This makes sense to me as the registrar is on a private network. However, I would have assumed that the nathelper module would have used the path information to build the destination address to send the INFO/OPTIONS message to. Is this expected behaviour or a bug/configuration issue of sorts?

The proxy is running version: kamailio 3.1.3 (i386/linux) 41e576
The registrar is running version: kamailio 3.1.3 (i386/linux) 41e576

Please let me know if you need any more information from me.

Thanks

More information can be found at the following URL:
http://sip-router.org/tracker/index.php?do=details&task_id=131

You are receiving this message because you have requested it from the Flyspray bugtracking system.  If you did not expect this message or don't want to receive mails in future, you can change your notification settings at the URL shown above.



More information about the sr-dev mailing list