Hi Guys,
I have been working on a number of different routines for call forwarding/hunt groups and came across an interesting oudity.
When I use failure_route and exec_dset and then use rewritehost and prefix the rewritehost and prefix do not work and my t_relay_to_udp fails. (this assuming I need to change the host.
Configuration example follows
failure_route[1] { exec_dset('/somdirectory/somescript.pl'); #returns a proper URI rewrite_host("host.com"); prefix(23423); t_relay_to_udp("gateway.com","5060"); }
Assuming the exec_dset returns "sip:test@mydomain.com" the t_relay_to_udp() will try contacting sip:test@mydomain.com" and not sip:test@gateway.com
Any ideas of why this happens. As it is now, I have my script do the rewrite_host and prefix job internally (assuming the call needs to go to my gateway).
Steve
I may be wrong but I suppose that's because exec_dset was created earlier than failure_route and does not include support for it completely. That said, finding the right reason and solution, even if probably trivial, takes a look in code. Volunteers wishing to do so are welcome, I can't promise doing so in reasonable time.
-jiri
At 06:46 PM 4/5/2004, Steven R. Bunin wrote:
Hi Guys,
I have been working on a number of different routines for call forwarding/hunt groups and came across an interesting oudity.
When I use failure_route and exec_dset and then use rewritehost and prefix the rewritehost and prefix do not work and my t_relay_to_udp fails. (this assuming I need to change the host.
Configuration example follows
failure_route[1] { exec_dset('/somdirectory/somescript.pl'); #returns a proper URI rewrite_host("host.com"); prefix(23423); t_relay_to_udp("gateway.com","5060"); }
Assuming the exec_dset returns "sip:test@mydomain.com" the t_relay_to_udp() will try contacting sip:test@mydomain.com" and not sip:test@gateway.com
Any ideas of why this happens. As it is now, I have my script do the rewrite_host and prefix job internally (assuming the call needs to go to my gateway).
Steve
Serusers mailing list serusers@lists.iptel.org http://lists.iptel.org/mailman/listinfo/serusers
-- Jiri Kuthan http://iptel.org/~jiri/
Jiri
Thanks for the quick response.. I will try to get a look at the code although I am not as good a C programmer as I would like to be.
Steve
Jiri Kuthan wrote:
I may be wrong but I suppose that's because exec_dset was created earlier than failure_route and does not include support for it completely. That said, finding the right reason and solution, even if probably trivial, takes a look in code. Volunteers wishing to do so are welcome, I can't promise doing so in reasonable time.
-jiri
At 06:46 PM 4/5/2004, Steven R. Bunin wrote:
Hi Guys,
I have been working on a number of different routines for call forwarding/hunt groups and came across an interesting oudity.
When I use failure_route and exec_dset and then use rewritehost and prefix the rewritehost and prefix do not work and my t_relay_to_udp fails. (this assuming I need to change the host.
Configuration example follows
failure_route[1] { exec_dset('/somdirectory/somescript.pl'); #returns a proper URI rewrite_host("host.com"); prefix(23423); t_relay_to_udp("gateway.com","5060"); }
Assuming the exec_dset returns "sip:test@mydomain.com" the t_relay_to_udp() will try contacting sip:test@mydomain.com" and not sip:test@gateway.com
Any ideas of why this happens. As it is now, I have my script do the rewrite_host and prefix job internally (assuming the call needs to go to my gateway).
Steve
Serusers mailing list serusers@lists.iptel.org http://lists.iptel.org/mailman/listinfo/serusers
-- Jiri Kuthan http://iptel.org/~jiri/