<html><head><meta http-equiv="Content-Type" content="text/html; charset=us-ascii"><meta name="Generator" content="Microsoft Word 15 (filtered medium)"><style><!--
/* Font Definitions */
@font-face
        {font-family:"Cambria Math";
        panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0cm;
        font-size:11.0pt;
        font-family:"Calibri",sans-serif;
        mso-fareast-language:EN-US;}
span.EstiloCorreo17
        {mso-style-type:personal-compose;
        font-family:"Calibri",sans-serif;
        color:windowtext;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-family:"Calibri",sans-serif;
        mso-fareast-language:EN-US;}
@page WordSection1
        {size:612.0pt 792.0pt;
        margin:70.85pt 3.0cm 70.85pt 3.0cm;}
div.WordSection1
        {page:WordSection1;}
--></style></head><body lang="ES-CL" link="#0563C1" vlink="#954F72" style="word-wrap:break-word"><div class="WordSection1"><p class="MsoNormal"><a name="_Hlk3459566"><span lang="EN-US">Hi.</span></a></p><p class="MsoNormal"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US">I’m facing two problems with my mid_registrar module scenario.</span></span></p><p class="MsoNormal"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US">The scenario is as follows:</span></span></p><p class="MsoNormal"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US"> </span></span></p><p class="MsoNormal"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US">UAC ------- MID_REGISTRAR ----- PBX</span></span></p><p class="MsoNormal"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US"> </span></span></p><p class="MsoNormal"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US">When a REGISTER came from the UAC to MID_REGISTRAR it has a header Expires:300</span></span></p><p class="MsoNormal"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US">I have set the </span></span></p><p class="MsoNormal"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US" style="font-family:"Courier New"">modparam("mid_registrar", "outgoing_expires", 3600)</span></span><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US"></span></span></p><p class="MsoNormal"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US"> </span></span></p><p class="MsoNormal"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US" style="font-family:"Courier New"">UAC ------------- MID_REGISTRAR ------------------- PBX</span></span></p><p class="MsoNormal"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US" style="font-family:"Courier New"">        REG</span></span></p><p class="MsoNormal"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US" style="font-family:"Courier New"">   Contact: (no expire)</span></span></p><p class="MsoNormal"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US" style="font-family:"Courier New"">   Expires: 300</span></span></p><p class="MsoNormal"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US" style="font-family:"Courier New"">                                     REG</span></span></p><p class="MsoNormal"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US" style="font-family:"Courier New"">                                    Contact: ( no expire)</span></span></p><p class="MsoNormal"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US" style="font-family:"Courier New"">                                    Expires: 3600</span></span></p><p class="MsoNormal"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US"> </span></span></p><p class="MsoNormal"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US">Seems ok!..</span></span></p><p class="MsoNormal"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US">But in another scenario I have:</span></span></p><p class="MsoNormal"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US">                                                                                                              </span></span></p><p class="MsoNormal"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US" style="font-family:"Courier New"">UAC ------------- MID_REGISTRAR ------------------- PBX</span></span></p><p class="MsoNormal"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US" style="font-family:"Courier New"">        REG</span></span></p><p class="MsoNormal"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US" style="font-family:"Courier New"">   Contact: (expire=600)</span></span></p><p class="MsoNormal"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US" style="font-family:"Courier New"">   Expires: 600</span></span></p><p class="MsoNormal"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US" style="font-family:"Courier New"">                                     REG</span></span></p><p class="MsoNormal"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US" style="font-family:"Courier New"">                                    Contact: (no expire)</span></span></p><p class="MsoNormal"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US" style="font-family:"Courier New"">                                    <b>Expires: 600</b></span></span></p><p class="MsoNormal"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US">                                               </span></span></p><p class="MsoNormal"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US"> </span></span></p><p class="MsoNormal"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US">I’m not getting why the mid_registrar does not modified the outgoing Expires to the PBX to 3600.  Anyone has a clue about this?</span></span></p><p class="MsoNormal" style="line-height:16.0pt"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US">Part of the configuration is:</span></span></p><p class="MsoNormal" style="line-height:16.0pt"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US" style="font-family:"Courier New"">### MID_REGISTRAR module</span></span></p><p class="MsoNormal" style="line-height:16.0pt"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US" style="font-family:"Courier New"">loadmodule "mid_registrar.so"</span></span></p><p class="MsoNormal" style="line-height:16.0pt"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US" style="font-family:"Courier New"">modparam("mid_registrar", "mode", 2) /* 0 = mirror / 1 = ct / 2 = AoR */</span></span></p><p class="MsoNormal" style="line-height:16.0pt"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US" style="font-family:"Courier New"">modparam("mid_registrar", "outgoing_expires", 3600)</span></span></p><p class="MsoNormal" style="line-height:16.0pt"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US" style="font-family:"Courier New"">modparam("mid_registrar", "contact_id_insertion", "ct-param")</span></span></p><p class="MsoNormal" style="line-height:16.0pt"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US" style="font-family:"Courier New"">modparam("mid_registrar", "max_contacts", 6)</span></span></p><p class="MsoNormal" style="line-height:16.0pt"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US" style="font-family:"Courier New"">modparam("mid_registrar", "received_avp", "$avp(rcv)")</span></span></p><p class="MsoNormal" style="line-height:16.0pt"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US" style="font-family:"Courier New"">modparam("mid_registrar", "extra_contact_params_avp", "$avp(extra_ct_params)")</span></span></p><p class="MsoNormal" style="line-height:16.0pt"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US" style="font-family:"Courier New""> </span></span></p><p class="MsoNormal" style="line-height:16.0pt"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US" style="font-family:"Courier New"">if (( is_method("REGISTER")) && (!has_totag())) {</span></span></p><p class="MsoNormal" style="line-height:16.0pt"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US" style="font-family:"Courier New"">mid_registrar_save("location","M<rinstance>");</span></span></p><p class="MsoNormal" style="line-height:16.0pt"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US" style="font-family:"Courier New"">                switch($retcode) {</span></span></p><p class="MsoNormal" style="line-height:16.0pt"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US" style="font-family:"Courier New"">                        case 1:</span></span></p><p class="MsoNormal" style="line-height:16.0pt"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US" style="font-family:"Courier New"">                                $du = $var(r_pbx_sethost);</span></span></p><p class="MsoNormal" style="line-height:16.0pt"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US" style="font-family:"Courier New"">                                xlog("[$ci] [from_vex] [REGISTER sin totag][mid_registrar_save]: Retorna valor 1\n");</span></span></p><p class="MsoNormal" style="line-height:16.0pt"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US" style="font-family:"Courier New"">                                xlog("[$ci] [from_vex] [REGISTER sin totag][mid_registrar_save]: $fu salvado en tabla location\n");</span></span></p><p class="MsoNormal" style="line-height:16.0pt"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US" style="font-family:"Courier New"">                                t_relay(,$var(r_pbx_send));</span></span></p><p class="MsoNormal" style="line-height:16.0pt"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US" style="font-family:"Courier New"">                                xlog("[$ci] [from_vex] [REGISTER sin totag][mid_registrar_save]: Redirecting $rm to destination [$var(r_pbx)]\n");</span></span></p><p class="MsoNormal" style="line-height:16.0pt"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US" style="font-family:"Courier New"">                                exit;</span></span></p><p class="MsoNormal" style="line-height:16.0pt"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US" style="font-family:"Courier New"">                        case 2:</span></span></p><p class="MsoNormal" style="line-height:16.0pt"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US" style="font-family:"Courier New"">                                xlog("[$ci] [from_vex] [REGISTER sin totag][mid_registrar_save]: Retorna valor 2\n");</span></span></p><p class="MsoNormal" style="line-height:16.0pt"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US" style="font-family:"Courier New"">                                xlog("[$ci] [from_vex] [REGISTER sin totag][mid_registrar_save]: Absorbiendo $rm from $si to domain $rd\n");</span></span></p><p class="MsoNormal" style="line-height:16.0pt"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US" style="font-family:"Courier New"">                                </span></span><span style="mso-bookmark:_Hlk3459566"><span style="font-family:"Courier New"">break;</span></span></p><p class="MsoNormal" style="line-height:16.0pt"><span style="mso-bookmark:_Hlk3459566"><span style="font-family:"Courier New"">                        default:</span></span></p><p class="MsoNormal" style="line-height:16.0pt"><span style="mso-bookmark:_Hlk3459566"><span style="font-family:"Courier New"">                                xlog("[$ci] [from_vex] [REGISTER sin totag][mid_registrar_save]: Retorna valor -2\n");</span></span></p><p class="MsoNormal" style="line-height:16.0pt"><span style="mso-bookmark:_Hlk3459566"><span style="font-family:"Courier New"">                                xlog("[$ci] [from_vex] [REGISTER sin totag][mid_registrar_save]: SECURITY: No se puede salvar localmente el registro desde [$si] a dominio [$rd]\n");</span></span></p><p class="MsoNormal" style="line-height:16.0pt"><span style="mso-bookmark:_Hlk3459566"><span style="font-family:"Courier New"">                                </span></span><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US" style="font-family:"Courier New"">send_reply(503,"MID Register Failed");</span></span></p><p class="MsoNormal" style="line-height:16.0pt"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US" style="font-family:"Courier New"">                                exit;</span></span></p><p class="MsoNormal" style="line-height:16.0pt"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US" style="font-family:"Courier New"">                }</span></span></p><p class="MsoNormal" style="line-height:16.0pt"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US" style="font-family:"Courier New"">        }</span></span></p><p class="MsoNormal" style="line-height:16.0pt"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US">                                                                                  </span></span></p><p class="MsoNormal" style="line-height:16.0pt"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US"> </span></span></p><p class="MsoNormal" style="line-height:16.0pt"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US">Beside of that subsequest REGISTER from that endpoint are route to the PBX instead of absorve the REGISTERS.  Could this be related??</span></span></p><p class="MsoNormal" style="line-height:16.0pt"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US"> </span></span></p><p class="MsoNormal" style="line-height:16.0pt"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US"> </span></span></p><p class="MsoNormal" style="line-height:16.0pt"><span style="mso-bookmark:_Hlk3459566"><span lang="EN-US">Thanks!</span></span></p><span style="mso-bookmark:_Hlk3459566"></span><p class="MsoNormal"><b><span lang="EN-US" style="font-size:10.0pt;font-family:"Arial",sans-serif;color:#595959">Ricardo</span></b><span lang="EN-US"></span></p></div></body></html>