Hi,<br><br>I have on doubt, my scenario I have a SIP-Phone A that calls a SIP-Phone B establish the calls, after some time the SIP-Phone B send a Refer with Refer-To header pointing to a SIP-Phone C, the call scenario is working properly, except that the Invite generated by the B2B scenario to transfer the call to the SIP-Phone C is generated with the SIP-Phone B as From, so to the SIP-Phone C seams that the SIP-Phone B are calling him, but who is calling is SIP-Phone A.<br>
<br>There are some way to change this behavior in the B2B call scenario, or Can i use the UAC module in the script to replace the From header?<br><br>Regards,<br><br clear="all">Antonio Anderson Souza<br>Voice Technology<br>
<a href="http://www.antonioams.com">http://www.antonioams.com</a><br>
<br><br><div class="gmail_quote">On Wed, Apr 14, 2010 at 4:44 PM, Antonio Anderson Souza <span dir="ltr"><<a href="mailto:antonioams@gmail.com">antonioams@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Anca,<br><br>Thank you very much for your support, I've made the changes in my script and I got the refer scenarios working properly.<div class="im"><br><br>Regards,<br><br clear="all">Antonio Anderson Souza<br>Voice Technology<br>
<a href="http://www.antonioams.com" target="_blank">http://www.antonioams.com</a><br>
<br><br></div><div><div></div><div class="h5"><div class="gmail_quote">On Wed, Apr 14, 2010 at 6:31 AM, Anca Vamanu <span dir="ltr"><<a href="mailto:anca@opensips.org" target="_blank">anca@opensips.org</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Hi Antonio,<br>
<br>
You have to call b2b_init on the initial INVITE that creates the dialog.<br>
And the B2B server will know to correctly treat the REFER when it comes.<br>
That REFER message in fact will never go in the default route but in the<br>
route with the name defined in the module parameter "script_req_route"<br>
<a href="http://www.opensips.org/html/docs/modules/devel/b2b_entities.html#id227305" target="_blank">http://www.opensips.org/html/docs/modules/devel/b2b_entities.html#id227305</a>.<br>
<br>
Regards,<br>
<br>
--<br>
Anca Vamanu<br>
<a href="http://www.voice-system.ro" target="_blank">www.voice-system.ro</a><br>
<div><div></div><div><br>
<br>
<br>
<br>
<br>
Antonio Anderson Souza wrote:<br>
> Hi,<br>
><br>
> I'm creating a B2B scnarios to handle Refer request and execute the<br>
> transfer process, I'm using the Refer scenario [1] as reference, but<br>
> when the UAC sends the Refer to Opensips and the Script call the<br>
> scenario and the following error is printed in the Log:<br>
><br>
> *Apr 13 14:10:18 localhost opensips[8924]:<br>
> ERROR:b2b_entities:b2b_tm_**cback: No TO TAG found *<br>
><br>
> Follow bellow my b2b scenario [2], and the Cfg snippet [3].<br>
><br>
> [1] - <a href="http://www.opensips.org/Resources/B2buaTutorial#toc15" target="_blank">http://www.opensips.org/Resources/B2buaTutorial#toc15</a><br>
><br>
> [2] - B2B Scenario:<br>
> <?xml version="1.0"?><br>
> <scenario id="b2b-refer" name="Handle refer at server" param="0"<br>
> type="script"><br>
> <init><br>
> <bridge><br>
> <server><br>
> <id>server1</id><br>
> </server><br>
> <client><br>
> <id>client1</id><br>
> <type>message</type><br>
> <destination><br>
> <value type="header">Refer-To</value><br>
> </destination><br>
> </client><br>
> </bridge><br>
> </init><br>
><br>
> <rules><br>
> <request><br>
> <refer><br>
> <rule id="1"><br>
> <action><br>
> <send_reply><br>
> <code>202</code><br>
> <reason>Accepted</reason><br>
> </send_reply><br>
> <end_dialog_leg/><br>
> <bridge><br>
> <client><br>
> <peer/><br>
> </client><br>
> <client><br>
> <id>client2</id><br>
> <destination><br>
> <value type="header">Refer-To</value><br>
> </destination><br>
> </client><br>
> </bridge><br>
> </action><br>
> </rule><br>
> </refer><br>
> </request><br>
> </rules><br>
> </scenario><br>
><br>
><br>
><br>
> [3] - Cfg snippet<br>
><br>
> if (has_totag()) {<br>
> # sequential request withing a dialog should<br>
> # take the path determined by record-routing<br>
> if (loose_route()) {<br>
> if (is_method("BYE")) {<br>
><br>
> setflag(1); # do accounting ...<br>
> setflag(3); # ... even if the<br>
> transaction fails<br>
> } else if (is_method("INVITE")) {<br>
> # even if in most of the cases is<br>
> useless, do RR for<br>
> # re-INVITEs alos, as some buggy<br>
> clients do change route set<br>
> # during the dialog.<br>
> record_route();<br>
> } else if (is_method("REFER")) {<br>
> xlog("L_ERR",<br>
> "Refer received the b2b<br>
> scenario will be triggered [$fu/$tu/$ru/$ci]");<br>
> # Start B2B Script to handle the<br>
> transference<br>
> *b2b_init_request("b2b-refer");*<br>
> xlog("L_ERR",<br>
> "Refer processed by the b2b<br>
> scenario [$fu/$tu/$ru/$ci]");<br>
> exit;<br>
><br>
><br>
> Does anybody have some idea to help me?<br>
><br>
> Best regards,<br>
><br>
> Antonio Anderson Souza<br>
> Voice Technology<br>
> <a href="http://www.antonioams.com" target="_blank">http://www.antonioams.com</a><br>
</div></div>> ------------------------------------------------------------------------<br>
><br>
> _______________________________________________<br>
> Users mailing list<br>
> <a href="mailto:Users@lists.opensips.org" target="_blank">Users@lists.opensips.org</a><br>
> <a href="http://lists.opensips.org/cgi-bin/mailman/listinfo/users" target="_blank">http://lists.opensips.org/cgi-bin/mailman/listinfo/users</a><br>
><br>
<br>
_______________________________________________<br>
Users mailing list<br>
<a href="mailto:Users@lists.opensips.org" target="_blank">Users@lists.opensips.org</a><br>
<a href="http://lists.opensips.org/cgi-bin/mailman/listinfo/users" target="_blank">http://lists.opensips.org/cgi-bin/mailman/listinfo/users</a><br>
</blockquote></div><br>
</div></div></blockquote></div><br>