blob: 36d77b43db2b16f1d047dd9ce3491b423fa474d0 [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 := *,
31 serverSigned1 := {
32 transactionId := ?,
33 euiccChallenge := euiccChallenge,
34 serverAddress := serverAddress,
35 serverChallenge := ?
36 },
37 serverSignature1 := ?,
38 euiccCiPKIdToBeUsed := ?,
39 serverCertificate := ?,
40 matchingId := *,
41 ctxParams1 := *
42 }
43 }
44}
45
46template (value) EsipaMessageFromEimToIpa
47ts_initiateAuthenticationResponseEsipa(template (value) octetstring euiccChallenge := '00112233445566778899AABBCCDDEEFF'O,
48 template (value) universal charstring serverAddress := "smdp.example.com") := {
49 initiateAuthenticationResponseEsipa := {
50 initiateAuthenticationOkEsipa := {
51 transactionId := omit,
52 serverSigned1 := {
53 transactionId := 'ABCDEF'O,
54 euiccChallenge := euiccChallenge,
55 serverAddress := "smdp.example.com",
56 serverChallenge := '01020304050607080910111213141516'O
57 },
58 serverSignature1 := '01020304'O,
59 euiccCiPKIdToBeUsed := 'F54172BDF98A95D65CBEB88A38A1C11D800A85C3'O, /* NIST */
60 serverCertificate := ts_cert_s_sm_dpauth_nist,
61// serverCertificate := ts_cert_s_sm_dpauth_brp,
62// serverCertificate := ts_cert_s_sm_dp2auth_nist,
63// serverCertificate := ts_cert_s_sm_dp2auth_brp,
64 matchingId := omit,
65 ctxParams1 := omit
66 }
67 }
68}
69
70/* GSMA SGP.32, section 6.3.2.1 */
71template (present) EsipaMessageFromIpaToEim
72tr_initiateAuthenticationRequestEsipa(template (present) octetstring euiccChallenge := ?) := {
73 initiateAuthenticationRequestEsipa := {
74 euiccChallenge := euiccChallenge,
75 smdpAddress := *,
76 euiccInfo1 := *
77 }
78}
79template (value) EsipaMessageFromIpaToEim
80ts_initiateAuthenticationRequestEsipa(template (value) octetstring euiccChallenge := '00112233445566778899aabbccddeeff'O) := {
81 initiateAuthenticationRequestEsipa := {
82 euiccChallenge := euiccChallenge,
83 smdpAddress := omit,
84 euiccInfo1 := omit
85 }
86}
87
88/* GSMA SGP.32, section 6.3.2.2 */
89template (present) EsipaMessageFromIpaToEim
90tr_authenticateClientRequestEsipa := {
91 authenticateClientRequestEsipa := {
92 transactionId := ?,
93 authenticateServerResponse := {
94 authenticateResponseOk := ?
95 }
96 }
97}
98/* TODO: create coresponding ts_ template */
99
100/* GSMA SGP.32, section 6.3.2.2 */
101template (present) EsipaMessageFromEimToIpa
102tr_authenticateClientResponseEsipa_dse(template (present) octetstring transactionId := ?,
103 template (present) charstring activationCode := ?) := {
104 authenticateClientResponseEsipa := {
105 authenticateClientOkDSEsipa := {
106 transactionId := transactionId,
107 profileDownloadTrigger := {
108 profileDownloadData := {
109 activationCode := ?
110 },
111 eimTransactionId := *
112 }
113 }
114 }
115}
116template (value) EsipaMessageFromEimToIpa
117ts_authenticateClientResponseEsipa_dse(template (value) octetstring transactionId := 'ABCDEF'O,
118 template (value) charstring activationCode := "1$SMDP.EXAMPLE.COM$$1.3.6.1.4.1.31746") := {
119 authenticateClientResponseEsipa := {
120 authenticateClientOkDSEsipa := {
121 transactionId := transactionId,
122 profileDownloadTrigger := {
123 profileDownloadData := {
124 activationCode := activationCode
125 },
126 eimTransactionId := omit
127 }
128 }
129 }
130}
131
132/* GSMA SGP.32, section 6.3.2.2 */
133template (present) EsipaMessageFromEimToIpa
134tr_authenticateClientResponseEsipa_dpe(template (present) octetstring transactionId := ?) := {
135 authenticateClientResponseEsipa := {
136 authenticateClientOkDPEsipa := {
137 transactionId := transactionId,
138 profileMetaData := *,
139 smdpSigned2 := {
140 transactionId := ?,
141 ccRequiredFlag := ?,
142 bppEuiccOtpk := *
143 },
144 smdpSignature2 := ?,
145 smdpCertificate := ?,
146 hashCc := *
147 }
148 }
149}
150template (value) EsipaMessageFromEimToIpa
151ts_authenticateClientResponseEsipa_dpe(template (value) octetstring transactionId := 'ABCDEF'O) := {
152 authenticateClientResponseEsipa := {
153 authenticateClientOkDPEsipa := {
154 transactionId := transactionId,
155 profileMetaData := omit,
156 smdpSigned2 := {
157 transactionId := transactionId,
158 ccRequiredFlag := false,
159 bppEuiccOtpk := omit
160 },
161 smdpSignature2 := 'AAAAAAAAAAAAAAAAAAAAAAAA'O,
162 smdpCertificate := ts_cert_s_sm_dpauth_nist,
163// smdpCertificate := ts_cert_s_sm_dpauth_brp,
164// smdpCertificate := ts_cert_s_sm_dp2auth_nist,
165// smdpCertificate := ts_cert_s_sm_dp2auth_brp,
166 hashCc := omit
167 }
168 }
169}
170
171/* GSMA SGP.32, section 6.3.2.6 */
172template (present) EsipaMessageFromIpaToEim
173tr_getEimPackageRequest(template (present) octetstring eidValue := ?) := {
174 getEimPackageRequest := {
175 eidValue := eidValue,
176 notifyStateChange := *,
177 rPLMN := *
178 }
179}
180template (value) EsipaMessageFromIpaToEim
181ts_getEimPackageRequest(template (value) octetstring eidValue) := {
182 getEimPackageRequest := {
183 eidValue := eidValue,
184 notifyStateChange := omit,
185 rPLMN := omit
186 }
187}
188
189/* GSMA SGP.32, section 6.3.2.6 and 2.11.1.3 */
190template (present) EsipaMessageFromEimToIpa
191tr_getEimPackageResponse_dnlTrigReq(template (present) charstring activationCode := ?) := {
192 getEimPackageResponse := {
193 profileDownloadTriggerRequest := {
194 profileDownloadData := {
195 activationCode := activationCode
196 },
197 eimTransactionId := *
198 }
199 }
200}
201template (value) EsipaMessageFromEimToIpa
202ts_getEimPackageResponse_dnlTrigReq(template (value) charstring activationCode := "1$SMDP.EXAMPLE.COM$$1.3.6.1.4.1.31746") := {
203 getEimPackageResponse := {
204 profileDownloadTriggerRequest := {
205 profileDownloadData := {
206 activationCode := activationCode
207 },
208 eimTransactionId := omit
209 }
210 }
211}
212
213/* GSMA SGP.32, section 6.3.2.6 and 2.11.1.2 */
214template (present) EsipaMessageFromEimToIpa
215tr_getEimPackageResponse_euiccDataReq := {
216 getEimPackageResponse := {
217 ipaEuiccDataRequest := {
218 tagList := ?,
219 euiccCiPKId := *,
220 searchCriteria := *
221 }
222 }
223}
224template (value) EsipaMessageFromEimToIpa
225ts_getEimPackageResponse_euiccDataReq := {
226 getEimPackageResponse := {
227 ipaEuiccDataRequest := {
228 tagList := '80BF20BF228384A5A688A9BF2B'O,
229 euiccCiPKId := omit,
230 searchCriteria := omit
231 }
232 }
233}
234
235/* GSMA SGP.32, section 6.3.2.6 */
236template (present) EsipaMessageFromEimToIpa
237tr_getEimPackageResponse_eimPkgErrUndef := {
238 getEimPackageResponse := {
239 eimPackageError := ?
240 }
241}
242template (value) EsipaMessageFromEimToIpa
243ts_getEimPackageResponse_eimPkgErrUndef := {
244 getEimPackageResponse := {
245 eimPackageError := 127
246 }
247}
248
249/* GSMA SGP.32, section 6.3.2.6 */
250template (value) EsipaMessageFromEimToIpa
251ts_getEimPackageResponse_euiccPkgReq := {
252 getEimPackageResponse := {
253 euiccPackageRequest := {
254 euiccPackageSigned := {
255 eimId := "myEim",
256 eidValue := '00112233445566778899AABBCCDDEEFF'O,
257 counterValue := 123,
258 transactionId := omit,
259 euiccPackage := {
260 psmoList := {
261 {
Philipp Maierac10cee2024-04-10 15:51:47 +0200262 enable := {
263 iccid := '123456789ABCDEFFAAAA'O,
264 rollbackFlag := NULL
Philipp Maier08902cf2024-03-04 10:32:55 +0100265 }
266 }
267 }
268 }
269 },
270 eimSignature := '1234567890'O
271 }
272 }
273}
274
275/* GSMA SGP.32, section 6.3.2.5 */
276template (present) EsipaMessageFromIpaToEim
277tr_cancelSessionRequestEsipa := {
278 cancelSessionRequestEsipa := {
279 transactionId := ?,
280 cancelSessionResponse := {
281 cancelSessionResponseOk := tr_cancelSessionResponseOk
282 }
283 }
284}
285template (value) EsipaMessageFromIpaToEim
286ts_cancelSessionRequestEsipa := {
287 cancelSessionRequestEsipa := {
288 transactionId := 'AABBCC'O,
289 cancelSessionResponse := {
290 cancelSessionResponseOk := ts_cancelSessionResponseOk
291 }
292 }
293}
294
295/* GSMA SGP.32, section 6.3.2.5 */
296template (present) EsipaMessageFromEimToIpa
297tr_cancelSessionResponseEsipa := {
298 cancelSessionResponseEsipa := {
299 cancelSessionOk := {
300 /* This function has no output data */
301 }
302 }
303}
304template (value) EsipaMessageFromEimToIpa
305ts_cancelSessionResponseEsipa := {
306 cancelSessionResponseEsipa := {
307 cancelSessionOk := {
308 /* This function has no output data */
309 }
310 }
311}
312
313/* GSMA SGP.32, section 6.3.2.3 */
314template (present) EsipaMessageFromEimToIpa
315tr_getBoundProfilePackageResponseEsipa := {
316 getBoundProfilePackageResponseEsipa := {
317 getBoundProfilePackageOkEsipa := {
318 transactionId := *,
319 boundProfilePackage := tr_boundProfilePackage
320 }
321 }
322}
323template (value) EsipaMessageFromEimToIpa
324ts_getBoundProfilePackageResponseEsipa := {
325 getBoundProfilePackageResponseEsipa := {
326 getBoundProfilePackageOkEsipa := {
327 transactionId := omit,
328 boundProfilePackage := ts_boundProfilePackage
329 }
330 }
331}
332
333/* GSMA SGP.32, section 5.9.1 */
334template (present) EuiccPackageResult
335tr_euiccPackageResult := {
336 euiccPackageResultSigned := {
337 euiccPackageResultDataSigned := {
338 eimId := ?,
339 counterValue := ?,
340 transactionId := *,
341 seqNumber := ?,
342 euiccResult := ?
343 },
344 euiccSignEPR := ?
345 }
346}
347template (value) EuiccPackageResult
348ts_euiccPackageResult := {
349 euiccPackageResultSigned := {
350 euiccPackageResultDataSigned := {
351 eimId := "myEim",
352 counterValue := 333,
353 transactionId := omit,
354 seqNumber := 1234,
355 euiccResult := {
356 {
Philipp Maierac10cee2024-04-10 15:51:47 +0200357 enableResult := 0
Philipp Maier08902cf2024-03-04 10:32:55 +0100358 }
359 }
360 },
361 euiccSignEPR := 'AABBCCDDEEFF'O
362 }
363}
364
365/* GSMA SGP.32, section 6.3.2.7 */
Philipp Maier08902cf2024-03-04 10:32:55 +0100366template (present) EsipaMessageFromEimToIpa
Philipp Maier88f24812024-04-10 15:55:51 +0200367tr_provideEimPackageResultResponse_eimAck := {
Philipp Maier08902cf2024-03-04 10:32:55 +0100368 provideEimPackageResultResponse := {
369 eimAcknowledgements := *
370 }
371}
372template (value) EsipaMessageFromEimToIpa
Philipp Maier88f24812024-04-10 15:55:51 +0200373ts_provideEimPackageResultResponse_eimAck(template (value) EimAcknowledgements eimAcknowledgements := {}) := {
Philipp Maier08902cf2024-03-04 10:32:55 +0100374 provideEimPackageResultResponse := {
375 eimAcknowledgements := eimAcknowledgements
376 }
377}
378
379/* GSMA SGP.32, section 2.11.1.2 */
380template (present) GetCertsResponse
381tr_getCertsResponse := {
382 certs := {
383 eumCertificate := ?,
384 euiccCertificate := ?
385 }
386}
387template (value) GetCertsResponse
388ts_getCertsResponse := {
389 certs := {
390 eumCertificate := ts_cert_s_sm_dpauth_nist,
391 euiccCertificate := ts_cert_eum_nist
392 }
393}
394
395/* GSMA SGP.32, section 5.9.18 */
396template (present) GetEimConfigurationDataResponse
397tr_getEimConfigurationDataResponse := {
398 eimConfigurationDataList := ?
399}
400template (value) GetEimConfigurationDataResponse
401ts_getEimConfigurationDataResponse(template (value) charstring eimFqdn := "127.0.0.1") := {
402 eimConfigurationDataList := {
403 {
404 eimId := "myEIM",
405 eimFqdn := eimFqdn,
406 eimIdType := omit,
407 counterValue := omit,
408 associationToken := 123,
409 eimPublicKeyData := omit,
410 trustedPublicKeyDataTls := omit,
411 eimSupportedProtocol := omit,
412 euiccCiPKId := omit
413 }
414 }
415}
416
417/* GSMA SGP.32, section 5.9.4 */
418template (present) AddInitialEimResponse
419tr_addInitialEimResponse := {
420 addInitialEimOk := ?
421}
422template (value) AddInitialEimResponse
Philipp Maierd9887d32024-04-10 15:48:05 +0200423ts_addInitialEimResponse := {
Philipp Maier08902cf2024-03-04 10:32:55 +0100424 addInitialEimOk := {
425 {
426 addOk := NULL
427 }
428 }
429}
430
Philipp Maier978ab442024-04-10 15:46:45 +0200431}