[SR-Users] How to rewritehostport() dynamically?
Alex Balashov
abalashov at evaristesys.com
Fri Jul 20 14:02:47 CEST 2012
Try modifying the request URI with $ru/$rU/$rd/$rp instead. See the pseudovariables page on the dokuwiki for more information.
rewritehostport() is a legacy function that does not deal with variables.
-- Alex
--
Sent from my Samsung mobile, and thus lacking in the refinement one might expect from a proper keyboard.
Alex Balashov - Principal
Evariste Systems LLC
235 E Ponce de Leon Ave
Suite 106
Decatur, GA 30030
Tel: +1-678-954-0670
Web: http://www.evaristesys.com/intel@intrans.baku.az wrote:Can I use rewritehostport() function with argument selected at time of
call processing?
I have a lua script, which gets address/port of next hop(from base)
But how to call rewritehostport() with it?
I can't find, how to call this function from lua script directly
(I've tried sr.tm.rewritehostport() and rewritehostport() - no success)
If i set pseudovariable (f.e $avp(relay)) and call
rewritehostport("$avp(relay)") from kamailio.cfg later, i can see in logs
such message:
ERROR: tm [ut.h:327]: failed to resolve "$avp(relay)"
Seems it use name of pv, not value?
What should I do to call this function with correct parameter?
--
_______________________________________________
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users at lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.sip-router.org/pipermail/sr-users/attachments/20120720/59b9386f/attachment.htm>
More information about the sr-users
mailing list