eapol/eapol_framework/eapol_symbian/am/type/tls_peap/symbian/plugin/src/EapTlsPeap.cpp
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: 64 % |
19 * %version: 67 % |
20 */ |
20 */ |
21 |
21 |
22 // This is enumeration of EAPOL source code. |
22 // This is enumeration of EAPOL source code. |
23 #if defined(USE_EAP_MINIMUM_RELEASE_TRACES) |
23 #if defined(USE_EAP_MINIMUM_RELEASE_TRACES) |
24 #undef EAP_FILE_NUMBER_ENUM |
24 #undef EAP_FILE_NUMBER_ENUM |
89 { |
89 { |
90 EAP_TRACE_END(m_am_tools, TRACE_FLAGS_DEFAULT); |
90 EAP_TRACE_END(m_am_tools, TRACE_FLAGS_DEFAULT); |
91 return; |
91 return; |
92 } |
92 } |
93 |
93 |
94 ASSERT(iEapType.get_vendor_id() == eap_type_vendor_id_ietf); |
|
95 ASSERT(iTunnelingType.get_vendor_id() == eap_type_vendor_id_ietf); |
|
96 |
|
97 #if defined(USE_FAST_EAP_TYPE) |
94 #if defined(USE_FAST_EAP_TYPE) |
98 if(iEapType == eap_type_fast) |
95 if(iEapType == eap_type_fast) |
99 { |
96 { |
100 eap_variable_data_c source(m_am_tools); |
97 eap_variable_data_c source(m_am_tools); |
101 |
98 |
200 { |
197 { |
201 EAP_TRACE_DEBUG_SYMBIAN((_L("CEapTlsPeap::NewTtlsPapL()\n"))); |
198 EAP_TRACE_DEBUG_SYMBIAN((_L("CEapTlsPeap::NewTtlsPapL()\n"))); |
202 EAP_TRACE_RETURN_STRING_SYMBIAN(_L("returns: CEapTlsPeap::NewTtlsPapL()\n")); |
199 EAP_TRACE_RETURN_STRING_SYMBIAN(_L("returns: CEapTlsPeap::NewTtlsPapL()\n")); |
203 |
200 |
204 return new (ELeave) CEapTlsPeap( |
201 return new (ELeave) CEapTlsPeap( |
205 aIapInfo->indexType, aIapInfo->index, eap_type_ttls_plain_pap ); |
202 aIapInfo->indexType, aIapInfo->index, eap_expanded_type_ttls_plain_pap.get_type() ); |
206 } |
203 } |
207 |
204 |
208 |
205 |
209 // ---------------------------------------------------------- |
206 // ---------------------------------------------------------- |
210 |
207 |
670 |
667 |
671 #ifdef USE_FAST_EAP_TYPE |
668 #ifdef USE_FAST_EAP_TYPE |
672 || iEapType == eap_type_fast |
669 || iEapType == eap_type_fast |
673 #endif |
670 #endif |
674 |
671 |
675 || iEapType == eap_type_ttls_plain_pap |
672 || iEapType == eap_expanded_type_ttls_plain_pap.get_type() |
676 |
673 |
677 |
674 |
678 ) |
675 ) |
679 { |
676 { |
680 iEapArray.ResetAndDestroy(); |
677 iEapArray.ResetAndDestroy(); |
687 |
684 |
688 #ifdef USE_FAST_EAP_TYPE |
685 #ifdef USE_FAST_EAP_TYPE |
689 || (iEapType == eap_type_fast && !CEapTypePlugin::IsDisallowedInsidePEAP(*iEapArray[i])) |
686 || (iEapType == eap_type_fast && !CEapTypePlugin::IsDisallowedInsidePEAP(*iEapArray[i])) |
690 #endif |
687 #endif |
691 |
688 |
692 || (iEapType == eap_type_ttls_plain_pap && !CEapTypePlugin::IsDisallowedInsidePEAP(*iEapArray[i])) |
689 || (iEapType == eap_expanded_type_ttls_plain_pap.get_type() && !CEapTypePlugin::IsDisallowedInsidePEAP(*iEapArray[i])) |
693 |
690 |
694 |
691 |
695 ) |
692 ) |
696 { |
693 { |
697 // Deleting the encapsulated EAP type configurations possible inside PEAP, TTLS and FAST. |
694 // Deleting the encapsulated EAP type configurations possible inside PEAP, TTLS and FAST. |
887 usercerts.Set(KFastAllowedUserCertsDatabaseTableName); |
884 usercerts.Set(KFastAllowedUserCertsDatabaseTableName); |
888 cacerts.Set(KFastAllowedCACertsDatabaseTableName); |
885 cacerts.Set(KFastAllowedCACertsDatabaseTableName); |
889 ciphersuites.Set(KFastAllowedCipherSuitesDatabaseTableName); |
886 ciphersuites.Set(KFastAllowedCipherSuitesDatabaseTableName); |
890 } |
887 } |
891 #endif |
888 #endif |
892 else if (iEapType == eap_type_ttls_plain_pap) |
889 else if (iEapType == eap_expanded_type_ttls_plain_pap.get_type()) |
893 { |
890 { |
894 settings.Set(KTtlsDatabaseTableName); |
891 settings.Set(KTtlsDatabaseTableName); |
895 usercerts.Set(KTtlsAllowedUserCertsDatabaseTableName); |
892 usercerts.Set(KTtlsAllowedUserCertsDatabaseTableName); |
896 cacerts.Set(KTtlsAllowedCACertsDatabaseTableName); |
893 cacerts.Set(KTtlsAllowedCACertsDatabaseTableName); |
897 ciphersuites.Set(KTtlsAllowedCipherSuitesDatabaseTableName); |
894 ciphersuites.Set(KTtlsAllowedCipherSuitesDatabaseTableName); |
995 |
992 |
996 #ifdef USE_FAST_EAP_TYPE |
993 #ifdef USE_FAST_EAP_TYPE |
997 || iEapType == eap_type_fast |
994 || iEapType == eap_type_fast |
998 #endif |
995 #endif |
999 |
996 |
1000 || iEapType == eap_type_ttls_plain_pap |
997 || iEapType == eap_expanded_type_ttls_plain_pap.get_type() |
1001 |
998 |
1002 |
999 |
1003 ) |
1000 ) |
1004 { |
1001 { |
1005 iEapArray.ResetAndDestroy(); |
1002 iEapArray.ResetAndDestroy(); |
1012 |
1009 |
1013 #ifdef USE_FAST_EAP_TYPE |
1010 #ifdef USE_FAST_EAP_TYPE |
1014 || (iEapType == eap_type_fast && !CEapTypePlugin::IsDisallowedInsidePEAP(*iEapArray[i])) |
1011 || (iEapType == eap_type_fast && !CEapTypePlugin::IsDisallowedInsidePEAP(*iEapArray[i])) |
1015 #endif |
1012 #endif |
1016 |
1013 |
1017 || (iEapType == eap_type_ttls_plain_pap && !CEapTypePlugin::IsDisallowedInsidePEAP(*iEapArray[i])) |
1014 || (iEapType == eap_expanded_type_ttls_plain_pap.get_type() && !CEapTypePlugin::IsDisallowedInsidePEAP(*iEapArray[i])) |
1018 |
1015 |
1019 |
1016 |
1020 ) |
1017 ) |
1021 { |
1018 { |
1022 // Setting the index for encapsulated EAP type configurations possible |
1019 // Setting the index for encapsulated EAP type configurations possible |
1208 usercerts.Set(KTtlsAllowedUserCertsDatabaseTableName); |
1205 usercerts.Set(KTtlsAllowedUserCertsDatabaseTableName); |
1209 cacerts.Set(KTtlsAllowedCACertsDatabaseTableName); |
1206 cacerts.Set(KTtlsAllowedCACertsDatabaseTableName); |
1210 ciphersuites.Set(KTtlsAllowedCipherSuitesDatabaseTableName); |
1207 ciphersuites.Set(KTtlsAllowedCipherSuitesDatabaseTableName); |
1211 } |
1208 } |
1212 #endif |
1209 #endif |
1213 else if (iEapType == eap_type_ttls_plain_pap) |
1210 else if (iEapType == eap_expanded_type_ttls_plain_pap.get_type()) |
1214 { |
1211 { |
1215 settings.Set(KTtlsDatabaseTableName); |
1212 settings.Set(KTtlsDatabaseTableName); |
1216 usercerts.Set(KTtlsAllowedUserCertsDatabaseTableName); |
1213 usercerts.Set(KTtlsAllowedUserCertsDatabaseTableName); |
1217 cacerts.Set(KTtlsAllowedCACertsDatabaseTableName); |
1214 cacerts.Set(KTtlsAllowedCACertsDatabaseTableName); |
1218 ciphersuites.Set(KTtlsAllowedCipherSuitesDatabaseTableName); |
1215 ciphersuites.Set(KTtlsAllowedCipherSuitesDatabaseTableName); |
1328 |
1325 |
1329 #ifdef USE_FAST_EAP_TYPE |
1326 #ifdef USE_FAST_EAP_TYPE |
1330 || iEapType == eap_type_fast |
1327 || iEapType == eap_type_fast |
1331 #endif |
1328 #endif |
1332 |
1329 |
1333 || iEapType == eap_type_ttls_plain_pap |
1330 || iEapType == eap_expanded_type_ttls_plain_pap.get_type() |
1334 |
1331 |
1335 |
1332 |
1336 ) |
1333 ) |
1337 { |
1334 { |
1338 EAP_TRACE_DEBUG_SYMBIAN( |
1335 EAP_TRACE_DEBUG_SYMBIAN( |
1348 |
1345 |
1349 #ifdef USE_FAST_EAP_TYPE |
1346 #ifdef USE_FAST_EAP_TYPE |
1350 || (iEapType == eap_type_fast && !CEapTypePlugin::IsDisallowedInsidePEAP(*iEapArray[i])) |
1347 || (iEapType == eap_type_fast && !CEapTypePlugin::IsDisallowedInsidePEAP(*iEapArray[i])) |
1351 #endif |
1348 #endif |
1352 |
1349 |
1353 || (iEapType == eap_type_ttls_plain_pap && !CEapTypePlugin::IsDisallowedInsidePEAP(*iEapArray[i])) |
1350 || (iEapType == eap_expanded_type_ttls_plain_pap.get_type() && !CEapTypePlugin::IsDisallowedInsidePEAP(*iEapArray[i])) |
1354 |
1351 |
1355 ) |
1352 ) |
1356 { |
1353 { |
1357 // Copying the settings of encapsulated EAP type configurations possible inside PEAP and TTLS. |
1354 // Copying the settings of encapsulated EAP type configurations possible inside PEAP and TTLS. |
1358 |
1355 |