Hi Brandon,
get_redirects can be used only from failure_route since it process a
negative (3xx) reply - see example:
http://www.openser.org/docs/modules/0.10.x/uac_redirect.html#AEN247
the function fetch the contacts from 3xx and adds them as branches to
the transaction. Once set as branches, the URIs can not be altered
anymore - so you cannot change the contact between "get_redirects" and
"t_relay".
regards,
bogdan
Brandon Price wrote:
I am trying to implement call forwarding using the uac_redirect
module. My user agents reply with a SIP 302 Moved Temporarily message
when the unconditional call forward is set. In the contact field there
is something like this...
Contact Binding: <sip:[EMAIL PROTECTED]
<mailto:[EMAIL PROTECTED]>>
I need ser to add a plus to that then send the call back out to our
pstn carrier.
I have tried this...
if (t_check_status("302"))
get_redirects("6:2","redirect");
prefix("+");
rewritehost("pstn.carriers.ip");
t_relay();
and putting it in a failure route then forcing that route
failure_route[2] {
get_redirects("6:2","redirect");
prefix("+");
rewritehost("our.pstn.carriers.ip");
t_relay();
I even tried
if (t_check_status("302")){ # what to do if device tells
us to forward to another number
add_diversion("user-forward");
get_redirects("6:2","redirect");
prefix("+");
rewritehost("our.pstn.carriers.ip");
t_relay();
but apparently get_redirects can only be used in a failure_route
Has anyone been able to get this working? On a 302 get the redirects
from the contact field using get_redirects append with a "+" and
rewritehost somewhere else it seemed so simple.
Any help is as always greatly appreciated, especially
from [EMAIL PROTECTED] <mailto:[EMAIL PROTECTED]> cause like
me he's too far for norway beer.
------------------------------------------------------------------------
_______________________________________________
Users mailing list
[email protected]
http://openser.org/cgi-bin/mailman/listinfo/users
_______________________________________________
Users mailing list
[email protected]
http://openser.org/cgi-bin/mailman/listinfo/users