What are the different types of SIP server?


This short guide is for our more technical readers who would like to understand more about the different classes of sip server that are found in VoIP networks today. There are many different types of SIP server and often the actual products we find in use do overlap with other roles and have features from more than one type of server. However, for the purposes of this tutorial, we shall deal with each type of SIP server as a distinct entity.

A SIP Server is not the same thing as a User Agent Server

Before we get started, there's one problem that always seems to trip up people new to the SIP stack and I want to clear this up first. Beginners often conflate a SIP Proxy Server with a User Agent Server. It can take a while to get this idea, but in every SIP communication there is a Request and a Response. The User Agent making the request is called the User Agent Client and the User Agent receiving the request is called the User Agent Server. This happens in every SIP communication, even between two SIP Proxies, and has nothing to do with whether they are a SIP phone, a SIP Proxy, a B2BUA or any other kind of SIP device on a network. The diagram below will hopefully make this a bit clearer.

Diagram of the request-response cycle between User Agent Client and User Agent Server
Diagram of the request-response cycle between a UAC and UAS

What can be seen here is SIP Proxy Server A forwarding a packet on to SIP Proxy Server B. Despite both of the entities in this diagram being SIP Servers, for this particular transaction Proxy A is in the role of User Agent Client (it is forwarding a request) and Proxy B is in the role of User Agent Server (it is forwarding on a response).

The SIP Proxy Server

If you have read about SIP servers at all, then you are bound to have come across the term "SIP Proxy". So what does a SIP Proxy do?

The basic function of a SIP Proxy Server is to receive requests from User Agents and other SIP Proxies and to forward them on to the correct destination. The proxy server may also perform a range of other useful functions as part of a SIP network, such as modifying headers to improve things like routing and security or to aid onward billing processes. However it's important to note that a SIP Proxy Server does not handle any media streams itself and does not inspect message bodies - it's concerned purely with a SIP packet's headers, as defined in RFC3261.

What are the different types of SIP proxy?

The main classification of SIP proxy servers is between stateless and stateful SIP proxies, but what is the difference between stateful and stateless proxy? We'll present a couple of definitions below.

Stateless proxy

A stateless proxy is the most basic type of proxy. It knows nothing about the overall state of a call and just processes each individual SIP packet in isolation. After any rules have been applied and the packet has been forwarded on or replied to, then no state is retained. Despite this making stateless proxies less versatile than stateful proxies (which we'll come to next) they are very fast and can process large volumes of traffic with minimal overhead.

Transaction stateful proxy

By contrast a stateful proxy does store and maintain state. The most common type of stateful proxy is the transaction stateful proxy. It does hold the state about each transaction but only for the pending request. Since it is not limiting itself to processing only one isolated packet at a time, it is able to implement features such as retransmission of packets that time out or more advanced routing plans such as call forking.

What open source SIP Proxy servers are there for Linux?

There are many popular open source SIP proxy servers for Linux if you want to try installing and running a SIP proxy for yourself. However, you should be warned that all of these servers need quite a lot of expert configuration in order to be used in a commercial telephony environment. If you just need to get up and running with a SIP trunk quickly, then you might want to purchase a SIP trunk solution from us. For those brave souls determined to persevere, here are a few great projects to get you started:

Back-To-Back User Agent (B2BUA)

The other main type of SIP Server that you're likely to come across in the enterprise is the Back To Back User Agent - more commonly referred to as a B2BUA. A B2BUA receives requests much like a proxy, but has a much broader remit. Crucially, a B2BUA does manipulate message bodies which contain data about the media for the session. In fact most B2BUAs actually process and manipulate the media streams themselves as well, enabling them to stitch together multiple streams into a single conference call or implement call recording and whisper coaching facilities. There are two main types of B2BUA that you're likely to encounter in the enterprise - the SBC and the PBX.

Session Border Controller (SBC)

The Session Border Controller or SBC is a specialised form of B2BUA that is used to provide one or more of the following types of features:

  • Topology hiding - hiding internal network topology
  • Traffic management - codec and media type manipulation
  • Maintaining NAT - helping to keep UDP mapping alive
  • Access control - authorising access to resources
  • Protocol repair - fixing known issues with device implementations of SIP standards
  • Media encryption - for example SRTP encryption outside of the network

Private Branch Exchange (PBX)

You may know the term PBX (or historically Private Branch Exchange) by a range of other terms such as Cloud PBX or Hosted PBX. These are business telephone systems deployed commonly in businesses to help manage telephone communication with their customers. You can learn more about our Cloud PBX solution here or if you're unclear on the difference between a PBX and a SIP Trunk, we have a article on this topic here.

B2BUA vs Proxy

So what is the difference between a B2BUA and a Proxy? In essence it comes down to the parts of the call that the different servers will manipulate. A Proxy is limited to only altering SIP headers, and even then only in accordance with RFC3261, whereas a B2BUA can alter any part of the packet, body included, as well as set up and manipulate various media streams.

Whilst B2BUAs are powerful, some people are critical of them because they break the end to end nature the SIP protocol and also introduce a single point of failure into a network. Additionally, because media is being processed and relayed by the B2BUA, rather than just between two end devices, the B2BUA can often introduce a source of latency and packet loss reducing call quality for end users.

What open source B2BUA servers are there for Linux?

The most famous Linux SIP server, which also happens to be a B2BUA PBX, is probably the Asterisk server. Even people who know very little about SIP have often heard of Asterisk. It's a powerful application and has a relatively gentle learning curve. It's a great learning tool and we recommend it to all you SIP hackers out there!

An alternative Linux PBX that has gained considerable traction in recent years is FreeSWITCH. It was deisgned almost as a response to Asterisk's shortcomings - see here - and we would definitely recommend it to anyone that is getting serious about

Of course if you just want to get up and running quickly with a Cloud PBX solution and minimal fuss, then you really should check out our own offering. Happy hacking!


What we provide

Orbtalk specialise in SIP and VoIP solutions for business and are unique in this market space due to our global reach. This allows us to offer SIP Trunking and Cloud Phone Systems to organisations across the globe for single and multi-sited companies. Our global presence also means that we have one of the largest offerings of international numbers available from over 8000 destinations globally.

Request a Call Back
Shop
Call us on 0800 101 7000