Presentation is loading. Please wait.

Presentation is loading. Please wait.

SIP, SDP and VoIP David A. Bryan CSCI 434/534 December 6, 2003.

Similar presentations


Presentation on theme: "SIP, SDP and VoIP David A. Bryan CSCI 434/534 December 6, 2003."— Presentation transcript:

1 SIP, SDP and VoIP David A. Bryan CSCI 434/534 December 6, 2003

2 VoIP VoIP – Voice over IP (Internet Protocol) Basic idea is to run telephone type services (and sometimes video) over IP –Cost savings (administration, arbitrage) –Tax/tariff avoidance –Security (internal, encryption) –Advanced features Next generation (3G and later) cellular phones run over IP networks

3 Telephony Protocols Original phone network is circuit switched –SS7 is the protocol used for this – NOT a computer standard –Defined by ITU – International Telecommunication Union VoIP is packet switched – uses computer networks –H.323 is also an ITU standard, but designed to work over packet switched networks

4 Telephony Protocols SIP –IETF defined a protocol for VoIP, called SIP –Designed for packet networks, useful for any sort of multimedia session establishment –Support for integration with email/web services –SIMPLE is a set of extensions to SIP to support instant messaging

5 H.323 vs. SIP FeatureH.323SIP EncodingBinaryText ControlCentralized serverEndpoints (using proxy) IntelligenceMost in central server; core Most in the endpoints; edge ModularityMonolithic (all in one server) Can be multiple servers MediaRTP

6 Media (RTP) SIP Call SIP Server SIP/SDP

7 SIP Session Initiation Protocol Defined (mostly) in IETF RFC 3261 –Many other drafts extend SIP and add new features Text based, very similar to HTTP Sets up a multimedia session between endpoints Allows mobility – locate users using a URL (sip:user@sip.cs.wm.edu) Usually runs on port 5060 Can use either UDP or TCP as transport Allows for IPv4 and IPv6. Next generation cellular phones (Europe) use SIP over TCP/IPv6

8 SDP Session Description Protocol SIP doesn’t try to describe the media stream Defined in IETF RFC 2327 This is used by SIP to actually describe the type of media being used, where to send it, etc. –Included in SIP message as a payload This is an older IETF protocol –IETF tries to promote reuse whenever possible Yet another protocol, RTP, is used for the actual media

9 SIP Logically, there are several parts to a SIP system –UA (User-Agent, Endpoint) – the phone itself – can also be a softphone – computer software –Registrar – keeps track of where the user is within a system –Redirect Server – used to inform devices when they need to contact different locations –Proxy Server – used to relay messages back and forth within the system In practice, several functions may actually be in the same server/program

10 Registration “I’m Alice, and I’ll be using a phone at 192.168.0.1 today!” 192.168.0.1 SIP Server sip.phonecompany.com When I get a call for Alice, I’ll know to contact her at 192.168.0.1! 10.0.1.1 “Lunch time! Use my mobile at 10.0.1.1” Ah, now I will have to use 10.0.1.1 to reach Alice.

11 Proxy sip.phonecompany.comsip.quickmart.com “I need to call Bob!” “Call here for Bob from Alice” “Call for you from Alice!” Bob is over at quickmart.com. I’ll proxy the call over there!

12 Redirection sip.phonecompany.comsip.quickmart.com “I need to call Bob!” “Call here for Bob from Alice” “Call for you from Alice!” sip.diveapartment.com “Try him at diveapartment.com” “Call here for Bob from Alice”

13 SIP Messages SIP messages fall into two types – requests and responses –Requests include a method telling what it is they are doing. –REGISTER, to register a phone or device –INVITE, to start a new session (call) –BYE, to end a session that is established –CANCEL, to end a session that is still being set up (no final response yet) –ACK, part of the triple handshake

14 SIP Messages Responses are numeric, much like HTTP –1xx Provisional – 100 Trying, 180 Ringing –2xx Successful – 200 OK –3xx Redirection – 301 Moved Permanently, 302 Moved Temporarily –4xx Failure – 404 Not Found, 410 Gone, 403 Forbidden –5xx Server Failure – 503 Service Unavailable –6xx Global Failure – 600 Busy Everywhere

15 Registration SIP Server REGISTER 401 Unauthorized REGISTER 200 OK

16 Basic Call SIP Server INVITE 100 Trying 180 Ringing 200 OK ACK BYE Bi-directional Media between endpoints 200 OK

17 No answer SIP Server INVITE 100 Trying 180 Ringing 487 Request Terminated 200 OK CANCEL 200 OK CANCEL 200 OK

18 INVITE message INVITE sip:bob@quickmart.com SIP/2.0 Via: SIP/2.0/TCP aliceua.phonecompany.com:5060 From: Alice To: Bob Call-ID: 3848276298220188511@phonecompany.com CSeq: 1 INVITE Contact: Content-Type: application/sdp Content-Length: 151 v=0 o=Cisco-UserAgent 10010 605 IN IP4 aliceua.phonecompany.com s=SIP Call c=IN IP4 192.0.1.1 t=0 0 m=audio 49172 RTP/AVP 0 8 16

19 INVITE message INVITE sip:bob@quickmart.com SIP/2.0 SIP request, method is INVITE – this message will start a new call Via: SIP/2.0/TCP aliceua.phonecompany.com:5060 Via header tracks where it has been – so far just Alice’s UA From: Alice Message is from Alice, and this is the SIP URL for Alice To: Bob Alice is trying to contact Bob at his SIP URL Call-ID: 3848276298220188511@phonecompany.com Call-ID is a (hopefully) unique ID to track this particular call. Alice’s UA generated this CSeq: 1 INVITE We also count messages within a call to see what responses go with what messages. This first exchange is an INVITE exchange. The response to this will also have a CSeq of 1 INVITE Contact: How to contact Alice directly – you can sometimes “skip” the proxy.

20 INVITE message Content-Type: application/sdp Content-Length: 151 The content of the message is SDP – to describe the media of the call. We have 151 bytes of SDP v=0 v is the SDP version number -- 0 o=Cisco-UserAgent 10010 605 IN IP4 aliceua.phonecompany.com o is a description of the UA and a session ID s=SIP Call s is an string to encode a name for this session c=IN IP4 192.0.1.1 c tells the other side what address to send the media to t=0 0 t indicates start and end times. 0 and 0 don’t specify times in advance m=audio 49172 RTP/AVP 0 8 16 m describes the media. We are listening for audio of type RTP/AVP on port 49172

21 Network Architecture Several ways to have a device that connects to an IP network –True IP endpoint – a phone w/an ethernet connection – often quite expensive –ATA – Analog Telephone Adaptor (this is what you get if you sign up with Vonage) – plugs into the ethernet, and you plug a phone into it –IP enabled PBX (make an existing office phone system speak SIP) –Soft Client – program that runs on a computer and is used with microphone and speakers

22 Network Architecture How about connecting to the outside world? –If you want to talk to another SIP user, your proxy may know how to contact that proxy directly –To call out (or to have calls come in) you use a gateway. It connects to one or more regular phone lines to let you receive and place calls to old fashioned “Plain Old Telephone Service”, or POTS

23 Gateway example SIP Server Gateway SIP/IP network POTS network

24 Problems with VoIP Cost of entrance –while the maintenance and operating costs are low, equipment can be expensive Reliability –Still issues with reliability of systems Safety/Security –911 is a large issue, particularly routing to the right place –Interception is difficult, and encryption is easy with softphones – possibly a national security issue

25 Problems with VoIP NAT and firewall traversal –Media and signaling on different ports leads to issues with media not being able traverse firewalls –Imbedded addresses within SIP messages are a problem for NATs Taxes/regulation –Remove some incentive for VoIP

26 Open Source SIP projects Several good open source SIP projects –VOCAL Full SIP “softswitch” – includes proxy, softclient, voice mail, etc. –ReSIProcate Newer, much nicer stack than VOCAL, but few applications so far –IPTel Sip Express Router High performance Proxy. Less full featured than VOCAL, but faster and more robust

27 References [1] SIP versus H.323, iptel.org, (http://www.iptel.org/info/trends/sip.html)http://www.iptel.org/info/trends/sip.html [2] SIP Tutorial, iptel.org, (http://www.iptel.org/sip/siptutorial.pdf)http://www.iptel.org/sip/siptutorial.pdf [3] SIP RFC, RFC-3261, IETF, (http://www.ietf.org/rfc/rfc3261.txt)http://www.ietf.org/rfc/rfc3261.txt [4] SDP RFC, RFC-2327, IETF, (http://www.ietf.org/rfc/rfc2327.txt)http://www.ietf.org/rfc/rfc2327.txt [5] VOCAL Project, (http://www.vovida.org)http://www.vovida.org [6] ReSIProcate Project, (http://www.resiprocate.org)http://www.resiprocate.org [7] Vonage, (http://www.vonage.com)http://www.vonage.com


Download ppt "SIP, SDP and VoIP David A. Bryan CSCI 434/534 December 6, 2003."

Similar presentations


Ads by Google