Without throwing the provider under the bus it might be good to document this as a "known issue with a workaround." We would just need to add a provider page and link it here:<br><a href="http://wiki.freeswitch.org/wiki/SIP_Provider_Examples">http://wiki.freeswitch.org/wiki/SIP_Provider_Examples</a><br>
<br>Thanks!<br>-MC<br><br><div class="gmail_quote">On Fri, Sep 14, 2012 at 4:46 AM, Rob Moore <span dir="ltr"><<a href="mailto:Rob.Moore@aeriandi.com" target="_blank">Rob.Moore@aeriandi.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div link="blue" vlink="purple" lang="EN-GB">
<div>
<p class="MsoNormal"><span style="color:#1f497d">Hi Everyone,<u></u><u></u></span></p>
<p class="MsoNormal"><span style="color:#1f497d"><u></u> <u></u></span></p>
<p class="MsoNormal"><span style="color:#1f497d">For those who are interested I found a way around this issue. I’m not sure if this is the correct way to produce this result but it worked.<u></u><u></u></span></p>
<p class="MsoNormal"><span style="color:#1f497d"><u></u> <u></u></span></p>
<p class="MsoNormal"><span style="color:#1f497d">The problem I had was that I could set the Freephone number I wished to present but the P asserted ID would overwrite this with the other standard number I was attempting to send.
<u></u><u></u></span></p>
<p class="MsoNormal"><span style="color:#1f497d"><u></u> <u></u></span></p>
<p class="MsoNormal"><span style="color:#1f497d">So to resolve the issue I had to disable all CID, use effective_caller_id_number to present my Freephone number (this adds the number to your from header) then I used sip_h_ to add the P-Asserted-Identity manually.<u></u><u></u></span></p>
<p class="MsoNormal"><span style="color:#1f497d"><u></u> <u></u></span></p>
<p class="MsoNormal"><span style="color:#1f497d"> <action application="set" data="effective_caller_id_number=<a href="tel:%2B448000000262" value="+448000000262" target="_blank">+448000000262</a>"/><u></u><u></u></span></p>
<p class="MsoNormal"><span style="color:#1f497d"> <action application="export" data="sip_cid_type=none"/><u></u><u></u></span></p>
<p class="MsoNormal"><span style="color:#1f497d"> <action application="export" data="sip_h_P-Asserted-Identity= <sip:<a href="tel:%2B445600000262" value="+445600000262" target="_blank">+445600000262</a>@<a href="http://fixsipbizzle.org" target="_blank">fixsipbizzle.org</a>> "/><u></u><u></u></span></p>
<p class="MsoNormal"><span style="color:#1f497d"><u></u> <u></u></span></p>
<p class="MsoNormal"><span style="color:#1f497d">Hope this helps anyone else who ever has to provide this unusual setup.<u></u><u></u></span></p>
<p class="MsoNormal"><span style="color:#1f497d"><u></u> <u></u></span></p>
<div>
<div style="border:none;border-top:solid #b5c4df 1.0pt;padding:3.0pt 0cm 0cm 0cm">
<p class="MsoNormal"><b><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif"" lang="EN-US">From:</span></b><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif"" lang="EN-US"> <a href="mailto:freeswitch-users-bounces@lists.freeswitch.org" target="_blank">freeswitch-users-bounces@lists.freeswitch.org</a>
[mailto:<a href="mailto:freeswitch-users-bounces@lists.freeswitch.org" target="_blank">freeswitch-users-bounces@lists.freeswitch.org</a>] <b>On Behalf Of </b>Rob Moore<br>
<b>Sent:</b> 11 September 2012 19:11<br>
<b>To:</b> <a href="mailto:freeswitch-users@lists.freeswitch.org" target="_blank">freeswitch-users@lists.freeswitch.org</a><br>
<b>Subject:</b> [Freeswitch-users] Altering From Header in SIP Invite<u></u><u></u></span></p>
</div>
</div>
<p class="MsoNormal"><u></u> <u></u></p>
<p class="MsoNormal" style="text-autospace:none"><span style>Hi All,<u></u><u></u></span></p>
<p class="MsoNormal" style="text-autospace:none"><span style><u></u> <u></u></span></p>
<p class="MsoNormal" style="text-autospace:none"><span style>I’m having a little trouble with ‘presentation numbers’ with a new provider I’m in IOT with this week.<u></u><u></u></span></p>
<p class="MsoNormal" style="text-autospace:none"><span style><u></u> <u></u></span></p>
<p class="MsoNormal" style="text-autospace:none"><span style>I’m trying to recreate the following Invite as the calls pass through our dialplan to this provider but there are issues with trying to get a different CLI
into the From and P-Asserted-Identity headers.<u></u><u></u></span></p>
<p class="MsoNormal" style="text-autospace:none"><span style><u></u> <u></u></span></p>
<p class="MsoNormal" style="text-autospace:none"><span style>When presenting a Freephone number (for example) we need to still present the regular number that would be used by this extension in the P-Asserted-Identity
whilst passing the number we wish to have presented in the From header.<u></u><u></u></span></p>
<p class="MsoNormal" style="text-autospace:none"><span style><u></u> <u></u></span></p>
<p class="MsoNormal" style="text-autospace:none"><span style>Currently we are not using Gateways so we cannot resort to using <param name="caller-id-in-from" value="true"/> (although I expect this won’t do what we need
in this case) so I’ve looked at altering the channel variables sip_from_user,sip_full_from and sip_full_uri using set and export dial plan apps but none of these seem to have any effect so I guess these variables must be read only.
<u></u><u></u></span></p>
<p class="MsoNormal" style="text-autospace:none"><span style><u></u> <u></u></span></p>
<p class="MsoNormal" style="text-autospace:none"><span style>I’m sure this must be simple, but can’t for the life of me work out what I need to do.
<u></u><u></u></span></p>
<p class="MsoNormal" style="text-autospace:none"><span style><u></u> <u></u></span></p>
<p class="MsoNormal" style="text-autospace:none"><span style>Below is an extract from an example header from the provider I am trying to recreate, I’ve also added a copy of the Dialplan extension I am using to test.<u></u><u></u></span></p>
<p class="MsoNormal" style="text-autospace:none"><span style>If someone can tell me what I’m getting wrong I would really appreciate it.<u></u><u></u></span></p>
<p class="MsoNormal" style="text-autospace:none"><span style><u></u> <u></u></span></p>
<p class="MsoNormal" style="text-autospace:none"><span style>Thanks<u></u><u></u></span></p>
<p class="MsoNormal" style="text-autospace:none"><span style><u></u> <u></u></span></p>
<p class="MsoNormal" style="text-autospace:none"><span style>Rob<u></u><u></u></span></p>
<p class="MsoNormal" style="text-autospace:none"><span style><u></u> <u></u></span></p>
<p class="MsoNormal"><b><span style="font-size:8.5pt;font-family:"Courier New";color:#1e508a"><u></u> <u></u></span></b></p>
<p class="MsoNormal"><b><span style="font-size:8.5pt;font-family:"Courier New";color:#1e508a">INVITE</span></b><span style="font-size:8.5pt;font-family:"Courier New"">
<span style="color:gray"><a>sip:<b>+445600005262@primarysip.barfoo.com;user=phone</b></a></span>
<span style="color:gray">SIP/2.0</span><u></u><u></u></span></p>
<p class="MsoNormal"><b><span style="font-size:8.5pt;font-family:"Courier New";color:#666666">Max-Forwards:</span></b><span style="font-size:8.5pt;font-family:"Courier New"">
<span style="color:#666666">69</span><u></u><u></u></span></p>
<p class="MsoNormal"><b><span style="font-size:8.5pt;font-family:"Courier New";color:#666666">Session-Expires:</span></b><span style="font-size:8.5pt;font-family:"Courier New"">
<span style="color:#666666">3600;refresher=uac</span><u></u><u></u></span></p>
<p class="MsoNormal"><b><span style="font-size:8.5pt;font-family:"Courier New";color:#666666">Min-SE:</span></b><span style="font-size:8.5pt;font-family:"Courier New"">
<span style="color:#666666">600</span><u></u><u></u></span></p>
<p class="MsoNormal"><b><span style="font-size:8.5pt;font-family:"Courier New";color:#666666">Supported:</span></b><span style="font-size:8.5pt;font-family:"Courier New"">
<span style="color:#666666">timer, 100rel</span><u></u><u></u></span></p>
<p class="MsoNormal"><b><span style="font-size:8.5pt;font-family:"Courier New"">To:</span></b><span style="font-size:8.5pt;font-family:"Courier New"">
<span style="color:#666666"><a href="tel:%2B445600000262" value="+445600000262" target="_blank">+445600000262</a> </span><b><span style="color:chocolate"><<a>sip:+445600005262@primarysip.barfoo.com;user=phone</a>></span></b><u></u><u></u></span></p>
<p class="MsoNormal"><b><span style="font-size:8.5pt;font-family:"Courier New"">From:</span></b><span style="font-size:8.5pt;font-family:"Courier New"">
<b><span style="color:chocolate"><<a>sip:+448000655262@uk.foo.bar.2.net;user=phone</a>></span></b><span style="color:#666666">;tag=</span><span style>12544</span><u></u><u></u></span></p>
<p class="MsoNormal"><b><span style="font-size:8.5pt;font-family:"Courier New";color:#666666">P-Asserted-Identity:</span></b><span style="font-size:8.5pt;font-family:"Courier New"">
<span style="color:#666666"><<a>sip:+445600655262@uk.sdin.bt.net</a>></span><u></u><u></u></span></p>
<p class="MsoNormal"><b><span style="font-size:8.5pt;font-family:"Courier New"">Call-ID:</span></b><span style="font-size:8.5pt;font-family:"Courier New"">
<span style><a href="mailto:1347372978-13100@mgc-uk-998.n2" target="_blank">1347372978-13100@mgc-uk-998.n2</a></span><u></u><u></u></span></p>
<p class="MsoNormal"><b><span style="font-size:8.5pt;font-family:"Courier New"">CSeq:</span></b><span style="font-size:8.5pt;font-family:"Courier New"">
<span style>1 INVITE</span><u></u><u></u></span></p>
<p class="MsoNormal"><b><span style="font-size:8.5pt;font-family:"Courier New";color:#666666">Allow:</span></b><span style="font-size:8.5pt;font-family:"Courier New"">
<span style="color:#666666">CANCEL, ACK, INVITE, BYE, OPTIONS, INFO, PRACK, UPDATE</span><u></u><u></u></span></p>
<p class="MsoNormal"><u></u> <u></u></p>
<p class="MsoNormal"><u></u> <u></u></p>
<p class="MsoNormal">DIAL Plan: (attempting <a href="tel:%2B445600655262" value="+445600655262" target="_blank">+445600655262</a> in P Asserted-Id and <a href="tel:%2B448000655262" value="+448000655262" target="_blank">+448000655262</a> in from) have commented out some things that I have tried.)<u></u><u></u></p>
<p class="MsoNormal">If you are worried about [sip_h_X-Gateway=4003:4] this is added to help our SBC forward calls to our different providers.<u></u><u></u></p>
<p class="MsoNormal"><u></u> <u></u></p>
<p class="MsoNormal"> <extension name="TC 25"><u></u><u></u></p>
<p class="MsoNormal"> <condition field="destination_number" expression="^10125$"><u></u><u></u></p>
<p class="MsoNormal"> <action application="set" data="effective_caller_id_name=_undef_"/><u></u><u></u></p>
<p class="MsoNormal"> <action application="set" data="effective_caller_id_number=<a href="tel:%2B445600005262" value="+445600005262" target="_blank">+445600005262</a> "/><u></u><u></u></p>
<p class="MsoNormal"> <action application="set" data="dtmf_type=rfc2833"/><u></u><u></u></p>
<p class="MsoNormal"> <action application="set" data="sip_cid_type=pid"/><u></u><u></u></p>
<p class="MsoNormal"> <!--<action application="export" data="<span style> sip_from_user</span> =<a href="tel:%2B448000655262" value="+448000655262" target="_blank">+448000655262</a>"/> --><u></u><u></u></p>
<p class="MsoNormal"> <!-- <action application="export" data="sip_h_from=<<a>sip:+448000655262@primarysip.barfoo.com</a>>;tag=${sip_from_tag} "/> --><u></u><u></u></p>
<p class="MsoNormal"> <!-- <action application="export" data="sip_h_P-Asserted-Identity= <a href="tel:%2B445600005262" value="+445600005262" target="_blank">+445600005262</a> <<a>sip:+445600655262@172.17.7.4</a>> "/> --><u></u><u></u></p>
<p class="MsoNormal"> <action application="info"/><u></u><u></u></p>
<p class="MsoNormal"> <action application="bridge" data="[sip_h_X-Gateway=4003:4]<a href="mailto:sofia/internal/+442920001199@pstn.tel" target="_blank">sofia/internal/+442920001199@pstn.tel</a>" />
<u></u><u></u></p>
<p class="MsoNormal"> </condition><u></u><u></u></p>
<p class="MsoNormal"> </extension> <u></u><u></u></p>
<p class="MsoNormal"><u></u> <u></u></p>
<p class="MsoNormal"><u></u> <u></u></p>
<p class="MsoNormal" style="margin-left:14.15pt"><span>Rob Moore<u></u><u></u></span></p>
<p class="MsoNormal" style="text-autospace:none"><span style="color:gray">Telephony Systems Infrastructure Manager</span><span style="font-family:"Arial","sans-serif";color:gray"><u></u><u></u></span></p>
<p class="MsoNormal"><b><span style="font-size:10.0pt;font-family:"Arial","sans-serif";color:#376092">Aeriandi<u></u><u></u></span></b></p>
<p class="MsoNormal"><span style="color:#7f7f7f">Aeriandi Ltd, Prama House, Banbury Road, Oxford, OX27HT
<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial","sans-serif";color:#7f7f7f">E:
</span><span style="font-size:10.0pt;font-family:"Arial","sans-serif""><a href="mailto:rob.moore@aeriandi.com" target="_blank">rob.moore@aeriandi.com</a><u><span style="color:#1f497d"><u></u><u></u></span></u></span></p>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial","sans-serif";color:#7f7f7f">W:
</span><span><a href="http://www.aeriandi.com/" target="_blank"><span style="font-size:10.0pt;font-family:"Arial","sans-serif"">www.aeriandi.com</span></a><br>
M: <a href="tel:%2B44%20%280%297766%20838040" value="+447766838040" target="_blank">+44 (0)7766 838040</a></span><u><span style="font-size:10.0pt;font-family:"Arial","sans-serif";color:#1f497d"><u></u><u></u></span></u></p>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial","sans-serif";color:#7f7f7f">T: +</span><span>44 (0) 845 108 0308</span><span style="font-size:10.0pt;font-family:"Arial","sans-serif";color:#1f497d"><u></u><u></u></span></p>
<p class="MsoNormal"><span><u></u> <u></u></span></p>
<p class="MsoNormal"><span><img src="cid:image001.png@01CD9264.4131A590" alt="Description: Description: Description: Description: Description: Description: Description: Description: cid:image002.png@01CC9E0C.20153A40" border="0" height="44" width="195">
<u></u><u></u></span></p>
<p class="MsoNormal"><u></u> <u></u></p>
</div>
</div>
<br>_________________________________________________________________________<br>
Professional FreeSWITCH Consulting Services:<br>
<a href="mailto:consulting@freeswitch.org">consulting@freeswitch.org</a><br>
<a href="http://www.freeswitchsolutions.com" target="_blank">http://www.freeswitchsolutions.com</a><br>
<br>
FreeSWITCH-powered IP PBX: The CudaTel Communication Server<br>
<a href="http://www.cudatel.com" target="_blank">http://www.cudatel.com</a><br>
<br>
Official FreeSWITCH Sites<br>
<a href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a><br>
<a href="http://wiki.freeswitch.org" target="_blank">http://wiki.freeswitch.org</a><br>
<a href="http://www.cluecon.com" target="_blank">http://www.cluecon.com</a><br>
<br>
FreeSWITCH-users mailing list<br>
<a href="mailto:FreeSWITCH-users@lists.freeswitch.org">FreeSWITCH-users@lists.freeswitch.org</a><br>
<a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>
UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br>
<a href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a><br>
<br></blockquote></div><br><br clear="all"><br>-- <br>Michael S Collins<br>Twitter: @mercutioviz<br><a href="http://www.FreeSWITCH.org" target="_blank">http://www.FreeSWITCH.org</a><br><a href="http://www.ClueCon.com" target="_blank">http://www.ClueCon.com</a><br>
<a href="http://www.OSTAG.org" target="_blank">http://www.OSTAG.org</a><br><br><br>