VoIP Technology Overview - National Taiwan Universityacpang/course/voip_2005_fall/slides/...VoIP...

45
VoIP Technology Overview Ai-Chun Pang Grad. Ins. of Networking and Multimedia Dept. of Comp. Sci. and Info. Engr. National Taiwan University

Transcript of VoIP Technology Overview - National Taiwan Universityacpang/course/voip_2005_fall/slides/...VoIP...

VoIP Technology Overview

Ai-Chun Pang

Grad. Ins. of Networking and Multimedia

Dept. of Comp. Sci. and Info. Engr.

National Taiwan University

2

Outline

� RTP (Real-Time Transport Protocol)/RTCP (RTP Control Protocol)

� SIP (Session Initiation Protocol)

� MGCP (Media Gateway Control Protocol)/MEGACO (Media Gateway Control Protocol)

� SIGTRAN (Signaling Transport)

� Softswitch

3

Voice over UDP, not TCP

� Speech

� Small packets, 10 – 40 ms

� Occasional packet loss is not a catastrophe.

� Delay-sensitive

� TCP: connection set-up, ack, retransmit → delays

� 5 % packet loss is acceptable if evenly spaced

� Resource management and reservation techniques (bandwidth and buffer size)

� A managed IP network

� Advanced voice-coding techniques

� In-sequence delivery

� UDP was not designed for voice traffic

4

Real-Time Transport Protocol

� RTP: A Transport Protocol for Real-Time Applications

� RFC 1889

� RTP – Real-Time Transport Protocol

� UDP

� Packets may be lost or out-of-sequence

� RTP over UDP

� A sequence number

� A time stamp for synchronized play-out

� Does not solve the QoS problems; simply provides

additional information

5

RTP Control Protocol

� RTCP

� A companion protocol with RTP

� Exchange messages between session users

� Quality feedback

� Number of lost packets, delay, inter-arrival jitter…

� RTCP is implicitly open when an RTP session is open

� E.g., RTP/RTCP uses UDP port 5004/5005

� Timing of RTCP packets

� The control traffic should be limited to a small fraction

of the session bandwidth.

6

Timing of RTCP Packets

� The control traffic should be limited to a small fraction of

the session bandwidth.

� RFC 1889 provides an algorithm for calculating the

interval between RTCP Packets.

� The following main characteristics are included.

� The interval > 5 seconds

� 0.5 – 1.5 times the calculated interval

� A dynamic adaptation for the interval based on the RTCP packet size

7

Introduction to SIP

� A powerful alternative to H.323

� More flexible, simpler

� Easier to implement advanced features

� Better suited to the support of intelligent user devices

� A part of IETF multimedia data and control architecture

8

The Popularity of SIP

� Originally Developed in the MMUSIC (Multiparty Multimedia Session Control)

� A separate SIP working group

� RFC 2543

� Many developers

� The latest version: RFC 3261

� SIP + MGCP/MEGACO

� The VoIP signaling in the future

� “bake-off”

� Various vendors come together and test their products against each other

� to ensure that they have implemented the specification correctly

� to ensure compatibility with other implementations

9

SIP Architecture

� A signaling protocol

� The setup, modification, and tear-down of multimedia

sessions

� SIP + SDP (Session Description Protocol)

� Describe the session characteristics

� Separate signaling and media streams

10

SIP Addressing

� SIP URLs (Uniform Resource Locators)

� user@host

� sip:[email protected]

� sip:[email protected]

11

SIP Network Entities [1/4]

� User Agents

� A SIP-enabled telephone

� User agent client (calling party)

� User agent server (called party)

� Servers

� Proxy Server

� Redirect Server

� Location Server (Registrar)

12

Proxy Server

� Can be used for call forwarding, time-of-day routing, or

follow-me services

13

Redirect Server

� Map the destination address to zero or more new addresses

14

Registrar

� Accepts SIP REGISTER requests

� Indicating that the user is at a particular address

� Personal/User mobility

� Typically combined with a proxy or redirect server

15

SIP Architecture

User Agent Client(Caller)

User Agent Server(Callee)

Proxy Server

Proxy Server

Proxy Server Redirect Server Location Server

SIP Request

SIP Response

RTP Media Stream

16

SIP Call Establishment

� It is simple, which contains a number of interim responses.

17

Overview of SIP Messaging Syntax

� Text-based

� Similar to HTTP

� Disadvantage – more bandwidth consumption

� 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 indicates the success or failure of a given request.

18

Overview of SIP Messaging Syntax

� 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 most common structure for the message body is SDP (Session Description Protocol).

� Could include an ISDN User Part message

� Examined only at the two ends

19

SIP Requests [1/2]

� Method SP Request-URI SP SIP-version CRLF

� Request-URI

� The address of the destination

� Methods

� INVITE, ACK, OPTIONS, BYE, CANCLE, REGISTER

� INVITE

� Initiate a session

� Information of the calling and called parties

� The type of media

� ~IAM (initial address message) of ISUP

� ACK only when receiving the final response

20

SIP Requests [2/2]

� BYE

� Terminate a session

� Can be issued by either the calling or called party

� OPTIONS

� Query capabilities

� A particular type of supported media

� CANCEL

� Terminate a pending request

� E.g., an INVITE did not receive a final response

� REGISTER

� Log in and register the address with a SIP server

� “all SIP servers” – multicast address (224.0.1.175)

� Can register with multiple servers

� Can have several registrations with one server

21

An Example of SIP Request

SIP Request Message Description

INVITE sip:[email protected] SIP/2.0 Method type, request URI and SIP version

Call-ID:[email protected] Globally unique ID for this call

Content-Type:application/sdp The body type, an SDP message

CSeq: 1 INVITE Command Sequence number and type

From: sip:[email protected];tag=c8-f3-1-4-5-3efad

User originating the request

To:sip:[email protected] User being invited into the call

Via: SIP/2.0/UDP 140.96.200.1:8080 IP Address and port of previous hop

Blank line separates header from body

v=0 SDP Version

o=smayer 280932498 IN IP4 140.96.200.1 Owner/creator and session identifier

s=Incoming phone call from acer The name of the session

p=+886 3 5914494 Phone number of caller

c=IN IP4 140.96.102.100 Connection information

m=audio 492837 RTP/AVP 0 Media name and transport address

22

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 as final responses

� Should be ACKed

23

An Example of SIP Response

SIP/2.0 200 OK

Via: SIP/2.0/UDP sippo.example.se

Via: SIP/2.0/UDP science.fiction.com

From: Fingal <sip:[email protected]>

To: Patric <sip:[email protected]>

Call-ID: [email protected]

Cseq: 1 INVITE

Content-Type: applcation/sdp

Content-Length: …

24

Invitation for SIP Proxy Server

itri.org.tw

location server

BENZ

honda@AUDI

(5)

AUDI(1) INVITE

[email protected]

[email protected]

csie.nctu.edu.tw

BMW(2) honda

(3) honda@AUDI

(4) INVITE

honda@AUDI

(5) 200 OK(6) 200 OK

(7) ACK [email protected] (8) ACK honda@AUDI

RTP Stream

25

Class 5

End Office Switch

The Telephone Network [1/2]

Circuit Switched Network

Intelligent

Peripheral

Signal

Transfer

Point

Service

Control

Point

Class 4

Tandem Switch

Service

Data

Point

+

Transport Layer

Control Layer

SS7 Signaling

ISUP Messages

INAP/TCAP Messages

Reference: CCL/ITRI

26

The Telephone Network [2/2]

� 5 Basic Components in Intelligent Networks

� SSP/Service Switching Point

� switching, signaling, routing, service invocation

� STP/Signal Transfer Point

� signaling, routing

� SCP/Service Control Point

� service logic execution

� SDP/Service Data Point

� subscriber data storage, access

� IP/Intelligent Peripheral

� resources such as customized voice announcement, voice recognition, DTMF digit collection

SSPSSP

SCPSCP

SDPSDP

STPSTPIP

IP

SSPSSP

STPSTP

TCAP messages

ISUP messages

Voice

27

Why MGCP/MEGACO

� Voice over IP� Lower cost of network implementation

� Integration of voice and data applications

� New service features

� Reduced bandwidth

� Replacing all traditional circuit-switched networks is not feasible.

� VoIP and circuit-switching networks must coexist.� Interoperation

� Seamless interworking

28

Separation of Media and Call Control [1/3]

� Gateways

� Interworking

� To make the VoIP network appear to the circuit switched network as a native circuit-switched system and vice versa

� Signaling path and media path are different in VoIPsystems.

� Media – directly (end-to-end)

� Signaling – through H.323 gatekeepers (or SIP proxies)

� SS7, Signaling System 7

� The logical separation of signaling and media

29

Separation of Media and Call Control [2/3]

� A network gateway has two related but separate

functions.

� Signaling conversion

� The call-control entities use signaling to communicate.

� Media conversion

� A slave function (mastered by call-control entities)

30

Separation of Media and Call Control [3/3]

� Advantages of Separation

� Media conversion close to the traffic source and sink

� The call-handling functions is centralized.

� A call agent (media gateway controller - MGC) can control multiple gateways.

� New features can be added more quickly.

� The first protocol is MGCP

� RFC 2705, IETF

� To be succeeded by MEGACO/H.248

� Has be included in several product developments

� MEGACO/H.248

� IETF and ITU-T Study Group 16

� RFC 3015 is now the official version.

31

MGCP

� A master-slave protocol

� Call agents (MGCs) control the operation of MGs

� Call-control intelligence

� Call-related signaling

� MGs

� Do what the CA instructs

� A line or trunk on circuit-switched side

� An RTP port on the IP side

� Types of Media Gateway

� Trunking Gateway to CO/Switches

� Residential Gateway to PSTN Phones

� Access Gateway

� Communication between call agents

� Likely to be the SIP

32

Network Architecture

Signaling

(SS7)

Gateway

Trunking

Gateway

Call

Agent

SCP

Residential

Gateway

InternetSS7 Network

STP

Trunking

GatewayTrunking

Gateway

CO

Switch

Residential

GatewayResidential

Gateway

MGCP/

MEGACO

MGCP/

MEGACO

RTP

SIGTRAN

33

MGCP Connection Establishment

34

Endpoints, Connections and Calls

� Endpoints

� Sources or sinks of media

� Trunk interfaces

� POTS line interfaces

� Announcement endpoint

� Connections

� Allocation of IP resources to an endpoint

� An ad hoc relationship is established from a circuited-switched line and an RTP port on the IP side.

� A single endpoint can have several connections

� A call

� A group of connections

35

� The primary function of MGCP is to enable

� The connections to be created

� The session descriptions to be exchanged between the connections

The Function of MGCP

36

H323 (SIP) vs. MGCP(MEGACO)

GWGK

MCU

GW : Gateway

GK : Gatekeeper

TN : Terminal

MCU : Multipoint Control Unit

TN

PSTNCA

TGW RGW

CA : Call Agent

TGW : Trunking Gateway

RGW : Residential Gateway

SG : Singling Gateway

SS7

PSTN CO

SG

RTP

MGCP

H.323

TNTN

GWGK

MCU

TN

TNTN

Reference: CCL/ITRI

37

Relation with H.323 Standards

CO

Switch

Internet

Call

Agent

Signaling

(SS7)

Gateway

Trunking

Gateway

Gatekeeper

Terminal

or

Gateway

SS7/ISUP

RTP

H.225/RAS

H.225/Q931

H.245

SIGTRAN

MGCP

Reference: CCL/ITRI

38

Signaling Transport

� Addressing the issues regarding the transport of signaling within IP networks

� The issues related to signaling performance within IP networks and the interworking with PSTN

� Issues discussed in SIGTRAN

� Address translation

� How can we deploy an SS7 application (e.g., ISUP) that expects certain services from lower layers such as MTP when lower layers do not exist in the IP network?

� For transport layer, the ISUP message must be carried in the IP network with the same speed and reliability as in the SS7.

� UDP x

� TCP x

39

SIGTRAN Architecture

� Signaling over standard IP uses a common transport protocol that ensures reliable signaling delivery.

� Stream Control Transmission Protocol (SCTP)

� An adaptation layer is used to support specific

primitives as required by a particular signaling

application.

� The standard SS7 applications (e.g., ISUP) do not

realize that the underlying transport is IP.

40

Why not use TCP and UDP?

� UDP

� Unreliable transmission

� Lack of congestion and flow controls

� TCP

� TCP provides both reliable data transfer and strict order-of-transmission, but SS7 may not need ordering.

� TCP will cause delay for supporting order-of-transmission.

� Head-of-line blocking

� The limited scope of TCP sockets complicates the task of data transmission using multi-homed hosts.

� TCP is relatively vulnerable to DoS attack, such as SYN attacks.

41

SCTP

� To offer the fast transmission and reliability required for

signaling carrying.

� SCTP provides a number of functions that are critical for

telephony signaling transport.

� It can potentially benefit other applications needing

transport with additional performance and reliability.

� SCTP must meet the Functional Requirements of

SIGTRAN.

42

What Supported By Using SCTP?

� To ensure reliable, error-free, in-sequence delivery of user messages (optional).

� To support fast delivery of messages and avoid head-of-

line blocking.

� To support network-level fault tolerance that is critical for

carrier-grade network performance by using multi-home hosts.

� To provide protection against DoS attack by using 4-way handshake and cookie.

43

An Example of SIGTRAN

ISUPTCAP

SCCP

MAP

MTP

OSI Layers

Application

Presentation

Session

Transport

Network

Data Link

Physical

INAP

SS7 Protocol Stack

ISUPTCAP

SCCP

MAP

SCN Signaling Adaptation

(SSA)

Common Signaling Transport

(CST)

IP

INAP

SIGTRAN Protocol Stack

44

Softswitch Overview

� Providing open layered architecture

Circuit-Switched

Transport

Hardware

Call Control

& Switching

Services &

Applications

P

R

O

P

R

I

E

T

A

R

Y

• Solutions in a proprietary box

• Little room for innovation

Soft-Switched

Transport Hardware

Softswitch Call Control

Services, Applications & Features

(Management, Provisioning and

Back Office)

Open Protocols APIs

Open Protocols APIs

• Solutions are based on open standards

• Open standards enable lower cost for

innovation

Reference: CCL/ITRI

45

Softswitch Architecture

� Softswitch: Emulating Circuit Switching in Software

IN/SCP

PSTN

Local Switch

PSTN

Local SwitchSTP

SS7 Network

IP Network

RTP Streams

MGCMGC MGCMGC

Trunk Trunk

GatewayGatewayTrunk Trunk

GatewayGateway

SGSGSGSG

IP PhoneIP Phone

90009000 Personalized VoIPService System

Application ServerApplication Server

Reference: CCL/ITRI