You are on page 1of 36

Session Initiation Protocol

(SIP)

by
B Pavan Kumar
SIP based VoIP Architecture
I
N
Application
T
3pcc Services
E eMail CPL
CPL
LDAP Oracle XML
L
L
I
G SIP Proxy, Registrar
E & Redirect Servers
N
T SIP

SIP SIP
S SIP User PSTN
E Agents (UA)
R
CAS or PRI
V
I RTP
C (Media)
E 2
S Legacy PBX
Basic SIP Call-Flow
SIP UA1 SIP UA2

INVITE w/ SDP for Media Negotiation

100 Trying

180/183 Ringing w/ SDP for Media Negotiation


MEDIA

200 OK

ACK

MEDIA

BYE

200 OK
3
SIP Call Flow with Proxy Server
User Agent 1 Proxy Server User Agent 1

Register Register
OK (200) OK (200)
Invite Invite
Trying (100)
Ringing (180)
Ringing (180)
OK (200)
OK (200)
ACK ACK

RTP/RTCP media
channels
4
VoIP Migration
Step1: IPPBX deployments in Enterprises

PSTN
Network

Customer Premises Customer Premises

IP Core
Network

- Large enterprises will handle VOIP calls directly DNS Server for URL resolution
- PSTN connectivity provided by Media Gateways
- Regulation can not stop spammers outside USA
(similar to SMTP spam)

6
STEP 2: Hosted IP Centrex
FW, NAT, VoIP service provided by Carrier Networks

Softswitches, MGW
VoIP Proxy Server, SGW Internet
SGC, VoIP Centrex Server,

Carrier Network

Customer Premises
7
Step 3: Carrier VoIP Network

VoIP Trunk

Softswitches, MGW Internet


VoIP Proxy Server, SGW
SGC, VoIP Centrix Server,

Carrier Network

- VoIP FW, NAT and Security provided by Carriers

Customer Premises

8
SIP Architecture
The Popularity of SIP
 Originally Developed in the MMUSIC
 A separate SIP working group
 RFC 2543, RFC 3261
 Many developers
 SIP + MGCP/MEGACO
 The VoIP signaling in the future
 “back-off” or SIPit (SIP Interoperability
Tests)
 Test products against each other
 Will be hosted by ETSI
10
SIP Architecture
 A signaling protocol
 The setup, modification, and tear-down of
multimedia sessions
 SIP + SDP
 Describe the session characteristics
 Separate signaling and media streams

11
SIP Network Entities
 Clients
 User agent clients
 Application programs sending SIP requests
 Servers
 Responds to clients’ requests
 Clients and servers may be in the same
platform
 Proxy
 Acts as both clients and servers

12
 Four types of servers
 Proxy servers
 Handle requests or forward requests to other
servers
 Can be used for call forwarding

13
 Redirect servers
 Map the destination address to zero or more new
addresses
 Do not initiate any SIP requests

14
 A user agent server
 Accept SIP requests and contacts the user
 The user responds → an SIP response
 A SIP device
 E.g., an SIP-enabled telephone
 A registrar
 Accepts SIP REGISTER requests
 Indicating the user is at a particular address
 Typically combined with a proxy or redirect
server

15
SIP Call Establishment
 It is simple
 A number of interim responses

16
SIP Advantages
 Attempt to keep the signaling as simple
as possible
 Offer a great deal of flexibility
 Various pieces of information can be
included within the messages
 Including non-standard information
 Enable the users to make intelligent
decisions
 The user has control of call handling
 No need to subscribe call features
17
 Call Completion to Busy Subscriber service

18
 Via contains the address (e.g., pc33.atlanta.com)
 Contact contains a SIP or SIPS URI that represents a
direct route to contact the called party, usually
composed of username at a fuly qualified domain name
(FQDN). While the FQDN is preferred, many end systems
do not have registered domain names, so IP addresses
are permitted. While Via header field tells other
elements where to send response, the Contact header
field tells other elements where the called party can be
reached directly.
 In a response, Via, To, From, Call-ID, and CSeq header
fields are copied from the INVITE request.

19
 In addition to DNS and location service
lookups, proxy servers can make flexible
“routing decisions” to decide where to send a
request. For example, if Bob’s SIP phone
returned 486 (busy) response, the biloxi.com
proxy server could proxy the INVITE to Bob’s
voicemail server. A proxy server can also send
an INVITE to a number of locations at the
same time. This type of parallel search is
known as forking.
 After learning the end point addresses, the
end points can communicate directly
20
Overview of SIP Messaging
Syntax
 Text-based
 Similar to HTTP
 SIP messages
 message = start-line
*message-header CRLF
[message-body]
 start-line = request-line | status-line
 Request-line specifies the type of request
 The response line
 The success or failure of a given request

21
 Message headers
 Additional information of the request or response
 E.g.,
 The originator and recipient
 Retry-after header
 Subject header
 Message body
 Describe the type of session
 The media format
 SDP, Session Description Protocol
 Could include an ISDN User Part message
 Examined only at the two ends
22
SIP Requests
 method SP request-URI SP SIP-version CRLF
 request-URI
 The address of the destination
 Methods
 INVITE, ACK, OPTIONS, BYE, CANCLE, REGISTER
 extensions: INFO, REFER, UPDATE, …
 INVITE
 Initiate a session
 Information of the calling and called parties
 The type of media
 IAM (initial address message) of ISUP
 ACK only the final response
23
 BYE
 Terminate a session
 Can be issued by either the calling or called
party
 Options
 Query a server as to its capabilities
 A particular type of media
 The response if sent an INVITE
 CANCEL
 Terminate a pending request
 E.g., an INVITE did not receive a final response

24
 REGISTER
 Log in and register the address with a SIP server
 “all SIP servers” – multicast address
(224.0.1.1750)
 Can register with multiple servers
 Can have several registrations with one server
 INFO
 RFC 2976
 Transfer information during an ongoing session
 DTMF digits
 account balance information
 midcall signaling information generated in
another network
25
SIP Responses
 SIP version SP status code SP reason-phrase CRLF
 reason-phrase
 A textual description of the outcome
 Could be presented to the user
 status code
 A three-digit number
 1XX Informational
 2XX Success (only code 200 is defined)
 3XX Redirection
 4XX Request Failure
 5XX Server Failure
 6XX Global Failure
 All responses, except for 1XX, are considered final 26
 Should be ACKed
“One number” service

27
SIP Addressing
 SIP URLs (Uniform Resource Locators)
 user@host
 E.g.,
 sip:collins@home.net
 sip:3344556789@telco.net
 Supplement the URL
 sip:3344556789@telco.net;user=phone
 sip:user:password@host:port;uri-parameters?headers

28
Message Headers
 Provide further information about the message
 information elements
 E.g.,
 To:header in an INVITE
 The called party
 From:header
 The caling party
 Four main categories
 General, request, response, and entity headers
 A list in Table 5-2
 Mapping in Table 5-3

29
General Headers
 Used in both requests and responses
 Basic information
 E.g., To:, From:, Call-ID:, …
 Contact:
 A URL for future communication
 May be different from the From: header
 Requests passed through proxies

30
 Request Headers
 Apply only to SIP requests
 Addition information about the request or the client
 E.g.,
 Subject:
 Priority:, urgency of the request
 Authorization:, authentication of the request
originator
 Response Headers
 Further information about the response
 E.g.,
 Unsupported:, features
 Retry-After
31
 Entity Header
 Session information presented to the user
 Session description, SDP
 The RTP payload type, an address and port
 Content-Length, the length of the message body
 Content-Type, the media type of the message
 Content-Encoding, for message compression
 Content Disposition,
 Content-Language,
 Allow, used in a Request to indicate the set of
methods supported
 Expires, the date and time

32
Example of SIP Message
Sequences
 Registration
 Via:
 Call-ID:
 host-specific
 Content-Length:
 Zero, no msg body
 Cseg:
 Avoid ambiguity
 Expires:
 TTL
 0, unreg
 Contact:
 * 33
Invitation
 A two-party call
 Subject:
 optional
 Content-Type:
 application/sdp

34
35
Termination of a Call

 Cseq:
 Has changed

36

You might also like