138 5.7.2 The Originating P-CSCF Processes the INVITE Request.. 145 5.7.3 The Originating S-CSCF Processes the INVITE Request.. 150 5.7.5 The Terminating S-CSCF Processes the INVITE Requ
Trang 3First edition first published 2004 2004 John Wiley & Sons Ltdc
Second edition first published 2005 2005 John Wiley & Sons Ltdc
All rights reserved No part of this publication may be reproduced, stored in a retrieval system, ortransmitted, in any form or by any means, electronic, mechanical, photocopying, recording or
otherwise, except as permitted by the UK Copyright, Designs and Patents Act 1988, without the priorpermission of the publisher
Wiley also publishes its books in a variety of electronic formats Some content that appears in printmay not be available in electronic books
Designations used by companies to distinguish their products are often claimed as trademarks Allbrand names and product names used in this book are trade names, service marks, trademarks orregistered trademarks of their respective owners The publisher is not associated with any product orvendor mentioned in this book This publication is designed to provide accurate and authoritativeinformation in regard to the subject matter covered It is sold on the understanding that the publisher isnot engaged in rendering professional services If professional advice or other expert assistance isrequired, the services of a competent professional should be sought
Library of Congress Cataloging-in-Publication Data
Camarillo, Gonzalo
The 3G IP multimedia subsystem (IMS) : merging the Internet and the cellular
worlds / Gonzalo Camarillo, Miguel A Garc´ıa-Mart´ın – 3rd ed
p cm
Includes bibliographical reference and index
ISBN 978-0-470-51662-1 (cloth)
1 Wireless communication systems 2 Mobile communication systems 3
Multimedia communications 4 Internet Protocol multimedia subsystem I
Garc´ıa-Mart´ın, Miguel A II Title
TK5103.2.C35 2008
A catalogue record for this book is available from the British Library
ISBN 978-0-470-51662-1 (HB)
Set in 10/12pt Times by Sunrise Setting Ltd, Torquay, UK
Printed in Great Britain by Antony Rowe Ltd, Chippenham, England
Trang 4To my parents, Anselmo and Isabel; my brothers, Alvaro, Daniel, and Ignacio; and Viviana.They all are a source of energy and motivation in everything I do.
Gonzalo
To my daughter Maria Elizabeth, who was born at the time I started writing this book – she
is the sunshine of my life; my wife Jelena, who provided me with all the support and love Ineeded; my parents, Jos´e and Mari-Luz, my aunt Feli, my brother Javier Jos´e who, throughthe distance, encouraged and supported me during this project
Miguel Angel
Trang 5Foreword by Stephen Hayes xxi Foreword by Allison Mankin and Jon Peterson xxiii
Preface to the Third Edition xxvii Preface to the Second Edition xxix Preface to the First Edition xxxi
Part I Introduction to the IMS 1
1 IMS Vision: Where Do We Want to Go? 5
1.1 The Internet 5
1.2 The Cellular World 6
1.3 Why do we need the IMS? 6
1.4 Relation between IMS and non-IMS Services 8
2 The History of the IMS Standardization 9 2.1 Relations between IMS-related Standardization Bodies 9
2.2 Internet Engineering Task Force 10
2.2.1 Structure of the IETF 10
2.2.2 Working Group Operations 12
2.2.3 Types of RFCs 12
2.3 Third Generation Partnership Project 14
2.3.1 3GPP Structure 15
2.3.2 3GPP Deliverables 15
2.4 Third Generation Partnership Project 2 15
2.4.1 3GPP2 Structure 16
2.4.2 3GPP2 Deliverables 17
2.5 IETF-3GPP/3GPP2 Collaboration 18
2.5.1 Internet Area 18
Trang 6viii CONTENTS
2.5.2 Operations and Management Area 19
2.5.3 Transport Area 19
2.6 Open Mobile Alliance 20
2.6.1 OMA Releases and Specifications 20
2.6.2 Relationship between OMA and 3GPP/3GPP2 22
2.6.3 Relationship between OMA and the IETF 22
3 General Principles of the IMS Architecture 25 3.1 From Circuit-switched to Packet-switched 25
3.1.1 GSM Circuit-switched 25
3.1.2 GSM Packet-switched 26
3.2 IMS Requirements 26
3.2.1 IP Multimedia Sessions 27
3.2.2 QoS 27
3.2.3 Interworking 28
3.2.4 Roaming 28
3.2.5 Service Control 28
3.2.6 Rapid Service Creation 29
3.2.7 Multiple Access 29
3.3 Overview of Protocols used in the IMS 29
3.3.1 Session Control Protocol 29
3.3.2 The AAA Protocol 30
3.3.3 Other Protocols 31
3.4 Overview of IMS Architecture 31
3.4.1 The Databases: the HSS and the SLF 32
3.4.2 The CSCF 33
3.4.2.1 The P-CSCF 33
3.4.2.2 P-CSCF Location 34
3.4.2.3 The I-CSCF 34
3.4.2.4 I-CSCF Location 35
3.4.2.5 The S-CSCF 35
3.4.2.6 S-CSCF Location 35
3.4.3 The Application Server 35
3.4.3.1 AS Location 37
3.4.4 The MRF 37
3.4.4.1 MRF Location 37
3.4.5 The BGCF 37
3.4.6 The IMS-ALG and the TrGW 37
3.4.7 The PSTN/CS Gateway 39
3.4.8 Home and Visited Networks 40
3.5 Identification in the IMS 42
3.5.1 Public User Identities 42
3.5.2 Private User Identities 43
3.5.3 The Relation between Public User Identities and Private User Identities 43
3.5.4 Public Service Identities 43
Trang 73.6 SIM, USIM, and ISIM in 3GPP 45
3.6.1 SIM 45
3.6.2 USIM 46
3.6.3 ISIM 48
3.7 Next Generation Networks (NGN) 49
3.7.1 NGN Overview 49
3.7.2 The Core IMS in NGN 51
Part II The Signaling Plane in the IMS 55 4 Session Control on the Internet 59 4.1 SIP Functionality 59
4.1.1 Session Descriptions and SDP 59
4.1.2 The Offer/Answer Model 60
4.1.3 SIP and SIPS URIs 61
4.1.4 User Location 62
4.2 SIP Entities 63
4.2.1 Forking Proxies 65
4.2.2 Redirect Servers 66
4.3 Message Format 67
4.4 The Start Line in SIP Responses: the Status Line 67
4.5 The Start Line in SIP Requests: the Request Line 68
4.6 Header Fields 68
4.7 Message Body 70
4.8 SIP Transactions 71
4.9 Message Flow for Session Establishment 72
4.10 SIP Dialogs 75
4.10.1 Record-Route, Route, and Contact Header Fields 78
4.11 Extending SIP 78
4.11.1 New Methods 80
4.12 Caller Preferences and User Agent Capabilities 80
4.13 Reliability of Provisional Responses 81
4.14 Preconditions 84
4.15 Event Notification 85
4.15.1 High Notification Rates 87
4.15.1.1 Event Throttling 88
4.15.1.2 Conditional Event Notification 88
4.16 Signaling Compression 89
4.16.1 SigComp Extended Operations 90
4.16.2 Static SIP/SDP Dictionary 91
4.17 Content Indirection 91
4.18 The REFER Method 93
4.19 Globally Routable User Agent URIs (GRUU) 96
4.20 NAT Traversal 100
4.20.1 Types of NAT 101
4.20.2 STUN 105
4.20.3 TURN 105
4.20.4 ICE 106
Trang 8x CONTENTS
5 Session Control in the IMS 111
5.1 Prerequisites for Operation in the IMS 112
5.2 IPv4 and IPv6 in the IMS 113
5.3 IP Connectivity Access Network 114
5.4 P-CSCF Discovery 115
5.5 IMS-level Registration 117
5.5.1 IMS Registration with an ISIM 117
5.5.2 IMS Registration with a USIM 125
5.5.2.1 Temporary Private User Identity 126
5.5.2.2 Temporary Public User Identity 127
5.5.2.3 Home Network Domain URI 127
5.5.2.4 Registration Flow 127
5.6 Subscription to the reg Event State 130
5.7 Basic Session Setup 135
5.7.1 The IMS Terminal Sends an INVITE Request 138
5.7.2 The Originating P-CSCF Processes the INVITE Request 145
5.7.3 The Originating S-CSCF Processes the INVITE Request 146
5.7.4 The Terminating I-CSCF Processes the INVITE Request 150
5.7.5 The Terminating S-CSCF Processes the INVITE Request 151
5.7.6 The Terminating P-CSCF Processes the INVITE Request 154
5.7.7 The Callee’s Terminal Processes the INVITE Request 154
5.7.8 Processing the 183 Response 158
5.7.9 The Caller’s IMS Terminal Processes the 183 Response 159
5.7.10 The Callee’s IMS Terminal Processes the PRACK request 159
5.7.11 Alerting the Callee 161
5.8 Application Servers: Providing Services to Users 166
5.8.1 Generalities about Application Servers 167
5.8.2 Types of Application Servers 169
5.8.2.1 The SIP Application Server 169
5.8.2.2 The OSA-SCS 170
5.8.2.3 The IM-SSF Application Server 170
5.8.3 The Session Setup Model through Application Servers 171
5.8.3.1 Application Server Acting as a SIP User Agent 172
5.8.3.2 Application Server Acting as a SIP Proxy Server 174
5.8.3.3 Application Server Acting as a SIP Redirect Server 177
5.8.3.4 Application Server Acting as a SIP B2BUA 178
5.8.4 Filter Criteria 180
5.8.5 An Example of Service Execution 184
5.9 Changes due to Next Generation Networks (NGN) 188
5.9.1 New SIP Functionality in NGN 188
5.9.2 Unneeded IMS Functionality in NGN 189
5.10 Interworking 189
5.10.1 SIP–PSTN Interworking 189
5.10.1.1 Gateway Architecture in the IMS 191
5.10.1.2 The BGCF 192
5.10.2 Interworking with Non-IMS SIP-based Networks 192
5.10.2.1 IPv4/IPv6 Interworking 192
Trang 95.11 Combinational Services 196
5.12 Basic Sessions Not Requiring Resource Reservation 197
5.12.1 The Callee Does Not Require Resource Reservation 198
5.12.2 The Caller Does Not Require Resource Reservation 204
5.12.3 Neither the Caller Nor the Callee Require Resource Reservation 206
5.13 Globally Routable User Agent URIs (GRUU) in IMS 206
5.14 IMS Communication Service Identifier (ICSI) 209
5.15 IMS Application Reference Identifier (IARI) 212
5.16 NAT Traversal in the IMS 213
6 AAA on the Internet 215 6.1 Authentication, Authorization, and Accounting 215
6.2 AAA Framework on the Internet 215
6.3 The Diameter Protocol 217
6.3.1 Diameter Sessions 218
6.3.2 The Format of a Diameter Message 219
6.3.3 Attribute-Value Pairs 220
6.3.4 The AAA and AAAS URIs 221
6.3.5 Diameter Base Protocol Commands 222
6.3.5.1 Abort Session Request and Answer (ASR, ASA) 223
6.3.5.2 Accounting Request and Answer (ACR, ACA) 223
6.3.5.3 Capabilities Exchange Request and Answer (CER, CEA) 223 6.3.5.4 Device Watchdog Request and Answer (DWR, DWA) 223 6.3.5.5 Disconnect Peer Request and Answer (DPR, DPA) 223
6.3.5.6 Re-Authentication Request and Answer (RAR, RAA) 224
6.3.5.7 Session Termination Request and Answer (STR, STA) 224 6.3.6 Diameter Base Protocol AVPs 224
7 AAA in the IMS 227 7.1 Authentication and Authorization in the IMS 227
7.2 The Cx and Dx Interfaces 227
7.2.1 Command Codes Defined in the Diameter Application for the Cx Interface 229
7.2.1.1 User Authorization Request and Answer (UAR, UAA) 229 7.2.1.2 Multimedia Auth Request and Answer (MAR, MAA) 230
7.2.1.3 Server Assignment Request and Answer (SAR, SAA) 230
7.2.1.4 Location Information Request and Answer (LIR, LIA) 231 7.2.1.5 Registration Termination Request and Answer (RTR, RTA) 232
7.2.1.6 Push Profile Request and Answer (PPR, PPA) 232
7.2.2 AVPs Defined in the Diameter Application for the Cx Interface 232
7.2.2.1 Usage of Existing AVPs 236
7.2.3 The User Profile 236
7.3 The Sh Interface 238
7.3.1 Command Codes Defined in the Diameter Application for the Sh Interface 239
7.3.1.1 User Data Request and Answer (UDR, UDA) 239
7.3.1.2 Profile Update Request and Answer (PUR, PUA) 240
Trang 10xii CONTENTS
7.3.1.3 Subscribe Notifications Request and Answer
(SNR, SNA) 240
7.3.1.4 Push Notification Request and Answer (PNR, PNA) 241
7.3.2 AVPs Defined in the Diameter Application for the Sh Interface 241
7.4 Accounting 242
8 Policy and Charging Control in the IMS 243 8.1 PCC Architecture 243
8.1.1 Session Establishment and Policy Control 244
8.1.2 SIP Procedures 246
8.1.3 Proxy Access to SDP Bodies 247
8.1.4 Status of the Signaling Bearer 248
8.1.5 The Rx Interface 249
8.1.6 The Gx Interface 249
8.2 Charging Architecture 251
8.3 Offline Charging Architecture 251
8.3.1 Charging-related SIP Header Fields 253
8.3.2 IMS Terminal in a Visited Network 253
8.3.3 IMS Terminal in its Home Network 255
8.3.4 The Rf Interface 258
8.3.5 The Ga Interface 258
8.4 Online Charging Architecture 260
8.4.1 S-CSCF 260
8.4.2 Application Servers and the MRFC 260
8.4.3 Types of Online Charging 261
8.4.3.1 Unit Determination 262
8.4.3.2 Rating 264
8.4.3.3 Tariff Changes 264
8.4.4 The Ro Interface 265
8.4.5 The Re Interface 265
9 Quality of Service on the Internet 267 9.1 Integrated Services 267
9.1.1 RSVP 267
9.1.2 State in the Network 269
9.2 Differentiated Services 269
10 Quality of Service in the IMS 271 10.1 Policy Control and QoS 271
10.2 Instructions to Perform Resource Reservations 271
10.2.1 Proxy Modifying Bodies 272
10.3 Reservations by the Terminals 274
10.4 QoS in the Network 275
Trang 1111 Security on the Internet 277
11.1 HTTP Digest Access Authentication 277
11.1.1 Security Properties of Digest 279
11.2 Certificates 280
11.3 TLS 280
11.3.1 SIP Usage 281
11.3.1.1 Client Authentication 282
11.4 S/MIME 282
11.4.1 Self-signed Certificates 284
11.5 Authenticated Identity Body 285
11.6 IPsec 287
11.6.1 ESP and AH 287
11.6.2 Tunnel and Transport Modes 287
11.6.3 Internet Key Exchange 291
11.6.3.1 IKE Security Association Establishment 291
11.6.3.2 IPsec Security Association Establishment 291
11.7 Privacy 291
11.8 Encrypting Media Streams 292
11.8.1 MIKEY 292
12 Security in the IMS 293 12.1 Access Security 293
12.1.1 Authentication and Authorization 294
12.1.1.1 HTTP Digest Access Authentication 294
12.1.1.2 HTTP Digest Access Authentication using AKA 297
12.1.1.2.1 HTTP Digest Access Authentication with AKA: UICC Contains an ISIM 297
12.1.1.2.2 HTTP Digest Access Authentication with AKA: UICC Contains a USIM 300
12.1.2 IPsec Security Association Establishment 300
12.1.3 TLS Connection Establishment 302
12.1.4 IP-CAN Linked Authentication 303
12.1.4.1 Early IMS Security Solution 303
12.1.4.2 NASS-IMS Bundled Authentication 306
12.2 Network Security 308
12.2.1 TLS Usage for Network Security 309
13 Emergency Calls on the Internet 311 13.1 Introduction 311
13.2 Location Acquisition 312
13.2.1 Manual Configuration 313
13.2.2 Location Acquired from DHCP 313
13.2.3 Location Acquired from Layer 2 Protocols 314
13.2.4 Location Acquired from Application Layer Protocols 315
13.2.5 Location Acquired from a GPS 316
13.2.6 Wireless Triangulation 316
13.3 Identifying Emergency Calls 318
13.4 Locating the Closest PSAP 319
Trang 12xiv CONTENTS
13.5 Issuing the Emergency Call 321
13.5.1 The Terminal Acquires its Location 322
13.5.2 The Terminal Does Not Have its Own Location 325
14 Emergency Calls in the IMS 329 14.1 Architecture for Supporting Emergency Calls in IMS 329
14.2 Establishing an Emergency Call in IMS 332
14.3 IMS Registration for Emergency Calls 333
14.4 Call Back from the PSAP to a User 334
14.5 Anonymous Calls 335
14.6 Emergency Calls in Fixed Broadband Accesses 336
Part III The Media Plane in the IMS 337 15 Media Encoding 341 15.1 Speech Encoding 341
15.1.1 Pulse Code Modulation 342
15.1.2 Linear Prediction 343
15.1.3 GSM-FR 344
15.1.4 AMR 345
15.1.4.1 AMR Modes 345
15.1.4.2 LPC Coefficients Calculation 347
15.1.4.3 Codebooks 347
15.1.4.4 Adaptive Codebook 347
15.1.4.5 Fixed Codebook 348
15.1.4.6 Gains 348
15.1.5 AMR-WB 348
15.1.6 SMV 348
15.2 Video Encoding 353
15.2.1 Common Video Codecs 354
15.2.2 H.263 355
15.2.3 Image Encoding 355
15.2.4 Temporal Correlation 355
15.2.5 Spatial Correlation 356
15.3 Text Encoding 356
15.4 Mandatory Codecs in the IMS 356
16 Media Transport 359 16.1 Reliable Media Transport 359
16.2 Unreliable Media Transport 360
16.2.1 DCCP 360
16.2.2 RTP 361
16.2.3 RTCP 363
16.2.4 SRTP 364
16.3 Media Transport in the IMS 364
Trang 13Part IV Building Services with the IMS 367
17 Service Configuration on the Internet 371
17.1 The XML Configuration Access Protocol (XCAP) 371
17.1.1 XCAP Application Usage 373
17.2 An Overview of XML 374
17.2.1 XML Namespaces 376
17.3 HTTP URIs that Identify XCAP Resources 376
17.4 XCAP Operations 378
17.4.1 Create or Replace Operations 378
17.4.2 Delete Operations 380
17.4.3 Fetching Operations 380
17.5 Entity Tags and Conditional Operations 380
17.6 Subscriptions to Changes in XML Documents 383
17.7 XML Patch Operations 386
18 Service Configuration in the IMS 389 18.1 XDM architecture 389
18.2 Downloading an XML Document, Attribute, or Element 391
18.3 Directory Retrieval 393
18.4 Data Search with XDM 397
18.5 Subscribing to Changes in XML Documents 403
19 The Presence Service on the Internet 405 19.1 Overview of the Presence Service 405
19.1.1 The pres URI 407
19.2 The Presence Life Cycle 407
19.3 Presence Subscriptions and Notifications 409
19.4 Presence Publication 412
19.5 Presence Information Data Format (PIDF) 412
19.5.1 Contents of the PIDF 413
19.6 The Presence Data Model for SIP 414
19.7 Mapping the SIP Presence Data Model to the PIDF 416
19.8 Rich PIDF 416
19.8.1 Contents of the RPID 417
19.9 CIPID 419
19.10 Timed Presence Extension to the PIDF 419
19.11 Presence Capabilities 421
19.11.1 Service Capabilities 423
19.11.2 Device Capabilities 424
19.11.3 An Example of the Presence Capabilities Document 424
19.12 Geographical Location in Presence 424
19.13 Watcher Information 427
19.14 Watcher Authorization: Presence Authorization Rules 430
19.14.1 Common Policy 430
19.14.2 Presence Authorization Policy Documents 431