<html>
  <head>
    <meta content="text/html; charset=utf-8" http-equiv="Content-Type">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    <tt>I checked the script you mentioned and it does not help you - it
      has only UDP (no WS), it is really basic and it does not handle
      any REGISTER stuff, which is the trickiest - see<br>
          
      <a class="moz-txt-link-freetext" href="https://blog.opensips.org/2016/12/13/how-to-proxy-sip-registrations/">https://blog.opensips.org/2016/12/13/how-to-proxy-sip-registrations/</a><br>
      or<br>
          
<a class="moz-txt-link-freetext" href="https://blog.opensips.org/2016/12/20/mid-registrar-scalable-registration-and-call-forking/">https://blog.opensips.org/2016/12/20/mid-registrar-scalable-registration-and-call-forking/</a><br>
      <br>
      Maybe you can start with handling REGISTERs - what you need (on
      top of the script from the WSS tutorial) is to add this
      uac_registrant, to have the WS extensions registered into </tt><tt>OmniPCX
      with a contact URI pointing back to OpenSIPS IP:<br>
         
      <a class="moz-txt-link-freetext" href="http://www.opensips.org/html/docs/modules/2.3.x/uac_registrant.html">http://www.opensips.org/html/docs/modules/2.3.x/uac_registrant.html</a><br>
      <br>
      Let me know if you get stuck in this first step.<br>
      <br>
      Regards,<br>
    </tt>
    <pre class="moz-signature" cols="72">Bogdan-Andrei Iancu
  OpenSIPS Founder and Developer
  <a class="moz-txt-link-freetext" href="http://www.opensips-solutions.com">http://www.opensips-solutions.com</a>

OpenSIPS Bootcamp 2017, Houston, US
  <a class="moz-txt-link-freetext" href="http://opensips.org/training/OpenSIPS_Bootcamp_2017.html">http://opensips.org/training/OpenSIPS_Bootcamp_2017.html</a>
</pre>
    <div class="moz-cite-prefix">On 06/30/2017 12:22 PM, Alex
      Megalokonomos wrote:<br>
    </div>
    <blockquote
cite="mid:CALwx21rMdbvLi_UwcnN84a94MkaY7OQmtTYLjJp4gnyUaPYM1Q@mail.gmail.com"
      type="cite">
      <div dir="ltr"><img moz-do-not-send="true" class="mailtrack-img"
          style="float:right;" alt=""
src="https://mailtrack.io/trace/mail/b5a94bde28b8363aa12da7417eeda5ea7dd7c5ff.png?u=1422671"
          height="0" width="0">Hello Bogdan,
        <div><br>
        </div>
        <div>First of all, thanks for your time.</div>
        <div><br>
        </div>
        <div>Unfortunately my SIP/OpensSIPS skills are what I've managed
          to learn in the last couple of days. I am a programmer but
          I've never had to work on SIP stuff before.</div>
        <div><br>
        </div>
        <div>Frankly to me, both solutions sound equally difficult since
          I have no idea where to start. (And to be honest, I expected
          the first to be simpler)</div>
        <div><br>
        </div>
        <div>I found this <a moz-do-not-send="true"
href="https://blog.voipxswitch.com/2015/03/27/kamailio-basic-sip-proxy-all-requests-setup/">https://blog.voipxswitch.com/2015/03/27/kamailio-basic-sip-proxy-all-requests-setup/</a>
          and tried to port the config to OpenSIPS since from what I
          understand Kamailio and OpenSIPS share a common codebase to an
          extent but was unsuccesful.<br>
        </div>
        <div><br>
        </div>
        <div>In your second scenario,  I am not interested in WS->WS
          calls so that auth part is not an issue.</div>
        <div><br>
        </div>
        <div>So I guess I need the uac_registrar, authorize by IP and
          usrloc parts.</div>
        <div><br>
        </div>
        <div>Any relevant documentation to get me started since I'm
          still not clear on what I need to change?</div>
        <div><br>
        </div>
        <div>Best regards,</div>
        <div>Alex</div>
      </div>
      <div class="gmail_extra"><br>
        <div class="gmail_quote">On Fri, Jun 30, 2017 at 11:29 AM,
          Bogdan-Andrei Iancu <span dir="ltr"><<a
              moz-do-not-send="true" href="mailto:bogdan@opensips.org"
              target="_blank"><a class="moz-txt-link-abbreviated" href="mailto:bogdan@opensips.org">bogdan@opensips.org</a></a>></span> wrote:<br>
          <blockquote class="gmail_quote" style="margin:0 0 0
            .8ex;border-left:1px #ccc solid;padding-left:1ex">
            <div bgcolor="#FFFFFF" text="#000000"> <tt>Hi Alex,<br>
                <br>
                To make a kind of WS<>UDP gateway you need a
                complete rework of the script presented in the tutorial,
                as it is a completely different SIP scenario. Not sure
                what are your SIP/OpenSIPS skills.<br>
                <br>
                But, there is a simpler alternative . Instead of a GW,
                you can make OpenSIPS as a sub-server for the WS
                extensions:<br>
                <br>
                Registration handling:<br>
                <br>
                1) WS extensions register only with OpenSIPS (as right
                now) - authentication is done by OpenSIPS<br>
                2) OpenSIPS registers the 3 extensions into </tt><tt>OmniPCX
                using the uac_registrar <br>
                <br>
                By this, we simply add the uac_registration and you
                achieve kind of decoupled 2 steps registration (with a
                minimum change in the cfg)<br>
                <br>
                <br>
                Inbound calls:<br>
                <br>
                1) </tt><tt><tt>OmniPCX will send all the calls (from
                  other extensions) for the WS extension to OpenSIPS
                  (due the registration via uac_registrar) - this is
                  default behavior , so nothing to change<br>
                  2) In OpenSIPS, when receiving calls, you need to
                  authorize (by IP) the calls from </tt></tt><tt><tt><tt><tt>OmniPCX
                      - and as the current script does, you will handle
                      them via the local opensips usrloc -> calls are
                      sent to WS extension<br>
                      <br>
                    </tt></tt></tt></tt><br>
              <tt><tt><tt><tt><tt>Outbound calls:<br>
                        <br>
                        1) when you receive a call from a WS extension,
                        you have to check if the call is for a local
                        extension (on opensips) or for an extension in </tt></tt></tt></tt></tt><tt><tt><tt><tt><tt><tt>OmniPCX<br>
                          2) if call is local (WS to WS) you will do
                          authentication for the call<br>
                          3) if the call is to be sent to </tt></tt></tt></tt></tt></tt><tt><tt><tt><tt><tt><tt><tt><tt><tt><tt><tt><tt>OmniPCX,
                                      simply send the call to  </tt></tt></tt></tt></tt></tt></tt></tt></tt></tt></tt></tt><tt><tt><tt><tt><tt><tt><tt><tt><tt><tt><tt><tt><tt><tt><tt><tt><tt><tt>OmniPCX
                                                  without auth - the
                                                  auth will be done by </tt></tt></tt></tt></tt></tt></tt></tt></tt></tt></tt></tt></tt></tt></tt></tt></tt></tt><tt><tt><tt><tt><tt><tt><tt><tt><tt><tt><tt><tt><tt><tt><tt><tt><tt><tt><tt><tt><tt><tt><tt><tt>OmniPCX
                                                          as for any
                                                          other
                                                          extension<br>
                                                          <br>
                                                          <br>
                                                          Hopefully this
                                                          will work for
                                                          you :)<br>
                                                          <br>
                                                          </tt></tt></tt></tt></tt></tt></tt></tt></tt></tt></tt></tt></tt></tt></tt></tt></tt></tt></tt></tt></tt></tt></tt>Best
                regards,<br>
              </tt><span class="">
                <pre class="m_-1652678207613874565moz-signature" cols="72">Bogdan-Andrei Iancu
  OpenSIPS Founder and Developer
  <a moz-do-not-send="true" class="m_-1652678207613874565moz-txt-link-freetext" href="http://www.opensips-solutions.com" target="_blank">http://www.opensips-solutions.<wbr>com</a>

OpenSIPS Bootcamp 2017, Houston, US
  <a moz-do-not-send="true" class="m_-1652678207613874565moz-txt-link-freetext" href="http://opensips.org/training/OpenSIPS_Bootcamp_2017.html" target="_blank">http://opensips.org/training/<wbr>OpenSIPS_Bootcamp_2017.html</a>
</pre>
    </span><div><div class="h5"><div class="m_-1652678207613874565moz-cite-prefix">On 06/29/2017 11:54 AM, Alex
      Megalokonomos wrote:

    </div>
    <blockquote type="cite">
      <div dir="ltr"><img moz-do-not-send="true" class="m_-1652678207613874565mailtrack-img" style="float:right" alt="" src="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7" height="0" width="0">Hello Bogdan,
        <div>

        </div>
        <div>Yes, a gateway from WS to UDP (as well as DTLS-SRTP to RTP
          in order for it to work) is exactly what we're looking for.</div>
        <div>

        </div>
        <div>Unfortunately our Alcatel OmniPCX call center  is a
          proprietary system that only allows for a limited number of
          SIP extensions (served from what appears to be an outdated
          customised  Kamailio 3.2.2 from what I can tell from the
          headers.</div>
        <div>

        </div>
        <div>For our normal internal office use it all works fine.</div>
        <div>

        </div>
        <div>However we have 3 customer support lines that are currently
          routed to 3 extensions via OmniPCX.</div>
        <div>

        </div>
        <div>We want to integrate these to our custom web-based CRM and
          the best way for us to do it is to use something like SIP js
          to handle and log calls, identify calling parties, bring up
          customer details etc.</div>
        <div>

        </div>
        <div>Since the kamailio version inside OmniPCX does not support
          ws/webrtc we are looking to set up Opensips in exactly the way
          you described as a gateway/proxy for everything in order to
          convert the UDP-only sip extensions to ws+ webRTC capable
          ones.</div>
        <div>

        </div>
        <div>I have used this tutorial <a moz-do-not-send="true" href="http://www.opensips.org/Documentation/Tutorials-WebSocket-2-1" target="_blank">http://www.opensips.<wbr>org/Documentation/Tutorials-<wbr>WebSocket-2-1</a>
          to get what I assume is half the work (for RTP proxying)  but
          I havent figured out the rest yet.</div>
        <div>

        </div>
        <div>Best regards,</div>
        <div>Alex</div>
      </div>
      <div class="gmail_extra">

        <div class="gmail_quote">On Thu, Jun 29, 2017 at 11:43 AM,
          Bogdan-Andrei Iancu <span dir="ltr"><<a moz-do-not-send="true" class="m_-1652678207613874565moz-txt-link-abbreviated" href="mailto:bogdan@opensips.org" target="_blank">bogdan@opensips.org</a>></span> wrote:

          <blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
            <div bgcolor="#FFFFFF" text="#000000"> <tt>Hi Alex,

                

                First, some questions regarding the desired topology:

                    1) the WS end-points should register in OpenSIPS or
                all the way into Kamailio ?

                    2) also, the calls from the WS end-points should be
                all the time sent to Kamailio ?

                

                More or less, what I'm asking is : is OpenSIPS suppose
                to act as a gateway from WS to UDP , but pass all the
                resulting traffic to Kamailio ?

                

                Regards,

              </tt>
              <pre class="m_-1652678207613874565m_-6874691586421181616moz-signature" cols="72">Bogdan-Andrei Iancu
  OpenSIPS Founder and Developer
  <a moz-do-not-send="true" class="m_-1652678207613874565m_-6874691586421181616moz-txt-link-freetext" href="http://www.opensips-solutions.com" target="_blank">http://www.opensips-solutions.<wbr>com</a>

OpenSIPS Bootcamp 2017, Houston, US
  <a moz-do-not-send="true" class="m_-1652678207613874565m_-6874691586421181616moz-txt-link-freetext" href="http://opensips.org/training/OpenSIPS_Bootcamp_2017.html" target="_blank">http://opensips.org/training/O<wbr>penSIPS_Bootcamp_2017.html</a>
</pre><div><div class="m_-1652678207613874565h5">
    <div class="m_-1652678207613874565m_-6874691586421181616moz-cite-prefix">On 06/28/2017 12:47 PM, Alex
      Megalokonomos wrote:

    </div>
    </div></div><blockquote type="cite"><div><div class="m_-1652678207613874565h5">
      <div dir="ltr"><img moz-do-not-send="true" class="m_-1652678207613874565m_-6874691586421181616mailtrack-img" style="float:right" alt="" height="0" width="0">Hello, 
        <div>

        </div>
        <div>We have the following scenario: our office call center is
          an Alcatel OmniPCX Office setup.</div>
        <div>

        </div>
        <div>This handles most of our needs and also provides 4 SIP
          extensions.</div>
        <div>

        </div>
        <div>These are provided by what appears to be a Kamailio SIP
          server v 3.2.2 (no webrtc or websockets support)</div>
        <div>

        </div>
        <div>What we would like to do is set up an OpenSIPS instance to
          handle WebRTC and proxy everything to this Kamailio SIP
          server.</div>
        <div>

        </div>
        <div>The idea is to allow a web client (using sip js or
          something similar) to register / make / receive calls as one
          of the Kamailio extensions.</div>
        <div>

        </div>
        <div>

          <div>I think half of the configuration is this : <a moz-do-not-send="true" class="m_-1652678207613874565m_-6874691586421181616moz-txt-link-freetext" href="http://www.opensips.org/Documentation/Tutorials-WebSocket-2-1" target="_blank">http://www.opensips.org/Docu<wbr>mentation/Tutorials-WebSocket-<wbr>2-1</a></div>
          <div>

          </div>
          <div>which I've already completed and indeed, clients can
            register to opensips and chat/make calls over websockets
            between them.</div>
          <div>

          </div>
          <div>How do I go about proxying registrations/invites/etc to
            the kamailio server instead?</div>
          <div>

          </div>
          <div>best regards</div>
        </div>
      </div>
      

      <fieldset class="m_-1652678207613874565m_-6874691586421181616mimeAttachmentHeader"></fieldset>
      

      </div></div><span><pre>______________________________<wbr>_________________
Users mailing list
<a moz-do-not-send="true" class="m_-1652678207613874565m_-6874691586421181616moz-txt-link-abbreviated" href="mailto:Users@lists.opensips.org" target="_blank">Users@lists.opensips.org</a>
<a moz-do-not-send="true" class="m_-1652678207613874565m_-6874691586421181616moz-txt-link-freetext" href="http://lists.opensips.org/cgi-bin/mailman/listinfo/users" target="_blank">http://lists.opensips.org/cgi-<wbr>bin/mailman/listinfo/users</a>
</pre>
    </span></blockquote>
    

  </div>

</blockquote></div>
</div>



</blockquote>
</div></div></div></blockquote></div>
</div>



</blockquote>
</body></html>