[Freeswitch-users] How to set invite domain on a sofia bridge?
Shaun Stokes
shaun.stokes at itec-support.co.uk
Fri Sep 21 14:56:32 UTC 2018
Hi All,
Freeswitch 1.8.1
Using sofia bridge inside a LUA script trying to set the domain on the INVITE to look like this:
INVITE sip:220 at mydomain.com:5060 SIP/2.0
Instead our invite looks like this:
INVITE sip:220 at 127.0.0.111:5060 SIP/2.0
We've tried setting various variables for domain\host, as follows:
domain_name = "mydomain.com";
session:execute("bridge_export","sip_invite_domain="..domain_name);
session:execute("bridge_export","domain_name="..domain_name);
session:execute("bridge_export","sip_from_host="..domain_name);
session:execute("bridge_export","sip_req_host="..domain_name);
session:execute("bridge_export","sip_to_host="..domain_name);
session:execute("bridge_export","sip_contact_host="..domain_name);
session:execute("bridge_export","sip_via_host="..domain_name);
session:execute("bridge", "sofia/internal/sip:"..dialed_extension.."@127.0.0.111:5060^"..dialed_extension.."@"..domain_name");
Tried putting the above exported variables inside the bridge using {}, like so:
session:execute("bridge", "{sip_invite_domain="..domain_name..",domain_name="..domain_name.."...etc...}sofia/internal/sip:"..dialed_extension.."@127.0.0.111:5060^"..dialed_extension.."@"..domain_name");
Tried with-out overriding the To header, like so:
session:execute("bridge", "sofia/local_internal/sip:"..dialed_extension.."@127.0.0.111:5060);
How do we set the invite domain on a bridge? Hope someone here can help.
Thanks,
Shaun
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20180921/826a569c/attachment-0001.html>
More information about the FreeSWITCH-users
mailing list