SIP in a nutshell

Components and attributes of Session Initiation Protocol

SIP in a nutshell_WellingtonPaez

SIP in a nutshell

In this post, “SIP in a Nutshell – Components and Attributes of SIP,” you will get a quick overview of the main components used to make a SIP communication possible. From User Agent Clients UACs or UAs, to UAS User Agent Servers, and last, the SIP Methods frequently use when establishing a SIP session.

Most of the VoIP apps nowadays are using, in one form or another, this protocol of SIP, which is text based running in the Application Layer of both Internet and OSI models. Because its similar to HTTP and SMTP, it is a great protocol to implement secure methods, such as end-to-end encryption link communication.

Giving the enduser the capability to interoperate with voice, video, messaging systems utilizing SRTP or the good old ‘unsecured RTP’ media streams, as well as the capability of offering secure HTTP certificates for secure communication. The most common certificates are provided by VeriSign, Entrust, and others. X.509 are the most popular certificates implemented today using the SHA1 signature algorythm. For those able to create their own certificate SIP lets you use Self-Signed Certs. Lastly on security SIP allows for SSL and TLS.

These are six components responsible for SIP communication

  • 1.- User Agents
  • 2.- Registration Servers
  • 3.- Proxy Servers
  • 4.- Redirect Servers
  • 5.- Location Servers
  • 6.- SIP Gateways

1.- User Agents

These are the endpoints and softphones available for our use. There are a variety of UAs available today. These can be downloadable freeware or license based through a SIP Server or Proxy.

2.- Registration Servers or Registrar

These servers will gather the UAs request and forward those to the Location Server. The request will contain location, user name, IP Address, etc.

3.- Proxy Servers

These are devices good to add another level of security in your network. Frequently, we implement SIP enabled Firewalls to act as a proxy, but in reality, any Proxy Server will do.

4.- Redirect Servers

For those UAs registering to multiple servers, a Redirect Sever will forward 3xx redirection responses to the UA’s Location Server.

5.- Location Servers

These devices hold the database and location info of the UAs; updated via the Registrar Service.  The Location Server can be combined with Active Directory.

6.- SIP Gateways

The function of these devices is to translate signaling to legacy equipment and vice versa.

How does SIP operates?

The processes of SIP registration and communication consist of request To and From the server or UA. These requests and responses are SIP messages associated with a response code ranging from 1xx to 6xx. We don’t need to know all of these, in fact when running traces or error messages, the UA device or soft-phone is kind enough to tell us the SIP Message or response associated with the error or failure. I have listed the six most common messages below=

INVITE – When a UA tries to call or contact another UA by inviting him/her to participate in a session.

ACK – Once the INVITE is received the UA will use the ACK to acknowledge

OPTIONS – These SIP Messages detailed the UA and Server capabilities. It sends the calling party or UA a full report of codec types, extensions, supported SIP Messages or methods, and any other features available or supported.

BYE – It indicates termination of a session. When this message is sent to the UA, the receptor replies with a 200 OK.

CANCEL – This message tells the caller to stop calling or if a session it’s in-progress, it forces the other UA to disconnect immediately by sending a ‘Request Terminated’ message.

REGISTER – This SIP request sends the server the UA domain information and location.

Other ones are= INFO, NOTIFY, REFER, UPDATE, COMET, MESSAGE, PRACK, SUBSCRIBE, SERVICE, and BENOTIFY.

References

RFC 3261 – SIP Initiation Protocol

RFC 3262 – Reliability of Provisional Responses in the Session Initiation Protocol (SIP)

 

When troubleshooting SIP sessions, which messages do you normally get?, and which messages do you find are the most common?

Please note: I reserve the right to delete comments that are offensive or off-topic.