equal
deleted
inserted
replaced
14 * Description: EAP and WLAN authentication protocols. |
14 * Description: EAP and WLAN authentication protocols. |
15 * |
15 * |
16 */ |
16 */ |
17 |
17 |
18 /* |
18 /* |
19 * %version: 49 % |
19 * %version: 52 % |
20 */ |
20 */ |
21 |
21 |
22 #include "eap_am_stack_symbian.h" |
22 #include "eap_am_stack_symbian.h" |
23 #include "eap_array_algorithms.h" |
23 #include "eap_array_algorithms.h" |
24 #include "eap_base_type.h" |
24 #include "eap_base_type.h" |
338 (EAPL("eap_am_stack_symbian_c::reset_eap_plugins(): %s, this = 0x%08x => 0x%08x\n"), |
338 (EAPL("eap_am_stack_symbian_c::reset_eap_plugins(): %s, this = 0x%08x => 0x%08x\n"), |
339 (iIsClient == true) ? "client": "server", |
339 (iIsClient == true) ? "client": "server", |
340 this, |
340 this, |
341 dynamic_cast<abs_eap_base_timer_c *>(this))); |
341 dynamic_cast<abs_eap_base_timer_c *>(this))); |
342 |
342 |
343 // Unload all loaded plugins |
|
344 for(int ind = 0; ind < m_plugin_if_array.Count(); ind++) |
|
345 { |
|
346 delete m_plugin_if_array[ind]; |
|
347 } |
|
348 |
|
349 m_plugin_if_array.Close(); |
|
350 |
|
351 |
|
352 iEnabledEapMethodsArray.reset(); |
343 iEnabledEapMethodsArray.reset(); |
353 iDisabledEapMethodsArray.reset(); |
344 iDisabledEapMethodsArray.reset(); |
354 |
|
355 |
345 |
356 m_eap_type_array.reset(); |
346 m_eap_type_array.reset(); |
357 |
347 |
358 EAP_TRACE_END(iTools, TRACE_FLAGS_DEFAULT); |
348 EAP_TRACE_END(iTools, TRACE_FLAGS_DEFAULT); |
359 return EAP_STATUS_RETURN(iTools, eap_status_ok); |
349 return EAP_STATUS_RETURN(iTools, eap_status_ok); |
374 this, |
364 this, |
375 dynamic_cast<abs_eap_base_timer_c *>(this))); |
365 dynamic_cast<abs_eap_base_timer_c *>(this))); |
376 |
366 |
377 delete iFileconfig; |
367 delete iFileconfig; |
378 iFileconfig = 0; |
368 iFileconfig = 0; |
|
369 |
|
370 // Unload all loaded plugins |
|
371 for(int ind = 0; ind < m_plugin_if_array.Count(); ind++) |
|
372 { |
|
373 delete m_plugin_if_array[ind]; |
|
374 } |
|
375 |
|
376 m_plugin_if_array.Close(); |
379 |
377 |
380 (void) reset_eap_plugins(); |
378 (void) reset_eap_plugins(); |
381 |
379 |
382 EAP_TRACE_END(iTools, TRACE_FLAGS_DEFAULT); |
380 EAP_TRACE_END(iTools, TRACE_FLAGS_DEFAULT); |
383 return EAP_STATUS_RETURN(iTools, eap_status_ok); |
381 return EAP_STATUS_RETURN(iTools, eap_status_ok); |
441 else if (iEnabledEapMethodsArray.get_object_count() == 0ul) |
439 else if (iEnabledEapMethodsArray.get_object_count() == 0ul) |
442 { |
440 { |
443 EAP_TRACE_ERROR( |
441 EAP_TRACE_ERROR( |
444 iTools, |
442 iTools, |
445 TRACE_FLAGS_DEFAULT, |
443 TRACE_FLAGS_DEFAULT, |
446 (EAPL("EAP settings not read from CommsDat\n"))); |
444 (EAPL("ERROR: No activated EAP-methods.\n"))); |
447 |
445 |
448 EAP_TRACE_END(iTools, TRACE_FLAGS_DEFAULT); |
446 EAP_TRACE_END(iTools, TRACE_FLAGS_DEFAULT); |
449 return EAP_STATUS_RETURN(iTools, eap_status_process_general_error); |
447 return EAP_STATUS_RETURN(iTools, eap_status_process_general_error); |
450 } |
448 } |
451 |
449 |
700 && allowed_eap_method->get_is_valid() == true) |
698 && allowed_eap_method->get_is_valid() == true) |
701 { |
699 { |
702 EAP_TRACE_DEBUG( |
700 EAP_TRACE_DEBUG( |
703 iTools, |
701 iTools, |
704 TRACE_FLAGS_DEFAULT, |
702 TRACE_FLAGS_DEFAULT, |
705 (EAPL("eap_am_stack_symbian_c::ReadEAPSettingsL(): Enabled expanded EAP type at index=%d, EAP-type=0xfe%06x%08x\n"), |
703 (EAPL("eap_am_stack_symbian_c::get_eap_type_list(): Enabled expanded EAP type at index=%d, EAP-type=0xfe%06x%08x\n"), |
706 ind, |
704 ind, |
707 allowed_eap_method->get_vendor_id(), |
705 allowed_eap_method->get_vendor_id(), |
708 allowed_eap_method->get_vendor_type())); |
706 allowed_eap_method->get_vendor_type())); |
709 |
707 |
710 status = eap_type_list->add_object(allowed_eap_method->copy(), true); |
708 status = eap_type_list->add_object(allowed_eap_method->copy(), true); |
821 |
819 |
822 // We must have a trap here since the EAPOL core knows nothing about Symbian. |
820 // We must have a trap here since the EAPOL core knows nothing about Symbian. |
823 TRAP(error, (eapType = CEapTypePlugin::NewL( |
821 TRAP(error, (eapType = CEapTypePlugin::NewL( |
824 expanded_type, |
822 expanded_type, |
825 iIndexType, |
823 iIndexType, |
826 iIndex))); |
824 iIndex, |
|
825 iTools))); |
827 if (error != KErrNone |
826 if (error != KErrNone |
828 || eapType == 0) |
827 || eapType == 0) |
829 { |
828 { |
830 // Interface not found or implementation creation function failed |
829 // Interface not found or implementation creation function failed |
831 status = iTools->convert_am_error_to_eapol_error(error); |
830 status = iTools->convert_am_error_to_eapol_error(error); |
1440 && allowed_eap_method->get_is_valid() == true) |
1439 && allowed_eap_method->get_is_valid() == true) |
1441 { |
1440 { |
1442 EAP_TRACE_DEBUG( |
1441 EAP_TRACE_DEBUG( |
1443 iTools, |
1442 iTools, |
1444 TRACE_FLAGS_DEFAULT, |
1443 TRACE_FLAGS_DEFAULT, |
1445 (EAPL("eap_am_stack_symbian_c::ReadEAPSettingsL(): Enabled expanded EAP type at index=%d, EAP-type=0xfe%06x%08x\n"), |
1444 (EAPL("eap_am_stack_symbian_c::get_802_11_authentication_mode(): Enabled expanded EAP type at index=%d, EAP-type=0xfe%06x%08x\n"), |
1446 ind_type, |
1445 ind_type, |
1447 allowed_eap_method->get_vendor_id(), |
1446 allowed_eap_method->get_vendor_id(), |
1448 allowed_eap_method->get_vendor_type())); |
1447 allowed_eap_method->get_vendor_type())); |
1449 |
1448 |
1450 if (*allowed_eap_method != eap_type_none) |
1449 if (*allowed_eap_method != eap_type_none) |