eSIM RSP 测试用例对比站

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

源码对照:4.2.22.2.3

ES10c 停用 Profile(Case 4) / TC_eUICC_ES10c.DisableProfile_Case4

左侧为人工切片入口(-man,来自 原料/切片 的最小可执行脚本),右侧为 Cas 盲生成入口(-cas,仅依据规范生成)。文件按原始编码(多为 GBK)解码为 UTF-8 显示,行号自 1 起;字节级原文与 sha256 见两侧脚本包。完整 unified diff 见本页底部折叠区,以及 报告原文 §4。
-man 入口
Import/TestCase_SGP_23.js
860 行 / 34715 字符 / gb18030
-cas 入口
TC_eUICC_ES10c_DisableProfile_Case4/Import/TC_eUICC_ES10c_DisableProfile_Case4.js
725 行 / 58923 字符 / gb18030
默认折行显示长行;取消勾选可横向滚动查看原始行宽
-man 人工切片Import/TestCase_SGP_23.js860 行 / 34715 字符 / gb18030入口函数 @L3
1// slice of Import\TestCase_SGP_23.js - cases: TC_eUICC_ES10c_DisableProfile_Case4_01_Nominal_Disable_Profile_by_ISD_P_AID_and_refreshFlag_set_when_Device_supports_UICC_Reset + TC_eUICC_ES10c_DisableProfile_Case4_02_Nominal_Disable_Profile_by_ICCID_and_refreshFlag_set_when_Device_supports_UICC_Reset + TC_eUICC_ES10c_DisableProfile_Case4_03_Nominal_Disable_Profile_by_ISD_P_AID_and_refreshFlag_set_when_Device_supports_eUICC_Profile_State_Change + TC_eUICC_ES10c_DisableProfile_Case4_04_Nominal_Disable_Profile_by_ICCID_and_refreshFlag_set_when_Device_supports_eUICC_Profile_State_Change + TC_eUICC_ES10c_DisableProfile_Case4_05_Nominal_Disable_Profile_by_ISD_P_AID_and_refreshFlag_not_set + TC_eUICC_ES10c_DisableProfile_Case4_06_Nominal_Disable_Profile_by_ICCID_and_refreshFlag_not_set + TC_eUICC_ES10c_DisableProfile_Case4_07_Nominal_Disable_Profile_by_ICCID_with_refreshFLag_set_while_proactive_sessionisongoing_catBusynotsupported + TC_eUICC_ES10c_DisableProfile_Case4_08_Nominal_Disable_Profile_by_ICCID_with_refreshFLag_not_set_while_proactive_sessionisongoing_catBusynotsupported + TC_eUICC_ES10c_DisableProfile_Case4_09_Nominal_Disable_Profile_by_ICCID_with_refreshFLag_set_while_proactive_sessionisongoing_withTerminalResponseoutstanding_catBusynotsupported + TC_eUICC_ES10c_DisableProfile_Case4_10_Nominal_Disable_Profile_by_ICCID_with_refreshFLag_not_set_while_proactive_sessionisongoing_withTerminalResponseoutstanding_catBusynotsupported (extracted verbatim)
2
3function TC_eUICC_ES10c_DisableProfile_Case4_01_Nominal_Disable_Profile_by_ISD_P_AID_and_refreshFlag_set_when_Device_supports_UICC_Reset()
4{
5	initial_condition_PROFILE_OPERATIONAL1_is_Enabled();
6	var ISD_P_Test01 = curProfile_ISD_P_AID;
7	
8	tracenamestr = "测试目的:设备支持 “UICC Reset”,通过ISD-P AID去失效profile,并设置refreshFlag";
9	curDis.TraceStart(sno++,tracenamestr);
10	
11	curLogicChannel = 0;
12	curDis.TestStepStart2(stno++,"eUICC卡片初始化;");
13	Ini_powerOn_eUICC_LPAe_not_activate();
14	
15	curDis.TestStepStart2(stno++,"读卡器向卡片发送MANAGE_CHANNEL命令,打开辅助逻辑通道;");
16	TS_MANAGE_CHANNEL_OPEN();
17	
18	curLogicChannel = 1;
19	
20	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
21	TS_SELECT("Select ISD",ISD_R_AID,"9000");
22	
23	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行DisableProfileRequest,refreshFlag为FF;");
24	var disableProRequest = new DisableProfileRequest();
25	disableProRequest.profileIdentifier = new ChoiceObj(tagOfProfileIdentifier.isdpAid,ISD_P_Test01);
26	disableProRequest.refreshFlag = BooleanValue_BerCode_True;
27	disableProRequest.GenHexData();
28	var respData = LPAd_Transport_data_to_eUICC(disableProRequest.hexData,"91","00","91XX");
29	
30	curStrHandle.CheckData("BF3203800100", respData, "DisableProfileResponse");
31	
32	curLogicChannel = 0;
33	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Fetch命令,主动式命令refresh;");
34	
35	FetchStr = Fetch("","9000","");
36		
37	var CmdDetails = GetValueByTag("01",1);
38	var CmdQualifier = CmdDetails.substr(4,2);
39	CheckData("04",CmdQualifier,"the command qualifier is equal to ’04’ (UICC Reset)");
40	
41	curLogicChannel = 0;
42	curDis.TestStepStart2(stno++,"eUICC卡片初始化;");
43	Ini_powerOn_eUICC_LPAe_not_activate();
44	
45	curDis.TestStepStart2(stno++,"读卡器向卡片发送MANAGE_CHANNEL命令,打开辅助逻辑通道;");
46	TS_MANAGE_CHANNEL_OPEN();
47	curLogicChannel = 1;
48	
49	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
50	TS_SELECT("Select ISD",ISD_R_AID,"9000");
51	
52	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行ProfileInfoListRequest,获取profile状态;");
53	var proInfoListRequest = new ProfileInfoListRequest();
54	proInfoListRequest.searchCriteria = new ChoiceObj(tagOfsearchCriteria_ProfileInfo.isdpAid,ISD_P_Test01);
55	proInfoListRequest.tagList = "5A4F9F70";
56	proInfoListRequest.GenHexData();
57	var respData = LPAd_Transport_data_to_eUICC(proInfoListRequest.hexData);
58
59	var proInfoListResponse = new  ProfileInfoListResponse();
60	proInfoListResponse.checkCardResDataFormat(respData);
61	
62	try
63	{
64		curStrHandle.CheckData(ICCID_OP_PROF1, proInfoListResponse.profileInfoListOk.arrOfElement[0].iccid, "ICCID");
65		curStrHandle.CheckData(ISD_P_Test01, proInfoListResponse.profileInfoListOk.arrOfElement[0].isdpAid, "ISD-P AID");
66		curStrHandle.CheckData(Profile_DISABLED, proInfoListResponse.profileInfoListOk.arrOfElement[0].profileState, "profile State");
67	}catch(e){
68		obj.SubLevel(ProfileInfoListResponse_Data_Error, level_of_SubLevel.error);
69	}
70	
71	curLogicChannel = 0;
72	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Select命令,选择ICCID;");
73	var para1 = new SelectFileEFPara_3G("2FE2");
74	para1.apdu.ressw = "6A82";
75	SendAPDU(para1.apdu);
76	
77	RecoverCard();
78}
79
80function TC_eUICC_ES10c_DisableProfile_Case4_02_Nominal_Disable_Profile_by_ICCID_and_refreshFlag_set_when_Device_supports_UICC_Reset()
81{
82	initial_condition_PROFILE_OPERATIONAL1_is_Enabled();
83	var ISD_P_Test01 = curProfile_ISD_P_AID;
84	
85	tracenamestr = "测试目的:设备支持 “UICC Reset”,通过ICCID去失效profile,并设置refreshFlag";
86	curDis.TraceStart(sno++,tracenamestr);
87	
88	curLogicChannel = 0;
89	curDis.TestStepStart2(stno++,"eUICC卡片初始化;");
90	Ini_powerOn_eUICC_LPAe_not_activate();
91	
92	curDis.TestStepStart2(stno++,"读卡器向卡片发送MANAGE_CHANNEL命令,打开辅助逻辑通道;");
93	TS_MANAGE_CHANNEL_OPEN();
94	
95	curLogicChannel = 1;
96	
97	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
98	TS_SELECT("Select ISD",ISD_R_AID,"9000");
99	
100	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行DisableProfileRequest,refreshFlag为FF;");
101	var disableProRequest = new DisableProfileRequest();
102	disableProRequest.profileIdentifier = new ChoiceObj(tagOfProfileIdentifier.iccid,ICCID_OP_PROF1);
103	disableProRequest.refreshFlag = BooleanValue_BerCode_True;
104	disableProRequest.GenHexData();
105	var respData = LPAd_Transport_data_to_eUICC(disableProRequest.hexData,"91","00","91XX");
106	
107	curStrHandle.CheckData("BF3203800100", respData, "DisableProfileResponse");
108	
109	curLogicChannel = 0;
110	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Fetch命令,主动式命令refresh;");
111	
112	FetchStr = Fetch("","9000","");
113		
114	var CmdDetails = GetValueByTag("01",1);
115	var CmdQualifier = CmdDetails.substr(4,2);
116	CheckData("04",CmdQualifier,"the command qualifier is equal to ’04’ (UICC Reset)");
117	
118	curLogicChannel = 0;
119	curDis.TestStepStart2(stno++,"eUICC卡片初始化;");
120	Ini_powerOn_eUICC_LPAe_not_activate();
121	
122	curDis.TestStepStart2(stno++,"读卡器向卡片发送MANAGE_CHANNEL命令,打开辅助逻辑通道;");
123	TS_MANAGE_CHANNEL_OPEN();
124	curLogicChannel = 1;
125	
126	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
127	TS_SELECT("Select ISD",ISD_R_AID,"9000");
128	
129	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行ProfileInfoListRequest,获取profile状态;");
130	var proInfoListRequest = new ProfileInfoListRequest();
131	proInfoListRequest.searchCriteria = new ChoiceObj(tagOfsearchCriteria_ProfileInfo.iccid,ICCID_OP_PROF1);
132	proInfoListRequest.tagList = "5A4F9F70";
133	proInfoListRequest.GenHexData();
134	var respData = LPAd_Transport_data_to_eUICC(proInfoListRequest.hexData);
135
136	var proInfoListResponse = new  ProfileInfoListResponse();
137	proInfoListResponse.checkCardResDataFormat(respData);
138	
139	try
140	{
141		curStrHandle.CheckData(ICCID_OP_PROF1, proInfoListResponse.profileInfoListOk.arrOfElement[0].iccid, "ICCID");
142		curStrHandle.CheckData(ISD_P_Test01, proInfoListResponse.profileInfoListOk.arrOfElement[0].isdpAid, "ISD-P AID");
143		curStrHandle.CheckData(Profile_DISABLED, proInfoListResponse.profileInfoListOk.arrOfElement[0].profileState, "profile State");
144	}catch(e){
145		obj.SubLevel(ProfileInfoListResponse_Data_Error, level_of_SubLevel.error);
146	}
147	
148	curLogicChannel = 0;
149	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Select命令,选择ICCID;");
150	var para1 = new SelectFileEFPara_3G("2FE2");
151	para1.apdu.ressw = "6A82";
152	SendAPDU(para1.apdu);
153	
154	RecoverCard();
155}
156
157function TC_eUICC_ES10c_DisableProfile_Case4_03_Nominal_Disable_Profile_by_ISD_P_AID_and_refreshFlag_set_when_Device_supports_eUICC_Profile_State_Change()
158{
159	initial_condition_PROFILE_OPERATIONAL1_is_Enabled();
160	var ISD_P_Test01 = curProfile_ISD_P_AID;
161	
162	tracenamestr = "测试目的:设备支持 “eUICC Profile State Change”,通过ISD-P AID去失效profile,并设置refreshFlag";
163	curDis.TraceStart(sno++,tracenamestr);
164	
165	curLogicChannel = 0;
166	curDis.TestStepStart2(stno++,"eUICC卡片初始化;");
167	TERMINAL_PROFILE_Default = TERMINAL_PROFILE_eUICCProfileStateChanged;
168	Ini_powerOn_eUICC_LPAe_not_activate();
169	
170	curDis.TestStepStart2(stno++,"读卡器向卡片发送MANAGE_CHANNEL命令,打开辅助逻辑通道;");
171	TS_MANAGE_CHANNEL_OPEN();
172	
173	curLogicChannel = 1;
174	
175	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
176	TS_SELECT("Select ISD",ISD_R_AID,"9000");
177	
178	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行DisableProfileRequest,设备支持eUICC Profile State Change,通过ISD-P AID失效profile时配置了refreshFlag的测试;");
179	var disableProRequest = new DisableProfileRequest();
180	disableProRequest.profileIdentifier = new ChoiceObj(tagOfProfileIdentifier.isdpAid,ISD_P_Test01);
181	disableProRequest.refreshFlag = BooleanValue_BerCode_True;
182	disableProRequest.GenHexData();
183	var respData = LPAd_Transport_data_to_eUICC(disableProRequest.hexData,"91","00","91XX");
184	
185	curStrHandle.CheckData("BF3203800100", respData, "DisableProfileResponse");
186	
187	curLogicChannel = 0;
188	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Fetch命令,主动式命令refresh;");
189	
190	FetchStr = Fetch("","9000","");
191		
192	var CmdDetails = GetValueByTag("01",1);
193	var CmdQualifier = CmdDetails.substr(4,2);
194	CheckData("09",CmdQualifier,"the command qualifier is equal to ’09’ (eUICC Profile State Change)");
195	
196	curDis.TestStepStart2(stno++,"读卡器向卡片发送TerminalResponse命令;");
197	TerminalResponse("00","9000");
198	
199	curLogicChannel = 0;
200	curDis.TestStepStart2(stno++,"eUICC卡片初始化;");
201	if (check_eUICC_support_TERMINAL_CAPABILITY_cmd())
202		TS_TERMINAL_CAPABILITY_cmd();
203	else
204		obj.SubLevel("eUICC不支持”TERMINAL_CAPABILITY“命令", level_of_SubLevel.warning);
205	
206	IniCard_SetUpMenu("",1);
207	
208	curDis.TestStepStart2(stno++,"读卡器向卡片发送MANAGE_CHANNEL命令,打开辅助逻辑通道;");
209	var Logicnum = TS_MANAGE_CHANNEL_OPEN();
210	
211	curLogicChannel = parseInt(Logicnum,16);
212	
213	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
214	TS_SELECT("Select ISD",ISD_R_AID,"9000");
215	
216	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行ProfileInfoListRequest,获取profile状态;");
217	var proInfoListRequest = new ProfileInfoListRequest();
218	proInfoListRequest.searchCriteria = new ChoiceObj(tagOfsearchCriteria_ProfileInfo.isdpAid,ISD_P_Test01);
219	proInfoListRequest.tagList = "5A4F9F70";
220	proInfoListRequest.GenHexData();
221	var respData = LPAd_Transport_data_to_eUICC(proInfoListRequest.hexData);
222	
223	var proInfoListResponse = new  ProfileInfoListResponse();
224	proInfoListResponse.checkCardResDataFormat(respData);
225	
226	try
227	{
228		curStrHandle.CheckData(ICCID_OP_PROF1, proInfoListResponse.profileInfoListOk.arrOfElement[0].iccid, "ICCID");
229		curStrHandle.CheckData(ISD_P_Test01, proInfoListResponse.profileInfoListOk.arrOfElement[0].isdpAid, "ISD-P AID");
230		curStrHandle.CheckData(Profile_DISABLED, proInfoListResponse.profileInfoListOk.arrOfElement[0].profileState, "profile State");
231	}catch(e){
232		obj.SubLevel(ProfileInfoListResponse_Data_Error, level_of_SubLevel.error);
233	}
234	
235	curLogicChannel = 0;
236	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Select命令,选择ICCID;");
237	var para1 = new SelectFileEFPara_3G("2FE2");
238	para1.apdu.ressw = "6A82";
239	SendAPDU(para1.apdu);
240	
241	RecoverCard();
242	
243	
244}
245
246function TC_eUICC_ES10c_DisableProfile_Case4_04_Nominal_Disable_Profile_by_ICCID_and_refreshFlag_set_when_Device_supports_eUICC_Profile_State_Change()
247{
248	initial_condition_PROFILE_OPERATIONAL1_is_Enabled();
249	var ISD_P_Test01 = curProfile_ISD_P_AID;
250	
251	tracenamestr = "测试目的:设备支持 “eUICC Profile State Change”,通过ICCID去失效profile,并设置refreshFlag";
252	curDis.TraceStart(sno++,tracenamestr);
253	
254	curLogicChannel = 0;
255	curDis.TestStepStart2(stno++,"eUICC卡片初始化;");
256	TERMINAL_PROFILE_Default = TERMINAL_PROFILE_eUICCProfileStateChanged;
257	Ini_powerOn_eUICC_LPAe_not_activate();
258	
259	curDis.TestStepStart2(stno++,"读卡器向卡片发送MANAGE_CHANNEL命令,打开辅助逻辑通道;");
260	TS_MANAGE_CHANNEL_OPEN();
261	
262	curLogicChannel = 1;
263	
264	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
265	TS_SELECT("Select ISD",ISD_R_AID,"9000");
266	
267	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行DisableProfileRequest,设备支持eUICC Profile State Change,通过ICCID失效profile时配置了refreshFlag的测试;");
268	var disableProRequest = new DisableProfileRequest();
269	disableProRequest.profileIdentifier = new ChoiceObj(tagOfProfileIdentifier.iccid,ICCID_OP_PROF1);
270	disableProRequest.refreshFlag = BooleanValue_BerCode_True;
271	disableProRequest.GenHexData();
272	var respData = LPAd_Transport_data_to_eUICC(disableProRequest.hexData,"91","00","91XX");
273	
274	curStrHandle.CheckData("BF3203800100", respData, "DisableProfileResponse");
275	
276	curLogicChannel = 0;
277	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Fetch命令,主动式命令refresh;");
278	
279	FetchStr = Fetch("","9000","");
280		
281	var CmdDetails = GetValueByTag("01",1);
282	var CmdQualifier = CmdDetails.substr(4,2);
283	CheckData("09",CmdQualifier,"the command qualifier is equal to ’09’ (eUICC Profile State Change)");
284	
285	curDis.TestStepStart2(stno++,"读卡器向卡片发送TerminalResponse命令;");
286	TerminalResponse("00","9000");
287	
288	curLogicChannel = 0;
289	curDis.TestStepStart2(stno++,"eUICC卡片初始化;");
290	if (check_eUICC_support_TERMINAL_CAPABILITY_cmd())
291		TS_TERMINAL_CAPABILITY_cmd();
292	else
293		obj.SubLevel("eUICC不支持”TERMINAL_CAPABILITY“命令", level_of_SubLevel.warning);
294	
295	IniCard_SetUpMenu("",1);
296	
297	curDis.TestStepStart2(stno++,"读卡器向卡片发送MANAGE_CHANNEL命令,打开辅助逻辑通道;");
298	var Logicnum = TS_MANAGE_CHANNEL_OPEN();
299	
300	curLogicChannel = parseInt(Logicnum,16);
301	
302	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
303	TS_SELECT("Select ISD",ISD_R_AID,"9000");
304	
305	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行ProfileInfoListRequest,获取profile状态;");
306	var proInfoListRequest = new ProfileInfoListRequest();
307	proInfoListRequest.searchCriteria = new ChoiceObj(tagOfsearchCriteria_ProfileInfo.iccid,ICCID_OP_PROF1);
308	proInfoListRequest.tagList = "5A4F9F70";
309	proInfoListRequest.GenHexData();
310	var respData = LPAd_Transport_data_to_eUICC(proInfoListRequest.hexData);
311	
312	var proInfoListResponse = new  ProfileInfoListResponse();
313	proInfoListResponse.checkCardResDataFormat(respData);
314	
315	try
316	{
317		curStrHandle.CheckData(ICCID_OP_PROF1, proInfoListResponse.profileInfoListOk.arrOfElement[0].iccid, "ICCID");
318		curStrHandle.CheckData(ISD_P_Test01, proInfoListResponse.profileInfoListOk.arrOfElement[0].isdpAid, "ISD-P AID");
319		curStrHandle.CheckData(Profile_DISABLED, proInfoListResponse.profileInfoListOk.arrOfElement[0].profileState, "profile State");
320	}catch(e){
321		obj.SubLevel(ProfileInfoListResponse_Data_Error, level_of_SubLevel.error);
322	}
323	
324	curLogicChannel = 0;
325	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Select命令,选择ICCID;");
326	var para1 = new SelectFileEFPara_3G("2FE2");
327	para1.apdu.ressw = "6A82";
328	SendAPDU(para1.apdu);
329	
330	RecoverCard();
331	
332	
333}
334
335function TC_eUICC_ES10c_DisableProfile_Case4_05_Nominal_Disable_Profile_by_ISD_P_AID_and_refreshFlag_not_set()
336{
337	if(!Card_Have_ECC_Cert)
338		return;
339	
340	TestOfMEPMode = 0;	
341
342	initial_condition_PROFILE_OPERATIONAL1_is_Enabled();
343	var ISD_P_Test01 = curProfile_ISD_P_AID;
344	
345	tracenamestr = "测试目的:通过ISD-P AID去失效profile,不设置refreshFlag";
346	curDis.TraceStart(sno++,tracenamestr);
347	
348	curLogicChannel = 0;
349	curDis.TestStepStart2(stno++,"eUICC卡片初始化;");
350	Ini_powerOn_eUICC_LPAe_not_activate();
351	
352	curDis.TestStepStart2(stno++,"读卡器向卡片发送MANAGE_CHANNEL命令,打开辅助逻辑通道;");
353	TS_MANAGE_CHANNEL_OPEN();
354	
355	curLogicChannel = 1;
356	
357	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
358	TS_SELECT("Select ISD",ISD_R_AID,"9000");
359	
360
361	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行DisableProfileRequest,refreshFlag为False;"); 
362	var disableProRequest = new DisableProfileRequest();
363	disableProRequest.profileIdentifier = new ChoiceObj(tagOfProfileIdentifier.isdpAid,ISD_P_Test01);
364	disableProRequest.refreshFlag = BooleanValue_BerCode_False;
365	disableProRequest.GenHexData();
366	var respData = LPAd_Transport_data_to_eUICC(disableProRequest.hexData,"91","00","9000");
367	
368    curStrHandle.CheckData("BF3203800100", respData, "DisableProfileResponse");	
369	
370	curDis.TestStepStart2(stno++,"读卡器向卡片发送 TERMINAL_PROFILE命令;");
371	IniCard_SetUpMenu("",1);
372	
373
374	curDis.TestStepStart2(stno++,"读卡器向卡片发送MANAGE_CHANNEL命令,打开辅助逻辑通道;");
375	TS_MANAGE_CHANNEL_OPEN();
376	curLogicChannel = 1;
377	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
378	TS_SELECT("Select ISD",ISD_R_AID,"9000");
379	
380	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行ProfileInfoListRequest,获取profile状态;");
381	
382	var proInfoListRequest = new ProfileInfoListRequest();
383	proInfoListRequest.searchCriteria = new ChoiceObj(tagOfsearchCriteria_ProfileInfo.isdpAid,ISD_P_Test01);
384	proInfoListRequest.tagList = "5A4F9F70";
385	proInfoListRequest.GenHexData();
386	var respData = LPAd_Transport_data_to_eUICC(proInfoListRequest.hexData);
387	
388
389	var proInfoListResponse = new  ProfileInfoListResponse();
390	proInfoListResponse.checkCardResDataFormat(respData);
391	
392	try
393	{
394		curStrHandle.CheckData(ICCID_OP_PROF1, proInfoListResponse.profileInfoListOk.arrOfElement[0].iccid, "ICCID");
395		curStrHandle.CheckData(ISD_P_Test01, proInfoListResponse.profileInfoListOk.arrOfElement[0].isdpAid, "ISD-P AID");
396		curStrHandle.CheckData(Profile_DISABLED, proInfoListResponse.profileInfoListOk.arrOfElement[0].profileState, "profile State");
397	}catch(e){
398		obj.SubLevel(ProfileInfoListResponse_Data_Error, level_of_SubLevel.error);
399	}
400	
401	curLogicChannel = 0;
402	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Select命令,选择ICCID;");
403	var para1 = new SelectFileEFPara_3G("2FE2");
404	para1.apdu.ressw = "6A82";
405	SendAPDU(para1.apdu);
406	
407	RecoverCard();
408	
409}
410
411function TC_eUICC_ES10c_DisableProfile_Case4_06_Nominal_Disable_Profile_by_ICCID_and_refreshFlag_not_set()
412{
413	if(!Card_Have_ECC_Cert)
414		return;
415	
416	TestOfMEPMode = 0;	
417
418	initial_condition_PROFILE_OPERATIONAL1_is_Enabled();
419	var ISD_P_Test01 = curProfile_ISD_P_AID;
420	
421	tracenamestr = "测试目的:通过ICCID去失效profile,不设置refreshFlag";
422	curDis.TraceStart(sno++,tracenamestr);
423	
424	curLogicChannel = 0;
425	curDis.TestStepStart2(stno++,"eUICC卡片初始化;");
426	Ini_powerOn_eUICC_LPAe_not_activate();
427	
428	curDis.TestStepStart2(stno++,"读卡器向卡片发送MANAGE_CHANNEL命令,打开辅助逻辑通道;");
429	TS_MANAGE_CHANNEL_OPEN();
430	
431	curLogicChannel = 1;
432	
433	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
434	TS_SELECT("Select ISD",ISD_R_AID,"9000");
435	
436
437	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行DisableProfileRequest,refreshFlag为False;");
438
439	var disableProRequest = new DisableProfileRequest();
440	disableProRequest.profileIdentifier = new ChoiceObj(tagOfProfileIdentifier.iccid,ICCID_OP_PROF1);
441	disableProRequest.refreshFlag = BooleanValue_BerCode_False;
442	disableProRequest.GenHexData();
443	var respData = LPAd_Transport_data_to_eUICC(disableProRequest.hexData,"91","00","9000");
444	
445    curStrHandle.CheckData("BF3203800100", respData, "DisableProfileResponse");	
446	
447	curDis.TestStepStart2(stno++,"读卡器向卡片发送 TERMINAL_PROFILE命令;");
448	IniCard_SetUpMenu("",1);
449	
450
451	curDis.TestStepStart2(stno++,"读卡器向卡片发送MANAGE_CHANNEL命令,打开辅助逻辑通道;");
452	TS_MANAGE_CHANNEL_OPEN();
453	curLogicChannel = 1;
454	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
455	TS_SELECT("Select ISD",ISD_R_AID,"9000");
456	
457	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行ProfileInfoListRequest,获取profile状态;");
458
459	var proInfoListRequest = new ProfileInfoListRequest();
460	proInfoListRequest.searchCriteria = new ChoiceObj(tagOfsearchCriteria_ProfileInfo.iccid,ICCID_OP_PROF1);
461	proInfoListRequest.tagList = "5A4F9F70";
462	proInfoListRequest.GenHexData();
463	var respData = LPAd_Transport_data_to_eUICC(proInfoListRequest.hexData);
464	
465
466	var proInfoListResponse = new  ProfileInfoListResponse();
467	proInfoListResponse.checkCardResDataFormat(respData);
468	
469	try
470	{
471		curStrHandle.CheckData(ICCID_OP_PROF1, proInfoListResponse.profileInfoListOk.arrOfElement[0].iccid, "ICCID");
472		curStrHandle.CheckData(ISD_P_Test01, proInfoListResponse.profileInfoListOk.arrOfElement[0].isdpAid, "ISD-P AID");
473		curStrHandle.CheckData(Profile_DISABLED, proInfoListResponse.profileInfoListOk.arrOfElement[0].profileState, "profile State");
474	}catch(e){
475		obj.SubLevel(ProfileInfoListResponse_Data_Error, level_of_SubLevel.error);
476	}
477	
478	curLogicChannel = 0;
479	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Select命令,选择ICCID;");
480	var para1 = new SelectFileEFPara_3G("2FE2");
481	para1.apdu.ressw = "6A82";
482	SendAPDU(para1.apdu);
483	
484	RecoverCard();
485	
486}
487
488function TC_eUICC_ES10c_DisableProfile_Case4_07_Nominal_Disable_Profile_by_ICCID_with_refreshFLag_set_while_proactive_sessionisongoing_catBusynotsupported()
489{
490
491	//测试入口条件
492	if(!check_Applicability_of_tests_RSP_SGP23_test("C033"))
493		return;
494	
495	initial_condition_PROFILE_OPERATIONAL1_is_Enabled();
496	var ISD_P_Test01 = curProfile_ISD_P_AID;
497	
498
499	tracenamestr = "测试目的:eUICC不支持catBusy,主动式会话进行中时,通过ISD-P AID去失效profile,并设置refreshFlag";
500	curDis.TraceStart(sno++,tracenamestr);
501	
502	curLogicChannel = 0;
503	curDis.TestStepStart2(stno++,"eUICC卡片初始化;");
504	Ini_powerOn_eUICC_LPAe_not_activate();
505	
506	curDis.TestStepStart2(stno++,"读卡器向卡片发送MANAGE_CHANNEL命令,打开辅助逻辑通道;");
507	TS_MANAGE_CHANNEL_OPEN();
508	curLogicChannel = 1;
509	
510	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
511	TS_SELECT("Select ISD",ISD_R_AID,"9000");
512	
513	curLogicChannel = 0;
514	var sSendType = SendTypeByOTA.SMS;
515	KIC = MNO_SCP80_ENC_KEY;
516	KID = MNO_SCP80_AUTH_KEY;
517	KIK = MNO_SCP80_DATA_ENC_KEY;
518	curDis.TestStepStart2(stno++,"SCP80,发送get status命令,使用MNO-SD的tar");
519	sAPDU = "80F28002024F00";
520	SendMessageToCard_GP(sSendType,"91XX",0,"B20100","12210015",sAPDU);
521	HaveReEntry91XX = true;
522	var ss = obj.GetState();
523	ReEntry91XXLength = ss.substr(2,2);
524	
525	curLogicChannel = 1;
526	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行DisableProfileRequest,refreshFlag为FF;");
527	var disableProRequest = new DisableProfileRequest();
528	disableProRequest.profileIdentifier = new ChoiceObj(tagOfProfileIdentifier.iccid,ICCID_OP_PROF1);
529	disableProRequest.refreshFlag = BooleanValue_BerCode_True;
530	disableProRequest.GenHexData();
531	var respData = LPAd_Transport_data_to_eUICC(disableProRequest.hexData,"91","00","91XX");
532	curStrHandle.CheckData("BF3203800100", respData, "DisableProfileResponse");
533	
534	curLogicChannel = 0;
535	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Fetch命令,主动式命令refresh;");
536	FetchStr = Fetch("","9000","");
537		
538	var CmdDetails = GetValueByTag("01",1);
539	var CmdQualifier = CmdDetails.substr(4,2);
540	CheckData("04",CmdQualifier,"the command qualifier is equal to ’04’ (UICC Reset)");
541	
542	
543	curLogicChannel = 0;
544	curDis.TestStepStart2(stno++,"eUICC卡片初始化;");
545	Ini_powerOn_eUICC_LPAe_not_activate();
546	
547	curDis.TestStepStart2(stno++,"读卡器向卡片发送MANAGE_CHANNEL命令,打开辅助逻辑通道;");
548	TS_MANAGE_CHANNEL_OPEN();
549
550	curLogicChannel = 1;
551	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
552	TS_SELECT("Select ISD",ISD_R_AID,"9000");
553
554	
555	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行ProfileInfoListRequest,获取profile状态;");
556	var proInfoListRequest = new ProfileInfoListRequest();
557	proInfoListRequest.searchCriteria = new ChoiceObj(tagOfsearchCriteria_ProfileInfo.iccid,ICCID_OP_PROF1);
558	proInfoListRequest.tagList = "5A4F9F70";
559	proInfoListRequest.GenHexData();
560	var respData = LPAd_Transport_data_to_eUICC(proInfoListRequest.hexData);
561	
562	var proInfoListResponse = new  ProfileInfoListResponse();
563	proInfoListResponse.checkCardResDataFormat(respData);
564	
565	try
566	{
567		curStrHandle.CheckData(ICCID_OP_PROF1, proInfoListResponse.profileInfoListOk.arrOfElement[0].iccid, "ICCID");
568		curStrHandle.CheckData(ISD_P_Test01, proInfoListResponse.profileInfoListOk.arrOfElement[0].isdpAid, "ISD-P AID");
569		curStrHandle.CheckData(Profile_DISABLED, proInfoListResponse.profileInfoListOk.arrOfElement[0].profileState, "profile State");
570	}catch(e){
571		obj.SubLevel(ProfileInfoListResponse_Data_Error, level_of_SubLevel.error);
572	}
573
574    curLogicChannel = 0;
575	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Select命令,选择ICCID;");
576	var para1 = new SelectFileEFPara_3G("2FE2");
577	para1.apdu.ressw = "6A82";
578	SendAPDU(para1.apdu);
579	
580	RecoverCard();
581}
582
583function TC_eUICC_ES10c_DisableProfile_Case4_08_Nominal_Disable_Profile_by_ICCID_with_refreshFLag_not_set_while_proactive_sessionisongoing_catBusynotsupported()
584{
585
586	//测试入口条件
587	if(!check_Applicability_of_tests_RSP_SGP23_test("C033"))
588		return;
589	
590	initial_condition_PROFILE_OPERATIONAL1_is_Enabled();
591	var ISD_P_Test01 = curProfile_ISD_P_AID;
592	
593
594	tracenamestr = "测试目的:eUICC不支持catBusy,主动式会话进行中时,通过ISD-P AID去失效profile,不设置refreshFlag";
595	curDis.TraceStart(sno++,tracenamestr);
596	
597	curLogicChannel = 0;
598	curDis.TestStepStart2(stno++,"eUICC卡片初始化;");
599	Ini_powerOn_eUICC_LPAe_not_activate();
600	
601	curDis.TestStepStart2(stno++,"读卡器向卡片发送MANAGE_CHANNEL命令,打开辅助逻辑通道;");
602	TS_MANAGE_CHANNEL_OPEN();
603	curLogicChannel = 1;
604	
605	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
606	TS_SELECT("Select ISD",ISD_R_AID,"9000");
607	
608	curLogicChannel = 0;
609	var sSendType = SendTypeByOTA.SMS;
610	KIC = MNO_SCP80_ENC_KEY;
611	KID = MNO_SCP80_AUTH_KEY;
612	KIK = MNO_SCP80_DATA_ENC_KEY;
613	curDis.TestStepStart2(stno++,"SCP80,发送get status命令,使用MNO-SD的tar");
614	sAPDU = "80F28002024F00";
615	SendMessageToCard_GP(sSendType,"91XX",0,"B20100","12210015",sAPDU);
616	HaveReEntry91XX = true;
617	var ss = obj.GetState();
618	ReEntry91XXLength = ss.substr(2,2);
619	
620	curLogicChannel = 1;
621	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行DisableProfileRequest,refreshFlag为False;");
622	var disableProRequest = new DisableProfileRequest();
623	disableProRequest.profileIdentifier = new ChoiceObj(tagOfProfileIdentifier.iccid,ICCID_OP_PROF1);
624	disableProRequest.refreshFlag = BooleanValue_BerCode_False;
625	disableProRequest.GenHexData();
626	var respData = LPAd_Transport_data_to_eUICC(disableProRequest.hexData,"91","00","9000");
627	curStrHandle.CheckData("BF3203800100", respData, "DisableProfileResponse");
628	
629	
630	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行ProfileInfoListRequest,获取profile状态;");
631	var proInfoListRequest = new ProfileInfoListRequest();
632	proInfoListRequest.searchCriteria = new ChoiceObj(tagOfsearchCriteria_ProfileInfo.iccid,ICCID_OP_PROF1);
633	proInfoListRequest.tagList = "5A4F9F70";
634	proInfoListRequest.GenHexData();
635	var respData = LPAd_Transport_data_to_eUICC(proInfoListRequest.hexData);
636	
637	var proInfoListResponse = new  ProfileInfoListResponse();
638	proInfoListResponse.checkCardResDataFormat(respData);
639	
640	try
641	{
642		curStrHandle.CheckData(ICCID_OP_PROF1, proInfoListResponse.profileInfoListOk.arrOfElement[0].iccid, "ICCID");
643		curStrHandle.CheckData(ISD_P_Test01, proInfoListResponse.profileInfoListOk.arrOfElement[0].isdpAid, "ISD-P AID");
644		curStrHandle.CheckData(Profile_DISABLED, proInfoListResponse.profileInfoListOk.arrOfElement[0].profileState, "profile State");
645	}catch(e){
646		obj.SubLevel(ProfileInfoListResponse_Data_Error, level_of_SubLevel.error);
647	}
648
649    curLogicChannel = 0;
650	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Select命令,选择ICCID;");
651	var para1 = new SelectFileEFPara_3G("2FE2");
652	para1.apdu.ressw = "6A82";
653	SendAPDU(para1.apdu);
654	
655	RecoverCard();
656}
657
658function TC_eUICC_ES10c_DisableProfile_Case4_09_Nominal_Disable_Profile_by_ICCID_with_refreshFLag_set_while_proactive_sessionisongoing_withTerminalResponseoutstanding_catBusynotsupported()
659{
660	//测试入口条件
661	if(!check_Applicability_of_tests_RSP_SGP23_test("C033"))
662		return;
663		
664	initial_condition_PROFILE_OPERATIONAL1_is_Enabled();
665	var ISD_P_Test01 = curProfile_ISD_P_AID;
666	
667
668	tracenamestr = "测试目的:eUICC不支持catBusy,主动式会话进行中(未给终端响应)时,通过ISD-P AID去失效profile,设置refreshFlag";
669	curDis.TraceStart(sno++,tracenamestr);
670	
671	curLogicChannel = 0;
672	curDis.TestStepStart2(stno++,"eUICC卡片初始化;");
673	Ini_powerOn_eUICC_LPAe_not_activate();
674	
675	curDis.TestStepStart2(stno++,"读卡器向卡片发送MANAGE_CHANNEL命令,打开辅助逻辑通道;");
676	TS_MANAGE_CHANNEL_OPEN();
677	curLogicChannel = 1;
678	
679	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
680	TS_SELECT("Select ISD",ISD_R_AID,"9000");
681	
682	curLogicChannel = 0;
683	curDis.TestStepStart2(stno++,"SCP80,发送get status命令,使用MNO-SD的tar");
684
685	var sSendType = SendTypeByOTA.SMS;
686	KIC = MNO_SCP80_ENC_KEY;
687	KID = MNO_SCP80_AUTH_KEY;
688	KIK = MNO_SCP80_DATA_ENC_KEY;
689	sAPDU = "80F28002024F00";
690	SendMessageToCard_GP(sSendType,"91XX",0,"B20100","12210015",sAPDU);
691	HaveReEntry91XX = true;
692	var ss = obj.GetState();
693	ReEntry91XXLength = ss.substr(2,2);
694	
695	curDis.TestStepStart2(stno++,"SCP80,发送Fetch命令,检查por");
696	curLogicChannel = 0;
697	CardSendMessageToServer(sSendType,1,"0161XX","00");
698
699	
700	
701	curLogicChannel = 1;
702	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行DisableProfileRequest,refreshFlag为FF;");
703	var disableProRequest = new DisableProfileRequest();
704	disableProRequest.profileIdentifier = new ChoiceObj(tagOfProfileIdentifier.isdpAid,ISD_P_Test01);
705	disableProRequest.refreshFlag = BooleanValue_BerCode_True;
706	disableProRequest.GenHexData();
707	var respData = LPAd_Transport_data_to_eUICC(disableProRequest.hexData,"91","00","9000");
708	curStrHandle.CheckData("BF3203800100", respData, "DisableProfileResponse");
709	
710	curLogicChannel = 0;
711	curDis.TestStepStart2(stno++,"读卡器向卡片发送TerminalResponse命令;");
712	TerminalResponse("00","91XX");		
713	var ss = obj.GetState();
714	HaveReEntry91XX = false;
715	
716	
717	curDis.TestStepStart2(stno++,"Fetch;");
718	FetchStr = Fetch(ss.substr(2),"9000","");	
719	var CmdDetails = GetValueByTag("01",1);
720	var CmdQualifier = CmdDetails.substr(4,2);
721	curStrHandle.CheckData("04",CmdQualifier,"the command qualifier is equal to ’04’ (UICC Reset)");
722	
723
724	curLogicChannel = 0;
725	curDis.TestStepStart2(stno++,"eUICC卡片初始化;");
726	Ini_powerOn_eUICC_LPAe_not_activate();
727	
728	curDis.TestStepStart2(stno++,"读卡器向卡片发送MANAGE_CHANNEL命令,打开辅助逻辑通道;");
729	TS_MANAGE_CHANNEL_OPEN();
730	curLogicChannel = 1;
731	
732	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
733	TS_SELECT("Select ISD",ISD_R_AID,"9000");
734	
735	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行ProfileInfoListRequest,获取profile1状态;");
736	var proInfoListRequest = new ProfileInfoListRequest();
737	proInfoListRequest.searchCriteria = new ChoiceObj(tagOfsearchCriteria_ProfileInfo.isdpAid,ISD_P_Test01);
738	proInfoListRequest.tagList = "5A4F9F70";
739	proInfoListRequest.GenHexData();
740	var respData = LPAd_Transport_data_to_eUICC(proInfoListRequest.hexData);
741	
742	var proInfoListResponse = new  ProfileInfoListResponse();
743	proInfoListResponse.checkCardResDataFormat(respData);
744	
745	try
746	{
747		curStrHandle.CheckData(ICCID_OP_PROF1, proInfoListResponse.profileInfoListOk.arrOfElement[0].iccid, "ICCID");
748		curStrHandle.CheckData(ISD_P_Test01, proInfoListResponse.profileInfoListOk.arrOfElement[0].isdpAid, "ISD-P AID");
749		curStrHandle.CheckData(Profile_DISABLED, proInfoListResponse.profileInfoListOk.arrOfElement[0].profileState, "profile State");
750	}catch(e){
751		obj.SubLevel(ProfileInfoListResponse_Data_Error, level_of_SubLevel.error);
752	}
753
754
755 	
756	curLogicChannel = 0;
757	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Select命令,选择ICCID;");
758	var para1 = new SelectFileEFPara_3G("2FE2");
759	SendAPDU(para1.apdu);
760	
761	curDis.TestStepStart2(stno++,"读卡器向卡片发送read binary命令;");
762	var para1 = new ReadBinaryPara_3G("00","00","0A");
763	para1.apdu.ressw = "6A82";
764	SendAPDU(para1.apdu);
765	
766	RecoverCard();
767}
768
769function TC_eUICC_ES10c_DisableProfile_Case4_10_Nominal_Disable_Profile_by_ICCID_with_refreshFLag_not_set_while_proactive_sessionisongoing_withTerminalResponseoutstanding_catBusynotsupported()
770{
771	//测试入口条件
772	if(!check_Applicability_of_tests_RSP_SGP23_test("C033"))
773		return;
774		
775	initial_condition_PROFILE_OPERATIONAL1_is_Enabled();
776	var ISD_P_Test01 = curProfile_ISD_P_AID;
777	
778
779	tracenamestr = "测试目的:eUICC不支持catBusy,主动式会话进行中(未给终端响应)时,通过ISD-P AID去失效profile,不设置refreshFlag";
780	curDis.TraceStart(sno++,tracenamestr);
781	
782	curLogicChannel = 0;
783	curDis.TestStepStart2(stno++,"eUICC卡片初始化;");
784	Ini_powerOn_eUICC_LPAe_not_activate();
785	
786	curDis.TestStepStart2(stno++,"读卡器向卡片发送MANAGE_CHANNEL命令,打开辅助逻辑通道;");
787	TS_MANAGE_CHANNEL_OPEN();
788	curLogicChannel = 1;
789	
790	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
791	TS_SELECT("Select ISD",ISD_R_AID,"9000");
792	
793	curLogicChannel = 0;
794	curDis.TestStepStart2(stno++,"SCP80,发送get status命令,使用MNO-SD的tar");
795
796	var sSendType = SendTypeByOTA.SMS;
797	KIC = MNO_SCP80_ENC_KEY;
798	KID = MNO_SCP80_AUTH_KEY;
799	KIK = MNO_SCP80_DATA_ENC_KEY;
800	sAPDU = "80F28002024F00";
801	SendMessageToCard_GP(sSendType,"91XX",0,"B20100","12210015",sAPDU);
802	HaveReEntry91XX = true;
803	var ss = obj.GetState();
804	ReEntry91XXLength = ss.substr(2,2);
805	
806	curDis.TestStepStart2(stno++,"SCP80,发送Fetch命令,检查por");
807	curLogicChannel = 0;
808	CardSendMessageToServer(sSendType,1,"0161XX","00");
809
810	
811	
812	curLogicChannel = 1;
813	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行DisableProfileRequest,refreshFlag为Flase;");
814	var disableProRequest = new DisableProfileRequest();
815	disableProRequest.profileIdentifier = new ChoiceObj(tagOfProfileIdentifier.iccid,ICCID_OP_PROF1);
816	disableProRequest.refreshFlag = BooleanValue_BerCode_False;
817	disableProRequest.GenHexData();
818	var respData = LPAd_Transport_data_to_eUICC(disableProRequest.hexData,"91","00","9000");
819	curStrHandle.CheckData("BF3203800100", respData, "DisableProfileResponse");
820	
821	curLogicChannel = 0;
822	curDis.TestStepStart2(stno++,"读卡器向卡片发送TerminalResponse命令;");
823	TerminalResponse("00","91XX");		
824	var ss = obj.GetState();
825	HaveReEntry91XX = false;
826	
827	
828	curLogicChannel = 1;
829	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行ProfileInfoListRequest,获取profile1状态;");
830	var proInfoListRequest = new ProfileInfoListRequest();
831	proInfoListRequest.searchCriteria = new ChoiceObj(tagOfsearchCriteria_ProfileInfo.iccid,ICCID_OP_PROF1);
832	proInfoListRequest.tagList = "5A4F9F70";
833	proInfoListRequest.GenHexData();
834	var respData = LPAd_Transport_data_to_eUICC(proInfoListRequest.hexData);
835	
836	var proInfoListResponse = new  ProfileInfoListResponse();
837	proInfoListResponse.checkCardResDataFormat(respData);
838	
839	try
840	{
841		curStrHandle.CheckData(ICCID_OP_PROF1, proInfoListResponse.profileInfoListOk.arrOfElement[0].iccid, "ICCID");
842		curStrHandle.CheckData(ISD_P_Test01, proInfoListResponse.profileInfoListOk.arrOfElement[0].isdpAid, "ISD-P AID");
843		curStrHandle.CheckData(Profile_DISABLED, proInfoListResponse.profileInfoListOk.arrOfElement[0].profileState, "profile State");
844	}catch(e){
845		obj.SubLevel(ProfileInfoListResponse_Data_Error, level_of_SubLevel.error);
846	}
847 	
848	curLogicChannel = 0;
849	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Select命令,选择ICCID;");
850	var para1 = new SelectFileEFPara_3G("2FE2");
851	SendAPDU(para1.apdu);
852	
853	curDis.TestStepStart2(stno++,"读卡器向卡片发送read binary命令;");
854	var para1 = new ReadBinaryPara_3G("00","00","0A");
855	para1.apdu.ressw = "6A82";
856	SendAPDU(para1.apdu);
857	
858	RecoverCard();
859}
860
-cas 盲生成TC_eUICC_ES10c_DisableProfile_Case4/Import/TC_eUICC_ES10c_DisableProfile_Case4.js725 行 / 58923 字符 / gb18030入口函数 @L40
1// Author: 卡思Cas智能体
2// Date: 20261005-152741
3// Function: (purpose 原文未由 SGP.23 该 TC 提供,corpus vacuum 登记)TC_eUICC_ES10c.DisableProfile_Case4,Test Sequence #01-#10 Nominal (all 10 sequences),适用性 M。
4// Test points: ICH-SEQ01-IC1-K1-C1 ATR_present;ICH-SEQ01-IC1-K2-C2 FCP_Template
5//   ICH-SEQ01-IC1-K2-C4 SW;ICH-SEQ01-IC1-K3-C4 SW;ICH-SEQ01-IC1-K4-C4 final SW
6//   ICH-SEQ01-IC2-K1-C4 SW;ICH-SEQ01-IC2-K1-C3 CHANNEL_NUMBER extracted;ICH-SEQ01-IC2-K2-C4 SW
7//   S1-C1 SW1 91;S1-C2 disableResult ok;S2-C1 proactive command envelope;IC4-IC1-K1-C1 ATR_present
8//   IC4-IC1-K2-C2 FCP_Template;IC4-IC1-K2-C4 SW;IC4-IC1-K3-C4 SW;IC4-IC1-K4-C4 final SW
9//   IC4-IC2-K1-C4 SW;IC4-IC2-K1-C3 CHANNEL_NUMBER extracted;IC4-IC2-K2-C4 SW;S4-C1 SW
10//   S4-C2 contains PROFILE_INFO1_DISABLED;S5-C1 SW;S6-C1 SW1 91;S6-C2 disableResult ok
11//   S7-C1 proactive command envelope;IC9-IC1-K1-C1 ATR_present;IC9-IC1-K2-C2 FCP_Template
12//   IC9-IC1-K2-C4 SW;IC9-IC1-K3-C4 SW;IC9-IC1-K4-C4 final SW;IC9-IC2-K1-C4 SW
13//   IC9-IC2-K1-C3 CHANNEL_NUMBER extracted;IC9-IC2-K2-C4 SW;S9-C1 SW
14//   S9-C2 contains PROFILE_INFO1_DISABLED;S10-C1 SW;S11-C1 SW1 91;S11-C2 disableResult ok
15//   S12-C1 proactive command envelope;S13-C1 SW;IC15-IC1-K2-C2 FCP_Template;IC15-IC1-K2-C4 SW
16//   IC15-IC1-K3-C4 SW;IC15-IC1-K4-C4 final SW;IC16-IC2-K1-C4 SW
17//   IC16-IC2-K1-C3 CHANNEL_NUMBER extracted;IC16-IC2-K2-C4 SW;S16-C1 SW
18//   S16-C2 contains PROFILE_INFO1_DISABLED;S17-C1 SW;S18-C1 SW1 91;S18-C2 disableResult ok
19//   S19-C1 proactive command envelope;S20-C1 SW;IC22-IC1-K2-C2 FCP_Template;IC22-IC1-K2-C4 SW
20//   IC22-IC1-K3-C4 SW;IC22-IC1-K4-C4 final SW;IC23-IC2-K1-C4 SW
21//   IC23-IC2-K1-C3 CHANNEL_NUMBER extracted;IC23-IC2-K2-C4 SW;S23-C1 SW
22//   S23-C2 contains PROFILE_INFO1_DISABLED;S24-C1 SW;S25-C1 SW;S25-C2 disableResult ok;S26-C1 SW
23//   S26-C2 contains PROFILE_INFO1_DISABLED;S27-C1 SW;S28-C1 SW;S28-C2 disableResult ok;S29-C1 SW
24//   S29-C2 contains PROFILE_INFO1_DISABLED;S30-C1 SW;S31-C1 SW1 91;S32-C1 SW1 91
25//   S32-C2 DisableResult ok;S33-C1 proactive command envelope;IC35-IC1-K1-C1 ATR_present
26//   IC35-IC1-K2-C2 FCP_Template;IC35-IC1-K2-C4 SW;IC35-IC1-K3-C4 SW;IC35-IC1-K4-C4 final SW
27//   IC35-IC2-K1-C4 SW;IC35-IC2-K1-C3 CHANNEL_NUMBER extracted;IC35-IC2-K2-C4 SW;S35-C1 SW
28//   S35-C2 contains PROFILE_INFO1_DISABLED;S36-C1 SW;S37-C1 SW1 91;S38-C1 SW
29//   S38-C2 DisableResult ok;S39-C1 SW;S39-C2 contains PROFILE_INFO1_DISABLED;S40-C1 SW
30//   S41-C1 SW1 91;S42-C1 proactive command envelope;S43-C1 SW;S43-C2 DisableResult ok;S44-C1 SW1 91
31//   S45-C1 proactive command envelope;IC47-IC1-K1-C1 ATR_present;IC47-IC1-K2-C2 FCP_Template
32//   IC47-IC1-K2-C4 SW;IC47-IC1-K3-C4 SW;IC47-IC1-K4-C4 final SW;IC47-IC2-K1-C4 SW
33//   IC47-IC2-K1-C3 CHANNEL_NUMBER extracted;IC47-IC2-K2-C4 SW;S47-C1 SW
34//   S47-C2 contains PROFILE_INFO1_DISABLED;S48-C1 SW;S49-C1 SW1 91
35//   S50-C1 proactive command envelope;S51-C1 SW;S51-C2 DisableResult ok;S52-C1 SW1 != 91;S53-C1 SW
36//   S53-C2 contains PROFILE_INFO1_DISABLED;S54-C1 SW
37// 本函数由 CaseIR 4.2.22.2.3 编译生成(fullwave-blindgen-live-70-W1-laneA2,SGP.23 v1.16 × SGP.22 v2.7):字节权威=CaseIR,非誊录黄金脚本。
38// Value-free template: every data byte is injected from CaseIR fields; no scaffold globals (see docs/speconly/compile-symbol-migration.md).
39// 适用性 M:编译期门,运行时由 harness 环境前置承担。
40function TC_eUICC_ES10c_DisableProfile_Case4_01_10_Nominal_all_10_sequences() {
41    var bind = curBind;
42    var profileAidSession = BindEs10xProcProfileDynamic.beginSession(bind, "TC_eUICC_ES10c_DisableProfile_Case4_01_10_Nominal_all_10_sequences");
43    // runtime-bound payload: ISD_P_AID1 stays in execution domain; context_lineage: {"context_id": "9355a262c89e8a7e", "authority_reference": "E_tc_4222/441-441/G_annexB_dynamic:L51"}
44    var cardCtxLoad1 = BindCardContext.load(bind, profileAidSession, "ISD_P_AID1", {"tag":"4F","bytes":16,"range":{"minHex":"A0000005591010FFFFFFFF8900001000","maxHex":"A0000005591010FFFFFFFF8900FFFF00","lastByte":"00"}}, {token: CARD_CONTEXT_TOKEN, domainId: CARD_CONTEXT_DOMAIN});
45    // TC-GEN-1 eUICC: The PROFILE_OPERATIONAL1 has been installed on the eUICC.: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
46    // SEQ01-IC-T1 eUICC: The PROFILE_OPERATIONAL1 is Enabled on the eUICC.: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
47    // SEQ01-IC-T2 eUICC: The PROFILE_OPERATIONAL1 corresponds to <ISD_P_AID1>.: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
48    // SEQ02-IC-T1 eUICC: The PROFILE_OPERATIONAL1 is Enabled on the eUICC.: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
49    // SEQ02-IC1 PROC_EUICC_INITIALIZATION_SEQUENCE: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
50    // SEQ02-IC2 PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
51    // SEQ03-IC-T1 eUICC: The PROFILE_OPERATIONAL1 is Enabled on the eUICC.: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
52    // SEQ03-IC-T2 eUICC: The PROFILE_OPERATIONAL1 corresponds to <ISD_P_AID1>.: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
53    // SEQ03-IC1 PROC_EUICC_INITIALIZATION_SEQUENCE_eUICCProfileStateChanged: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
54    // SEQ03-IC2 PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
55    // SEQ04-IC-T1 eUICC: The PROFILE_OPERATIONAL1 is Enabled on the eUICC.: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
56    // SEQ04-IC1 PROC_EUICC_INITIALIZATION_SEQUENCE_eUICCProfileStateChanged: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
57    // SEQ04-IC2 PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
58    // SEQ05-IC-T1 eUICC: The PROFILE_OPERATIONAL1 is Enabled on the eUICC.: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
59    // SEQ05-IC-T2 eUICC: The PROFILE_OPERATIONAL1 corresponds to <ISD_P_AID1>.: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
60    // SEQ05-IC1 PROC_EUICC_INITIALIZATION_SEQUENCE: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
61    // SEQ05-IC2 PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
62    // SEQ06-IC-T1 eUICC: The PROFILE_OPERATIONAL1 is Enabled on the eUICC.: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
63    // SEQ06-IC1 PROC_EUICC_INITIALIZATION_SEQUENCE: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
64    // SEQ06-IC2 PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
65    // SEQ07-IC-T1 eUICC: The PROFILE_OPERATIONAL1 is Enabled on the eUICC.: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
66    // SEQ07-IC1 PROC_EUICC_INITIALIZATION_SEQUENCE: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
67    // SEQ07-IC2 PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
68    // SEQ07-IC4 Do not send FETCH command: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
69    // SEQ08-IC-T1 eUICC: The PROFILE_OPERATIONAL1 is Enabled on the eUICC.: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
70    // SEQ08-IC1 PROC_EUICC_INITIALIZATION_SEQUENCE: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
71    // SEQ08-IC2 PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
72    // SEQ08-IC4 Do not send FETCH command: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
73    // SEQ09-IC-T1 eUICC: The PROFILE_OPERATIONAL1 is Enabled on the eUICC.: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
74    // SEQ09-IC1 PROC_EUICC_INITIALIZATION_SEQUENCE: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
75    // SEQ09-IC2 PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
76    // SEQ10-IC-T1 eUICC: The PROFILE_OPERATIONAL1 is Enabled on the eUICC.: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
77    // SEQ10-IC1 PROC_EUICC_INITIALIZATION_SEQUENCE: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
78    // SEQ10-IC2 PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
79    // PREFLIGHT_CONTEXT AUTHORIZED_DISCOVERY: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
80
81    // IC head inline (initial_conditions → PROC_EUICC_INITIALIZATION_SEQUENCE, K row 1):RESET(K 语料机械展开)
82    var s56 = bind.resetAndAtr();
83    bind.checkData("ICH-SEQ01-IC1-K1-C1 ATR_present", "1", s56.atr_hex !== "" ? "1" : "0");
84
85    // IC head inline (initial_conditions → PROC_EUICC_INITIALIZATION_SEQUENCE, K row 2):SELECT_MF(K 语料机械展开)
86    // FCP outer tag not materialized from clause: tag-face asserted only when corpus fixes the tag byte (e.g. TS 102 221 FCP '62').
87    var s57 = bind.sendApdu("00", "A4", "00", "04", "3F00", "00", "9000");
88    bind.checkData("ICH-SEQ01-IC1-K2-C2 FCP_Template", "1", s57.resp.length > 0 ? "1" : "0");
89    bind.checkData("ICH-SEQ01-IC1-K2-C4 SW", "9000", s57.sw);
90
91    // IC head inline (initial_conditions → PROC_EUICC_INITIALIZATION_SEQUENCE, K row 3):TERMINAL_CAPABILITY_LPAd(K 语料机械展开)
92    var s58 = bind.sendApdu("80", "AA", "00", "00", "A9058100830107", null, "9000");
93    bind.checkData("ICH-SEQ01-IC1-K3-C4 SW", "9000", s58.sw);
94
95    // IC head inline (initial_conditions → PROC_EUICC_INITIALIZATION_SEQUENCE, K row 4):TERMINAL_PROFILE(K 语料机械展开)
96    var steady59 = bind.runToSteadyState(function () {
97        return bind.sendTerminalProfile("FFFFFFFF7F9D00DFBF00001FE2000000C7EB0000000168005000000000000200", "9000");
98    });
99    bind.checkData("ICH-SEQ01-IC1-K4-C4 final SW", "9000", steady59.final.sw);
100
101    // IC head inline (initial_conditions → PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR, K row 1):MANAGE_CHANNEL_OPEN(K 语料机械展开)
102    // CHANNEL_NUMBER extraction and dynamic CLA rebinding are CasBind internal state (chaining rule; no generated-code re-implementation).
103    var s60 = bind.manageChannelOpen("9000");
104    bind.checkData("ICH-SEQ01-IC2-K1-C4 SW", "9000", s60.sw);
105    bind.checkData("ICH-SEQ01-IC2-K1-C3 CHANNEL_NUMBER extracted", "1", s60.chan !== null ? "1" : "0");
106
107    // IC head inline (initial_conditions → PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR, K row 2):MTD_SELECT(K 语料机械展开)
108    // CLA = bound channel (cla_rule) and <L> length binding are CasBind internal state (chaining rule; no generated-code re-implementation).
109    var s61 = bind.sendApdu(null, "A4", "04", "00", "A0000005591010FFFFFFFF8900000100", null, "9000");
110    // 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.
111    bind.checkData("ICH-SEQ01-IC2-K2-C4 SW", "9000", s61.sw);
112
113    // 步骤 1:MTD_STORE_DATA(tc_step)
114    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
115    var s1 = bind.sendApdu("81", "E2", "91", "00", "BF2D035C014F", "00", "9000");
116
117    // 步骤 2:SEQ01-1] MTD_STORE_DATA(tc_step;REQ: RQ32_031, RQ32_033, RQ32_037_1, RQ57_142_2, RQ57_142_3, RQ57_142_12, RQ57_149, RQ57_150, RQ24_010)
118    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
119    var sdCla2 = s60.chan !== null ? (s60.chan <= 3 ? 128 + s60.chan : 188 + s60.chan).toString(16).toUpperCase() : null;
120    // runtime-bound payload: ISD_P_AID1 stays in execution domain
121    var s2 = bind.sendApdu(sdCla2, "E2", "91", "00", BindEs10xProcProfileDynamic.bindProfileAidTemplate(bind, "ISD_P_AID1", "BF32154F10", "0101FF", profileAidSession), "00", null);
122    BindEs10xProcProfileDynamic.assertBoundPayload(bind, "ISD_P_AID1", s2.cmd, profileAidSession);
123    bind.checkData("S1-C1 SW1 91", "91", s2.sw.substring(0, 2));
124    var r2w2 = BindGecaProc.parseGecaResponse(s2.resp, {outer: "BF32", required: ["80"]});
125    bind.checkData("S1-C2 disableResult ok", "00", (r2w2.ok && r2w2.fields["80"] === "00") ? "00" : (r2w2.fields["80"] || "absent"));
126
127    // 步骤 3:SEQ01-2] FETCH 'XX'(tc_step;REQ: RQ32_038, RQ32_039, RQ32_039_1, RQ32_041_2, RQ57_142_13, RQ57_142_14, RQ57_147)
128    // FETCH header literals follow the golden wire evidence 8012 (same
129    // anchor as runToSteadyState; J Annex D.4 has no FETCH row, D 2.2.2
130    // gives mechanism only). Le = pending length from the last 91XX
131    // (chain rule, binding-internal state).
132    var s3 = bind.fetchPending("80", "12", "00", "00", null);
133    bind.checkData("S2-C1 proactive command envelope", "1", (s3.resp.length >= 4 && s3.resp.substring(0, 2) === "D0") ? "1" : "0");
134    // S2-C1: REFRESH type/mode bytes are not corpus-fixed (envelope face only; per-mode bytes absent from input).
135    // S3:主动会话协议闭合(TS 102 223 §6.3:主动命令必须 TR 应答;
136    // UICC Reset 变体 E 表无 TR 行属编辑省略,golden U3 线证同构)。
137    var s3tr = bind.terminalResponseForPending("80", "14", "00", "00", "9000");
138
139    // IC ref inline @E 步骤 4(IC1 → PROC_EUICC_INITIALIZATION_SEQUENCE, K row 1):RESET(K 语料机械展开)
140    var s62 = bind.resetAndAtr();
141    bind.checkData("IC4-IC1-K1-C1 ATR_present", "1", s62.atr_hex !== "" ? "1" : "0");
142
143    // IC ref inline @E 步骤 4(IC1 → PROC_EUICC_INITIALIZATION_SEQUENCE, K row 2):SELECT_MF(K 语料机械展开)
144    // FCP outer tag not materialized from clause: tag-face asserted only when corpus fixes the tag byte (e.g. TS 102 221 FCP '62').
145    var s63 = bind.sendApdu("00", "A4", "00", "04", "3F00", "00", "9000");
146    bind.checkData("IC4-IC1-K2-C2 FCP_Template", "1", s63.resp.length > 0 ? "1" : "0");
147    bind.checkData("IC4-IC1-K2-C4 SW", "9000", s63.sw);
148
149    // IC ref inline @E 步骤 4(IC1 → PROC_EUICC_INITIALIZATION_SEQUENCE, K row 3):TERMINAL_CAPABILITY_LPAd(K 语料机械展开)
150    var s64 = bind.sendApdu("80", "AA", "00", "00", "A9058100830107", null, "9000");
151    bind.checkData("IC4-IC1-K3-C4 SW", "9000", s64.sw);
152
153    // IC ref inline @E 步骤 4(IC1 → PROC_EUICC_INITIALIZATION_SEQUENCE, K row 4):TERMINAL_PROFILE(K 语料机械展开)
154    var steady65 = bind.runToSteadyState(function () {
155        return bind.sendTerminalProfile("FFFFFFFF7F9D00DFBF00001FE2000000C7EB0000000168005000000000000200", "9000");
156    });
157    bind.checkData("IC4-IC1-K4-C4 final SW", "9000", steady65.final.sw);
158
159    // IC ref inline @E 步骤 4(IC2 → PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR, K row 1):MANAGE_CHANNEL_OPEN(K 语料机械展开)
160    // CHANNEL_NUMBER extraction and dynamic CLA rebinding are CasBind internal state (chaining rule; no generated-code re-implementation).
161    var s66 = bind.manageChannelOpen("9000");
162    bind.checkData("IC4-IC2-K1-C4 SW", "9000", s66.sw);
163    bind.checkData("IC4-IC2-K1-C3 CHANNEL_NUMBER extracted", "1", s66.chan !== null ? "1" : "0");
164
165    // IC ref inline @E 步骤 4(IC2 → PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR, K row 2):MTD_SELECT(K 语料机械展开)
166    // CLA = bound channel (cla_rule) and <L> length binding are CasBind internal state (chaining rule; no generated-code re-implementation).
167    var s67 = bind.sendApdu(null, "A4", "04", "00", "A0000005591010FFFFFFFF8900000100", null, "9000");
168    // 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.
169    bind.checkData("IC4-IC2-K2-C4 SW", "9000", s67.sw);
170
171    // 步骤 5:SEQ01-4] MTD_STORE_DATA(tc_step;REQ: RQ32_031, RQ32_033, RQ32_037_1, RQ57_142_2, RQ57_142_3, RQ57_142_12, RQ57_149, RQ57_150, RQ24_010)
172    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
173    var sdCla5 = s66.chan !== null ? (s66.chan <= 3 ? 128 + s66.chan : 188 + s66.chan).toString(16).toUpperCase() : null;
174    // runtime-bound payload: ISD_P_AID1 stays in execution domain
175    var s5 = bind.sendApdu(sdCla5, "E2", "91", "00", BindEs10xProcProfileDynamic.bindProfileAidTemplate(bind, "ISD_P_AID1", "BF2D16A0124F10", "", profileAidSession), "00", "9000");
176    bind.checkData("S4-C1 SW", "9000", s5.sw);
177    BindEs10xProcProfileDynamic.assertBoundPayload(bind, "ISD_P_AID1", s5.cmd, profileAidSession);
178    var r2p5 = BindEs10xProcProfile.walkChoiceList(s5.resp, {respTag: "BF2D", okTag: "A0", errTag: "81"});
179    var r2has5_0 = false;
180    for (var r2i5_0 = 0; r2i5_0 < r2p5.elements.length; r2i5_0++) {
181        var f = r2p5.elements[r2i5_0].fields;
182        if (f["5A"] === "989209012143658709F5" && f["9F70"] === "00") { r2has5_0 = true; break; }
183    }
184    bind.checkData("S4-C2 contains PROFILE_INFO1_DISABLED", "1", (r2p5.branch_tag === "A0" && r2has5_0) ? "1" : "0");
185
186    // 步骤 6:SEQ01-5] [SELECT_ICCID(tc_step;REQ: RQ24_025)
187    var s6 = bind.sendApdu("00", "A4", "00", "0C", "2FE2", null, "6A82");
188    bind.checkData("S5-C1 SW", "6A82", s6.sw);
189
190    // 步骤 7:SEQ02-1] MTD_STORE_DATA(tc_step;REQ: RQ32_031, RQ32_033, RQ32_037_1, RQ57_142_2, RQ57_142_3, RQ57_142_12, RQ57_149, RQ57_150)
191    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
192    var sdCla7 = s66.chan !== null ? (s66.chan <= 3 ? 128 + s66.chan : 188 + s66.chan).toString(16).toUpperCase() : null;
193    var s7 = bind.sendApdu(sdCla7, "E2", "91", "00", "BF320F5A0A989209012143658709F50101FF", "00", null);
194    bind.checkData("S6-C1 SW1 91", "91", s7.sw.substring(0, 2));
195    var r2w7 = BindGecaProc.parseGecaResponse(s7.resp, {outer: "BF32", required: ["80"]});
196    bind.checkData("S6-C2 disableResult ok", "00", (r2w7.ok && r2w7.fields["80"] === "00") ? "00" : (r2w7.fields["80"] || "absent"));
197
198    // 步骤 8:SEQ02-2] FETCH 'XX'(tc_step;REQ: RQ32_038, RQ32_039, RQ32_039_1, RQ32_041_2, RQ57_142_13, RQ57_142_14, RQ57_147)
199    // FETCH header literals follow the golden wire evidence 8012 (same
200    // anchor as runToSteadyState; J Annex D.4 has no FETCH row, D 2.2.2
201    // gives mechanism only). Le = pending length from the last 91XX
202    // (chain rule, binding-internal state).
203    var s8 = bind.fetchPending("80", "12", "00", "00", null);
204    bind.checkData("S7-C1 proactive command envelope", "1", (s8.resp.length >= 4 && s8.resp.substring(0, 2) === "D0") ? "1" : "0");
205    // S7-C1: REFRESH type/mode bytes are not corpus-fixed (envelope face only; per-mode bytes absent from input).
206    // S8:主动会话协议闭合(TS 102 223 §6.3:主动命令必须 TR 应答;
207    // UICC Reset 变体 E 表无 TR 行属编辑省略,golden U3 线证同构)。
208    var s8tr = bind.terminalResponseForPending("80", "14", "00", "00", "9000");
209
210    // IC ref inline @E 步骤 9(IC1 → PROC_EUICC_INITIALIZATION_SEQUENCE, K row 1):RESET(K 语料机械展开)
211    var s68 = bind.resetAndAtr();
212    bind.checkData("IC9-IC1-K1-C1 ATR_present", "1", s68.atr_hex !== "" ? "1" : "0");
213
214    // IC ref inline @E 步骤 9(IC1 → PROC_EUICC_INITIALIZATION_SEQUENCE, K row 2):SELECT_MF(K 语料机械展开)
215    // FCP outer tag not materialized from clause: tag-face asserted only when corpus fixes the tag byte (e.g. TS 102 221 FCP '62').
216    var s69 = bind.sendApdu("00", "A4", "00", "04", "3F00", "00", "9000");
217    bind.checkData("IC9-IC1-K2-C2 FCP_Template", "1", s69.resp.length > 0 ? "1" : "0");
218    bind.checkData("IC9-IC1-K2-C4 SW", "9000", s69.sw);
219
220    // IC ref inline @E 步骤 9(IC1 → PROC_EUICC_INITIALIZATION_SEQUENCE, K row 3):TERMINAL_CAPABILITY_LPAd(K 语料机械展开)
221    var s70 = bind.sendApdu("80", "AA", "00", "00", "A9058100830107", null, "9000");
222    bind.checkData("IC9-IC1-K3-C4 SW", "9000", s70.sw);
223
224    // IC ref inline @E 步骤 9(IC1 → PROC_EUICC_INITIALIZATION_SEQUENCE, K row 4):TERMINAL_PROFILE(K 语料机械展开)
225    var steady71 = bind.runToSteadyState(function () {
226        return bind.sendTerminalProfile("FFFFFFFF7F9D00DFBF00001FE2000000C7EB0000000168005000000000000200", "9000");
227    });
228    bind.checkData("IC9-IC1-K4-C4 final SW", "9000", steady71.final.sw);
229
230    // IC ref inline @E 步骤 9(IC2 → PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR, K row 1):MANAGE_CHANNEL_OPEN(K 语料机械展开)
231    // CHANNEL_NUMBER extraction and dynamic CLA rebinding are CasBind internal state (chaining rule; no generated-code re-implementation).
232    var s72 = bind.manageChannelOpen("9000");
233    bind.checkData("IC9-IC2-K1-C4 SW", "9000", s72.sw);
234    bind.checkData("IC9-IC2-K1-C3 CHANNEL_NUMBER extracted", "1", s72.chan !== null ? "1" : "0");
235
236    // IC ref inline @E 步骤 9(IC2 → PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR, K row 2):MTD_SELECT(K 语料机械展开)
237    // CLA = bound channel (cla_rule) and <L> length binding are CasBind internal state (chaining rule; no generated-code re-implementation).
238    var s73 = bind.sendApdu(null, "A4", "04", "00", "A0000005591010FFFFFFFF8900000100", null, "9000");
239    // 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.
240    bind.checkData("IC9-IC2-K2-C4 SW", "9000", s73.sw);
241
242    // 步骤 10:SEQ02-4] MTD_STORE_DATA(tc_step;REQ: RQ32_031, RQ32_033, RQ32_037_1, RQ57_142_2, RQ57_142_3, RQ57_142_12, RQ57_149, RQ57_150)
243    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
244    var sdCla10 = s72.chan !== null ? (s72.chan <= 3 ? 128 + s72.chan : 188 + s72.chan).toString(16).toUpperCase() : null;
245    var s10 = bind.sendApdu(sdCla10, "E2", "91", "00", "BF2D0EA00C5A0A989209012143658709F5", "00", "9000");
246    bind.checkData("S9-C1 SW", "9000", s10.sw);
247    var r2p10 = BindEs10xProcProfile.walkChoiceList(s10.resp, {respTag: "BF2D", okTag: "A0", errTag: "81"});
248    var r2has10_0 = false;
249    for (var r2i10_0 = 0; r2i10_0 < r2p10.elements.length; r2i10_0++) {
250        var f = r2p10.elements[r2i10_0].fields;
251        if (f["5A"] === "989209012143658709F5" && f["9F70"] === "00") { r2has10_0 = true; break; }
252    }
253    bind.checkData("S9-C2 contains PROFILE_INFO1_DISABLED", "1", (r2p10.branch_tag === "A0" && r2has10_0) ? "1" : "0");
254
255    // 步骤 11:SEQ02-5] [SELECT_ICCID(tc_step;REQ: RQ24_025)
256    var s11 = bind.sendApdu("00", "A4", "00", "0C", "2FE2", null, "6A82");
257    bind.checkData("S10-C1 SW", "6A82", s11.sw);
258
259    // 步骤 12:SEQ03-1] MTD_STORE_DATA(tc_step;REQ: RQ32_031, RQ32_033, RQ32_037_1, RQ57_142_2, RQ57_142_3, RQ57_142_12, RQ57_149, RQ57_150, RQ24_010)
260    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
261    var sdCla12 = s72.chan !== null ? (s72.chan <= 3 ? 128 + s72.chan : 188 + s72.chan).toString(16).toUpperCase() : null;
262    // runtime-bound payload: ISD_P_AID1 stays in execution domain
263    var s12 = bind.sendApdu(sdCla12, "E2", "91", "00", BindEs10xProcProfileDynamic.bindProfileAidTemplate(bind, "ISD_P_AID1", "BF32154F10", "0101FF", profileAidSession), "00", null);
264    BindEs10xProcProfileDynamic.assertBoundPayload(bind, "ISD_P_AID1", s12.cmd, profileAidSession);
265    bind.checkData("S11-C1 SW1 91", "91", s12.sw.substring(0, 2));
266    var r2w12 = BindGecaProc.parseGecaResponse(s12.resp, {outer: "BF32", required: ["80"]});
267    bind.checkData("S11-C2 disableResult ok", "00", (r2w12.ok && r2w12.fields["80"] === "00") ? "00" : (r2w12.fields["80"] || "absent"));
268
269    // 步骤 13:SEQ03-2] FETCH 'XX'(tc_step;REQ: RQ32_038, RQ32_039, RQ32_039_1, RQ32_041_2, RQ57_142_13, RQ57_142_14, RQ57_147)
270    // FETCH header literals follow the golden wire evidence 8012 (same
271    // anchor as runToSteadyState; J Annex D.4 has no FETCH row, D 2.2.2
272    // gives mechanism only). Le = pending length from the last 91XX
273    // (chain rule, binding-internal state).
274    var s13 = bind.fetchPending("80", "12", "00", "00", null);
275    bind.checkData("S12-C1 proactive command envelope", "1", (s13.resp.length >= 4 && s13.resp.substring(0, 2) === "D0") ? "1" : "0");
276    // S12-C1: REFRESH type/mode bytes are not corpus-fixed (envelope face only; per-mode bytes absent from input).
277
278    // 步骤 14:SEQ03-3] TERMINAL RESPONSE(tc_step)
279    // TERMINAL RESPONSE data is dynamically built by the binding from the
280    // last FETCHed proactive command (D 2.2.2; buildTrData) - never static.
281    // Header literals follow the golden wire evidence 8014.
282    var s14 = bind.terminalResponseForPending("80", "14", "00", "00", "9000");
283    bind.checkData("S13-C1 SW", "9000", s14.sw);
284
285    // IC ref inline @E 步骤 15(IC1 → PROC_EUICC_INITIALIZATION_SEQUENCE_eUICCProfileStateChanged, K row 2):SELECT_MF(K 语料机械展开)
286    // FCP outer tag not materialized from clause: tag-face asserted only when corpus fixes the tag byte (e.g. TS 102 221 FCP '62').
287    var s74 = bind.sendApdu("00", "A4", "00", "04", "3F00", "00", "9000");
288    bind.checkData("IC15-IC1-K2-C2 FCP_Template", "1", s74.resp.length > 0 ? "1" : "0");
289    bind.checkData("IC15-IC1-K2-C4 SW", "9000", s74.sw);
290
291    // IC ref inline @E 步骤 15(IC1 → PROC_EUICC_INITIALIZATION_SEQUENCE_eUICCProfileStateChanged, K row 3):TERMINAL_CAPABILITY_LPAd(K 语料机械展开)
292    var s75 = bind.sendApdu("80", "AA", "00", "00", "A9058100830107", null, "9000");
293    bind.checkData("IC15-IC1-K3-C4 SW", "9000", s75.sw);
294
295    // IC ref inline @E 步骤 15(IC1 → PROC_EUICC_INITIALIZATION_SEQUENCE_eUICCProfileStateChanged, K row 4):TERMINAL_PROFILE_eUICCProfileStateChanged(K 语料机械展开)
296    var steady76 = bind.runToSteadyState(function () {
297        return bind.sendTerminalProfile("FFFFFFFFFFFF1FFFFF0302FFFF9FFFEFDFFF0FFF0FFFFF0FFF03003F7FFF03FFFF20", "9000");
298    });
299    bind.checkData("IC15-IC1-K4-C4 final SW", "9000", steady76.final.sw);
300
301    // IC ref inline @E 步骤 16(IC2 → PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR, K row 1):MANAGE_CHANNEL_OPEN(K 语料机械展开)
302    // CHANNEL_NUMBER extraction and dynamic CLA rebinding are CasBind internal state (chaining rule; no generated-code re-implementation).
303    var s77 = bind.manageChannelOpen("9000");
304    bind.checkData("IC16-IC2-K1-C4 SW", "9000", s77.sw);
305    bind.checkData("IC16-IC2-K1-C3 CHANNEL_NUMBER extracted", "1", s77.chan !== null ? "1" : "0");
306
307    // IC ref inline @E 步骤 16(IC2 → PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR, K row 2):MTD_SELECT(K 语料机械展开)
308    // CLA = bound channel (cla_rule) and <L> length binding are CasBind internal state (chaining rule; no generated-code re-implementation).
309    var s78 = bind.sendApdu(null, "A4", "04", "00", "A0000005591010FFFFFFFF8900000100", null, "9000");
310    // 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.
311    bind.checkData("IC16-IC2-K2-C4 SW", "9000", s78.sw);
312
313    // 步骤 17:SEQ03-6] MTD_STORE_DATA(tc_step;REQ: RQ32_031, RQ32_033, RQ32_037_1, RQ57_142_2, RQ57_142_3, RQ57_142_12, RQ57_149, RQ57_150, RQ24_010)
314    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
315    var sdCla17 = s77.chan !== null ? (s77.chan <= 3 ? 128 + s77.chan : 188 + s77.chan).toString(16).toUpperCase() : null;
316    // runtime-bound payload: ISD_P_AID1 stays in execution domain
317    var s17 = bind.sendApdu(sdCla17, "E2", "91", "00", BindEs10xProcProfileDynamic.bindProfileAidTemplate(bind, "ISD_P_AID1", "BF2D16A0124F10", "", profileAidSession), "00", "9000");
318    bind.checkData("S16-C1 SW", "9000", s17.sw);
319    BindEs10xProcProfileDynamic.assertBoundPayload(bind, "ISD_P_AID1", s17.cmd, profileAidSession);
320    var r2p17 = BindEs10xProcProfile.walkChoiceList(s17.resp, {respTag: "BF2D", okTag: "A0", errTag: "81"});
321    var r2has17_0 = false;
322    for (var r2i17_0 = 0; r2i17_0 < r2p17.elements.length; r2i17_0++) {
323        var f = r2p17.elements[r2i17_0].fields;
324        if (f["5A"] === "989209012143658709F5" && f["9F70"] === "00") { r2has17_0 = true; break; }
325    }
326    bind.checkData("S16-C2 contains PROFILE_INFO1_DISABLED", "1", (r2p17.branch_tag === "A0" && r2has17_0) ? "1" : "0");
327
328    // 步骤 18:SEQ03-7] [SELECT_ICCID(tc_step;REQ: RQ24_025)
329    var s18 = bind.sendApdu("00", "A4", "00", "0C", "2FE2", null, "6A82");
330    bind.checkData("S17-C1 SW", "6A82", s18.sw);
331
332    // 步骤 19:SEQ04-1] MTD_STORE_DATA(tc_step;REQ: RQ32_031, RQ32_033, RQ32_037_1, RQ57_142_2, RQ57_142_3, RQ57_142_12, RQ57_149, RQ57_150)
333    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
334    var sdCla19 = s77.chan !== null ? (s77.chan <= 3 ? 128 + s77.chan : 188 + s77.chan).toString(16).toUpperCase() : null;
335    var s19 = bind.sendApdu(sdCla19, "E2", "91", "00", "BF320F5A0A989209012143658709F50101FF", "00", null);
336    bind.checkData("S18-C1 SW1 91", "91", s19.sw.substring(0, 2));
337    var r2w19 = BindGecaProc.parseGecaResponse(s19.resp, {outer: "BF32", required: ["80"]});
338    bind.checkData("S18-C2 disableResult ok", "00", (r2w19.ok && r2w19.fields["80"] === "00") ? "00" : (r2w19.fields["80"] || "absent"));
339
340    // 步骤 20:SEQ04-2] FETCH 'XX'(tc_step;REQ: RQ32_038, RQ32_039, RQ32_039_1, RQ32_041_2, RQ57_142_13, RQ57_142_14, RQ57_147)
341    // FETCH header literals follow the golden wire evidence 8012 (same
342    // anchor as runToSteadyState; J Annex D.4 has no FETCH row, D 2.2.2
343    // gives mechanism only). Le = pending length from the last 91XX
344    // (chain rule, binding-internal state).
345    var s20 = bind.fetchPending("80", "12", "00", "00", null);
346    bind.checkData("S19-C1 proactive command envelope", "1", (s20.resp.length >= 4 && s20.resp.substring(0, 2) === "D0") ? "1" : "0");
347    // S19-C1: REFRESH type/mode bytes are not corpus-fixed (envelope face only; per-mode bytes absent from input).
348
349    // 步骤 21:SEQ04-3] TERMINAL RESPONSE(tc_step)
350    // TERMINAL RESPONSE data is dynamically built by the binding from the
351    // last FETCHed proactive command (D 2.2.2; buildTrData) - never static.
352    // Header literals follow the golden wire evidence 8014.
353    var s21 = bind.terminalResponseForPending("80", "14", "00", "00", "9000");
354    bind.checkData("S20-C1 SW", "9000", s21.sw);
355
356    // IC ref inline @E 步骤 22(IC1 → PROC_EUICC_INITIALIZATION_SEQUENCE_eUICCProfileStateChanged, K row 2):SELECT_MF(K 语料机械展开)
357    // FCP outer tag not materialized from clause: tag-face asserted only when corpus fixes the tag byte (e.g. TS 102 221 FCP '62').
358    var s79 = bind.sendApdu("00", "A4", "00", "04", "3F00", "00", "9000");
359    bind.checkData("IC22-IC1-K2-C2 FCP_Template", "1", s79.resp.length > 0 ? "1" : "0");
360    bind.checkData("IC22-IC1-K2-C4 SW", "9000", s79.sw);
361
362    // IC ref inline @E 步骤 22(IC1 → PROC_EUICC_INITIALIZATION_SEQUENCE_eUICCProfileStateChanged, K row 3):TERMINAL_CAPABILITY_LPAd(K 语料机械展开)
363    var s80 = bind.sendApdu("80", "AA", "00", "00", "A9058100830107", null, "9000");
364    bind.checkData("IC22-IC1-K3-C4 SW", "9000", s80.sw);
365
366    // IC ref inline @E 步骤 22(IC1 → PROC_EUICC_INITIALIZATION_SEQUENCE_eUICCProfileStateChanged, K row 4):TERMINAL_PROFILE_eUICCProfileStateChanged(K 语料机械展开)
367    var steady81 = bind.runToSteadyState(function () {
368        return bind.sendTerminalProfile("FFFFFFFFFFFF1FFFFF0302FFFF9FFFEFDFFF0FFF0FFFFF0FFF03003F7FFF03FFFF20", "9000");
369    });
370    bind.checkData("IC22-IC1-K4-C4 final SW", "9000", steady81.final.sw);
371
372    // IC ref inline @E 步骤 23(IC2 → PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR, K row 1):MANAGE_CHANNEL_OPEN(K 语料机械展开)
373    // CHANNEL_NUMBER extraction and dynamic CLA rebinding are CasBind internal state (chaining rule; no generated-code re-implementation).
374    var s82 = bind.manageChannelOpen("9000");
375    bind.checkData("IC23-IC2-K1-C4 SW", "9000", s82.sw);
376    bind.checkData("IC23-IC2-K1-C3 CHANNEL_NUMBER extracted", "1", s82.chan !== null ? "1" : "0");
377
378    // IC ref inline @E 步骤 23(IC2 → PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR, K row 2):MTD_SELECT(K 语料机械展开)
379    // CLA = bound channel (cla_rule) and <L> length binding are CasBind internal state (chaining rule; no generated-code re-implementation).
380    var s83 = bind.sendApdu(null, "A4", "04", "00", "A0000005591010FFFFFFFF8900000100", null, "9000");
381    // 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.
382    bind.checkData("IC23-IC2-K2-C4 SW", "9000", s83.sw);
383
384    // 步骤 24:SEQ04-6] MTD_STORE_DATA(tc_step;REQ: RQ32_031, RQ32_033, RQ32_037_1, RQ57_142_2, RQ57_142_3, RQ57_142_12, RQ57_149, RQ57_150)
385    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
386    var sdCla24 = s82.chan !== null ? (s82.chan <= 3 ? 128 + s82.chan : 188 + s82.chan).toString(16).toUpperCase() : null;
387    var s24 = bind.sendApdu(sdCla24, "E2", "91", "00", "BF2D0EA00C5A0A989209012143658709F5", "00", "9000");
388    bind.checkData("S23-C1 SW", "9000", s24.sw);
389    var r2p24 = BindEs10xProcProfile.walkChoiceList(s24.resp, {respTag: "BF2D", okTag: "A0", errTag: "81"});
390    var r2has24_0 = false;
391    for (var r2i24_0 = 0; r2i24_0 < r2p24.elements.length; r2i24_0++) {
392        var f = r2p24.elements[r2i24_0].fields;
393        if (f["5A"] === "989209012143658709F5" && f["9F70"] === "00") { r2has24_0 = true; break; }
394    }
395    bind.checkData("S23-C2 contains PROFILE_INFO1_DISABLED", "1", (r2p24.branch_tag === "A0" && r2has24_0) ? "1" : "0");
396
397    // 步骤 25:SEQ04-7] [SELECT_ICCID(tc_step;REQ: RQ24_025)
398    var s25 = bind.sendApdu("00", "A4", "00", "0C", "2FE2", null, "6A82");
399    bind.checkData("S24-C1 SW", "6A82", s25.sw);
400
401    // 步骤 26:SEQ05-1] MTD_STORE_DATA(tc_step;REQ: RQ32_031, RQ32_033, RQ32_038, RQ32_041_1, RQ57_142_1, RQ57_142_2, RQ57_142_3, RQ57_142_6, RQ57_142_9, RQ57_142_14, RQ57_149, RQ57_150)
402    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
403    var sdCla26 = s82.chan !== null ? (s82.chan <= 3 ? 128 + s82.chan : 188 + s82.chan).toString(16).toUpperCase() : null;
404    // runtime-bound payload: ISD_P_AID1 stays in execution domain
405    var s26 = bind.sendApdu(sdCla26, "E2", "91", "00", BindEs10xProcProfileDynamic.bindProfileAidTemplate(bind, "ISD_P_AID1", "BF32154F10", "010100", profileAidSession), "00", "9000");
406    bind.checkData("S25-C1 SW", "9000", s26.sw);
407    BindEs10xProcProfileDynamic.assertBoundPayload(bind, "ISD_P_AID1", s26.cmd, profileAidSession);
408    var r2w26 = BindGecaProc.parseGecaResponse(s26.resp, {outer: "BF32", required: ["80"]});
409    bind.checkData("S25-C2 disableResult ok", "00", (r2w26.ok && r2w26.fields["80"] === "00") ? "00" : (r2w26.fields["80"] || "absent"));
410
411    // 步骤 27:SEQ05-2] MTD_STORE_DATA(tc_step;REQ: RQ32_031, RQ32_033, RQ32_038, RQ32_041_1, RQ57_142_1, RQ57_142_2, RQ57_142_3, RQ57_142_6, RQ57_142_9, RQ57_142_14, RQ57_149, RQ57_150)
412    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
413    var sdCla27 = s82.chan !== null ? (s82.chan <= 3 ? 128 + s82.chan : 188 + s82.chan).toString(16).toUpperCase() : null;
414    // runtime-bound payload: ISD_P_AID1 stays in execution domain
415    var s27 = bind.sendApdu(sdCla27, "E2", "91", "00", BindEs10xProcProfileDynamic.bindProfileAidTemplate(bind, "ISD_P_AID1", "BF2D16A0124F10", "", profileAidSession), "00", "9000");
416    bind.checkData("S26-C1 SW", "9000", s27.sw);
417    BindEs10xProcProfileDynamic.assertBoundPayload(bind, "ISD_P_AID1", s27.cmd, profileAidSession);
418    var r2p27 = BindEs10xProcProfile.walkChoiceList(s27.resp, {respTag: "BF2D", okTag: "A0", errTag: "81"});
419    var r2has27_0 = false;
420    for (var r2i27_0 = 0; r2i27_0 < r2p27.elements.length; r2i27_0++) {
421        var f = r2p27.elements[r2i27_0].fields;
422        if (f["5A"] === "989209012143658709F5" && f["9F70"] === "00") { r2has27_0 = true; break; }
423    }
424    bind.checkData("S26-C2 contains PROFILE_INFO1_DISABLED", "1", (r2p27.branch_tag === "A0" && r2has27_0) ? "1" : "0");
425
426    // 步骤 28:SEQ05-3] [SELECT_ICCID(tc_step;REQ: RQ24_025)
427    var s28 = bind.sendApdu("00", "A4", "00", "0C", "2FE2", null, "6A82");
428    bind.checkData("S27-C1 SW", "6A82", s28.sw);
429
430    // 步骤 29:SEQ06-1] MTD_STORE_DATA(tc_step;REQ: RQ32_031, RQ32_033, RQ32_038, RQ32_041_1, RQ57_142_1, RQ57_142_2, RQ57_142_3, RQ57_142_6, RQ57_142_9, RQ57_142_14, RQ57_149, RQ57_150)
431    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
432    var sdCla29 = s82.chan !== null ? (s82.chan <= 3 ? 128 + s82.chan : 188 + s82.chan).toString(16).toUpperCase() : null;
433    var s29 = bind.sendApdu(sdCla29, "E2", "91", "00", "BF320F5A0A989209012143658709F5010100", "00", "9000");
434    bind.checkData("S28-C1 SW", "9000", s29.sw);
435    var r2w29 = BindGecaProc.parseGecaResponse(s29.resp, {outer: "BF32", required: ["80"]});
436    bind.checkData("S28-C2 disableResult ok", "00", (r2w29.ok && r2w29.fields["80"] === "00") ? "00" : (r2w29.fields["80"] || "absent"));
437
438    // 步骤 30:SEQ06-2] MTD_STORE_DATA(tc_step;REQ: RQ32_031, RQ32_033, RQ32_038, RQ32_041_1, RQ57_142_1, RQ57_142_2, RQ57_142_3, RQ57_142_6, RQ57_142_9, RQ57_142_14, RQ57_149, RQ57_150)
439    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
440    var sdCla30 = s82.chan !== null ? (s82.chan <= 3 ? 128 + s82.chan : 188 + s82.chan).toString(16).toUpperCase() : null;
441    var s30 = bind.sendApdu(sdCla30, "E2", "91", "00", "BF2D0EA00C5A0A989209012143658709F5", "00", "9000");
442    bind.checkData("S29-C1 SW", "9000", s30.sw);
443    var r2p30 = BindEs10xProcProfile.walkChoiceList(s30.resp, {respTag: "BF2D", okTag: "A0", errTag: "81"});
444    var r2has30_0 = false;
445    for (var r2i30_0 = 0; r2i30_0 < r2p30.elements.length; r2i30_0++) {
446        var f = r2p30.elements[r2i30_0].fields;
447        if (f["5A"] === "989209012143658709F5" && f["9F70"] === "00") { r2has30_0 = true; break; }
448    }
449    bind.checkData("S29-C2 contains PROFILE_INFO1_DISABLED", "1", (r2p30.branch_tag === "A0" && r2has30_0) ? "1" : "0");
450
451    // 步骤 31:SEQ06-3] [SELECT_ICCID(tc_step;REQ: RQ24_025)
452    var s31 = bind.sendApdu("00", "A4", "00", "0C", "2FE2", null, "6A82");
453    bind.checkData("S30-C1 SW", "6A82", s31.sw);
454
455    // 步骤 32:SEQ07-IC3] MTD_SEND_SMS_PP(tc_step)
456    // MTD_SEND_SMS_PP ENVELOPE (H Annex C.1 表1238 Details: 80 C2 00 00 <L>): SCP80-packed SMS-PP body is runtime-domain
457    // (<MNO_SCP80_COUNTER>/<CC>/<C_APDUS_SCRIPT>) — no bytes fabricated; the embedded STORE DATA
458    // script executes via the proactive FETCH / TERMINAL RESPONSE chain, not in this response.
459    var s32 = bind.sendApdu("80", "C2", "00", "00", null, null, null);
460    bind.checkData("S31-C1 SW1 91", "91", s32.sw.substring(0, 2));
461
462    // 步骤 33:SEQ07-1] MTD_STORE_DATA(tc_step)
463    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
464    var sdCla33 = s82.chan !== null ? (s82.chan <= 3 ? 128 + s82.chan : 188 + s82.chan).toString(16).toUpperCase() : null;
465    // runtime-bound payload: ISD_P_AID1 stays in execution domain
466    var s33 = bind.sendApdu(sdCla33, "E2", "91", "00", BindEs10xProcProfileDynamic.bindProfileAidTemplate(bind, "ISD_P_AID1", "BF32154F10", "0101FF", profileAidSession), "00", null);
467    BindEs10xProcProfileDynamic.assertBoundPayload(bind, "ISD_P_AID1", s33.cmd, profileAidSession);
468    bind.checkData("S32-C1 SW1 91", "91", s33.sw.substring(0, 2));
469    var r2w33 = BindGecaProc.parseGecaResponse(s33.resp, {outer: "BF32", required: ["80"]});
470    bind.checkData("S32-C2 DisableResult ok", "00", (r2w33.ok && r2w33.fields["80"] === "00") ? "00" : (r2w33.fields["80"] || "absent"));
471
472    // 步骤 34:SEQ07-2] FETCH 'YY'(tc_step;REQ: RQ32_016_3, RQ32_017, RQ57_134)
473    // FETCH header literals follow the golden wire evidence 8012 (same
474    // anchor as runToSteadyState; J Annex D.4 has no FETCH row, D 2.2.2
475    // gives mechanism only). Le = pending length from the last 91XX
476    // (chain rule, binding-internal state).
477    var s34 = bind.fetchPending("80", "12", "00", "00", null);
478    bind.checkData("S33-C1 proactive command envelope", "1", (s34.resp.length >= 4 && s34.resp.substring(0, 2) === "D0") ? "1" : "0");
479    // S33-C1: REFRESH type/mode bytes are not corpus-fixed (envelope face only; per-mode bytes absent from input).
480    // S34:主动会话协议闭合(TS 102 223 §6.3:主动命令必须 TR 应答;
481    // UICC Reset 变体 E 表无 TR 行属编辑省略,golden U3 线证同构)。
482    var s34tr = bind.terminalResponseForPending("80", "14", "00", "00", "9000");
483
484    // IC ref inline @E 步骤 35(IC1 → PROC_EUICC_INITIALIZATION_SEQUENCE, K row 1):RESET(K 语料机械展开)
485    var s84 = bind.resetAndAtr();
486    bind.checkData("IC35-IC1-K1-C1 ATR_present", "1", s84.atr_hex !== "" ? "1" : "0");
487
488    // IC ref inline @E 步骤 35(IC1 → PROC_EUICC_INITIALIZATION_SEQUENCE, K row 2):SELECT_MF(K 语料机械展开)
489    // FCP outer tag not materialized from clause: tag-face asserted only when corpus fixes the tag byte (e.g. TS 102 221 FCP '62').
490    var s85 = bind.sendApdu("00", "A4", "00", "04", "3F00", "00", "9000");
491    bind.checkData("IC35-IC1-K2-C2 FCP_Template", "1", s85.resp.length > 0 ? "1" : "0");
492    bind.checkData("IC35-IC1-K2-C4 SW", "9000", s85.sw);
493
494    // IC ref inline @E 步骤 35(IC1 → PROC_EUICC_INITIALIZATION_SEQUENCE, K row 3):TERMINAL_CAPABILITY_LPAd(K 语料机械展开)
495    var s86 = bind.sendApdu("80", "AA", "00", "00", "A9058100830107", null, "9000");
496    bind.checkData("IC35-IC1-K3-C4 SW", "9000", s86.sw);
497
498    // IC ref inline @E 步骤 35(IC1 → PROC_EUICC_INITIALIZATION_SEQUENCE, K row 4):TERMINAL_PROFILE(K 语料机械展开)
499    var steady87 = bind.runToSteadyState(function () {
500        return bind.sendTerminalProfile("FFFFFFFF7F9D00DFBF00001FE2000000C7EB0000000168005000000000000200", "9000");
501    });
502    bind.checkData("IC35-IC1-K4-C4 final SW", "9000", steady87.final.sw);
503
504    // IC ref inline @E 步骤 35(IC2 → PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR, K row 1):MANAGE_CHANNEL_OPEN(K 语料机械展开)
505    // CHANNEL_NUMBER extraction and dynamic CLA rebinding are CasBind internal state (chaining rule; no generated-code re-implementation).
506    var s88 = bind.manageChannelOpen("9000");
507    bind.checkData("IC35-IC2-K1-C4 SW", "9000", s88.sw);
508    bind.checkData("IC35-IC2-K1-C3 CHANNEL_NUMBER extracted", "1", s88.chan !== null ? "1" : "0");
509
510    // IC ref inline @E 步骤 35(IC2 → PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR, K row 2):MTD_SELECT(K 语料机械展开)
511    // CLA = bound channel (cla_rule) and <L> length binding are CasBind internal state (chaining rule; no generated-code re-implementation).
512    var s89 = bind.sendApdu(null, "A4", "04", "00", "A0000005591010FFFFFFFF8900000100", null, "9000");
513    // 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.
514    bind.checkData("IC35-IC2-K2-C4 SW", "9000", s89.sw);
515
516    // 步骤 36:SEQ07-4] MTD_STORE_DATA(tc_step)
517    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
518    var sdCla36 = s88.chan !== null ? (s88.chan <= 3 ? 128 + s88.chan : 188 + s88.chan).toString(16).toUpperCase() : null;
519    // runtime-bound payload: ISD_P_AID1 stays in execution domain
520    var s36 = bind.sendApdu(sdCla36, "E2", "91", "00", BindEs10xProcProfileDynamic.bindProfileAidTemplate(bind, "ISD_P_AID1", "BF2D16A0124F10", "", profileAidSession), "00", "9000");
521    bind.checkData("S35-C1 SW", "9000", s36.sw);
522    BindEs10xProcProfileDynamic.assertBoundPayload(bind, "ISD_P_AID1", s36.cmd, profileAidSession);
523    var r2p36 = BindEs10xProcProfile.walkChoiceList(s36.resp, {respTag: "BF2D", okTag: "A0", errTag: "81"});
524    var r2has36_0 = false;
525    for (var r2i36_0 = 0; r2i36_0 < r2p36.elements.length; r2i36_0++) {
526        var f = r2p36.elements[r2i36_0].fields;
527        if (f["5A"] === "989209012143658709F5" && f["9F70"] === "00") { r2has36_0 = true; break; }
528    }
529    bind.checkData("S35-C2 contains PROFILE_INFO1_DISABLED", "1", (r2p36.branch_tag === "A0" && r2has36_0) ? "1" : "0");
530
531    // 步骤 37:SEQ07-5] [SELECT_ICCID(tc_step;REQ: RQ24_025)
532    var s37 = bind.sendApdu("00", "A4", "00", "0C", "2FE2", null, "6A82");
533    bind.checkData("S36-C1 SW", "6A82", s37.sw);
534
535    // 步骤 38:SEQ08-IC3] MTD_SEND_SMS_PP(tc_step)
536    // MTD_SEND_SMS_PP ENVELOPE (H Annex C.1 表1238 Details: 80 C2 00 00 <L>): SCP80-packed SMS-PP body is runtime-domain
537    // (<MNO_SCP80_COUNTER>/<CC>/<C_APDUS_SCRIPT>) — no bytes fabricated; the embedded STORE DATA
538    // script executes via the proactive FETCH / TERMINAL RESPONSE chain, not in this response.
539    var s38 = bind.sendApdu("80", "C2", "00", "00", null, null, null);
540    bind.checkData("S37-C1 SW1 91", "91", s38.sw.substring(0, 2));
541
542    // 步骤 39:SEQ08-1] MTD_STORE_DATA(tc_step)
543    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
544    var sdCla39 = s88.chan !== null ? (s88.chan <= 3 ? 128 + s88.chan : 188 + s88.chan).toString(16).toUpperCase() : null;
545    // runtime-bound payload: ISD_P_AID1 stays in execution domain
546    var s39 = bind.sendApdu(sdCla39, "E2", "91", "00", BindEs10xProcProfileDynamic.bindProfileAidTemplate(bind, "ISD_P_AID1", "BF32154F10", "010100", profileAidSession), "00", "9000");
547    bind.checkData("S38-C1 SW", "9000", s39.sw);
548    BindEs10xProcProfileDynamic.assertBoundPayload(bind, "ISD_P_AID1", s39.cmd, profileAidSession);
549    var r2w39 = BindGecaProc.parseGecaResponse(s39.resp, {outer: "BF32", required: ["80"]});
550    bind.checkData("S38-C2 DisableResult ok", "00", (r2w39.ok && r2w39.fields["80"] === "00") ? "00" : (r2w39.fields["80"] || "absent"));
551
552    // 步骤 40:SEQ08-2] MTD_STORE_DATA(tc_step)
553    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
554    var sdCla40 = s88.chan !== null ? (s88.chan <= 3 ? 128 + s88.chan : 188 + s88.chan).toString(16).toUpperCase() : null;
555    // runtime-bound payload: ISD_P_AID1 stays in execution domain
556    var s40 = bind.sendApdu(sdCla40, "E2", "91", "00", BindEs10xProcProfileDynamic.bindProfileAidTemplate(bind, "ISD_P_AID1", "BF2D16A0124F10", "", profileAidSession), "00", "9000");
557    bind.checkData("S39-C1 SW", "9000", s40.sw);
558    BindEs10xProcProfileDynamic.assertBoundPayload(bind, "ISD_P_AID1", s40.cmd, profileAidSession);
559    var r2p40 = BindEs10xProcProfile.walkChoiceList(s40.resp, {respTag: "BF2D", okTag: "A0", errTag: "81"});
560    var r2has40_0 = false;
561    for (var r2i40_0 = 0; r2i40_0 < r2p40.elements.length; r2i40_0++) {
562        var f = r2p40.elements[r2i40_0].fields;
563        if (f["5A"] === "989209012143658709F5" && f["9F70"] === "00") { r2has40_0 = true; break; }
564    }
565    bind.checkData("S39-C2 contains PROFILE_INFO1_DISABLED", "1", (r2p40.branch_tag === "A0" && r2has40_0) ? "1" : "0");
566
567    // 步骤 41:SEQ08-3] [SELECT_ICCID(tc_step;REQ: RQ24_025)
568    var s41 = bind.sendApdu("00", "A4", "00", "0C", "2FE2", null, "6A82");
569    bind.checkData("S40-C1 SW", "6A82", s41.sw);
570
571    // 步骤 42:SEQ09-IC3] MTD_SEND_SMS_PP(tc_step)
572    // MTD_SEND_SMS_PP ENVELOPE (H Annex C.1 表1238 Details: 80 C2 00 00 <L>): SCP80-packed SMS-PP body is runtime-domain
573    // (<MNO_SCP80_COUNTER>/<CC>/<C_APDUS_SCRIPT>) — no bytes fabricated; the embedded STORE DATA
574    // script executes via the proactive FETCH / TERMINAL RESPONSE chain, not in this response.
575    var s42 = bind.sendApdu("80", "C2", "00", "00", null, null, null);
576    bind.checkData("S41-C1 SW1 91", "91", s42.sw.substring(0, 2));
577
578    // 步骤 43:SEQ09-1] FETCH ‘XX’(tc_step)
579    // FETCH header literals follow the golden wire evidence 8012 (same
580    // anchor as runToSteadyState; J Annex D.4 has no FETCH row, D 2.2.2
581    // gives mechanism only). Le = pending length from the last 91XX
582    // (chain rule, binding-internal state).
583    var s43 = bind.fetchPending("80", "12", "00", "00", null);
584    bind.checkData("S42-C1 proactive command envelope", "1", (s43.resp.length >= 4 && s43.resp.substring(0, 2) === "D0") ? "1" : "0");
585    // S42-C1: REFRESH type/mode bytes are not corpus-fixed (envelope face only; per-mode bytes absent from input).
586    // S43:主动会话协议闭合(TS 102 223 §6.3:主动命令必须 TR 应答;
587    // UICC Reset 变体 E 表无 TR 行属编辑省略,golden U3 线证同构)。
588    var s43tr = bind.terminalResponseForPending("80", "14", "00", "00", "9000");
589
590    // 步骤 44:SEQ09-2] MTD_STORE_DATA(tc_step)
591    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
592    var sdCla44 = s88.chan !== null ? (s88.chan <= 3 ? 128 + s88.chan : 188 + s88.chan).toString(16).toUpperCase() : null;
593    // runtime-bound payload: ISD_P_AID1 stays in execution domain
594    var s44 = bind.sendApdu(sdCla44, "E2", "91", "00", BindEs10xProcProfileDynamic.bindProfileAidTemplate(bind, "ISD_P_AID1", "BF32154F10", "0101FF", profileAidSession), "00", "9000");
595    bind.checkData("S43-C1 SW", "9000", s44.sw);
596    BindEs10xProcProfileDynamic.assertBoundPayload(bind, "ISD_P_AID1", s44.cmd, profileAidSession);
597    var r2w44 = BindGecaProc.parseGecaResponse(s44.resp, {outer: "BF32", required: ["80"]});
598    bind.checkData("S43-C2 DisableResult ok", "00", (r2w44.ok && r2w44.fields["80"] === "00") ? "00" : (r2w44.fields["80"] || "absent"));
599
600    // 步骤 45:SEQ09-3] TERMINAL RESPONSE(tc_step)
601    // TERMINAL RESPONSE data is dynamically built by the binding from the
602    // last FETCHed proactive command (D 2.2.2; buildTrData) - never static.
603    // Header literals follow the golden wire evidence 8014.
604    var s45 = bind.terminalResponseForPending("80", "14", "00", "00", null);
605    bind.checkData("S44-C1 SW1 91", "91", s45.sw.substring(0, 2));
606
607    // 步骤 46:SEQ09-4] FETCH 'YY'(tc_step;REQ: RQ32_016_3, RQ32_017, RQ57_134)
608    // FETCH header literals follow the golden wire evidence 8012 (same
609    // anchor as runToSteadyState; J Annex D.4 has no FETCH row, D 2.2.2
610    // gives mechanism only). Le = pending length from the last 91XX
611    // (chain rule, binding-internal state).
612    var s46 = bind.fetchPending("80", "12", "00", "00", null);
613    bind.checkData("S45-C1 proactive command envelope", "1", (s46.resp.length >= 4 && s46.resp.substring(0, 2) === "D0") ? "1" : "0");
614    // S45-C1: REFRESH type/mode bytes are not corpus-fixed (envelope face only; per-mode bytes absent from input).
615    // S46:主动会话协议闭合(TS 102 223 §6.3:主动命令必须 TR 应答;
616    // UICC Reset 变体 E 表无 TR 行属编辑省略,golden U3 线证同构)。
617    var s46tr = bind.terminalResponseForPending("80", "14", "00", "00", "9000");
618
619    // IC ref inline @E 步骤 47(IC1 → PROC_EUICC_INITIALIZATION_SEQUENCE, K row 1):RESET(K 语料机械展开)
620    var s90 = bind.resetAndAtr();
621    bind.checkData("IC47-IC1-K1-C1 ATR_present", "1", s90.atr_hex !== "" ? "1" : "0");
622
623    // IC ref inline @E 步骤 47(IC1 → PROC_EUICC_INITIALIZATION_SEQUENCE, K row 2):SELECT_MF(K 语料机械展开)
624    // FCP outer tag not materialized from clause: tag-face asserted only when corpus fixes the tag byte (e.g. TS 102 221 FCP '62').
625    var s91 = bind.sendApdu("00", "A4", "00", "04", "3F00", "00", "9000");
626    bind.checkData("IC47-IC1-K2-C2 FCP_Template", "1", s91.resp.length > 0 ? "1" : "0");
627    bind.checkData("IC47-IC1-K2-C4 SW", "9000", s91.sw);
628
629    // IC ref inline @E 步骤 47(IC1 → PROC_EUICC_INITIALIZATION_SEQUENCE, K row 3):TERMINAL_CAPABILITY_LPAd(K 语料机械展开)
630    var s92 = bind.sendApdu("80", "AA", "00", "00", "A9058100830107", null, "9000");
631    bind.checkData("IC47-IC1-K3-C4 SW", "9000", s92.sw);
632
633    // IC ref inline @E 步骤 47(IC1 → PROC_EUICC_INITIALIZATION_SEQUENCE, K row 4):TERMINAL_PROFILE(K 语料机械展开)
634    var steady93 = bind.runToSteadyState(function () {
635        return bind.sendTerminalProfile("FFFFFFFF7F9D00DFBF00001FE2000000C7EB0000000168005000000000000200", "9000");
636    });
637    bind.checkData("IC47-IC1-K4-C4 final SW", "9000", steady93.final.sw);
638
639    // IC ref inline @E 步骤 47(IC2 → PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR, K row 1):MANAGE_CHANNEL_OPEN(K 语料机械展开)
640    // CHANNEL_NUMBER extraction and dynamic CLA rebinding are CasBind internal state (chaining rule; no generated-code re-implementation).
641    var s94 = bind.manageChannelOpen("9000");
642    bind.checkData("IC47-IC2-K1-C4 SW", "9000", s94.sw);
643    bind.checkData("IC47-IC2-K1-C3 CHANNEL_NUMBER extracted", "1", s94.chan !== null ? "1" : "0");
644
645    // IC ref inline @E 步骤 47(IC2 → PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR, K row 2):MTD_SELECT(K 语料机械展开)
646    // CLA = bound channel (cla_rule) and <L> length binding are CasBind internal state (chaining rule; no generated-code re-implementation).
647    var s95 = bind.sendApdu(null, "A4", "04", "00", "A0000005591010FFFFFFFF8900000100", null, "9000");
648    // 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.
649    bind.checkData("IC47-IC2-K2-C4 SW", "9000", s95.sw);
650
651    // 步骤 48:SEQ09-6] MTD_STORE_DATA(tc_step)
652    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
653    var sdCla48 = s94.chan !== null ? (s94.chan <= 3 ? 128 + s94.chan : 188 + s94.chan).toString(16).toUpperCase() : null;
654    // runtime-bound payload: ISD_P_AID1 stays in execution domain
655    var s48 = bind.sendApdu(sdCla48, "E2", "91", "00", BindEs10xProcProfileDynamic.bindProfileAidTemplate(bind, "ISD_P_AID1", "BF2D16A0124F10", "", profileAidSession), "00", "9000");
656    bind.checkData("S47-C1 SW", "9000", s48.sw);
657    BindEs10xProcProfileDynamic.assertBoundPayload(bind, "ISD_P_AID1", s48.cmd, profileAidSession);
658    var r2p48 = BindEs10xProcProfile.walkChoiceList(s48.resp, {respTag: "BF2D", okTag: "A0", errTag: "81"});
659    var r2has48_0 = false;
660    for (var r2i48_0 = 0; r2i48_0 < r2p48.elements.length; r2i48_0++) {
661        var f = r2p48.elements[r2i48_0].fields;
662        if (f["5A"] === "989209012143658709F5" && f["9F70"] === "00") { r2has48_0 = true; break; }
663    }
664    bind.checkData("S47-C2 contains PROFILE_INFO1_DISABLED", "1", (r2p48.branch_tag === "A0" && r2has48_0) ? "1" : "0");
665
666    // 步骤 49:SEQ09-7] [SELECT_ICCID(tc_step;REQ: RQ24_025)
667    var s49 = bind.sendApdu("00", "A4", "00", "0C", "2FE2", null, "6A82");
668    bind.checkData("S48-C1 SW", "6A82", s49.sw);
669
670    // 步骤 50:SEQ10-IC3] MTD_SEND_SMS_PP(tc_step)
671    // MTD_SEND_SMS_PP ENVELOPE (H Annex C.1 表1238 Details: 80 C2 00 00 <L>): SCP80-packed SMS-PP body is runtime-domain
672    // (<MNO_SCP80_COUNTER>/<CC>/<C_APDUS_SCRIPT>) — no bytes fabricated; the embedded STORE DATA
673    // script executes via the proactive FETCH / TERMINAL RESPONSE chain, not in this response.
674    var s50 = bind.sendApdu("80", "C2", "00", "00", null, null, null);
675    bind.checkData("S49-C1 SW1 91", "91", s50.sw.substring(0, 2));
676
677    // 步骤 51:SEQ10-1] FETCH ‘XX’(tc_step)
678    // FETCH header literals follow the golden wire evidence 8012 (same
679    // anchor as runToSteadyState; J Annex D.4 has no FETCH row, D 2.2.2
680    // gives mechanism only). Le = pending length from the last 91XX
681    // (chain rule, binding-internal state).
682    var s51 = bind.fetchPending("80", "12", "00", "00", null);
683    bind.checkData("S50-C1 proactive command envelope", "1", (s51.resp.length >= 4 && s51.resp.substring(0, 2) === "D0") ? "1" : "0");
684    // S50-C1: REFRESH type/mode bytes are not corpus-fixed (envelope face only; per-mode bytes absent from input).
685    // S51:主动会话协议闭合(TS 102 223 §6.3:主动命令必须 TR 应答;
686    // UICC Reset 变体 E 表无 TR 行属编辑省略,golden U3 线证同构)。
687    var s51tr = bind.terminalResponseForPending("80", "14", "00", "00", "9000");
688
689    // 步骤 52:SEQ10-2] MTD_STORE_DATA(tc_step)
690    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
691    var sdCla52 = s94.chan !== null ? (s94.chan <= 3 ? 128 + s94.chan : 188 + s94.chan).toString(16).toUpperCase() : null;
692    // runtime-bound payload: ISD_P_AID1 stays in execution domain
693    var s52 = bind.sendApdu(sdCla52, "E2", "91", "00", BindEs10xProcProfileDynamic.bindProfileAidTemplate(bind, "ISD_P_AID1", "BF32154F10", "010100", profileAidSession), "00", "9000");
694    bind.checkData("S51-C1 SW", "9000", s52.sw);
695    BindEs10xProcProfileDynamic.assertBoundPayload(bind, "ISD_P_AID1", s52.cmd, profileAidSession);
696    var r2w52 = BindGecaProc.parseGecaResponse(s52.resp, {outer: "BF32", required: ["80"]});
697    bind.checkData("S51-C2 DisableResult ok", "00", (r2w52.ok && r2w52.fields["80"] === "00") ? "00" : (r2w52.fields["80"] || "absent"));
698
699    // 步骤 53:SEQ10-3] TERMINAL RESPONSE(tc_step)
700    // TERMINAL RESPONSE data is dynamically built by the binding from the
701    // last FETCHed proactive command (D 2.2.2; buildTrData) - never static.
702    // Header literals follow the golden wire evidence 8014.
703    var s53 = bind.terminalResponseForPending("80", "14", "00", "00", null);
704    bind.checkData("S52-C1 SW1 != 91", "1", s53.sw.substring(0, 2) !== "91" ? "1" : "0");
705
706    // 步骤 54:SEQ10-4] MTD_STORE_DATA(tc_step)
707    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
708    var sdCla54 = s94.chan !== null ? (s94.chan <= 3 ? 128 + s94.chan : 188 + s94.chan).toString(16).toUpperCase() : null;
709    // runtime-bound payload: ISD_P_AID1 stays in execution domain
710    var s54 = bind.sendApdu(sdCla54, "E2", "91", "00", BindEs10xProcProfileDynamic.bindProfileAidTemplate(bind, "ISD_P_AID1", "BF2D16A0124F10", "", profileAidSession), "00", "9000");
711    bind.checkData("S53-C1 SW", "9000", s54.sw);
712    BindEs10xProcProfileDynamic.assertBoundPayload(bind, "ISD_P_AID1", s54.cmd, profileAidSession);
713    var r2p54 = BindEs10xProcProfile.walkChoiceList(s54.resp, {respTag: "BF2D", okTag: "A0", errTag: "81"});
714    var r2has54_0 = false;
715    for (var r2i54_0 = 0; r2i54_0 < r2p54.elements.length; r2i54_0++) {
716        var f = r2p54.elements[r2i54_0].fields;
717        if (f["5A"] === "989209012143658709F5" && f["9F70"] === "00") { r2has54_0 = true; break; }
718    }
719    bind.checkData("S53-C2 contains PROFILE_INFO1_DISABLED", "1", (r2p54.branch_tag === "A0" && r2has54_0) ? "1" : "0");
720
721    // 步骤 55:SEQ10-5] [SELECT_ICCID(tc_step;REQ: RQ24_025)
722    var s55 = bind.sendApdu("00", "A4", "00", "0C", "2FE2", null, "6A82");
723    bind.checkData("S54-C1 SW", "6A82", s55.sw);
724}
725

完整 unified diff

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

展开 diff(1586 行)
--- -man
+++ -cas
@@ -1,860 +1,725 @@
-// slice of Import\TestCase_SGP_23.js - cases: TC_eUICC_ES10c_DisableProfile_Case4_01_Nominal_Disable_Profile_by_ISD_P_AID_and_refreshFlag_set_when_Device_supports_UICC_Reset + TC_eUICC_ES10c_DisableProfile_Case4_02_Nominal_Disable_Profile_by_ICCID_and_refreshFlag_set_when_Device_supports_UICC_Reset + TC_eUICC_ES10c_DisableProfile_Case4_03_Nominal_Disable_Profile_by_ISD_P_AID_and_refreshFlag_set_when_Device_supports_eUICC_Profile_State_Change + TC_eUICC_ES10c_DisableProfile_Case4_04_Nominal_Disable_Profile_by_ICCID_and_refreshFlag_set_when_Device_supports_eUICC_Profile_State_Change + TC_eUICC_ES10c_DisableProfile_Case4_05_Nominal_Disable_Profile_by_ISD_P_AID_and_refreshFlag_not_set + TC_eUICC_ES10c_DisableProfile_Case4_06_Nominal_Disable_Profile_by_ICCID_and_refreshFlag_not_set + TC_eUICC_ES10c_DisableProfile_Case4_07_Nominal_Disable_Profile_by_ICCID_with_refreshFLag_set_while_proactive_sessionisongoing_catBusynotsupported + TC_eUICC_ES10c_DisableProfile_Case4_08_Nominal_Disable_Profile_by_ICCID_with_refreshFLag_not_set_while_proactive_sessionisongoing_catBusynotsupported + TC_eUICC_ES10c_DisableProfile_Case4_09_Nominal_Disable_Profile_by_ICCID_with_refreshFLag_set_while_proactive_sessionisongoing_withTerminalResponseoutstanding_catBusynotsupported + TC_eUICC_ES10c_DisableProfile_Case4_10_Nominal_Disable_Profile_by_ICCID_with_refreshFLag_not_set_while_proactive_sessionisongoing_withTerminalResponseoutstanding_catBusynotsupported (extracted verbatim)
-
-function TC_eUICC_ES10c_DisableProfile_Case4_01_Nominal_Disable_Profile_by_ISD_P_AID_and_refreshFlag_set_when_Device_supports_UICC_Reset()
-{
-	initial_condition_PROFILE_OPERATIONAL1_is_Enabled();
-	var ISD_P_Test01 = curProfile_ISD_P_AID;
-	
-	tracenamestr = "测试目的:设备支持 “UICC Reset”,通过ISD-P AID去失效profile,并设置refreshFlag";
-	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();
-	
-	curLogicChannel = 1;
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
-	TS_SELECT("Select ISD",ISD_R_AID,"9000");
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行DisableProfileRequest,refreshFlag为FF;");
-	var disableProRequest = new DisableProfileRequest();
-	disableProRequest.profileIdentifier = new ChoiceObj(tagOfProfileIdentifier.isdpAid,ISD_P_Test01);
-	disableProRequest.refreshFlag = BooleanValue_BerCode_True;
-	disableProRequest.GenHexData();
-	var respData = LPAd_Transport_data_to_eUICC(disableProRequest.hexData,"91","00","91XX");
-	
-	curStrHandle.CheckData("BF3203800100", respData, "DisableProfileResponse");
-	
-	curLogicChannel = 0;
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Fetch命令,主动式命令refresh;");
-	
-	FetchStr = Fetch("","9000","");
-		
-	var CmdDetails = GetValueByTag("01",1);
-	var CmdQualifier = CmdDetails.substr(4,2);
-	CheckData("04",CmdQualifier,"the command qualifier is equal to ’04’ (UICC Reset)");
-	
-	curLogicChannel = 0;
-	curDis.TestStepStart2(stno++,"eUICC卡片初始化;");
-	Ini_powerOn_eUICC_LPAe_not_activate();
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送MANAGE_CHANNEL命令,打开辅助逻辑通道;");
-	TS_MANAGE_CHANNEL_OPEN();
-	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.isdpAid,ISD_P_Test01);
-	proInfoListRequest.tagList = "5A4F9F70";
-	proInfoListRequest.GenHexData();
-	var respData = LPAd_Transport_data_to_eUICC(proInfoListRequest.hexData);
-
-	var proInfoListResponse = new  ProfileInfoListResponse();
-	proInfoListResponse.checkCardResDataFormat(respData);
-	
-	try
-	{
-		curStrHandle.CheckData(ICCID_OP_PROF1, proInfoListResponse.profileInfoListOk.arrOfElement[0].iccid, "ICCID");
-		curStrHandle.CheckData(ISD_P_Test01, proInfoListResponse.profileInfoListOk.arrOfElement[0].isdpAid, "ISD-P AID");
-		curStrHandle.CheckData(Profile_DISABLED, proInfoListResponse.profileInfoListOk.arrOfElement[0].profileState, "profile State");
-	}catch(e){
-		obj.SubLevel(ProfileInfoListResponse_Data_Error, level_of_SubLevel.error);
-	}
-	
-	curLogicChannel = 0;
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Select命令,选择ICCID;");
-	var para1 = new SelectFileEFPara_3G("2FE2");
-	para1.apdu.ressw = "6A82";
-	SendAPDU(para1.apdu);
-	
-	RecoverCard();
-}
-
-function TC_eUICC_ES10c_DisableProfile_Case4_02_Nominal_Disable_Profile_by_ICCID_and_refreshFlag_set_when_Device_supports_UICC_Reset()
-{
-	initial_condition_PROFILE_OPERATIONAL1_is_Enabled();
-	var ISD_P_Test01 = curProfile_ISD_P_AID;
-	
-	tracenamestr = "测试目的:设备支持 “UICC Reset”,通过ICCID去失效profile,并设置refreshFlag";
-	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();
-	
-	curLogicChannel = 1;
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
-	TS_SELECT("Select ISD",ISD_R_AID,"9000");
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行DisableProfileRequest,refreshFlag为FF;");
-	var disableProRequest = new DisableProfileRequest();
-	disableProRequest.profileIdentifier = new ChoiceObj(tagOfProfileIdentifier.iccid,ICCID_OP_PROF1);
-	disableProRequest.refreshFlag = BooleanValue_BerCode_True;
-	disableProRequest.GenHexData();
-	var respData = LPAd_Transport_data_to_eUICC(disableProRequest.hexData,"91","00","91XX");
-	
-	curStrHandle.CheckData("BF3203800100", respData, "DisableProfileResponse");
-	
-	curLogicChannel = 0;
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Fetch命令,主动式命令refresh;");
-	
-	FetchStr = Fetch("","9000","");
-		
-	var CmdDetails = GetValueByTag("01",1);
-	var CmdQualifier = CmdDetails.substr(4,2);
-	CheckData("04",CmdQualifier,"the command qualifier is equal to ’04’ (UICC Reset)");
-	
-	curLogicChannel = 0;
-	curDis.TestStepStart2(stno++,"eUICC卡片初始化;");
-	Ini_powerOn_eUICC_LPAe_not_activate();
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送MANAGE_CHANNEL命令,打开辅助逻辑通道;");
-	TS_MANAGE_CHANNEL_OPEN();
-	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 = "5A4F9F70";
-	proInfoListRequest.GenHexData();
-	var respData = LPAd_Transport_data_to_eUICC(proInfoListRequest.hexData);
-
-	var proInfoListResponse = new  ProfileInfoListResponse();
-	proInfoListResponse.checkCardResDataFormat(respData);
-	
-	try
-	{
-		curStrHandle.CheckData(ICCID_OP_PROF1, proInfoListResponse.profileInfoListOk.arrOfElement[0].iccid, "ICCID");
-		curStrHandle.CheckData(ISD_P_Test01, proInfoListResponse.profileInfoListOk.arrOfElement[0].isdpAid, "ISD-P AID");
-		curStrHandle.CheckData(Profile_DISABLED, proInfoListResponse.profileInfoListOk.arrOfElement[0].profileState, "profile State");
-	}catch(e){
-		obj.SubLevel(ProfileInfoListResponse_Data_Error, level_of_SubLevel.error);
-	}
-	
-	curLogicChannel = 0;
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Select命令,选择ICCID;");
-	var para1 = new SelectFileEFPara_3G("2FE2");
-	para1.apdu.ressw = "6A82";
-	SendAPDU(para1.apdu);
-	
-	RecoverCard();
-}
-
-function TC_eUICC_ES10c_DisableProfile_Case4_03_Nominal_Disable_Profile_by_ISD_P_AID_and_refreshFlag_set_when_Device_supports_eUICC_Profile_State_Change()
-{
-	initial_condition_PROFILE_OPERATIONAL1_is_Enabled();
-	var ISD_P_Test01 = curProfile_ISD_P_AID;
-	
-	tracenamestr = "测试目的:设备支持 “eUICC Profile State Change”,通过ISD-P AID去失效profile,并设置refreshFlag";
-	curDis.TraceStart(sno++,tracenamestr);
-	
-	curLogicChannel = 0;
-	curDis.TestStepStart2(stno++,"eUICC卡片初始化;");
-	TERMINAL_PROFILE_Default = TERMINAL_PROFILE_eUICCProfileStateChanged;
-	Ini_powerOn_eUICC_LPAe_not_activate();
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送MANAGE_CHANNEL命令,打开辅助逻辑通道;");
-	TS_MANAGE_CHANNEL_OPEN();
-	
-	curLogicChannel = 1;
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
-	TS_SELECT("Select ISD",ISD_R_AID,"9000");
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行DisableProfileRequest,设备支持eUICC Profile State Change,通过ISD-P AID失效profile时配置了refreshFlag的测试;");
-	var disableProRequest = new DisableProfileRequest();
-	disableProRequest.profileIdentifier = new ChoiceObj(tagOfProfileIdentifier.isdpAid,ISD_P_Test01);
-	disableProRequest.refreshFlag = BooleanValue_BerCode_True;
-	disableProRequest.GenHexData();
-	var respData = LPAd_Transport_data_to_eUICC(disableProRequest.hexData,"91","00","91XX");
-	
-	curStrHandle.CheckData("BF3203800100", respData, "DisableProfileResponse");
-	
-	curLogicChannel = 0;
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Fetch命令,主动式命令refresh;");
-	
-	FetchStr = Fetch("","9000","");
-		
-	var CmdDetails = GetValueByTag("01",1);
-	var CmdQualifier = CmdDetails.substr(4,2);
-	CheckData("09",CmdQualifier,"the command qualifier is equal to ’09’ (eUICC Profile State Change)");
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送TerminalResponse命令;");
-	TerminalResponse("00","9000");
-	
-	curLogicChannel = 0;
-	curDis.TestStepStart2(stno++,"eUICC卡片初始化;");
-	if (check_eUICC_support_TERMINAL_CAPABILITY_cmd())
-		TS_TERMINAL_CAPABILITY_cmd();
-	else
-		obj.SubLevel("eUICC不支持”TERMINAL_CAPABILITY“命令", level_of_SubLevel.warning);
-	
-	IniCard_SetUpMenu("",1);
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送MANAGE_CHANNEL命令,打开辅助逻辑通道;");
-	var Logicnum = TS_MANAGE_CHANNEL_OPEN();
-	
-	curLogicChannel = parseInt(Logicnum,16);
-	
-	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.isdpAid,ISD_P_Test01);
-	proInfoListRequest.tagList = "5A4F9F70";
-	proInfoListRequest.GenHexData();
-	var respData = LPAd_Transport_data_to_eUICC(proInfoListRequest.hexData);
-	
-	var proInfoListResponse = new  ProfileInfoListResponse();
-	proInfoListResponse.checkCardResDataFormat(respData);
-	
-	try
-	{
-		curStrHandle.CheckData(ICCID_OP_PROF1, proInfoListResponse.profileInfoListOk.arrOfElement[0].iccid, "ICCID");
-		curStrHandle.CheckData(ISD_P_Test01, proInfoListResponse.profileInfoListOk.arrOfElement[0].isdpAid, "ISD-P AID");
-		curStrHandle.CheckData(Profile_DISABLED, proInfoListResponse.profileInfoListOk.arrOfElement[0].profileState, "profile State");
-	}catch(e){
-		obj.SubLevel(ProfileInfoListResponse_Data_Error, level_of_SubLevel.error);
-	}
-	
-	curLogicChannel = 0;
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Select命令,选择ICCID;");
-	var para1 = new SelectFileEFPara_3G("2FE2");
-	para1.apdu.ressw = "6A82";
-	SendAPDU(para1.apdu);
-	
-	RecoverCard();
-	
-	
-}
-
-function TC_eUICC_ES10c_DisableProfile_Case4_04_Nominal_Disable_Profile_by_ICCID_and_refreshFlag_set_when_Device_supports_eUICC_Profile_State_Change()
-{
-	initial_condition_PROFILE_OPERATIONAL1_is_Enabled();
-	var ISD_P_Test01 = curProfile_ISD_P_AID;
-	
-	tracenamestr = "测试目的:设备支持 “eUICC Profile State Change”,通过ICCID去失效profile,并设置refreshFlag";
-	curDis.TraceStart(sno++,tracenamestr);
-	
-	curLogicChannel = 0;
-	curDis.TestStepStart2(stno++,"eUICC卡片初始化;");
-	TERMINAL_PROFILE_Default = TERMINAL_PROFILE_eUICCProfileStateChanged;
-	Ini_powerOn_eUICC_LPAe_not_activate();
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送MANAGE_CHANNEL命令,打开辅助逻辑通道;");
-	TS_MANAGE_CHANNEL_OPEN();
-	
-	curLogicChannel = 1;
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
-	TS_SELECT("Select ISD",ISD_R_AID,"9000");
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行DisableProfileRequest,设备支持eUICC Profile State Change,通过ICCID失效profile时配置了refreshFlag的测试;");
-	var disableProRequest = new DisableProfileRequest();
-	disableProRequest.profileIdentifier = new ChoiceObj(tagOfProfileIdentifier.iccid,ICCID_OP_PROF1);
-	disableProRequest.refreshFlag = BooleanValue_BerCode_True;
-	disableProRequest.GenHexData();
-	var respData = LPAd_Transport_data_to_eUICC(disableProRequest.hexData,"91","00","91XX");
-	
-	curStrHandle.CheckData("BF3203800100", respData, "DisableProfileResponse");
-	
-	curLogicChannel = 0;
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Fetch命令,主动式命令refresh;");
-	
-	FetchStr = Fetch("","9000","");
-		
-	var CmdDetails = GetValueByTag("01",1);
-	var CmdQualifier = CmdDetails.substr(4,2);
-	CheckData("09",CmdQualifier,"the command qualifier is equal to ’09’ (eUICC Profile State Change)");
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送TerminalResponse命令;");
-	TerminalResponse("00","9000");
-	
-	curLogicChannel = 0;
-	curDis.TestStepStart2(stno++,"eUICC卡片初始化;");
-	if (check_eUICC_support_TERMINAL_CAPABILITY_cmd())
-		TS_TERMINAL_CAPABILITY_cmd();
-	else
-		obj.SubLevel("eUICC不支持”TERMINAL_CAPABILITY“命令", level_of_SubLevel.warning);
-	
-	IniCard_SetUpMenu("",1);
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送MANAGE_CHANNEL命令,打开辅助逻辑通道;");
-	var Logicnum = TS_MANAGE_CHANNEL_OPEN();
-	
-	curLogicChannel = parseInt(Logicnum,16);
-	
-	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 = "5A4F9F70";
-	proInfoListRequest.GenHexData();
-	var respData = LPAd_Transport_data_to_eUICC(proInfoListRequest.hexData);
-	
-	var proInfoListResponse = new  ProfileInfoListResponse();
-	proInfoListResponse.checkCardResDataFormat(respData);
-	
-	try
-	{
-		curStrHandle.CheckData(ICCID_OP_PROF1, proInfoListResponse.profileInfoListOk.arrOfElement[0].iccid, "ICCID");
-		curStrHandle.CheckData(ISD_P_Test01, proInfoListResponse.profileInfoListOk.arrOfElement[0].isdpAid, "ISD-P AID");
-		curStrHandle.CheckData(Profile_DISABLED, proInfoListResponse.profileInfoListOk.arrOfElement[0].profileState, "profile State");
-	}catch(e){
-		obj.SubLevel(ProfileInfoListResponse_Data_Error, level_of_SubLevel.error);
-	}
-	
-	curLogicChannel = 0;
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Select命令,选择ICCID;");
-	var para1 = new SelectFileEFPara_3G("2FE2");
-	para1.apdu.ressw = "6A82";
-	SendAPDU(para1.apdu);
-	
-	RecoverCard();
-	
-	
-}
-
-function TC_eUICC_ES10c_DisableProfile_Case4_05_Nominal_Disable_Profile_by_ISD_P_AID_and_refreshFlag_not_set()
-{
-	if(!Card_Have_ECC_Cert)
-		return;
-	
-	TestOfMEPMode = 0;	
-
-	initial_condition_PROFILE_OPERATIONAL1_is_Enabled();
-	var ISD_P_Test01 = curProfile_ISD_P_AID;
-	
-	tracenamestr = "测试目的:通过ISD-P AID去失效profile,不设置refreshFlag";
-	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();
-	
-	curLogicChannel = 1;
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
-	TS_SELECT("Select ISD",ISD_R_AID,"9000");
-	
-
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行DisableProfileRequest,refreshFlag为False;"); 
-	var disableProRequest = new DisableProfileRequest();
-	disableProRequest.profileIdentifier = new ChoiceObj(tagOfProfileIdentifier.isdpAid,ISD_P_Test01);
-	disableProRequest.refreshFlag = BooleanValue_BerCode_False;
-	disableProRequest.GenHexData();
-	var respData = LPAd_Transport_data_to_eUICC(disableProRequest.hexData,"91","00","9000");
-	
-    curStrHandle.CheckData("BF3203800100", respData, "DisableProfileResponse");	
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 TERMINAL_PROFILE命令;");
-	IniCard_SetUpMenu("",1);
-	
-
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送MANAGE_CHANNEL命令,打开辅助逻辑通道;");
-	TS_MANAGE_CHANNEL_OPEN();
-	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.isdpAid,ISD_P_Test01);
-	proInfoListRequest.tagList = "5A4F9F70";
-	proInfoListRequest.GenHexData();
-	var respData = LPAd_Transport_data_to_eUICC(proInfoListRequest.hexData);
-	
-
-	var proInfoListResponse = new  ProfileInfoListResponse();
-	proInfoListResponse.checkCardResDataFormat(respData);
-	
-	try
-	{
-		curStrHandle.CheckData(ICCID_OP_PROF1, proInfoListResponse.profileInfoListOk.arrOfElement[0].iccid, "ICCID");
-		curStrHandle.CheckData(ISD_P_Test01, proInfoListResponse.profileInfoListOk.arrOfElement[0].isdpAid, "ISD-P AID");
-		curStrHandle.CheckData(Profile_DISABLED, proInfoListResponse.profileInfoListOk.arrOfElement[0].profileState, "profile State");
-	}catch(e){
-		obj.SubLevel(ProfileInfoListResponse_Data_Error, level_of_SubLevel.error);
-	}
-	
-	curLogicChannel = 0;
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Select命令,选择ICCID;");
-	var para1 = new SelectFileEFPara_3G("2FE2");
-	para1.apdu.ressw = "6A82";
-	SendAPDU(para1.apdu);
-	
-	RecoverCard();
-	
-}
-
-function TC_eUICC_ES10c_DisableProfile_Case4_06_Nominal_Disable_Profile_by_ICCID_and_refreshFlag_not_set()
-{
-	if(!Card_Have_ECC_Cert)
-		return;
-	
-	TestOfMEPMode = 0;	
-
-	initial_condition_PROFILE_OPERATIONAL1_is_Enabled();
-	var ISD_P_Test01 = curProfile_ISD_P_AID;
-	
-	tracenamestr = "测试目的:通过ICCID去失效profile,不设置refreshFlag";
-	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();
-	
-	curLogicChannel = 1;
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
-	TS_SELECT("Select ISD",ISD_R_AID,"9000");
-	
-
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行DisableProfileRequest,refreshFlag为False;");
-
-	var disableProRequest = new DisableProfileRequest();
-	disableProRequest.profileIdentifier = new ChoiceObj(tagOfProfileIdentifier.iccid,ICCID_OP_PROF1);
-	disableProRequest.refreshFlag = BooleanValue_BerCode_False;
-	disableProRequest.GenHexData();
-	var respData = LPAd_Transport_data_to_eUICC(disableProRequest.hexData,"91","00","9000");
-	
-    curStrHandle.CheckData("BF3203800100", respData, "DisableProfileResponse");	
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 TERMINAL_PROFILE命令;");
-	IniCard_SetUpMenu("",1);
-	
-
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送MANAGE_CHANNEL命令,打开辅助逻辑通道;");
-	TS_MANAGE_CHANNEL_OPEN();
-	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 = "5A4F9F70";
-	proInfoListRequest.GenHexData();
-	var respData = LPAd_Transport_data_to_eUICC(proInfoListRequest.hexData);
-	
-
-	var proInfoListResponse = new  ProfileInfoListResponse();
-	proInfoListResponse.checkCardResDataFormat(respData);
-	
-	try
-	{
-		curStrHandle.CheckData(ICCID_OP_PROF1, proInfoListResponse.profileInfoListOk.arrOfElement[0].iccid, "ICCID");
-		curStrHandle.CheckData(ISD_P_Test01, proInfoListResponse.profileInfoListOk.arrOfElement[0].isdpAid, "ISD-P AID");
-		curStrHandle.CheckData(Profile_DISABLED, proInfoListResponse.profileInfoListOk.arrOfElement[0].profileState, "profile State");
-	}catch(e){
-		obj.SubLevel(ProfileInfoListResponse_Data_Error, level_of_SubLevel.error);
-	}
-	
-	curLogicChannel = 0;
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Select命令,选择ICCID;");
-	var para1 = new SelectFileEFPara_3G("2FE2");
-	para1.apdu.ressw = "6A82";
-	SendAPDU(para1.apdu);
-	
-	RecoverCard();
-	
-}
-
-function TC_eUICC_ES10c_DisableProfile_Case4_07_Nominal_Disable_Profile_by_ICCID_with_refreshFLag_set_while_proactive_sessionisongoing_catBusynotsupported()
-{
-
-	//测试入口条件
-	if(!check_Applicability_of_tests_RSP_SGP23_test("C033"))
-		return;
-	
-	initial_condition_PROFILE_OPERATIONAL1_is_Enabled();
-	var ISD_P_Test01 = curProfile_ISD_P_AID;
-	
-
-	tracenamestr = "测试目的:eUICC不支持catBusy,主动式会话进行中时,通过ISD-P AID去失效profile,并设置refreshFlag";
-	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();
-	curLogicChannel = 1;
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
-	TS_SELECT("Select ISD",ISD_R_AID,"9000");
-	
-	curLogicChannel = 0;
-	var sSendType = SendTypeByOTA.SMS;
-	KIC = MNO_SCP80_ENC_KEY;
-	KID = MNO_SCP80_AUTH_KEY;
-	KIK = MNO_SCP80_DATA_ENC_KEY;
-	curDis.TestStepStart2(stno++,"SCP80,发送get status命令,使用MNO-SD的tar");
-	sAPDU = "80F28002024F00";
-	SendMessageToCard_GP(sSendType,"91XX",0,"B20100","12210015",sAPDU);
-	HaveReEntry91XX = true;
-	var ss = obj.GetState();
-	ReEntry91XXLength = ss.substr(2,2);
-	
-	curLogicChannel = 1;
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行DisableProfileRequest,refreshFlag为FF;");
-	var disableProRequest = new DisableProfileRequest();
-	disableProRequest.profileIdentifier = new ChoiceObj(tagOfProfileIdentifier.iccid,ICCID_OP_PROF1);
-	disableProRequest.refreshFlag = BooleanValue_BerCode_True;
-	disableProRequest.GenHexData();
-	var respData = LPAd_Transport_data_to_eUICC(disableProRequest.hexData,"91","00","91XX");
-	curStrHandle.CheckData("BF3203800100", respData, "DisableProfileResponse");
-	
-	curLogicChannel = 0;
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Fetch命令,主动式命令refresh;");
-	FetchStr = Fetch("","9000","");
-		
-	var CmdDetails = GetValueByTag("01",1);
-	var CmdQualifier = CmdDetails.substr(4,2);
-	CheckData("04",CmdQualifier,"the command qualifier is equal to ’04’ (UICC Reset)");
-	
-	
-	curLogicChannel = 0;
-	curDis.TestStepStart2(stno++,"eUICC卡片初始化;");
-	Ini_powerOn_eUICC_LPAe_not_activate();
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送MANAGE_CHANNEL命令,打开辅助逻辑通道;");
-	TS_MANAGE_CHANNEL_OPEN();
-
-	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 = "5A4F9F70";
-	proInfoListRequest.GenHexData();
-	var respData = LPAd_Transport_data_to_eUICC(proInfoListRequest.hexData);
-	
-	var proInfoListResponse = new  ProfileInfoListResponse();
-	proInfoListResponse.checkCardResDataFormat(respData);
-	
-	try
-	{
-		curStrHandle.CheckData(ICCID_OP_PROF1, proInfoListResponse.profileInfoListOk.arrOfElement[0].iccid, "ICCID");
-		curStrHandle.CheckData(ISD_P_Test01, proInfoListResponse.profileInfoListOk.arrOfElement[0].isdpAid, "ISD-P AID");
-		curStrHandle.CheckData(Profile_DISABLED, proInfoListResponse.profileInfoListOk.arrOfElement[0].profileState, "profile State");
-	}catch(e){
-		obj.SubLevel(ProfileInfoListResponse_Data_Error, level_of_SubLevel.error);
-	}
-
-    curLogicChannel = 0;
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Select命令,选择ICCID;");
-	var para1 = new SelectFileEFPara_3G("2FE2");
-	para1.apdu.ressw = "6A82";
-	SendAPDU(para1.apdu);
-	
-	RecoverCard();
-}
-
-function TC_eUICC_ES10c_DisableProfile_Case4_08_Nominal_Disable_Profile_by_ICCID_with_refreshFLag_not_set_while_proactive_sessionisongoing_catBusynotsupported()
-{
-
-	//测试入口条件
-	if(!check_Applicability_of_tests_RSP_SGP23_test("C033"))
-		return;
-	
-	initial_condition_PROFILE_OPERATIONAL1_is_Enabled();
-	var ISD_P_Test01 = curProfile_ISD_P_AID;
-	
-
-	tracenamestr = "测试目的:eUICC不支持catBusy,主动式会话进行中时,通过ISD-P AID去失效profile,不设置refreshFlag";
-	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();
-	curLogicChannel = 1;
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
-	TS_SELECT("Select ISD",ISD_R_AID,"9000");
-	
-	curLogicChannel = 0;
-	var sSendType = SendTypeByOTA.SMS;
-	KIC = MNO_SCP80_ENC_KEY;
-	KID = MNO_SCP80_AUTH_KEY;
-	KIK = MNO_SCP80_DATA_ENC_KEY;
-	curDis.TestStepStart2(stno++,"SCP80,发送get status命令,使用MNO-SD的tar");
-	sAPDU = "80F28002024F00";
-	SendMessageToCard_GP(sSendType,"91XX",0,"B20100","12210015",sAPDU);
-	HaveReEntry91XX = true;
-	var ss = obj.GetState();
-	ReEntry91XXLength = ss.substr(2,2);
-	
-	curLogicChannel = 1;
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行DisableProfileRequest,refreshFlag为False;");
-	var disableProRequest = new DisableProfileRequest();
-	disableProRequest.profileIdentifier = new ChoiceObj(tagOfProfileIdentifier.iccid,ICCID_OP_PROF1);
-	disableProRequest.refreshFlag = BooleanValue_BerCode_False;
-	disableProRequest.GenHexData();
-	var respData = LPAd_Transport_data_to_eUICC(disableProRequest.hexData,"91","00","9000");
-	curStrHandle.CheckData("BF3203800100", respData, "DisableProfileResponse");
-	
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行ProfileInfoListRequest,获取profile状态;");
-	var proInfoListRequest = new ProfileInfoListRequest();
-	proInfoListRequest.searchCriteria = new ChoiceObj(tagOfsearchCriteria_ProfileInfo.iccid,ICCID_OP_PROF1);
-	proInfoListRequest.tagList = "5A4F9F70";
-	proInfoListRequest.GenHexData();
-	var respData = LPAd_Transport_data_to_eUICC(proInfoListRequest.hexData);
-	
-	var proInfoListResponse = new  ProfileInfoListResponse();
-	proInfoListResponse.checkCardResDataFormat(respData);
-	
-	try
-	{
-		curStrHandle.CheckData(ICCID_OP_PROF1, proInfoListResponse.profileInfoListOk.arrOfElement[0].iccid, "ICCID");
-		curStrHandle.CheckData(ISD_P_Test01, proInfoListResponse.profileInfoListOk.arrOfElement[0].isdpAid, "ISD-P AID");
-		curStrHandle.CheckData(Profile_DISABLED, proInfoListResponse.profileInfoListOk.arrOfElement[0].profileState, "profile State");
-	}catch(e){
-		obj.SubLevel(ProfileInfoListResponse_Data_Error, level_of_SubLevel.error);
-	}
-
-    curLogicChannel = 0;
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Select命令,选择ICCID;");
-	var para1 = new SelectFileEFPara_3G("2FE2");
-	para1.apdu.ressw = "6A82";
-	SendAPDU(para1.apdu);
-	
-	RecoverCard();
-}
-
-function TC_eUICC_ES10c_DisableProfile_Case4_09_Nominal_Disable_Profile_by_ICCID_with_refreshFLag_set_while_proactive_sessionisongoing_withTerminalResponseoutstanding_catBusynotsupported()
-{
-	//测试入口条件
-	if(!check_Applicability_of_tests_RSP_SGP23_test("C033"))
-		return;
-		
-	initial_condition_PROFILE_OPERATIONAL1_is_Enabled();
-	var ISD_P_Test01 = curProfile_ISD_P_AID;
-	
-
-	tracenamestr = "测试目的:eUICC不支持catBusy,主动式会话进行中(未给终端响应)时,通过ISD-P AID去失效profile,设置refreshFlag";
-	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();
-	curLogicChannel = 1;
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
-	TS_SELECT("Select ISD",ISD_R_AID,"9000");
-	
-	curLogicChannel = 0;
-	curDis.TestStepStart2(stno++,"SCP80,发送get status命令,使用MNO-SD的tar");
-
-	var sSendType = SendTypeByOTA.SMS;
-	KIC = MNO_SCP80_ENC_KEY;
-	KID = MNO_SCP80_AUTH_KEY;
-	KIK = MNO_SCP80_DATA_ENC_KEY;
-	sAPDU = "80F28002024F00";
-	SendMessageToCard_GP(sSendType,"91XX",0,"B20100","12210015",sAPDU);
-	HaveReEntry91XX = true;
-	var ss = obj.GetState();
-	ReEntry91XXLength = ss.substr(2,2);
-	
-	curDis.TestStepStart2(stno++,"SCP80,发送Fetch命令,检查por");
-	curLogicChannel = 0;
-	CardSendMessageToServer(sSendType,1,"0161XX","00");
-
-	
-	
-	curLogicChannel = 1;
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行DisableProfileRequest,refreshFlag为FF;");
-	var disableProRequest = new DisableProfileRequest();
-	disableProRequest.profileIdentifier = new ChoiceObj(tagOfProfileIdentifier.isdpAid,ISD_P_Test01);
-	disableProRequest.refreshFlag = BooleanValue_BerCode_True;
-	disableProRequest.GenHexData();
-	var respData = LPAd_Transport_data_to_eUICC(disableProRequest.hexData,"91","00","9000");
-	curStrHandle.CheckData("BF3203800100", respData, "DisableProfileResponse");
-	
-	curLogicChannel = 0;
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送TerminalResponse命令;");
-	TerminalResponse("00","91XX");		
-	var ss = obj.GetState();
-	HaveReEntry91XX = false;
-	
-	
-	curDis.TestStepStart2(stno++,"Fetch;");
-	FetchStr = Fetch(ss.substr(2),"9000","");	
-	var CmdDetails = GetValueByTag("01",1);
-	var CmdQualifier = CmdDetails.substr(4,2);
-	curStrHandle.CheckData("04",CmdQualifier,"the command qualifier is equal to ’04’ (UICC Reset)");
-	
-
-	curLogicChannel = 0;
-	curDis.TestStepStart2(stno++,"eUICC卡片初始化;");
-	Ini_powerOn_eUICC_LPAe_not_activate();
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送MANAGE_CHANNEL命令,打开辅助逻辑通道;");
-	TS_MANAGE_CHANNEL_OPEN();
-	curLogicChannel = 1;
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
-	TS_SELECT("Select ISD",ISD_R_AID,"9000");
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行ProfileInfoListRequest,获取profile1状态;");
-	var proInfoListRequest = new ProfileInfoListRequest();
-	proInfoListRequest.searchCriteria = new ChoiceObj(tagOfsearchCriteria_ProfileInfo.isdpAid,ISD_P_Test01);
-	proInfoListRequest.tagList = "5A4F9F70";
-	proInfoListRequest.GenHexData();
-	var respData = LPAd_Transport_data_to_eUICC(proInfoListRequest.hexData);
-	
-	var proInfoListResponse = new  ProfileInfoListResponse();
-	proInfoListResponse.checkCardResDataFormat(respData);
-	
-	try
-	{
-		curStrHandle.CheckData(ICCID_OP_PROF1, proInfoListResponse.profileInfoListOk.arrOfElement[0].iccid, "ICCID");
-		curStrHandle.CheckData(ISD_P_Test01, proInfoListResponse.profileInfoListOk.arrOfElement[0].isdpAid, "ISD-P AID");
-		curStrHandle.CheckData(Profile_DISABLED, proInfoListResponse.profileInfoListOk.arrOfElement[0].profileState, "profile State");
-	}catch(e){
-		obj.SubLevel(ProfileInfoListResponse_Data_Error, level_of_SubLevel.error);
-	}
-
-
- 	
-	curLogicChannel = 0;
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Select命令,选择ICCID;");
-	var para1 = new SelectFileEFPara_3G("2FE2");
-	SendAPDU(para1.apdu);
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送read binary命令;");
-	var para1 = new ReadBinaryPara_3G("00","00","0A");
-	para1.apdu.ressw = "6A82";
-	SendAPDU(para1.apdu);
-	
-	RecoverCard();
-}
-
-function TC_eUICC_ES10c_DisableProfile_Case4_10_Nominal_Disable_Profile_by_ICCID_with_refreshFLag_not_set_while_proactive_sessionisongoing_withTerminalResponseoutstanding_catBusynotsupported()
-{
-	//测试入口条件
-	if(!check_Applicability_of_tests_RSP_SGP23_test("C033"))
-		return;
-		
-	initial_condition_PROFILE_OPERATIONAL1_is_Enabled();
-	var ISD_P_Test01 = curProfile_ISD_P_AID;
-	
-
-	tracenamestr = "测试目的:eUICC不支持catBusy,主动式会话进行中(未给终端响应)时,通过ISD-P AID去失效profile,不设置refreshFlag";
-	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();
-	curLogicChannel = 1;
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送SELECT命令,选择ISD-R;");
-	TS_SELECT("Select ISD",ISD_R_AID,"9000");
-	
-	curLogicChannel = 0;
-	curDis.TestStepStart2(stno++,"SCP80,发送get status命令,使用MNO-SD的tar");
-
-	var sSendType = SendTypeByOTA.SMS;
-	KIC = MNO_SCP80_ENC_KEY;
-	KID = MNO_SCP80_AUTH_KEY;
-	KIK = MNO_SCP80_DATA_ENC_KEY;
-	sAPDU = "80F28002024F00";
-	SendMessageToCard_GP(sSendType,"91XX",0,"B20100","12210015",sAPDU);
-	HaveReEntry91XX = true;
-	var ss = obj.GetState();
-	ReEntry91XXLength = ss.substr(2,2);
-	
-	curDis.TestStepStart2(stno++,"SCP80,发送Fetch命令,检查por");
-	curLogicChannel = 0;
-	CardSendMessageToServer(sSendType,1,"0161XX","00");
-
-	
-	
-	curLogicChannel = 1;
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行DisableProfileRequest,refreshFlag为Flase;");
-	var disableProRequest = new DisableProfileRequest();
-	disableProRequest.profileIdentifier = new ChoiceObj(tagOfProfileIdentifier.iccid,ICCID_OP_PROF1);
-	disableProRequest.refreshFlag = BooleanValue_BerCode_False;
-	disableProRequest.GenHexData();
-	var respData = LPAd_Transport_data_to_eUICC(disableProRequest.hexData,"91","00","9000");
-	curStrHandle.CheckData("BF3203800100", respData, "DisableProfileResponse");
-	
-	curLogicChannel = 0;
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送TerminalResponse命令;");
-	TerminalResponse("00","91XX");		
-	var ss = obj.GetState();
-	HaveReEntry91XX = false;
-	
-	
-	curLogicChannel = 1;
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 StoreData命令,执行ProfileInfoListRequest,获取profile1状态;");
-	var proInfoListRequest = new ProfileInfoListRequest();
-	proInfoListRequest.searchCriteria = new ChoiceObj(tagOfsearchCriteria_ProfileInfo.iccid,ICCID_OP_PROF1);
-	proInfoListRequest.tagList = "5A4F9F70";
-	proInfoListRequest.GenHexData();
-	var respData = LPAd_Transport_data_to_eUICC(proInfoListRequest.hexData);
-	
-	var proInfoListResponse = new  ProfileInfoListResponse();
-	proInfoListResponse.checkCardResDataFormat(respData);
-	
-	try
-	{
-		curStrHandle.CheckData(ICCID_OP_PROF1, proInfoListResponse.profileInfoListOk.arrOfElement[0].iccid, "ICCID");
-		curStrHandle.CheckData(ISD_P_Test01, proInfoListResponse.profileInfoListOk.arrOfElement[0].isdpAid, "ISD-P AID");
-		curStrHandle.CheckData(Profile_DISABLED, proInfoListResponse.profileInfoListOk.arrOfElement[0].profileState, "profile State");
-	}catch(e){
-		obj.SubLevel(ProfileInfoListResponse_Data_Error, level_of_SubLevel.error);
-	}
- 	
-	curLogicChannel = 0;
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送 Select命令,选择ICCID;");
-	var para1 = new SelectFileEFPara_3G("2FE2");
-	SendAPDU(para1.apdu);
-	
-	curDis.TestStepStart2(stno++,"读卡器向卡片发送read binary命令;");
-	var para1 = new ReadBinaryPara_3G("00","00","0A");
-	para1.apdu.ressw = "6A82";
-	SendAPDU(para1.apdu);
-	
-	RecoverCard();
+// Author: 卡思Cas智能体
+// Date: 20261005-152741
+// Function: (purpose 原文未由 SGP.23 该 TC 提供,corpus vacuum 登记)TC_eUICC_ES10c.DisableProfile_Case4,Test Sequence #01-#10 Nominal (all 10 sequences),适用性 M。
+// Test points: ICH-SEQ01-IC1-K1-C1 ATR_present;ICH-SEQ01-IC1-K2-C2 FCP_Template
+//   ICH-SEQ01-IC1-K2-C4 SW;ICH-SEQ01-IC1-K3-C4 SW;ICH-SEQ01-IC1-K4-C4 final SW
+//   ICH-SEQ01-IC2-K1-C4 SW;ICH-SEQ01-IC2-K1-C3 CHANNEL_NUMBER extracted;ICH-SEQ01-IC2-K2-C4 SW
+//   S1-C1 SW1 91;S1-C2 disableResult ok;S2-C1 proactive command envelope;IC4-IC1-K1-C1 ATR_present
+//   IC4-IC1-K2-C2 FCP_Template;IC4-IC1-K2-C4 SW;IC4-IC1-K3-C4 SW;IC4-IC1-K4-C4 final SW
+//   IC4-IC2-K1-C4 SW;IC4-IC2-K1-C3 CHANNEL_NUMBER extracted;IC4-IC2-K2-C4 SW;S4-C1 SW
+//   S4-C2 contains PROFILE_INFO1_DISABLED;S5-C1 SW;S6-C1 SW1 91;S6-C2 disableResult ok
+//   S7-C1 proactive command envelope;IC9-IC1-K1-C1 ATR_present;IC9-IC1-K2-C2 FCP_Template
+//   IC9-IC1-K2-C4 SW;IC9-IC1-K3-C4 SW;IC9-IC1-K4-C4 final SW;IC9-IC2-K1-C4 SW
+//   IC9-IC2-K1-C3 CHANNEL_NUMBER extracted;IC9-IC2-K2-C4 SW;S9-C1 SW
+//   S9-C2 contains PROFILE_INFO1_DISABLED;S10-C1 SW;S11-C1 SW1 91;S11-C2 disableResult ok
+//   S12-C1 proactive command envelope;S13-C1 SW;IC15-IC1-K2-C2 FCP_Template;IC15-IC1-K2-C4 SW
+//   IC15-IC1-K3-C4 SW;IC15-IC1-K4-C4 final SW;IC16-IC2-K1-C4 SW
+//   IC16-IC2-K1-C3 CHANNEL_NUMBER extracted;IC16-IC2-K2-C4 SW;S16-C1 SW
+//   S16-C2 contains PROFILE_INFO1_DISABLED;S17-C1 SW;S18-C1 SW1 91;S18-C2 disableResult ok
+//   S19-C1 proactive command envelope;S20-C1 SW;IC22-IC1-K2-C2 FCP_Template;IC22-IC1-K2-C4 SW
+//   IC22-IC1-K3-C4 SW;IC22-IC1-K4-C4 final SW;IC23-IC2-K1-C4 SW
+//   IC23-IC2-K1-C3 CHANNEL_NUMBER extracted;IC23-IC2-K2-C4 SW;S23-C1 SW
+//   S23-C2 contains PROFILE_INFO1_DISABLED;S24-C1 SW;S25-C1 SW;S25-C2 disableResult ok;S26-C1 SW
+//   S26-C2 contains PROFILE_INFO1_DISABLED;S27-C1 SW;S28-C1 SW;S28-C2 disableResult ok;S29-C1 SW
+//   S29-C2 contains PROFILE_INFO1_DISABLED;S30-C1 SW;S31-C1 SW1 91;S32-C1 SW1 91
+//   S32-C2 DisableResult ok;S33-C1 proactive command envelope;IC35-IC1-K1-C1 ATR_present
+//   IC35-IC1-K2-C2 FCP_Template;IC35-IC1-K2-C4 SW;IC35-IC1-K3-C4 SW;IC35-IC1-K4-C4 final SW
+//   IC35-IC2-K1-C4 SW;IC35-IC2-K1-C3 CHANNEL_NUMBER extracted;IC35-IC2-K2-C4 SW;S35-C1 SW
+//   S35-C2 contains PROFILE_INFO1_DISABLED;S36-C1 SW;S37-C1 SW1 91;S38-C1 SW
+//   S38-C2 DisableResult ok;S39-C1 SW;S39-C2 contains PROFILE_INFO1_DISABLED;S40-C1 SW
+//   S41-C1 SW1 91;S42-C1 proactive command envelope;S43-C1 SW;S43-C2 DisableResult ok;S44-C1 SW1 91
+//   S45-C1 proactive command envelope;IC47-IC1-K1-C1 ATR_present;IC47-IC1-K2-C2 FCP_Template
+//   IC47-IC1-K2-C4 SW;IC47-IC1-K3-C4 SW;IC47-IC1-K4-C4 final SW;IC47-IC2-K1-C4 SW
+//   IC47-IC2-K1-C3 CHANNEL_NUMBER extracted;IC47-IC2-K2-C4 SW;S47-C1 SW
+//   S47-C2 contains PROFILE_INFO1_DISABLED;S48-C1 SW;S49-C1 SW1 91
+//   S50-C1 proactive command envelope;S51-C1 SW;S51-C2 DisableResult ok;S52-C1 SW1 != 91;S53-C1 SW
+//   S53-C2 contains PROFILE_INFO1_DISABLED;S54-C1 SW
+// 本函数由 CaseIR 4.2.22.2.3 编译生成(fullwave-blindgen-live-70-W1-laneA2,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_ES10c_DisableProfile_Case4_01_10_Nominal_all_10_sequences() {
+    var bind = curBind;
+    var profileAidSession = BindEs10xProcProfileDynamic.beginSession(bind, "TC_eUICC_ES10c_DisableProfile_Case4_01_10_Nominal_all_10_sequences");
+    // runtime-bound payload: ISD_P_AID1 stays in execution domain; context_lineage: {"context_id": "9355a262c89e8a7e", "authority_reference": "E_tc_4222/441-441/G_annexB_dynamic:L51"}
+    var cardCtxLoad1 = BindCardContext.load(bind, profileAidSession, "ISD_P_AID1", {"tag":"4F","bytes":16,"range":{"minHex":"A0000005591010FFFFFFFF8900001000","maxHex":"A0000005591010FFFFFFFF8900FFFF00","lastByte":"00"}}, {token: CARD_CONTEXT_TOKEN, domainId: CARD_CONTEXT_DOMAIN});
+    // TC-GEN-1 eUICC: The PROFILE_OPERATIONAL1 has been installed on the eUICC.: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
+    // SEQ01-IC-T1 eUICC: The PROFILE_OPERATIONAL1 is Enabled on the eUICC.: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
+    // SEQ01-IC-T2 eUICC: The PROFILE_OPERATIONAL1 corresponds to <ISD_P_AID1>.: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
+    // SEQ02-IC-T1 eUICC: The PROFILE_OPERATIONAL1 is Enabled on the eUICC.: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
+    // SEQ02-IC1 PROC_EUICC_INITIALIZATION_SEQUENCE: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
+    // SEQ02-IC2 PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
+    // SEQ03-IC-T1 eUICC: The PROFILE_OPERATIONAL1 is Enabled on the eUICC.: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
+    // SEQ03-IC-T2 eUICC: The PROFILE_OPERATIONAL1 corresponds to <ISD_P_AID1>.: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
+    // SEQ03-IC1 PROC_EUICC_INITIALIZATION_SEQUENCE_eUICCProfileStateChanged: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
+    // SEQ03-IC2 PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
+    // SEQ04-IC-T1 eUICC: The PROFILE_OPERATIONAL1 is Enabled on the eUICC.: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
+    // SEQ04-IC1 PROC_EUICC_INITIALIZATION_SEQUENCE_eUICCProfileStateChanged: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
+    // SEQ04-IC2 PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
+    // SEQ05-IC-T1 eUICC: The PROFILE_OPERATIONAL1 is Enabled on the eUICC.: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
+    // SEQ05-IC-T2 eUICC: The PROFILE_OPERATIONAL1 corresponds to <ISD_P_AID1>.: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
+    // SEQ05-IC1 PROC_EUICC_INITIALIZATION_SEQUENCE: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
+    // SEQ05-IC2 PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
+    // SEQ06-IC-T1 eUICC: The PROFILE_OPERATIONAL1 is Enabled on the eUICC.: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
+    // SEQ06-IC1 PROC_EUICC_INITIALIZATION_SEQUENCE: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
+    // SEQ06-IC2 PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
+    // SEQ07-IC-T1 eUICC: The PROFILE_OPERATIONAL1 is Enabled on the eUICC.: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
+    // SEQ07-IC1 PROC_EUICC_INITIALIZATION_SEQUENCE: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
+    // SEQ07-IC2 PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
+    // SEQ07-IC4 Do not send FETCH command: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
+    // SEQ08-IC-T1 eUICC: The PROFILE_OPERATIONAL1 is Enabled on the eUICC.: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
+    // SEQ08-IC1 PROC_EUICC_INITIALIZATION_SEQUENCE: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
+    // SEQ08-IC2 PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
+    // SEQ08-IC4 Do not send FETCH command: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
+    // SEQ09-IC-T1 eUICC: The PROFILE_OPERATIONAL1 is Enabled on the eUICC.: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
+    // SEQ09-IC1 PROC_EUICC_INITIALIZATION_SEQUENCE: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
+    // SEQ09-IC2 PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
+    // SEQ10-IC-T1 eUICC: The PROFILE_OPERATIONAL1 is Enabled on the eUICC.: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
+    // SEQ10-IC1 PROC_EUICC_INITIALIZATION_SEQUENCE: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
+    // SEQ10-IC2 PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
+    // PREFLIGHT_CONTEXT AUTHORIZED_DISCOVERY: declared unexpanded (non-PROC row or K corpus vacuum; see CaseIR open_items).
+
+    // IC head inline (initial_conditions → PROC_EUICC_INITIALIZATION_SEQUENCE, K row 1):RESET(K 语料机械展开)
+    var s56 = bind.resetAndAtr();
+    bind.checkData("ICH-SEQ01-IC1-K1-C1 ATR_present", "1", s56.atr_hex !== "" ? "1" : "0");
+
+    // IC head inline (initial_conditions → PROC_EUICC_INITIALIZATION_SEQUENCE, K row 2):SELECT_MF(K 语料机械展开)
+    // 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 s57 = bind.sendApdu("00", "A4", "00", "04", "3F00", "00", "9000");
+    bind.checkData("ICH-SEQ01-IC1-K2-C2 FCP_Template", "1", s57.resp.length > 0 ? "1" : "0");
+    bind.checkData("ICH-SEQ01-IC1-K2-C4 SW", "9000", s57.sw);
+
+    // IC head inline (initial_conditions → PROC_EUICC_INITIALIZATION_SEQUENCE, K row 3):TERMINAL_CAPABILITY_LPAd(K 语料机械展开)
+    var s58 = bind.sendApdu("80", "AA", "00", "00", "A9058100830107", null, "9000");
+    bind.checkData("ICH-SEQ01-IC1-K3-C4 SW", "9000", s58.sw);
+
+    // IC head inline (initial_conditions → PROC_EUICC_INITIALIZATION_SEQUENCE, K row 4):TERMINAL_PROFILE(K 语料机械展开)
+    var steady59 = bind.runToSteadyState(function () {
+        return bind.sendTerminalProfile("FFFFFFFF7F9D00DFBF00001FE2000000C7EB0000000168005000000000000200", "9000");
+    });
+    bind.checkData("ICH-SEQ01-IC1-K4-C4 final SW", "9000", steady59.final.sw);
+
+    // IC head inline (initial_conditions → PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR, K row 1):MANAGE_CHANNEL_OPEN(K 语料机械展开)
+    // CHANNEL_NUMBER extraction and dynamic CLA rebinding are CasBind internal state (chaining rule; no generated-code re-implementation).
+    var s60 = bind.manageChannelOpen("9000");
+    bind.checkData("ICH-SEQ01-IC2-K1-C4 SW", "9000", s60.sw);
+    bind.checkData("ICH-SEQ01-IC2-K1-C3 CHANNEL_NUMBER extracted", "1", s60.chan !== null ? "1" : "0");
+
+    // IC head inline (initial_conditions → PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR, K row 2):MTD_SELECT(K 语料机械展开)
+    // CLA = bound channel (cla_rule) and <L> length binding are CasBind internal state (chaining rule; no generated-code re-implementation).
+    var s61 = bind.sendApdu(null, "A4", "04", "00", "A0000005591010FFFFFFFF8900000100", null, "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("ICH-SEQ01-IC2-K2-C4 SW", "9000", s61.sw);
+
+    // 步骤 1:MTD_STORE_DATA(tc_step)
+    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
+    var s1 = bind.sendApdu("81", "E2", "91", "00", "BF2D035C014F", "00", "9000");
+
+    // 步骤 2:SEQ01-1] MTD_STORE_DATA(tc_step;REQ: RQ32_031, RQ32_033, RQ32_037_1, RQ57_142_2, RQ57_142_3, RQ57_142_12, RQ57_149, RQ57_150, RQ24_010)
+    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
+    var sdCla2 = s60.chan !== null ? (s60.chan <= 3 ? 128 + s60.chan : 188 + s60.chan).toString(16).toUpperCase() : null;
+    // runtime-bound payload: ISD_P_AID1 stays in execution domain
+    var s2 = bind.sendApdu(sdCla2, "E2", "91", "00", BindEs10xProcProfileDynamic.bindProfileAidTemplate(bind, "ISD_P_AID1", "BF32154F10", "0101FF", profileAidSession), "00", null);
+    BindEs10xProcProfileDynamic.assertBoundPayload(bind, "ISD_P_AID1", s2.cmd, profileAidSession);
+    bind.checkData("S1-C1 SW1 91", "91", s2.sw.substring(0, 2));
+    var r2w2 = BindGecaProc.parseGecaResponse(s2.resp, {outer: "BF32", required: ["80"]});
+    bind.checkData("S1-C2 disableResult ok", "00", (r2w2.ok && r2w2.fields["80"] === "00") ? "00" : (r2w2.fields["80"] || "absent"));
+
+    // 步骤 3:SEQ01-2] FETCH 'XX'(tc_step;REQ: RQ32_038, RQ32_039, RQ32_039_1, RQ32_041_2, RQ57_142_13, RQ57_142_14, RQ57_147)
+    // 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 s3 = bind.fetchPending("80", "12", "00", "00", null);
+    bind.checkData("S2-C1 proactive command envelope", "1", (s3.resp.length >= 4 && s3.resp.substring(0, 2) === "D0") ? "1" : "0");
+    // S2-C1: REFRESH type/mode bytes are not corpus-fixed (envelope face only; per-mode bytes absent from input).
+    // S3:主动会话协议闭合(TS 102 223 §6.3:主动命令必须 TR 应答;
+    // UICC Reset 变体 E 表无 TR 行属编辑省略,golden U3 线证同构)。
+    var s3tr = bind.terminalResponseForPending("80", "14", "00", "00", "9000");
+
+    // IC ref inline @E 步骤 4(IC1 → PROC_EUICC_INITIALIZATION_SEQUENCE, K row 1):RESET(K 语料机械展开)
+    var s62 = bind.resetAndAtr();
+    bind.checkData("IC4-IC1-K1-C1 ATR_present", "1", s62.atr_hex !== "" ? "1" : "0");
+
+    // IC ref inline @E 步骤 4(IC1 → PROC_EUICC_INITIALIZATION_SEQUENCE, K row 2):SELECT_MF(K 语料机械展开)
+    // 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 s63 = bind.sendApdu("00", "A4", "00", "04", "3F00", "00", "9000");
+    bind.checkData("IC4-IC1-K2-C2 FCP_Template", "1", s63.resp.length > 0 ? "1" : "0");
+    bind.checkData("IC4-IC1-K2-C4 SW", "9000", s63.sw);
+
+    // IC ref inline @E 步骤 4(IC1 → PROC_EUICC_INITIALIZATION_SEQUENCE, K row 3):TERMINAL_CAPABILITY_LPAd(K 语料机械展开)
+    var s64 = bind.sendApdu("80", "AA", "00", "00", "A9058100830107", null, "9000");
+    bind.checkData("IC4-IC1-K3-C4 SW", "9000", s64.sw);
+
+    // IC ref inline @E 步骤 4(IC1 → PROC_EUICC_INITIALIZATION_SEQUENCE, K row 4):TERMINAL_PROFILE(K 语料机械展开)
+    var steady65 = bind.runToSteadyState(function () {
+        return bind.sendTerminalProfile("FFFFFFFF7F9D00DFBF00001FE2000000C7EB0000000168005000000000000200", "9000");
+    });
+    bind.checkData("IC4-IC1-K4-C4 final SW", "9000", steady65.final.sw);
+
+    // IC ref inline @E 步骤 4(IC2 → PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR, K row 1):MANAGE_CHANNEL_OPEN(K 语料机械展开)
+    // CHANNEL_NUMBER extraction and dynamic CLA rebinding are CasBind internal state (chaining rule; no generated-code re-implementation).
+    var s66 = bind.manageChannelOpen("9000");
+    bind.checkData("IC4-IC2-K1-C4 SW", "9000", s66.sw);
+    bind.checkData("IC4-IC2-K1-C3 CHANNEL_NUMBER extracted", "1", s66.chan !== null ? "1" : "0");
+
+    // IC ref inline @E 步骤 4(IC2 → PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR, K row 2):MTD_SELECT(K 语料机械展开)
+    // CLA = bound channel (cla_rule) and <L> length binding are CasBind internal state (chaining rule; no generated-code re-implementation).
+    var s67 = bind.sendApdu(null, "A4", "04", "00", "A0000005591010FFFFFFFF8900000100", null, "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("IC4-IC2-K2-C4 SW", "9000", s67.sw);
+
+    // 步骤 5:SEQ01-4] MTD_STORE_DATA(tc_step;REQ: RQ32_031, RQ32_033, RQ32_037_1, RQ57_142_2, RQ57_142_3, RQ57_142_12, RQ57_149, RQ57_150, RQ24_010)
+    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
+    var sdCla5 = s66.chan !== null ? (s66.chan <= 3 ? 128 + s66.chan : 188 + s66.chan).toString(16).toUpperCase() : null;
+    // runtime-bound payload: ISD_P_AID1 stays in execution domain
+    var s5 = bind.sendApdu(sdCla5, "E2", "91", "00", BindEs10xProcProfileDynamic.bindProfileAidTemplate(bind, "ISD_P_AID1", "BF2D16A0124F10", "", profileAidSession), "00", "9000");
+    bind.checkData("S4-C1 SW", "9000", s5.sw);
+    BindEs10xProcProfileDynamic.assertBoundPayload(bind, "ISD_P_AID1", s5.cmd, profileAidSession);
+    var r2p5 = BindEs10xProcProfile.walkChoiceList(s5.resp, {respTag: "BF2D", okTag: "A0", errTag: "81"});
+    var r2has5_0 = false;
+    for (var r2i5_0 = 0; r2i5_0 < r2p5.elements.length; r2i5_0++) {
+        var f = r2p5.elements[r2i5_0].fields;
+        if (f["5A"] === "989209012143658709F5" && f["9F70"] === "00") { r2has5_0 = true; break; }
+    }
+    bind.checkData("S4-C2 contains PROFILE_INFO1_DISABLED", "1", (r2p5.branch_tag === "A0" && r2has5_0) ? "1" : "0");
+
+    // 步骤 6:SEQ01-5] [SELECT_ICCID(tc_step;REQ: RQ24_025)
+    var s6 = bind.sendApdu("00", "A4", "00", "0C", "2FE2", null, "6A82");
+    bind.checkData("S5-C1 SW", "6A82", s6.sw);
+
+    // 步骤 7:SEQ02-1] MTD_STORE_DATA(tc_step;REQ: RQ32_031, RQ32_033, RQ32_037_1, RQ57_142_2, RQ57_142_3, RQ57_142_12, RQ57_149, RQ57_150)
+    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
+    var sdCla7 = s66.chan !== null ? (s66.chan <= 3 ? 128 + s66.chan : 188 + s66.chan).toString(16).toUpperCase() : null;
+    var s7 = bind.sendApdu(sdCla7, "E2", "91", "00", "BF320F5A0A989209012143658709F50101FF", "00", null);
+    bind.checkData("S6-C1 SW1 91", "91", s7.sw.substring(0, 2));
+    var r2w7 = BindGecaProc.parseGecaResponse(s7.resp, {outer: "BF32", required: ["80"]});
+    bind.checkData("S6-C2 disableResult ok", "00", (r2w7.ok && r2w7.fields["80"] === "00") ? "00" : (r2w7.fields["80"] || "absent"));
+
+    // 步骤 8:SEQ02-2] FETCH 'XX'(tc_step;REQ: RQ32_038, RQ32_039, RQ32_039_1, RQ32_041_2, RQ57_142_13, RQ57_142_14, RQ57_147)
+    // 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 s8 = bind.fetchPending("80", "12", "00", "00", null);
+    bind.checkData("S7-C1 proactive command envelope", "1", (s8.resp.length >= 4 && s8.resp.substring(0, 2) === "D0") ? "1" : "0");
+    // S7-C1: REFRESH type/mode bytes are not corpus-fixed (envelope face only; per-mode bytes absent from input).
+    // S8:主动会话协议闭合(TS 102 223 §6.3:主动命令必须 TR 应答;
+    // UICC Reset 变体 E 表无 TR 行属编辑省略,golden U3 线证同构)。
+    var s8tr = bind.terminalResponseForPending("80", "14", "00", "00", "9000");
+
+    // IC ref inline @E 步骤 9(IC1 → PROC_EUICC_INITIALIZATION_SEQUENCE, K row 1):RESET(K 语料机械展开)
+    var s68 = bind.resetAndAtr();
+    bind.checkData("IC9-IC1-K1-C1 ATR_present", "1", s68.atr_hex !== "" ? "1" : "0");
+
+    // IC ref inline @E 步骤 9(IC1 → PROC_EUICC_INITIALIZATION_SEQUENCE, K row 2):SELECT_MF(K 语料机械展开)
+    // 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 s69 = bind.sendApdu("00", "A4", "00", "04", "3F00", "00", "9000");
+    bind.checkData("IC9-IC1-K2-C2 FCP_Template", "1", s69.resp.length > 0 ? "1" : "0");
+    bind.checkData("IC9-IC1-K2-C4 SW", "9000", s69.sw);
+
+    // IC ref inline @E 步骤 9(IC1 → PROC_EUICC_INITIALIZATION_SEQUENCE, K row 3):TERMINAL_CAPABILITY_LPAd(K 语料机械展开)
+    var s70 = bind.sendApdu("80", "AA", "00", "00", "A9058100830107", null, "9000");
+    bind.checkData("IC9-IC1-K3-C4 SW", "9000", s70.sw);
+
+    // IC ref inline @E 步骤 9(IC1 → PROC_EUICC_INITIALIZATION_SEQUENCE, K row 4):TERMINAL_PROFILE(K 语料机械展开)
+    var steady71 = bind.runToSteadyState(function () {
+        return bind.sendTerminalProfile("FFFFFFFF7F9D00DFBF00001FE2000000C7EB0000000168005000000000000200", "9000");
+    });
+    bind.checkData("IC9-IC1-K4-C4 final SW", "9000", steady71.final.sw);
+
+    // IC ref inline @E 步骤 9(IC2 → PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR, K row 1):MANAGE_CHANNEL_OPEN(K 语料机械展开)
+    // CHANNEL_NUMBER extraction and dynamic CLA rebinding are CasBind internal state (chaining rule; no generated-code re-implementation).
+    var s72 = bind.manageChannelOpen("9000");
+    bind.checkData("IC9-IC2-K1-C4 SW", "9000", s72.sw);
+    bind.checkData("IC9-IC2-K1-C3 CHANNEL_NUMBER extracted", "1", s72.chan !== null ? "1" : "0");
+
+    // IC ref inline @E 步骤 9(IC2 → PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR, K row 2):MTD_SELECT(K 语料机械展开)
+    // CLA = bound channel (cla_rule) and <L> length binding are CasBind internal state (chaining rule; no generated-code re-implementation).
+    var s73 = bind.sendApdu(null, "A4", "04", "00", "A0000005591010FFFFFFFF8900000100", null, "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("IC9-IC2-K2-C4 SW", "9000", s73.sw);
+
+    // 步骤 10:SEQ02-4] MTD_STORE_DATA(tc_step;REQ: RQ32_031, RQ32_033, RQ32_037_1, RQ57_142_2, RQ57_142_3, RQ57_142_12, RQ57_149, RQ57_150)
+    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
+    var sdCla10 = s72.chan !== null ? (s72.chan <= 3 ? 128 + s72.chan : 188 + s72.chan).toString(16).toUpperCase() : null;
+    var s10 = bind.sendApdu(sdCla10, "E2", "91", "00", "BF2D0EA00C5A0A989209012143658709F5", "00", "9000");
+    bind.checkData("S9-C1 SW", "9000", s10.sw);
+    var r2p10 = BindEs10xProcProfile.walkChoiceList(s10.resp, {respTag: "BF2D", okTag: "A0", errTag: "81"});
+    var r2has10_0 = false;
+    for (var r2i10_0 = 0; r2i10_0 < r2p10.elements.length; r2i10_0++) {
+        var f = r2p10.elements[r2i10_0].fields;
+        if (f["5A"] === "989209012143658709F5" && f["9F70"] === "00") { r2has10_0 = true; break; }
+    }
+    bind.checkData("S9-C2 contains PROFILE_INFO1_DISABLED", "1", (r2p10.branch_tag === "A0" && r2has10_0) ? "1" : "0");
+
+    // 步骤 11:SEQ02-5] [SELECT_ICCID(tc_step;REQ: RQ24_025)
+    var s11 = bind.sendApdu("00", "A4", "00", "0C", "2FE2", null, "6A82");
+    bind.checkData("S10-C1 SW", "6A82", s11.sw);
+
+    // 步骤 12:SEQ03-1] MTD_STORE_DATA(tc_step;REQ: RQ32_031, RQ32_033, RQ32_037_1, RQ57_142_2, RQ57_142_3, RQ57_142_12, RQ57_149, RQ57_150, RQ24_010)
+    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
+    var sdCla12 = s72.chan !== null ? (s72.chan <= 3 ? 128 + s72.chan : 188 + s72.chan).toString(16).toUpperCase() : null;
+    // runtime-bound payload: ISD_P_AID1 stays in execution domain
+    var s12 = bind.sendApdu(sdCla12, "E2", "91", "00", BindEs10xProcProfileDynamic.bindProfileAidTemplate(bind, "ISD_P_AID1", "BF32154F10", "0101FF", profileAidSession), "00", null);
+    BindEs10xProcProfileDynamic.assertBoundPayload(bind, "ISD_P_AID1", s12.cmd, profileAidSession);
+    bind.checkData("S11-C1 SW1 91", "91", s12.sw.substring(0, 2));
+    var r2w12 = BindGecaProc.parseGecaResponse(s12.resp, {outer: "BF32", required: ["80"]});
+    bind.checkData("S11-C2 disableResult ok", "00", (r2w12.ok && r2w12.fields["80"] === "00") ? "00" : (r2w12.fields["80"] || "absent"));
+
+    // 步骤 13:SEQ03-2] FETCH 'XX'(tc_step;REQ: RQ32_038, RQ32_039, RQ32_039_1, RQ32_041_2, RQ57_142_13, RQ57_142_14, RQ57_147)
+    // 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 s13 = bind.fetchPending("80", "12", "00", "00", null);
+    bind.checkData("S12-C1 proactive command envelope", "1", (s13.resp.length >= 4 && s13.resp.substring(0, 2) === "D0") ? "1" : "0");
+    // S12-C1: REFRESH type/mode bytes are not corpus-fixed (envelope face only; per-mode bytes absent from input).
+
+    // 步骤 14:SEQ03-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 s14 = bind.terminalResponseForPending("80", "14", "00", "00", "9000");
+    bind.checkData("S13-C1 SW", "9000", s14.sw);
+
+    // IC ref inline @E 步骤 15(IC1 → PROC_EUICC_INITIALIZATION_SEQUENCE_eUICCProfileStateChanged, K row 2):SELECT_MF(K 语料机械展开)
+    // 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 s74 = bind.sendApdu("00", "A4", "00", "04", "3F00", "00", "9000");
+    bind.checkData("IC15-IC1-K2-C2 FCP_Template", "1", s74.resp.length > 0 ? "1" : "0");
+    bind.checkData("IC15-IC1-K2-C4 SW", "9000", s74.sw);
+
+    // IC ref inline @E 步骤 15(IC1 → PROC_EUICC_INITIALIZATION_SEQUENCE_eUICCProfileStateChanged, K row 3):TERMINAL_CAPABILITY_LPAd(K 语料机械展开)
+    var s75 = bind.sendApdu("80", "AA", "00", "00", "A9058100830107", null, "9000");
+    bind.checkData("IC15-IC1-K3-C4 SW", "9000", s75.sw);
+
+    // IC ref inline @E 步骤 15(IC1 → PROC_EUICC_INITIALIZATION_SEQUENCE_eUICCProfileStateChanged, K row 4):TERMINAL_PROFILE_eUICCProfileStateChanged(K 语料机械展开)
+    var steady76 = bind.runToSteadyState(function () {
+        return bind.sendTerminalProfile("FFFFFFFFFFFF1FFFFF0302FFFF9FFFEFDFFF0FFF0FFFFF0FFF03003F7FFF03FFFF20", "9000");
+    });
+    bind.checkData("IC15-IC1-K4-C4 final SW", "9000", steady76.final.sw);
+
+    // IC ref inline @E 步骤 16(IC2 → PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR, K row 1):MANAGE_CHANNEL_OPEN(K 语料机械展开)
+    // CHANNEL_NUMBER extraction and dynamic CLA rebinding are CasBind internal state (chaining rule; no generated-code re-implementation).
+    var s77 = bind.manageChannelOpen("9000");
+    bind.checkData("IC16-IC2-K1-C4 SW", "9000", s77.sw);
+    bind.checkData("IC16-IC2-K1-C3 CHANNEL_NUMBER extracted", "1", s77.chan !== null ? "1" : "0");
+
+    // IC ref inline @E 步骤 16(IC2 → PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR, K row 2):MTD_SELECT(K 语料机械展开)
+    // CLA = bound channel (cla_rule) and <L> length binding are CasBind internal state (chaining rule; no generated-code re-implementation).
+    var s78 = bind.sendApdu(null, "A4", "04", "00", "A0000005591010FFFFFFFF8900000100", null, "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("IC16-IC2-K2-C4 SW", "9000", s78.sw);
+
+    // 步骤 17:SEQ03-6] MTD_STORE_DATA(tc_step;REQ: RQ32_031, RQ32_033, RQ32_037_1, RQ57_142_2, RQ57_142_3, RQ57_142_12, RQ57_149, RQ57_150, RQ24_010)
+    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
+    var sdCla17 = s77.chan !== null ? (s77.chan <= 3 ? 128 + s77.chan : 188 + s77.chan).toString(16).toUpperCase() : null;
+    // runtime-bound payload: ISD_P_AID1 stays in execution domain
+    var s17 = bind.sendApdu(sdCla17, "E2", "91", "00", BindEs10xProcProfileDynamic.bindProfileAidTemplate(bind, "ISD_P_AID1", "BF2D16A0124F10", "", profileAidSession), "00", "9000");
+    bind.checkData("S16-C1 SW", "9000", s17.sw);
+    BindEs10xProcProfileDynamic.assertBoundPayload(bind, "ISD_P_AID1", s17.cmd, profileAidSession);
+    var r2p17 = BindEs10xProcProfile.walkChoiceList(s17.resp, {respTag: "BF2D", okTag: "A0", errTag: "81"});
+    var r2has17_0 = false;
+    for (var r2i17_0 = 0; r2i17_0 < r2p17.elements.length; r2i17_0++) {
+        var f = r2p17.elements[r2i17_0].fields;
+        if (f["5A"] === "989209012143658709F5" && f["9F70"] === "00") { r2has17_0 = true; break; }
+    }
+    bind.checkData("S16-C2 contains PROFILE_INFO1_DISABLED", "1", (r2p17.branch_tag === "A0" && r2has17_0) ? "1" : "0");
+
+    // 步骤 18:SEQ03-7] [SELECT_ICCID(tc_step;REQ: RQ24_025)
+    var s18 = bind.sendApdu("00", "A4", "00", "0C", "2FE2", null, "6A82");
+    bind.checkData("S17-C1 SW", "6A82", s18.sw);
+
+    // 步骤 19:SEQ04-1] MTD_STORE_DATA(tc_step;REQ: RQ32_031, RQ32_033, RQ32_037_1, RQ57_142_2, RQ57_142_3, RQ57_142_12, RQ57_149, RQ57_150)
+    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
+    var sdCla19 = s77.chan !== null ? (s77.chan <= 3 ? 128 + s77.chan : 188 + s77.chan).toString(16).toUpperCase() : null;
+    var s19 = bind.sendApdu(sdCla19, "E2", "91", "00", "BF320F5A0A989209012143658709F50101FF", "00", null);
+    bind.checkData("S18-C1 SW1 91", "91", s19.sw.substring(0, 2));
+    var r2w19 = BindGecaProc.parseGecaResponse(s19.resp, {outer: "BF32", required: ["80"]});
+    bind.checkData("S18-C2 disableResult ok", "00", (r2w19.ok && r2w19.fields["80"] === "00") ? "00" : (r2w19.fields["80"] || "absent"));
+
+    // 步骤 20:SEQ04-2] FETCH 'XX'(tc_step;REQ: RQ32_038, RQ32_039, RQ32_039_1, RQ32_041_2, RQ57_142_13, RQ57_142_14, RQ57_147)
+    // 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 s20 = bind.fetchPending("80", "12", "00", "00", null);
+    bind.checkData("S19-C1 proactive command envelope", "1", (s20.resp.length >= 4 && s20.resp.substring(0, 2) === "D0") ? "1" : "0");
+    // S19-C1: REFRESH type/mode bytes are not corpus-fixed (envelope face only; per-mode bytes absent from input).
+
+    // 步骤 21:SEQ04-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 s21 = bind.terminalResponseForPending("80", "14", "00", "00", "9000");
+    bind.checkData("S20-C1 SW", "9000", s21.sw);
+
+    // IC ref inline @E 步骤 22(IC1 → PROC_EUICC_INITIALIZATION_SEQUENCE_eUICCProfileStateChanged, K row 2):SELECT_MF(K 语料机械展开)
+    // 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 s79 = bind.sendApdu("00", "A4", "00", "04", "3F00", "00", "9000");
+    bind.checkData("IC22-IC1-K2-C2 FCP_Template", "1", s79.resp.length > 0 ? "1" : "0");
+    bind.checkData("IC22-IC1-K2-C4 SW", "9000", s79.sw);
+
+    // IC ref inline @E 步骤 22(IC1 → PROC_EUICC_INITIALIZATION_SEQUENCE_eUICCProfileStateChanged, K row 3):TERMINAL_CAPABILITY_LPAd(K 语料机械展开)
+    var s80 = bind.sendApdu("80", "AA", "00", "00", "A9058100830107", null, "9000");
+    bind.checkData("IC22-IC1-K3-C4 SW", "9000", s80.sw);
+
+    // IC ref inline @E 步骤 22(IC1 → PROC_EUICC_INITIALIZATION_SEQUENCE_eUICCProfileStateChanged, K row 4):TERMINAL_PROFILE_eUICCProfileStateChanged(K 语料机械展开)
+    var steady81 = bind.runToSteadyState(function () {
+        return bind.sendTerminalProfile("FFFFFFFFFFFF1FFFFF0302FFFF9FFFEFDFFF0FFF0FFFFF0FFF03003F7FFF03FFFF20", "9000");
+    });
+    bind.checkData("IC22-IC1-K4-C4 final SW", "9000", steady81.final.sw);
+
+    // IC ref inline @E 步骤 23(IC2 → PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR, K row 1):MANAGE_CHANNEL_OPEN(K 语料机械展开)
+    // CHANNEL_NUMBER extraction and dynamic CLA rebinding are CasBind internal state (chaining rule; no generated-code re-implementation).
+    var s82 = bind.manageChannelOpen("9000");
+    bind.checkData("IC23-IC2-K1-C4 SW", "9000", s82.sw);
+    bind.checkData("IC23-IC2-K1-C3 CHANNEL_NUMBER extracted", "1", s82.chan !== null ? "1" : "0");
+
+    // IC ref inline @E 步骤 23(IC2 → PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR, K row 2):MTD_SELECT(K 语料机械展开)
+    // CLA = bound channel (cla_rule) and <L> length binding are CasBind internal state (chaining rule; no generated-code re-implementation).
+    var s83 = bind.sendApdu(null, "A4", "04", "00", "A0000005591010FFFFFFFF8900000100", null, "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("IC23-IC2-K2-C4 SW", "9000", s83.sw);
+
+    // 步骤 24:SEQ04-6] MTD_STORE_DATA(tc_step;REQ: RQ32_031, RQ32_033, RQ32_037_1, RQ57_142_2, RQ57_142_3, RQ57_142_12, RQ57_149, RQ57_150)
+    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
+    var sdCla24 = s82.chan !== null ? (s82.chan <= 3 ? 128 + s82.chan : 188 + s82.chan).toString(16).toUpperCase() : null;
+    var s24 = bind.sendApdu(sdCla24, "E2", "91", "00", "BF2D0EA00C5A0A989209012143658709F5", "00", "9000");
+    bind.checkData("S23-C1 SW", "9000", s24.sw);
+    var r2p24 = BindEs10xProcProfile.walkChoiceList(s24.resp, {respTag: "BF2D", okTag: "A0", errTag: "81"});
+    var r2has24_0 = false;
+    for (var r2i24_0 = 0; r2i24_0 < r2p24.elements.length; r2i24_0++) {
+        var f = r2p24.elements[r2i24_0].fields;
+        if (f["5A"] === "989209012143658709F5" && f["9F70"] === "00") { r2has24_0 = true; break; }
+    }
+    bind.checkData("S23-C2 contains PROFILE_INFO1_DISABLED", "1", (r2p24.branch_tag === "A0" && r2has24_0) ? "1" : "0");
+
+    // 步骤 25:SEQ04-7] [SELECT_ICCID(tc_step;REQ: RQ24_025)
+    var s25 = bind.sendApdu("00", "A4", "00", "0C", "2FE2", null, "6A82");
+    bind.checkData("S24-C1 SW", "6A82", s25.sw);
+
+    // 步骤 26:SEQ05-1] MTD_STORE_DATA(tc_step;REQ: RQ32_031, RQ32_033, RQ32_038, RQ32_041_1, RQ57_142_1, RQ57_142_2, RQ57_142_3, RQ57_142_6, RQ57_142_9, RQ57_142_14, RQ57_149, RQ57_150)
+    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
+    var sdCla26 = s82.chan !== null ? (s82.chan <= 3 ? 128 + s82.chan : 188 + s82.chan).toString(16).toUpperCase() : null;
+    // runtime-bound payload: ISD_P_AID1 stays in execution domain
+    var s26 = bind.sendApdu(sdCla26, "E2", "91", "00", BindEs10xProcProfileDynamic.bindProfileAidTemplate(bind, "ISD_P_AID1", "BF32154F10", "010100", profileAidSession), "00", "9000");
+    bind.checkData("S25-C1 SW", "9000", s26.sw);
+    BindEs10xProcProfileDynamic.assertBoundPayload(bind, "ISD_P_AID1", s26.cmd, profileAidSession);
+    var r2w26 = BindGecaProc.parseGecaResponse(s26.resp, {outer: "BF32", required: ["80"]});
+    bind.checkData("S25-C2 disableResult ok", "00", (r2w26.ok && r2w26.fields["80"] === "00") ? "00" : (r2w26.fields["80"] || "absent"));
+
+    // 步骤 27:SEQ05-2] MTD_STORE_DATA(tc_step;REQ: RQ32_031, RQ32_033, RQ32_038, RQ32_041_1, RQ57_142_1, RQ57_142_2, RQ57_142_3, RQ57_142_6, RQ57_142_9, RQ57_142_14, RQ57_149, RQ57_150)
+    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
+    var sdCla27 = s82.chan !== null ? (s82.chan <= 3 ? 128 + s82.chan : 188 + s82.chan).toString(16).toUpperCase() : null;
+    // runtime-bound payload: ISD_P_AID1 stays in execution domain
+    var s27 = bind.sendApdu(sdCla27, "E2", "91", "00", BindEs10xProcProfileDynamic.bindProfileAidTemplate(bind, "ISD_P_AID1", "BF2D16A0124F10", "", profileAidSession), "00", "9000");
+    bind.checkData("S26-C1 SW", "9000", s27.sw);
+    BindEs10xProcProfileDynamic.assertBoundPayload(bind, "ISD_P_AID1", s27.cmd, profileAidSession);
+    var r2p27 = BindEs10xProcProfile.walkChoiceList(s27.resp, {respTag: "BF2D", okTag: "A0", errTag: "81"});
+    var r2has27_0 = false;
+    for (var r2i27_0 = 0; r2i27_0 < r2p27.elements.length; r2i27_0++) {
+        var f = r2p27.elements[r2i27_0].fields;
+        if (f["5A"] === "989209012143658709F5" && f["9F70"] === "00") { r2has27_0 = true; break; }
+    }
+    bind.checkData("S26-C2 contains PROFILE_INFO1_DISABLED", "1", (r2p27.branch_tag === "A0" && r2has27_0) ? "1" : "0");
+
+    // 步骤 28:SEQ05-3] [SELECT_ICCID(tc_step;REQ: RQ24_025)
+    var s28 = bind.sendApdu("00", "A4", "00", "0C", "2FE2", null, "6A82");
+    bind.checkData("S27-C1 SW", "6A82", s28.sw);
+
+    // 步骤 29:SEQ06-1] MTD_STORE_DATA(tc_step;REQ: RQ32_031, RQ32_033, RQ32_038, RQ32_041_1, RQ57_142_1, RQ57_142_2, RQ57_142_3, RQ57_142_6, RQ57_142_9, RQ57_142_14, RQ57_149, RQ57_150)
+    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
+    var sdCla29 = s82.chan !== null ? (s82.chan <= 3 ? 128 + s82.chan : 188 + s82.chan).toString(16).toUpperCase() : null;
+    var s29 = bind.sendApdu(sdCla29, "E2", "91", "00", "BF320F5A0A989209012143658709F5010100", "00", "9000");
+    bind.checkData("S28-C1 SW", "9000", s29.sw);
+    var r2w29 = BindGecaProc.parseGecaResponse(s29.resp, {outer: "BF32", required: ["80"]});
+    bind.checkData("S28-C2 disableResult ok", "00", (r2w29.ok && r2w29.fields["80"] === "00") ? "00" : (r2w29.fields["80"] || "absent"));
+
+    // 步骤 30:SEQ06-2] MTD_STORE_DATA(tc_step;REQ: RQ32_031, RQ32_033, RQ32_038, RQ32_041_1, RQ57_142_1, RQ57_142_2, RQ57_142_3, RQ57_142_6, RQ57_142_9, RQ57_142_14, RQ57_149, RQ57_150)
+    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
+    var sdCla30 = s82.chan !== null ? (s82.chan <= 3 ? 128 + s82.chan : 188 + s82.chan).toString(16).toUpperCase() : null;
+    var s30 = bind.sendApdu(sdCla30, "E2", "91", "00", "BF2D0EA00C5A0A989209012143658709F5", "00", "9000");
+    bind.checkData("S29-C1 SW", "9000", s30.sw);
+    var r2p30 = BindEs10xProcProfile.walkChoiceList(s30.resp, {respTag: "BF2D", okTag: "A0", errTag: "81"});
+    var r2has30_0 = false;
+    for (var r2i30_0 = 0; r2i30_0 < r2p30.elements.length; r2i30_0++) {
+        var f = r2p30.elements[r2i30_0].fields;
+        if (f["5A"] === "989209012143658709F5" && f["9F70"] === "00") { r2has30_0 = true; break; }
+    }
+    bind.checkData("S29-C2 contains PROFILE_INFO1_DISABLED", "1", (r2p30.branch_tag === "A0" && r2has30_0) ? "1" : "0");
+
+    // 步骤 31:SEQ06-3] [SELECT_ICCID(tc_step;REQ: RQ24_025)
+    var s31 = bind.sendApdu("00", "A4", "00", "0C", "2FE2", null, "6A82");
+    bind.checkData("S30-C1 SW", "6A82", s31.sw);
+
+    // 步骤 32:SEQ07-IC3] 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 s32 = bind.sendApdu("80", "C2", "00", "00", null, null, null);
+    bind.checkData("S31-C1 SW1 91", "91", s32.sw.substring(0, 2));
+
+    // 步骤 33:SEQ07-1] MTD_STORE_DATA(tc_step)
+    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
+    var sdCla33 = s82.chan !== null ? (s82.chan <= 3 ? 128 + s82.chan : 188 + s82.chan).toString(16).toUpperCase() : null;
+    // runtime-bound payload: ISD_P_AID1 stays in execution domain
+    var s33 = bind.sendApdu(sdCla33, "E2", "91", "00", BindEs10xProcProfileDynamic.bindProfileAidTemplate(bind, "ISD_P_AID1", "BF32154F10", "0101FF", profileAidSession), "00", null);
+    BindEs10xProcProfileDynamic.assertBoundPayload(bind, "ISD_P_AID1", s33.cmd, profileAidSession);
+    bind.checkData("S32-C1 SW1 91", "91", s33.sw.substring(0, 2));
+    var r2w33 = BindGecaProc.parseGecaResponse(s33.resp, {outer: "BF32", required: ["80"]});
+    bind.checkData("S32-C2 DisableResult ok", "00", (r2w33.ok && r2w33.fields["80"] === "00") ? "00" : (r2w33.fields["80"] || "absent"));
+
+    // 步骤 34:SEQ07-2] FETCH 'YY'(tc_step;REQ: RQ32_016_3, RQ32_017, RQ57_134)
+    // 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 s34 = bind.fetchPending("80", "12", "00", "00", null);
+    bind.checkData("S33-C1 proactive command envelope", "1", (s34.resp.length >= 4 && s34.resp.substring(0, 2) === "D0") ? "1" : "0");
+    // S33-C1: REFRESH type/mode bytes are not corpus-fixed (envelope face only; per-mode bytes absent from input).
+    // S34:主动会话协议闭合(TS 102 223 §6.3:主动命令必须 TR 应答;
+    // UICC Reset 变体 E 表无 TR 行属编辑省略,golden U3 线证同构)。
+    var s34tr = bind.terminalResponseForPending("80", "14", "00", "00", "9000");
+
+    // IC ref inline @E 步骤 35(IC1 → PROC_EUICC_INITIALIZATION_SEQUENCE, K row 1):RESET(K 语料机械展开)
+    var s84 = bind.resetAndAtr();
+    bind.checkData("IC35-IC1-K1-C1 ATR_present", "1", s84.atr_hex !== "" ? "1" : "0");
+
+    // IC ref inline @E 步骤 35(IC1 → PROC_EUICC_INITIALIZATION_SEQUENCE, K row 2):SELECT_MF(K 语料机械展开)
+    // 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("IC35-IC1-K2-C2 FCP_Template", "1", s85.resp.length > 0 ? "1" : "0");
+    bind.checkData("IC35-IC1-K2-C4 SW", "9000", s85.sw);
+
+    // IC ref inline @E 步骤 35(IC1 → PROC_EUICC_INITIALIZATION_SEQUENCE, K row 3):TERMINAL_CAPABILITY_LPAd(K 语料机械展开)
+    var s86 = bind.sendApdu("80", "AA", "00", "00", "A9058100830107", null, "9000");
+    bind.checkData("IC35-IC1-K3-C4 SW", "9000", s86.sw);
+
+    // IC ref inline @E 步骤 35(IC1 → PROC_EUICC_INITIALIZATION_SEQUENCE, K row 4):TERMINAL_PROFILE(K 语料机械展开)
+    var steady87 = bind.runToSteadyState(function () {
+        return bind.sendTerminalProfile("FFFFFFFF7F9D00DFBF00001FE2000000C7EB0000000168005000000000000200", "9000");
+    });
+    bind.checkData("IC35-IC1-K4-C4 final SW", "9000", steady87.final.sw);
+
+    // IC ref inline @E 步骤 35(IC2 → PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR, K row 1):MANAGE_CHANNEL_OPEN(K 语料机械展开)
+    // CHANNEL_NUMBER extraction and dynamic CLA rebinding are CasBind internal state (chaining rule; no generated-code re-implementation).
+    var s88 = bind.manageChannelOpen("9000");
+    bind.checkData("IC35-IC2-K1-C4 SW", "9000", s88.sw);
+    bind.checkData("IC35-IC2-K1-C3 CHANNEL_NUMBER extracted", "1", s88.chan !== null ? "1" : "0");
+
+    // IC ref inline @E 步骤 35(IC2 → PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR, K row 2):MTD_SELECT(K 语料机械展开)
+    // CLA = bound channel (cla_rule) and <L> length binding are CasBind internal state (chaining rule; no generated-code re-implementation).
+    var s89 = bind.sendApdu(null, "A4", "04", "00", "A0000005591010FFFFFFFF8900000100", null, "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("IC35-IC2-K2-C4 SW", "9000", s89.sw);
+
+    // 步骤 36:SEQ07-4] MTD_STORE_DATA(tc_step)
+    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
+    var sdCla36 = s88.chan !== null ? (s88.chan <= 3 ? 128 + s88.chan : 188 + s88.chan).toString(16).toUpperCase() : null;
+    // runtime-bound payload: ISD_P_AID1 stays in execution domain
+    var s36 = bind.sendApdu(sdCla36, "E2", "91", "00", BindEs10xProcProfileDynamic.bindProfileAidTemplate(bind, "ISD_P_AID1", "BF2D16A0124F10", "", profileAidSession), "00", "9000");
+    bind.checkData("S35-C1 SW", "9000", s36.sw);
+    BindEs10xProcProfileDynamic.assertBoundPayload(bind, "ISD_P_AID1", s36.cmd, profileAidSession);
+    var r2p36 = BindEs10xProcProfile.walkChoiceList(s36.resp, {respTag: "BF2D", okTag: "A0", errTag: "81"});
+    var r2has36_0 = false;
+    for (var r2i36_0 = 0; r2i36_0 < r2p36.elements.length; r2i36_0++) {
+        var f = r2p36.elements[r2i36_0].fields;
+        if (f["5A"] === "989209012143658709F5" && f["9F70"] === "00") { r2has36_0 = true; break; }
+    }
+    bind.checkData("S35-C2 contains PROFILE_INFO1_DISABLED", "1", (r2p36.branch_tag === "A0" && r2has36_0) ? "1" : "0");
+
+    // 步骤 37:SEQ07-5] [SELECT_ICCID(tc_step;REQ: RQ24_025)
+    var s37 = bind.sendApdu("00", "A4", "00", "0C", "2FE2", null, "6A82");
+    bind.checkData("S36-C1 SW", "6A82", s37.sw);
+
+    // 步骤 38:SEQ08-IC3] 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 s38 = bind.sendApdu("80", "C2", "00", "00", null, null, null);
+    bind.checkData("S37-C1 SW1 91", "91", s38.sw.substring(0, 2));
+
+    // 步骤 39:SEQ08-1] MTD_STORE_DATA(tc_step)
+    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
+    var sdCla39 = s88.chan !== null ? (s88.chan <= 3 ? 128 + s88.chan : 188 + s88.chan).toString(16).toUpperCase() : null;
+    // runtime-bound payload: ISD_P_AID1 stays in execution domain
+    var s39 = bind.sendApdu(sdCla39, "E2", "91", "00", BindEs10xProcProfileDynamic.bindProfileAidTemplate(bind, "ISD_P_AID1", "BF32154F10", "010100", profileAidSession), "00", "9000");
+    bind.checkData("S38-C1 SW", "9000", s39.sw);
+    BindEs10xProcProfileDynamic.assertBoundPayload(bind, "ISD_P_AID1", s39.cmd, profileAidSession);
+    var r2w39 = BindGecaProc.parseGecaResponse(s39.resp, {outer: "BF32", required: ["80"]});
+    bind.checkData("S38-C2 DisableResult ok", "00", (r2w39.ok && r2w39.fields["80"] === "00") ? "00" : (r2w39.fields["80"] || "absent"));
+
+    // 步骤 40:SEQ08-2] MTD_STORE_DATA(tc_step)
+    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
+    var sdCla40 = s88.chan !== null ? (s88.chan <= 3 ? 128 + s88.chan : 188 + s88.chan).toString(16).toUpperCase() : null;
+    // runtime-bound payload: ISD_P_AID1 stays in execution domain
+    var s40 = bind.sendApdu(sdCla40, "E2", "91", "00", BindEs10xProcProfileDynamic.bindProfileAidTemplate(bind, "ISD_P_AID1", "BF2D16A0124F10", "", profileAidSession), "00", "9000");
+    bind.checkData("S39-C1 SW", "9000", s40.sw);
+    BindEs10xProcProfileDynamic.assertBoundPayload(bind, "ISD_P_AID1", s40.cmd, profileAidSession);
+    var r2p40 = BindEs10xProcProfile.walkChoiceList(s40.resp, {respTag: "BF2D", okTag: "A0", errTag: "81"});
+    var r2has40_0 = false;
+    for (var r2i40_0 = 0; r2i40_0 < r2p40.elements.length; r2i40_0++) {
+        var f = r2p40.elements[r2i40_0].fields;
+        if (f["5A"] === "989209012143658709F5" && f["9F70"] === "00") { r2has40_0 = true; break; }
+    }
+    bind.checkData("S39-C2 contains PROFILE_INFO1_DISABLED", "1", (r2p40.branch_tag === "A0" && r2has40_0) ? "1" : "0");
+
+    // 步骤 41:SEQ08-3] [SELECT_ICCID(tc_step;REQ: RQ24_025)
+    var s41 = bind.sendApdu("00", "A4", "00", "0C", "2FE2", null, "6A82");
+    bind.checkData("S40-C1 SW", "6A82", s41.sw);
+
+    // 步骤 42:SEQ09-IC3] 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 s42 = bind.sendApdu("80", "C2", "00", "00", null, null, null);
+    bind.checkData("S41-C1 SW1 91", "91", s42.sw.substring(0, 2));
+
+    // 步骤 43:SEQ09-1] 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 s43 = bind.fetchPending("80", "12", "00", "00", null);
+    bind.checkData("S42-C1 proactive command envelope", "1", (s43.resp.length >= 4 && s43.resp.substring(0, 2) === "D0") ? "1" : "0");
+    // S42-C1: REFRESH type/mode bytes are not corpus-fixed (envelope face only; per-mode bytes absent from input).
+    // S43:主动会话协议闭合(TS 102 223 §6.3:主动命令必须 TR 应答;
+    // UICC Reset 变体 E 表无 TR 行属编辑省略,golden U3 线证同构)。
+    var s43tr = bind.terminalResponseForPending("80", "14", "00", "00", "9000");
+
+    // 步骤 44:SEQ09-2] MTD_STORE_DATA(tc_step)
+    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
+    var sdCla44 = s88.chan !== null ? (s88.chan <= 3 ? 128 + s88.chan : 188 + s88.chan).toString(16).toUpperCase() : null;
+    // runtime-bound payload: ISD_P_AID1 stays in execution domain
+    var s44 = bind.sendApdu(sdCla44, "E2", "91", "00", BindEs10xProcProfileDynamic.bindProfileAidTemplate(bind, "ISD_P_AID1", "BF32154F10", "0101FF", profileAidSession), "00", "9000");
+    bind.checkData("S43-C1 SW", "9000", s44.sw);
+    BindEs10xProcProfileDynamic.assertBoundPayload(bind, "ISD_P_AID1", s44.cmd, profileAidSession);
+    var r2w44 = BindGecaProc.parseGecaResponse(s44.resp, {outer: "BF32", required: ["80"]});
+    bind.checkData("S43-C2 DisableResult ok", "00", (r2w44.ok && r2w44.fields["80"] === "00") ? "00" : (r2w44.fields["80"] || "absent"));
+
+    // 步骤 45:SEQ09-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 s45 = bind.terminalResponseForPending("80", "14", "00", "00", null);
+    bind.checkData("S44-C1 SW1 91", "91", s45.sw.substring(0, 2));
+
+    // 步骤 46:SEQ09-4] FETCH 'YY'(tc_step;REQ: RQ32_016_3, RQ32_017, RQ57_134)
+    // 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);
+    bind.checkData("S45-C1 proactive command envelope", "1", (s46.resp.length >= 4 && s46.resp.substring(0, 2) === "D0") ? "1" : "0");
+    // S45-C1: REFRESH type/mode bytes are not corpus-fixed (envelope face only; per-mode bytes absent from input).
+    // S46:主动会话协议闭合(TS 102 223 §6.3:主动命令必须 TR 应答;
+    // UICC Reset 变体 E 表无 TR 行属编辑省略,golden U3 线证同构)。
+    var s46tr = bind.terminalResponseForPending("80", "14", "00", "00", "9000");
+
+    // IC ref inline @E 步骤 47(IC1 → PROC_EUICC_INITIALIZATION_SEQUENCE, K row 1):RESET(K 语料机械展开)
+    var s90 = bind.resetAndAtr();
+    bind.checkData("IC47-IC1-K1-C1 ATR_present", "1", s90.atr_hex !== "" ? "1" : "0");
+
+    // IC ref inline @E 步骤 47(IC1 → PROC_EUICC_INITIALIZATION_SEQUENCE, K row 2):SELECT_MF(K 语料机械展开)
+    // 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 s91 = bind.sendApdu("00", "A4", "00", "04", "3F00", "00", "9000");
+    bind.checkData("IC47-IC1-K2-C2 FCP_Template", "1", s91.resp.length > 0 ? "1" : "0");
+    bind.checkData("IC47-IC1-K2-C4 SW", "9000", s91.sw);
+
+    // IC ref inline @E 步骤 47(IC1 → PROC_EUICC_INITIALIZATION_SEQUENCE, K row 3):TERMINAL_CAPABILITY_LPAd(K 语料机械展开)
+    var s92 = bind.sendApdu("80", "AA", "00", "00", "A9058100830107", null, "9000");
+    bind.checkData("IC47-IC1-K3-C4 SW", "9000", s92.sw);
+
+    // IC ref inline @E 步骤 47(IC1 → PROC_EUICC_INITIALIZATION_SEQUENCE, K row 4):TERMINAL_PROFILE(K 语料机械展开)
+    var steady93 = bind.runToSteadyState(function () {
+        return bind.sendTerminalProfile("FFFFFFFF7F9D00DFBF00001FE2000000C7EB0000000168005000000000000200", "9000");
+    });
+    bind.checkData("IC47-IC1-K4-C4 final SW", "9000", steady93.final.sw);
+
+    // IC ref inline @E 步骤 47(IC2 → PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR, K row 1):MANAGE_CHANNEL_OPEN(K 语料机械展开)
+    // CHANNEL_NUMBER extraction and dynamic CLA rebinding are CasBind internal state (chaining rule; no generated-code re-implementation).
+    var s94 = bind.manageChannelOpen("9000");
+    bind.checkData("IC47-IC2-K1-C4 SW", "9000", s94.sw);
+    bind.checkData("IC47-IC2-K1-C3 CHANNEL_NUMBER extracted", "1", s94.chan !== null ? "1" : "0");
+
+    // IC ref inline @E 步骤 47(IC2 → PROC_OPEN_LOGICAL_CHANNEL_AND_SELECT_ISDR, K row 2):MTD_SELECT(K 语料机械展开)
+    // CLA = bound channel (cla_rule) and <L> length binding are CasBind internal state (chaining rule; no generated-code re-implementation).
+    var s95 = bind.sendApdu(null, "A4", "04", "00", "A0000005591010FFFFFFFF8900000100", null, "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("IC47-IC2-K2-C4 SW", "9000", s95.sw);
+
+    // 步骤 48:SEQ09-6] MTD_STORE_DATA(tc_step)
+    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
+    var sdCla48 = s94.chan !== null ? (s94.chan <= 3 ? 128 + s94.chan : 188 + s94.chan).toString(16).toUpperCase() : null;
+    // runtime-bound payload: ISD_P_AID1 stays in execution domain
+    var s48 = bind.sendApdu(sdCla48, "E2", "91", "00", BindEs10xProcProfileDynamic.bindProfileAidTemplate(bind, "ISD_P_AID1", "BF2D16A0124F10", "", profileAidSession), "00", "9000");
+    bind.checkData("S47-C1 SW", "9000", s48.sw);
+    BindEs10xProcProfileDynamic.assertBoundPayload(bind, "ISD_P_AID1", s48.cmd, profileAidSession);
+    var r2p48 = BindEs10xProcProfile.walkChoiceList(s48.resp, {respTag: "BF2D", okTag: "A0", errTag: "81"});
+    var r2has48_0 = false;
+    for (var r2i48_0 = 0; r2i48_0 < r2p48.elements.length; r2i48_0++) {
+        var f = r2p48.elements[r2i48_0].fields;
+        if (f["5A"] === "989209012143658709F5" && f["9F70"] === "00") { r2has48_0 = true; break; }
+    }
+    bind.checkData("S47-C2 contains PROFILE_INFO1_DISABLED", "1", (r2p48.branch_tag === "A0" && r2has48_0) ? "1" : "0");
+
+    // 步骤 49:SEQ09-7] [SELECT_ICCID(tc_step;REQ: RQ24_025)
+    var s49 = bind.sendApdu("00", "A4", "00", "0C", "2FE2", null, "6A82");
+    bind.checkData("S48-C1 SW", "6A82", s49.sw);
+
+    // 步骤 50:SEQ10-IC3] 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 s50 = bind.sendApdu("80", "C2", "00", "00", null, null, null);
+    bind.checkData("S49-C1 SW1 91", "91", s50.sw.substring(0, 2));
+
+    // 步骤 51:SEQ10-1] 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 s51 = bind.fetchPending("80", "12", "00", "00", null);
+    bind.checkData("S50-C1 proactive command envelope", "1", (s51.resp.length >= 4 && s51.resp.substring(0, 2) === "D0") ? "1" : "0");
+    // S50-C1: REFRESH type/mode bytes are not corpus-fixed (envelope face only; per-mode bytes absent from input).
+    // S51:主动会话协议闭合(TS 102 223 §6.3:主动命令必须 TR 应答;
+    // UICC Reset 变体 E 表无 TR 行属编辑省略,golden U3 线证同构)。
+    var s51tr = bind.terminalResponseForPending("80", "14", "00", "00", "9000");
+
+    // 步骤 52:SEQ10-2] MTD_STORE_DATA(tc_step)
+    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
+    var sdCla52 = s94.chan !== null ? (s94.chan <= 3 ? 128 + s94.chan : 188 + s94.chan).toString(16).toUpperCase() : null;
+    // runtime-bound payload: ISD_P_AID1 stays in execution domain
+    var s52 = bind.sendApdu(sdCla52, "E2", "91", "00", BindEs10xProcProfileDynamic.bindProfileAidTemplate(bind, "ISD_P_AID1", "BF32154F10", "010100", profileAidSession), "00", "9000");
+    bind.checkData("S51-C1 SW", "9000", s52.sw);
+    BindEs10xProcProfileDynamic.assertBoundPayload(bind, "ISD_P_AID1", s52.cmd, profileAidSession);
+    var r2w52 = BindGecaProc.parseGecaResponse(s52.resp, {outer: "BF32", required: ["80"]});
+    bind.checkData("S51-C2 DisableResult ok", "00", (r2w52.ok && r2w52.fields["80"] === "00") ? "00" : (r2w52.fields["80"] || "absent"));
+
+    // 步骤 53:SEQ10-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 s53 = bind.terminalResponseForPending("80", "14", "00", "00", null);
+    bind.checkData("S52-C1 SW1 != 91", "1", s53.sw.substring(0, 2) !== "91" ? "1" : "0");
+
+    // 步骤 54:SEQ10-4] MTD_STORE_DATA(tc_step)
+    // <L> length binding and the conditional 61XX + GET RESPONSE chain (D.4.2) are CasBind internal state (chaining rule).
+    var sdCla54 = s94.chan !== null ? (s94.chan <= 3 ? 128 + s94.chan : 188 + s94.chan).toString(16).toUpperCase() : null;
+    // runtime-bound payload: ISD_P_AID1 stays in execution domain
+    var s54 = bind.sendApdu(sdCla54, "E2", "91", "00", BindEs10xProcProfileDynamic.bindProfileAidTemplate(bind, "ISD_P_AID1", "BF2D16A0124F10", "", profileAidSession), "00", "9000");
+    bind.checkData("S53-C1 SW", "9000", s54.sw);
+    BindEs10xProcProfileDynamic.assertBoundPayload(bind, "ISD_P_AID1", s54.cmd, profileAidSession);
+    var r2p54 = BindEs10xProcProfile.walkChoiceList(s54.resp, {respTag: "BF2D", okTag: "A0", errTag: "81"});
+    var r2has54_0 = false;
+    for (var r2i54_0 = 0; r2i54_0 < r2p54.elements.length; r2i54_0++) {
+        var f = r2p54.elements[r2i54_0].fields;
+        if (f["5A"] === "989209012143658709F5" && f["9F70"] === "00") { r2has54_0 = true; break; }
+    }
+    bind.checkData("S53-C2 contains PROFILE_INFO1_DISABLED", "1", (r2p54.branch_tag === "A0" && r2has54_0) ? "1" : "0");
+
+    // 步骤 55:SEQ10-5] [SELECT_ICCID(tc_step;REQ: RQ24_025)
+    var s55 = bind.sendApdu("00", "A4", "00", "0C", "2FE2", null, "6A82");
+    bind.checkData("S54-C1 SW", "6A82", s55.sw);
 }