blob: 26ded294a7a574834fb40e59d488c373d0f7d8ba [file] [log] [blame]
Philipp Maier08902cf2024-03-04 10:32:55 +01001/* SGP32 Templates in TTCN-3
2 *
3 * Author: Philipp Maier <pmaier@sysmocom.de> / sysmocom - s.f.m.c. GmbH
4 *
5 * Released under the terms of GNU General Public License, Version 2 or
6 * (at your option) any later version.
7 *
8 * SPDX-License-Identifier: GPL-2.0-or-later
9 */
10
11module SGP32Definitions_Templates {
12
13import from SGP32Definitions all;
14import from SGP32Definitions_Types all;
15
16import from RSPDefinitions all;
17import from RSPDefinitions_Types all;
18import from RSPDefinitions_Templates all;
19
20import from PKIX1Explicit88 all;
21import from PKIX1Explicit88_Templates all;
22import from PKIX1Explicit88_Types all;
23
24/* GSMA SGP.32, section 6.3.2.1 */
25template (present) EsipaMessageFromEimToIpa
26tr_initiateAuthenticationResponseEsipa(template (present) octetstring euiccChallenge := ?,
27 template (present) universal charstring serverAddress := ?) := {
28 initiateAuthenticationResponseEsipa := {
29 initiateAuthenticationOkEsipa := {
30 transactionId := *,
Philipp Maier746f43e2024-04-29 12:17:12 +020031 serverSigned1 := tr_serverSigned1(euiccChallenge := euiccChallenge, serverAddress := serverAddress),
Philipp Maier08902cf2024-03-04 10:32:55 +010032 serverSignature1 := ?,
33 euiccCiPKIdToBeUsed := ?,
34 serverCertificate := ?,
35 matchingId := *,
36 ctxParams1 := *
37 }
38 }
39}
40
41template (value) EsipaMessageFromEimToIpa
42ts_initiateAuthenticationResponseEsipa(template (value) octetstring euiccChallenge := '00112233445566778899AABBCCDDEEFF'O,
43 template (value) universal charstring serverAddress := "smdp.example.com") := {
44 initiateAuthenticationResponseEsipa := {
45 initiateAuthenticationOkEsipa := {
46 transactionId := omit,
Philipp Maier746f43e2024-04-29 12:17:12 +020047 serverSigned1 := ts_serverSigned1(euiccChallenge := euiccChallenge, serverAddress := serverAddress),
Philipp Maier08902cf2024-03-04 10:32:55 +010048 serverSignature1 := '01020304'O,
49 euiccCiPKIdToBeUsed := 'F54172BDF98A95D65CBEB88A38A1C11D800A85C3'O, /* NIST */
50 serverCertificate := ts_cert_s_sm_dpauth_nist,
51// serverCertificate := ts_cert_s_sm_dpauth_brp,
52// serverCertificate := ts_cert_s_sm_dp2auth_nist,
53// serverCertificate := ts_cert_s_sm_dp2auth_brp,
54 matchingId := omit,
55 ctxParams1 := omit
56 }
57 }
58}
59
60/* GSMA SGP.32, section 6.3.2.1 */
61template (present) EsipaMessageFromIpaToEim
62tr_initiateAuthenticationRequestEsipa(template (present) octetstring euiccChallenge := ?) := {
63 initiateAuthenticationRequestEsipa := {
64 euiccChallenge := euiccChallenge,
65 smdpAddress := *,
66 euiccInfo1 := *
67 }
68}
69template (value) EsipaMessageFromIpaToEim
Philipp Maiere73a6a32024-04-25 15:48:37 +020070ts_initiateAuthenticationRequestEsipa(template (value) octetstring euiccChallenge := '00112233445566778899aabbccddeeff'O,
71 template (omit) charstring smdpAddress := "smdp.example.com",
72 template (omit) EUICCInfo1 euiccInfo1 := ts_EUICCInfo1) := {
Philipp Maier08902cf2024-03-04 10:32:55 +010073 initiateAuthenticationRequestEsipa := {
74 euiccChallenge := euiccChallenge,
Philipp Maiere73a6a32024-04-25 15:48:37 +020075 smdpAddress := smdpAddress,
76 euiccInfo1 := euiccInfo1
Philipp Maier08902cf2024-03-04 10:32:55 +010077 }
78}
79
80/* GSMA SGP.32, section 6.3.2.2 */
81template (present) EsipaMessageFromIpaToEim
82tr_authenticateClientRequestEsipa := {
83 authenticateClientRequestEsipa := {
84 transactionId := ?,
85 authenticateServerResponse := {
86 authenticateResponseOk := ?
87 }
88 }
89}
Philipp Maier916b5fa2024-04-30 11:34:09 +020090template (value) EsipaMessageFromIpaToEim
91ts_authenticateClientRequestEsipa(template (value) octetstring transactionId := 'ABCDEF'O) := {
92 authenticateClientRequestEsipa := {
93 transactionId := transactionId,
94 authenticateServerResponse := {
95 authenticateResponseOk := {
96 euiccSigned1 := ts_euiccSigned1,
97 euiccSignature1 := '1234567890'O,
98 euiccCertificate := ts_cert_eum_nist,
99 eumCertificate := ts_cert_s_sm_dpauth_nist
100 }
101 }
102 }
103}
Philipp Maier08902cf2024-03-04 10:32:55 +0100104
105/* GSMA SGP.32, section 6.3.2.2 */
106template (present) EsipaMessageFromEimToIpa
107tr_authenticateClientResponseEsipa_dse(template (present) octetstring transactionId := ?,
108 template (present) charstring activationCode := ?) := {
109 authenticateClientResponseEsipa := {
110 authenticateClientOkDSEsipa := {
111 transactionId := transactionId,
112 profileDownloadTrigger := {
113 profileDownloadData := {
114 activationCode := ?
115 },
116 eimTransactionId := *
117 }
118 }
119 }
120}
121template (value) EsipaMessageFromEimToIpa
122ts_authenticateClientResponseEsipa_dse(template (value) octetstring transactionId := 'ABCDEF'O,
123 template (value) charstring activationCode := "1$SMDP.EXAMPLE.COM$$1.3.6.1.4.1.31746") := {
124 authenticateClientResponseEsipa := {
125 authenticateClientOkDSEsipa := {
126 transactionId := transactionId,
127 profileDownloadTrigger := {
128 profileDownloadData := {
129 activationCode := activationCode
130 },
131 eimTransactionId := omit
132 }
133 }
134 }
135}
136
137/* GSMA SGP.32, section 6.3.2.2 */
138template (present) EsipaMessageFromEimToIpa
139tr_authenticateClientResponseEsipa_dpe(template (present) octetstring transactionId := ?) := {
140 authenticateClientResponseEsipa := {
141 authenticateClientOkDPEsipa := {
142 transactionId := transactionId,
143 profileMetaData := *,
144 smdpSigned2 := {
145 transactionId := ?,
146 ccRequiredFlag := ?,
147 bppEuiccOtpk := *
148 },
149 smdpSignature2 := ?,
150 smdpCertificate := ?,
151 hashCc := *
152 }
153 }
154}
155template (value) EsipaMessageFromEimToIpa
156ts_authenticateClientResponseEsipa_dpe(template (value) octetstring transactionId := 'ABCDEF'O) := {
157 authenticateClientResponseEsipa := {
158 authenticateClientOkDPEsipa := {
159 transactionId := transactionId,
160 profileMetaData := omit,
161 smdpSigned2 := {
162 transactionId := transactionId,
163 ccRequiredFlag := false,
164 bppEuiccOtpk := omit
165 },
166 smdpSignature2 := 'AAAAAAAAAAAAAAAAAAAAAAAA'O,
167 smdpCertificate := ts_cert_s_sm_dpauth_nist,
168// smdpCertificate := ts_cert_s_sm_dpauth_brp,
169// smdpCertificate := ts_cert_s_sm_dp2auth_nist,
170// smdpCertificate := ts_cert_s_sm_dp2auth_brp,
171 hashCc := omit
172 }
173 }
174}
175
176/* GSMA SGP.32, section 6.3.2.6 */
177template (present) EsipaMessageFromIpaToEim
178tr_getEimPackageRequest(template (present) octetstring eidValue := ?) := {
179 getEimPackageRequest := {
180 eidValue := eidValue,
181 notifyStateChange := *,
182 rPLMN := *
183 }
184}
185template (value) EsipaMessageFromIpaToEim
186ts_getEimPackageRequest(template (value) octetstring eidValue) := {
187 getEimPackageRequest := {
188 eidValue := eidValue,
189 notifyStateChange := omit,
190 rPLMN := omit
191 }
192}
193
194/* GSMA SGP.32, section 6.3.2.6 and 2.11.1.3 */
195template (present) EsipaMessageFromEimToIpa
196tr_getEimPackageResponse_dnlTrigReq(template (present) charstring activationCode := ?) := {
197 getEimPackageResponse := {
198 profileDownloadTriggerRequest := {
199 profileDownloadData := {
200 activationCode := activationCode
201 },
202 eimTransactionId := *
203 }
204 }
205}
206template (value) EsipaMessageFromEimToIpa
207ts_getEimPackageResponse_dnlTrigReq(template (value) charstring activationCode := "1$SMDP.EXAMPLE.COM$$1.3.6.1.4.1.31746") := {
208 getEimPackageResponse := {
209 profileDownloadTriggerRequest := {
210 profileDownloadData := {
211 activationCode := activationCode
212 },
213 eimTransactionId := omit
214 }
215 }
216}
217
218/* GSMA SGP.32, section 6.3.2.6 and 2.11.1.2 */
219template (present) EsipaMessageFromEimToIpa
220tr_getEimPackageResponse_euiccDataReq := {
221 getEimPackageResponse := {
222 ipaEuiccDataRequest := {
223 tagList := ?,
224 euiccCiPKId := *,
225 searchCriteria := *
226 }
227 }
228}
229template (value) EsipaMessageFromEimToIpa
230ts_getEimPackageResponse_euiccDataReq := {
231 getEimPackageResponse := {
232 ipaEuiccDataRequest := {
233 tagList := '80BF20BF228384A5A688A9BF2B'O,
234 euiccCiPKId := omit,
235 searchCriteria := omit
236 }
237 }
238}
239
240/* GSMA SGP.32, section 6.3.2.6 */
241template (present) EsipaMessageFromEimToIpa
242tr_getEimPackageResponse_eimPkgErrUndef := {
243 getEimPackageResponse := {
244 eimPackageError := ?
245 }
246}
247template (value) EsipaMessageFromEimToIpa
248ts_getEimPackageResponse_eimPkgErrUndef := {
249 getEimPackageResponse := {
250 eimPackageError := 127
251 }
252}
253
254/* GSMA SGP.32, section 6.3.2.6 */
255template (value) EsipaMessageFromEimToIpa
256ts_getEimPackageResponse_euiccPkgReq := {
257 getEimPackageResponse := {
258 euiccPackageRequest := {
259 euiccPackageSigned := {
260 eimId := "myEim",
261 eidValue := '00112233445566778899AABBCCDDEEFF'O,
262 counterValue := 123,
263 transactionId := omit,
264 euiccPackage := {
265 psmoList := {
266 {
Philipp Maierac10cee2024-04-10 15:51:47 +0200267 enable := {
268 iccid := '123456789ABCDEFFAAAA'O,
269 rollbackFlag := NULL
Philipp Maier08902cf2024-03-04 10:32:55 +0100270 }
271 }
272 }
273 }
274 },
275 eimSignature := '1234567890'O
276 }
277 }
278}
279
280/* GSMA SGP.32, section 6.3.2.5 */
281template (present) EsipaMessageFromIpaToEim
282tr_cancelSessionRequestEsipa := {
283 cancelSessionRequestEsipa := {
284 transactionId := ?,
285 cancelSessionResponse := {
286 cancelSessionResponseOk := tr_cancelSessionResponseOk
287 }
288 }
289}
290template (value) EsipaMessageFromIpaToEim
291ts_cancelSessionRequestEsipa := {
292 cancelSessionRequestEsipa := {
293 transactionId := 'AABBCC'O,
294 cancelSessionResponse := {
295 cancelSessionResponseOk := ts_cancelSessionResponseOk
296 }
297 }
298}
299
300/* GSMA SGP.32, section 6.3.2.5 */
301template (present) EsipaMessageFromEimToIpa
302tr_cancelSessionResponseEsipa := {
303 cancelSessionResponseEsipa := {
304 cancelSessionOk := {
305 /* This function has no output data */
306 }
307 }
308}
309template (value) EsipaMessageFromEimToIpa
310ts_cancelSessionResponseEsipa := {
311 cancelSessionResponseEsipa := {
312 cancelSessionOk := {
313 /* This function has no output data */
314 }
315 }
316}
317
318/* GSMA SGP.32, section 6.3.2.3 */
319template (present) EsipaMessageFromEimToIpa
320tr_getBoundProfilePackageResponseEsipa := {
321 getBoundProfilePackageResponseEsipa := {
322 getBoundProfilePackageOkEsipa := {
323 transactionId := *,
324 boundProfilePackage := tr_boundProfilePackage
325 }
326 }
327}
328template (value) EsipaMessageFromEimToIpa
329ts_getBoundProfilePackageResponseEsipa := {
330 getBoundProfilePackageResponseEsipa := {
331 getBoundProfilePackageOkEsipa := {
332 transactionId := omit,
333 boundProfilePackage := ts_boundProfilePackage
334 }
335 }
336}
337
338/* GSMA SGP.32, section 5.9.1 */
339template (present) EuiccPackageResult
340tr_euiccPackageResult := {
341 euiccPackageResultSigned := {
342 euiccPackageResultDataSigned := {
343 eimId := ?,
344 counterValue := ?,
345 transactionId := *,
346 seqNumber := ?,
347 euiccResult := ?
348 },
349 euiccSignEPR := ?
350 }
351}
352template (value) EuiccPackageResult
353ts_euiccPackageResult := {
354 euiccPackageResultSigned := {
355 euiccPackageResultDataSigned := {
356 eimId := "myEim",
357 counterValue := 333,
358 transactionId := omit,
359 seqNumber := 1234,
360 euiccResult := {
361 {
Philipp Maierac10cee2024-04-10 15:51:47 +0200362 enableResult := 0
Philipp Maier08902cf2024-03-04 10:32:55 +0100363 }
364 }
365 },
366 euiccSignEPR := 'AABBCCDDEEFF'O
367 }
368}
369
370/* GSMA SGP.32, section 6.3.2.7 */
Philipp Maiere4de06e2024-04-10 15:58:22 +0200371template (present) EsipaMessageFromIpaToEim
372tr_provideEimPackageResult_ePRAndNotif := {
373 provideEimPackageResult := {
374 ePRAndNotifications := {
375 euiccPackageResult := ?,
376 notificationList := ?
377 }
378 }
379}
Philipp Maier08902cf2024-03-04 10:32:55 +0100380template (present) EsipaMessageFromEimToIpa
Philipp Maier88f24812024-04-10 15:55:51 +0200381tr_provideEimPackageResultResponse_eimAck := {
Philipp Maier08902cf2024-03-04 10:32:55 +0100382 provideEimPackageResultResponse := {
383 eimAcknowledgements := *
384 }
385}
386template (value) EsipaMessageFromEimToIpa
Philipp Maier88f24812024-04-10 15:55:51 +0200387ts_provideEimPackageResultResponse_eimAck(template (value) EimAcknowledgements eimAcknowledgements := {}) := {
Philipp Maier08902cf2024-03-04 10:32:55 +0100388 provideEimPackageResultResponse := {
389 eimAcknowledgements := eimAcknowledgements
390 }
391}
392
393/* GSMA SGP.32, section 2.11.1.2 */
394template (present) GetCertsResponse
395tr_getCertsResponse := {
396 certs := {
397 eumCertificate := ?,
398 euiccCertificate := ?
399 }
400}
401template (value) GetCertsResponse
402ts_getCertsResponse := {
403 certs := {
404 eumCertificate := ts_cert_s_sm_dpauth_nist,
405 euiccCertificate := ts_cert_eum_nist
406 }
407}
408
409/* GSMA SGP.32, section 5.9.18 */
410template (present) GetEimConfigurationDataResponse
411tr_getEimConfigurationDataResponse := {
412 eimConfigurationDataList := ?
413}
414template (value) GetEimConfigurationDataResponse
415ts_getEimConfigurationDataResponse(template (value) charstring eimFqdn := "127.0.0.1") := {
416 eimConfigurationDataList := {
417 {
418 eimId := "myEIM",
419 eimFqdn := eimFqdn,
420 eimIdType := omit,
421 counterValue := omit,
422 associationToken := 123,
423 eimPublicKeyData := omit,
424 trustedPublicKeyDataTls := omit,
425 eimSupportedProtocol := omit,
426 euiccCiPKId := omit
427 }
428 }
429}
430
431/* GSMA SGP.32, section 5.9.4 */
432template (present) AddInitialEimResponse
433tr_addInitialEimResponse := {
434 addInitialEimOk := ?
435}
436template (value) AddInitialEimResponse
Philipp Maierd9887d32024-04-10 15:48:05 +0200437ts_addInitialEimResponse := {
Philipp Maier08902cf2024-03-04 10:32:55 +0100438 addInitialEimOk := {
439 {
440 addOk := NULL
441 }
442 }
443}
444
Philipp Maier4a24fb02024-04-10 16:01:06 +0200445/* GSMA SGP.32, section 5.9.16 */
446template (present) ProfileRollbackRequest
447tr_profileRollbackRequest := {
448 refreshFlag := ?
449}
450template (value) ProfileRollbackRequest
451ts_profileRollbackRequest := {
452 refreshFlag := false
453}
454template (present) ProfileRollbackResponse
455tr_profileRollbackResponse := {
456 cmdResult := ?,
457 eUICCPackageResult := ?
458}
459template (value) ProfileRollbackResponse
460ts_profileRollbackResponse := {
461 cmdResult := 0,
462 eUICCPackageResult := {
463 euiccPackageResultSigned := {
464 euiccPackageResultDataSigned := {
465 eimId := "myEim",
466 counterValue := 333,
467 transactionId := omit,
468 seqNumber := 1234,
469 euiccResult := {
470 {
471 enableResult := 0
472 },
473 {
474 rollbackResult := 0
475 }
476 }
477 },
478 euiccSignEPR := 'AABBCCDDEEFF'O
479 }
480 }
481}
482
483
Philipp Maier978ab442024-04-10 15:46:45 +0200484}