1 Extending SIP Speaker: Hsuan-Ming Chen Adviser: Ho-Ting Wu Date: 2005/04/26.

39
1 Extending SIP Speaker: Hsuan-Ming Chen Adviser: Ho-Ting Wu Date: 2005/04/26
  • date post

    21-Dec-2015
  • Category

    Documents

  • view

    226
  • download

    1

Transcript of 1 Extending SIP Speaker: Hsuan-Ming Chen Adviser: Ho-Ting Wu Date: 2005/04/26.

Page 1: 1 Extending SIP Speaker: Hsuan-Ming Chen Adviser: Ho-Ting Wu Date: 2005/04/26.

1

Extending SIP

Speaker: Hsuan-Ming Chen

Adviser: Ho-Ting Wu

Date: 2005/04/26

Page 2: 1 Extending SIP Speaker: Hsuan-Ming Chen Adviser: Ho-Ting Wu Date: 2005/04/26.

2

Outline

Background Extending SIP Introduction Design Principle for SIP Extension Extension to SIP Summary

Page 3: 1 Extending SIP Speaker: Hsuan-Ming Chen Adviser: Ho-Ting Wu Date: 2005/04/26.

3

Background What is SIP?

SIP is an end-to-end, application-layer control (signaling) protocol for Initiating, modifying, terminating sessions

Find the user’s current location Carry session descriptions

signaling qulity of service media transport

physical

link

network

transport

Page 4: 1 Extending SIP Speaker: Hsuan-Ming Chen Adviser: Ho-Ting Wu Date: 2005/04/26.

4

Background (cont.)

SIP components - User Agent User Agent Client (UAC)- Initiate SIP Request User Agent Server (UAS)-Accepts or rejects call

Page 5: 1 Extending SIP Speaker: Hsuan-Ming Chen Adviser: Ho-Ting Wu Date: 2005/04/26.

5

Background (cont.)

SIP components - Proxy Server Heart of SIP network that contains all service logic Receives SIP messages, forwards to next SIP UAS

Page 6: 1 Extending SIP Speaker: Hsuan-Ming Chen Adviser: Ho-Ting Wu Date: 2005/04/26.

6

Background (cont.)

SIP components - Redirect Server Return routing information to the originating endpoint

Page 7: 1 Extending SIP Speaker: Hsuan-Ming Chen Adviser: Ho-Ting Wu Date: 2005/04/26.

7

Background (cont.)

SIP components - Registrar Server Maintains user’s whereabouts Typically co-located with a proxy server or a redir

ect server and may offer location services

Page 8: 1 Extending SIP Speaker: Hsuan-Ming Chen Adviser: Ho-Ting Wu Date: 2005/04/26.

8

Background (cont.) SIP Method

INVITE Initiates a call by inviting user to participate in session

ACK Confirms the client has received a final response to an INVITE request

BYE Indicates termination of the call

CANCEL Cancels a pending request

REGISTER Registers the user agent

OPTIONS Used to query the capabilities of a server

Page 9: 1 Extending SIP Speaker: Hsuan-Ming Chen Adviser: Ho-Ting Wu Date: 2005/04/26.

9

Background (cont.)

SIP Network Architecture

Page 10: 1 Extending SIP Speaker: Hsuan-Ming Chen Adviser: Ho-Ting Wu Date: 2005/04/26.

10

Extending SIP Introduction

Session Initiation Protocol (SIP) is designed so that its core functionality is present in every implementation

SIP is flexible and easy to extend According to special requirements devise extensions to

meet particular needs The community has defined a set of extensions very

quickly

These extensions are implemented in a module fashion

Page 11: 1 Extending SIP Speaker: Hsuan-Ming Chen Adviser: Ho-Ting Wu Date: 2005/04/26.

11

Introduction (cont.)

Extension Negotiation A negotiation process is needed in order to determine the

extensions that will be used within any given session

Page 12: 1 Extending SIP Speaker: Hsuan-Ming Chen Adviser: Ho-Ting Wu Date: 2005/04/26.

12

Introduction (cont.) Extension Negotiation

Two headers: Require an Supported A client lists all of the extensions it needs to establish a

session in the Require header and all of the extensions it supports in the Supported header

RequireSupported

SupportedRequire

foo3, foo5 will not be used

Supports: 1, 2, 3, 4 Supports: 1, 2, 4, 5

Page 13: 1 Extending SIP Speaker: Hsuan-Ming Chen Adviser: Ho-Ting Wu Date: 2005/04/26.

13

Design Principle for SIP Extension

Do Not Break the Toolkit Approach Extensions to SIP should not broaden the scope

of SIP Ex. One might want to use SIP to download Web

pages from a server, but HTTP already exists for that purpose. So using sip extensions to cover HTTP functionality is not wise

Page 14: 1 Extending SIP Speaker: Hsuan-Ming Chen Adviser: Ho-Ting Wu Date: 2005/04/26.

14

Design Principle for SIP Extension (cont.)

Independence from Session Type SIP separates session establishment from session descript

ion Ex. should define how SIP interacts with QoS, should not d

efine how SIP can used in conjunction with SDP and RSVP in order to provide QoS

Do Not Change Method Semantics Ex. define a header called Real-Purpose be carried in INVI

TE request as follows: Real-Purpose: Tell me your capabilities

Use OPTIONS method which is defined specifically for that purpose

Page 15: 1 Extending SIP Speaker: Hsuan-Ming Chen Adviser: Ho-Ting Wu Date: 2005/04/26.

15

Extension to SIP 1. Reliable Delivery of Provisional Responses 2. Mid-session Transaction That Do Not Change the State of the Session 3. Multiple Message Bodies 4. Instant Messages 5. Automatic Configuration of UAs 6. Preconditions to Be Fulfilled Before Alerting 7. Caller Preferences 8. Asynchronous Notification of Events 9. Third-party Call Control 10. Session Transfer 11. Sending Commands 12. SIP Security

Page 16: 1 Extending SIP Speaker: Hsuan-Ming Chen Adviser: Ho-Ting Wu Date: 2005/04/26.

16

Extension to SIP (1/12)

Reliable Delivery of Provisional Responses SIP does not transmit provisional responses reliably [Draft-ietf-sip-100rel] is the SIP extension defined to

provide the reliable transfer of provisional responses

(1) INVITE

(2) 180 Ringing

(3) 200 OK

(4) ACK

Converstaion

Page 17: 1 Extending SIP Speaker: Hsuan-Ming Chen Adviser: Ho-Ting Wu Date: 2005/04/26.

17

Extension to SIP (1/12) (cont.)

Reliable Delivery of Provisional Responses A new method called Provisional Response ACK (PRA

CK) was defined to acknowledge the reception of provisional responses

UASs transmitting reliable provisional responses retransmit until a message from the UAC is received acknowledging reception

Page 18: 1 Extending SIP Speaker: Hsuan-Ming Chen Adviser: Ho-Ting Wu Date: 2005/04/26.

18

Extension to SIP (1/12) (cont.)

(1) INVITE

(2) 180 RINGING

(3) 180 RINGING

(4) PRACK(5) 200 OK

(6) 200 OK

(7) ACK

Conversation

Page 19: 1 Extending SIP Speaker: Hsuan-Ming Chen Adviser: Ho-Ting Wu Date: 2005/04/26.

19

Extension to SIP (2/12)

Mid-session Transaction That Do Not Change the State of the Session SIP provides a means to change the parameters

of the sessions through re-INVITEs Exchange information (ex. Billing information) that

does not influence the state of the session New SIP method called INFO [RFC 2976] provides thi

s functionality

Page 20: 1 Extending SIP Speaker: Hsuan-Ming Chen Adviser: Ho-Ting Wu Date: 2005/04/26.

20

Extension to SIP (3/12) Multiple Message Bodies

Deliver photos along with the session description UA needs to receive a file with the photo or a URL where

Bob’s UA can retrieve the photo An INVITE carrying a message body with two parts:

SDP session description photo

(1) INVITE

SDPLaura’ s photo

(2) 200 OK

(3) ACK

Page 21: 1 Extending SIP Speaker: Hsuan-Ming Chen Adviser: Ho-Ting Wu Date: 2005/04/26.

21

Extension to SIP (4/12)

Instant Messages A new method called MESSAGE was defined to carry in its

body the message that the sender wrote

Bob Larua

(1) INVITE

(4) MESSAGE“ Costa del Sol”

(2) 200 OK

How do you spell the name of the place we are

going on vocation?

(3) ACK

(5) 200 OK

Page 22: 1 Extending SIP Speaker: Hsuan-Ming Chen Adviser: Ho-Ting Wu Date: 2005/04/26.

22

Extension to SIP (5/12) Automatic Configuration of UAs

One of the main features of SIP is that it provides user mobility through registration

(1) I am a new laptop in the internet, I have just been connected

DHCP server

(2) Your IP address is: 140.124.181.112Your SIP domain name is: ntut.edu.tw

Page 23: 1 Extending SIP Speaker: Hsuan-Ming Chen Adviser: Ho-Ting Wu Date: 2005/04/26.

23

Extension to SIP (6/12)

Preconditions to Be Fulfilled Before Alerting Establishing a secure channel between two end users and

providing QoS takes time Ghost ringing

If the session is established and the network does not grant the necessary QoS, the session fails. This would mean that a user answers a SIP phone that is ringing and finds no call established

A new method called preCOnditions MET (COMET) COMETs are sent to indicate that all preconditions are met

and session establishment can proceed

Page 24: 1 Extending SIP Speaker: Hsuan-Ming Chen Adviser: Ho-Ting Wu Date: 2005/04/26.

24

Extension to SIP (6/12) (cont.)

(1) INVITEQoS

preconditions

(2) 183 Session Progress

(3) PRACK

(5) COMET

(4) 200 OK

(6) 200 OK

(7) 180 RINGING

Bob

per

form

s Q

oS r

eser

vatio

ns

Laur

a pe

rfor

ms

QoS

res

erva

tions

Page 25: 1 Extending SIP Speaker: Hsuan-Ming Chen Adviser: Ho-Ting Wu Date: 2005/04/26.

25

Extension to SIP (6/12) (cont.)

Page 26: 1 Extending SIP Speaker: Hsuan-Ming Chen Adviser: Ho-Ting Wu Date: 2005/04/26.

26

Extension to SIP (7/12)

Caller Preferences Ex. Fixed phone rung first, mobile phone next New headers

Accept-Contact Reject-Contact Request-Disposition

Page 27: 1 Extending SIP Speaker: Hsuan-Ming Chen Adviser: Ho-Ting Wu Date: 2005/04/26.

27

Extension to SIP (7/12) (cont.)

Laura uses new SIP headers to indicate her preferences

Accept-Contact

Accept-ContactReject-Contact

Reject-ContactRequest-Disposition

Request-Disposition

Page 28: 1 Extending SIP Speaker: Hsuan-Ming Chen Adviser: Ho-Ting Wu Date: 2005/04/26.

28

Extension to SIP (8/12)

Asynchronous Notification of Events Event notification mechanism

The SIP event notification framework enables SIP to inform users about a variety of events in which they’ve previously indicated an interest via signaling

Two new methods: SUBSCRIBE is used by a SIP entity to declare its

interest in a particular When the subscribed event occurs, NOTIFY requests

are sent containing information about the session

Page 29: 1 Extending SIP Speaker: Hsuan-Ming Chen Adviser: Ho-Ting Wu Date: 2005/04/26.

29

Extension to SIP (8/12) (cont.)

(1) INVITE

(2) 464 Busy here

(3) ACK

(4) SUBSCRIBELaura’ s status

(6) 200 OK(5) 200 OK

(8) NOTIFYLaura is available

(7) 200 OK

(9) 200 OK

(10) INVITE

(6) NOTIFYLaura is busy

Bob Laura

Page 30: 1 Extending SIP Speaker: Hsuan-Ming Chen Adviser: Ho-Ting Wu Date: 2005/04/26.

30

Extension to SIP (8/12) (cont.)

Bob receives a NOTIFY when Laura joins the conference call

LauraBob

(1) INVITE

(2) 200 OK

(3) ACK

(4) SUBSCRIBENumber of particpants

(5) 200 OK

(6) NOTIFYThere are currently 6 participants

(7) 200 OK

(8) INVITE

(9) 200 OK

(10) ACK

(11) NOTIFYThere are currently 7 participants

(12) 200 OK

ConferenceUnit

Page 31: 1 Extending SIP Speaker: Hsuan-Ming Chen Adviser: Ho-Ting Wu Date: 2005/04/26.

31

Extension to SIP (9/12)

Third-party Call Control

Bob establishes a session between the conference unit and his computer at home

Page 32: 1 Extending SIP Speaker: Hsuan-Ming Chen Adviser: Ho-Ting Wu Date: 2005/04/26.

32

Extension to SIP (9/12) (cont.)

Third-party call control message flow

Because the second INVITE contains the session description provided by Bob’s computer, the conference unit will send the audio stream to Bob’s computer.

Bob

Bob’ scomputer

Conference Unit

(1) INVITEno SDP

(2) 200 OKSDP computer

(3) INVITESDP computer

(4) 200 OKSDP conference unit

(5) ACKSDP conference unit

(6) ACKno SDP

Page 33: 1 Extending SIP Speaker: Hsuan-Ming Chen Adviser: Ho-Ting Wu Date: 2005/04/26.

33

Extension to SIP (10/12)

Session Transfer Using session transfer to filtrate phone call A new method REFER was defined instructs a server

to send a specific request

Page 34: 1 Extending SIP Speaker: Hsuan-Ming Chen Adviser: Ho-Ting Wu Date: 2005/04/26.

34

Extension to SIP (10/12) (cont.)Laura Bob

Bob’ ssecretary

Please holdwhile I transfer

your call

Conversation

Conversation

(1) INVITE

(2) 200 OK

(3) ACK

(4) INVITE (hold)

(5) 200 OK

(6) ACK

(7) REFERRefer-To: SIP: [email protected]: SIP: [email protected]

(8) 202 Accepted

(9) INVITEReferred-By: SIP: [email protected]

(10) 200 OK

(11) ACK

(12) NOTIFY

(13) 200 OK

(14) BYE

(15) 200 OK

Page 35: 1 Extending SIP Speaker: Hsuan-Ming Chen Adviser: Ho-Ting Wu Date: 2005/04/26.

35

Extension to SIP (11/12)

Sending Commands sometimes it is necessary to send a command to a device

outside a master/slave architecture A new method called DO was defined to carry commands

Bob controls his radio using SIP

Laura BobBob’ s radio

(1) INVITE(2) DOmute

(3) 200 OK(4) 200 OK

(5) ACK

Conversation

(6) BYE

(7) 200 OK

(2) DOSet volume to 3/10

(9) 200 OK

Page 36: 1 Extending SIP Speaker: Hsuan-Ming Chen Adviser: Ho-Ting Wu Date: 2005/04/26.

36

Extension to SIP (12/12) SIP Security

SIP security is concerned with the exchange of SIP signalling

Bob Laura

(1) INVITE

(2) 401 UnauthorizedWWW – authenticate: (challenge)

(3) ACK

(4) INVITEAuthorization: (Credentials)

(6) ACK

(5) 200 OK

Conversation

Page 37: 1 Extending SIP Speaker: Hsuan-Ming Chen Adviser: Ho-Ting Wu Date: 2005/04/26.

37

Extension to SIP (12/12) (cont.)

SIP Security A malicious proxy in the middle of the SIP path

could change the contents of the SIP message S/MIME Authentication is generic enough to

exchange secure e-mails and work with both HTTP and SIP Message are signed using a public-key encryption

mechanism An individual user has two keys

private key: only one user knows public key: available to anyone

Page 38: 1 Extending SIP Speaker: Hsuan-Ming Chen Adviser: Ho-Ting Wu Date: 2005/04/26.

38

Summary

SIP is flexible and easy to extend SIP security is a critical issue because it is

used in the internet SIP + Extending SIP can develop unexpected

applications

Page 39: 1 Extending SIP Speaker: Hsuan-Ming Chen Adviser: Ho-Ting Wu Date: 2005/04/26.

39

Reference

SIP Demystified by Gonzalo CamarilloMcGraw-Hill, Published August 2001, ISBN 0071373403

http://www.cs.columbia.edu/sip/ RFC 3261(SIP/2.0) RFC 2327(SDP)