Daniel,

Adding double quotes around the second parameter of uac_reg_request_to does not help.

route{
    if (method=="REGISTER") {
        $rU = "daniel123";
        if(uac_reg_request_to("$rU", "0")){
            xlog("uac_reg_request_to remote user [$rU] on [$rd] via [$du]\n");
            t_on_failure("REMOTE_AUTH");
            t_relay();
        }
        exit;
    }
}
 0(24774) DEBUG: <core> [route.c:929]: fixing uac_reg_request_to()
 0(24774) ERROR: <core> [route.c:1216]: fixing failed (code=-1) at cfg:/usr/local/etc/kamailio/kamailio.cfg:71

regards,
Ron


On 8/20/2012 1:06 AM, Daniel-Constantin Mierla wrote:
Hello,


On 8/20/12 1:19 AM, Ron Hopson wrote:
Daniel,

Thank you for your response.  I was away the remainder of the past week.

Calls to uac_reg_lookup() and uac_reg_request_to(), with prior assignment or no assignment, yield "fixing failed (code=-1)".  For example,

     if(uac_reg_request_to("$rU", 0)){        #line 76

 0(16293) DEBUG: <core> [route.c:929]: fixing uac_reg_request_to()
 0(16293) ERROR: <core> [route.c:1216]: fixing failed (code=-1) at cfg:/usr/local/etc/kamailio/kamailio.cfg:76

I am most interested in function uac_reg_request_to().  I expect to receive a REGISTER command from a local user and forward it with proper credentials to a remote server.  I believe uac_reg_request_to() will read (a memory image of) the uacreg file for the remote user's name and credentials, and manage registration at the remote server.  Is this correct?

I would like to lookup the registration information by $tU. Both of the following code snippets get "fixing failed".
(1)     if(uac_reg_request_to("$tU", 0)){
and
(2)        $rU = $tU;
         if(uac_reg_request_to("$rU", 0)){

Thank you for any hints or examples of how to use uac_reg_request_to().
can you try putting the second parameter between double quotes? It should work without in the latest version, quotes being required in older releases, but just to check. I cannot test for the moment in my side, I will do it when I get a chance.


BTW:  How do I become a member of sr-users@lists.sip-router.org?

See:

http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users

Cheers,
Daniel

-- 
Daniel-Constantin Mierla - http://www.asipto.com
http://twitter.com/#!/miconda - http://www.linkedin.com/in/miconda
Kamailio Advanced Training, Seattle, USA, Sep 23-26, 2012 - http://asipto.com/u/katu
Kamailio Practical Workshop, Netherlands, Sep 10-12, 2012 - http://asipto.com/u/kpw