Hi, I'm trying to send outbound calls to an external IP address adding a prefix, is this possible using function rewritehostport?
Thank you Max
Hi
No posible, please use append_branch() and seturi(" sip:08121069941@10.70.1.1:5060"); for forward call
UAC---->KAMAILIO A---->MSC---->Mobile Subscriber
# if someone calls B, the call should be forwarded to C too. if (method=="INVITE" && uri=~"sip:B@xx.xxx.xx ") { # copy the current branch (branches[0]) into # a new branch (branches[1]) append_branch(); # all URI manipulation functions work on branches[0] # thus, URI manipulation does not touch the # appended branch (branches[1]) seturi("sip:C@domain"); # now: branch 0 = C@domain # branch 1 = B@xx.xx.xx.xx
See Detail http://www.open-voip.org/index.php?title=Kamailio_%22revert%22_%22append_bra...
//Gafar
On Wed, Dec 3, 2014 at 5:56 PM, Massimo Varriale (IPZeta) < m.varriale@ipzeta.it> wrote:
Hi,
No, rewritehostport() only touches the domain part of the Request URI (the part after the @ symbol, in a typical URI). So, it can accomplish the first part of your request, but not the second.
That said, the rewritehostport() function is rather antiquated. It's much easier to manipulate the Request URI directly, and it would allow you to achieve both objectives. Take a look at pseudovariable documentation for $ru, $rU, $rd and $rp.
On 3 December 2014 03:56:11 GMT-05:00, "Massimo Varriale (IPZeta)" m.varriale@ipzeta.it wrote:
-- Sent from my mobile, and thus lacking in the refinement one might expect from a fully fledged keyboard.
Alex Balashov - Principal Evariste Systems LLC 235 E Ponce de Leon Ave Suite 106 Decatur, GA 30030 United States Tel: +1-678-954-0671 Web: http://www.evaristesys.com/, http://www.alexbalashov.com