<div dir="ltr">I had this somewhere before the RELAY<div><br></div><div>$var(destdom) = $du;<br>$td = $(var(destdom){s.replace,sip:,});</div><div><br></div><div>No idea why, this is a very old deployment. I think i wanted to set the domain instead of using "ds_set_domain" for some reason i can't quite remember now. I usually comment my code, but this one i didn't.</div><div><br></div><div>Thanks, sometimes when i'm stuck just write it out as a sounding board, i guess.<div><div dir="ltr" class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr"><div><br></div>David Villasmil<div>email: <a href="mailto:david.villasmil.work@gmail.com" target="_blank">david.villasmil.work@gmail.com</a></div><div>phone: +34669448337</div></div></div></div><br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Thu, Oct 29, 2020 at 11:47 PM Alex Balashov <<a href="mailto:abalashov@evaristesys.com">abalashov@evaristesys.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">:-)  What was it?<br>
<br>
On 10/29/20 6:54 PM, David Villasmil wrote:<br>
> Like i said: It was me.<br>
> <br>
> sorry for the noise<br>
> Regards,<br>
> <br>
> David Villasmil<br>
> email: <a href="mailto:david.villasmil.work@gmail.com" target="_blank">david.villasmil.work@gmail.com</a> <br>
> <mailto:<a href="mailto:david.villasmil.work@gmail.com" target="_blank">david.villasmil.work@gmail.com</a>><br>
> phone: +34669448337<br>
> <br>
> <br>
> On Thu, Oct 29, 2020 at 10:35 PM David Villasmil <br>
> <<a href="mailto:david.villasmil.work@gmail.com" target="_blank">david.villasmil.work@gmail.com</a> <mailto:<a href="mailto:david.villasmil.work@gmail.com" target="_blank">david.villasmil.work@gmail.com</a>>> <br>
> wrote:<br>
> <br>
>     I don't know what to think... knowing kamailio it's probably me<br>
>     somehow...<br>
> <br>
>     Regards,<br>
> <br>
>     David Villasmil<br>
>     email: <a href="mailto:david.villasmil.work@gmail.com" target="_blank">david.villasmil.work@gmail.com</a><br>
>     <mailto:<a href="mailto:david.villasmil.work@gmail.com" target="_blank">david.villasmil.work@gmail.com</a>><br>
>     phone: +34669448337<br>
> <br>
> <br>
>     On Thu, Oct 29, 2020 at 10:22 PM Alex Balashov<br>
>     <<a href="mailto:abalashov@evaristesys.com" target="_blank">abalashov@evaristesys.com</a> <mailto:<a href="mailto:abalashov@evaristesys.com" target="_blank">abalashov@evaristesys.com</a>>> wrote:<br>
> <br>
>         So it is your belief that Kamailio is modifying the To header<br>
>         via an<br>
>         unknown mechanism?<br>
> <br>
>         On 10/29/20 6:19 PM, David Villasmil wrote:<br>
>          > No, no to manipulation...<br>
>          ><br>
>          > Regards,<br>
>          ><br>
>          > David Villasmil<br>
>          > email: <a href="mailto:david.villasmil.work@gmail.com" target="_blank">david.villasmil.work@gmail.com</a><br>
>         <mailto:<a href="mailto:david.villasmil.work@gmail.com" target="_blank">david.villasmil.work@gmail.com</a>><br>
>          > <mailto:<a href="mailto:david.villasmil.work@gmail.com" target="_blank">david.villasmil.work@gmail.com</a><br>
>         <mailto:<a href="mailto:david.villasmil.work@gmail.com" target="_blank">david.villasmil.work@gmail.com</a>>><br>
>          > phone: +34669448337<br>
>          ><br>
>          ><br>
>          > On Thu, Oct 29, 2020 at 9:45 PM Alex Balashov<br>
>         <<a href="mailto:abalashov@evaristesys.com" target="_blank">abalashov@evaristesys.com</a> <mailto:<a href="mailto:abalashov@evaristesys.com" target="_blank">abalashov@evaristesys.com</a>><br>
>          > <mailto:<a href="mailto:abalashov@evaristesys.com" target="_blank">abalashov@evaristesys.com</a><br>
>         <mailto:<a href="mailto:abalashov@evaristesys.com" target="_blank">abalashov@evaristesys.com</a>>>> wrote:<br>
>          ><br>
>          >     Kamailio shouldn't be touching the To header at all,<br>
>         unless you're<br>
>          >     modifying it using uac_replace_to()?<br>
>          ><br>
>          >     -- Alex<br>
>          ><br>
>          >     On 10/29/20 5:35 PM, David Villasmil wrote:<br>
>          >      > Hello guys,<br>
>          >      ><br>
>          >      > This happened to me a long time ago but i totally<br>
>         forgot the reason.<br>
>          >      ><br>
>          >      > I using a simple dispatcher, and when relaying out to the<br>
>          >     destination,<br>
>          >      > kamailio is adding an additional :5060 port to the To<br>
>         header:<br>
>          >      ><br>
>          >      > To: <<a href="http://sip:910609738@172.31.6.1:5080" rel="noreferrer" target="_blank">sip:910609738@172.31.6.1:5080</a><br>
>         <<a href="http://sip:910609738@172.31.6.1:5080" rel="noreferrer" target="_blank">http://sip:910609738@172.31.6.1:5080</a>><br>
>          >     <<a href="http://sip:910609738@172.31.6.1:5080" rel="noreferrer" target="_blank">http://sip:910609738@172.31.6.1:5080</a>>:5060><br>
>          >      ><br>
>          >      > The Destination is actually <a href="http://172.16.6.1:5080" rel="noreferrer" target="_blank">172.16.6.1:5080</a><br>
>         <<a href="http://172.16.6.1:5080" rel="noreferrer" target="_blank">http://172.16.6.1:5080</a>><br>
>          >     <<a href="http://172.16.6.1:5080" rel="noreferrer" target="_blank">http://172.16.6.1:5080</a>> <<a href="http://172.16.6.1:5080" rel="noreferrer" target="_blank">http://172.16.6.1:5080</a>>, i<br>
>          >      > don't know why Kamailio is adding that :5060<br>
>          >      ><br>
>          >      > The dispatcher is<br>
>          >      ><br>
>          >      >    if (!ds_select_dst($var(dispatcher_outbound), "4")) {<br>
>          >      >          xlog("[DISPATCH]: ds_select_dst FAILED!\n");<br>
>          >      >          send_reply("404", "No destination");<br>
>          >      >          exit;<br>
>          >      >      } else {<br>
>          >      >          xlog("[DISPATCH]: ds_select_dst was<br>
>         succesful\n");<br>
>          >      >      }<br>
>          >      >      xlog("L_DBG", "[DISPATCH]: going to <$ru> via<br>
>         <$du>\n");<br>
>          >      >      t_on_failure("RTF_DISPATCH");<br>
>          >      >      route(RELAY);<br>
>          >      ><br>
>          >      > Any ideas? I totally forgot... and it's late, i guess...<br>
>          >      ><br>
>          >      > Thanks!<br>
>          >      ><br>
>          >      > David Villasmil<br>
>          >      > email: <a href="mailto:david.villasmil.work@gmail.com" target="_blank">david.villasmil.work@gmail.com</a><br>
>         <mailto:<a href="mailto:david.villasmil.work@gmail.com" target="_blank">david.villasmil.work@gmail.com</a>><br>
>          >     <mailto:<a href="mailto:david.villasmil.work@gmail.com" target="_blank">david.villasmil.work@gmail.com</a><br>
>         <mailto:<a href="mailto:david.villasmil.work@gmail.com" target="_blank">david.villasmil.work@gmail.com</a>>><br>
>          >      > <mailto:<a href="mailto:david.villasmil.work@gmail.com" target="_blank">david.villasmil.work@gmail.com</a><br>
>         <mailto:<a href="mailto:david.villasmil.work@gmail.com" target="_blank">david.villasmil.work@gmail.com</a>><br>
>          >     <mailto:<a href="mailto:david.villasmil.work@gmail.com" target="_blank">david.villasmil.work@gmail.com</a><br>
>         <mailto:<a href="mailto:david.villasmil.work@gmail.com" target="_blank">david.villasmil.work@gmail.com</a>>>><br>
>          >      > phone: +34669448337<br>
>          >      ><br>
>          >      > _______________________________________________<br>
>          >      > Kamailio (SER) - Users Mailing List<br>
>          >      > <a href="mailto:sr-users@lists.kamailio.org" target="_blank">sr-users@lists.kamailio.org</a><br>
>         <mailto:<a href="mailto:sr-users@lists.kamailio.org" target="_blank">sr-users@lists.kamailio.org</a>><br>
>         <mailto:<a href="mailto:sr-users@lists.kamailio.org" target="_blank">sr-users@lists.kamailio.org</a><br>
>         <mailto:<a href="mailto:sr-users@lists.kamailio.org" target="_blank">sr-users@lists.kamailio.org</a>>><br>
>          >      ><br>
>         <a href="https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users" rel="noreferrer" target="_blank">https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users</a><br>
>          >      ><br>
>          ><br>
>          >     --<br>
>          >     Alex Balashov | Principal | Evariste Systems LLC<br>
>          ><br>
>          >     Tel: +1-706-510-6800 / +1-800-250-5920 (toll-free)<br>
>          >     Web: <a href="http://www.evaristesys.com/" rel="noreferrer" target="_blank">http://www.evaristesys.com/</a>, <a href="http://www.csrpswitch.com/" rel="noreferrer" target="_blank">http://www.csrpswitch.com/</a><br>
>          ><br>
>          >     _______________________________________________<br>
>          >     Kamailio (SER) - Users Mailing List<br>
>          > <a href="mailto:sr-users@lists.kamailio.org" target="_blank">sr-users@lists.kamailio.org</a><br>
>         <mailto:<a href="mailto:sr-users@lists.kamailio.org" target="_blank">sr-users@lists.kamailio.org</a>><br>
>         <mailto:<a href="mailto:sr-users@lists.kamailio.org" target="_blank">sr-users@lists.kamailio.org</a><br>
>         <mailto:<a href="mailto:sr-users@lists.kamailio.org" target="_blank">sr-users@lists.kamailio.org</a>>><br>
>          > <a href="https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users" rel="noreferrer" target="_blank">https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users</a><br>
>          ><br>
>          ><br>
>          > _______________________________________________<br>
>          > Kamailio (SER) - Users Mailing List<br>
>          > <a href="mailto:sr-users@lists.kamailio.org" target="_blank">sr-users@lists.kamailio.org</a> <mailto:<a href="mailto:sr-users@lists.kamailio.org" target="_blank">sr-users@lists.kamailio.org</a>><br>
>          > <a href="https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users" rel="noreferrer" target="_blank">https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users</a><br>
>          ><br>
> <br>
>         -- <br>
>         Alex Balashov | Principal | Evariste Systems LLC<br>
> <br>
>         Tel: +1-706-510-6800 / +1-800-250-5920 (toll-free)<br>
>         Web: <a href="http://www.evaristesys.com/" rel="noreferrer" target="_blank">http://www.evaristesys.com/</a>, <a href="http://www.csrpswitch.com/" rel="noreferrer" target="_blank">http://www.csrpswitch.com/</a><br>
> <br>
>         _______________________________________________<br>
>         Kamailio (SER) - Users Mailing List<br>
>         <a href="mailto:sr-users@lists.kamailio.org" target="_blank">sr-users@lists.kamailio.org</a> <mailto:<a href="mailto:sr-users@lists.kamailio.org" target="_blank">sr-users@lists.kamailio.org</a>><br>
>         <a href="https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users" rel="noreferrer" target="_blank">https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users</a><br>
> <br>
> <br>
> _______________________________________________<br>
> Kamailio (SER) - Users Mailing List<br>
> <a href="mailto:sr-users@lists.kamailio.org" target="_blank">sr-users@lists.kamailio.org</a><br>
> <a href="https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users" rel="noreferrer" target="_blank">https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users</a><br>
> <br>
<br>
-- <br>
Alex Balashov | Principal | Evariste Systems LLC<br>
<br>
Tel: +1-706-510-6800 / +1-800-250-5920 (toll-free)<br>
Web: <a href="http://www.evaristesys.com/" rel="noreferrer" target="_blank">http://www.evaristesys.com/</a>, <a href="http://www.csrpswitch.com/" rel="noreferrer" target="_blank">http://www.csrpswitch.com/</a><br>
<br>
_______________________________________________<br>
Kamailio (SER) - Users Mailing List<br>
<a href="mailto:sr-users@lists.kamailio.org" target="_blank">sr-users@lists.kamailio.org</a><br>
<a href="https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users" rel="noreferrer" target="_blank">https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users</a><br>
</blockquote></div>