eSIM RSP 测试用例对比站

人工切片(-man) ↔ Cas 盲生成(-cas)· 真机真卡执行证据对照

源码对照:4.2.2.2.1

ES6 更新元数据(UpdateMetadata) / TC_eUICC_ES6.UpdateMetadata

左侧为人工切片入口(-man,来自 原料/切片 的最小可执行脚本),右侧为 Cas 盲生成入口(-cas,仅依据规范生成)。文件按原始编码(多为 GBK)解码为 UTF-8 显示,行号自 1 起;字节级原文与 sha256 见两侧脚本包。完整 unified diff 见本页底部折叠区,以及 报告原文 §4。
-man 入口
Import/TestCase_SGP_23.js
973 行 / 37033 字符 / gb18030
-cas 入口
TC_eUICC_ES6_UpdateMetadata/Import/TC_eUICC_ES6_UpdateMetadata.js
739 行 / 56295 字符 / gb18030
默认折行显示长行;取消勾选可横向滚动查看原始行宽
-man 人工切片Import/TestCase_SGP_23.js973 行 / 37033 字符 / gb18030入口函数 @L3
1// slice of Import\TestCase_SGP_23.js - cases: TC_eUICC_ES6_UpdateMetadata_01_Nominal_Unset_PPR1 + TC_eUICC_ES6_UpdateMetadata_02_Nominal_Unset_PPR2_and_update_icon + TC_eUICC_ES6_UpdateMetadata_03_Nominal_Unset_PPR1_and_PPR2_and_update_Profile_name_and_Service_Provider_name + TC_eUICC_ES6_UpdateMetadata_04_Nominal_Delete_PPRs_Service_Provider_and_Profile_names + TC_eUICC_ES6_UpdateMetadata_06_Nominal_Delete_Unset_PPRs + TC_eUICC_ES6_UpdateMetadata_07_Error_Set_a_pprUpdateControl_value_to_one_e + TC_eUICC_ES6_UpdateMetadata_08_Error_Update_Metadata_on_a_Disable_Profile + TC_eUICC_ES6_UpdateMetadata_09_Error_Empty_request + TC_eUICC_ES6_UpdateMetadata_10_Error_Update_Icon_without_Icon_Type_field + TC_eUICC_ES6_UpdateMetadata_11_Error_Update_Icon_Type_without_Icon_field (extracted verbatim)
2
3function TC_eUICC_ES6_UpdateMetadata_01_Nominal_Unset_PPR1()
4{
5	
6	RecoverCard();
7
8	initial_condition_PROFILE_OPERATIONAL1_is_Enabled("0560");
9	
10	tracenamestr = "测试目的:验证MNO可以从Profile中取消已设置的PPR1,以及eUICC能够处理仅包含一个字段的Update Metadata的请求";
11	curDis.TraceStart(sno++,tracenamestr);
12	
13	curLogicChannel = 0;
14	curDis.TestStepStart2(stno++,"eUICC卡片初始化;");
15	Ini_powerOn_eUICC_LPAe_not_activate();
16	
17	curDis.TestStepStart2(stno++,"读卡器向卡片发送MANAGE_CHANNEL命令,打开辅助逻辑通道;");
18	TS_MANAGE_CHANNEL_OPEN();
19	
20	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Terminal Profile命令,进行主动式命令交互;");
21	IniCard_SetUpMenu("",1);
22	
23	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Envelope命令,执行UpdateMetadataRequest,更新策略,REMOVE_PPR1;");
24	sSendType = SendTypeByOTA.SMS;
25		
26	KIC = MNO_SCP80_ENC_KEY;
27	KID = MNO_SCP80_AUTH_KEY;
28	KIK = MNO_SCP80_DATA_ENC_KEY;
29
30
31	numOfCmdTlvs = 0;
32	arrExpandedRemoteCmdObj = new Array();
33	
34	InstallForPerson = new InstallForPersonalizationPara(RESERVED_ISD_P_AID);
35	InstallForPerson.SetAPDU();
36	arrExpandedRemoteCmdObj[numOfCmdTlvs] = new ExpandedRemoteCommandObject();
37	arrExpandedRemoteCmdObj[numOfCmdTlvs].crtExpandedRemoteApduObj(InstallForPerson.apdu);
38	numOfCmdTlvs ++;
39	
40	
41	var sdatain = "BF2A0499020520";
42	var storedatapara =new StoreDataPara("90","00",sdatain,"9000");
43	
44	storedatapara.SetAPDU();
45	arrExpandedRemoteCmdObj[numOfCmdTlvs] = new ExpandedRemoteCommandObject();
46	arrExpandedRemoteCmdObj[numOfCmdTlvs].crtExpandedRemoteApduObj(storedatapara.apdu);
47	numOfCmdTlvs ++;
48	
49	sAPDU = GenExpandedRemoteCmd(arrExpandedRemoteCmdObj);
50	
51	SendMessageToCard_GP(sSendType,"91XX",0,MNO_TAR_PROFILE_OPERATIONAL1,"12210015",sAPDU);
52	
53	var exResPara = new ExpandedRemoteResponsePara(arrExpandedRemoteCmdObj, "9000", "00", sSendType);
54	CardSendMessageToServerExpandedRemoteCmd(exResPara);
55	
56	TerminalResponse("00","9000");
57	
58	
59	curLogicChannel = 1;
60	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
61	TS_SELECT("Select ISD",ISD_R_AID,"9000");
62	
63	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行ProfileInfoListRequest,获取profile信息;");
64	var proInfoListRequest = new ProfileInfoListRequest();
65	proInfoListRequest.searchCriteria = new ChoiceObj(tagOfsearchCriteria_ProfileInfo.iccid,ICCID_OP_PROF1);
66	proInfoListRequest.tagList = "9192939499";
67	proInfoListRequest.GenHexData();
68	var respData = LPAd_Transport_data_to_eUICC(proInfoListRequest.hexData);
69	
70
71	var proInfoListResponse = new  ProfileInfoListResponse();
72	proInfoListResponse.checkCardResDataFormat(respData);
73	
74	try
75	{
76		curStrHandle.CheckData(SP_NAME1, proInfoListResponse.profileInfoListOk.arrOfElement[0].serviceProviderName, "serviceProviderName");
77		curStrHandle.CheckData(PROFILE_OPERATIONAL1_NAME1, proInfoListResponse.profileInfoListOk.arrOfElement[0].profileName, "profileName");
78		curStrHandle.CheckData("01", proInfoListResponse.profileInfoListOk.arrOfElement[0].iconType, "iconType");
79		curStrHandle.CheckData(ICON_OP_PROF1, proInfoListResponse.profileInfoListOk.arrOfElement[0].icon, "icon");
80		curStrHandle.CheckData("0520", proInfoListResponse.profileInfoListOk.arrOfElement[0].profilePolicyRules, "profilePolicyRules");
81	}catch(e){
82		obj.SubLevel(ProfileInfoListResponse_Data_Error, level_of_SubLevel.error);
83	}
84	
85	RecoverCard();
86	return;
87	
88	
89}
90
91function TC_eUICC_ES6_UpdateMetadata_02_Nominal_Unset_PPR2_and_update_icon()
92{
93	
94	initial_condition_PROFILE_OPERATIONAL1_is_Enabled("0560");
95	
96	tracenamestr = "测试目的:验证MNO可以从Profile中取消已设置的PPR2,并更新icon和icon type值";
97	
98	curDis.TraceStart(sno++,tracenamestr);
99	
100	curLogicChannel = 0;
101	curDis.TestStepStart2(stno++,"eUICC卡片初始化;");
102	Ini_powerOn_eUICC_LPAe_not_activate();
103	
104	curDis.TestStepStart2(stno++,"读卡器向卡片发送MANAGE_CHANNEL命令,打开辅助逻辑通道;");
105	TS_MANAGE_CHANNEL_OPEN();
106	
107	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Terminal Profile命令,进行主动式命令交互;");
108	IniCard_SetUpMenu("",1);
109	
110	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Envelope命令,执行UpdateMetadataRequest,更新icon和icon类型,UPD_ICON_REM_PPR2;");
111	sSendType = SendTypeByOTA.SMS;
112		
113	KIC = MNO_SCP80_ENC_KEY;
114	KID = MNO_SCP80_AUTH_KEY;
115	KIK = MNO_SCP80_DATA_ENC_KEY;
116	
117
118	numOfCmdTlvs = 0;
119	arrExpandedRemoteCmdObj = new Array();
120	
121	InstallForPerson = new InstallForPersonalizationPara(RESERVED_ISD_P_AID);
122	InstallForPerson.SetAPDU();
123	arrExpandedRemoteCmdObj[numOfCmdTlvs] = new ExpandedRemoteCommandObject();
124	arrExpandedRemoteCmdObj[numOfCmdTlvs].crtExpandedRemoteApduObj(InstallForPerson.apdu);
125	numOfCmdTlvs ++;
126	
127
128	var UpdateMetadataReq = new UpdateMetadataRequest();
129	UpdateMetadataReq.profilePolicyRules = "0640";    
130	UpdateMetadataReq.iconType = "00";
131	UpdateMetadataReq.icon = ICON_JPG;
132		
133	var sdatain = UpdateMetadataReq.GenHexData();
134	
135	var stdataArray = StoreDataarr(sdatain,"90","00","9000");
136	for (var i = 0; i < stdataArray.length; i++)
137	{
138
139		arrExpandedRemoteCmdObj[numOfCmdTlvs] = new ExpandedRemoteCommandObject();
140		arrExpandedRemoteCmdObj[numOfCmdTlvs].crtExpandedRemoteApduObj(stdataArray[i]);
141		numOfCmdTlvs ++;
142		
143	}
144	
145	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
146	sAPDU = GenExpandedRemoteCmd(arrExpandedRemoteCmdObj);
147	SendMessageToCard_GP(sSendType,"91XX",0,MNO_TAR_PROFILE_OPERATIONAL1,"12210015",sAPDU);
148	
149	var exResPara = new ExpandedRemoteResponsePara(arrExpandedRemoteCmdObj, "9000", "00", sSendType);
150	CardSendMessageToServerExpandedRemoteCmd(exResPara);
151	
152	TerminalResponse("00","9000");
153
154	curLogicChannel = 1;
155	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
156	TS_SELECT("Select ISD",ISD_R_AID,"9000");
157	
158	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行ProfileInfoListRequest,获取profile信息;");
159	var proInfoListRequest = new ProfileInfoListRequest();
160	proInfoListRequest.searchCriteria = new ChoiceObj(tagOfsearchCriteria_ProfileInfo.iccid,ICCID_OP_PROF1);
161	proInfoListRequest.tagList = "9192939499";
162	proInfoListRequest.GenHexData();
163	var respData = LPAd_Transport_data_to_eUICC(proInfoListRequest.hexData);
164	
165
166	var proInfoListResponse = new  ProfileInfoListResponse();
167	proInfoListResponse.checkCardResDataFormat(respData);
168	
169	try
170	{
171		curStrHandle.CheckData(SP_NAME1, proInfoListResponse.profileInfoListOk.arrOfElement[0].serviceProviderName, "serviceProviderName");
172		curStrHandle.CheckData(PROFILE_OPERATIONAL1_NAME1, proInfoListResponse.profileInfoListOk.arrOfElement[0].profileName, "profileName");
173		curStrHandle.CheckData("00", proInfoListResponse.profileInfoListOk.arrOfElement[0].iconType, "iconType");
174		curStrHandle.CheckData(ICON_JPG, proInfoListResponse.profileInfoListOk.arrOfElement[0].icon, "icon");
175		curStrHandle.CheckData("0640", proInfoListResponse.profileInfoListOk.arrOfElement[0].profilePolicyRules, "profilePolicyRules");
176	}catch(e){
177		obj.SubLevel(ProfileInfoListResponse_Data_Error, level_of_SubLevel.error);
178	}
179	
180	RecoverCard();
181	return;
182	
183	
184}
185
186function TC_eUICC_ES6_UpdateMetadata_03_Nominal_Unset_PPR1_and_PPR2_and_update_Profile_name_and_Service_Provider_name()
187{
188	
189	initial_condition_PROFILE_OPERATIONAL1_is_Enabled("0560");
190	
191	tracenamestr = "测试目的:验证MNO可以从Profile中取消已设置的PPR1和PPR2,并更新Service Provider Name和Profile Name values";
192	curDis.TraceStart(sno++,tracenamestr);
193	
194	curLogicChannel = 0;
195	curDis.TestStepStart2(stno++,"eUICC卡片初始化;");
196	Ini_powerOn_eUICC_LPAe_not_activate();
197	
198	curDis.TestStepStart2(stno++,"读卡器向卡片发送MANAGE_CHANNEL命令,打开辅助逻辑通道;");
199	TS_MANAGE_CHANNEL_OPEN();
200	
201	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Terminal Profile命令,进行主动式命令交互;");
202	IniCard_SetUpMenu("",1);
203	
204	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Envelope命令,执行UpdateMetadataRequest,更新serviceProviderName和profileName,UPD_NAMES_REM_PPRS;");
205	sSendType = SendTypeByOTA.SMS;
206		
207	KIC = MNO_SCP80_ENC_KEY;
208	KID = MNO_SCP80_AUTH_KEY;
209	KIK = MNO_SCP80_DATA_ENC_KEY;
210	
211
212	numOfCmdTlvs = 0;
213	arrExpandedRemoteCmdObj = new Array();
214	
215	InstallForPerson = new InstallForPersonalizationPara(RESERVED_ISD_P_AID);
216	InstallForPerson.SetAPDU();
217	arrExpandedRemoteCmdObj[numOfCmdTlvs] = new ExpandedRemoteCommandObject();
218	arrExpandedRemoteCmdObj[numOfCmdTlvs].crtExpandedRemoteApduObj(InstallForPerson.apdu);
219	numOfCmdTlvs ++;
220	
221
222	var UpdateMetadataReq = new UpdateMetadataRequest();
223	UpdateMetadataReq.profilePolicyRules = "00";
224	UpdateMetadataReq.serviceProviderName=SP_NAME2;
225	UpdateMetadataReq.profileName=NAME_OP_PROF2;
226	
227		
228	var sdatain = UpdateMetadataReq.GenHexData();
229	var stdataArray = StoreDataarr(sdatain,"90","00","9000");
230	for (var i = 0; i < stdataArray.length; i++)
231	{
232
233		arrExpandedRemoteCmdObj[numOfCmdTlvs] = new ExpandedRemoteCommandObject();
234		arrExpandedRemoteCmdObj[numOfCmdTlvs].crtExpandedRemoteApduObj(stdataArray[i]);
235		numOfCmdTlvs ++;
236		
237	}
238
239	
240	sAPDU = GenExpandedRemoteCmd(arrExpandedRemoteCmdObj);
241	
242	SendMessageToCard_GP(sSendType,"91XX",0,MNO_TAR_PROFILE_OPERATIONAL1,"12210015",sAPDU);
243	
244	var exResPara = new ExpandedRemoteResponsePara(arrExpandedRemoteCmdObj, "9000", "00", sSendType);
245	CardSendMessageToServerExpandedRemoteCmd(exResPara);
246	
247	TerminalResponse("00","9000");
248
249	curLogicChannel = 1;
250	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
251	TS_SELECT("Select ISD",ISD_R_AID,"9000");
252	
253	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行ProfileInfoListRequest,获取profile信息;");
254	var proInfoListRequest = new ProfileInfoListRequest();
255	proInfoListRequest.searchCriteria = new ChoiceObj(tagOfsearchCriteria_ProfileInfo.iccid,ICCID_OP_PROF1);
256	proInfoListRequest.tagList = "9192939499";
257	proInfoListRequest.GenHexData();
258	var respData = LPAd_Transport_data_to_eUICC(proInfoListRequest.hexData);
259	
260
261	var proInfoListResponse = new  ProfileInfoListResponse();
262	proInfoListResponse.checkCardResDataFormat(respData);
263	
264	try
265	{
266		curStrHandle.CheckData(SP_NAME2, proInfoListResponse.profileInfoListOk.arrOfElement[0].serviceProviderName, "serviceProviderName");
267		curStrHandle.CheckData(NAME_OP_PROF2, proInfoListResponse.profileInfoListOk.arrOfElement[0].profileName, "profileName");	
268	}catch(e){
269		obj.SubLevel(ProfileInfoListResponse_Data_Error, level_of_SubLevel.error);
270	}
271	
272	RecoverCard();
273	return;
274	
275	
276}
277
278function TC_eUICC_ES6_UpdateMetadata_04_Nominal_Delete_PPRs_Service_Provider_and_Profile_names()
279{
280	
281	initial_condition_PROFILE_OPERATIONAL1_is_Enabled("0560");
282	
283	tracenamestr = "测试目的:验证MNO可以删除Profile中所有的PPR ,Profile名和Service Provider名";
284	curDis.TraceStart(sno++,tracenamestr);
285	
286	curLogicChannel = 0;
287	curDis.TestStepStart2(stno++,"eUICC卡片初始化;");
288	Ini_powerOn_eUICC_LPAe_not_activate();
289	
290	curDis.TestStepStart2(stno++,"读卡器向卡片发送MANAGE_CHANNEL命令,打开辅助逻辑通道;");
291	TS_MANAGE_CHANNEL_OPEN();
292	
293	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Terminal Profile命令,进行主动式命令交互;");
294	IniCard_SetUpMenu("",1);
295	
296	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Envelope命令,执行UpdateMetadataRequest,删除Profile中所有的PPR ,Profile名和Service Provider名,REMOVE_NAMES_PPRS;");
297	sSendType = SendTypeByOTA.SMS;
298		
299	KIC = MNO_SCP80_ENC_KEY;
300	KID = MNO_SCP80_AUTH_KEY;
301	KIK = MNO_SCP80_DATA_ENC_KEY;
302	
303
304	numOfCmdTlvs = 0;
305	arrExpandedRemoteCmdObj = new Array();
306	
307	InstallForPerson = new InstallForPersonalizationPara(RESERVED_ISD_P_AID);
308	InstallForPerson.SetAPDU();
309	arrExpandedRemoteCmdObj[numOfCmdTlvs] = new ExpandedRemoteCommandObject();
310	arrExpandedRemoteCmdObj[numOfCmdTlvs].crtExpandedRemoteApduObj(InstallForPerson.apdu);
311	numOfCmdTlvs ++;
312	
313	var UpdateMetadataReq = new UpdateMetadataRequest();
314	UpdateMetadataReq.profilePolicyRules = "00";
315	UpdateMetadataReq.serviceProviderName = "";
316	UpdateMetadataReq.profileName = "";
317		
318	var sdatain = UpdateMetadataReq.GenHexData();
319	
320	var stdataArray = StoreDataarr(sdatain,"90","00","9000");
321	for (var i = 0; i < stdataArray.length; i++)
322	{
323		arrExpandedRemoteCmdObj[numOfCmdTlvs] = new ExpandedRemoteCommandObject();
324		arrExpandedRemoteCmdObj[numOfCmdTlvs].crtExpandedRemoteApduObj(stdataArray[i]);
325		numOfCmdTlvs ++;
326		
327	}
328	
329	sAPDU = GenExpandedRemoteCmd(arrExpandedRemoteCmdObj);
330	
331	SendMessageToCard_GP(sSendType,"91XX",0,MNO_TAR_PROFILE_OPERATIONAL1,"12210515",sAPDU);
332	
333	var exResPara = new ExpandedRemoteResponsePara(arrExpandedRemoteCmdObj, "9000", "00", sSendType);
334	CardSendMessageToServerExpandedRemoteCmd(exResPara);
335	
336	TerminalResponse("00","9000");
337
338	curLogicChannel = 1;
339	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
340	TS_SELECT("Select ISD",ISD_R_AID,"9000");
341	
342	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行ProfileInfoListRequest,获取profile信息;");
343	var proInfoListRequest = new ProfileInfoListRequest();
344	proInfoListRequest.searchCriteria = new ChoiceObj(tagOfsearchCriteria_ProfileInfo.iccid,ICCID_OP_PROF1);
345	proInfoListRequest.tagList = "9192939499";
346	proInfoListRequest.GenHexData();
347	var respData = LPAd_Transport_data_to_eUICC(proInfoListRequest.hexData);
348	
349
350	var proInfoListResponse = new  ProfileInfoListResponse();
351	proInfoListResponse.checkCardResDataFormat(respData);
352	
353	try
354	{
355
356		curStrHandle.CheckData("01", proInfoListResponse.profileInfoListOk.arrOfElement[0].iconType, "iconType");
357		curStrHandle.CheckData(ICON_OP_PROF1, proInfoListResponse.profileInfoListOk.arrOfElement[0].icon, "icon");
358		
359		if (typeof(proInfoListResponse.profileInfoListOk.arrOfElement[0].serviceProviderName) != "undefined")
360			obj.SubLevelError("期望不返回serviceProviderName");
361		
362		if (typeof(proInfoListResponse.profileInfoListOk.arrOfElement[0].profileName) != "undefined")
363			obj.SubLevelError("期望不返回profileName");
364		
365		if (typeof(proInfoListResponse.profileInfoListOk.arrOfElement[0].profilePolicyRules) != "undefined")
366			obj.SubLevelError("期望不返回profilePolicyRules");
367	}catch(e){
368		obj.SubLevel(ProfileInfoListResponse_Data_Error, level_of_SubLevel.error);
369	}
370	
371	RecoverCard();
372	return;
373}
374
375function TC_eUICC_ES6_UpdateMetadata_06_Nominal_Delete_Unset_PPRs()
376{
377	
378	initial_condition_PROFILE_OPERATIONAL1_is_Enabled("0560");
379	
380	tracenamestr = "测试目的:验证MNO通过Update Metadata请求可以删除的所有PPRs";
381	curDis.TraceStart(sno++,tracenamestr);
382	
383	curLogicChannel = 0;
384	curDis.TestStepStart2(stno++,"eUICC卡片初始化;");
385	Ini_powerOn_eUICC_LPAe_not_activate();
386	
387	curDis.TestStepStart2(stno++,"读卡器向卡片发送MANAGE_CHANNEL命令,打开辅助逻辑通道;");
388	TS_MANAGE_CHANNEL_OPEN();
389	
390	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Terminal Profile命令,进行主动式命令交互;");
391	IniCard_SetUpMenu("",1);
392	
393	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Envelope命令,执行UpdateMetadataRequest,删除Profile中所有的PPR ,Profile名和Service Provider名,REMOVE_NAMES_PPRS;");
394	sSendType = SendTypeByOTA.SMS;
395		
396	KIC = MNO_SCP80_ENC_KEY;
397	KID = MNO_SCP80_AUTH_KEY;
398	KIK = MNO_SCP80_DATA_ENC_KEY;
399	
400	numOfCmdTlvs = 0;
401	arrExpandedRemoteCmdObj = new Array();
402	
403	InstallForPerson = new InstallForPersonalizationPara(RESERVED_ISD_P_AID);
404	InstallForPerson.SetAPDU();
405	arrExpandedRemoteCmdObj[numOfCmdTlvs] = new ExpandedRemoteCommandObject();
406	arrExpandedRemoteCmdObj[numOfCmdTlvs].crtExpandedRemoteApduObj(InstallForPerson.apdu);
407	numOfCmdTlvs ++;
408	
409	var UpdateMetadataReq = new UpdateMetadataRequest();
410	UpdateMetadataReq.profilePolicyRules = "00";
411	UpdateMetadataReq.serviceProviderName = "";
412	UpdateMetadataReq.profileName = "";
413		
414	var sdatain = UpdateMetadataReq.GenHexData();
415	
416	var stdataArray = StoreDataarr(sdatain,"90","00","9000");
417	for (var i = 0; i < stdataArray.length; i++)
418	{
419		arrExpandedRemoteCmdObj[numOfCmdTlvs] = new ExpandedRemoteCommandObject();
420		arrExpandedRemoteCmdObj[numOfCmdTlvs].crtExpandedRemoteApduObj(stdataArray[i]);
421		numOfCmdTlvs ++;
422		
423	}
424	
425	sAPDU = GenExpandedRemoteCmd(arrExpandedRemoteCmdObj);
426	
427	SendMessageToCard_GP(sSendType,"91XX",0,MNO_TAR_PROFILE_OPERATIONAL1,"12210515",sAPDU);
428	
429	var exResPara = new ExpandedRemoteResponsePara(arrExpandedRemoteCmdObj, "9000", "00", sSendType);
430	CardSendMessageToServerExpandedRemoteCmd(exResPara);
431	
432	TerminalResponse("00","9000");
433	
434	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Envelope命令,执行UpdateMetadataRequest,更新Profile name和Service Provider name,UPD_NAMES_REM_PPRS;");
435	sSendType = SendTypeByOTA.SMS;
436		
437	KIC = MNO_SCP80_ENC_KEY;
438	KID = MNO_SCP80_AUTH_KEY;
439	KIK = MNO_SCP80_DATA_ENC_KEY;
440	
441	numOfCmdTlvs = 0;
442	arrExpandedRemoteCmdObj = new Array();
443	
444	InstallForPerson = new InstallForPersonalizationPara(RESERVED_ISD_P_AID);
445	InstallForPerson.SetAPDU();
446	arrExpandedRemoteCmdObj[numOfCmdTlvs] = new ExpandedRemoteCommandObject();
447	arrExpandedRemoteCmdObj[numOfCmdTlvs].crtExpandedRemoteApduObj(InstallForPerson.apdu);
448	numOfCmdTlvs ++;
449	
450	var UpdateMetadataReq = new UpdateMetadataRequest();
451	UpdateMetadataReq.profilePolicyRules = "00";
452	UpdateMetadataReq.serviceProviderName = SP_NAME2;
453	UpdateMetadataReq.profileName = NAME_OP_PROF2;
454		
455	var sdatain = UpdateMetadataReq.GenHexData();
456	
457	var stdataArray = StoreDataarr(sdatain,"90","00","9000");
458	for (var i = 0; i < stdataArray.length; i++)
459	{
460		arrExpandedRemoteCmdObj[numOfCmdTlvs] = new ExpandedRemoteCommandObject();
461		arrExpandedRemoteCmdObj[numOfCmdTlvs].crtExpandedRemoteApduObj(stdataArray[i]);
462		numOfCmdTlvs ++;
463		
464	}
465	
466	sAPDU = GenExpandedRemoteCmd(arrExpandedRemoteCmdObj);
467	
468	SendMessageToCard_GP(sSendType,"91XX",0,MNO_TAR_PROFILE_OPERATIONAL1,"12210515",sAPDU);
469	
470	var exResPara = new ExpandedRemoteResponsePara(arrExpandedRemoteCmdObj, "9000", "00", sSendType);
471	CardSendMessageToServerExpandedRemoteCmd(exResPara);
472	
473	TerminalResponse("00","9000");
474
475	curLogicChannel = 1;
476	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
477	TS_SELECT("Select ISD",ISD_R_AID,"9000");
478	
479	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行ProfileInfoListRequest,获取profile信息;");
480	var proInfoListRequest = new ProfileInfoListRequest();
481	proInfoListRequest.searchCriteria = new ChoiceObj(tagOfsearchCriteria_ProfileInfo.iccid,ICCID_OP_PROF1);
482	proInfoListRequest.tagList = "9192939499";
483	proInfoListRequest.GenHexData();
484	var respData = LPAd_Transport_data_to_eUICC(proInfoListRequest.hexData);
485	
486	var proInfoListResponse = new  ProfileInfoListResponse();
487	proInfoListResponse.checkCardResDataFormat(respData);
488	
489	try
490	{
491		curStrHandle.CheckData(SP_NAME2, proInfoListResponse.profileInfoListOk.arrOfElement[0].serviceProviderName, "serviceProviderName");
492		curStrHandle.CheckData(NAME_OP_PROF2, proInfoListResponse.profileInfoListOk.arrOfElement[0].profileName, "profileName");
493		curStrHandle.CheckData("01", proInfoListResponse.profileInfoListOk.arrOfElement[0].iconType, "iconType");
494		curStrHandle.CheckData(ICON_OP_PROF1, proInfoListResponse.profileInfoListOk.arrOfElement[0].icon, "icon");
495		if (typeof(proInfoListResponse.profileInfoListOk.arrOfElement[0].profilePolicyRules) != "undefined")
496			obj.SubLevelError("期望不返回profilePolicyRules");
497		
498	}catch(e){
499		obj.SubLevel(ProfileInfoListResponse_Data_Error, level_of_SubLevel.error);
500	}
501	
502	RecoverCard();
503	return;
504}
505
506function TC_eUICC_ES6_UpdateMetadata_07_Error_Set_a_pprUpdateControl_value_to_one_e()
507{
508	
509	initial_condition_PROFILE_OPERATIONAL1_is_Enabled("0560");
510	
511	tracenamestr = "测试目的:验证eUICC可以正确处理来自MNO请求的pprUpdateControl的错误值,并返回预期的错误码";
512	curDis.TraceStart(sno++,tracenamestr);
513	
514	curLogicChannel = 0;
515	curDis.TestStepStart2(stno++,"eUICC卡片初始化;");
516	Ini_powerOn_eUICC_LPAe_not_activate();
517	
518	curDis.TestStepStart2(stno++,"读卡器向卡片发送MANAGE_CHANNEL命令,打开辅助逻辑通道;");
519	TS_MANAGE_CHANNEL_OPEN();
520	
521	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Terminal Profile命令,进行主动式命令交互;");
522	IniCard_SetUpMenu("",1);
523	
524	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Envelope命令,执行UpdateMetadataRequest,更新serviceProviderName、profileName、iconType、icon和profilePolicyRules,UPD_PPR_CONTROL;");
525	sSendType = SendTypeByOTA.SMS;
526		
527	KIC = MNO_SCP80_ENC_KEY;
528	KID = MNO_SCP80_AUTH_KEY;
529	KIK = MNO_SCP80_DATA_ENC_KEY;
530	
531
532	numOfCmdTlvs = 0;
533	arrExpandedRemoteCmdObj = new Array();
534	
535	InstallForPerson = new InstallForPersonalizationPara(RESERVED_ISD_P_AID);
536	InstallForPerson.SetAPDU();
537	arrExpandedRemoteCmdObj[numOfCmdTlvs] = new ExpandedRemoteCommandObject();
538	arrExpandedRemoteCmdObj[numOfCmdTlvs].crtExpandedRemoteApduObj(InstallForPerson.apdu);
539	numOfCmdTlvs ++;
540	
541
542	var UpdateMetadataReq = new UpdateMetadataRequest();
543	UpdateMetadataReq.profilePolicyRules = "06C0";
544	UpdateMetadataReq.serviceProviderName=SP_NAME2;
545	UpdateMetadataReq.profileName=NAME_OP_PROF2;
546	UpdateMetadataReq.iconType = "00";
547	UpdateMetadataReq.icon = ICON_JPG;
548	
549		
550	var sdatain = UpdateMetadataReq.GenHexData();
551	var stdataArray = StoreDataarr(sdatain,"90","00","6A81");
552	for (var i = 0; i < stdataArray.length; i++)
553	{
554
555		arrExpandedRemoteCmdObj[numOfCmdTlvs] = new ExpandedRemoteCommandObject();
556		arrExpandedRemoteCmdObj[numOfCmdTlvs].crtExpandedRemoteApduObj(stdataArray[i]);
557		numOfCmdTlvs ++;
558		
559	}
560
561	
562	sAPDU = GenExpandedRemoteCmd(arrExpandedRemoteCmdObj);
563	
564	SendMessageToCard_GP(sSendType,"91XX",0,MNO_TAR_PROFILE_OPERATIONAL1,"12210015",sAPDU);
565	
566	var exResPara = new ExpandedRemoteResponsePara(arrExpandedRemoteCmdObj, "9000", "00", sSendType);
567	CardSendMessageToServerExpandedRemoteCmd(exResPara);
568	
569	
570	TerminalResponse("00","9000");
571
572	curLogicChannel = 1;
573	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
574	TS_SELECT("Select ISD",ISD_R_AID,"9000");
575	
576	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行ProfileInfoListRequest,获取profile信息;");
577	var proInfoListRequest = new ProfileInfoListRequest();
578	proInfoListRequest.searchCriteria = new ChoiceObj(tagOfsearchCriteria_ProfileInfo.iccid,ICCID_OP_PROF1);
579	proInfoListRequest.tagList = "9192939499";
580	proInfoListRequest.GenHexData();
581	var respData = LPAd_Transport_data_to_eUICC(proInfoListRequest.hexData);
582	
583
584	var proInfoListResponse = new  ProfileInfoListResponse();
585	proInfoListResponse.checkCardResDataFormat(respData);
586
587	try
588	{
589		curStrHandle.CheckData(SP_NAME1, proInfoListResponse.profileInfoListOk.arrOfElement[0].serviceProviderName, "serviceProviderName");
590		curStrHandle.CheckData(PROFILE_OPERATIONAL1_NAME1, proInfoListResponse.profileInfoListOk.arrOfElement[0].profileName, "profileName");	
591		curStrHandle.CheckData("01", proInfoListResponse.profileInfoListOk.arrOfElement[0].iconType, "iconType");
592		curStrHandle.CheckData(ICON_OP_PROF1, proInfoListResponse.profileInfoListOk.arrOfElement[0].icon, "icon");
593		curStrHandle.CheckData("0560", proInfoListResponse.profileInfoListOk.arrOfElement[0].profilePolicyRules, "profilePolicyRules");
594	}catch(e){
595		obj.SubLevel(ProfileInfoListResponse_Data_Error, level_of_SubLevel.error);
596	}
597	
598	RecoverCard();
599	return;
600	
601	
602}
603
604function TC_eUICC_ES6_UpdateMetadata_08_Error_Update_Metadata_on_a_Disable_Profile()
605{
606	
607	
608	initial_condition_PROFILE_OPERATIONAL1_is_Disabled("0560");
609	
610	tracenamestr = "测试目的:验证当目标Profile已禁用时,eUICC可以正确拒绝来自MNO的Update Metadata请求";
611	curDis.TraceStart(sno++,tracenamestr);
612	
613	curLogicChannel = 0;
614	curDis.TestStepStart2(stno++,"eUICC卡片初始化;");
615	Ini_powerOn_eUICC_LPAe_not_activate();
616	
617	curDis.TestStepStart2(stno++,"读卡器向卡片发送MANAGE_CHANNEL命令,打开辅助逻辑通道;");
618	TS_MANAGE_CHANNEL_OPEN();
619	
620	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Terminal Profile命令,进行主动式命令交互;");
621	IniCard_SetUpMenu("",1);
622	
623	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Envelope命令,执行UpdateMetadataRequest,更新PPR2,REMOVE_PPR1;");
624	sSendType = SendTypeByOTA.SMS;
625		
626	KIC = MNO_SCP80_ENC_KEY;
627	KID = MNO_SCP80_AUTH_KEY;
628	KIK = MNO_SCP80_DATA_ENC_KEY;
629	
630	numOfCmdTlvs = 0;
631	arrExpandedRemoteCmdObj = new Array();
632	
633	InstallForPerson = new InstallForPersonalizationPara(RESERVED_ISD_P_AID);
634	InstallForPerson.SetAPDU();
635	arrExpandedRemoteCmdObj[numOfCmdTlvs] = new ExpandedRemoteCommandObject();
636	arrExpandedRemoteCmdObj[numOfCmdTlvs].crtExpandedRemoteApduObj(InstallForPerson.apdu);
637	numOfCmdTlvs ++;
638	
639	var sdatain = "BF2A0499020520";
640	var storedatapara =new StoreDataPara("90","00",sdatain,"9000");
641	storedatapara.apdu.ressw="6A81";
642		
643	storedatapara.SetAPDU();
644	arrExpandedRemoteCmdObj[numOfCmdTlvs] = new ExpandedRemoteCommandObject();
645	arrExpandedRemoteCmdObj[numOfCmdTlvs].crtExpandedRemoteApduObj(storedatapara.apdu);
646	numOfCmdTlvs ++;
647	
648	
649	sAPDU = GenExpandedRemoteCmd(arrExpandedRemoteCmdObj);
650	
651	SendMessageToCard_GP(sSendType,"91XX",0,MNO_TAR_PROFILE_OPERATIONAL1,"12210015",sAPDU);
652	
653	var exResPara = new ExpandedRemoteResponsePara(arrExpandedRemoteCmdObj, "9000", "06/09", sSendType);
654	CardSendMessageToServerExpandedRemoteCmd(exResPara);
655	
656	TerminalResponse("00","9000");
657
658	curLogicChannel = 1;
659	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
660	TS_SELECT("Select ISD",ISD_R_AID,"9000");
661	
662	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行ProfileInfoListRequest,获取profile信息;");
663	var proInfoListRequest = new ProfileInfoListRequest();
664	proInfoListRequest.searchCriteria = new ChoiceObj(tagOfsearchCriteria_ProfileInfo.iccid,ICCID_OP_PROF1);
665	proInfoListRequest.tagList = "9192939499";
666	proInfoListRequest.GenHexData();
667	var respData = LPAd_Transport_data_to_eUICC(proInfoListRequest.hexData);
668
669	var proInfoListResponse = new  ProfileInfoListResponse();
670	proInfoListResponse.checkCardResDataFormat(respData);
671	
672	
673	try
674	{
675		curStrHandle.CheckData(SP_NAME1, proInfoListResponse.profileInfoListOk.arrOfElement[0].serviceProviderName, "serviceProviderName");
676		curStrHandle.CheckData(PROFILE_OPERATIONAL1_NAME1, proInfoListResponse.profileInfoListOk.arrOfElement[0].profileName, "profileName");	
677		curStrHandle.CheckData("0560", proInfoListResponse.profileInfoListOk.arrOfElement[0].profilePolicyRules, "profilePolicyRules");
678	}catch(e){
679		obj.SubLevel(ProfileInfoListResponse_Data_Error, level_of_SubLevel.error);
680	}
681	
682	RecoverCard();
683	return;
684	
685	
686}
687
688function TC_eUICC_ES6_UpdateMetadata_09_Error_Empty_request()
689{
690	
691	initial_condition_PROFILE_OPERATIONAL1_is_Enabled("0560");
692	
693	tracenamestr = "测试目的:验证没有字段存在时,eUICC可以正确拒绝来自MNO的Update Metadata请求";
694	curDis.TraceStart(sno++,tracenamestr);
695	
696	curLogicChannel = 0;
697	curDis.TestStepStart2(stno++,"eUICC卡片初始化;");
698	Ini_powerOn_eUICC_LPAe_not_activate();
699	
700	curDis.TestStepStart2(stno++,"读卡器向卡片发送MANAGE_CHANNEL命令,打开辅助逻辑通道;");
701	TS_MANAGE_CHANNEL_OPEN();
702	
703	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Terminal Profile命令,进行主动式命令交互;");
704	IniCard_SetUpMenu("",1);
705	
706	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Envelope命令,执行UpdateMetadataRequest,UPD_NO_METADATA");
707	sSendType = SendTypeByOTA.SMS;
708		
709	KIC = MNO_SCP80_ENC_KEY;
710	KID = MNO_SCP80_AUTH_KEY;
711	KIK = MNO_SCP80_DATA_ENC_KEY;
712	
713
714	numOfCmdTlvs = 0;
715	arrExpandedRemoteCmdObj = new Array();
716	
717	InstallForPerson = new InstallForPersonalizationPara(RESERVED_ISD_P_AID);
718	InstallForPerson.SetAPDU();
719	arrExpandedRemoteCmdObj[numOfCmdTlvs] = new ExpandedRemoteCommandObject();
720	arrExpandedRemoteCmdObj[numOfCmdTlvs].crtExpandedRemoteApduObj(InstallForPerson.apdu);
721	numOfCmdTlvs ++;
722	
723
724	var UpdateMetadataReq = new UpdateMetadataRequest();
725		
726	var sdatain = UpdateMetadataReq.GenHexData();
727	
728	var stdataArray = StoreDataarr(sdatain,"90","00","XXXX");
729	for (var i = 0; i < stdataArray.length; i++)
730	{
731
732		arrExpandedRemoteCmdObj[numOfCmdTlvs] = new ExpandedRemoteCommandObject();
733		arrExpandedRemoteCmdObj[numOfCmdTlvs].crtExpandedRemoteApduObj(stdataArray[i]);
734		numOfCmdTlvs ++;
735		
736	}
737
738	
739	sAPDU = GenExpandedRemoteCmd(arrExpandedRemoteCmdObj);
740	
741	SendMessageToCard_GP(sSendType,"91XX",0,MNO_TAR_PROFILE_OPERATIONAL1,"12210015",sAPDU);
742	
743	var exResPara = new ExpandedRemoteResponsePara(arrExpandedRemoteCmdObj, "9000", "00", sSendType);
744	CardSendMessageToServerExpandedRemoteCmd(exResPara);
745	
746	
747	TerminalResponse("00","9000");
748
749	curLogicChannel = 1;
750	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
751	TS_SELECT("Select ISD",ISD_R_AID,"9000");
752	
753	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行ProfileInfoListRequest,获取profile信息;");
754	var proInfoListRequest = new ProfileInfoListRequest();
755	proInfoListRequest.searchCriteria = new ChoiceObj(tagOfsearchCriteria_ProfileInfo.iccid,ICCID_OP_PROF1);
756	proInfoListRequest.tagList = "9192939499";
757	proInfoListRequest.GenHexData();
758	var respData = LPAd_Transport_data_to_eUICC(proInfoListRequest.hexData);
759	
760
761	var proInfoListResponse = new  ProfileInfoListResponse();
762	proInfoListResponse.checkCardResDataFormat(respData);
763	
764	try
765	{
766		curStrHandle.CheckData(SP_NAME1, proInfoListResponse.profileInfoListOk.arrOfElement[0].serviceProviderName, "serviceProviderName");
767		curStrHandle.CheckData(PROFILE_OPERATIONAL1_NAME1, proInfoListResponse.profileInfoListOk.arrOfElement[0].profileName, "profileName");	
768		curStrHandle.CheckData("01", proInfoListResponse.profileInfoListOk.arrOfElement[0].iconType, "iconType");
769		curStrHandle.CheckData(ICON_OP_PROF1, proInfoListResponse.profileInfoListOk.arrOfElement[0].icon, "icon");
770		curStrHandle.CheckData("0560", proInfoListResponse.profileInfoListOk.arrOfElement[0].profilePolicyRules, "profilePolicyRules");
771	}catch(e){
772		obj.SubLevel(ProfileInfoListResponse_Data_Error, level_of_SubLevel.error);
773	}
774	
775	RecoverCard();
776	return;
777	
778	
779}
780
781function TC_eUICC_ES6_UpdateMetadata_10_Error_Update_Icon_without_Icon_Type_field()//
782{
783	
784	initial_condition_PROFILE_OPERATIONAL1_is_Enabled("0560");
785	
786	tracenamestr = "测试目的:验证当icon字段存在,但icon type字段不存在时,eUICC可以正确拒绝来自MNO的Update Metadata请求";
787	curDis.TraceStart(sno++,tracenamestr);
788	
789	curLogicChannel = 0;
790	curDis.TestStepStart2(stno++,"eUICC卡片初始化;");
791	Ini_powerOn_eUICC_LPAe_not_activate();
792	
793	curDis.TestStepStart2(stno++,"读卡器向卡片发送MANAGE_CHANNEL命令,打开辅助逻辑通道;");
794	TS_MANAGE_CHANNEL_OPEN();
795	
796	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Terminal Profile命令,进行主动式命令交互;");
797	IniCard_SetUpMenu("",1);
798	
799	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Envelope命令,执行UpdateMetadataRequest,UPD_NO_METADATA");
800	sSendType = SendTypeByOTA.SMS;
801		
802	KIC = MNO_SCP80_ENC_KEY;
803	KID = MNO_SCP80_AUTH_KEY;
804	KIK = MNO_SCP80_DATA_ENC_KEY;
805	
806
807	numOfCmdTlvs = 0;
808	arrExpandedRemoteCmdObj = new Array();
809	
810	InstallForPerson = new InstallForPersonalizationPara(RESERVED_ISD_P_AID);
811	InstallForPerson.SetAPDU();
812	arrExpandedRemoteCmdObj[numOfCmdTlvs] = new ExpandedRemoteCommandObject();
813	arrExpandedRemoteCmdObj[numOfCmdTlvs].crtExpandedRemoteApduObj(InstallForPerson.apdu);
814	numOfCmdTlvs ++;
815	
816
817	var UpdateMetadataReq = new UpdateMetadataRequest();
818	UpdateMetadataReq.profilePolicyRules = "00";
819	UpdateMetadataReq.serviceProviderName=SP_NAME2;
820	UpdateMetadataReq.profileName=NAME_OP_PROF2;
821	UpdateMetadataReq.icon = ICON_JPG;
822	
823		
824	var sdatain = UpdateMetadataReq.GenHexData();
825	
826	
827	var stdataArray = StoreDataarr(sdatain,"90","00","XXXX");
828	for (var i = 0; i < stdataArray.length; i++)
829	{
830
831		arrExpandedRemoteCmdObj[numOfCmdTlvs] = new ExpandedRemoteCommandObject();
832		arrExpandedRemoteCmdObj[numOfCmdTlvs].crtExpandedRemoteApduObj(stdataArray[i]);
833		numOfCmdTlvs ++;
834		
835	}
836
837	
838	sAPDU = GenExpandedRemoteCmd(arrExpandedRemoteCmdObj);
839	
840	SendMessageToCard_GP(sSendType,"91XX",0,MNO_TAR_PROFILE_OPERATIONAL1,"12210015",sAPDU);
841	
842	var exResPara = new ExpandedRemoteResponsePara(arrExpandedRemoteCmdObj, "9000", "00", sSendType);
843	CardSendMessageToServerExpandedRemoteCmd(exResPara);
844	
845	
846	TerminalResponse("00","9000");
847
848	curLogicChannel = 1;
849	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
850	TS_SELECT("Select ISD",ISD_R_AID,"9000");
851	
852	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行ProfileInfoListRequest,获取profile信息;");
853	var proInfoListRequest = new ProfileInfoListRequest();
854	proInfoListRequest.searchCriteria = new ChoiceObj(tagOfsearchCriteria_ProfileInfo.iccid,ICCID_OP_PROF1);
855	proInfoListRequest.tagList = "9192939499";
856	proInfoListRequest.GenHexData();
857	var respData = LPAd_Transport_data_to_eUICC(proInfoListRequest.hexData);
858	
859
860	var proInfoListResponse = new  ProfileInfoListResponse();
861	proInfoListResponse.checkCardResDataFormat(respData);
862	
863	try
864	{
865		curStrHandle.CheckData(SP_NAME1, proInfoListResponse.profileInfoListOk.arrOfElement[0].serviceProviderName, "serviceProviderName");
866		curStrHandle.CheckData(PROFILE_OPERATIONAL1_NAME1, proInfoListResponse.profileInfoListOk.arrOfElement[0].profileName, "profileName");	
867		curStrHandle.CheckData("01", proInfoListResponse.profileInfoListOk.arrOfElement[0].iconType, "iconType");
868		curStrHandle.CheckData(ICON_OP_PROF1, proInfoListResponse.profileInfoListOk.arrOfElement[0].icon, "icon");//ICON_OP_PROF1=ICON_PNG
869		curStrHandle.CheckData("0560", proInfoListResponse.profileInfoListOk.arrOfElement[0].profilePolicyRules, "profilePolicyRules");
870	}catch(e){
871		obj.SubLevel(ProfileInfoListResponse_Data_Error, level_of_SubLevel.error);
872	}
873	
874	RecoverCard();
875	return;
876	
877	
878}
879
880function TC_eUICC_ES6_UpdateMetadata_11_Error_Update_Icon_Type_without_Icon_field ()
881{
882	
883	initial_condition_PROFILE_OPERATIONAL1_is_Enabled("0560");
884	
885	tracenamestr = "测试目的:验证当icon type字段存在,但icon字段不存在时,eUICC可以正确拒绝来自MNO的Update Metadata请求";
886	curDis.TraceStart(sno++,tracenamestr);
887	
888	curLogicChannel = 0;
889	curDis.TestStepStart2(stno++,"eUICC卡片初始化;");
890	Ini_powerOn_eUICC_LPAe_not_activate();
891	
892	curDis.TestStepStart2(stno++,"读卡器向卡片发送MANAGE_CHANNEL命令,打开辅助逻辑通道;");
893	TS_MANAGE_CHANNEL_OPEN();
894	
895	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Terminal Profile命令,进行主动式命令交互;");
896	IniCard_SetUpMenu("",1);
897	
898	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Envelope命令,执行UpdateMetadataRequest,只更新icon类型不更新icon,UPD_ICON_TYPE_ONLY;");
899	sSendType = SendTypeByOTA.SMS;
900		
901	KIC = MNO_SCP80_ENC_KEY;
902	KID = MNO_SCP80_AUTH_KEY;
903	KIK = MNO_SCP80_DATA_ENC_KEY;
904	
905	//扩展格式更新策略
906	numOfCmdTlvs = 0;
907	arrExpandedRemoteCmdObj = new Array();
908	
909	InstallForPerson = new InstallForPersonalizationPara(RESERVED_ISD_P_AID);
910	InstallForPerson.SetAPDU();
911	arrExpandedRemoteCmdObj[numOfCmdTlvs] = new ExpandedRemoteCommandObject();
912	arrExpandedRemoteCmdObj[numOfCmdTlvs].crtExpandedRemoteApduObj(InstallForPerson.apdu);
913	numOfCmdTlvs ++;
914	
915	var UpdateMetadataReq = new UpdateMetadataRequest();
916	UpdateMetadataReq.serviceProviderName = SP_NAME2;
917	UpdateMetadataReq.profileName = NAME_OP_PROF2;
918	UpdateMetadataReq.iconType = "00";
919	UpdateMetadataReq.profilePolicyRules = "00";
920		
921	var sdatain = UpdateMetadataReq.GenHexData();
922	
923	var stdataArray = StoreDataarr(sdatain,"90","00","");
924	for (var i = 0; i < stdataArray.length; i++)
925	{
926		arrExpandedRemoteCmdObj[numOfCmdTlvs] = new ExpandedRemoteCommandObject();
927		arrExpandedRemoteCmdObj[numOfCmdTlvs].crtExpandedRemoteApduObj(stdataArray[i]);
928		numOfCmdTlvs ++;
929		
930	}
931	
932	sAPDU = GenExpandedRemoteCmd(arrExpandedRemoteCmdObj);
933	
934	SendMessageToCard_GP(sSendType,"91XX",0,MNO_TAR_PROFILE_OPERATIONAL1,"12210515",sAPDU);
935	
936	var exResPara = new ExpandedRemoteResponsePara(arrExpandedRemoteCmdObj, "9000", "00", sSendType);
937	CardSendMessageToServerExpandedRemoteCmd(exResPara);
938	
939	if (stdataArray[stdataArray.length - 1].sw == "9000")
940			obj.SubLevelError("期望Update Metadata request数据为空时,抛错");
941	
942	TerminalResponse("00","9000");
943	
944	curLogicChannel = 1;
945	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
946	TS_SELECT("Select ISD",ISD_R_AID,"9000");
947	
948	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行ProfileInfoListRequest,获取profile信息;");
949	var proInfoListRequest = new ProfileInfoListRequest();
950	proInfoListRequest.searchCriteria = new ChoiceObj(tagOfsearchCriteria_ProfileInfo.iccid,ICCID_OP_PROF1);
951	proInfoListRequest.tagList = "9192939499";
952	proInfoListRequest.GenHexData();
953	var respData = LPAd_Transport_data_to_eUICC(proInfoListRequest.hexData);
954
955	var proInfoListResponse = new  ProfileInfoListResponse();
956	proInfoListResponse.checkCardResDataFormat(respData);
957	
958	try
959	{
960		curStrHandle.CheckData(SP_NAME1, proInfoListResponse.profileInfoListOk.arrOfElement[0].serviceProviderName, "serviceProviderName");
961		curStrHandle.CheckData(PROFILE_OPERATIONAL1_NAME1, proInfoListResponse.profileInfoListOk.arrOfElement[0].profileName, "profileName");
962		curStrHandle.CheckData("01", proInfoListResponse.profileInfoListOk.arrOfElement[0].iconType, "iconType");
963		curStrHandle.CheckData(ICON_OP_PROF1, proInfoListResponse.profileInfoListOk.arrOfElement[0].icon, "icon");
964		curStrHandle.CheckData("0560", proInfoListResponse.profileInfoListOk.arrOfElement[0].profilePolicyRules, "profilePolicyRules");
965	}catch(e){
966		obj.SubLevel(ProfileInfoListResponse_Data_Error, level_of_SubLevel.error);
967	}
968	RecoverCard();
969	return;
970	
971	
972}
973
-cas 盲生成TC_eUICC_ES6_UpdateMetadata/Import/TC_eUICC_ES6_UpdateMetadata.js739 行 / 56295 字符 / gb18030入口函数 @L34
1// Author: 卡思Cas智能体
2// Date: 20261005-152741
3// Function: (purpose 原文未由 SGP.23 该 TC 提供,corpus vacuum 登记)TC_eUICC_ES6.UpdateMetadata,Test Sequence #01–#11(#05 FFS 不适用);每序列 Nominal/Error 混合,见 steps 前缀,适用性 M。
4// Test points: S1-C1 ATR_present;S2-C2 FCP_Template;S2-C1 SW;S3-C1 SW;S4-C1 final SW;S5-C1 SW1 91
5//   S7-C1 SW;S8-C1 SW;S9-C1 SW;S10-C1 SW;S10-C2 serviceProviderName SP Name 1
6//   S10-C2 profileName Operational Profile Name 1;S10-C2 iconType;S10-C2 icon present
7//   S10-C2 profilePolicyRules {ppr2} oracle;S11-C1 ATR_present;S12-C2 FCP_Template;S12-C1 SW
8//   S13-C1 SW;S14-C1 final SW;S15-C1 SW1 91;S17-C1 SW;S18-C1 SW;S19-C1 SW;S20-C1 SW
9//   S20-C2 serviceProviderName SP Name 1;S20-C2 profileName Operational Profile Name 1
10//   S20-C2 iconType;S20-C2 icon present;S20-C2 profilePolicyRules {ppr1} oracle;S21-C1 ATR_present
11//   S22-C2 FCP_Template;S22-C1 SW;S23-C1 SW;S24-C1 final SW;S25-C1 SW1 91;S27-C1 SW;S28-C1 SW
12//   S29-C1 SW;S30-C1 SW;S30-C2 serviceProviderName SP Name 2
13//   S30-C2 profileName Operational Profile Name 2;S30-C2 profilePolicyRules absent;S30-C2 iconType
14//   S30-C2 icon present;S31-C1 ATR_present;S32-C2 FCP_Template;S32-C1 SW;S33-C1 SW;S34-C1 final SW
15//   S35-C1 SW1 91;S37-C1 SW;S38-C1 SW;S39-C1 SW;S40-C1 SW;S40-C2 serviceProviderName absent
16//   S40-C2 profileName absent;S40-C2 profilePolicyRules absent;S40-C2 iconType;S40-C2 icon present
17//   S41-C1 ATR_present;S42-C2 FCP_Template;S42-C1 SW;S43-C1 SW;S44-C1 final SW;S45-C1 SW1 91
18//   S47-C1 SW;S48-C1 SW1 91;S50-C1 SW;S51-C1 SW;S52-C1 SW;S53-C1 SW
19//   S53-C2 serviceProviderName SP Name 2;S53-C2 profileName Operational Profile Name 2
20//   S53-C2 profilePolicyRules absent;S53-C2 iconType;S53-C2 icon present;S54-C1 ATR_present
21//   S55-C2 FCP_Template;S55-C1 SW;S56-C1 SW;S57-C1 final SW;S58-C1 SW1 91;S60-C1 SW;S61-C1 SW
22//   S62-C1 SW;S63-C1 SW;S63-C2 profileInfoListOk present;S64-C1 ATR_present;S65-C2 FCP_Template
23//   S65-C1 SW;S66-C1 SW;S67-C1 final SW;S70-C1 SW;S71-C1 SW;S72-C1 SW;S73-C1 SW
24//   S73-C2 profileInfoListOk present;S74-C1 ATR_present;S75-C2 FCP_Template;S75-C1 SW;S76-C1 SW
25//   S77-C1 final SW;S78-C1 SW1 91;S80-C1 SW;S81-C1 SW;S82-C1 SW;S83-C1 SW
26//   S83-C2 profileInfoListOk present;S84-C1 ATR_present;S85-C2 FCP_Template;S85-C1 SW;S86-C1 SW
27//   S87-C1 final SW;S88-C1 SW1 91;S90-C1 SW;S91-C1 SW;S92-C1 SW;S93-C1 SW
28//   S93-C2 profileInfoListOk present;S94-C1 ATR_present;S95-C2 FCP_Template;S95-C1 SW;S96-C1 SW
29//   S97-C1 final SW;S98-C1 SW1 91;S100-C1 SW;S101-C1 SW;S102-C1 SW;S103-C1 SW
30//   S103-C2 profileInfoListOk present
31// 本函数由 CaseIR 4.2.2.2.1 编译生成(fullwave-blindgen-live-70,SGP.23 v1.16 × SGP.22 v2.7):字节权威=CaseIR,非誊录黄金脚本。
32// Value-free template: every data byte is injected from CaseIR fields; no scaffold globals (see docs/speconly/compile-symbol-migration.md).
33// 适用性 M:编译期门,运行时由 harness 环境前置承担。
34function TC_eUICC_ES6_UpdateMetadata_01_11_05_FFS_Nominal_Error_steps() {
35    var bind = curBind;
36    // GIC General Initial Condition: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
37    // IC1 PROC_EUICC_INITIALIZATION_SEQUENCE(每序列): declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
38
39    // 步骤 1:Seq#01 IC1/1: RESET(PROC_EUICC_INITIALIZATION_SEQUENCE 展开1/4,K_annexC2_procs 表1256)(procedure_expansion)
40    var s1 = bind.resetAndAtr();
41    bind.checkData("S1-C1 ATR_present", "1", s1.atr_hex !== "" ? "1" : "0");
42
43    // 步骤 2:Seq#01 IC1/2: [SELECT_MF](展开2/4)(procedure_expansion)
44    // FCP outer tag not materialized from clause: tag-face asserted only when corpus fixes the tag byte (e.g. TS 102 221 FCP '62').
45    var s2 = bind.sendApdu("00", "A4", "00", "04", "3F00", "00", "9000");
46    bind.checkData("S2-C2 FCP_Template", "1", s2.resp.length > 0 ? "1" : "0");
47    bind.checkData("S2-C1 SW", "9000", s2.sw);
48
49    // 步骤 3:Seq#01 IC1/3: [TERMINAL_CAPABILITY_LPAd](展开3/4)(procedure_expansion)
50    var s3 = bind.sendApdu("80", "AA", "00", "00", "A9058100830107", null, "9000");
51    bind.checkData("S3-C1 SW", "9000", s3.sw);
52
53    // 步骤 4:Seq#01 IC1/4: [TERMINAL_PROFILE](展开4/4)(procedure_expansion)
54    var steady4 = bind.runToSteadyState(function () {
55        return bind.sendTerminalProfile("FFFFFFFF7F9D00DFBF00001FE2000000C7EB0000000168005000000000000200", "9000");
56    });
57    bind.checkData("S4-C1 final SW", "9000", steady4.final.sw);
58
59    // 步骤 5:Seq#01 1: MTD_SEND_SMS_PP(tc_step;REQ: RQ54_001, RQ54_002, RQ54_003, RQ54_004, RQ54_005, RQ54_006, RQ54_007, RQ54_009, RQ54_010, RQ54_013_1, RQ29_021, RQ24_021, RQ54_011)
60    // MTD_SEND_SMS_PP ENVELOPE (H Annex C.1 表1238 Details: 80 C2 00 00 <L>): SCP80-packed SMS-PP body is runtime-domain
61    // (<MNO_SCP80_COUNTER>/<CC>/<C_APDUS_SCRIPT>) — no bytes fabricated; the embedded STORE DATA
62    // script executes via the proactive FETCH / TERMINAL RESPONSE chain, not in this response.
63    var s5 = bind.sendApdu("80", "C2", "00", "00", null, null, null);
64    bind.checkData("S5-C1 SW1 91", "91", s5.sw.substring(0, 2));
65
66    // 步骤 6:Seq#01 2: FETCH "XX"(tc_step;REQ: RQ54_015, RQ54_011)
67    // FETCH header literals follow the golden wire evidence 8012 (same
68    // anchor as runToSteadyState; J Annex D.4 has no FETCH row, D 2.2.2
69    // gives mechanism only). Le = pending length from the last 91XX
70    // (chain rule, binding-internal state).
71    var s6 = bind.fetchPending("80", "12", "00", "00", null);
72    // S6-C1: binding:fetch_sms_por_runtime_parse(MTD_CHECK_SMS_POR;H-annexC1) (check_attestation)
73    // S6-C2: binding:fetch_length_chaining_last_91xx_sw2(TS102223-6.3-NOTE1) (check_attestation)
74
75    // 步骤 7:Seq#01 3: TERMINAL RESPONSE(tc_step)
76    // TERMINAL RESPONSE data is dynamically built by the binding from the
77    // last FETCHed proactive command (D 2.2.2; buildTrData) - never static.
78    // Header literals follow the golden wire evidence 8014.
79    var s7 = bind.terminalResponseForPending("80", "14", "00", "00", "9000");
80    bind.checkData("S7-C1 SW", "9000", s7.sw);
81
82    // 步骤 8:Seq#01 4/1: [MANAGE_CHANNEL_OPEN](PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR 展开1/2,K_annexC2_procs 表1258)(procedure_expansion)
83    // CHANNEL_NUMBER extraction and dynamic CLA rebinding are CasBind internal state (chaining rule; no generated-code re-implementation).
84    var s8 = bind.manageChannelOpen("9000");
85    bind.checkData("S8-C1 SW", "9000", s8.sw);
86
87    // 步骤 9:Seq#01 4/2: MTD_SELECT(procedure_expansion)
88    // CLA = bound channel (cla_rule) and <L> length binding are CasBind internal state (chaining rule; no generated-code re-implementation).
89    var s9 = bind.sendApdu(null, "A4", "04", "00", "A0000005591010FFFFFFFF8900000100", "00", "9000");
90    // MTD_SELECT expected face is SW-only (K Annex C.2 open-channel procedure step 2: no FCI content assertion in corpus); no fabricated template parse.
91    bind.checkData("S9-C1 SW", "9000", s9.sw);
92
93    // 步骤 10:Seq#01 5: MTD_STORE_DATA(tc_step;REQ: RQ54_013_1, RQ54_009, RQ57_120, RQ57_122, RQ57_123, RQ57_126)
94    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
95    var sdCla10 = s8.chan !== null ? (s8.chan <= 3 ? 128 + s8.chan : 188 + s8.chan).toString(16).toUpperCase() : null;
96    var s10 = bind.sendApdu(sdCla10, "E2", "91", "00", "BF2D15A00C5A0A989209012143658709F55C059192939499", "00", "9000");
97    bind.checkData("S10-C1 SW", "9000", s10.sw);
98    var r2p10 = BindEs10xProcProfile.walkChoiceList(s10.resp, {respTag: "BF2D", okTag: "A0", errTag: "81"});
99    var r2e10 = r2p10.elements.length > 0 ? r2p10.elements[0].fields : null;
100    var r2a10_91 = __asciiHex("SP Name 1");
101    bind.checkData("S10-C2 serviceProviderName SP Name 1", r2a10_91, r2e10 === null ? "absent" : (r2e10["91"] === undefined ? "absent" : r2e10["91"]));
102    var r2a10_92 = __asciiHex("Operational Profile Name 1");
103    bind.checkData("S10-C2 profileName Operational Profile Name 1", r2a10_92, r2e10 === null ? "absent" : (r2e10["92"] === undefined ? "absent" : r2e10["92"]));
104    bind.checkData("S10-C2 iconType", "01", r2e10 === null ? "absent" : (r2e10["93"] === undefined ? "absent" : r2e10["93"]));
105    bind.checkData("S10-C2 icon present", "1", (r2e10 !== null && r2e10["94"] !== undefined) ? "1" : "0");
106    // S10-C2: profilePolicyRules {ppr2} 等值比对基准 = PprIds BIT STRING 位定位 oracle(模块未入包)
107    // ——运行时无比对操作数,发射 fail-closed 恒断言诚实面(如实计错,不伪造通过)。
108    bind.checkData("S10-C2 profilePolicyRules {ppr2} oracle", "ppr_bits_oracle_declared", "oracle_absent_ppr_bits_module_vacuum");
109    // S10-C3: kind 'requirement' pattern 'profilePolicyRules per R_GET_UPDATE_N1' has no static generation face (corpus vacuum; see CaseIR unresolved).
110    // S10-C3: binding:bf2d_query_structure_satisfies_requirement(S22-prof_info) (check_attestation)
111
112    // 步骤 11:Seq#02 IC1/1: RESET(PROC_EUICC_INITIALIZATION_SEQUENCE 展开1/4,K_annexC2_procs 表1256)(procedure_expansion)
113    var s11 = bind.resetAndAtr();
114    bind.checkData("S11-C1 ATR_present", "1", s11.atr_hex !== "" ? "1" : "0");
115
116    // 步骤 12:Seq#02 IC1/2: [SELECT_MF](展开2/4)(procedure_expansion)
117    // FCP outer tag not materialized from clause: tag-face asserted only when corpus fixes the tag byte (e.g. TS 102 221 FCP '62').
118    var s12 = bind.sendApdu("00", "A4", "00", "04", "3F00", "00", "9000");
119    bind.checkData("S12-C2 FCP_Template", "1", s12.resp.length > 0 ? "1" : "0");
120    bind.checkData("S12-C1 SW", "9000", s12.sw);
121
122    // 步骤 13:Seq#02 IC1/3: [TERMINAL_CAPABILITY_LPAd](展开3/4)(procedure_expansion)
123    var s13 = bind.sendApdu("80", "AA", "00", "00", "A9058100830107", null, "9000");
124    bind.checkData("S13-C1 SW", "9000", s13.sw);
125
126    // 步骤 14:Seq#02 IC1/4: [TERMINAL_PROFILE](展开4/4)(procedure_expansion)
127    var steady14 = bind.runToSteadyState(function () {
128        return bind.sendTerminalProfile("FFFFFFFF7F9D00DFBF00001FE2000000C7EB0000000168005000000000000200", "9000");
129    });
130    bind.checkData("S14-C1 final SW", "9000", steady14.final.sw);
131
132    // 步骤 15:Seq#02 1: MTD_SEND_SMS_PP(tc_step;REQ: RQ54_001, RQ54_002, RQ54_003, RQ54_004, RQ54_005, RQ54_006, RQ54_007, RQ54_009, RQ54_010, RQ54_011, RQ54_012, RQ54_013_1, RQ29_021, RQ24_021)
133    // MTD_SEND_SMS_PP ENVELOPE (H Annex C.1 表1238 Details: 80 C2 00 00 <L>): SCP80-packed SMS-PP body is runtime-domain
134    // (<MNO_SCP80_COUNTER>/<CC>/<C_APDUS_SCRIPT>) — no bytes fabricated; the embedded STORE DATA
135    // script executes via the proactive FETCH / TERMINAL RESPONSE chain, not in this response.
136    var s15 = bind.sendApdu("80", "C2", "00", "00", null, null, null);
137    bind.checkData("S15-C1 SW1 91", "91", s15.sw.substring(0, 2));
138
139    // 步骤 16:Seq#02 2: FETCH "XX"(tc_step;REQ: RQ54_015, RQ54_011)
140    // FETCH header literals follow the golden wire evidence 8012 (same
141    // anchor as runToSteadyState; J Annex D.4 has no FETCH row, D 2.2.2
142    // gives mechanism only). Le = pending length from the last 91XX
143    // (chain rule, binding-internal state).
144    var s16 = bind.fetchPending("80", "12", "00", "00", null);
145    // S16-C1: binding:fetch_sms_por_runtime_parse(MTD_CHECK_SMS_POR;H-annexC1) (check_attestation)
146    // S16-C2: binding:fetch_length_chaining_last_91xx_sw2(TS102223-6.3-NOTE1) (check_attestation)
147
148    // 步骤 17:Seq#02 3: TERMINAL RESPONSE(tc_step)
149    // TERMINAL RESPONSE data is dynamically built by the binding from the
150    // last FETCHed proactive command (D 2.2.2; buildTrData) - never static.
151    // Header literals follow the golden wire evidence 8014.
152    var s17 = bind.terminalResponseForPending("80", "14", "00", "00", "9000");
153    bind.checkData("S17-C1 SW", "9000", s17.sw);
154
155    // 步骤 18:Seq#02 4/1: [MANAGE_CHANNEL_OPEN](PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR 展开1/2,K_annexC2_procs 表1258)(procedure_expansion)
156    // CHANNEL_NUMBER extraction and dynamic CLA rebinding are CasBind internal state (chaining rule; no generated-code re-implementation).
157    var s18 = bind.manageChannelOpen("9000");
158    bind.checkData("S18-C1 SW", "9000", s18.sw);
159
160    // 步骤 19:Seq#02 4/2: MTD_SELECT(procedure_expansion)
161    // CLA = bound channel (cla_rule) and <L> length binding are CasBind internal state (chaining rule; no generated-code re-implementation).
162    var s19 = bind.sendApdu(null, "A4", "04", "00", "A0000005591010FFFFFFFF8900000100", "00", "9000");
163    // MTD_SELECT expected face is SW-only (K Annex C.2 open-channel procedure step 2: no FCI content assertion in corpus); no fabricated template parse.
164    bind.checkData("S19-C1 SW", "9000", s19.sw);
165
166    // 步骤 20:Seq#02 5: MTD_STORE_DATA(tc_step;REQ: RQ54_009, RQ54_012, RQ54_013_1, RQ57_120, RQ57_122, RQ57_123, RQ57_126)
167    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
168    var sdCla20 = s18.chan !== null ? (s18.chan <= 3 ? 128 + s18.chan : 188 + s18.chan).toString(16).toUpperCase() : null;
169    var s20 = bind.sendApdu(sdCla20, "E2", "91", "00", "BF2D15A00C5A0A989209012143658709F55C059192939499", "00", "9000");
170    bind.checkData("S20-C1 SW", "9000", s20.sw);
171    var r2p20 = BindEs10xProcProfile.walkChoiceList(s20.resp, {respTag: "BF2D", okTag: "A0", errTag: "81"});
172    var r2e20 = r2p20.elements.length > 0 ? r2p20.elements[0].fields : null;
173    var r2a20_91 = __asciiHex("SP Name 1");
174    bind.checkData("S20-C2 serviceProviderName SP Name 1", r2a20_91, r2e20 === null ? "absent" : (r2e20["91"] === undefined ? "absent" : r2e20["91"]));
175    var r2a20_92 = __asciiHex("Operational Profile Name 1");
176    bind.checkData("S20-C2 profileName Operational Profile Name 1", r2a20_92, r2e20 === null ? "absent" : (r2e20["92"] === undefined ? "absent" : r2e20["92"]));
177    bind.checkData("S20-C2 iconType", "00", r2e20 === null ? "absent" : (r2e20["93"] === undefined ? "absent" : r2e20["93"]));
178    bind.checkData("S20-C2 icon present", "1", (r2e20 !== null && r2e20["94"] !== undefined) ? "1" : "0");
179    // S20-C2: profilePolicyRules {ppr1} 等值比对基准 = PprIds BIT STRING 位定位 oracle(模块未入包)
180    // ——运行时无比对操作数,发射 fail-closed 恒断言诚实面(如实计错,不伪造通过)。
181    bind.checkData("S20-C2 profilePolicyRules {ppr1} oracle", "ppr_bits_oracle_declared", "oracle_absent_ppr_bits_module_vacuum");
182    // S20-C3: kind 'requirement' pattern 'profilePolicyRules per R_GET_UPDATE_N2' has no static generation face (corpus vacuum; see CaseIR unresolved).
183    // S20-C3: binding:bf2d_query_structure_satisfies_requirement(S22-prof_info) (check_attestation)
184
185    // 步骤 21:Seq#03 IC1/1: RESET(PROC_EUICC_INITIALIZATION_SEQUENCE 展开1/4,K_annexC2_procs 表1256)(procedure_expansion)
186    var s21 = bind.resetAndAtr();
187    bind.checkData("S21-C1 ATR_present", "1", s21.atr_hex !== "" ? "1" : "0");
188
189    // 步骤 22:Seq#03 IC1/2: [SELECT_MF](展开2/4)(procedure_expansion)
190    // FCP outer tag not materialized from clause: tag-face asserted only when corpus fixes the tag byte (e.g. TS 102 221 FCP '62').
191    var s22 = bind.sendApdu("00", "A4", "00", "04", "3F00", "00", "9000");
192    bind.checkData("S22-C2 FCP_Template", "1", s22.resp.length > 0 ? "1" : "0");
193    bind.checkData("S22-C1 SW", "9000", s22.sw);
194
195    // 步骤 23:Seq#03 IC1/3: [TERMINAL_CAPABILITY_LPAd](展开3/4)(procedure_expansion)
196    var s23 = bind.sendApdu("80", "AA", "00", "00", "A9058100830107", null, "9000");
197    bind.checkData("S23-C1 SW", "9000", s23.sw);
198
199    // 步骤 24:Seq#03 IC1/4: [TERMINAL_PROFILE](展开4/4)(procedure_expansion)
200    var steady24 = bind.runToSteadyState(function () {
201        return bind.sendTerminalProfile("FFFFFFFF7F9D00DFBF00001FE2000000C7EB0000000168005000000000000200", "9000");
202    });
203    bind.checkData("S24-C1 final SW", "9000", steady24.final.sw);
204
205    // 步骤 25:Seq#03 1: MTD_SEND_SMS_PP(tc_step;REQ: RQ54_001, RQ54_002, RQ54_003, RQ54_004, RQ54_005, RQ54_006, RQ54_007, RQ54_009, RQ54_010, RQ54_011, RQ54_012, RQ54_013_1, RQ29_021, RQ24_021)
206    // MTD_SEND_SMS_PP ENVELOPE (H Annex C.1 表1238 Details: 80 C2 00 00 <L>): SCP80-packed SMS-PP body is runtime-domain
207    // (<MNO_SCP80_COUNTER>/<CC>/<C_APDUS_SCRIPT>) — no bytes fabricated; the embedded STORE DATA
208    // script executes via the proactive FETCH / TERMINAL RESPONSE chain, not in this response.
209    var s25 = bind.sendApdu("80", "C2", "00", "00", null, null, null);
210    bind.checkData("S25-C1 SW1 91", "91", s25.sw.substring(0, 2));
211
212    // 步骤 26:Seq#03 2: FETCH "XX"(tc_step;REQ: RQ54_015, RQ54_011)
213    // FETCH header literals follow the golden wire evidence 8012 (same
214    // anchor as runToSteadyState; J Annex D.4 has no FETCH row, D 2.2.2
215    // gives mechanism only). Le = pending length from the last 91XX
216    // (chain rule, binding-internal state).
217    var s26 = bind.fetchPending("80", "12", "00", "00", null);
218    // S26-C1: binding:fetch_sms_por_runtime_parse(MTD_CHECK_SMS_POR;H-annexC1) (check_attestation)
219    // S26-C2: binding:fetch_length_chaining_last_91xx_sw2(TS102223-6.3-NOTE1) (check_attestation)
220
221    // 步骤 27:Seq#03 3: TERMINAL RESPONSE(tc_step)
222    // TERMINAL RESPONSE data is dynamically built by the binding from the
223    // last FETCHed proactive command (D 2.2.2; buildTrData) - never static.
224    // Header literals follow the golden wire evidence 8014.
225    var s27 = bind.terminalResponseForPending("80", "14", "00", "00", "9000");
226    bind.checkData("S27-C1 SW", "9000", s27.sw);
227
228    // 步骤 28:Seq#03 4/1: [MANAGE_CHANNEL_OPEN](PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR 展开1/2,K_annexC2_procs 表1258)(procedure_expansion)
229    // CHANNEL_NUMBER extraction and dynamic CLA rebinding are CasBind internal state (chaining rule; no generated-code re-implementation).
230    var s28 = bind.manageChannelOpen("9000");
231    bind.checkData("S28-C1 SW", "9000", s28.sw);
232
233    // 步骤 29:Seq#03 4/2: MTD_SELECT(procedure_expansion)
234    // CLA = bound channel (cla_rule) and <L> length binding are CasBind internal state (chaining rule; no generated-code re-implementation).
235    var s29 = bind.sendApdu(null, "A4", "04", "00", "A0000005591010FFFFFFFF8900000100", "00", "9000");
236    // MTD_SELECT expected face is SW-only (K Annex C.2 open-channel procedure step 2: no FCI content assertion in corpus); no fabricated template parse.
237    bind.checkData("S29-C1 SW", "9000", s29.sw);
238
239    // 步骤 30:Seq#03 5: MTD_STORE_DATA(tc_step;REQ: RQ54_009, RQ54_012, RQ54_013_1, RQ57_120, RQ57_122, RQ57_123, RQ57_126)
240    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
241    var sdCla30 = s28.chan !== null ? (s28.chan <= 3 ? 128 + s28.chan : 188 + s28.chan).toString(16).toUpperCase() : null;
242    var s30 = bind.sendApdu(sdCla30, "E2", "91", "00", "BF2D15A00C5A0A989209012143658709F55C059192939499", "00", "9000");
243    bind.checkData("S30-C1 SW", "9000", s30.sw);
244    var r2p30 = BindEs10xProcProfile.walkChoiceList(s30.resp, {respTag: "BF2D", okTag: "A0", errTag: "81"});
245    var r2e30 = r2p30.elements.length > 0 ? r2p30.elements[0].fields : null;
246    var r2a30_91 = __asciiHex("SP Name 2");
247    bind.checkData("S30-C2 serviceProviderName SP Name 2", r2a30_91, r2e30 === null ? "absent" : (r2e30["91"] === undefined ? "absent" : r2e30["91"]));
248    var r2a30_92 = __asciiHex("Operational Profile Name 2");
249    bind.checkData("S30-C2 profileName Operational Profile Name 2", r2a30_92, r2e30 === null ? "absent" : (r2e30["92"] === undefined ? "absent" : r2e30["92"]));
250    bind.checkData("S30-C2 profilePolicyRules absent", "absent", (r2e30 === null || r2e30["99"] === undefined) ? "absent" : r2e30["99"]);
251    bind.checkData("S30-C2 iconType", "01", r2e30 === null ? "absent" : (r2e30["93"] === undefined ? "absent" : r2e30["93"]));
252    bind.checkData("S30-C2 icon present", "1", (r2e30 !== null && r2e30["94"] !== undefined) ? "1" : "0");
253    // S30-C3: kind 'requirement' pattern 'profilePolicyRules per R_GET_UPDATE_N3' has no static generation face (corpus vacuum; see CaseIR unresolved).
254    // S30-C3: binding:bf2d_query_structure_satisfies_requirement(S22-prof_info) (check_attestation)
255
256    // 步骤 31:Seq#04 IC1/1: RESET(PROC_EUICC_INITIALIZATION_SEQUENCE 展开1/4,K_annexC2_procs 表1256)(procedure_expansion)
257    var s31 = bind.resetAndAtr();
258    bind.checkData("S31-C1 ATR_present", "1", s31.atr_hex !== "" ? "1" : "0");
259
260    // 步骤 32:Seq#04 IC1/2: [SELECT_MF](展开2/4)(procedure_expansion)
261    // FCP outer tag not materialized from clause: tag-face asserted only when corpus fixes the tag byte (e.g. TS 102 221 FCP '62').
262    var s32 = bind.sendApdu("00", "A4", "00", "04", "3F00", "00", "9000");
263    bind.checkData("S32-C2 FCP_Template", "1", s32.resp.length > 0 ? "1" : "0");
264    bind.checkData("S32-C1 SW", "9000", s32.sw);
265
266    // 步骤 33:Seq#04 IC1/3: [TERMINAL_CAPABILITY_LPAd](展开3/4)(procedure_expansion)
267    var s33 = bind.sendApdu("80", "AA", "00", "00", "A9058100830107", null, "9000");
268    bind.checkData("S33-C1 SW", "9000", s33.sw);
269
270    // 步骤 34:Seq#04 IC1/4: [TERMINAL_PROFILE](展开4/4)(procedure_expansion)
271    var steady34 = bind.runToSteadyState(function () {
272        return bind.sendTerminalProfile("FFFFFFFF7F9D00DFBF00001FE2000000C7EB0000000168005000000000000200", "9000");
273    });
274    bind.checkData("S34-C1 final SW", "9000", steady34.final.sw);
275
276    // 步骤 35:Seq#04 1: MTD_SEND_SMS_PP(tc_step;REQ: RQ54_001, RQ54_002, RQ54_003, RQ54_004, RQ54_005, RQ54_006, RQ54_007, RQ54_009, RQ54_010, RQ54_011, RQ54_013, RQ54_013_1, RQ29_021, RQ24_021)
277    // MTD_SEND_SMS_PP ENVELOPE (H Annex C.1 表1238 Details: 80 C2 00 00 <L>): SCP80-packed SMS-PP body is runtime-domain
278    // (<MNO_SCP80_COUNTER>/<CC>/<C_APDUS_SCRIPT>) — no bytes fabricated; the embedded STORE DATA
279    // script executes via the proactive FETCH / TERMINAL RESPONSE chain, not in this response.
280    var s35 = bind.sendApdu("80", "C2", "00", "00", null, null, null);
281    bind.checkData("S35-C1 SW1 91", "91", s35.sw.substring(0, 2));
282
283    // 步骤 36:Seq#04 2: FETCH "XX"(tc_step;REQ: RQ54_015, RQ54_011)
284    // FETCH header literals follow the golden wire evidence 8012 (same
285    // anchor as runToSteadyState; J Annex D.4 has no FETCH row, D 2.2.2
286    // gives mechanism only). Le = pending length from the last 91XX
287    // (chain rule, binding-internal state).
288    var s36 = bind.fetchPending("80", "12", "00", "00", null);
289    // S36-C1: binding:fetch_sms_por_runtime_parse(MTD_CHECK_SMS_POR;H-annexC1) (check_attestation)
290    // S36-C2: binding:fetch_length_chaining_last_91xx_sw2(TS102223-6.3-NOTE1) (check_attestation)
291
292    // 步骤 37:Seq#04 3: TERMINAL RESPONSE(tc_step)
293    // TERMINAL RESPONSE data is dynamically built by the binding from the
294    // last FETCHed proactive command (D 2.2.2; buildTrData) - never static.
295    // Header literals follow the golden wire evidence 8014.
296    var s37 = bind.terminalResponseForPending("80", "14", "00", "00", "9000");
297    bind.checkData("S37-C1 SW", "9000", s37.sw);
298
299    // 步骤 38:Seq#04 4/1: [MANAGE_CHANNEL_OPEN](PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR 展开1/2,K_annexC2_procs 表1258)(procedure_expansion)
300    // CHANNEL_NUMBER extraction and dynamic CLA rebinding are CasBind internal state (chaining rule; no generated-code re-implementation).
301    var s38 = bind.manageChannelOpen("9000");
302    bind.checkData("S38-C1 SW", "9000", s38.sw);
303
304    // 步骤 39:Seq#04 4/2: MTD_SELECT(procedure_expansion)
305    // CLA = bound channel (cla_rule) and <L> length binding are CasBind internal state (chaining rule; no generated-code re-implementation).
306    var s39 = bind.sendApdu(null, "A4", "04", "00", "A0000005591010FFFFFFFF8900000100", "00", "9000");
307    // MTD_SELECT expected face is SW-only (K Annex C.2 open-channel procedure step 2: no FCI content assertion in corpus); no fabricated template parse.
308    bind.checkData("S39-C1 SW", "9000", s39.sw);
309
310    // 步骤 40:Seq#04 5: MTD_STORE_DATA(tc_step;REQ: RQ54_013, RQ54_013_1, RQ54_009, RQ57_120, RQ57_122, RQ57_123, RQ57_126)
311    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
312    var sdCla40 = s38.chan !== null ? (s38.chan <= 3 ? 128 + s38.chan : 188 + s38.chan).toString(16).toUpperCase() : null;
313    var s40 = bind.sendApdu(sdCla40, "E2", "91", "00", "BF2D15A00C5A0A989209012143658709F55C059192939499", "00", "9000");
314    bind.checkData("S40-C1 SW", "9000", s40.sw);
315    var r2p40 = BindEs10xProcProfile.walkChoiceList(s40.resp, {respTag: "BF2D", okTag: "A0", errTag: "81"});
316    var r2e40 = r2p40.elements.length > 0 ? r2p40.elements[0].fields : null;
317    bind.checkData("S40-C2 serviceProviderName absent", "absent", (r2e40 === null || r2e40["91"] === undefined) ? "absent" : r2e40["91"]);
318    bind.checkData("S40-C2 profileName absent", "absent", (r2e40 === null || r2e40["92"] === undefined) ? "absent" : r2e40["92"]);
319    bind.checkData("S40-C2 profilePolicyRules absent", "absent", (r2e40 === null || r2e40["99"] === undefined) ? "absent" : r2e40["99"]);
320    bind.checkData("S40-C2 iconType", "01", r2e40 === null ? "absent" : (r2e40["93"] === undefined ? "absent" : r2e40["93"]));
321    bind.checkData("S40-C2 icon present", "1", (r2e40 !== null && r2e40["94"] !== undefined) ? "1" : "0");
322    // S40-C3: kind 'requirement' pattern 'profilePolicyRules per R_GET_UPDATE_N4' has no static generation face (corpus vacuum; see CaseIR unresolved).
323    // S40-C3: binding:bf2d_query_structure_satisfies_requirement(S22-prof_info) (check_attestation)
324
325    // 步骤 41:Seq#06 IC1/1: RESET(PROC_EUICC_INITIALIZATION_SEQUENCE 展开1/4,K_annexC2_procs 表1256)(procedure_expansion)
326    var s41 = bind.resetAndAtr();
327    bind.checkData("S41-C1 ATR_present", "1", s41.atr_hex !== "" ? "1" : "0");
328
329    // 步骤 42:Seq#06 IC1/2: [SELECT_MF](展开2/4)(procedure_expansion)
330    // FCP outer tag not materialized from clause: tag-face asserted only when corpus fixes the tag byte (e.g. TS 102 221 FCP '62').
331    var s42 = bind.sendApdu("00", "A4", "00", "04", "3F00", "00", "9000");
332    bind.checkData("S42-C2 FCP_Template", "1", s42.resp.length > 0 ? "1" : "0");
333    bind.checkData("S42-C1 SW", "9000", s42.sw);
334
335    // 步骤 43:Seq#06 IC1/3: [TERMINAL_CAPABILITY_LPAd](展开3/4)(procedure_expansion)
336    var s43 = bind.sendApdu("80", "AA", "00", "00", "A9058100830107", null, "9000");
337    bind.checkData("S43-C1 SW", "9000", s43.sw);
338
339    // 步骤 44:Seq#06 IC1/4: [TERMINAL_PROFILE](展开4/4)(procedure_expansion)
340    var steady44 = bind.runToSteadyState(function () {
341        return bind.sendTerminalProfile("FFFFFFFF7F9D00DFBF00001FE2000000C7EB0000000168005000000000000200", "9000");
342    });
343    bind.checkData("S44-C1 final SW", "9000", steady44.final.sw);
344
345    // 步骤 45:Seq#06 IC2: MTD_SEND_SMS_PP(tc_step)
346    // MTD_SEND_SMS_PP ENVELOPE (H Annex C.1 表1238 Details: 80 C2 00 00 <L>): SCP80-packed SMS-PP body is runtime-domain
347    // (<MNO_SCP80_COUNTER>/<CC>/<C_APDUS_SCRIPT>) — no bytes fabricated; the embedded STORE DATA
348    // script executes via the proactive FETCH / TERMINAL RESPONSE chain, not in this response.
349    var s45 = bind.sendApdu("80", "C2", "00", "00", null, null, null);
350    bind.checkData("S45-C1 SW1 91", "91", s45.sw.substring(0, 2));
351
352    // 步骤 46:Seq#06 IC3: FETCH "XX"(tc_step)
353    // FETCH header literals follow the golden wire evidence 8012 (same
354    // anchor as runToSteadyState; J Annex D.4 has no FETCH row, D 2.2.2
355    // gives mechanism only). Le = pending length from the last 91XX
356    // (chain rule, binding-internal state).
357    var s46 = bind.fetchPending("80", "12", "00", "00", null);
358    // S46-C1: binding:fetch_sms_por_runtime_parse(MTD_CHECK_SMS_POR;H-annexC1) (check_attestation)
359    // S46-C2: binding:fetch_length_chaining_last_91xx_sw2(TS102223-6.3-NOTE1) (check_attestation)
360
361    // 步骤 47:Seq#06 IC4: TERMINAL RESPONSE(tc_step)
362    // TERMINAL RESPONSE data is dynamically built by the binding from the
363    // last FETCHed proactive command (D 2.2.2; buildTrData) - never static.
364    // Header literals follow the golden wire evidence 8014.
365    var s47 = bind.terminalResponseForPending("80", "14", "00", "00", "9000");
366    bind.checkData("S47-C1 SW", "9000", s47.sw);
367
368    // 步骤 48:Seq#06 1: MTD_SEND_SMS_PP(tc_step;REQ: RQ54_001, RQ54_002, RQ54_003, RQ54_004, RQ54_005, RQ54_006, RQ54_007, RQ54_009, RQ54_010, RQ54_011, RQ54_013, RQ54_015, RQ54_013_1, RQ29_021, RQ24_021)
369    // MTD_SEND_SMS_PP ENVELOPE (H Annex C.1 表1238 Details: 80 C2 00 00 <L>): SCP80-packed SMS-PP body is runtime-domain
370    // (<MNO_SCP80_COUNTER>/<CC>/<C_APDUS_SCRIPT>) — no bytes fabricated; the embedded STORE DATA
371    // script executes via the proactive FETCH / TERMINAL RESPONSE chain, not in this response.
372    var s48 = bind.sendApdu("80", "C2", "00", "00", null, null, null);
373    bind.checkData("S48-C1 SW1 91", "91", s48.sw.substring(0, 2));
374
375    // 步骤 49:Seq#06 2: FETCH "XX"(tc_step)
376    // FETCH header literals follow the golden wire evidence 8012 (same
377    // anchor as runToSteadyState; J Annex D.4 has no FETCH row, D 2.2.2
378    // gives mechanism only). Le = pending length from the last 91XX
379    // (chain rule, binding-internal state).
380    var s49 = bind.fetchPending("80", "12", "00", "00", null);
381    // S49-C1: binding:fetch_sms_por_runtime_parse(MTD_CHECK_SMS_POR;H-annexC1) (check_attestation)
382    // S49-C2: binding:fetch_length_chaining_last_91xx_sw2(TS102223-6.3-NOTE1) (check_attestation)
383
384    // 步骤 50:Seq#06 3: TERMINAL RESPONSE(tc_step)
385    // TERMINAL RESPONSE data is dynamically built by the binding from the
386    // last FETCHed proactive command (D 2.2.2; buildTrData) - never static.
387    // Header literals follow the golden wire evidence 8014.
388    var s50 = bind.terminalResponseForPending("80", "14", "00", "00", "9000");
389    bind.checkData("S50-C1 SW", "9000", s50.sw);
390
391    // 步骤 51:Seq#06 4/1: [MANAGE_CHANNEL_OPEN](PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR 展开1/2,K_annexC2_procs 表1258)(procedure_expansion)
392    // CHANNEL_NUMBER extraction and dynamic CLA rebinding are CasBind internal state (chaining rule; no generated-code re-implementation).
393    var s51 = bind.manageChannelOpen("9000");
394    bind.checkData("S51-C1 SW", "9000", s51.sw);
395
396    // 步骤 52:Seq#06 4/2: MTD_SELECT(procedure_expansion)
397    // CLA = bound channel (cla_rule) and <L> length binding are CasBind internal state (chaining rule; no generated-code re-implementation).
398    var s52 = bind.sendApdu(null, "A4", "04", "00", "A0000005591010FFFFFFFF8900000100", "00", "9000");
399    // MTD_SELECT expected face is SW-only (K Annex C.2 open-channel procedure step 2: no FCI content assertion in corpus); no fabricated template parse.
400    bind.checkData("S52-C1 SW", "9000", s52.sw);
401
402    // 步骤 53:Seq#06 5: MTD_STORE_DATA(tc_step;REQ: RQ54_013, RQ54_013_1, RQ54_009, RQ57_120, RQ57_122, RQ57_123, RQ57_126)
403    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
404    var sdCla53 = s51.chan !== null ? (s51.chan <= 3 ? 128 + s51.chan : 188 + s51.chan).toString(16).toUpperCase() : null;
405    var s53 = bind.sendApdu(sdCla53, "E2", "91", "00", "BF2D15A00C5A0A989209012143658709F55C059192939499", "00", "9000");
406    bind.checkData("S53-C1 SW", "9000", s53.sw);
407    var r2p53 = BindEs10xProcProfile.walkChoiceList(s53.resp, {respTag: "BF2D", okTag: "A0", errTag: "81"});
408    var r2e53 = r2p53.elements.length > 0 ? r2p53.elements[0].fields : null;
409    var r2a53_91 = __asciiHex("SP Name 2");
410    bind.checkData("S53-C2 serviceProviderName SP Name 2", r2a53_91, r2e53 === null ? "absent" : (r2e53["91"] === undefined ? "absent" : r2e53["91"]));
411    var r2a53_92 = __asciiHex("Operational Profile Name 2");
412    bind.checkData("S53-C2 profileName Operational Profile Name 2", r2a53_92, r2e53 === null ? "absent" : (r2e53["92"] === undefined ? "absent" : r2e53["92"]));
413    bind.checkData("S53-C2 profilePolicyRules absent", "absent", (r2e53 === null || r2e53["99"] === undefined) ? "absent" : r2e53["99"]);
414    bind.checkData("S53-C2 iconType", "01", r2e53 === null ? "absent" : (r2e53["93"] === undefined ? "absent" : r2e53["93"]));
415    bind.checkData("S53-C2 icon present", "1", (r2e53 !== null && r2e53["94"] !== undefined) ? "1" : "0");
416    // S53-C3: kind 'requirement' pattern 'profilePolicyRules per R_GET_UPDATE_N6' has no static generation face (corpus vacuum; see CaseIR unresolved).
417    // S53-C3: binding:bf2d_query_structure_satisfies_requirement(S22-prof_info) (check_attestation)
418
419    // 步骤 54:Seq#07 IC1/1: RESET(PROC_EUICC_INITIALIZATION_SEQUENCE 展开1/4,K_annexC2_procs 表1256)(procedure_expansion)
420    var s54 = bind.resetAndAtr();
421    bind.checkData("S54-C1 ATR_present", "1", s54.atr_hex !== "" ? "1" : "0");
422
423    // 步骤 55:Seq#07 IC1/2: [SELECT_MF](展开2/4)(procedure_expansion)
424    // FCP outer tag not materialized from clause: tag-face asserted only when corpus fixes the tag byte (e.g. TS 102 221 FCP '62').
425    var s55 = bind.sendApdu("00", "A4", "00", "04", "3F00", "00", "9000");
426    bind.checkData("S55-C2 FCP_Template", "1", s55.resp.length > 0 ? "1" : "0");
427    bind.checkData("S55-C1 SW", "9000", s55.sw);
428
429    // 步骤 56:Seq#07 IC1/3: [TERMINAL_CAPABILITY_LPAd](展开3/4)(procedure_expansion)
430    var s56 = bind.sendApdu("80", "AA", "00", "00", "A9058100830107", null, "9000");
431    bind.checkData("S56-C1 SW", "9000", s56.sw);
432
433    // 步骤 57:Seq#07 IC1/4: [TERMINAL_PROFILE](展开4/4)(procedure_expansion)
434    var steady57 = bind.runToSteadyState(function () {
435        return bind.sendTerminalProfile("FFFFFFFF7F9D00DFBF00001FE2000000C7EB0000000168005000000000000200", "9000");
436    });
437    bind.checkData("S57-C1 final SW", "9000", steady57.final.sw);
438
439    // 步骤 58:Seq#07 1: MTD_SEND_SMS_PP(tc_step;REQ: RQ24_021, RQ54_001, RQ54_002, RQ54_003, RQ54_004, RQ54_005, RQ54_006, RQ54_010, RQ54_011)
440    // MTD_SEND_SMS_PP ENVELOPE (H Annex C.1 表1238 Details: 80 C2 00 00 <L>): SCP80-packed SMS-PP body is runtime-domain
441    // (<MNO_SCP80_COUNTER>/<CC>/<C_APDUS_SCRIPT>) — no bytes fabricated; the embedded STORE DATA
442    // script executes via the proactive FETCH / TERMINAL RESPONSE chain, not in this response.
443    var s58 = bind.sendApdu("80", "C2", "00", "00", null, null, null);
444    bind.checkData("S58-C1 SW1 91", "91", s58.sw.substring(0, 2));
445
446    // 步骤 59:Seq#07 2: FETCH "XX"(tc_step;REQ: RQ54_008, RQ54_014, RQ54_015, RQ54_016, RQ54_011)
447    // FETCH header literals follow the golden wire evidence 8012 (same
448    // anchor as runToSteadyState; J Annex D.4 has no FETCH row, D 2.2.2
449    // gives mechanism only). Le = pending length from the last 91XX
450    // (chain rule, binding-internal state).
451    var s59 = bind.fetchPending("80", "12", "00", "00", null);
452    // S59-C1: binding:fetch_sms_por_runtime_parse(MTD_CHECK_SMS_POR;H-annexC1) (check_attestation)
453    // S59-C2: binding:fetch_length_chaining_last_91xx_sw2(TS102223-6.3-NOTE1) (check_attestation)
454
455    // 步骤 60:Seq#07 3: TERMINAL RESPONSE(tc_step)
456    // TERMINAL RESPONSE data is dynamically built by the binding from the
457    // last FETCHed proactive command (D 2.2.2; buildTrData) - never static.
458    // Header literals follow the golden wire evidence 8014.
459    var s60 = bind.terminalResponseForPending("80", "14", "00", "00", "9000");
460    bind.checkData("S60-C1 SW", "9000", s60.sw);
461
462    // 步骤 61:Seq#07 4/1: [MANAGE_CHANNEL_OPEN](PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR 展开1/2,K_annexC2_procs 表1258)(procedure_expansion)
463    // CHANNEL_NUMBER extraction and dynamic CLA rebinding are CasBind internal state (chaining rule; no generated-code re-implementation).
464    var s61 = bind.manageChannelOpen("9000");
465    bind.checkData("S61-C1 SW", "9000", s61.sw);
466
467    // 步骤 62:Seq#07 4/2: MTD_SELECT(procedure_expansion)
468    // CLA = bound channel (cla_rule) and <L> length binding are CasBind internal state (chaining rule; no generated-code re-implementation).
469    var s62 = bind.sendApdu(null, "A4", "04", "00", "A0000005591010FFFFFFFF8900000100", "00", "9000");
470    // MTD_SELECT expected face is SW-only (K Annex C.2 open-channel procedure step 2: no FCI content assertion in corpus); no fabricated template parse.
471    bind.checkData("S62-C1 SW", "9000", s62.sw);
472
473    // 步骤 63:Seq#07 5: MTD_STORE_DATA(tc_step;REQ: RQ54_014, RQ57_120, RQ57_122, RQ57_123, RQ57_126)
474    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
475    var sdCla63 = s61.chan !== null ? (s61.chan <= 3 ? 128 + s61.chan : 188 + s61.chan).toString(16).toUpperCase() : null;
476    var s63 = bind.sendApdu(sdCla63, "E2", "91", "00", "BF2D15A00C5A0A989209012143658709F55C059192939499", "00", "9000");
477    bind.checkData("S63-C1 SW", "9000", s63.sw);
478    var r2p63 = BindEs10xProcProfile.walkChoiceList(s63.resp, {respTag: "BF2D", okTag: "A0", errTag: "81"});
479    bind.checkData("S63-C2 profileInfoListOk present", "1", (r2p63.branch_tag === "A0" && r2p63.elements.length >= 1) ? "1" : "0");
480    // S63-C3: kind 'requirement' pattern 'metadata unchanged (SP_NAME1/NAME_OP_PROF1/png/ICON_OP_PROF1/{ppr1,ppr2})' has no static generation face (corpus vacuum; see CaseIR unresolved).
481    // S63-C3: binding:bf2d_query_structure_satisfies_requirement(S22-prof_info) (check_attestation)
482
483    // 步骤 64:Seq#08 IC1/1: RESET(PROC_EUICC_INITIALIZATION_SEQUENCE 展开1/4,K_annexC2_procs 表1256)(procedure_expansion)
484    var s64 = bind.resetAndAtr();
485    bind.checkData("S64-C1 ATR_present", "1", s64.atr_hex !== "" ? "1" : "0");
486
487    // 步骤 65:Seq#08 IC1/2: [SELECT_MF](展开2/4)(procedure_expansion)
488    // FCP outer tag not materialized from clause: tag-face asserted only when corpus fixes the tag byte (e.g. TS 102 221 FCP '62').
489    var s65 = bind.sendApdu("00", "A4", "00", "04", "3F00", "00", "9000");
490    bind.checkData("S65-C2 FCP_Template", "1", s65.resp.length > 0 ? "1" : "0");
491    bind.checkData("S65-C1 SW", "9000", s65.sw);
492
493    // 步骤 66:Seq#08 IC1/3: [TERMINAL_CAPABILITY_LPAd](展开3/4)(procedure_expansion)
494    var s66 = bind.sendApdu("80", "AA", "00", "00", "A9058100830107", null, "9000");
495    bind.checkData("S66-C1 SW", "9000", s66.sw);
496
497    // 步骤 67:Seq#08 IC1/4: [TERMINAL_PROFILE](展开4/4)(procedure_expansion)
498    var steady67 = bind.runToSteadyState(function () {
499        return bind.sendTerminalProfile("FFFFFFFF7F9D00DFBF00001FE2000000C7EB0000000168005000000000000200", "9000");
500    });
501    bind.checkData("S67-C1 final SW", "9000", steady67.final.sw);
502
503    // 步骤 68:Seq#08 1: MTD_SEND_SMS_PP(tc_step;REQ: RQ54_001, RQ54_002, RQ54_003, RQ54_004, RQ54_005, RQ54_006, RQ54_010, RQ54_011, RQ24_024, RQ24_021)
504    // MTD_SEND_SMS_PP ENVELOPE (H Annex C.1 表1238 Details: 80 C2 00 00 <L>): SCP80-packed SMS-PP body is runtime-domain
505    // (<MNO_SCP80_COUNTER>/<CC>/<C_APDUS_SCRIPT>) — no bytes fabricated; the embedded STORE DATA
506    // script executes via the proactive FETCH / TERMINAL RESPONSE chain, not in this response.
507    var s68 = bind.sendApdu("80", "C2", "00", "00", null, null, null);
508    // S68-C1: binding:scp80_envelope_response_status_disjunctive(91XX|9000|error;E_tc_527-NOTE) (check_attestation)
509
510    // 步骤 69:Seq#08 2: FETCH "XX"(tc_step;REQ: RQ54_011, RQ54_014)
511    // FETCH header literals follow the golden wire evidence 8012 (same
512    // anchor as runToSteadyState; J Annex D.4 has no FETCH row, D 2.2.2
513    // gives mechanism only). Le = pending length from the last 91XX
514    // (chain rule, binding-internal state).
515    var s69 = bind.fetchPending("80", "12", "00", "00", null);
516    // S69-C1: binding:fetch_sms_por_runtime_parse(MTD_CHECK_SMS_POR;H-annexC1) (check_attestation)
517    // S69-C2: binding:fetch_length_chaining_last_91xx_sw2(TS102223-6.3-NOTE1) (check_attestation)
518
519    // 步骤 70:Seq#08 3: TERMINAL RESPONSE(tc_step)
520    // TERMINAL RESPONSE data is dynamically built by the binding from the
521    // last FETCHed proactive command (D 2.2.2; buildTrData) - never static.
522    // Header literals follow the golden wire evidence 8014.
523    var s70 = bind.terminalResponseForPending("80", "14", "00", "00", "9000");
524    bind.checkData("S70-C1 SW", "9000", s70.sw);
525
526    // 步骤 71:Seq#08 4/1: [MANAGE_CHANNEL_OPEN](PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR 展开1/2,K_annexC2_procs 表1258)(procedure_expansion)
527    // CHANNEL_NUMBER extraction and dynamic CLA rebinding are CasBind internal state (chaining rule; no generated-code re-implementation).
528    var s71 = bind.manageChannelOpen("9000");
529    bind.checkData("S71-C1 SW", "9000", s71.sw);
530
531    // 步骤 72:Seq#08 4/2: MTD_SELECT(procedure_expansion)
532    // CLA = bound channel (cla_rule) and <L> length binding are CasBind internal state (chaining rule; no generated-code re-implementation).
533    var s72 = bind.sendApdu(null, "A4", "04", "00", "A0000005591010FFFFFFFF8900000100", "00", "9000");
534    // MTD_SELECT expected face is SW-only (K Annex C.2 open-channel procedure step 2: no FCI content assertion in corpus); no fabricated template parse.
535    bind.checkData("S72-C1 SW", "9000", s72.sw);
536
537    // 步骤 73:Seq#08 5: MTD_STORE_DATA(tc_step;REQ: RQ54_014, RQ57_120, RQ57_122, RQ57_123, RQ57_126)
538    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
539    var sdCla73 = s71.chan !== null ? (s71.chan <= 3 ? 128 + s71.chan : 188 + s71.chan).toString(16).toUpperCase() : null;
540    var s73 = bind.sendApdu(sdCla73, "E2", "91", "00", "BF2D15A00C5A0A989209012143658709F55C059192939499", "00", "9000");
541    bind.checkData("S73-C1 SW", "9000", s73.sw);
542    var r2p73 = BindEs10xProcProfile.walkChoiceList(s73.resp, {respTag: "BF2D", okTag: "A0", errTag: "81"});
543    bind.checkData("S73-C2 profileInfoListOk present", "1", (r2p73.branch_tag === "A0" && r2p73.elements.length >= 1) ? "1" : "0");
544    // S73-C3: kind 'requirement' pattern 'metadata unchanged (SP_NAME1/NAME_OP_PROF1/png/ICON_OP_PROF1/{ppr1,ppr2})' has no static generation face (corpus vacuum; see CaseIR unresolved).
545    // S73-C3: binding:bf2d_query_structure_satisfies_requirement(S22-prof_info) (check_attestation)
546
547    // 步骤 74:Seq#09 IC1/1: RESET(PROC_EUICC_INITIALIZATION_SEQUENCE 展开1/4,K_annexC2_procs 表1256)(procedure_expansion)
548    var s74 = bind.resetAndAtr();
549    bind.checkData("S74-C1 ATR_present", "1", s74.atr_hex !== "" ? "1" : "0");
550
551    // 步骤 75:Seq#09 IC1/2: [SELECT_MF](展开2/4)(procedure_expansion)
552    // FCP outer tag not materialized from clause: tag-face asserted only when corpus fixes the tag byte (e.g. TS 102 221 FCP '62').
553    var s75 = bind.sendApdu("00", "A4", "00", "04", "3F00", "00", "9000");
554    bind.checkData("S75-C2 FCP_Template", "1", s75.resp.length > 0 ? "1" : "0");
555    bind.checkData("S75-C1 SW", "9000", s75.sw);
556
557    // 步骤 76:Seq#09 IC1/3: [TERMINAL_CAPABILITY_LPAd](展开3/4)(procedure_expansion)
558    var s76 = bind.sendApdu("80", "AA", "00", "00", "A9058100830107", null, "9000");
559    bind.checkData("S76-C1 SW", "9000", s76.sw);
560
561    // 步骤 77:Seq#09 IC1/4: [TERMINAL_PROFILE](展开4/4)(procedure_expansion)
562    var steady77 = bind.runToSteadyState(function () {
563        return bind.sendTerminalProfile("FFFFFFFF7F9D00DFBF00001FE2000000C7EB0000000168005000000000000200", "9000");
564    });
565    bind.checkData("S77-C1 final SW", "9000", steady77.final.sw);
566
567    // 步骤 78:Seq#09 1: MTD_SEND_SMS_PP(tc_step;REQ: RQ24_021, RQ54_001, RQ54_002, RQ54_003, RQ54_004, RQ54_005, RQ54_006, RQ54_010, RQ54_011)
568    // MTD_SEND_SMS_PP ENVELOPE (H Annex C.1 表1238 Details: 80 C2 00 00 <L>): SCP80-packed SMS-PP body is runtime-domain
569    // (<MNO_SCP80_COUNTER>/<CC>/<C_APDUS_SCRIPT>) — no bytes fabricated; the embedded STORE DATA
570    // script executes via the proactive FETCH / TERMINAL RESPONSE chain, not in this response.
571    var s78 = bind.sendApdu("80", "C2", "00", "00", null, null, null);
572    bind.checkData("S78-C1 SW1 91", "91", s78.sw.substring(0, 2));
573
574    // 步骤 79:Seq#09 2: FETCH "XX"(tc_step;REQ: RQ54_011, RQ54_014, RQ54_015)
575    // FETCH header literals follow the golden wire evidence 8012 (same
576    // anchor as runToSteadyState; J Annex D.4 has no FETCH row, D 2.2.2
577    // gives mechanism only). Le = pending length from the last 91XX
578    // (chain rule, binding-internal state).
579    var s79 = bind.fetchPending("80", "12", "00", "00", null);
580    // S79-C1: binding:fetch_sms_por_runtime_parse(MTD_CHECK_SMS_POR;H-annexC1) (check_attestation)
581    // S79-C2: binding:fetch_length_chaining_last_91xx_sw2(TS102223-6.3-NOTE1) (check_attestation)
582
583    // 步骤 80:Seq#09 3: TERMINAL RESPONSE(tc_step)
584    // TERMINAL RESPONSE data is dynamically built by the binding from the
585    // last FETCHed proactive command (D 2.2.2; buildTrData) - never static.
586    // Header literals follow the golden wire evidence 8014.
587    var s80 = bind.terminalResponseForPending("80", "14", "00", "00", "9000");
588    bind.checkData("S80-C1 SW", "9000", s80.sw);
589
590    // 步骤 81:Seq#09 4/1: [MANAGE_CHANNEL_OPEN](PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR 展开1/2,K_annexC2_procs 表1258)(procedure_expansion)
591    // CHANNEL_NUMBER extraction and dynamic CLA rebinding are CasBind internal state (chaining rule; no generated-code re-implementation).
592    var s81 = bind.manageChannelOpen("9000");
593    bind.checkData("S81-C1 SW", "9000", s81.sw);
594
595    // 步骤 82:Seq#09 4/2: MTD_SELECT(procedure_expansion)
596    // CLA = bound channel (cla_rule) and <L> length binding are CasBind internal state (chaining rule; no generated-code re-implementation).
597    var s82 = bind.sendApdu(null, "A4", "04", "00", "A0000005591010FFFFFFFF8900000100", "00", "9000");
598    // MTD_SELECT expected face is SW-only (K Annex C.2 open-channel procedure step 2: no FCI content assertion in corpus); no fabricated template parse.
599    bind.checkData("S82-C1 SW", "9000", s82.sw);
600
601    // 步骤 83:Seq#09 5: MTD_STORE_DATA(tc_step;REQ: RQ57_120, RQ57_122, RQ57_123, RQ57_126, RQ54_014)
602    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
603    var sdCla83 = s81.chan !== null ? (s81.chan <= 3 ? 128 + s81.chan : 188 + s81.chan).toString(16).toUpperCase() : null;
604    var s83 = bind.sendApdu(sdCla83, "E2", "91", "00", "BF2D15A00C5A0A989209012143658709F55C059192939499", "00", "9000");
605    bind.checkData("S83-C1 SW", "9000", s83.sw);
606    var r2p83 = BindEs10xProcProfile.walkChoiceList(s83.resp, {respTag: "BF2D", okTag: "A0", errTag: "81"});
607    bind.checkData("S83-C2 profileInfoListOk present", "1", (r2p83.branch_tag === "A0" && r2p83.elements.length >= 1) ? "1" : "0");
608    // S83-C3: kind 'requirement' pattern 'metadata unchanged (SP_NAME1/NAME_OP_PROF1/png/ICON_OP_PROF1/{ppr1,ppr2})' has no static generation face (corpus vacuum; see CaseIR unresolved).
609    // S83-C3: binding:bf2d_query_structure_satisfies_requirement(S22-prof_info) (check_attestation)
610
611    // 步骤 84:Seq#10 IC1/1: RESET(PROC_EUICC_INITIALIZATION_SEQUENCE 展开1/4,K_annexC2_procs 表1256)(procedure_expansion)
612    var s84 = bind.resetAndAtr();
613    bind.checkData("S84-C1 ATR_present", "1", s84.atr_hex !== "" ? "1" : "0");
614
615    // 步骤 85:Seq#10 IC1/2: [SELECT_MF](展开2/4)(procedure_expansion)
616    // FCP outer tag not materialized from clause: tag-face asserted only when corpus fixes the tag byte (e.g. TS 102 221 FCP '62').
617    var s85 = bind.sendApdu("00", "A4", "00", "04", "3F00", "00", "9000");
618    bind.checkData("S85-C2 FCP_Template", "1", s85.resp.length > 0 ? "1" : "0");
619    bind.checkData("S85-C1 SW", "9000", s85.sw);
620
621    // 步骤 86:Seq#10 IC1/3: [TERMINAL_CAPABILITY_LPAd](展开3/4)(procedure_expansion)
622    var s86 = bind.sendApdu("80", "AA", "00", "00", "A9058100830107", null, "9000");
623    bind.checkData("S86-C1 SW", "9000", s86.sw);
624
625    // 步骤 87:Seq#10 IC1/4: [TERMINAL_PROFILE](展开4/4)(procedure_expansion)
626    var steady87 = bind.runToSteadyState(function () {
627        return bind.sendTerminalProfile("FFFFFFFF7F9D00DFBF00001FE2000000C7EB0000000168005000000000000200", "9000");
628    });
629    bind.checkData("S87-C1 final SW", "9000", steady87.final.sw);
630
631    // 步骤 88:Seq#10 1: MTD_SEND_SMS_PP(tc_step;REQ: RQ24_021, RQ54_001, RQ54_002, RQ54_003, RQ54_004, RQ54_005, RQ54_006, RQ54_010, RQ54_011)
632    // MTD_SEND_SMS_PP ENVELOPE (H Annex C.1 表1238 Details: 80 C2 00 00 <L>): SCP80-packed SMS-PP body is runtime-domain
633    // (<MNO_SCP80_COUNTER>/<CC>/<C_APDUS_SCRIPT>) — no bytes fabricated; the embedded STORE DATA
634    // script executes via the proactive FETCH / TERMINAL RESPONSE chain, not in this response.
635    var s88 = bind.sendApdu("80", "C2", "00", "00", null, null, null);
636    bind.checkData("S88-C1 SW1 91", "91", s88.sw.substring(0, 2));
637
638    // 步骤 89:Seq#10 2: FETCH "XX"(tc_step;REQ: RQ54_011, RQ54_014, RQ54_015)
639    // FETCH header literals follow the golden wire evidence 8012 (same
640    // anchor as runToSteadyState; J Annex D.4 has no FETCH row, D 2.2.2
641    // gives mechanism only). Le = pending length from the last 91XX
642    // (chain rule, binding-internal state).
643    var s89 = bind.fetchPending("80", "12", "00", "00", null);
644    // S89-C1: binding:fetch_sms_por_runtime_parse(MTD_CHECK_SMS_POR;H-annexC1) (check_attestation)
645    // S89-C2: binding:fetch_length_chaining_last_91xx_sw2(TS102223-6.3-NOTE1) (check_attestation)
646
647    // 步骤 90:Seq#10 3: TERMINAL RESPONSE(tc_step)
648    // TERMINAL RESPONSE data is dynamically built by the binding from the
649    // last FETCHed proactive command (D 2.2.2; buildTrData) - never static.
650    // Header literals follow the golden wire evidence 8014.
651    var s90 = bind.terminalResponseForPending("80", "14", "00", "00", "9000");
652    bind.checkData("S90-C1 SW", "9000", s90.sw);
653
654    // 步骤 91:Seq#10 4/1: [MANAGE_CHANNEL_OPEN](PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR 展开1/2,K_annexC2_procs 表1258)(procedure_expansion)
655    // CHANNEL_NUMBER extraction and dynamic CLA rebinding are CasBind internal state (chaining rule; no generated-code re-implementation).
656    var s91 = bind.manageChannelOpen("9000");
657    bind.checkData("S91-C1 SW", "9000", s91.sw);
658
659    // 步骤 92:Seq#10 4/2: MTD_SELECT(procedure_expansion)
660    // CLA = bound channel (cla_rule) and <L> length binding are CasBind internal state (chaining rule; no generated-code re-implementation).
661    var s92 = bind.sendApdu(null, "A4", "04", "00", "A0000005591010FFFFFFFF8900000100", "00", "9000");
662    // MTD_SELECT expected face is SW-only (K Annex C.2 open-channel procedure step 2: no FCI content assertion in corpus); no fabricated template parse.
663    bind.checkData("S92-C1 SW", "9000", s92.sw);
664
665    // 步骤 93:Seq#10 5: MTD_STORE_DATA(tc_step;REQ: RQ54_014, RQ57_120, RQ57_122, RQ57_123, RQ57_126)
666    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
667    var sdCla93 = s91.chan !== null ? (s91.chan <= 3 ? 128 + s91.chan : 188 + s91.chan).toString(16).toUpperCase() : null;
668    var s93 = bind.sendApdu(sdCla93, "E2", "91", "00", "BF2D15A00C5A0A989209012143658709F55C059192939499", "00", "9000");
669    bind.checkData("S93-C1 SW", "9000", s93.sw);
670    var r2p93 = BindEs10xProcProfile.walkChoiceList(s93.resp, {respTag: "BF2D", okTag: "A0", errTag: "81"});
671    bind.checkData("S93-C2 profileInfoListOk present", "1", (r2p93.branch_tag === "A0" && r2p93.elements.length >= 1) ? "1" : "0");
672    // S93-C3: kind 'requirement' pattern 'metadata unchanged (SP_NAME1/NAME_OP_PROF1/png/ICON_OP_PROF1/{ppr1,ppr2})' has no static generation face (corpus vacuum; see CaseIR unresolved).
673    // S93-C3: binding:bf2d_query_structure_satisfies_requirement(S22-prof_info) (check_attestation)
674
675    // 步骤 94:Seq#11 IC1/1: RESET(PROC_EUICC_INITIALIZATION_SEQUENCE 展开1/4,K_annexC2_procs 表1256)(procedure_expansion)
676    var s94 = bind.resetAndAtr();
677    bind.checkData("S94-C1 ATR_present", "1", s94.atr_hex !== "" ? "1" : "0");
678
679    // 步骤 95:Seq#11 IC1/2: [SELECT_MF](展开2/4)(procedure_expansion)
680    // FCP outer tag not materialized from clause: tag-face asserted only when corpus fixes the tag byte (e.g. TS 102 221 FCP '62').
681    var s95 = bind.sendApdu("00", "A4", "00", "04", "3F00", "00", "9000");
682    bind.checkData("S95-C2 FCP_Template", "1", s95.resp.length > 0 ? "1" : "0");
683    bind.checkData("S95-C1 SW", "9000", s95.sw);
684
685    // 步骤 96:Seq#11 IC1/3: [TERMINAL_CAPABILITY_LPAd](展开3/4)(procedure_expansion)
686    var s96 = bind.sendApdu("80", "AA", "00", "00", "A9058100830107", null, "9000");
687    bind.checkData("S96-C1 SW", "9000", s96.sw);
688
689    // 步骤 97:Seq#11 IC1/4: [TERMINAL_PROFILE](展开4/4)(procedure_expansion)
690    var steady97 = bind.runToSteadyState(function () {
691        return bind.sendTerminalProfile("FFFFFFFF7F9D00DFBF00001FE2000000C7EB0000000168005000000000000200", "9000");
692    });
693    bind.checkData("S97-C1 final SW", "9000", steady97.final.sw);
694
695    // 步骤 98:Seq#11 1: MTD_SEND_SMS_PP(tc_step;REQ: RQ24_021, RQ54_001, RQ54_002, RQ54_003, RQ54_004, RQ54_005, RQ54_006, RQ54_010, RQ54_011)
696    // MTD_SEND_SMS_PP ENVELOPE (H Annex C.1 表1238 Details: 80 C2 00 00 <L>): SCP80-packed SMS-PP body is runtime-domain
697    // (<MNO_SCP80_COUNTER>/<CC>/<C_APDUS_SCRIPT>) — no bytes fabricated; the embedded STORE DATA
698    // script executes via the proactive FETCH / TERMINAL RESPONSE chain, not in this response.
699    var s98 = bind.sendApdu("80", "C2", "00", "00", null, null, null);
700    bind.checkData("S98-C1 SW1 91", "91", s98.sw.substring(0, 2));
701
702    // 步骤 99:Seq#11 2: FETCH "XX"(tc_step;REQ: RQ54_011, RQ54_014, RQ54_015)
703    // FETCH header literals follow the golden wire evidence 8012 (same
704    // anchor as runToSteadyState; J Annex D.4 has no FETCH row, D 2.2.2
705    // gives mechanism only). Le = pending length from the last 91XX
706    // (chain rule, binding-internal state).
707    var s99 = bind.fetchPending("80", "12", "00", "00", null);
708    // S99-C1: binding:fetch_sms_por_runtime_parse(MTD_CHECK_SMS_POR;H-annexC1) (check_attestation)
709    // S99-C2: binding:fetch_length_chaining_last_91xx_sw2(TS102223-6.3-NOTE1) (check_attestation)
710
711    // 步骤 100:Seq#11 3: TERMINAL RESPONSE(tc_step)
712    // TERMINAL RESPONSE data is dynamically built by the binding from the
713    // last FETCHed proactive command (D 2.2.2; buildTrData) - never static.
714    // Header literals follow the golden wire evidence 8014.
715    var s100 = bind.terminalResponseForPending("80", "14", "00", "00", "9000");
716    bind.checkData("S100-C1 SW", "9000", s100.sw);
717
718    // 步骤 101:Seq#11 4/1: [MANAGE_CHANNEL_OPEN](PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR 展开1/2,K_annexC2_procs 表1258)(procedure_expansion)
719    // CHANNEL_NUMBER extraction and dynamic CLA rebinding are CasBind internal state (chaining rule; no generated-code re-implementation).
720    var s101 = bind.manageChannelOpen("9000");
721    bind.checkData("S101-C1 SW", "9000", s101.sw);
722
723    // 步骤 102:Seq#11 4/2: MTD_SELECT(procedure_expansion)
724    // CLA = bound channel (cla_rule) and <L> length binding are CasBind internal state (chaining rule; no generated-code re-implementation).
725    var s102 = bind.sendApdu(null, "A4", "04", "00", "A0000005591010FFFFFFFF8900000100", "00", "9000");
726    // MTD_SELECT expected face is SW-only (K Annex C.2 open-channel procedure step 2: no FCI content assertion in corpus); no fabricated template parse.
727    bind.checkData("S102-C1 SW", "9000", s102.sw);
728
729    // 步骤 103:Seq#11 5: MTD_STORE_DATA(tc_step;REQ: RQ54_014, RQ57_120, RQ57_122, RQ57_123, RQ57_126)
730    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
731    var sdCla103 = s101.chan !== null ? (s101.chan <= 3 ? 128 + s101.chan : 188 + s101.chan).toString(16).toUpperCase() : null;
732    var s103 = bind.sendApdu(sdCla103, "E2", "91", "00", "BF2D15A00C5A0A989209012143658709F55C059192939499", "00", "9000");
733    bind.checkData("S103-C1 SW", "9000", s103.sw);
734    var r2p103 = BindEs10xProcProfile.walkChoiceList(s103.resp, {respTag: "BF2D", okTag: "A0", errTag: "81"});
735    bind.checkData("S103-C2 profileInfoListOk present", "1", (r2p103.branch_tag === "A0" && r2p103.elements.length >= 1) ? "1" : "0");
736    // S103-C3: kind 'requirement' pattern 'metadata unchanged (SP_NAME1/NAME_OP_PROF1/png/ICON_OP_PROF1/{ppr1,ppr2})' has no static generation face (corpus vacuum; see CaseIR unresolved).
737    // S103-C3: binding:bf2d_query_structure_satisfies_requirement(S22-prof_info) (check_attestation)
738}
739

完整 unified diff

行级差异:新增 737 行 / 删除 971 行(以 -man 为基准,unified 上下文 3 行)。

展开 diff(1713 行)
--- -man
+++ -cas
@@ -1,973 +1,739 @@
-// slice of Import\TestCase_SGP_23.js - cases: TC_eUICC_ES6_UpdateMetadata_01_Nominal_Unset_PPR1 + TC_eUICC_ES6_UpdateMetadata_02_Nominal_Unset_PPR2_and_update_icon + TC_eUICC_ES6_UpdateMetadata_03_Nominal_Unset_PPR1_and_PPR2_and_update_Profile_name_and_Service_Provider_name + TC_eUICC_ES6_UpdateMetadata_04_Nominal_Delete_PPRs_Service_Provider_and_Profile_names + TC_eUICC_ES6_UpdateMetadata_06_Nominal_Delete_Unset_PPRs + TC_eUICC_ES6_UpdateMetadata_07_Error_Set_a_pprUpdateControl_value_to_one_e + TC_eUICC_ES6_UpdateMetadata_08_Error_Update_Metadata_on_a_Disable_Profile + TC_eUICC_ES6_UpdateMetadata_09_Error_Empty_request + TC_eUICC_ES6_UpdateMetadata_10_Error_Update_Icon_without_Icon_Type_field + TC_eUICC_ES6_UpdateMetadata_11_Error_Update_Icon_Type_without_Icon_field (extracted verbatim)
-
-function TC_eUICC_ES6_UpdateMetadata_01_Nominal_Unset_PPR1()
-{
-	
-	RecoverCard();
-
-	initial_condition_PROFILE_OPERATIONAL1_is_Enabled("0560");
-	
-	tracenamestr = "测试目的:验证MNO可以从Profile中取消已设置的PPR1,以及eUICC能够处理仅包含一个字段的Update Metadata的请求";
-	curDis.TraceStart(sno++,tracenamestr);
-	
-	curLogicChannel = 0;
-	curDis.TestStepStart2(stno++,"eUICC卡片初始化;");
-	Ini_powerOn_eUICC_LPAe_not_activate();
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送MANAGE_CHANNEL命令,打开辅助逻辑通道;");
-	TS_MANAGE_CHANNEL_OPEN();
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Terminal Profile命令,进行主动式命令交互;");
-	IniCard_SetUpMenu("",1);
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Envelope命令,执行UpdateMetadataRequest,更新策略,REMOVE_PPR1;");
-	sSendType = SendTypeByOTA.SMS;
-		
-	KIC = MNO_SCP80_ENC_KEY;
-	KID = MNO_SCP80_AUTH_KEY;
-	KIK = MNO_SCP80_DATA_ENC_KEY;
-
-
-	numOfCmdTlvs = 0;
-	arrExpandedRemoteCmdObj = new Array();
-	
-	InstallForPerson = new InstallForPersonalizationPara(RESERVED_ISD_P_AID);
-	InstallForPerson.SetAPDU();
-	arrExpandedRemoteCmdObj[numOfCmdTlvs] = new ExpandedRemoteCommandObject();
-	arrExpandedRemoteCmdObj[numOfCmdTlvs].crtExpandedRemoteApduObj(InstallForPerson.apdu);
-	numOfCmdTlvs ++;
-	
-	
-	var sdatain = "BF2A0499020520";
-	var storedatapara =new StoreDataPara("90","00",sdatain,"9000");
-	
-	storedatapara.SetAPDU();
-	arrExpandedRemoteCmdObj[numOfCmdTlvs] = new ExpandedRemoteCommandObject();
-	arrExpandedRemoteCmdObj[numOfCmdTlvs].crtExpandedRemoteApduObj(storedatapara.apdu);
-	numOfCmdTlvs ++;
-	
-	sAPDU = GenExpandedRemoteCmd(arrExpandedRemoteCmdObj);
-	
-	SendMessageToCard_GP(sSendType,"91XX",0,MNO_TAR_PROFILE_OPERATIONAL1,"12210015",sAPDU);
-	
-	var exResPara = new ExpandedRemoteResponsePara(arrExpandedRemoteCmdObj, "9000", "00", sSendType);
-	CardSendMessageToServerExpandedRemoteCmd(exResPara);
-	
-	TerminalResponse("00","9000");
-	
-	
-	curLogicChannel = 1;
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
-	TS_SELECT("Select ISD",ISD_R_AID,"9000");
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行ProfileInfoListRequest,获取profile信息;");
-	var proInfoListRequest = new ProfileInfoListRequest();
-	proInfoListRequest.searchCriteria = new ChoiceObj(tagOfsearchCriteria_ProfileInfo.iccid,ICCID_OP_PROF1);
-	proInfoListRequest.tagList = "9192939499";
-	proInfoListRequest.GenHexData();
-	var respData = LPAd_Transport_data_to_eUICC(proInfoListRequest.hexData);
-	
-
-	var proInfoListResponse = new  ProfileInfoListResponse();
-	proInfoListResponse.checkCardResDataFormat(respData);
-	
-	try
-	{
-		curStrHandle.CheckData(SP_NAME1, proInfoListResponse.profileInfoListOk.arrOfElement[0].serviceProviderName, "serviceProviderName");
-		curStrHandle.CheckData(PROFILE_OPERATIONAL1_NAME1, proInfoListResponse.profileInfoListOk.arrOfElement[0].profileName, "profileName");
-		curStrHandle.CheckData("01", proInfoListResponse.profileInfoListOk.arrOfElement[0].iconType, "iconType");
-		curStrHandle.CheckData(ICON_OP_PROF1, proInfoListResponse.profileInfoListOk.arrOfElement[0].icon, "icon");
-		curStrHandle.CheckData("0520", proInfoListResponse.profileInfoListOk.arrOfElement[0].profilePolicyRules, "profilePolicyRules");
-	}catch(e){
-		obj.SubLevel(ProfileInfoListResponse_Data_Error, level_of_SubLevel.error);
-	}
-	
-	RecoverCard();
-	return;
-	
-	
-}
-
-function TC_eUICC_ES6_UpdateMetadata_02_Nominal_Unset_PPR2_and_update_icon()
-{
-	
-	initial_condition_PROFILE_OPERATIONAL1_is_Enabled("0560");
-	
-	tracenamestr = "测试目的:验证MNO可以从Profile中取消已设置的PPR2,并更新icon和icon type值";
-	
-	curDis.TraceStart(sno++,tracenamestr);
-	
-	curLogicChannel = 0;
-	curDis.TestStepStart2(stno++,"eUICC卡片初始化;");
-	Ini_powerOn_eUICC_LPAe_not_activate();
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送MANAGE_CHANNEL命令,打开辅助逻辑通道;");
-	TS_MANAGE_CHANNEL_OPEN();
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Terminal Profile命令,进行主动式命令交互;");
-	IniCard_SetUpMenu("",1);
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Envelope命令,执行UpdateMetadataRequest,更新icon和icon类型,UPD_ICON_REM_PPR2;");
-	sSendType = SendTypeByOTA.SMS;
-		
-	KIC = MNO_SCP80_ENC_KEY;
-	KID = MNO_SCP80_AUTH_KEY;
-	KIK = MNO_SCP80_DATA_ENC_KEY;
-	
-
-	numOfCmdTlvs = 0;
-	arrExpandedRemoteCmdObj = new Array();
-	
-	InstallForPerson = new InstallForPersonalizationPara(RESERVED_ISD_P_AID);
-	InstallForPerson.SetAPDU();
-	arrExpandedRemoteCmdObj[numOfCmdTlvs] = new ExpandedRemoteCommandObject();
-	arrExpandedRemoteCmdObj[numOfCmdTlvs].crtExpandedRemoteApduObj(InstallForPerson.apdu);
-	numOfCmdTlvs ++;
-	
-
-	var UpdateMetadataReq = new UpdateMetadataRequest();
-	UpdateMetadataReq.profilePolicyRules = "0640";    
-	UpdateMetadataReq.iconType = "00";
-	UpdateMetadataReq.icon = ICON_JPG;
-		
-	var sdatain = UpdateMetadataReq.GenHexData();
-	
-	var stdataArray = StoreDataarr(sdatain,"90","00","9000");
-	for (var i = 0; i < stdataArray.length; i++)
-	{
-
-		arrExpandedRemoteCmdObj[numOfCmdTlvs] = new ExpandedRemoteCommandObject();
-		arrExpandedRemoteCmdObj[numOfCmdTlvs].crtExpandedRemoteApduObj(stdataArray[i]);
-		numOfCmdTlvs ++;
-		
-	}
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
-	sAPDU = GenExpandedRemoteCmd(arrExpandedRemoteCmdObj);
-	SendMessageToCard_GP(sSendType,"91XX",0,MNO_TAR_PROFILE_OPERATIONAL1,"12210015",sAPDU);
-	
-	var exResPara = new ExpandedRemoteResponsePara(arrExpandedRemoteCmdObj, "9000", "00", sSendType);
-	CardSendMessageToServerExpandedRemoteCmd(exResPara);
-	
-	TerminalResponse("00","9000");
-
-	curLogicChannel = 1;
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
-	TS_SELECT("Select ISD",ISD_R_AID,"9000");
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行ProfileInfoListRequest,获取profile信息;");
-	var proInfoListRequest = new ProfileInfoListRequest();
-	proInfoListRequest.searchCriteria = new ChoiceObj(tagOfsearchCriteria_ProfileInfo.iccid,ICCID_OP_PROF1);
-	proInfoListRequest.tagList = "9192939499";
-	proInfoListRequest.GenHexData();
-	var respData = LPAd_Transport_data_to_eUICC(proInfoListRequest.hexData);
-	
-
-	var proInfoListResponse = new  ProfileInfoListResponse();
-	proInfoListResponse.checkCardResDataFormat(respData);
-	
-	try
-	{
-		curStrHandle.CheckData(SP_NAME1, proInfoListResponse.profileInfoListOk.arrOfElement[0].serviceProviderName, "serviceProviderName");
-		curStrHandle.CheckData(PROFILE_OPERATIONAL1_NAME1, proInfoListResponse.profileInfoListOk.arrOfElement[0].profileName, "profileName");
-		curStrHandle.CheckData("00", proInfoListResponse.profileInfoListOk.arrOfElement[0].iconType, "iconType");
-		curStrHandle.CheckData(ICON_JPG, proInfoListResponse.profileInfoListOk.arrOfElement[0].icon, "icon");
-		curStrHandle.CheckData("0640", proInfoListResponse.profileInfoListOk.arrOfElement[0].profilePolicyRules, "profilePolicyRules");
-	}catch(e){
-		obj.SubLevel(ProfileInfoListResponse_Data_Error, level_of_SubLevel.error);
-	}
-	
-	RecoverCard();
-	return;
-	
-	
-}
-
-function TC_eUICC_ES6_UpdateMetadata_03_Nominal_Unset_PPR1_and_PPR2_and_update_Profile_name_and_Service_Provider_name()
-{
-	
-	initial_condition_PROFILE_OPERATIONAL1_is_Enabled("0560");
-	
-	tracenamestr = "测试目的:验证MNO可以从Profile中取消已设置的PPR1和PPR2,并更新Service Provider Name和Profile Name values";
-	curDis.TraceStart(sno++,tracenamestr);
-	
-	curLogicChannel = 0;
-	curDis.TestStepStart2(stno++,"eUICC卡片初始化;");
-	Ini_powerOn_eUICC_LPAe_not_activate();
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送MANAGE_CHANNEL命令,打开辅助逻辑通道;");
-	TS_MANAGE_CHANNEL_OPEN();
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Terminal Profile命令,进行主动式命令交互;");
-	IniCard_SetUpMenu("",1);
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Envelope命令,执行UpdateMetadataRequest,更新serviceProviderName和profileName,UPD_NAMES_REM_PPRS;");
-	sSendType = SendTypeByOTA.SMS;
-		
-	KIC = MNO_SCP80_ENC_KEY;
-	KID = MNO_SCP80_AUTH_KEY;
-	KIK = MNO_SCP80_DATA_ENC_KEY;
-	
-
-	numOfCmdTlvs = 0;
-	arrExpandedRemoteCmdObj = new Array();
-	
-	InstallForPerson = new InstallForPersonalizationPara(RESERVED_ISD_P_AID);
-	InstallForPerson.SetAPDU();
-	arrExpandedRemoteCmdObj[numOfCmdTlvs] = new ExpandedRemoteCommandObject();
-	arrExpandedRemoteCmdObj[numOfCmdTlvs].crtExpandedRemoteApduObj(InstallForPerson.apdu);
-	numOfCmdTlvs ++;
-	
-
-	var UpdateMetadataReq = new UpdateMetadataRequest();
-	UpdateMetadataReq.profilePolicyRules = "00";
-	UpdateMetadataReq.serviceProviderName=SP_NAME2;
-	UpdateMetadataReq.profileName=NAME_OP_PROF2;
-	
-		
-	var sdatain = UpdateMetadataReq.GenHexData();
-	var stdataArray = StoreDataarr(sdatain,"90","00","9000");
-	for (var i = 0; i < stdataArray.length; i++)
-	{
-
-		arrExpandedRemoteCmdObj[numOfCmdTlvs] = new ExpandedRemoteCommandObject();
-		arrExpandedRemoteCmdObj[numOfCmdTlvs].crtExpandedRemoteApduObj(stdataArray[i]);
-		numOfCmdTlvs ++;
-		
-	}
-
-	
-	sAPDU = GenExpandedRemoteCmd(arrExpandedRemoteCmdObj);
-	
-	SendMessageToCard_GP(sSendType,"91XX",0,MNO_TAR_PROFILE_OPERATIONAL1,"12210015",sAPDU);
-	
-	var exResPara = new ExpandedRemoteResponsePara(arrExpandedRemoteCmdObj, "9000", "00", sSendType);
-	CardSendMessageToServerExpandedRemoteCmd(exResPara);
-	
-	TerminalResponse("00","9000");
-
-	curLogicChannel = 1;
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
-	TS_SELECT("Select ISD",ISD_R_AID,"9000");
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行ProfileInfoListRequest,获取profile信息;");
-	var proInfoListRequest = new ProfileInfoListRequest();
-	proInfoListRequest.searchCriteria = new ChoiceObj(tagOfsearchCriteria_ProfileInfo.iccid,ICCID_OP_PROF1);
-	proInfoListRequest.tagList = "9192939499";
-	proInfoListRequest.GenHexData();
-	var respData = LPAd_Transport_data_to_eUICC(proInfoListRequest.hexData);
-	
-
-	var proInfoListResponse = new  ProfileInfoListResponse();
-	proInfoListResponse.checkCardResDataFormat(respData);
-	
-	try
-	{
-		curStrHandle.CheckData(SP_NAME2, proInfoListResponse.profileInfoListOk.arrOfElement[0].serviceProviderName, "serviceProviderName");
-		curStrHandle.CheckData(NAME_OP_PROF2, proInfoListResponse.profileInfoListOk.arrOfElement[0].profileName, "profileName");	
-	}catch(e){
-		obj.SubLevel(ProfileInfoListResponse_Data_Error, level_of_SubLevel.error);
-	}
-	
-	RecoverCard();
-	return;
-	
-	
-}
-
-function TC_eUICC_ES6_UpdateMetadata_04_Nominal_Delete_PPRs_Service_Provider_and_Profile_names()
-{
-	
-	initial_condition_PROFILE_OPERATIONAL1_is_Enabled("0560");
-	
-	tracenamestr = "测试目的:验证MNO可以删除Profile中所有的PPR ,Profile名和Service Provider名";
-	curDis.TraceStart(sno++,tracenamestr);
-	
-	curLogicChannel = 0;
-	curDis.TestStepStart2(stno++,"eUICC卡片初始化;");
-	Ini_powerOn_eUICC_LPAe_not_activate();
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送MANAGE_CHANNEL命令,打开辅助逻辑通道;");
-	TS_MANAGE_CHANNEL_OPEN();
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Terminal Profile命令,进行主动式命令交互;");
-	IniCard_SetUpMenu("",1);
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Envelope命令,执行UpdateMetadataRequest,删除Profile中所有的PPR ,Profile名和Service Provider名,REMOVE_NAMES_PPRS;");
-	sSendType = SendTypeByOTA.SMS;
-		
-	KIC = MNO_SCP80_ENC_KEY;
-	KID = MNO_SCP80_AUTH_KEY;
-	KIK = MNO_SCP80_DATA_ENC_KEY;
-	
-
-	numOfCmdTlvs = 0;
-	arrExpandedRemoteCmdObj = new Array();
-	
-	InstallForPerson = new InstallForPersonalizationPara(RESERVED_ISD_P_AID);
-	InstallForPerson.SetAPDU();
-	arrExpandedRemoteCmdObj[numOfCmdTlvs] = new ExpandedRemoteCommandObject();
-	arrExpandedRemoteCmdObj[numOfCmdTlvs].crtExpandedRemoteApduObj(InstallForPerson.apdu);
-	numOfCmdTlvs ++;
-	
-	var UpdateMetadataReq = new UpdateMetadataRequest();
-	UpdateMetadataReq.profilePolicyRules = "00";
-	UpdateMetadataReq.serviceProviderName = "";
-	UpdateMetadataReq.profileName = "";
-		
-	var sdatain = UpdateMetadataReq.GenHexData();
-	
-	var stdataArray = StoreDataarr(sdatain,"90","00","9000");
-	for (var i = 0; i < stdataArray.length; i++)
-	{
-		arrExpandedRemoteCmdObj[numOfCmdTlvs] = new ExpandedRemoteCommandObject();
-		arrExpandedRemoteCmdObj[numOfCmdTlvs].crtExpandedRemoteApduObj(stdataArray[i]);
-		numOfCmdTlvs ++;
-		
-	}
-	
-	sAPDU = GenExpandedRemoteCmd(arrExpandedRemoteCmdObj);
-	
-	SendMessageToCard_GP(sSendType,"91XX",0,MNO_TAR_PROFILE_OPERATIONAL1,"12210515",sAPDU);
-	
-	var exResPara = new ExpandedRemoteResponsePara(arrExpandedRemoteCmdObj, "9000", "00", sSendType);
-	CardSendMessageToServerExpandedRemoteCmd(exResPara);
-	
-	TerminalResponse("00","9000");
-
-	curLogicChannel = 1;
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
-	TS_SELECT("Select ISD",ISD_R_AID,"9000");
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行ProfileInfoListRequest,获取profile信息;");
-	var proInfoListRequest = new ProfileInfoListRequest();
-	proInfoListRequest.searchCriteria = new ChoiceObj(tagOfsearchCriteria_ProfileInfo.iccid,ICCID_OP_PROF1);
-	proInfoListRequest.tagList = "9192939499";
-	proInfoListRequest.GenHexData();
-	var respData = LPAd_Transport_data_to_eUICC(proInfoListRequest.hexData);
-	
-
-	var proInfoListResponse = new  ProfileInfoListResponse();
-	proInfoListResponse.checkCardResDataFormat(respData);
-	
-	try
-	{
-
-		curStrHandle.CheckData("01", proInfoListResponse.profileInfoListOk.arrOfElement[0].iconType, "iconType");
-		curStrHandle.CheckData(ICON_OP_PROF1, proInfoListResponse.profileInfoListOk.arrOfElement[0].icon, "icon");
-		
-		if (typeof(proInfoListResponse.profileInfoListOk.arrOfElement[0].serviceProviderName) != "undefined")
-			obj.SubLevelError("期望不返回serviceProviderName");
-		
-		if (typeof(proInfoListResponse.profileInfoListOk.arrOfElement[0].profileName) != "undefined")
-			obj.SubLevelError("期望不返回profileName");
-		
-		if (typeof(proInfoListResponse.profileInfoListOk.arrOfElement[0].profilePolicyRules) != "undefined")
-			obj.SubLevelError("期望不返回profilePolicyRules");
-	}catch(e){
-		obj.SubLevel(ProfileInfoListResponse_Data_Error, level_of_SubLevel.error);
-	}
-	
-	RecoverCard();
-	return;
-}
-
-function TC_eUICC_ES6_UpdateMetadata_06_Nominal_Delete_Unset_PPRs()
-{
-	
-	initial_condition_PROFILE_OPERATIONAL1_is_Enabled("0560");
-	
-	tracenamestr = "测试目的:验证MNO通过Update Metadata请求可以删除的所有PPRs";
-	curDis.TraceStart(sno++,tracenamestr);
-	
-	curLogicChannel = 0;
-	curDis.TestStepStart2(stno++,"eUICC卡片初始化;");
-	Ini_powerOn_eUICC_LPAe_not_activate();
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送MANAGE_CHANNEL命令,打开辅助逻辑通道;");
-	TS_MANAGE_CHANNEL_OPEN();
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Terminal Profile命令,进行主动式命令交互;");
-	IniCard_SetUpMenu("",1);
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Envelope命令,执行UpdateMetadataRequest,删除Profile中所有的PPR ,Profile名和Service Provider名,REMOVE_NAMES_PPRS;");
-	sSendType = SendTypeByOTA.SMS;
-		
-	KIC = MNO_SCP80_ENC_KEY;
-	KID = MNO_SCP80_AUTH_KEY;
-	KIK = MNO_SCP80_DATA_ENC_KEY;
-	
-	numOfCmdTlvs = 0;
-	arrExpandedRemoteCmdObj = new Array();
-	
-	InstallForPerson = new InstallForPersonalizationPara(RESERVED_ISD_P_AID);
-	InstallForPerson.SetAPDU();
-	arrExpandedRemoteCmdObj[numOfCmdTlvs] = new ExpandedRemoteCommandObject();
-	arrExpandedRemoteCmdObj[numOfCmdTlvs].crtExpandedRemoteApduObj(InstallForPerson.apdu);
-	numOfCmdTlvs ++;
-	
-	var UpdateMetadataReq = new UpdateMetadataRequest();
-	UpdateMetadataReq.profilePolicyRules = "00";
-	UpdateMetadataReq.serviceProviderName = "";
-	UpdateMetadataReq.profileName = "";
-		
-	var sdatain = UpdateMetadataReq.GenHexData();
-	
-	var stdataArray = StoreDataarr(sdatain,"90","00","9000");
-	for (var i = 0; i < stdataArray.length; i++)
-	{
-		arrExpandedRemoteCmdObj[numOfCmdTlvs] = new ExpandedRemoteCommandObject();
-		arrExpandedRemoteCmdObj[numOfCmdTlvs].crtExpandedRemoteApduObj(stdataArray[i]);
-		numOfCmdTlvs ++;
-		
-	}
-	
-	sAPDU = GenExpandedRemoteCmd(arrExpandedRemoteCmdObj);
-	
-	SendMessageToCard_GP(sSendType,"91XX",0,MNO_TAR_PROFILE_OPERATIONAL1,"12210515",sAPDU);
-	
-	var exResPara = new ExpandedRemoteResponsePara(arrExpandedRemoteCmdObj, "9000", "00", sSendType);
-	CardSendMessageToServerExpandedRemoteCmd(exResPara);
-	
-	TerminalResponse("00","9000");
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Envelope命令,执行UpdateMetadataRequest,更新Profile name和Service Provider name,UPD_NAMES_REM_PPRS;");
-	sSendType = SendTypeByOTA.SMS;
-		
-	KIC = MNO_SCP80_ENC_KEY;
-	KID = MNO_SCP80_AUTH_KEY;
-	KIK = MNO_SCP80_DATA_ENC_KEY;
-	
-	numOfCmdTlvs = 0;
-	arrExpandedRemoteCmdObj = new Array();
-	
-	InstallForPerson = new InstallForPersonalizationPara(RESERVED_ISD_P_AID);
-	InstallForPerson.SetAPDU();
-	arrExpandedRemoteCmdObj[numOfCmdTlvs] = new ExpandedRemoteCommandObject();
-	arrExpandedRemoteCmdObj[numOfCmdTlvs].crtExpandedRemoteApduObj(InstallForPerson.apdu);
-	numOfCmdTlvs ++;
-	
-	var UpdateMetadataReq = new UpdateMetadataRequest();
-	UpdateMetadataReq.profilePolicyRules = "00";
-	UpdateMetadataReq.serviceProviderName = SP_NAME2;
-	UpdateMetadataReq.profileName = NAME_OP_PROF2;
-		
-	var sdatain = UpdateMetadataReq.GenHexData();
-	
-	var stdataArray = StoreDataarr(sdatain,"90","00","9000");
-	for (var i = 0; i < stdataArray.length; i++)
-	{
-		arrExpandedRemoteCmdObj[numOfCmdTlvs] = new ExpandedRemoteCommandObject();
-		arrExpandedRemoteCmdObj[numOfCmdTlvs].crtExpandedRemoteApduObj(stdataArray[i]);
-		numOfCmdTlvs ++;
-		
-	}
-	
-	sAPDU = GenExpandedRemoteCmd(arrExpandedRemoteCmdObj);
-	
-	SendMessageToCard_GP(sSendType,"91XX",0,MNO_TAR_PROFILE_OPERATIONAL1,"12210515",sAPDU);
-	
-	var exResPara = new ExpandedRemoteResponsePara(arrExpandedRemoteCmdObj, "9000", "00", sSendType);
-	CardSendMessageToServerExpandedRemoteCmd(exResPara);
-	
-	TerminalResponse("00","9000");
-
-	curLogicChannel = 1;
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
-	TS_SELECT("Select ISD",ISD_R_AID,"9000");
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行ProfileInfoListRequest,获取profile信息;");
-	var proInfoListRequest = new ProfileInfoListRequest();
-	proInfoListRequest.searchCriteria = new ChoiceObj(tagOfsearchCriteria_ProfileInfo.iccid,ICCID_OP_PROF1);
-	proInfoListRequest.tagList = "9192939499";
-	proInfoListRequest.GenHexData();
-	var respData = LPAd_Transport_data_to_eUICC(proInfoListRequest.hexData);
-	
-	var proInfoListResponse = new  ProfileInfoListResponse();
-	proInfoListResponse.checkCardResDataFormat(respData);
-	
-	try
-	{
-		curStrHandle.CheckData(SP_NAME2, proInfoListResponse.profileInfoListOk.arrOfElement[0].serviceProviderName, "serviceProviderName");
-		curStrHandle.CheckData(NAME_OP_PROF2, proInfoListResponse.profileInfoListOk.arrOfElement[0].profileName, "profileName");
-		curStrHandle.CheckData("01", proInfoListResponse.profileInfoListOk.arrOfElement[0].iconType, "iconType");
-		curStrHandle.CheckData(ICON_OP_PROF1, proInfoListResponse.profileInfoListOk.arrOfElement[0].icon, "icon");
-		if (typeof(proInfoListResponse.profileInfoListOk.arrOfElement[0].profilePolicyRules) != "undefined")
-			obj.SubLevelError("期望不返回profilePolicyRules");
-		
-	}catch(e){
-		obj.SubLevel(ProfileInfoListResponse_Data_Error, level_of_SubLevel.error);
-	}
-	
-	RecoverCard();
-	return;
-}
-
-function TC_eUICC_ES6_UpdateMetadata_07_Error_Set_a_pprUpdateControl_value_to_one_e()
-{
-	
-	initial_condition_PROFILE_OPERATIONAL1_is_Enabled("0560");
-	
-	tracenamestr = "测试目的:验证eUICC可以正确处理来自MNO请求的pprUpdateControl的错误值,并返回预期的错误码";
-	curDis.TraceStart(sno++,tracenamestr);
-	
-	curLogicChannel = 0;
-	curDis.TestStepStart2(stno++,"eUICC卡片初始化;");
-	Ini_powerOn_eUICC_LPAe_not_activate();
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送MANAGE_CHANNEL命令,打开辅助逻辑通道;");
-	TS_MANAGE_CHANNEL_OPEN();
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Terminal Profile命令,进行主动式命令交互;");
-	IniCard_SetUpMenu("",1);
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Envelope命令,执行UpdateMetadataRequest,更新serviceProviderName、profileName、iconType、icon和profilePolicyRules,UPD_PPR_CONTROL;");
-	sSendType = SendTypeByOTA.SMS;
-		
-	KIC = MNO_SCP80_ENC_KEY;
-	KID = MNO_SCP80_AUTH_KEY;
-	KIK = MNO_SCP80_DATA_ENC_KEY;
-	
-
-	numOfCmdTlvs = 0;
-	arrExpandedRemoteCmdObj = new Array();
-	
-	InstallForPerson = new InstallForPersonalizationPara(RESERVED_ISD_P_AID);
-	InstallForPerson.SetAPDU();
-	arrExpandedRemoteCmdObj[numOfCmdTlvs] = new ExpandedRemoteCommandObject();
-	arrExpandedRemoteCmdObj[numOfCmdTlvs].crtExpandedRemoteApduObj(InstallForPerson.apdu);
-	numOfCmdTlvs ++;
-	
-
-	var UpdateMetadataReq = new UpdateMetadataRequest();
-	UpdateMetadataReq.profilePolicyRules = "06C0";
-	UpdateMetadataReq.serviceProviderName=SP_NAME2;
-	UpdateMetadataReq.profileName=NAME_OP_PROF2;
-	UpdateMetadataReq.iconType = "00";
-	UpdateMetadataReq.icon = ICON_JPG;
-	
-		
-	var sdatain = UpdateMetadataReq.GenHexData();
-	var stdataArray = StoreDataarr(sdatain,"90","00","6A81");
-	for (var i = 0; i < stdataArray.length; i++)
-	{
-
-		arrExpandedRemoteCmdObj[numOfCmdTlvs] = new ExpandedRemoteCommandObject();
-		arrExpandedRemoteCmdObj[numOfCmdTlvs].crtExpandedRemoteApduObj(stdataArray[i]);
-		numOfCmdTlvs ++;
-		
-	}
-
-	
-	sAPDU = GenExpandedRemoteCmd(arrExpandedRemoteCmdObj);
-	
-	SendMessageToCard_GP(sSendType,"91XX",0,MNO_TAR_PROFILE_OPERATIONAL1,"12210015",sAPDU);
-	
-	var exResPara = new ExpandedRemoteResponsePara(arrExpandedRemoteCmdObj, "9000", "00", sSendType);
-	CardSendMessageToServerExpandedRemoteCmd(exResPara);
-	
-	
-	TerminalResponse("00","9000");
-
-	curLogicChannel = 1;
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
-	TS_SELECT("Select ISD",ISD_R_AID,"9000");
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行ProfileInfoListRequest,获取profile信息;");
-	var proInfoListRequest = new ProfileInfoListRequest();
-	proInfoListRequest.searchCriteria = new ChoiceObj(tagOfsearchCriteria_ProfileInfo.iccid,ICCID_OP_PROF1);
-	proInfoListRequest.tagList = "9192939499";
-	proInfoListRequest.GenHexData();
-	var respData = LPAd_Transport_data_to_eUICC(proInfoListRequest.hexData);
-	
-
-	var proInfoListResponse = new  ProfileInfoListResponse();
-	proInfoListResponse.checkCardResDataFormat(respData);
-
-	try
-	{
-		curStrHandle.CheckData(SP_NAME1, proInfoListResponse.profileInfoListOk.arrOfElement[0].serviceProviderName, "serviceProviderName");
-		curStrHandle.CheckData(PROFILE_OPERATIONAL1_NAME1, proInfoListResponse.profileInfoListOk.arrOfElement[0].profileName, "profileName");	
-		curStrHandle.CheckData("01", proInfoListResponse.profileInfoListOk.arrOfElement[0].iconType, "iconType");
-		curStrHandle.CheckData(ICON_OP_PROF1, proInfoListResponse.profileInfoListOk.arrOfElement[0].icon, "icon");
-		curStrHandle.CheckData("0560", proInfoListResponse.profileInfoListOk.arrOfElement[0].profilePolicyRules, "profilePolicyRules");
-	}catch(e){
-		obj.SubLevel(ProfileInfoListResponse_Data_Error, level_of_SubLevel.error);
-	}
-	
-	RecoverCard();
-	return;
-	
-	
-}
-
-function TC_eUICC_ES6_UpdateMetadata_08_Error_Update_Metadata_on_a_Disable_Profile()
-{
-	
-	
-	initial_condition_PROFILE_OPERATIONAL1_is_Disabled("0560");
-	
-	tracenamestr = "测试目的:验证当目标Profile已禁用时,eUICC可以正确拒绝来自MNO的Update Metadata请求";
-	curDis.TraceStart(sno++,tracenamestr);
-	
-	curLogicChannel = 0;
-	curDis.TestStepStart2(stno++,"eUICC卡片初始化;");
-	Ini_powerOn_eUICC_LPAe_not_activate();
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送MANAGE_CHANNEL命令,打开辅助逻辑通道;");
-	TS_MANAGE_CHANNEL_OPEN();
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Terminal Profile命令,进行主动式命令交互;");
-	IniCard_SetUpMenu("",1);
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Envelope命令,执行UpdateMetadataRequest,更新PPR2,REMOVE_PPR1;");
-	sSendType = SendTypeByOTA.SMS;
-		
-	KIC = MNO_SCP80_ENC_KEY;
-	KID = MNO_SCP80_AUTH_KEY;
-	KIK = MNO_SCP80_DATA_ENC_KEY;
-	
-	numOfCmdTlvs = 0;
-	arrExpandedRemoteCmdObj = new Array();
-	
-	InstallForPerson = new InstallForPersonalizationPara(RESERVED_ISD_P_AID);
-	InstallForPerson.SetAPDU();
-	arrExpandedRemoteCmdObj[numOfCmdTlvs] = new ExpandedRemoteCommandObject();
-	arrExpandedRemoteCmdObj[numOfCmdTlvs].crtExpandedRemoteApduObj(InstallForPerson.apdu);
-	numOfCmdTlvs ++;
-	
-	var sdatain = "BF2A0499020520";
-	var storedatapara =new StoreDataPara("90","00",sdatain,"9000");
-	storedatapara.apdu.ressw="6A81";
-		
-	storedatapara.SetAPDU();
-	arrExpandedRemoteCmdObj[numOfCmdTlvs] = new ExpandedRemoteCommandObject();
-	arrExpandedRemoteCmdObj[numOfCmdTlvs].crtExpandedRemoteApduObj(storedatapara.apdu);
-	numOfCmdTlvs ++;
-	
-	
-	sAPDU = GenExpandedRemoteCmd(arrExpandedRemoteCmdObj);
-	
-	SendMessageToCard_GP(sSendType,"91XX",0,MNO_TAR_PROFILE_OPERATIONAL1,"12210015",sAPDU);
-	
-	var exResPara = new ExpandedRemoteResponsePara(arrExpandedRemoteCmdObj, "9000", "06/09", sSendType);
-	CardSendMessageToServerExpandedRemoteCmd(exResPara);
-	
-	TerminalResponse("00","9000");
-
-	curLogicChannel = 1;
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
-	TS_SELECT("Select ISD",ISD_R_AID,"9000");
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行ProfileInfoListRequest,获取profile信息;");
-	var proInfoListRequest = new ProfileInfoListRequest();
-	proInfoListRequest.searchCriteria = new ChoiceObj(tagOfsearchCriteria_ProfileInfo.iccid,ICCID_OP_PROF1);
-	proInfoListRequest.tagList = "9192939499";
-	proInfoListRequest.GenHexData();
-	var respData = LPAd_Transport_data_to_eUICC(proInfoListRequest.hexData);
-
-	var proInfoListResponse = new  ProfileInfoListResponse();
-	proInfoListResponse.checkCardResDataFormat(respData);
-	
-	
-	try
-	{
-		curStrHandle.CheckData(SP_NAME1, proInfoListResponse.profileInfoListOk.arrOfElement[0].serviceProviderName, "serviceProviderName");
-		curStrHandle.CheckData(PROFILE_OPERATIONAL1_NAME1, proInfoListResponse.profileInfoListOk.arrOfElement[0].profileName, "profileName");	
-		curStrHandle.CheckData("0560", proInfoListResponse.profileInfoListOk.arrOfElement[0].profilePolicyRules, "profilePolicyRules");
-	}catch(e){
-		obj.SubLevel(ProfileInfoListResponse_Data_Error, level_of_SubLevel.error);
-	}
-	
-	RecoverCard();
-	return;
-	
-	
-}
-
-function TC_eUICC_ES6_UpdateMetadata_09_Error_Empty_request()
-{
-	
-	initial_condition_PROFILE_OPERATIONAL1_is_Enabled("0560");
-	
-	tracenamestr = "测试目的:验证没有字段存在时,eUICC可以正确拒绝来自MNO的Update Metadata请求";
-	curDis.TraceStart(sno++,tracenamestr);
-	
-	curLogicChannel = 0;
-	curDis.TestStepStart2(stno++,"eUICC卡片初始化;");
-	Ini_powerOn_eUICC_LPAe_not_activate();
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送MANAGE_CHANNEL命令,打开辅助逻辑通道;");
-	TS_MANAGE_CHANNEL_OPEN();
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Terminal Profile命令,进行主动式命令交互;");
-	IniCard_SetUpMenu("",1);
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Envelope命令,执行UpdateMetadataRequest,UPD_NO_METADATA");
-	sSendType = SendTypeByOTA.SMS;
-		
-	KIC = MNO_SCP80_ENC_KEY;
-	KID = MNO_SCP80_AUTH_KEY;
-	KIK = MNO_SCP80_DATA_ENC_KEY;
-	
-
-	numOfCmdTlvs = 0;
-	arrExpandedRemoteCmdObj = new Array();
-	
-	InstallForPerson = new InstallForPersonalizationPara(RESERVED_ISD_P_AID);
-	InstallForPerson.SetAPDU();
-	arrExpandedRemoteCmdObj[numOfCmdTlvs] = new ExpandedRemoteCommandObject();
-	arrExpandedRemoteCmdObj[numOfCmdTlvs].crtExpandedRemoteApduObj(InstallForPerson.apdu);
-	numOfCmdTlvs ++;
-	
-
-	var UpdateMetadataReq = new UpdateMetadataRequest();
-		
-	var sdatain = UpdateMetadataReq.GenHexData();
-	
-	var stdataArray = StoreDataarr(sdatain,"90","00","XXXX");
-	for (var i = 0; i < stdataArray.length; i++)
-	{
-
-		arrExpandedRemoteCmdObj[numOfCmdTlvs] = new ExpandedRemoteCommandObject();
-		arrExpandedRemoteCmdObj[numOfCmdTlvs].crtExpandedRemoteApduObj(stdataArray[i]);
-		numOfCmdTlvs ++;
-		
-	}
-
-	
-	sAPDU = GenExpandedRemoteCmd(arrExpandedRemoteCmdObj);
-	
-	SendMessageToCard_GP(sSendType,"91XX",0,MNO_TAR_PROFILE_OPERATIONAL1,"12210015",sAPDU);
-	
-	var exResPara = new ExpandedRemoteResponsePara(arrExpandedRemoteCmdObj, "9000", "00", sSendType);
-	CardSendMessageToServerExpandedRemoteCmd(exResPara);
-	
-	
-	TerminalResponse("00","9000");
-
-	curLogicChannel = 1;
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
-	TS_SELECT("Select ISD",ISD_R_AID,"9000");
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行ProfileInfoListRequest,获取profile信息;");
-	var proInfoListRequest = new ProfileInfoListRequest();
-	proInfoListRequest.searchCriteria = new ChoiceObj(tagOfsearchCriteria_ProfileInfo.iccid,ICCID_OP_PROF1);
-	proInfoListRequest.tagList = "9192939499";
-	proInfoListRequest.GenHexData();
-	var respData = LPAd_Transport_data_to_eUICC(proInfoListRequest.hexData);
-	
-
-	var proInfoListResponse = new  ProfileInfoListResponse();
-	proInfoListResponse.checkCardResDataFormat(respData);
-	
-	try
-	{
-		curStrHandle.CheckData(SP_NAME1, proInfoListResponse.profileInfoListOk.arrOfElement[0].serviceProviderName, "serviceProviderName");
-		curStrHandle.CheckData(PROFILE_OPERATIONAL1_NAME1, proInfoListResponse.profileInfoListOk.arrOfElement[0].profileName, "profileName");	
-		curStrHandle.CheckData("01", proInfoListResponse.profileInfoListOk.arrOfElement[0].iconType, "iconType");
-		curStrHandle.CheckData(ICON_OP_PROF1, proInfoListResponse.profileInfoListOk.arrOfElement[0].icon, "icon");
-		curStrHandle.CheckData("0560", proInfoListResponse.profileInfoListOk.arrOfElement[0].profilePolicyRules, "profilePolicyRules");
-	}catch(e){
-		obj.SubLevel(ProfileInfoListResponse_Data_Error, level_of_SubLevel.error);
-	}
-	
-	RecoverCard();
-	return;
-	
-	
-}
-
-function TC_eUICC_ES6_UpdateMetadata_10_Error_Update_Icon_without_Icon_Type_field()//
-{
-	
-	initial_condition_PROFILE_OPERATIONAL1_is_Enabled("0560");
-	
-	tracenamestr = "测试目的:验证当icon字段存在,但icon type字段不存在时,eUICC可以正确拒绝来自MNO的Update Metadata请求";
-	curDis.TraceStart(sno++,tracenamestr);
-	
-	curLogicChannel = 0;
-	curDis.TestStepStart2(stno++,"eUICC卡片初始化;");
-	Ini_powerOn_eUICC_LPAe_not_activate();
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送MANAGE_CHANNEL命令,打开辅助逻辑通道;");
-	TS_MANAGE_CHANNEL_OPEN();
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Terminal Profile命令,进行主动式命令交互;");
-	IniCard_SetUpMenu("",1);
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Envelope命令,执行UpdateMetadataRequest,UPD_NO_METADATA");
-	sSendType = SendTypeByOTA.SMS;
-		
-	KIC = MNO_SCP80_ENC_KEY;
-	KID = MNO_SCP80_AUTH_KEY;
-	KIK = MNO_SCP80_DATA_ENC_KEY;
-	
-
-	numOfCmdTlvs = 0;
-	arrExpandedRemoteCmdObj = new Array();
-	
-	InstallForPerson = new InstallForPersonalizationPara(RESERVED_ISD_P_AID);
-	InstallForPerson.SetAPDU();
-	arrExpandedRemoteCmdObj[numOfCmdTlvs] = new ExpandedRemoteCommandObject();
-	arrExpandedRemoteCmdObj[numOfCmdTlvs].crtExpandedRemoteApduObj(InstallForPerson.apdu);
-	numOfCmdTlvs ++;
-	
-
-	var UpdateMetadataReq = new UpdateMetadataRequest();
-	UpdateMetadataReq.profilePolicyRules = "00";
-	UpdateMetadataReq.serviceProviderName=SP_NAME2;
-	UpdateMetadataReq.profileName=NAME_OP_PROF2;
-	UpdateMetadataReq.icon = ICON_JPG;
-	
-		
-	var sdatain = UpdateMetadataReq.GenHexData();
-	
-	
-	var stdataArray = StoreDataarr(sdatain,"90","00","XXXX");
-	for (var i = 0; i < stdataArray.length; i++)
-	{
-
-		arrExpandedRemoteCmdObj[numOfCmdTlvs] = new ExpandedRemoteCommandObject();
-		arrExpandedRemoteCmdObj[numOfCmdTlvs].crtExpandedRemoteApduObj(stdataArray[i]);
-		numOfCmdTlvs ++;
-		
-	}
-
-	
-	sAPDU = GenExpandedRemoteCmd(arrExpandedRemoteCmdObj);
-	
-	SendMessageToCard_GP(sSendType,"91XX",0,MNO_TAR_PROFILE_OPERATIONAL1,"12210015",sAPDU);
-	
-	var exResPara = new ExpandedRemoteResponsePara(arrExpandedRemoteCmdObj, "9000", "00", sSendType);
-	CardSendMessageToServerExpandedRemoteCmd(exResPara);
-	
-	
-	TerminalResponse("00","9000");
-
-	curLogicChannel = 1;
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
-	TS_SELECT("Select ISD",ISD_R_AID,"9000");
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行ProfileInfoListRequest,获取profile信息;");
-	var proInfoListRequest = new ProfileInfoListRequest();
-	proInfoListRequest.searchCriteria = new ChoiceObj(tagOfsearchCriteria_ProfileInfo.iccid,ICCID_OP_PROF1);
-	proInfoListRequest.tagList = "9192939499";
-	proInfoListRequest.GenHexData();
-	var respData = LPAd_Transport_data_to_eUICC(proInfoListRequest.hexData);
-	
-
-	var proInfoListResponse = new  ProfileInfoListResponse();
-	proInfoListResponse.checkCardResDataFormat(respData);
-	
-	try
-	{
-		curStrHandle.CheckData(SP_NAME1, proInfoListResponse.profileInfoListOk.arrOfElement[0].serviceProviderName, "serviceProviderName");
-		curStrHandle.CheckData(PROFILE_OPERATIONAL1_NAME1, proInfoListResponse.profileInfoListOk.arrOfElement[0].profileName, "profileName");	
-		curStrHandle.CheckData("01", proInfoListResponse.profileInfoListOk.arrOfElement[0].iconType, "iconType");
-		curStrHandle.CheckData(ICON_OP_PROF1, proInfoListResponse.profileInfoListOk.arrOfElement[0].icon, "icon");//ICON_OP_PROF1=ICON_PNG
-		curStrHandle.CheckData("0560", proInfoListResponse.profileInfoListOk.arrOfElement[0].profilePolicyRules, "profilePolicyRules");
-	}catch(e){
-		obj.SubLevel(ProfileInfoListResponse_Data_Error, level_of_SubLevel.error);
-	}
-	
-	RecoverCard();
-	return;
-	
-	
-}
-
-function TC_eUICC_ES6_UpdateMetadata_11_Error_Update_Icon_Type_without_Icon_field ()
-{
-	
-	initial_condition_PROFILE_OPERATIONAL1_is_Enabled("0560");
-	
-	tracenamestr = "测试目的:验证当icon type字段存在,但icon字段不存在时,eUICC可以正确拒绝来自MNO的Update Metadata请求";
-	curDis.TraceStart(sno++,tracenamestr);
-	
-	curLogicChannel = 0;
-	curDis.TestStepStart2(stno++,"eUICC卡片初始化;");
-	Ini_powerOn_eUICC_LPAe_not_activate();
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送MANAGE_CHANNEL命令,打开辅助逻辑通道;");
-	TS_MANAGE_CHANNEL_OPEN();
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Terminal Profile命令,进行主动式命令交互;");
-	IniCard_SetUpMenu("",1);
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Envelope命令,执行UpdateMetadataRequest,只更新icon类型不更新icon,UPD_ICON_TYPE_ONLY;");
-	sSendType = SendTypeByOTA.SMS;
-		
-	KIC = MNO_SCP80_ENC_KEY;
-	KID = MNO_SCP80_AUTH_KEY;
-	KIK = MNO_SCP80_DATA_ENC_KEY;
-	
-	//扩展格式更新策略
-	numOfCmdTlvs = 0;
-	arrExpandedRemoteCmdObj = new Array();
-	
-	InstallForPerson = new InstallForPersonalizationPara(RESERVED_ISD_P_AID);
-	InstallForPerson.SetAPDU();
-	arrExpandedRemoteCmdObj[numOfCmdTlvs] = new ExpandedRemoteCommandObject();
-	arrExpandedRemoteCmdObj[numOfCmdTlvs].crtExpandedRemoteApduObj(InstallForPerson.apdu);
-	numOfCmdTlvs ++;
-	
-	var UpdateMetadataReq = new UpdateMetadataRequest();
-	UpdateMetadataReq.serviceProviderName = SP_NAME2;
-	UpdateMetadataReq.profileName = NAME_OP_PROF2;
-	UpdateMetadataReq.iconType = "00";
-	UpdateMetadataReq.profilePolicyRules = "00";
-		
-	var sdatain = UpdateMetadataReq.GenHexData();
-	
-	var stdataArray = StoreDataarr(sdatain,"90","00","");
-	for (var i = 0; i < stdataArray.length; i++)
-	{
-		arrExpandedRemoteCmdObj[numOfCmdTlvs] = new ExpandedRemoteCommandObject();
-		arrExpandedRemoteCmdObj[numOfCmdTlvs].crtExpandedRemoteApduObj(stdataArray[i]);
-		numOfCmdTlvs ++;
-		
-	}
-	
-	sAPDU = GenExpandedRemoteCmd(arrExpandedRemoteCmdObj);
-	
-	SendMessageToCard_GP(sSendType,"91XX",0,MNO_TAR_PROFILE_OPERATIONAL1,"12210515",sAPDU);
-	
-	var exResPara = new ExpandedRemoteResponsePara(arrExpandedRemoteCmdObj, "9000", "00", sSendType);
-	CardSendMessageToServerExpandedRemoteCmd(exResPara);
-	
-	if (stdataArray[stdataArray.length - 1].sw == "9000")
-			obj.SubLevelError("期望Update Metadata request数据为空时,抛错");
-	
-	TerminalResponse("00","9000");
-	
-	curLogicChannel = 1;
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
-	TS_SELECT("Select ISD",ISD_R_AID,"9000");
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行ProfileInfoListRequest,获取profile信息;");
-	var proInfoListRequest = new ProfileInfoListRequest();
-	proInfoListRequest.searchCriteria = new ChoiceObj(tagOfsearchCriteria_ProfileInfo.iccid,ICCID_OP_PROF1);
-	proInfoListRequest.tagList = "9192939499";
-	proInfoListRequest.GenHexData();
-	var respData = LPAd_Transport_data_to_eUICC(proInfoListRequest.hexData);
-
-	var proInfoListResponse = new  ProfileInfoListResponse();
-	proInfoListResponse.checkCardResDataFormat(respData);
-	
-	try
-	{
-		curStrHandle.CheckData(SP_NAME1, proInfoListResponse.profileInfoListOk.arrOfElement[0].serviceProviderName, "serviceProviderName");
-		curStrHandle.CheckData(PROFILE_OPERATIONAL1_NAME1, proInfoListResponse.profileInfoListOk.arrOfElement[0].profileName, "profileName");
-		curStrHandle.CheckData("01", proInfoListResponse.profileInfoListOk.arrOfElement[0].iconType, "iconType");
-		curStrHandle.CheckData(ICON_OP_PROF1, proInfoListResponse.profileInfoListOk.arrOfElement[0].icon, "icon");
-		curStrHandle.CheckData("0560", proInfoListResponse.profileInfoListOk.arrOfElement[0].profilePolicyRules, "profilePolicyRules");
-	}catch(e){
-		obj.SubLevel(ProfileInfoListResponse_Data_Error, level_of_SubLevel.error);
-	}
-	RecoverCard();
-	return;
-	
-	
+// Author: 卡思Cas智能体
+// Date: 20261005-152741
+// Function: (purpose 原文未由 SGP.23 该 TC 提供,corpus vacuum 登记)TC_eUICC_ES6.UpdateMetadata,Test Sequence #01–#11(#05 FFS 不适用);每序列 Nominal/Error 混合,见 steps 前缀,适用性 M。
+// Test points: S1-C1 ATR_present;S2-C2 FCP_Template;S2-C1 SW;S3-C1 SW;S4-C1 final SW;S5-C1 SW1 91
+//   S7-C1 SW;S8-C1 SW;S9-C1 SW;S10-C1 SW;S10-C2 serviceProviderName SP Name 1
+//   S10-C2 profileName Operational Profile Name 1;S10-C2 iconType;S10-C2 icon present
+//   S10-C2 profilePolicyRules {ppr2} oracle;S11-C1 ATR_present;S12-C2 FCP_Template;S12-C1 SW
+//   S13-C1 SW;S14-C1 final SW;S15-C1 SW1 91;S17-C1 SW;S18-C1 SW;S19-C1 SW;S20-C1 SW
+//   S20-C2 serviceProviderName SP Name 1;S20-C2 profileName Operational Profile Name 1
+//   S20-C2 iconType;S20-C2 icon present;S20-C2 profilePolicyRules {ppr1} oracle;S21-C1 ATR_present
+//   S22-C2 FCP_Template;S22-C1 SW;S23-C1 SW;S24-C1 final SW;S25-C1 SW1 91;S27-C1 SW;S28-C1 SW
+//   S29-C1 SW;S30-C1 SW;S30-C2 serviceProviderName SP Name 2
+//   S30-C2 profileName Operational Profile Name 2;S30-C2 profilePolicyRules absent;S30-C2 iconType
+//   S30-C2 icon present;S31-C1 ATR_present;S32-C2 FCP_Template;S32-C1 SW;S33-C1 SW;S34-C1 final SW
+//   S35-C1 SW1 91;S37-C1 SW;S38-C1 SW;S39-C1 SW;S40-C1 SW;S40-C2 serviceProviderName absent
+//   S40-C2 profileName absent;S40-C2 profilePolicyRules absent;S40-C2 iconType;S40-C2 icon present
+//   S41-C1 ATR_present;S42-C2 FCP_Template;S42-C1 SW;S43-C1 SW;S44-C1 final SW;S45-C1 SW1 91
+//   S47-C1 SW;S48-C1 SW1 91;S50-C1 SW;S51-C1 SW;S52-C1 SW;S53-C1 SW
+//   S53-C2 serviceProviderName SP Name 2;S53-C2 profileName Operational Profile Name 2
+//   S53-C2 profilePolicyRules absent;S53-C2 iconType;S53-C2 icon present;S54-C1 ATR_present
+//   S55-C2 FCP_Template;S55-C1 SW;S56-C1 SW;S57-C1 final SW;S58-C1 SW1 91;S60-C1 SW;S61-C1 SW
+//   S62-C1 SW;S63-C1 SW;S63-C2 profileInfoListOk present;S64-C1 ATR_present;S65-C2 FCP_Template
+//   S65-C1 SW;S66-C1 SW;S67-C1 final SW;S70-C1 SW;S71-C1 SW;S72-C1 SW;S73-C1 SW
+//   S73-C2 profileInfoListOk present;S74-C1 ATR_present;S75-C2 FCP_Template;S75-C1 SW;S76-C1 SW
+//   S77-C1 final SW;S78-C1 SW1 91;S80-C1 SW;S81-C1 SW;S82-C1 SW;S83-C1 SW
+//   S83-C2 profileInfoListOk present;S84-C1 ATR_present;S85-C2 FCP_Template;S85-C1 SW;S86-C1 SW
+//   S87-C1 final SW;S88-C1 SW1 91;S90-C1 SW;S91-C1 SW;S92-C1 SW;S93-C1 SW
+//   S93-C2 profileInfoListOk present;S94-C1 ATR_present;S95-C2 FCP_Template;S95-C1 SW;S96-C1 SW
+//   S97-C1 final SW;S98-C1 SW1 91;S100-C1 SW;S101-C1 SW;S102-C1 SW;S103-C1 SW
+//   S103-C2 profileInfoListOk present
+// 本函数由 CaseIR 4.2.2.2.1 编译生成(fullwave-blindgen-live-70,SGP.23 v1.16 × SGP.22 v2.7):字节权威=CaseIR,非誊录黄金脚本。
+// Value-free template: every data byte is injected from CaseIR fields; no scaffold globals (see docs/speconly/compile-symbol-migration.md).
+// 适用性 M:编译期门,运行时由 harness 环境前置承担。
+function TC_eUICC_ES6_UpdateMetadata_01_11_05_FFS_Nominal_Error_steps() {
+    var bind = curBind;
+    // GIC General Initial Condition: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
+    // IC1 PROC_EUICC_INITIALIZATION_SEQUENCE(每序列): declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
+
+    // 步骤 1:Seq#01 IC1/1: RESET(PROC_EUICC_INITIALIZATION_SEQUENCE 展开1/4,K_annexC2_procs 表1256)(procedure_expansion)
+    var s1 = bind.resetAndAtr();
+    bind.checkData("S1-C1 ATR_present", "1", s1.atr_hex !== "" ? "1" : "0");
+
+    // 步骤 2:Seq#01 IC1/2: [SELECT_MF](展开2/4)(procedure_expansion)
+    // FCP outer tag not materialized from clause: tag-face asserted only when corpus fixes the tag byte (e.g. TS 102 221 FCP '62').
+    var s2 = bind.sendApdu("00", "A4", "00", "04", "3F00", "00", "9000");
+    bind.checkData("S2-C2 FCP_Template", "1", s2.resp.length > 0 ? "1" : "0");
+    bind.checkData("S2-C1 SW", "9000", s2.sw);
+
+    // 步骤 3:Seq#01 IC1/3: [TERMINAL_CAPABILITY_LPAd](展开3/4)(procedure_expansion)
+    var s3 = bind.sendApdu("80", "AA", "00", "00", "A9058100830107", null, "9000");
+    bind.checkData("S3-C1 SW", "9000", s3.sw);
+
+    // 步骤 4:Seq#01 IC1/4: [TERMINAL_PROFILE](展开4/4)(procedure_expansion)
+    var steady4 = bind.runToSteadyState(function () {
+        return bind.sendTerminalProfile("FFFFFFFF7F9D00DFBF00001FE2000000C7EB0000000168005000000000000200", "9000");
+    });
+    bind.checkData("S4-C1 final SW", "9000", steady4.final.sw);
+
+    // 步骤 5:Seq#01 1: MTD_SEND_SMS_PP(tc_step;REQ: RQ54_001, RQ54_002, RQ54_003, RQ54_004, RQ54_005, RQ54_006, RQ54_007, RQ54_009, RQ54_010, RQ54_013_1, RQ29_021, RQ24_021, RQ54_011)
+    // MTD_SEND_SMS_PP ENVELOPE (H Annex C.1 表1238 Details: 80 C2 00 00 <L>): SCP80-packed SMS-PP body is runtime-domain
+    // (<MNO_SCP80_COUNTER>/<CC>/<C_APDUS_SCRIPT>) — no bytes fabricated; the embedded STORE DATA
+    // script executes via the proactive FETCH / TERMINAL RESPONSE chain, not in this response.
+    var s5 = bind.sendApdu("80", "C2", "00", "00", null, null, null);
+    bind.checkData("S5-C1 SW1 91", "91", s5.sw.substring(0, 2));
+
+    // 步骤 6:Seq#01 2: FETCH "XX"(tc_step;REQ: RQ54_015, RQ54_011)
+    // FETCH header literals follow the golden wire evidence 8012 (same
+    // anchor as runToSteadyState; J Annex D.4 has no FETCH row, D 2.2.2
+    // gives mechanism only). Le = pending length from the last 91XX
+    // (chain rule, binding-internal state).
+    var s6 = bind.fetchPending("80", "12", "00", "00", null);
+    // S6-C1: binding:fetch_sms_por_runtime_parse(MTD_CHECK_SMS_POR;H-annexC1) (check_attestation)
+    // S6-C2: binding:fetch_length_chaining_last_91xx_sw2(TS102223-6.3-NOTE1) (check_attestation)
+
+    // 步骤 7:Seq#01 3: TERMINAL RESPONSE(tc_step)
+    // TERMINAL RESPONSE data is dynamically built by the binding from the
+    // last FETCHed proactive command (D 2.2.2; buildTrData) - never static.
+    // Header literals follow the golden wire evidence 8014.
+    var s7 = bind.terminalResponseForPending("80", "14", "00", "00", "9000");
+    bind.checkData("S7-C1 SW", "9000", s7.sw);
+
+    // 步骤 8:Seq#01 4/1: [MANAGE_CHANNEL_OPEN](PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR 展开1/2,K_annexC2_procs 表1258)(procedure_expansion)
+    // CHANNEL_NUMBER extraction and dynamic CLA rebinding are CasBind internal state (chaining rule; no generated-code re-implementation).
+    var s8 = bind.manageChannelOpen("9000");
+    bind.checkData("S8-C1 SW", "9000", s8.sw);
+
+    // 步骤 9:Seq#01 4/2: MTD_SELECT(procedure_expansion)
+    // CLA = bound channel (cla_rule) and <L> length binding are CasBind internal state (chaining rule; no generated-code re-implementation).
+    var s9 = bind.sendApdu(null, "A4", "04", "00", "A0000005591010FFFFFFFF8900000100", "00", "9000");
+    // MTD_SELECT expected face is SW-only (K Annex C.2 open-channel procedure step 2: no FCI content assertion in corpus); no fabricated template parse.
+    bind.checkData("S9-C1 SW", "9000", s9.sw);
+
+    // 步骤 10:Seq#01 5: MTD_STORE_DATA(tc_step;REQ: RQ54_013_1, RQ54_009, RQ57_120, RQ57_122, RQ57_123, RQ57_126)
+    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
+    var sdCla10 = s8.chan !== null ? (s8.chan <= 3 ? 128 + s8.chan : 188 + s8.chan).toString(16).toUpperCase() : null;
+    var s10 = bind.sendApdu(sdCla10, "E2", "91", "00", "BF2D15A00C5A0A989209012143658709F55C059192939499", "00", "9000");
+    bind.checkData("S10-C1 SW", "9000", s10.sw);
+    var r2p10 = BindEs10xProcProfile.walkChoiceList(s10.resp, {respTag: "BF2D", okTag: "A0", errTag: "81"});
+    var r2e10 = r2p10.elements.length > 0 ? r2p10.elements[0].fields : null;
+    var r2a10_91 = __asciiHex("SP Name 1");
+    bind.checkData("S10-C2 serviceProviderName SP Name 1", r2a10_91, r2e10 === null ? "absent" : (r2e10["91"] === undefined ? "absent" : r2e10["91"]));
+    var r2a10_92 = __asciiHex("Operational Profile Name 1");
+    bind.checkData("S10-C2 profileName Operational Profile Name 1", r2a10_92, r2e10 === null ? "absent" : (r2e10["92"] === undefined ? "absent" : r2e10["92"]));
+    bind.checkData("S10-C2 iconType", "01", r2e10 === null ? "absent" : (r2e10["93"] === undefined ? "absent" : r2e10["93"]));
+    bind.checkData("S10-C2 icon present", "1", (r2e10 !== null && r2e10["94"] !== undefined) ? "1" : "0");
+    // S10-C2: profilePolicyRules {ppr2} 等值比对基准 = PprIds BIT STRING 位定位 oracle(模块未入包)
+    // ——运行时无比对操作数,发射 fail-closed 恒断言诚实面(如实计错,不伪造通过)。
+    bind.checkData("S10-C2 profilePolicyRules {ppr2} oracle", "ppr_bits_oracle_declared", "oracle_absent_ppr_bits_module_vacuum");
+    // S10-C3: kind 'requirement' pattern 'profilePolicyRules per R_GET_UPDATE_N1' has no static generation face (corpus vacuum; see CaseIR unresolved).
+    // S10-C3: binding:bf2d_query_structure_satisfies_requirement(S22-prof_info) (check_attestation)
+
+    // 步骤 11:Seq#02 IC1/1: RESET(PROC_EUICC_INITIALIZATION_SEQUENCE 展开1/4,K_annexC2_procs 表1256)(procedure_expansion)
+    var s11 = bind.resetAndAtr();
+    bind.checkData("S11-C1 ATR_present", "1", s11.atr_hex !== "" ? "1" : "0");
+
+    // 步骤 12:Seq#02 IC1/2: [SELECT_MF](展开2/4)(procedure_expansion)
+    // FCP outer tag not materialized from clause: tag-face asserted only when corpus fixes the tag byte (e.g. TS 102 221 FCP '62').
+    var s12 = bind.sendApdu("00", "A4", "00", "04", "3F00", "00", "9000");
+    bind.checkData("S12-C2 FCP_Template", "1", s12.resp.length > 0 ? "1" : "0");
+    bind.checkData("S12-C1 SW", "9000", s12.sw);
+
+    // 步骤 13:Seq#02 IC1/3: [TERMINAL_CAPABILITY_LPAd](展开3/4)(procedure_expansion)
+    var s13 = bind.sendApdu("80", "AA", "00", "00", "A9058100830107", null, "9000");
+    bind.checkData("S13-C1 SW", "9000", s13.sw);
+
+    // 步骤 14:Seq#02 IC1/4: [TERMINAL_PROFILE](展开4/4)(procedure_expansion)
+    var steady14 = bind.runToSteadyState(function () {
+        return bind.sendTerminalProfile("FFFFFFFF7F9D00DFBF00001FE2000000C7EB0000000168005000000000000200", "9000");
+    });
+    bind.checkData("S14-C1 final SW", "9000", steady14.final.sw);
+
+    // 步骤 15:Seq#02 1: MTD_SEND_SMS_PP(tc_step;REQ: RQ54_001, RQ54_002, RQ54_003, RQ54_004, RQ54_005, RQ54_006, RQ54_007, RQ54_009, RQ54_010, RQ54_011, RQ54_012, RQ54_013_1, RQ29_021, RQ24_021)
+    // MTD_SEND_SMS_PP ENVELOPE (H Annex C.1 表1238 Details: 80 C2 00 00 <L>): SCP80-packed SMS-PP body is runtime-domain
+    // (<MNO_SCP80_COUNTER>/<CC>/<C_APDUS_SCRIPT>) — no bytes fabricated; the embedded STORE DATA
+    // script executes via the proactive FETCH / TERMINAL RESPONSE chain, not in this response.
+    var s15 = bind.sendApdu("80", "C2", "00", "00", null, null, null);
+    bind.checkData("S15-C1 SW1 91", "91", s15.sw.substring(0, 2));
+
+    // 步骤 16:Seq#02 2: FETCH "XX"(tc_step;REQ: RQ54_015, RQ54_011)
+    // FETCH header literals follow the golden wire evidence 8012 (same
+    // anchor as runToSteadyState; J Annex D.4 has no FETCH row, D 2.2.2
+    // gives mechanism only). Le = pending length from the last 91XX
+    // (chain rule, binding-internal state).
+    var s16 = bind.fetchPending("80", "12", "00", "00", null);
+    // S16-C1: binding:fetch_sms_por_runtime_parse(MTD_CHECK_SMS_POR;H-annexC1) (check_attestation)
+    // S16-C2: binding:fetch_length_chaining_last_91xx_sw2(TS102223-6.3-NOTE1) (check_attestation)
+
+    // 步骤 17:Seq#02 3: TERMINAL RESPONSE(tc_step)
+    // TERMINAL RESPONSE data is dynamically built by the binding from the
+    // last FETCHed proactive command (D 2.2.2; buildTrData) - never static.
+    // Header literals follow the golden wire evidence 8014.
+    var s17 = bind.terminalResponseForPending("80", "14", "00", "00", "9000");
+    bind.checkData("S17-C1 SW", "9000", s17.sw);
+
+    // 步骤 18:Seq#02 4/1: [MANAGE_CHANNEL_OPEN](PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR 展开1/2,K_annexC2_procs 表1258)(procedure_expansion)
+    // CHANNEL_NUMBER extraction and dynamic CLA rebinding are CasBind internal state (chaining rule; no generated-code re-implementation).
+    var s18 = bind.manageChannelOpen("9000");
+    bind.checkData("S18-C1 SW", "9000", s18.sw);
+
+    // 步骤 19:Seq#02 4/2: MTD_SELECT(procedure_expansion)
+    // CLA = bound channel (cla_rule) and <L> length binding are CasBind internal state (chaining rule; no generated-code re-implementation).
+    var s19 = bind.sendApdu(null, "A4", "04", "00", "A0000005591010FFFFFFFF8900000100", "00", "9000");
+    // MTD_SELECT expected face is SW-only (K Annex C.2 open-channel procedure step 2: no FCI content assertion in corpus); no fabricated template parse.
+    bind.checkData("S19-C1 SW", "9000", s19.sw);
+
+    // 步骤 20:Seq#02 5: MTD_STORE_DATA(tc_step;REQ: RQ54_009, RQ54_012, RQ54_013_1, RQ57_120, RQ57_122, RQ57_123, RQ57_126)
+    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
+    var sdCla20 = s18.chan !== null ? (s18.chan <= 3 ? 128 + s18.chan : 188 + s18.chan).toString(16).toUpperCase() : null;
+    var s20 = bind.sendApdu(sdCla20, "E2", "91", "00", "BF2D15A00C5A0A989209012143658709F55C059192939499", "00", "9000");
+    bind.checkData("S20-C1 SW", "9000", s20.sw);
+    var r2p20 = BindEs10xProcProfile.walkChoiceList(s20.resp, {respTag: "BF2D", okTag: "A0", errTag: "81"});
+    var r2e20 = r2p20.elements.length > 0 ? r2p20.elements[0].fields : null;
+    var r2a20_91 = __asciiHex("SP Name 1");
+    bind.checkData("S20-C2 serviceProviderName SP Name 1", r2a20_91, r2e20 === null ? "absent" : (r2e20["91"] === undefined ? "absent" : r2e20["91"]));
+    var r2a20_92 = __asciiHex("Operational Profile Name 1");
+    bind.checkData("S20-C2 profileName Operational Profile Name 1", r2a20_92, r2e20 === null ? "absent" : (r2e20["92"] === undefined ? "absent" : r2e20["92"]));
+    bind.checkData("S20-C2 iconType", "00", r2e20 === null ? "absent" : (r2e20["93"] === undefined ? "absent" : r2e20["93"]));
+    bind.checkData("S20-C2 icon present", "1", (r2e20 !== null && r2e20["94"] !== undefined) ? "1" : "0");
+    // S20-C2: profilePolicyRules {ppr1} 等值比对基准 = PprIds BIT STRING 位定位 oracle(模块未入包)
+    // ——运行时无比对操作数,发射 fail-closed 恒断言诚实面(如实计错,不伪造通过)。
+    bind.checkData("S20-C2 profilePolicyRules {ppr1} oracle", "ppr_bits_oracle_declared", "oracle_absent_ppr_bits_module_vacuum");
+    // S20-C3: kind 'requirement' pattern 'profilePolicyRules per R_GET_UPDATE_N2' has no static generation face (corpus vacuum; see CaseIR unresolved).
+    // S20-C3: binding:bf2d_query_structure_satisfies_requirement(S22-prof_info) (check_attestation)
+
+    // 步骤 21:Seq#03 IC1/1: RESET(PROC_EUICC_INITIALIZATION_SEQUENCE 展开1/4,K_annexC2_procs 表1256)(procedure_expansion)
+    var s21 = bind.resetAndAtr();
+    bind.checkData("S21-C1 ATR_present", "1", s21.atr_hex !== "" ? "1" : "0");
+
+    // 步骤 22:Seq#03 IC1/2: [SELECT_MF](展开2/4)(procedure_expansion)
+    // FCP outer tag not materialized from clause: tag-face asserted only when corpus fixes the tag byte (e.g. TS 102 221 FCP '62').
+    var s22 = bind.sendApdu("00", "A4", "00", "04", "3F00", "00", "9000");
+    bind.checkData("S22-C2 FCP_Template", "1", s22.resp.length > 0 ? "1" : "0");
+    bind.checkData("S22-C1 SW", "9000", s22.sw);
+
+    // 步骤 23:Seq#03 IC1/3: [TERMINAL_CAPABILITY_LPAd](展开3/4)(procedure_expansion)
+    var s23 = bind.sendApdu("80", "AA", "00", "00", "A9058100830107", null, "9000");
+    bind.checkData("S23-C1 SW", "9000", s23.sw);
+
+    // 步骤 24:Seq#03 IC1/4: [TERMINAL_PROFILE](展开4/4)(procedure_expansion)
+    var steady24 = bind.runToSteadyState(function () {
+        return bind.sendTerminalProfile("FFFFFFFF7F9D00DFBF00001FE2000000C7EB0000000168005000000000000200", "9000");
+    });
+    bind.checkData("S24-C1 final SW", "9000", steady24.final.sw);
+
+    // 步骤 25:Seq#03 1: MTD_SEND_SMS_PP(tc_step;REQ: RQ54_001, RQ54_002, RQ54_003, RQ54_004, RQ54_005, RQ54_006, RQ54_007, RQ54_009, RQ54_010, RQ54_011, RQ54_012, RQ54_013_1, RQ29_021, RQ24_021)
+    // MTD_SEND_SMS_PP ENVELOPE (H Annex C.1 表1238 Details: 80 C2 00 00 <L>): SCP80-packed SMS-PP body is runtime-domain
+    // (<MNO_SCP80_COUNTER>/<CC>/<C_APDUS_SCRIPT>) — no bytes fabricated; the embedded STORE DATA
+    // script executes via the proactive FETCH / TERMINAL RESPONSE chain, not in this response.
+    var s25 = bind.sendApdu("80", "C2", "00", "00", null, null, null);
+    bind.checkData("S25-C1 SW1 91", "91", s25.sw.substring(0, 2));
+
+    // 步骤 26:Seq#03 2: FETCH "XX"(tc_step;REQ: RQ54_015, RQ54_011)
+    // FETCH header literals follow the golden wire evidence 8012 (same
+    // anchor as runToSteadyState; J Annex D.4 has no FETCH row, D 2.2.2
+    // gives mechanism only). Le = pending length from the last 91XX
+    // (chain rule, binding-internal state).
+    var s26 = bind.fetchPending("80", "12", "00", "00", null);
+    // S26-C1: binding:fetch_sms_por_runtime_parse(MTD_CHECK_SMS_POR;H-annexC1) (check_attestation)
+    // S26-C2: binding:fetch_length_chaining_last_91xx_sw2(TS102223-6.3-NOTE1) (check_attestation)
+
+    // 步骤 27:Seq#03 3: TERMINAL RESPONSE(tc_step)
+    // TERMINAL RESPONSE data is dynamically built by the binding from the
+    // last FETCHed proactive command (D 2.2.2; buildTrData) - never static.
+    // Header literals follow the golden wire evidence 8014.
+    var s27 = bind.terminalResponseForPending("80", "14", "00", "00", "9000");
+    bind.checkData("S27-C1 SW", "9000", s27.sw);
+
+    // 步骤 28:Seq#03 4/1: [MANAGE_CHANNEL_OPEN](PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR 展开1/2,K_annexC2_procs 表1258)(procedure_expansion)
+    // CHANNEL_NUMBER extraction and dynamic CLA rebinding are CasBind internal state (chaining rule; no generated-code re-implementation).
+    var s28 = bind.manageChannelOpen("9000");
+    bind.checkData("S28-C1 SW", "9000", s28.sw);
+
+    // 步骤 29:Seq#03 4/2: MTD_SELECT(procedure_expansion)
+    // CLA = bound channel (cla_rule) and <L> length binding are CasBind internal state (chaining rule; no generated-code re-implementation).
+    var s29 = bind.sendApdu(null, "A4", "04", "00", "A0000005591010FFFFFFFF8900000100", "00", "9000");
+    // MTD_SELECT expected face is SW-only (K Annex C.2 open-channel procedure step 2: no FCI content assertion in corpus); no fabricated template parse.
+    bind.checkData("S29-C1 SW", "9000", s29.sw);
+
+    // 步骤 30:Seq#03 5: MTD_STORE_DATA(tc_step;REQ: RQ54_009, RQ54_012, RQ54_013_1, RQ57_120, RQ57_122, RQ57_123, RQ57_126)
+    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
+    var sdCla30 = s28.chan !== null ? (s28.chan <= 3 ? 128 + s28.chan : 188 + s28.chan).toString(16).toUpperCase() : null;
+    var s30 = bind.sendApdu(sdCla30, "E2", "91", "00", "BF2D15A00C5A0A989209012143658709F55C059192939499", "00", "9000");
+    bind.checkData("S30-C1 SW", "9000", s30.sw);
+    var r2p30 = BindEs10xProcProfile.walkChoiceList(s30.resp, {respTag: "BF2D", okTag: "A0", errTag: "81"});
+    var r2e30 = r2p30.elements.length > 0 ? r2p30.elements[0].fields : null;
+    var r2a30_91 = __asciiHex("SP Name 2");
+    bind.checkData("S30-C2 serviceProviderName SP Name 2", r2a30_91, r2e30 === null ? "absent" : (r2e30["91"] === undefined ? "absent" : r2e30["91"]));
+    var r2a30_92 = __asciiHex("Operational Profile Name 2");
+    bind.checkData("S30-C2 profileName Operational Profile Name 2", r2a30_92, r2e30 === null ? "absent" : (r2e30["92"] === undefined ? "absent" : r2e30["92"]));
+    bind.checkData("S30-C2 profilePolicyRules absent", "absent", (r2e30 === null || r2e30["99"] === undefined) ? "absent" : r2e30["99"]);
+    bind.checkData("S30-C2 iconType", "01", r2e30 === null ? "absent" : (r2e30["93"] === undefined ? "absent" : r2e30["93"]));
+    bind.checkData("S30-C2 icon present", "1", (r2e30 !== null && r2e30["94"] !== undefined) ? "1" : "0");
+    // S30-C3: kind 'requirement' pattern 'profilePolicyRules per R_GET_UPDATE_N3' has no static generation face (corpus vacuum; see CaseIR unresolved).
+    // S30-C3: binding:bf2d_query_structure_satisfies_requirement(S22-prof_info) (check_attestation)
+
+    // 步骤 31:Seq#04 IC1/1: RESET(PROC_EUICC_INITIALIZATION_SEQUENCE 展开1/4,K_annexC2_procs 表1256)(procedure_expansion)
+    var s31 = bind.resetAndAtr();
+    bind.checkData("S31-C1 ATR_present", "1", s31.atr_hex !== "" ? "1" : "0");
+
+    // 步骤 32:Seq#04 IC1/2: [SELECT_MF](展开2/4)(procedure_expansion)
+    // FCP outer tag not materialized from clause: tag-face asserted only when corpus fixes the tag byte (e.g. TS 102 221 FCP '62').
+    var s32 = bind.sendApdu("00", "A4", "00", "04", "3F00", "00", "9000");
+    bind.checkData("S32-C2 FCP_Template", "1", s32.resp.length > 0 ? "1" : "0");
+    bind.checkData("S32-C1 SW", "9000", s32.sw);
+
+    // 步骤 33:Seq#04 IC1/3: [TERMINAL_CAPABILITY_LPAd](展开3/4)(procedure_expansion)
+    var s33 = bind.sendApdu("80", "AA", "00", "00", "A9058100830107", null, "9000");
+    bind.checkData("S33-C1 SW", "9000", s33.sw);
+
+    // 步骤 34:Seq#04 IC1/4: [TERMINAL_PROFILE](展开4/4)(procedure_expansion)
+    var steady34 = bind.runToSteadyState(function () {
+        return bind.sendTerminalProfile("FFFFFFFF7F9D00DFBF00001FE2000000C7EB0000000168005000000000000200", "9000");
+    });
+    bind.checkData("S34-C1 final SW", "9000", steady34.final.sw);
+
+    // 步骤 35:Seq#04 1: MTD_SEND_SMS_PP(tc_step;REQ: RQ54_001, RQ54_002, RQ54_003, RQ54_004, RQ54_005, RQ54_006, RQ54_007, RQ54_009, RQ54_010, RQ54_011, RQ54_013, RQ54_013_1, RQ29_021, RQ24_021)
+    // MTD_SEND_SMS_PP ENVELOPE (H Annex C.1 表1238 Details: 80 C2 00 00 <L>): SCP80-packed SMS-PP body is runtime-domain
+    // (<MNO_SCP80_COUNTER>/<CC>/<C_APDUS_SCRIPT>) — no bytes fabricated; the embedded STORE DATA
+    // script executes via the proactive FETCH / TERMINAL RESPONSE chain, not in this response.
+    var s35 = bind.sendApdu("80", "C2", "00", "00", null, null, null);
+    bind.checkData("S35-C1 SW1 91", "91", s35.sw.substring(0, 2));
+
+    // 步骤 36:Seq#04 2: FETCH "XX"(tc_step;REQ: RQ54_015, RQ54_011)
+    // FETCH header literals follow the golden wire evidence 8012 (same
+    // anchor as runToSteadyState; J Annex D.4 has no FETCH row, D 2.2.2
+    // gives mechanism only). Le = pending length from the last 91XX
+    // (chain rule, binding-internal state).
+    var s36 = bind.fetchPending("80", "12", "00", "00", null);
+    // S36-C1: binding:fetch_sms_por_runtime_parse(MTD_CHECK_SMS_POR;H-annexC1) (check_attestation)
+    // S36-C2: binding:fetch_length_chaining_last_91xx_sw2(TS102223-6.3-NOTE1) (check_attestation)
+
+    // 步骤 37:Seq#04 3: TERMINAL RESPONSE(tc_step)
+    // TERMINAL RESPONSE data is dynamically built by the binding from the
+    // last FETCHed proactive command (D 2.2.2; buildTrData) - never static.
+    // Header literals follow the golden wire evidence 8014.
+    var s37 = bind.terminalResponseForPending("80", "14", "00", "00", "9000");
+    bind.checkData("S37-C1 SW", "9000", s37.sw);
+
+    // 步骤 38:Seq#04 4/1: [MANAGE_CHANNEL_OPEN](PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR 展开1/2,K_annexC2_procs 表1258)(procedure_expansion)
+    // CHANNEL_NUMBER extraction and dynamic CLA rebinding are CasBind internal state (chaining rule; no generated-code re-implementation).
+    var s38 = bind.manageChannelOpen("9000");
+    bind.checkData("S38-C1 SW", "9000", s38.sw);
+
+    // 步骤 39:Seq#04 4/2: MTD_SELECT(procedure_expansion)
+    // CLA = bound channel (cla_rule) and <L> length binding are CasBind internal state (chaining rule; no generated-code re-implementation).
+    var s39 = bind.sendApdu(null, "A4", "04", "00", "A0000005591010FFFFFFFF8900000100", "00", "9000");
+    // MTD_SELECT expected face is SW-only (K Annex C.2 open-channel procedure step 2: no FCI content assertion in corpus); no fabricated template parse.
+    bind.checkData("S39-C1 SW", "9000", s39.sw);
+
+    // 步骤 40:Seq#04 5: MTD_STORE_DATA(tc_step;REQ: RQ54_013, RQ54_013_1, RQ54_009, RQ57_120, RQ57_122, RQ57_123, RQ57_126)
+    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
+    var sdCla40 = s38.chan !== null ? (s38.chan <= 3 ? 128 + s38.chan : 188 + s38.chan).toString(16).toUpperCase() : null;
+    var s40 = bind.sendApdu(sdCla40, "E2", "91", "00", "BF2D15A00C5A0A989209012143658709F55C059192939499", "00", "9000");
+    bind.checkData("S40-C1 SW", "9000", s40.sw);
+    var r2p40 = BindEs10xProcProfile.walkChoiceList(s40.resp, {respTag: "BF2D", okTag: "A0", errTag: "81"});
+    var r2e40 = r2p40.elements.length > 0 ? r2p40.elements[0].fields : null;
+    bind.checkData("S40-C2 serviceProviderName absent", "absent", (r2e40 === null || r2e40["91"] === undefined) ? "absent" : r2e40["91"]);
+    bind.checkData("S40-C2 profileName absent", "absent", (r2e40 === null || r2e40["92"] === undefined) ? "absent" : r2e40["92"]);
+    bind.checkData("S40-C2 profilePolicyRules absent", "absent", (r2e40 === null || r2e40["99"] === undefined) ? "absent" : r2e40["99"]);
+    bind.checkData("S40-C2 iconType", "01", r2e40 === null ? "absent" : (r2e40["93"] === undefined ? "absent" : r2e40["93"]));
+    bind.checkData("S40-C2 icon present", "1", (r2e40 !== null && r2e40["94"] !== undefined) ? "1" : "0");
+    // S40-C3: kind 'requirement' pattern 'profilePolicyRules per R_GET_UPDATE_N4' has no static generation face (corpus vacuum; see CaseIR unresolved).
+    // S40-C3: binding:bf2d_query_structure_satisfies_requirement(S22-prof_info) (check_attestation)
+
+    // 步骤 41:Seq#06 IC1/1: RESET(PROC_EUICC_INITIALIZATION_SEQUENCE 展开1/4,K_annexC2_procs 表1256)(procedure_expansion)
+    var s41 = bind.resetAndAtr();
+    bind.checkData("S41-C1 ATR_present", "1", s41.atr_hex !== "" ? "1" : "0");
+
+    // 步骤 42:Seq#06 IC1/2: [SELECT_MF](展开2/4)(procedure_expansion)
+    // FCP outer tag not materialized from clause: tag-face asserted only when corpus fixes the tag byte (e.g. TS 102 221 FCP '62').
+    var s42 = bind.sendApdu("00", "A4", "00", "04", "3F00", "00", "9000");
+    bind.checkData("S42-C2 FCP_Template", "1", s42.resp.length > 0 ? "1" : "0");
+    bind.checkData("S42-C1 SW", "9000", s42.sw);
+
+    // 步骤 43:Seq#06 IC1/3: [TERMINAL_CAPABILITY_LPAd](展开3/4)(procedure_expansion)
+    var s43 = bind.sendApdu("80", "AA", "00", "00", "A9058100830107", null, "9000");
+    bind.checkData("S43-C1 SW", "9000", s43.sw);
+
+    // 步骤 44:Seq#06 IC1/4: [TERMINAL_PROFILE](展开4/4)(procedure_expansion)
+    var steady44 = bind.runToSteadyState(function () {
+        return bind.sendTerminalProfile("FFFFFFFF7F9D00DFBF00001FE2000000C7EB0000000168005000000000000200", "9000");
+    });
+    bind.checkData("S44-C1 final SW", "9000", steady44.final.sw);
+
+    // 步骤 45:Seq#06 IC2: MTD_SEND_SMS_PP(tc_step)
+    // MTD_SEND_SMS_PP ENVELOPE (H Annex C.1 表1238 Details: 80 C2 00 00 <L>): SCP80-packed SMS-PP body is runtime-domain
+    // (<MNO_SCP80_COUNTER>/<CC>/<C_APDUS_SCRIPT>) — no bytes fabricated; the embedded STORE DATA
+    // script executes via the proactive FETCH / TERMINAL RESPONSE chain, not in this response.
+    var s45 = bind.sendApdu("80", "C2", "00", "00", null, null, null);
+    bind.checkData("S45-C1 SW1 91", "91", s45.sw.substring(0, 2));
+
+    // 步骤 46:Seq#06 IC3: FETCH "XX"(tc_step)
+    // FETCH header literals follow the golden wire evidence 8012 (same
+    // anchor as runToSteadyState; J Annex D.4 has no FETCH row, D 2.2.2
+    // gives mechanism only). Le = pending length from the last 91XX
+    // (chain rule, binding-internal state).
+    var s46 = bind.fetchPending("80", "12", "00", "00", null);
+    // S46-C1: binding:fetch_sms_por_runtime_parse(MTD_CHECK_SMS_POR;H-annexC1) (check_attestation)
+    // S46-C2: binding:fetch_length_chaining_last_91xx_sw2(TS102223-6.3-NOTE1) (check_attestation)
+
+    // 步骤 47:Seq#06 IC4: TERMINAL RESPONSE(tc_step)
+    // TERMINAL RESPONSE data is dynamically built by the binding from the
+    // last FETCHed proactive command (D 2.2.2; buildTrData) - never static.
+    // Header literals follow the golden wire evidence 8014.
+    var s47 = bind.terminalResponseForPending("80", "14", "00", "00", "9000");
+    bind.checkData("S47-C1 SW", "9000", s47.sw);
+
+    // 步骤 48:Seq#06 1: MTD_SEND_SMS_PP(tc_step;REQ: RQ54_001, RQ54_002, RQ54_003, RQ54_004, RQ54_005, RQ54_006, RQ54_007, RQ54_009, RQ54_010, RQ54_011, RQ54_013, RQ54_015, RQ54_013_1, RQ29_021, RQ24_021)
+    // MTD_SEND_SMS_PP ENVELOPE (H Annex C.1 表1238 Details: 80 C2 00 00 <L>): SCP80-packed SMS-PP body is runtime-domain
+    // (<MNO_SCP80_COUNTER>/<CC>/<C_APDUS_SCRIPT>) — no bytes fabricated; the embedded STORE DATA
+    // script executes via the proactive FETCH / TERMINAL RESPONSE chain, not in this response.
+    var s48 = bind.sendApdu("80", "C2", "00", "00", null, null, null);
+    bind.checkData("S48-C1 SW1 91", "91", s48.sw.substring(0, 2));
+
+    // 步骤 49:Seq#06 2: FETCH "XX"(tc_step)
+    // FETCH header literals follow the golden wire evidence 8012 (same
+    // anchor as runToSteadyState; J Annex D.4 has no FETCH row, D 2.2.2
+    // gives mechanism only). Le = pending length from the last 91XX
+    // (chain rule, binding-internal state).
+    var s49 = bind.fetchPending("80", "12", "00", "00", null);
+    // S49-C1: binding:fetch_sms_por_runtime_parse(MTD_CHECK_SMS_POR;H-annexC1) (check_attestation)
+    // S49-C2: binding:fetch_length_chaining_last_91xx_sw2(TS102223-6.3-NOTE1) (check_attestation)
+
+    // 步骤 50:Seq#06 3: TERMINAL RESPONSE(tc_step)
+    // TERMINAL RESPONSE data is dynamically built by the binding from the
+    // last FETCHed proactive command (D 2.2.2; buildTrData) - never static.
+    // Header literals follow the golden wire evidence 8014.
+    var s50 = bind.terminalResponseForPending("80", "14", "00", "00", "9000");
+    bind.checkData("S50-C1 SW", "9000", s50.sw);
+
+    // 步骤 51:Seq#06 4/1: [MANAGE_CHANNEL_OPEN](PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR 展开1/2,K_annexC2_procs 表1258)(procedure_expansion)
+    // CHANNEL_NUMBER extraction and dynamic CLA rebinding are CasBind internal state (chaining rule; no generated-code re-implementation).
+    var s51 = bind.manageChannelOpen("9000");
+    bind.checkData("S51-C1 SW", "9000", s51.sw);
+
+    // 步骤 52:Seq#06 4/2: MTD_SELECT(procedure_expansion)
+    // CLA = bound channel (cla_rule) and <L> length binding are CasBind internal state (chaining rule; no generated-code re-implementation).
+    var s52 = bind.sendApdu(null, "A4", "04", "00", "A0000005591010FFFFFFFF8900000100", "00", "9000");
+    // MTD_SELECT expected face is SW-only (K Annex C.2 open-channel procedure step 2: no FCI content assertion in corpus); no fabricated template parse.
+    bind.checkData("S52-C1 SW", "9000", s52.sw);
+
+    // 步骤 53:Seq#06 5: MTD_STORE_DATA(tc_step;REQ: RQ54_013, RQ54_013_1, RQ54_009, RQ57_120, RQ57_122, RQ57_123, RQ57_126)
+    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
+    var sdCla53 = s51.chan !== null ? (s51.chan <= 3 ? 128 + s51.chan : 188 + s51.chan).toString(16).toUpperCase() : null;
+    var s53 = bind.sendApdu(sdCla53, "E2", "91", "00", "BF2D15A00C5A0A989209012143658709F55C059192939499", "00", "9000");
+    bind.checkData("S53-C1 SW", "9000", s53.sw);
+    var r2p53 = BindEs10xProcProfile.walkChoiceList(s53.resp, {respTag: "BF2D", okTag: "A0", errTag: "81"});
+    var r2e53 = r2p53.elements.length > 0 ? r2p53.elements[0].fields : null;
+    var r2a53_91 = __asciiHex("SP Name 2");
+    bind.checkData("S53-C2 serviceProviderName SP Name 2", r2a53_91, r2e53 === null ? "absent" : (r2e53["91"] === undefined ? "absent" : r2e53["91"]));
+    var r2a53_92 = __asciiHex("Operational Profile Name 2");
+    bind.checkData("S53-C2 profileName Operational Profile Name 2", r2a53_92, r2e53 === null ? "absent" : (r2e53["92"] === undefined ? "absent" : r2e53["92"]));
+    bind.checkData("S53-C2 profilePolicyRules absent", "absent", (r2e53 === null || r2e53["99"] === undefined) ? "absent" : r2e53["99"]);
+    bind.checkData("S53-C2 iconType", "01", r2e53 === null ? "absent" : (r2e53["93"] === undefined ? "absent" : r2e53["93"]));
+    bind.checkData("S53-C2 icon present", "1", (r2e53 !== null && r2e53["94"] !== undefined) ? "1" : "0");
+    // S53-C3: kind 'requirement' pattern 'profilePolicyRules per R_GET_UPDATE_N6' has no static generation face (corpus vacuum; see CaseIR unresolved).
+    // S53-C3: binding:bf2d_query_structure_satisfies_requirement(S22-prof_info) (check_attestation)
+
+    // 步骤 54:Seq#07 IC1/1: RESET(PROC_EUICC_INITIALIZATION_SEQUENCE 展开1/4,K_annexC2_procs 表1256)(procedure_expansion)
+    var s54 = bind.resetAndAtr();
+    bind.checkData("S54-C1 ATR_present", "1", s54.atr_hex !== "" ? "1" : "0");
+
+    // 步骤 55:Seq#07 IC1/2: [SELECT_MF](展开2/4)(procedure_expansion)
+    // FCP outer tag not materialized from clause: tag-face asserted only when corpus fixes the tag byte (e.g. TS 102 221 FCP '62').
+    var s55 = bind.sendApdu("00", "A4", "00", "04", "3F00", "00", "9000");
+    bind.checkData("S55-C2 FCP_Template", "1", s55.resp.length > 0 ? "1" : "0");
+    bind.checkData("S55-C1 SW", "9000", s55.sw);
+
+    // 步骤 56:Seq#07 IC1/3: [TERMINAL_CAPABILITY_LPAd](展开3/4)(procedure_expansion)
+    var s56 = bind.sendApdu("80", "AA", "00", "00", "A9058100830107", null, "9000");
+    bind.checkData("S56-C1 SW", "9000", s56.sw);
+
+    // 步骤 57:Seq#07 IC1/4: [TERMINAL_PROFILE](展开4/4)(procedure_expansion)
+    var steady57 = bind.runToSteadyState(function () {
+        return bind.sendTerminalProfile("FFFFFFFF7F9D00DFBF00001FE2000000C7EB0000000168005000000000000200", "9000");
+    });
+    bind.checkData("S57-C1 final SW", "9000", steady57.final.sw);
+
+    // 步骤 58:Seq#07 1: MTD_SEND_SMS_PP(tc_step;REQ: RQ24_021, RQ54_001, RQ54_002, RQ54_003, RQ54_004, RQ54_005, RQ54_006, RQ54_010, RQ54_011)
+    // MTD_SEND_SMS_PP ENVELOPE (H Annex C.1 表1238 Details: 80 C2 00 00 <L>): SCP80-packed SMS-PP body is runtime-domain
+    // (<MNO_SCP80_COUNTER>/<CC>/<C_APDUS_SCRIPT>) — no bytes fabricated; the embedded STORE DATA
+    // script executes via the proactive FETCH / TERMINAL RESPONSE chain, not in this response.
+    var s58 = bind.sendApdu("80", "C2", "00", "00", null, null, null);
+    bind.checkData("S58-C1 SW1 91", "91", s58.sw.substring(0, 2));
+
+    // 步骤 59:Seq#07 2: FETCH "XX"(tc_step;REQ: RQ54_008, RQ54_014, RQ54_015, RQ54_016, RQ54_011)
+    // FETCH header literals follow the golden wire evidence 8012 (same
+    // anchor as runToSteadyState; J Annex D.4 has no FETCH row, D 2.2.2
+    // gives mechanism only). Le = pending length from the last 91XX
+    // (chain rule, binding-internal state).
+    var s59 = bind.fetchPending("80", "12", "00", "00", null);
+    // S59-C1: binding:fetch_sms_por_runtime_parse(MTD_CHECK_SMS_POR;H-annexC1) (check_attestation)
+    // S59-C2: binding:fetch_length_chaining_last_91xx_sw2(TS102223-6.3-NOTE1) (check_attestation)
+
+    // 步骤 60:Seq#07 3: TERMINAL RESPONSE(tc_step)
+    // TERMINAL RESPONSE data is dynamically built by the binding from the
+    // last FETCHed proactive command (D 2.2.2; buildTrData) - never static.
+    // Header literals follow the golden wire evidence 8014.
+    var s60 = bind.terminalResponseForPending("80", "14", "00", "00", "9000");
+    bind.checkData("S60-C1 SW", "9000", s60.sw);
+
+    // 步骤 61:Seq#07 4/1: [MANAGE_CHANNEL_OPEN](PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR 展开1/2,K_annexC2_procs 表1258)(procedure_expansion)
+    // CHANNEL_NUMBER extraction and dynamic CLA rebinding are CasBind internal state (chaining rule; no generated-code re-implementation).
+    var s61 = bind.manageChannelOpen("9000");
+    bind.checkData("S61-C1 SW", "9000", s61.sw);
+
+    // 步骤 62:Seq#07 4/2: MTD_SELECT(procedure_expansion)
+    // CLA = bound channel (cla_rule) and <L> length binding are CasBind internal state (chaining rule; no generated-code re-implementation).
+    var s62 = bind.sendApdu(null, "A4", "04", "00", "A0000005591010FFFFFFFF8900000100", "00", "9000");
+    // MTD_SELECT expected face is SW-only (K Annex C.2 open-channel procedure step 2: no FCI content assertion in corpus); no fabricated template parse.
+    bind.checkData("S62-C1 SW", "9000", s62.sw);
+
+    // 步骤 63:Seq#07 5: MTD_STORE_DATA(tc_step;REQ: RQ54_014, RQ57_120, RQ57_122, RQ57_123, RQ57_126)
+    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
+    var sdCla63 = s61.chan !== null ? (s61.chan <= 3 ? 128 + s61.chan : 188 + s61.chan).toString(16).toUpperCase() : null;
+    var s63 = bind.sendApdu(sdCla63, "E2", "91", "00", "BF2D15A00C5A0A989209012143658709F55C059192939499", "00", "9000");
+    bind.checkData("S63-C1 SW", "9000", s63.sw);
+    var r2p63 = BindEs10xProcProfile.walkChoiceList(s63.resp, {respTag: "BF2D", okTag: "A0", errTag: "81"});
+    bind.checkData("S63-C2 profileInfoListOk present", "1", (r2p63.branch_tag === "A0" && r2p63.elements.length >= 1) ? "1" : "0");
+    // S63-C3: kind 'requirement' pattern 'metadata unchanged (SP_NAME1/NAME_OP_PROF1/png/ICON_OP_PROF1/{ppr1,ppr2})' has no static generation face (corpus vacuum; see CaseIR unresolved).
+    // S63-C3: binding:bf2d_query_structure_satisfies_requirement(S22-prof_info) (check_attestation)
+
+    // 步骤 64:Seq#08 IC1/1: RESET(PROC_EUICC_INITIALIZATION_SEQUENCE 展开1/4,K_annexC2_procs 表1256)(procedure_expansion)
+    var s64 = bind.resetAndAtr();
+    bind.checkData("S64-C1 ATR_present", "1", s64.atr_hex !== "" ? "1" : "0");
+
+    // 步骤 65:Seq#08 IC1/2: [SELECT_MF](展开2/4)(procedure_expansion)
+    // FCP outer tag not materialized from clause: tag-face asserted only when corpus fixes the tag byte (e.g. TS 102 221 FCP '62').
+    var s65 = bind.sendApdu("00", "A4", "00", "04", "3F00", "00", "9000");
+    bind.checkData("S65-C2 FCP_Template", "1", s65.resp.length > 0 ? "1" : "0");
+    bind.checkData("S65-C1 SW", "9000", s65.sw);
+
+    // 步骤 66:Seq#08 IC1/3: [TERMINAL_CAPABILITY_LPAd](展开3/4)(procedure_expansion)
+    var s66 = bind.sendApdu("80", "AA", "00", "00", "A9058100830107", null, "9000");
+    bind.checkData("S66-C1 SW", "9000", s66.sw);
+
+    // 步骤 67:Seq#08 IC1/4: [TERMINAL_PROFILE](展开4/4)(procedure_expansion)
+    var steady67 = bind.runToSteadyState(function () {
+        return bind.sendTerminalProfile("FFFFFFFF7F9D00DFBF00001FE2000000C7EB0000000168005000000000000200", "9000");
+    });
+    bind.checkData("S67-C1 final SW", "9000", steady67.final.sw);
+
+    // 步骤 68:Seq#08 1: MTD_SEND_SMS_PP(tc_step;REQ: RQ54_001, RQ54_002, RQ54_003, RQ54_004, RQ54_005, RQ54_006, RQ54_010, RQ54_011, RQ24_024, RQ24_021)
+    // MTD_SEND_SMS_PP ENVELOPE (H Annex C.1 表1238 Details: 80 C2 00 00 <L>): SCP80-packed SMS-PP body is runtime-domain
+    // (<MNO_SCP80_COUNTER>/<CC>/<C_APDUS_SCRIPT>) — no bytes fabricated; the embedded STORE DATA
+    // script executes via the proactive FETCH / TERMINAL RESPONSE chain, not in this response.
+    var s68 = bind.sendApdu("80", "C2", "00", "00", null, null, null);
+    // S68-C1: binding:scp80_envelope_response_status_disjunctive(91XX|9000|error;E_tc_527-NOTE) (check_attestation)
+
+    // 步骤 69:Seq#08 2: FETCH "XX"(tc_step;REQ: RQ54_011, RQ54_014)
+    // FETCH header literals follow the golden wire evidence 8012 (same
+    // anchor as runToSteadyState; J Annex D.4 has no FETCH row, D 2.2.2
+    // gives mechanism only). Le = pending length from the last 91XX
+    // (chain rule, binding-internal state).
+    var s69 = bind.fetchPending("80", "12", "00", "00", null);
+    // S69-C1: binding:fetch_sms_por_runtime_parse(MTD_CHECK_SMS_POR;H-annexC1) (check_attestation)
+    // S69-C2: binding:fetch_length_chaining_last_91xx_sw2(TS102223-6.3-NOTE1) (check_attestation)
+
+    // 步骤 70:Seq#08 3: TERMINAL RESPONSE(tc_step)
+    // TERMINAL RESPONSE data is dynamically built by the binding from the
+    // last FETCHed proactive command (D 2.2.2; buildTrData) - never static.
+    // Header literals follow the golden wire evidence 8014.
+    var s70 = bind.terminalResponseForPending("80", "14", "00", "00", "9000");
+    bind.checkData("S70-C1 SW", "9000", s70.sw);
+
+    // 步骤 71:Seq#08 4/1: [MANAGE_CHANNEL_OPEN](PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR 展开1/2,K_annexC2_procs 表1258)(procedure_expansion)
+    // CHANNEL_NUMBER extraction and dynamic CLA rebinding are CasBind internal state (chaining rule; no generated-code re-implementation).
+    var s71 = bind.manageChannelOpen("9000");
+    bind.checkData("S71-C1 SW", "9000", s71.sw);
+
+    // 步骤 72:Seq#08 4/2: MTD_SELECT(procedure_expansion)
+    // CLA = bound channel (cla_rule) and <L> length binding are CasBind internal state (chaining rule; no generated-code re-implementation).
+    var s72 = bind.sendApdu(null, "A4", "04", "00", "A0000005591010FFFFFFFF8900000100", "00", "9000");
+    // MTD_SELECT expected face is SW-only (K Annex C.2 open-channel procedure step 2: no FCI content assertion in corpus); no fabricated template parse.
+    bind.checkData("S72-C1 SW", "9000", s72.sw);
+
+    // 步骤 73:Seq#08 5: MTD_STORE_DATA(tc_step;REQ: RQ54_014, RQ57_120, RQ57_122, RQ57_123, RQ57_126)
+    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
+    var sdCla73 = s71.chan !== null ? (s71.chan <= 3 ? 128 + s71.chan : 188 + s71.chan).toString(16).toUpperCase() : null;
+    var s73 = bind.sendApdu(sdCla73, "E2", "91", "00", "BF2D15A00C5A0A989209012143658709F55C059192939499", "00", "9000");
+    bind.checkData("S73-C1 SW", "9000", s73.sw);
+    var r2p73 = BindEs10xProcProfile.walkChoiceList(s73.resp, {respTag: "BF2D", okTag: "A0", errTag: "81"});
+    bind.checkData("S73-C2 profileInfoListOk present", "1", (r2p73.branch_tag === "A0" && r2p73.elements.length >= 1) ? "1" : "0");
+    // S73-C3: kind 'requirement' pattern 'metadata unchanged (SP_NAME1/NAME_OP_PROF1/png/ICON_OP_PROF1/{ppr1,ppr2})' has no static generation face (corpus vacuum; see CaseIR unresolved).
+    // S73-C3: binding:bf2d_query_structure_satisfies_requirement(S22-prof_info) (check_attestation)
+
+    // 步骤 74:Seq#09 IC1/1: RESET(PROC_EUICC_INITIALIZATION_SEQUENCE 展开1/4,K_annexC2_procs 表1256)(procedure_expansion)
+    var s74 = bind.resetAndAtr();
+    bind.checkData("S74-C1 ATR_present", "1", s74.atr_hex !== "" ? "1" : "0");
+
+    // 步骤 75:Seq#09 IC1/2: [SELECT_MF](展开2/4)(procedure_expansion)
+    // FCP outer tag not materialized from clause: tag-face asserted only when corpus fixes the tag byte (e.g. TS 102 221 FCP '62').
+    var s75 = bind.sendApdu("00", "A4", "00", "04", "3F00", "00", "9000");
+    bind.checkData("S75-C2 FCP_Template", "1", s75.resp.length > 0 ? "1" : "0");
+    bind.checkData("S75-C1 SW", "9000", s75.sw);
+
+    // 步骤 76:Seq#09 IC1/3: [TERMINAL_CAPABILITY_LPAd](展开3/4)(procedure_expansion)
+    var s76 = bind.sendApdu("80", "AA", "00", "00", "A9058100830107", null, "9000");
+    bind.checkData("S76-C1 SW", "9000", s76.sw);
+
+    // 步骤 77:Seq#09 IC1/4: [TERMINAL_PROFILE](展开4/4)(procedure_expansion)
+    var steady77 = bind.runToSteadyState(function () {
+        return bind.sendTerminalProfile("FFFFFFFF7F9D00DFBF00001FE2000000C7EB0000000168005000000000000200", "9000");
+    });
+    bind.checkData("S77-C1 final SW", "9000", steady77.final.sw);
+
+    // 步骤 78:Seq#09 1: MTD_SEND_SMS_PP(tc_step;REQ: RQ24_021, RQ54_001, RQ54_002, RQ54_003, RQ54_004, RQ54_005, RQ54_006, RQ54_010, RQ54_011)
+    // MTD_SEND_SMS_PP ENVELOPE (H Annex C.1 表1238 Details: 80 C2 00 00 <L>): SCP80-packed SMS-PP body is runtime-domain
+    // (<MNO_SCP80_COUNTER>/<CC>/<C_APDUS_SCRIPT>) — no bytes fabricated; the embedded STORE DATA
+    // script executes via the proactive FETCH / TERMINAL RESPONSE chain, not in this response.
+    var s78 = bind.sendApdu("80", "C2", "00", "00", null, null, null);
+    bind.checkData("S78-C1 SW1 91", "91", s78.sw.substring(0, 2));
+
+    // 步骤 79:Seq#09 2: FETCH "XX"(tc_step;REQ: RQ54_011, RQ54_014, RQ54_015)
+    // FETCH header literals follow the golden wire evidence 8012 (same
+    // anchor as runToSteadyState; J Annex D.4 has no FETCH row, D 2.2.2
+    // gives mechanism only). Le = pending length from the last 91XX
+    // (chain rule, binding-internal state).
+    var s79 = bind.fetchPending("80", "12", "00", "00", null);
+    // S79-C1: binding:fetch_sms_por_runtime_parse(MTD_CHECK_SMS_POR;H-annexC1) (check_attestation)
+    // S79-C2: binding:fetch_length_chaining_last_91xx_sw2(TS102223-6.3-NOTE1) (check_attestation)
+
+    // 步骤 80:Seq#09 3: TERMINAL RESPONSE(tc_step)
+    // TERMINAL RESPONSE data is dynamically built by the binding from the
+    // last FETCHed proactive command (D 2.2.2; buildTrData) - never static.
+    // Header literals follow the golden wire evidence 8014.
+    var s80 = bind.terminalResponseForPending("80", "14", "00", "00", "9000");
+    bind.checkData("S80-C1 SW", "9000", s80.sw);
+
+    // 步骤 81:Seq#09 4/1: [MANAGE_CHANNEL_OPEN](PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR 展开1/2,K_annexC2_procs 表1258)(procedure_expansion)
+    // CHANNEL_NUMBER extraction and dynamic CLA rebinding are CasBind internal state (chaining rule; no generated-code re-implementation).
+    var s81 = bind.manageChannelOpen("9000");
+    bind.checkData("S81-C1 SW", "9000", s81.sw);
+
+    // 步骤 82:Seq#09 4/2: MTD_SELECT(procedure_expansion)
+    // CLA = bound channel (cla_rule) and <L> length binding are CasBind internal state (chaining rule; no generated-code re-implementation).
+    var s82 = bind.sendApdu(null, "A4", "04", "00", "A0000005591010FFFFFFFF8900000100", "00", "9000");
+    // MTD_SELECT expected face is SW-only (K Annex C.2 open-channel procedure step 2: no FCI content assertion in corpus); no fabricated template parse.
+    bind.checkData("S82-C1 SW", "9000", s82.sw);
+
+    // 步骤 83:Seq#09 5: MTD_STORE_DATA(tc_step;REQ: RQ57_120, RQ57_122, RQ57_123, RQ57_126, RQ54_014)
+    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
+    var sdCla83 = s81.chan !== null ? (s81.chan <= 3 ? 128 + s81.chan : 188 + s81.chan).toString(16).toUpperCase() : null;
+    var s83 = bind.sendApdu(sdCla83, "E2", "91", "00", "BF2D15A00C5A0A989209012143658709F55C059192939499", "00", "9000");
+    bind.checkData("S83-C1 SW", "9000", s83.sw);
+    var r2p83 = BindEs10xProcProfile.walkChoiceList(s83.resp, {respTag: "BF2D", okTag: "A0", errTag: "81"});
+    bind.checkData("S83-C2 profileInfoListOk present", "1", (r2p83.branch_tag === "A0" && r2p83.elements.length >= 1) ? "1" : "0");
+    // S83-C3: kind 'requirement' pattern 'metadata unchanged (SP_NAME1/NAME_OP_PROF1/png/ICON_OP_PROF1/{ppr1,ppr2})' has no static generation face (corpus vacuum; see CaseIR unresolved).
+    // S83-C3: binding:bf2d_query_structure_satisfies_requirement(S22-prof_info) (check_attestation)
+
+    // 步骤 84:Seq#10 IC1/1: RESET(PROC_EUICC_INITIALIZATION_SEQUENCE 展开1/4,K_annexC2_procs 表1256)(procedure_expansion)
+    var s84 = bind.resetAndAtr();
+    bind.checkData("S84-C1 ATR_present", "1", s84.atr_hex !== "" ? "1" : "0");
+
+    // 步骤 85:Seq#10 IC1/2: [SELECT_MF](展开2/4)(procedure_expansion)
+    // FCP outer tag not materialized from clause: tag-face asserted only when corpus fixes the tag byte (e.g. TS 102 221 FCP '62').
+    var s85 = bind.sendApdu("00", "A4", "00", "04", "3F00", "00", "9000");
+    bind.checkData("S85-C2 FCP_Template", "1", s85.resp.length > 0 ? "1" : "0");
+    bind.checkData("S85-C1 SW", "9000", s85.sw);
+
+    // 步骤 86:Seq#10 IC1/3: [TERMINAL_CAPABILITY_LPAd](展开3/4)(procedure_expansion)
+    var s86 = bind.sendApdu("80", "AA", "00", "00", "A9058100830107", null, "9000");
+    bind.checkData("S86-C1 SW", "9000", s86.sw);
+
+    // 步骤 87:Seq#10 IC1/4: [TERMINAL_PROFILE](展开4/4)(procedure_expansion)
+    var steady87 = bind.runToSteadyState(function () {
+        return bind.sendTerminalProfile("FFFFFFFF7F9D00DFBF00001FE2000000C7EB0000000168005000000000000200", "9000");
+    });
+    bind.checkData("S87-C1 final SW", "9000", steady87.final.sw);
+
+    // 步骤 88:Seq#10 1: MTD_SEND_SMS_PP(tc_step;REQ: RQ24_021, RQ54_001, RQ54_002, RQ54_003, RQ54_004, RQ54_005, RQ54_006, RQ54_010, RQ54_011)
+    // MTD_SEND_SMS_PP ENVELOPE (H Annex C.1 表1238 Details: 80 C2 00 00 <L>): SCP80-packed SMS-PP body is runtime-domain
+    // (<MNO_SCP80_COUNTER>/<CC>/<C_APDUS_SCRIPT>) — no bytes fabricated; the embedded STORE DATA
+    // script executes via the proactive FETCH / TERMINAL RESPONSE chain, not in this response.
+    var s88 = bind.sendApdu("80", "C2", "00", "00", null, null, null);
+    bind.checkData("S88-C1 SW1 91", "91", s88.sw.substring(0, 2));
+
+    // 步骤 89:Seq#10 2: FETCH "XX"(tc_step;REQ: RQ54_011, RQ54_014, RQ54_015)
+    // FETCH header literals follow the golden wire evidence 8012 (same
+    // anchor as runToSteadyState; J Annex D.4 has no FETCH row, D 2.2.2
+    // gives mechanism only). Le = pending length from the last 91XX
+    // (chain rule, binding-internal state).
+    var s89 = bind.fetchPending("80", "12", "00", "00", null);
+    // S89-C1: binding:fetch_sms_por_runtime_parse(MTD_CHECK_SMS_POR;H-annexC1) (check_attestation)
+    // S89-C2: binding:fetch_length_chaining_last_91xx_sw2(TS102223-6.3-NOTE1) (check_attestation)
+
+    // 步骤 90:Seq#10 3: TERMINAL RESPONSE(tc_step)
+    // TERMINAL RESPONSE data is dynamically built by the binding from the
+    // last FETCHed proactive command (D 2.2.2; buildTrData) - never static.
+    // Header literals follow the golden wire evidence 8014.
+    var s90 = bind.terminalResponseForPending("80", "14", "00", "00", "9000");
+    bind.checkData("S90-C1 SW", "9000", s90.sw);
+
+    // 步骤 91:Seq#10 4/1: [MANAGE_CHANNEL_OPEN](PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR 展开1/2,K_annexC2_procs 表1258)(procedure_expansion)
+    // CHANNEL_NUMBER extraction and dynamic CLA rebinding are CasBind internal state (chaining rule; no generated-code re-implementation).
+    var s91 = bind.manageChannelOpen("9000");
+    bind.checkData("S91-C1 SW", "9000", s91.sw);
+
+    // 步骤 92:Seq#10 4/2: MTD_SELECT(procedure_expansion)
+    // CLA = bound channel (cla_rule) and <L> length binding are CasBind internal state (chaining rule; no generated-code re-implementation).
+    var s92 = bind.sendApdu(null, "A4", "04", "00", "A0000005591010FFFFFFFF8900000100", "00", "9000");
+    // MTD_SELECT expected face is SW-only (K Annex C.2 open-channel procedure step 2: no FCI content assertion in corpus); no fabricated template parse.
+    bind.checkData("S92-C1 SW", "9000", s92.sw);
+
+    // 步骤 93:Seq#10 5: MTD_STORE_DATA(tc_step;REQ: RQ54_014, RQ57_120, RQ57_122, RQ57_123, RQ57_126)
+    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
+    var sdCla93 = s91.chan !== null ? (s91.chan <= 3 ? 128 + s91.chan : 188 + s91.chan).toString(16).toUpperCase() : null;
+    var s93 = bind.sendApdu(sdCla93, "E2", "91", "00", "BF2D15A00C5A0A989209012143658709F55C059192939499", "00", "9000");
+    bind.checkData("S93-C1 SW", "9000", s93.sw);
+    var r2p93 = BindEs10xProcProfile.walkChoiceList(s93.resp, {respTag: "BF2D", okTag: "A0", errTag: "81"});
+    bind.checkData("S93-C2 profileInfoListOk present", "1", (r2p93.branch_tag === "A0" && r2p93.elements.length >= 1) ? "1" : "0");
+    // S93-C3: kind 'requirement' pattern 'metadata unchanged (SP_NAME1/NAME_OP_PROF1/png/ICON_OP_PROF1/{ppr1,ppr2})' has no static generation face (corpus vacuum; see CaseIR unresolved).
+    // S93-C3: binding:bf2d_query_structure_satisfies_requirement(S22-prof_info) (check_attestation)
+
+    // 步骤 94:Seq#11 IC1/1: RESET(PROC_EUICC_INITIALIZATION_SEQUENCE 展开1/4,K_annexC2_procs 表1256)(procedure_expansion)
+    var s94 = bind.resetAndAtr();
+    bind.checkData("S94-C1 ATR_present", "1", s94.atr_hex !== "" ? "1" : "0");
+
+    // 步骤 95:Seq#11 IC1/2: [SELECT_MF](展开2/4)(procedure_expansion)
+    // FCP outer tag not materialized from clause: tag-face asserted only when corpus fixes the tag byte (e.g. TS 102 221 FCP '62').
+    var s95 = bind.sendApdu("00", "A4", "00", "04", "3F00", "00", "9000");
+    bind.checkData("S95-C2 FCP_Template", "1", s95.resp.length > 0 ? "1" : "0");
+    bind.checkData("S95-C1 SW", "9000", s95.sw);
+
+    // 步骤 96:Seq#11 IC1/3: [TERMINAL_CAPABILITY_LPAd](展开3/4)(procedure_expansion)
+    var s96 = bind.sendApdu("80", "AA", "00", "00", "A9058100830107", null, "9000");
+    bind.checkData("S96-C1 SW", "9000", s96.sw);
+
+    // 步骤 97:Seq#11 IC1/4: [TERMINAL_PROFILE](展开4/4)(procedure_expansion)
+    var steady97 = bind.runToSteadyState(function () {
+        return bind.sendTerminalProfile("FFFFFFFF7F9D00DFBF00001FE2000000C7EB0000000168005000000000000200", "9000");
+    });
+    bind.checkData("S97-C1 final SW", "9000", steady97.final.sw);
+
+    // 步骤 98:Seq#11 1: MTD_SEND_SMS_PP(tc_step;REQ: RQ24_021, RQ54_001, RQ54_002, RQ54_003, RQ54_004, RQ54_005, RQ54_006, RQ54_010, RQ54_011)
+    // MTD_SEND_SMS_PP ENVELOPE (H Annex C.1 表1238 Details: 80 C2 00 00 <L>): SCP80-packed SMS-PP body is runtime-domain
+    // (<MNO_SCP80_COUNTER>/<CC>/<C_APDUS_SCRIPT>) — no bytes fabricated; the embedded STORE DATA
+    // script executes via the proactive FETCH / TERMINAL RESPONSE chain, not in this response.
+    var s98 = bind.sendApdu("80", "C2", "00", "00", null, null, null);
+    bind.checkData("S98-C1 SW1 91", "91", s98.sw.substring(0, 2));
+
+    // 步骤 99:Seq#11 2: FETCH "XX"(tc_step;REQ: RQ54_011, RQ54_014, RQ54_015)
+    // FETCH header literals follow the golden wire evidence 8012 (same
+    // anchor as runToSteadyState; J Annex D.4 has no FETCH row, D 2.2.2
+    // gives mechanism only). Le = pending length from the last 91XX
+    // (chain rule, binding-internal state).
+    var s99 = bind.fetchPending("80", "12", "00", "00", null);
+    // S99-C1: binding:fetch_sms_por_runtime_parse(MTD_CHECK_SMS_POR;H-annexC1) (check_attestation)
+    // S99-C2: binding:fetch_length_chaining_last_91xx_sw2(TS102223-6.3-NOTE1) (check_attestation)
+
+    // 步骤 100:Seq#11 3: TERMINAL RESPONSE(tc_step)
+    // TERMINAL RESPONSE data is dynamically built by the binding from the
+    // last FETCHed proactive command (D 2.2.2; buildTrData) - never static.
+    // Header literals follow the golden wire evidence 8014.
+    var s100 = bind.terminalResponseForPending("80", "14", "00", "00", "9000");
+    bind.checkData("S100-C1 SW", "9000", s100.sw);
+
+    // 步骤 101:Seq#11 4/1: [MANAGE_CHANNEL_OPEN](PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR 展开1/2,K_annexC2_procs 表1258)(procedure_expansion)
+    // CHANNEL_NUMBER extraction and dynamic CLA rebinding are CasBind internal state (chaining rule; no generated-code re-implementation).
+    var s101 = bind.manageChannelOpen("9000");
+    bind.checkData("S101-C1 SW", "9000", s101.sw);
+
+    // 步骤 102:Seq#11 4/2: MTD_SELECT(procedure_expansion)
+    // CLA = bound channel (cla_rule) and <L> length binding are CasBind internal state (chaining rule; no generated-code re-implementation).
+    var s102 = bind.sendApdu(null, "A4", "04", "00", "A0000005591010FFFFFFFF8900000100", "00", "9000");
+    // MTD_SELECT expected face is SW-only (K Annex C.2 open-channel procedure step 2: no FCI content assertion in corpus); no fabricated template parse.
+    bind.checkData("S102-C1 SW", "9000", s102.sw);
+
+    // 步骤 103:Seq#11 5: MTD_STORE_DATA(tc_step;REQ: RQ54_014, RQ57_120, RQ57_122, RQ57_123, RQ57_126)
+    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
+    var sdCla103 = s101.chan !== null ? (s101.chan <= 3 ? 128 + s101.chan : 188 + s101.chan).toString(16).toUpperCase() : null;
+    var s103 = bind.sendApdu(sdCla103, "E2", "91", "00", "BF2D15A00C5A0A989209012143658709F55C059192939499", "00", "9000");
+    bind.checkData("S103-C1 SW", "9000", s103.sw);
+    var r2p103 = BindEs10xProcProfile.walkChoiceList(s103.resp, {respTag: "BF2D", okTag: "A0", errTag: "81"});
+    bind.checkData("S103-C2 profileInfoListOk present", "1", (r2p103.branch_tag === "A0" && r2p103.elements.length >= 1) ? "1" : "0");
+    // S103-C3: kind 'requirement' pattern 'metadata unchanged (SP_NAME1/NAME_OP_PROF1/png/ICON_OP_PROF1/{ppr1,ppr2})' has no static generation face (corpus vacuum; see CaseIR unresolved).
+    // S103-C3: binding:bf2d_query_structure_satisfies_requirement(S22-prof_info) (check_attestation)
 }