Final Presentation

50
07/03/22 Megaco/H.248 1 Media Gateway Control Protocol (Megaco/H.248) Ömer Korçak

Transcript of Final Presentation

Page 1: Final Presentation

04/13/23Megaco/H.248

1

Media Gateway Control Protocol (Megaco/H.248)

Ömer Korçak

Page 2: Final Presentation

Megaco/H.248 2

IntroductionVoice Over IP

• Viable alternative / addition to traditional circuit-switched telephony.

• Large companies (which have their own private global IP networks) already realize the benefits of VoIP networks.

• VoIP is now penetrating the wider population of small offices and residential Internet users.

Page 3: Final Presentation

Megaco/H.248 3

Voice Over IP

Poor quality characterized the first generation of VoIP products.

However, the opportunity for corporations to cut telephony costs and enhance voice communications with a range services has forced the technology to improve.

Page 4: Final Presentation

Megaco/H.248 4

Voice Over IP

Today's VoIP quality of service (QoS) has improved tremendously

However, the drawbacks are still apparent. The architecture of a carrier-grade VoIP

network that provides telephony service for a wider customer base cannot be completely based on the peer-to-peer architecture of current VoIP call-processing standards.

Page 5: Final Presentation

Megaco/H.248 5

Voice Over IP

• Central management and call-routing functions are needed

• Interoperable, easy-to-design, cost effective client is imperative.

Page 6: Final Presentation

Megaco/H.248 6

MEGACO

The newly-emerging media gateway control protocol (Megaco) attempts to bridge the gap between the first generation of VoIP networks and the VoIP networks of tomorrow.

Page 7: Final Presentation

Megaco/H.248 7

MEGACO

Megaco addresses the relationship between the Media Gateway (MG) and the Media Gateway Controller (MGC)

A Master/Slave protocol that removes intelligence from MGs

Page 8: Final Presentation

Megaco/H.248 8

Glossary

Decomposed Gateway Architectural model:

Gateway is decomposed into three functional components:

• Signalling Gateway

• Media Gateway

• Media Gateway Controller

Page 9: Final Presentation

Megaco/H.248 9

Media Gateway:

• Central elements in the voice stream

• Provides mapping of streams between two different networks.

• Dumb Devices

Glossary

Page 10: Final Presentation

Megaco/H.248 10

Example Media Gateways

Residental Gateways:

• Situated in the costumer premises and that provide an analog line where a traditional telephone set can be connected

• On the other side, connected to a packet network providing VoIP.

Glossary

Page 11: Final Presentation

Megaco/H.248 11

Example Media Gateways

Trunking Gateways:

• Interface between the telephone network and a VoIP network.

• Manage large number of digital virtual circuits.

Glossary

Page 12: Final Presentation

Megaco/H.248 12

Signalling Gateway:

• Intermediate element between IP network and SCN domain.

• Provides the signalling mediation function between a voice over IP network and a switched circuit network.

Glossary

Page 13: Final Presentation

Megaco/H.248 13

Gatekeeper:

• Controls terminals and gateways

• Responsible for Registration, Admission and Status (RAS) messages.

• A central element in the control of the calls through an IP system.

• Contains the intelligence of the control part of IP network.

Glossary

Page 14: Final Presentation

Megaco/H.248 14

Media Gateway Controller:

• Controls Media Gateways depending on the SCN signalling coming from the SG and IP signalling coming from the gatekeeper.

• Intelligent Devices

Glossary

Page 15: Final Presentation

Megaco/H.248 15

GK GK

H.323 terminal

MGC

MG

Back-end

SG

ESTI-TIPHON functional decomposition reference model

Page 16: Final Presentation

Megaco/H.248 16

Benefits of Decomposed Media Gateway Model

• Removing the signaling to a fast server is more practical than trying to integrate it into the MG.

• New services can be introduced without requiring any customer premises equipment (CPE) upgrades.

• Handled by simply upgrading the centralized software that contains the intelligence for implementing services.

Page 17: Final Presentation

Megaco/H.248 17

Benefits of Decomposed Media Gateway Model

• Central call control gains a strong power

• Modularity satisfied

• Interoperable, easy-to-design, cost effective client.

• Any necessity to proprietary protocols is abandoned.

• Better suited to implementing protocol stacks and large volumes of general-purpose code.

Page 18: Final Presentation

Megaco/H.248 18

Media gateway control vs. call signalling

SG

MG

MGC SG

MG

MGC

SIPUser Agent

H.323Endpoint

PSTN PSTN

Call signaling

Media gateway control signaling

Media flows

SIP-T, ISUP in H.323, Q.BICC

SIP

H.323 callsignalingGateway

controlprotocol

Gatewaycontrolprotocol

Page 19: Final Presentation

Megaco/H.248 19

Media Gateway Model

The MG is composed of two logical entities that can be controlled by the MGC:

Terminations: interfaces to the media streams. Context: assotiation between a collection of

terminations.

Page 20: Final Presentation

Megaco/H.248 20

Basic Concepts Connection model: terminations,

streams, and the context Termination properties: descriptors Message structure: transactions, actions,

and commands Event and signal processing Packages

Page 21: Final Presentation

Megaco/H.248 21

Terminations

Source or sink of media flows Available on both sides of the Media Gateway

(SCN and IP-Network) Media flows can be either one way or two way Terminations can also sink/source multimedia

streams that include several media streams.

Page 22: Final Presentation

Megaco/H.248 22

Terminations

Two types of terminations: Persistent terminations: Instantiated by the MG

when it boots and remain active all the time. Ephemeral terminations: Created when they are

needed. ROOT termination: Represents the MG as an

entity in itself.

Page 23: Final Presentation

Megaco/H.248 23

Context

Modeled as a mixing bridge between terminations. Two or more terminations may placed into a

context in order to mix and connect them. Created and released by the MG under command

of MGC. Null context: holds the persistent terminations

while they are not in use.

Page 24: Final Presentation

Megaco/H.248 24

Context Example: Basic call

T1 T2

Medium=audio,

Mode=sendReceive

Medium=audio,

Mode=sendReceive

Ordinary two-party conversation between terminations T1 and T2

Page 25: Final Presentation

Megaco/H.248 25

Context Example:Conversation with passive listener

T1 T2

Medium=audio,

Mode=sendReceive

Medium=audio,

Mode=sendReceive

T3

Medium=audio,

Mode=sendOnly

Example:

• Wiretap

• Recording Machine

Page 26: Final Presentation

Megaco/H.248 26

Context Example: Media Conversion

T1 T2

Medium=audio,

Mode=sendReceive

Medium=text,

Mode=sendReceive

Implicit conversion between media

Page 27: Final Presentation

Megaco/H.248 27

Context Example:Multimedia

Stream=1,medium=audio

Stream=1,medium=audio

Stream=2,medium=video

Stream=2,medium=video

T3

T1 T2

Page 28: Final Presentation

Megaco/H.248 28

Descriptors

Properties of terminations Most important ones:

Media Descriptor : Describes the transformations to be applied to media flows through the termination

Events Descriptor : Selects and reports events that are currently occurred and important for MGC

Signals Descriptor : Indicates which signals the MGC currently wishes the MG to play out the termination

Page 29: Final Presentation

Megaco/H.248 29

Descriptors

Media Descriptors include some other descriptors: Termination State Descriptor: Carries the state of the

termination which is independent of any media flow Local Control Descriptor: Provides Media-stream-related

information relevant only between MGC and MG Local and Remote Descriptor: Carries information describing

media flows within a stream which must be coordinated with the remote entity

Page 30: Final Presentation

Megaco/H.248 30

Message StructureMegaco/H.248 message

Header Transaction Transaction ... Transaction Req or Reply Req or Reply Req or Reply

Trans Hdr Action ... Action

Ctx Hdr Ctx Properties Command ... Command

Cmd Hdr Descriptor ... Descriptor

Page 31: Final Presentation

Megaco/H.248 31

Commands

Megaco uses some commands in order to manipulate terminations, contexts, signals and events.

For termination manipulation: Add, Subtract, Move, Modify

For event reporting: Notify For management: AuditCapability, AuditValue,

ServiceChange

Page 32: Final Presentation

Megaco/H.248 32

Commands

From MGC to MC: Add: adds a termination to a context Subtract: removes a termination from a context Move: moves a termination from a context to another Modify: changes the characteristics of an existing

termination , which can be in the null context AuditValue & AuditCapabilities: return information

about terminations, contexts and general state and capabilities of MG

Page 33: Final Presentation

Megaco/H.248 33

Commands

From MG to MGC: Notify: MG sends it to inform MGC that an event

has occured. Either from MG to MGC or from MGC to MG:

ServiceChange: creates a connection between MG and MGC.

Descriptors are parameters for all these commands & return values of some of them.

Page 34: Final Presentation

Megaco/H.248 34

Events

Events are detected at MG and reported to MGC. (example: inband signaling) MGC controls what events it wants to learn about at

any given time sets the termination Events descriptor

Events can have side effects stop playout of signals start new signals automatically update the set of events of interest

Page 35: Final Presentation

Megaco/H.248 35

Signals

Signals cause things to happen on terminations play a tone, display text, ...

Specified in the Signals descriptor for a termination MGC can specify duration of signal ahead of time or

signal can play until explicitly stopped Signals stop playing when any event is detected

unless MGC says otherwise.

Page 36: Final Presentation

Megaco/H.248 36

Packages

Add detailed content to the protocol all events, signals, and statistics are specified in

packages can also specify additional properties

Package definition a continuing process being created by multiple standards bodies private packages also allowed

Packages can inherit from and extend other packages.

Page 37: Final Presentation

Megaco/H.248 37

Example Call FlowsUser A RGW1 MGC RGW2 User B

MODIFY to check off-hookMODIFY to

check off-hook

Response ResponseUserA offhook

NOTIFY offhook

Response

MODIFY SG:dialtone

Dial ToneResponse

User dials digitsNOTIFY digits

Response

Page 38: Final Presentation

Megaco/H.248 38

Example Call Flows (2)User A RGW1 MGC RGW2 User B

ADD TermA SD:ringbacktone

ADD $, Local SDPRingback Tone

Response

ADD TermB SD:Ring

ADD $ Local, Remote SDP

User B phone ringingResponse

User goes offhookNOTIFY offhook

Response

Page 39: Final Presentation

Megaco/H.248 39

Example Call Flows (3)User A RGW1 MGC RGW2 User B

MODIFY TermA SendRecv

MODIFY EphA Remote SendRecv

ResponseMODIFY TermB SendRecv

MODIFY EphB Remote SendRecv

Response

R T P M e d i a

Page 40: Final Presentation

Megaco/H.248 40

Sample MessageMGC to MG1:

MEGACO/1 [123.123.123.4]:55555

Transaction = 9999 {

Context = $ {

ADD=A4444 {Media= {

LocalControl={mode=sendonly}, Local={v=0c=IN IP4 $m=audio $ RTP/AVP 4 },

Page 41: Final Presentation

Megaco/H.248 41

Sample Message (cont.)

Remote={v=0c=IN IP4 124.124.124.222m=audio 2222 RTP/AVP 4 }}}}}

Page 42: Final Presentation

Megaco/H.248 42

What we are going to do

Megaco is the most complex and very extensive VoIP protocol.

In some companies hundreds of people are working for this.

No efficient way for the implementation. We should work over a subset of Megaco

implementation.

Page 43: Final Presentation

Megaco/H.248 43

What we are going to do

Megaco architecture can be considered as 3 basic components: Protocol Stack Media Gateway Application Media Gateway Controller Application.

Page 44: Final Presentation

Megaco/H.248 44

What we are going to do

Both of the MG and MGC applications use the stack

They are in a higher level. Therefore our aim is to implement the stack first. Keep the scope of the stack implementation as

small as possible.

Page 45: Final Presentation

Megaco/H.248 45

An Example Protocol StackNet Brahma Technologies

Page 46: Final Presentation

Megaco/H.248 46

What we are going to do

First we should do a careful definition of the interfaces to our stack. An interface to the application state machines

(control association, termination, context) An interface to the Transport Layer.

Protocol specification provides an API to the application. We should decide how we are going to implement API.

Page 47: Final Presentation

Megaco/H.248 47

Protocol Stack ImplementationLooking at the incoming message we should have do following operations:

receive it from the transport layer you are using parse it at the message level, breaking it down into

header and transactions  parse transactions into actions  parse actions into context properties and commands parse commands into descriptors  parse descriptors into individual parameters, including

items defined in packages  pass the results across our defined application

interface.

Page 48: Final Presentation

Megaco/H.248 48

Protocol Stack Implementation

Major Challenge : To define the appropriate actions to take when we find

syntactic errors. They are generally could not be handled in stack level.

Page 49: Final Presentation

Megaco/H.248 49

Protocol Stack Implementation

What our stack will support? Media Gateways: Only residential gateways Transport mechanism: Only TCP. Encoding Mechanism: Only text encoding Descriptors: All, except topology descriptor. Packages: Only that are necessary (such as analog line

supervision package, RTP package, generic package, DTMF detection package ).

Commands: All commands except “Move” command.

Page 50: Final Presentation

Megaco/H.248 50

References

RFC 3015: Megaco Protocol Version 1.0 T. Taylor, “Megaco/H248: A New Standard for Media Gateway Control”,

IEEE Communications Magazine, Oct. 2000. M. B. Brahmanapally, draft-madhu-megaco-callflow-00.txt D. Allen, “Megaco and MGCP”, www.networkmagazine.com, May 2000. www.netbrahma.com S. Çabuk, E. Deveci, Ö. Köken, S. Üstün, “Issues in Softswitch Design”,

Boğaziçi University, June 2001. www.hssworld.com/products/protocolstacks/megaco/megaco_home.htm H. Liu and P. Mouchtaris, “Voice over IP Signalling: H323 and Beyond”,

IEEE Communications Magazine, Oct. 2000.