<div dir="ltr">Yes, FreeSWITCH supports webSockets natively, but if you&#39;re setting up a cluster of servers then it helps to have a proxy to act as a SIP registration endpoint.  We also have some Asterisk servers handling legacy clients, and OpenSIPS acts as a proxy for them as well.<div>

<br></div><div>James</div></div><div class="gmail_extra"><br clear="all"><div><div dir="ltr"><div><br></div><div>James<br></div><div><br><div><i><b>&quot;Every Call, Every Time!&quot;</b></i></div><div><br></div><div><h4 style="font-family:Helvetica,Arial,sans-serif;font-size:14px;color:#111;padding:0px;margin:0 0 8px">

How did I do?</h4><p style="padding:0px;margin:0 0 8px"><a href="https://secure.teamhively.com/welcome/rate/735/3" target="_blank"><img width="41" height="45" style="border:none;font-size:9px;text-decoration:none;margin-right:15px;font-weight:bold;color:#5b723f" alt="Happy" src="https://secure.teamhively.com/images/icon-happy_45.png"></a><a href="https://secure.teamhively.com/welcome/rate/735/2" target="_blank"><img width="41" height="45" style="border:none;font-size:9px;text-decoration:none;margin-right:15px;font-weight:bold;color:#0e88b6" alt="Satisfied" src="https://secure.teamhively.com/images/icon-satisfied_45.png"></a><a href="https://secure.teamhively.com/welcome/rate/735/1" target="_blank"><img width="41" height="45" style="border:none;font-size:9px;text-decoration:none;font-weight:bold;color:#e2644f" alt="Unhappy" src="https://secure.teamhively.com/images/icon-unhappy_45.png"></a></p>

<p style="padding:0px;margin:0 0 8px"><a href="https://secure.teamhively.com/welcome/rate/735" style="font-family:Helvetica,Arial,sans-serif;font-size:12px;font-weight:bold;color:rgb(88,169,210)" target="_blank">Click on a face to provide feedback on my performance!</a></p>

</div><div><br></div><div>Synclio Extension:<i>  110627</i></div><div>Phone: <i> 866-707-4590</i></div><div>Skype: <i>No!</i> <i>Call me on Synclio! :)</i></div></div></div></div>
<br><br><div class="gmail_quote">On Mon, Sep 30, 2013 at 5:19 AM, Michael Jerris <span dir="ltr">&lt;<a href="mailto:mike@jerris.com" target="_blank">mike@jerris.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">

<div style="word-wrap:break-word">Were you aware that FreeSWITCH also supports websockets natively?<div><div class="h5"><div><br><div><div>On Sep 29, 2013, at 1:01 PM, James Mortensen &lt;<a href="mailto:james.mortensen@synclio.com" target="_blank">james.mortensen@synclio.com</a>&gt; wrote:</div>

<br><blockquote type="cite"><div dir="ltr">Hi Kristian, <div><br></div><div>No, I wasn&#39;t aware <span style="color:rgb(102,102,102);font-family:&#39;Trebuchet MS&#39;,sans-serif,Verdana,Arial;font-size:13px;line-height:21.578125px">OpenSIPS</span> handled WebSockets. Looks like it&#39;s even been supported since v1.9, which is the one we&#39;re using.</div>



<div><br></div><div>This gives us more to think about.  Thank you!</div><div><br></div><div class="gmail_extra"><div><div dir="ltr"><div><br></div><div>James<br></div><div><br><div><br></div></div></div></div><br><div class="gmail_quote">



On Sat, Sep 28, 2013 at 4:22 PM, Kristian Kielhofner <span dir="ltr">&lt;<a href="mailto:kris@kriskinc.com" target="_blank">kris@kriskinc.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">



I&#39;m glad it worked for you.<div><br></div><div>Are you aware that Opensips supports SIP over websockets and secure websockets <span></span>natively?<div><div><br><br>On Saturday, September 28, 2013, James Mortensen  wrote:<br>



<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div dir="ltr">Hi Kristian,<div><br></div><div>You&#39;re right, what I want is a WebRTC SDP, which FreeSWITCH is clearly capable of generating as it does this with the default configuration by default if port 5066 is enabled for the ws-binding parameter.  </div>






<div><br></div><div>To answer your question, OverSIP sits in front of Opensips between the Chrome client and Opensips.  Chrome can only register with a SIP endpoint using websockets, so OverSIP listens on a TCP/WS port and passes the SIP messages to Opensips.</div>






<div><br></div><div><a href="http://BANDWIDTH.com" target="_blank">BANDWIDTH.com</a> --udp--&gt;  FreeSWITCH -udp--&gt;  Opensips -udp--&gt; OverSIP --ws--&gt; Chrome WebRTC client.</div><div><br></div><div>It looks like what I was missing was the &lt;action application=&quot;export&quot; data=&quot;media_webrtc=true&quot;/&gt; and using application export instead of set.  I was able to get an inbound call routed to my Chrome client, answer it, and experience two way audio.</div>






<div><br></div><div><br></div><div>Thanks again! :)</div><div><br></div><div class="gmail_extra"><div><div dir="ltr"><div><br></div><div>James<br></div><div><br><div><br></div></div></div></div><br><div>

On Sat, Sep 28, 2013 at 12:46 PM, Kristian Kielhofner <span dir="ltr">&lt;<a>kris@kriskinc.com</a>&gt;</span> wrote:<br><blockquote style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">

James,<br>
<br>
  There&#39;s quite a bit of detail omitted here but a few points:<br>
<br>
- avpf=yes on your gateway definition isn&#39;t doing anything.<br>
- Have you tried exporting media_webrtc=true before bridging back to Opensips?<br>
- Try exporting the actual variables, not including variable_ :<br>
<div><br>
&lt;extension name=&quot;<a href="http://bandwidth.com/" target="_blank">bandwidth.com</a> inbound bridge&quot;&gt;<br>
    &lt;condition field=&quot;destination_number&quot; expression=&quot;^\+1(5035551212)$&quot;&gt;<br>
</div>       &lt;action application=&quot;answer&quot; /&gt; &lt;!-- This probably shouldn&#39;t be<br>
here either --&gt;<br>
       &lt;action application=&quot;export&quot; data=&quot;sip_auth_username=11234&quot;/&gt;<br>
       &lt;action application=&quot;export&quot; data=&quot;sip_auth_password=password&quot;/&gt;<br>
       &lt;action application=&quot;export&quot; data=&quot;media_webrtc=true&quot;/&gt;<br>
<div>       &lt;action application=&quot;bridge&quot;<br>
data=&quot;<a href="mailto:sofia/external/ws-Opensips/11234@54.X.X.75" target="_blank">sofia/external/ws-Opensips/11234@54.X.X.75</a>&quot;/&gt;<br>
    &lt;/condition&gt;<br>
  &lt;/extension&gt;<br>
<br>
</div>- While you do want an &quot;SAVPF INVITE&quot; you really want a WebRTC SDP,<br>
which includes much much more than just SAVPF.<br>
- You&#39;ll probably want to do all other sorts of codec manipulation,<br>
fixups, etc when bridging between typical SIP endpoints and WebRTC<br>
endpoints.  Look into late negotiation and every codec<br>
variable/setting you can find.<br>
- You may want to re-consider the interaction and authentication<br>
between OpenSIPS and FreeSWITCH.<br>
<br>
  Also, what are you using OverSIP for in this scenario?<br>
<div><br>
<br>
On Fri, Sep 27, 2013 at 8:26 PM, James Mortensen<br>
&lt;<a>james.mortensen@synclio.com</a>&gt; wrote:<br>
&gt; Hello,<br>
&gt;<br>
&gt; I have a <a href="http://bandwidth.com/" target="_blank">bandwidth.com</a> number pointed to opensips, and a WebRTC peer<br>
&gt; registered with Opensips.  I&#39;m trying to dial the 10 digit number from a<br>
&gt; cell phone and connect the call through FreeSWITCH to the Chrome WebRTC<br>
&gt; client.<br>
&gt;<br>
&gt;<br>
&gt; I defined opensips as a gateway, in the external profile:<br>
&gt;<br>
&gt; &lt;include&gt;<br>
&gt;    &lt;gateway name=&quot;ws-Opensips&quot;&gt;<br>
&gt;      &lt;!-- &lt;param name=&quot;from-user&quot; value=&quot;fromuser&quot;/&gt; --&gt;<br>
&gt;      &lt;param name=&quot;from-domain&quot; value=&quot;54.X.X.75&quot;/&gt;<br>
&gt;      &lt;param name=&quot;proxy&quot; value=&quot;54.X.X.75&quot;/&gt;<br>
&gt;      &lt;param name=&quot;expire-seconds&quot; value=&quot;600&quot;/&gt;<br>
&gt;      &lt;param name=&quot;register&quot; value=&quot;false&quot;/&gt;<br>
&gt;      &lt;param name=&quot;retry_seconds&quot; value=&quot;30&quot;/&gt;<br>
&gt;      &lt;param name=&quot;extension&quot; value=&quot;18257773456&quot;/&gt;<br>
&gt;      &lt;param name=&quot;context&quot; value=&quot;public&quot;/&gt;<br>
&gt;      &lt;param name=&quot;avpf&quot; value=&quot;yes&quot;/&gt;<br>
&gt;      &lt;param name=&quot;username&quot; value=&quot;11234&quot;/&gt;<br>
&gt;      &lt;param name=&quot;password&quot; value=&quot;password&quot;/&gt;<br>
&gt;    &lt;/gateway&gt;<br>
&gt; &lt;/include&gt;<br>
&gt;<br>
&gt;<br>
&gt; In the public dialplan context, I added in a condition to catch the INVITE<br>
&gt; coming in from opensips and pass it to a context I&#39;ve called<br>
&gt; &quot;default-inbound&quot;. See the second condition:<br>
&gt;<br>
&gt;  &lt;extension name=&quot;from_opensips&quot;&gt;<br>
&gt;     &lt;condition field=&quot;network_addr&quot; expression=&quot;^54\.X\.X\.75$&quot;<br>
&gt; break=&quot;never&quot;&gt; &lt;!--CUSTOMIZE--&gt;<br>
&gt;       &lt;action application=&quot;transfer&quot; data=&quot;${destination_number} XML<br>
&gt; default&quot;/&gt;<br>
&gt;     &lt;/condition&gt;<br>
&gt;     &lt;condition field=&quot;network_addr&quot; expression=&quot;^54\.X\.X\.111$&quot;&gt;<br>
&gt; &lt;!--CUSTOMIZE Use a third context here --&gt;<br>
&gt;       &lt;action application=&quot;transfer&quot; data=&quot;${destination_number} XML<br>
&gt; default-inbound&quot;/&gt;<br>
&gt;     &lt;/condition&gt;<br>
&gt;   &lt;/extension&gt;<br>
&gt;<br>
&gt;<br>
&gt; Then, in the default-inbound context, I match the dialed number, answer the<br>
&gt; call leg from the PSTN, and then try to transfer back through opensips to<br>
&gt; oversip and to Chrome.  The problem is that I either end up sending back AVP<br>
&gt; INVITES, or Opensips refuses to authenticate the user.<br>
&gt;<br>
&gt; &lt;extension name=&quot;<a href="http://bandwidth.com/" target="_blank"></a></div></blockquote></div></div></div>
</blockquote></div></div></div><span><font color="#888888"><br><br>-- <br>Sent from mobile device<br>
</font></span><br>_________________________________________________________________________<br>
Professional FreeSWITCH Consulting Services:<br>
<a href="mailto:consulting@freeswitch.org" target="_blank">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" target="_blank">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></div></div>
_________________________________________________________________________<br>Professional FreeSWITCH Consulting Services:<br><a href="mailto:consulting@freeswitch.org" target="_blank">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" target="_blank">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></blockquote></div><br></div></div></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></div>