Hands on with SipToSis SIP / Skype gateway

I’ve known about SipToSis for quite a while but I’ve never worked up the energy to experiment with it.  I finally thought it was about time to do so.

When I first considered all the moving pieces to getting it working, I gave myself about a 25% chance of success. To make it even more challenging, I decided to try to set it up on an Ubuntu Linux VM running under VirtualBox on Mac OS X.

Well, to my pleasant surprise, the whole thing went swimmingly well. I followed the excellent SipToSis Linux Tips documentation on the SipToSis site and it all went smoothly. The first trick is to find a static version 2.1.0.81 download of Skype for Linux – to ensure compatibility with SipToSis. (I can’t put a link here because it moves around and I don’t think anyone is allowed to host it officially – you have to get Skype from Skype’s own website.)

Once the proper version of Skype is installed, it’s just a matter of setting it up to use the snd-dummy fake sound drivers and getting SipToSis installed and configured.

The Skype wire protocol is not open nor documented, so one cannot simply connect to Skype directly via the network from a third-party program. Third party apps can, however, interact with the running Skype (binary) process on the same machine via an inter-process communications API.  So to use SipToSis, you first start the normal Skype application on the machine and then start the SipToSis application (on the same machine) – SipToSis then connects to the Skype application via the inter-process communications API (on the same machine) to manage calls on the Skype side via the Skype App, while speaking the open-standard SIP protocol on the other side directly.

In this basic configuration, there is one instance of Skype running, with one Skype username, which means it’s basically a one-channel gateway, one call at time. The call flow for a call from SIP to a Skype user looks like this:

SipToSis SIP to Skype Call Flow

SipToSis - SIP to Skype Call Flow

Note that SipToSis and Skype (representing the running Skype App) are shown inside one box because they are on the same machine, not connected over the network. The arrows inside that box, between SipToSis and the Skype App, represents Skype API inter-process communication – not network traffic. The other arrows in the diagram, the arrows between boxes, represent network traffic flows,where those elements could be on the same machine, or on a separate machine across the room or miles way. The Skype user SkypeUser will see an inbound call from the user that was used to sign in with the Skype instance that SipToSis is attached to. All calls will appear to originate from the same Skype user in this simple single-channel setup.

The SipToSis app talks SIP protocol directly on one side and uses the Skype App on the other side as a “black box” to speak the proprietary, undocumented, Skype protocol.

As shown above, I have SipToSis registering to a SIP proxy, where I can send calls from SIP to Skype via SipToSis – in this case, I have speed-dial codes that I dial from a plain handset that place Skype calls to specific Skype users, but depending on your SIP proxy/PBX capability (and your skills) you could setup click-dial or SIP uris, perhaps something like sip:skype-{username}@mypbx.com that ring through to the specified user on Skype.

Inbound calls from Skype work just the opposite of the diagram above, where SipToSis is configured to forward inbound calls arriving from Skype to a specified SIP address (if you’re connecting to Asterisk, that means an extension on the PBX).

As mentioned previously, my setup has just a single instance of Skype running and, therefore, provides only one Skype gateway channel, supporting just one Skype-to-SIP or SIP-to-Skype call at a time.  The SipToSis website has documentation about running multiple SipToSis and multiple Skype instances and even chaining multiple Skype accounts so you can advertise a single Skype Userid and still take multiple incoming Skype calls. Based on my experience with SipToSis so far, I have no doubt this stuff actually works.  However, it’s way more than I want to mess with – and Skype is a pretty heavy, resource intensive app – you would want to have a pretty beefy machine to run multiple instances of it. The SipToSis site has some information on performance on various hardware and OSes running multiple Skype users.

Overall, SipToSis is quite cool.  Skype charges $6.95 per month per channel for a SIP PBX interface that only allows inbound calls (from Skype) and calls from the PBX to SkypeOut (paid calls) – it does not support calls from the SIP PBX to Skype users, as SipToSis does.  Why Skype still doesn’t offer (preferably FREE) SIP support after all these years is just sad, but it’s nice to see third-parties like the SipToSis folks putting together practical solutions like this. The fact that it is cross-platform, and runs on Linux (and even under a VirtualBox VM), is very impressive and greatly improves the server-friendliness and cloud-based friendliness of SipToSis.

SipToSis is not quite for the mainstream, but it does work, and if one follows their excellent documentation, it’s not that hard to setup (assuming you already have the SIP side in place, or why would you want SipToSis in the first place).  If you already have a machine available, why not run SipToSis rather than pay Skype $6.95 per month for the same thing (whether you use it or not) – plus, if you want to call Skype users from SIP, SipToSis will do that, where Skype’s own product won’t.

A few notes:

  • Since you must have Skype running to use SipToSis, and Skype is a GUI app, you need X Windows setup on the machine where you want to use SipToSis. This was not a problem for my simple test case, but it could be an issue on a real server setup running in a data center. The SipToSis docs talk about running Xvfb in the “background” but I didn’t test that trick.
  • I had to remove the pulseaudio drivers on my Ubuntu machine to get this working
  • Because I wanted to test it on a lightweight setup, I only gave the VM 512MB of RAM – and it works – impressive
  • SipToSis needs Java – I used Java 6.

5 comments for “Hands on with SipToSis SIP / Skype gateway

  1. Could you create an app that allowed skype to be configured as a sip gateway for Fring? Either on a normal iPhone 4 or in a jailbroken one?
    Cheers

  2. Without removing your Ubuntu pulseaudio, you can also try this Skype to Sip gateway. Though the sw has not been updated for a while, it still should function well under Ubuntu, pulse audio

  3. I’m not sure if a Windows based Skype to SIP would interest you, but, the 3CX PBX with the addition of the Skype gateway, when run on the same machine, allows calls to pass between the two. Both downloads are free and 3CX has a small free version available. It works too.

  4. Thanks. The site says Skype2sip.no-ip.org i will be free for a limited time only.

    One concern I have aboutit is don’t I have to submit both my SIP and Skype passwords to the site? That seems risky.

Comments are closed.