summaryrefslogtreecommitdiffstats
path: root/MobileL3_v13.4.0_CNL113832_LATEST/src/MobileL3_MM_Types.ttcn
blob: 56f8553b9867765df48a9a16566eff14b0b70e92 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
///////////////////////////////////////////////////////////////////////////////
//                                                                           //
// Copyright Test Competence Center (TCC) ETH 2016                           //
//                                                                           //
// The copyright to the computer  program(s) herein  is the property of TCC. //
// The program(s) may be used and/or copied only with the written permission //
// of TCC or in accordance with  the terms and conditions  stipulated in the //
// agreement/contract under which the program(s) has been supplied.          //
//                                                                           //
///////////////////////////////////////////////////////////////////////////////
//
//  File:               MobileL3_MM_Types.ttcn
//  Rev:                R1B
//  Prodnr:             CNL 113 832
//  Contact:            http://ttcn.ericsson.se
//  Reference:          3GPP TS 24.008 v13.4.0


module  MobileL3_MM_Types
{

import from General_Types           all;
import from MobileL3_CommonIE_Types all;

//============================================================================
// 24.008/ 10.5.3  Mobility Management information elements
//============================================================================

//10.5.3.1  AuthenticationParRAND
//**********************************************************************
type record AuthenticationParameterRANDTV
{
  OCT1               elementIdentifier,
  OCT16              randValue
} with { variant "PRESENCE (elementIdentifier = '21'O)"; };

//10.5.3.1.1 Authentication Par AUTN (UMTS auth. ch. only)
//**********************************************************************
type record AuthenticationParameterAUTNTLV
{
  OCT1               elementIdentifier,
  LIN1               lengthIndicator,
  OCT16              autnValue
} with { variant (lengthIndicator) "LENGTHTO (autnValue)"};

//10.5.3.2 Authentication Response parameter
//**********************************************************************
type record  AuthenticationResponseParameterTV
{
  OCT1               elementIdentifier,
  OCT4               valueField   length (4)
} with { variant "PRESENCE (elementIdentifier = '22'O)"; };

//10.5.3.2.1 Authentication Response parameter (extension)
//**********************************************************************
type record AuthenticationResponseParameterUMTSTLV
{
  OCT1               elementIdentifier,
  LIN1               lengthIndicator,
  octetstring        valueField     length (1..12)
} with { variant (lengthIndicator) "LENGTHTO (valueField)"};


//10.5.3.2.2 Authentication Failure parameter (UMTS authentication challenge only)
//**********************************************************************
type record AuthenticationFailureParametersTLV
{
  OCT1               elementIdentifier,
  LIN1               lengthIndicator,
  octetstring        valueField     length (14)
} with { variant "PRESENCE (elementIdentifier = '30'O)";
         variant (lengthIndicator) "LENGTHTO (valueField)"};

//10.5.3.5 Location Update Type
//****************************************************************************
type record LocationUpdatingType
{
  BIT2               lut, // LU  Normal  (00)
                          // LU  Periodic  (01)
                          // Attach  IMSI  (10)
                          // reserved    (11)
  BIT1               spare1_1, // 0
  BIT1               fop   // Follow Pending on (1), not (0)
};

//10.5.3.5a Network Name
//****************************************************************************
type record  NetworkNameTLV
{
  BIT7               elementIdentifier,
  BIT1               spare1,
  LIN1               lengthIndicator,
  NetworkNameV       valueField
} with { variant (lengthIndicator) "LENGTHTO (valueField)"};


type record  NetworkNameV
{
  BIT3               nSpareBits,
  BIT1               addCI,
  BIT3               codingScheme,
  BIT1               ext1, //'1'B
  octetstring        textString //     length (0..infinity)
  // actually the upper limit depends on the max size of the PDU, see 44.006
};

//10.5.3.7 Follow-on Proceed
//****************************************************************************
type Type2 FollowOnProceed; //'A1'O

//10.5.3.8 TimeZone
//****************************************************************************
type record TimeZoneTV
{
  BIT7               elementIdentifier,
  BIT1               spare,
  TimeZoneV          valueField
} with { variant "PRESENCE (elementIdentifier = '1000110'B)"; };  //'46'O  7 bits

type record TimeZoneV
{
  OCT1               timeZone
};

//10.5.3.9 Time Zone And Time
//****************************************************************************
type record TimeZoneAndTimeTV
{
  BIT7               elementIdentifier,
  BIT1               spare,
  TimeZoneAndTimeV   valueField
} with { variant "PRESENCE (elementIdentifier = '1000111'B)"; };  //'47'O  7 bits;


type record TimeZoneAndTimeV
{
  OCT1               year,
  OCT1               month,
  OCT1               day,
  OCT1               hour,
  OCT1               minute,
  OCT1               second,
  OCT1               timeZone
};

//10.5.3.10 CTS permission
//**********************************************************************
type Type2 CTS_Permission;

//10.5.3.11 LSA identifier (Localised Service Area)
//**********************************************************************
type record  LSA_IdentifierTLV
{
  BIT7               elementIdentifier,
  BIT1               spare,
  LIN1               lengthIndicator,
  LSA_IdentifierV    valueField
} with { variant "PRESENCE (elementIdentifier = '1001000'B)";  //'48'O  7 bits
         variant (lengthIndicator) "LENGTHTO (valueField)"};

type record LSA_IdentifierV
{
  octetstring lsa_id length (0..3)
};

//10.5.3.12 Daylight Saving Time
//**********************************************************************
type record DaylightSavingTimeTLV
{
  OCT1               elementIdentifier,
  LIN1               lengthIndicator,
  DaylightSavingTimeV valueField
} with { variant "PRESENCE (elementIdentifier = '49'O)";
         variant (lengthIndicator) "LENGTHTO (valueField)"};

type record DaylightSavingTimeV
{
  BIT2               valueField,
  BIT6               spare     // Shall be set to 000000
};

//10.5.3.13 Emergency Number List
//**********************************************************************
type record EmergencyNumberListTLV
{
  OCT1                 elementIdentifier,
  LIN1                 lengthIndicator,
  EmergencyNumberListV emergencyNumberListV
} with { variant "PRESENCE (elementIdentifier = '34'O)";
         variant (lengthIndicator) "LENGTHTO (emergencyNumberListV)"};

type record of EmergencyNumber EmergencyNumberListV

type record EmergencyNumber
{
  LIN1                     lengthIndicator,
  EmergencyServiceCategory emergencyServiceCategory,
  hexstring                emergencyNumber        length (1..44)
} with { variant (lengthIndicator) "LENGTHTO (emergencyServiceCategory,emergencyNumber)";
         variant "PADDING(yes)";
         variant "PADDING_PATTERN('1111'B)"};

type record EmergencyServiceCategory
{
  BIT5               valueFiled,
  BIT3               spare   //'000'B
};

//10.5.3.14 Additional Update Parameter
//moved into MobileL3_CommonIE_Types


//10.5.3.16 MM Timer
//**********************************************************************
type record MM_TimerTLV
{
  OCT1                 elementIdentifier,
  LIN1                 lengthIndicator,
  MM_TimerV            valueField
} with { variant "PRESENCE (elementIdentifier = '36'O)";
         variant (lengthIndicator) "LENGTHTO (valueField)"};

type record MM_TimerV
{
  BIT5               timerValue,
  BIT3               unit
}

//============================================================================
// 24.008/9.2 Messages for mobility management (MM)
//============================================================================

//**********************************************************************
// Security Messages
//**********************************************************************

// 9.2.1 Authentication Reject
//**********************************************************************
type record PDU_ML3_AuthenticationReject
{
  BIT6  messageType, // '010001'B  (AuthenticationReject)
  BIT2  nsd
};

// 9.2.2 Authentication Request
//**********************************************************************
type record PDU_ML3_AuthenticationRequest
{
  BIT6  messageType, // '010010'B
  BIT2  nsd,
  CipheringKeySequenceNumberV   cipheringKeySequenceNumber,
  BIT4                          spare2_4, // B'0000
  OCT16                         authenticationParRAND,
  AuthenticationParameterAUTNTLV  authenticationParAUTN    optional
      // added by ethcky acc to 10/155 17_1/APT 210 26/1 Uen Rev A
} with { variant "TAG (
                authenticationParAUTN, elementIdentifier = '20'O ) "};

// 9.2.3 Authentication Response
//****************************************************************************
type record PDU_ML3_AuthenticationResponse
{
  BIT6  messageType, // '010100'B  (AuthenticationResponse)
  BIT2  nsd,
  OCT4  authenticationParSRES, //10.5.3.2
  AuthenticationResponseParameterUMTSTLV  authenticationParSRESext  optional
} with { variant "TAG (authenticationParSRESext, elementIdentifier = '21'O )"};

// 9.2.3a Authentication Failure
//****************************************************************************
type record PDU_ML3_AuthenticationFailure
{
  BIT6  messageType, // '011100'B  (AuthenticationFailure)
  BIT2  nsd,
  OCT1  rejectCause, //10.5.3.6
  AuthenticationFailureParametersTLV  authenticationParFailure  optional
} with { variant "TAG (authenticationParFailure , elementIdentifier = '22'O ) " };

//**********************************************************************
// Mobility Management Message Types (TS 24.008/ chapter 9)
// Connection management (CM) messages
//**********************************************************************

// 9.2.4 CM Re-establishment Request
//**********************************************************************
type record PDU_ML3_CMReestablishmentRequest
{
  BIT6                          messageType,      // '101000'B
  BIT2                          nsd,
  CipheringKeySequenceNumberV   cipheringKeySequenceNumber,
  BIT4                          spare,
  MobileStationClassmark2_LV    mobileStationClassmark2,
  MobileIdentityLV              mobileIdentityLV,
  LocationAreaIdentification_TV locationAreaIdentification optional,
  DevicePropertiesTV            deviceProperties  optional  
} with { variant "TAG (locationAreaIdentification, elementIdentifier = '13'O;
                       deviceProperties,           elementIdentifier = '1101'B;) 
"};

// 9.2.5 CM Service Accept (NW->MS)
//**********************************************************************
type record PDU_ML3_CMServiceAccept
{
  BIT6  messageType, //    '100001'B
  BIT2  nsd
};

// 9.2.5a CMServicePrompt (NW->MS)
//**********************************************************************
type record PDU_ML3_CMServicePrompt
{
  BIT6  messageType, //    '100101'B
  BIT2  nsd,
  PdAndSapi pd_sapi
};

// 9.2.6 CMServiceReject (NW->MS)
//**********************************************************************
type record PDU_ML3_CMServiceReject
{
  BIT6  messageType, //    '100010'B
  BIT2  nsd,
  OCT1  rejectCause, //10.5.3.6
  MM_TimerTLV t3246_Value optional     
};

// 9.2.7 CM Service Abort (MS->NW to request the abortion)
//**********************************************************************
type record PDU_ML3_CMServiceAbort
{
  BIT6  messageType, //   '100011'B
  BIT2  nsd
};

// 9.2.8  Abort (NW->MS to initiate the abortion)
//**********************************************************************
type record PDU_ML3_Abort
{
  BIT6  messageType, //    '100010'B
  BIT2  nsd,
  OCT1  rejectCause //10.5.3.6
};

// 9.2.9 CM Service Request (MS->NW)
//**********************************************************************
type record PDU_ML3_CMServiceRequest
{
  BIT6  messageType,//    '100100'B
  BIT2  nsd,
  BIT4  cm_ServiceType,  // '0001'B establishment  MOC
                         // '0010'B Emergency Call
                         // '0100'SMS  B
                         // '1000'B SS activation
  CipheringKeySequenceNumberV cipheringKeySequenceNumber,
  MobileStationClassmark2_LV  mobileStationClassmark2,
  MobileIdentityLV            mobileIdentity,
  PriorityLevel_ML3           priorityLevel   optional,
  AdditionalUpdateParameterTV additionalUpdateParameterTV optional,
  DevicePropertiesTV          deviceProperties optional
} with { variant "TAG (priorityLevel,    elementIdentifier = '1000'B; 
                       deviceProperties, elementIdentifier = '1101'B;) 
"};

//9.2.10 Identity Request
//**********************************************************************
type record PDU_ML3_IdentityRequest
{
  BIT6  messageType, //   '011000'B ( IdentityRequest )
  BIT2  nsd,
  BIT3  identityType,  // IMSI:'001'B IMEI:'010'B IMEISV:'011'B
                       //(TMSI:'100'B not allowed?) 10.5.3.4
  BIT5  spare1_5       // '00000'B
};

//9.2.11 Identity Response
//**********************************************************************
type record PDU_ML3_IdentityResponse
{
  BIT6  messageType,  //    '011001'B (IdentityResponse)
  BIT2  nsd,
  MobileIdentityLV  mobileIdentityLV,
  P_TMSI_TypeTV     p_TMSI_TypeTV optional,
  RoutingAreaIdentification2TLV routingAreaIdentification2TLV optional,
  P_TMSISignature2TLV p_TMSISignature2TLV optional
};

//9.2.12 IMSI Detach Indication
//**********************************************************************
type record PDU_ML3_IMSI_DetachIndication
{
   BIT6  messageType, //    '000001'IMSI Detach Indication
   BIT2  nsd,
   MobileStationClassmark1_V    mobileStationClassmark1,
   MobileIdentityLV             mobileIdentityLV
};

//****************************************************************************
// 24.008/9 Mobility Management message contents
//****************************************************************************

// 9.2.13 Location Update Accept
//****************************************************************************
type record PDU_ML3_LocationUpdateAccept
{
  BIT6  messageType, // '000010'B  (LocationUpdateRequest)
  BIT2  nsd,
  LocationAreaIdentification_V  locationAreaIdentification,
  MobileIdentityTLV             mobileIdentityTLV           optional,
  Type2                         followOnProceed             optional,
  CTS_Permission                cTS_Permission              optional,
  PLMNListTLV                   equivalentPLMNs             optional,
  EmergencyNumberListTLV        emergencyNumberList         optional,
  GPRSTimer3TLV                 perMS_T3212                 optional
} with { variant "TAG ( mobileIdentityTLV,  elementIdentifier = '0010111'B;  //'17'O;
                        followOnProceed,    elementIdentifier = 'A1'O;
                        cTS_Permission,     elementIdentifier = 'A2'O;
                        equivalentPLMNs,    elementIdentifier = '1001010'B;  //'4A'O;
                        emergencyNumberList,  elementIdentifier = '34'O;) "};

// 9.2.14 Location Update Reject (NW->MS)
//****************************************************************************
type record PDU_ML3_LocationUpdateReject
{
  BIT6  messageType,  // '000100'B (LocationUpdateReject)
  BIT2  nsd,
  OCT1  rejectCause,   // see 10.5.3.6
  MM_TimerTLV  t3246_Value optional
};

//9.2.15 Location Update Request (MS->NW)
//****************************************************************************
type record PDU_ML3_LocationUpdateRequest
{
  BIT6  messageType, // B'_001000  (LocationUpdateRequest)
  BIT2  nsd,
  LocationUpdatingType               locationUpdatingType,
  CipheringKeySequenceNumberV        cipheringKeySequenceNumber,
  LocationAreaIdentification_V       locationAreaIdentification,
  MobileStationClassmark1_V          mobileStationClassmark1,
  MobileIdentityLV                   mobileIdentityLV,
  ClassmarkInformationType2_forUMTS  classmarkInformationType2_forUMTS  optional,
  AdditionalUpdateParameterTV        additionalUpdateParameterTV        optional,
  DevicePropertiesTV                 deviceProperties                   optional,
  MS_NetworkFeatureSupportTV         mS_NetworkFeatureSupport           optional
} with {
  variant "TAG (
    deviceProperties,                elementIdentifier = '1101'B;
    mS_NetworkFeatureSupport,        elementIdentifier = '1110'B;  //E
  )"
};

//9.2.15a MM information
//****************************************************************************
type record PDU_ML3_MMInformation
{
  BIT6  messageType,    //
  BIT2  nsd,
  NetworkNameTLV        fullNetworkName     optional,
  NetworkNameTLV        shortNetworkName    optional,
  TimeZoneTV            localtimeZone       optional,
  TimeZoneAndTimeTV     univTime            optional,
  LSA_IdentifierTLV     lSAIdentity         optional,
  DaylightSavingTimeTLV networkDST          optional
} with { variant "TAG (
              fullNetworkName,  elementIdentifier = '1000011'B;   // '43'O;
              shortNetworkName, elementIdentifier = '1000101'B;   // '45'O;
              localtimeZone,    elementIdentifier = '1000110'B;   // '46'O;
              univTime,         elementIdentifier = '1000111'B;   // '47'O;
              lSAIdentity,      elementIdentifier = '1001000'B;   //' 48'O;
              networkDST,       elementIdentifier = '49'O;)"};

//9.2.16 MM Status
//****************************************************************************
type record PDU_ML3_MMStatus
{
  BIT6  messageType,
  BIT2  nsd,
  OCT1  rejectCause //10.5.3.6
 };

//9.2.17 TMSI reallocation command (NW->MS)
//****************************************************************************
type record PDU_ML3_TMSI_ReallocationCommand
{
  BIT6  messageType,    // '011010'B
  BIT2  nsd,
  LocationAreaIdentification_V  locationAreaIdentification,
  MobileIdentityLV              mobileIdentity
};

//9.2.18 TMSI reallocation complete (MS->NW)
//****************************************************************************
type record PDU_ML3_TMSI_ReallocationComplete
{
  BIT6  messageType,    //  '011011'B
  BIT2  nsd
};

//9.2.19 MM Null (MS->NW)
//****************************************************************************
type record PDU_ML3_MMNull
{
  BIT6  messageType,    //  '110000'B
  BIT2  nsd
};


// ***************************************************************************
// *     Mobility Management Messages
// ***************************************************************************
// 24.008/ Table 10.2
type union PDU_ML3_MM
{
  PDU_ML3_IMSI_DetachIndication    imsiDetachIndication,
  PDU_ML3_LocationUpdateAccept     locationUpdateAccept,
  PDU_ML3_LocationUpdateReject     locationUpdateReject,
  PDU_ML3_LocationUpdateRequest    locationUpdateRequest,

  PDU_ML3_AuthenticationReject       authenticationReject,
  PDU_ML3_AuthenticationRequest      authenticationRequest,
  PDU_ML3_AuthenticationResponse     authenticationResponse,
  PDU_ML3_AuthenticationFailure      authenticationFailure,
  PDU_ML3_IdentityRequest            identityRequest,
  PDU_ML3_IdentityResponse           identityResponse,
  PDU_ML3_TMSI_ReallocationCommand   tmsiReallocCommand,
  PDU_ML3_TMSI_ReallocationComplete  tmsiReallocComplete,

  PDU_ML3_CMServiceAbort           cMServiceAbort,
  PDU_ML3_CMServiceAccept          cMServiceAccept,
  PDU_ML3_CMServiceReject          cMServiceReject,
  PDU_ML3_CMServiceRequest         cMServiceRequest,
  PDU_ML3_CMServicePrompt          cMServicePrompt,
  PDU_ML3_CMReestablishmentRequest cMReEstablReq,
  PDU_ML3_Abort                    abort,

  PDU_ML3_MMNull                   mMNull,
  PDU_ML3_MMStatus                 mMStatus,
  PDU_ML3_MMInformation            mMInformation
} with { variant "TAG (
                imsiDetachIndication,   messageType ='000001'B; //registration msgs
                locationUpdateAccept,   messageType ='000010'B;
                locationUpdateReject,   messageType ='000100'B;
                locationUpdateRequest,  messageType ='001000'B;

                authenticationReject,   messageType ='010001'B;//security msgs
                authenticationRequest,  messageType ='010010'B;
                authenticationResponse, messageType ='010100'B;
                authenticationFailure,  messageType ='011100'B;
                identityRequest,        messageType ='011000'B;
                identityResponse,       messageType ='011001'B;
                tmsiReallocCommand,     messageType ='011010'B;
                tmsiReallocComplete,    messageType ='011011'B;

                cMServiceAbort,         messageType ='100011'B; //conn, mgmt
                cMServiceAccept,        messageType ='100001'B;
                cMServiceReject,        messageType ='100010'B;
                cMServiceRequest,       messageType ='100100'B;
                cMServicePrompt,        messageType ='100101'B;
                cMReEstablReq,          messageType ='101000'B;
                abort,                  messageType ='101001'B;

                mMNull,               messageType ='110000'B; //misc
                mMStatus,             messageType ='110001'B;
                mMInformation,        messageType ='110010'B;
              )"};

}//end of module
with {
extension "version R1B"
encode "RAW"
}