--- a/eapol/eapol_framework/eapol_symbian/am/include/EapSimInterface.h Mon Jun 21 15:44:11 2010 +0300
+++ b/eapol/eapol_framework/eapol_symbian/am/include/EapSimInterface.h Thu Aug 19 09:58:27 2010 +0300
@@ -16,7 +16,7 @@
*/
/*
-* %version: 12 %
+* %version: 13 %
*/
#ifndef _EAPSIMINTERFACE_H_
@@ -88,6 +88,8 @@
// Creates the MMETel connection and loads the phone module.
TInt CreateMMETelConnectionL();
+ void DisconnectMMETel();
+
private:
eap_am_type_gsmsim_symbian_c * const iParent;
--- a/eapol/eapol_framework/eapol_symbian/am/type/aka/symbian/EapAkaInterface.cpp Mon Jun 21 15:44:11 2010 +0300
+++ b/eapol/eapol_framework/eapol_symbian/am/type/aka/symbian/EapAkaInterface.cpp Thu Aug 19 09:58:27 2010 +0300
@@ -16,7 +16,7 @@
*/
/*
-* %version: 17 %
+* %version: 17.1.3 %
*/
// This is enumeration of EAPOL source code.
@@ -30,6 +30,7 @@
// INCLUDE FILES
#include "EapAkaInterface.h"
#include "eap_type_aka_types.h"
+#include "eap_automatic_variable.h"
#include <mmtsy_names.h>
#include <etelmmerr.h>
@@ -45,6 +46,8 @@
, iMMETELConnectionStatus(EFalse)
{
EAP_TRACE_BEGIN(m_am_tools, TRACE_FLAGS_DEFAULT);
+ EAP_TRACE_DEBUG(m_am_tools, TRACE_FLAGS_DEFAULT, (EAPL("CEapAkaInterface::CEapAkaInterface\n")));
+ EAP_TRACE_RETURN_STRING(m_am_tools, "returns: CEapAkaInterface::CEapAkaInterface()");
EAP_TRACE_END(m_am_tools, TRACE_FLAGS_DEFAULT);
}
@@ -76,18 +79,14 @@
CEapAkaInterface::~CEapAkaInterface()
{
EAP_TRACE_BEGIN(m_am_tools, TRACE_FLAGS_DEFAULT);
+ EAP_TRACE_DEBUG(m_am_tools, TRACE_FLAGS_DEFAULT, (EAPL("CEapAkaInterface::~CEapAkaInterface\n")));
+ EAP_TRACE_RETURN_STRING(m_am_tools, "returns: CEapAkaInterface::~CEapAkaInterface()");
if(IsActive())
{
Cancel();
}
- /*
- EAP_TRACE_DEBUG(m_am_tools, TRACE_FLAGS_DEFAULT, (EAPL("Closing RMobilePhone and MMETEL.\n")));
-
- iPhone.Close();
- iServer.Close(); // Phone module is unloaded automatically when RTelServer session is closed
- */
DisconnectMMETel();
delete iAuthenticationData;
@@ -101,8 +100,9 @@
void CEapAkaInterface::QueryIMSIL()
{
EAP_TRACE_BEGIN(m_am_tools, TRACE_FLAGS_DEFAULT);
- EAP_TRACE_DEBUG(m_am_tools, TRACE_FLAGS_DEFAULT, (EAPL("AKA interface: Querying IMSI.\n")));
-
+ EAP_TRACE_DEBUG(m_am_tools, TRACE_FLAGS_DEFAULT, (EAPL("AKA interface: CEapAkaInterface::QueryIMSIL()\n")));
+ EAP_TRACE_RETURN_STRING(m_am_tools, "returns: CEapAkaInterface::QueryIMSIL()");
+
iQueryId = EQueryIMSI;
// Create MMETEl connection.
@@ -123,7 +123,8 @@
void CEapAkaInterface::QueryRESL( eap_variable_data_c * const aRand, eap_variable_data_c * const aAUTN )
{
EAP_TRACE_BEGIN(m_am_tools, TRACE_FLAGS_DEFAULT);
- EAP_TRACE_DEBUG(m_am_tools, TRACE_FLAGS_DEFAULT, (EAPL("AKA interface: Querying RES, CK, IK and AUTS.\n")));
+ EAP_TRACE_DEBUG(m_am_tools, TRACE_FLAGS_DEFAULT, (EAPL("AKA interface: CEapAkaInterface::QueryRESL(), CK, IK and AUTS.\n")));
+ EAP_TRACE_RETURN_STRING(m_am_tools, "returns: CEapAkaInterface::QueryRESL()");
iQueryId = EQueryRES;
@@ -184,12 +185,19 @@
void CEapAkaInterface::DoCancel()
{
- EAP_TRACE_DEBUG(m_am_tools, TRACE_FLAGS_DEFAULT, (EAPL("CEapAkaInterface::DoCancel() - Cancelling MMETEL query.\n") ) );
+ EAP_TRACE_DEBUG(m_am_tools, TRACE_FLAGS_DEFAULT, (EAPL("CEapAkaInterface::DoCancel() - Cancelling MMETEL query, iQueryId=%d\n"),
+ iQueryId) );
+ EAP_TRACE_RETURN_STRING(m_am_tools, "returns: CEapAkaInterface::DoCancel()");
- // Cancel the request.
- iCustomAPI.CancelAsyncRequest( ECustomGetSimAuthenticationDataIPC );
-
- EAP_TRACE_DEBUG(m_am_tools, TRACE_FLAGS_DEFAULT, (EAPL("CEapAkaInterface::DoCancel(): CANCELLED CUSTOM API REQUEST \n")));
+ if (iQueryId == EQueryRES)
+ {
+ iQueryId = EQueryNone;
+
+ // Cancel the request.
+ iCustomAPI.CancelAsyncRequest( ECustomGetSimAuthenticationDataIPC );
+
+ EAP_TRACE_DEBUG(m_am_tools, TRACE_FLAGS_DEFAULT, (EAPL("CEapAkaInterface::DoCancel(): CANCELLED CUSTOM API REQUEST \n")));
+ }
}
//--------------------------------------------------
@@ -198,7 +206,10 @@
{
EAP_TRACE_BEGIN(m_am_tools, TRACE_FLAGS_DEFAULT);
- EAP_TRACE_DEBUG(m_am_tools, TRACE_FLAGS_DEFAULT, (EAPL("CEapAkaInterface::RunL(). iStatus.Int() =%d \n"), iStatus.Int() ));
+ EAP_TRACE_DEBUG(m_am_tools, TRACE_FLAGS_DEFAULT, (EAPL("CEapAkaInterface::RunL(). iStatus.Int()=%d, iQueryId=%d\n"),
+ iStatus.Int(),
+ iQueryId));
+ EAP_TRACE_RETURN_STRING(m_am_tools, "returns: CEapAkaInterface::RunL()");
TInt error = KErrNone;
@@ -220,12 +231,15 @@
switch( iQueryId )
{
case EQueryIMSI:
+
EAP_TRACE_DEBUG(m_am_tools, TRACE_FLAGS_DEFAULT, (EAPL("AKA interface: Got IMSI reply.\n")));
EAP_TRACE_DATA_DEBUG(m_am_tools, TRACE_FLAGS_DEFAULT, (EAPL("IMSI"),
iSubscriberId.Ptr(),
iSubscriberId.Size()));
+ iQueryId = EQueryNone;
+
// Convert the IMSI from unicode to UTF8 characters.
completion_status = imsiInUnicode.set_buffer(iSubscriberId.Ptr(), iSubscriberId.Size(), false, false);
@@ -254,6 +268,7 @@
break;
case EQueryRES:
+
EAP_TRACE_DEBUG(m_am_tools, TRACE_FLAGS_DEFAULT, (EAPL("####AKA interface: Got RES, CK, IK and AUTS reply. ####\n")));
EAP_TRACE_DATA_DEBUG(m_am_tools, TRACE_FLAGS_DEFAULT, (EAPL("RES"),
@@ -272,6 +287,8 @@
iEAPAka.iAUTS.Ptr(),
iEAPAka.iAUTS.Size()));
+ iQueryId = EQueryNone;
+
delete iAuthenticationData;
iAuthenticationData = NULL;
@@ -326,6 +343,7 @@
case EQueryIMSI:
// Error with IMSI. Reset it and complete the request.
+ iQueryId = EQueryNone;
imsi.reset();
EAP_TRACE_DEBUG(m_am_tools, TRACE_FLAGS_DEFAULT, (EAPL("AKA interface: Error in IMSI.\n")));
@@ -337,6 +355,7 @@
// Re-synchronization needed or error with RES or CK or IK.
// We have to close the custom API anyway.
+ iQueryId = EQueryNone;
iCustomAPI.Close();
EAP_TRACE_DEBUG(m_am_tools, TRACE_FLAGS_DEFAULT, (EAPL("CEapAkaInterface::RunL() - error case: CLOSED CUSTOM API \n")));
@@ -408,7 +427,8 @@
TInt CEapAkaInterface::CreateMMETelConnectionL()
{
EAP_TRACE_BEGIN(m_am_tools, TRACE_FLAGS_DEFAULT);
- EAP_TRACE_DEBUG(m_am_tools, TRACE_FLAGS_DEFAULT, (EAPL("Creating MMETel connection.\n")));
+ EAP_TRACE_DEBUG(m_am_tools, TRACE_FLAGS_DEFAULT, (EAPL("CEapAkaInterface::CreateMMETelConnectionL()\n")));
+ EAP_TRACE_RETURN_STRING(m_am_tools, "returns: CEapAkaInterface::CreateMMETelConnectionL()");
TInt errorCode = KErrNone;
@@ -470,6 +490,14 @@
void CEapAkaInterface::DisconnectMMETel()
{
+ EAP_TRACE_DEBUG(m_am_tools, TRACE_FLAGS_DEFAULT, (EAPL("CEapAkaInterface::DisconnectMMETel()\n")));
+ EAP_TRACE_RETURN_STRING(m_am_tools, "returns: CEapAkaInterface::DisconnectMMETel()");
+
+ iQueryId = EQueryNone;
+
+ // Close the custom API since we don't need it any more.
+ iCustomAPI.Close();
+
if( iMMETELConnectionStatus )
{
EAP_TRACE_DEBUG(m_am_tools, TRACE_FLAGS_DEFAULT, (EAPL("Closing RMobilePhone and MMETEL.\n")));
--- a/eapol/eapol_framework/eapol_symbian/am/type/gsmsim/symbian/EapSimInterface.cpp Mon Jun 21 15:44:11 2010 +0300
+++ b/eapol/eapol_framework/eapol_symbian/am/type/gsmsim/symbian/EapSimInterface.cpp Thu Aug 19 09:58:27 2010 +0300
@@ -16,7 +16,7 @@
*/
/*
-* %version: 15 %
+* %version: 15.1.5 %
*/
// This is enumeration of EAPOL source code.
@@ -30,6 +30,7 @@
// INCLUDE FILES
#include "EapSimInterface.h"
+#include "eap_automatic_variable.h"
#include <mmtsy_names.h>
#include "eap_sim_triplets.h" // For SIM_SRES_LENGTH.
@@ -46,6 +47,8 @@
, iMMETELConnectionStatus(EFalse)
{
EAP_TRACE_BEGIN(m_am_tools, TRACE_FLAGS_DEFAULT);
+ EAP_TRACE_DEBUG(m_am_tools, TRACE_FLAGS_DEFAULT, (EAPL("CEapSimIsaInterface::CEapSimIsaInterface()\n")));
+ EAP_TRACE_RETURN_STRING(m_am_tools, "returns: CEapSimIsaInterface::CEapSimIsaInterface()");
EAP_TRACE_END(m_am_tools, TRACE_FLAGS_DEFAULT);
}
@@ -77,17 +80,16 @@
CEapSimIsaInterface::~CEapSimIsaInterface()
{
EAP_TRACE_BEGIN(m_am_tools, TRACE_FLAGS_DEFAULT);
+ EAP_TRACE_DEBUG(m_am_tools, TRACE_FLAGS_DEFAULT, (EAPL("CEapSimIsaInterface::~CEapSimIsaInterface()\n")));
+ EAP_TRACE_RETURN_STRING(m_am_tools, "returns: CEapSimIsaInterface::~CEapSimIsaInterface()");
if(IsActive())
{
- Cancel();
+ Cancel();
}
- EAP_TRACE_DEBUG(m_am_tools, TRACE_FLAGS_DEFAULT, (EAPL("Closing RMobilePhone and MMETEL.\n")));
-
- iPhone.Close();
- iServer.Close(); // Phone module is unloaded automatically when RTelServer session is closed
-
+ DisconnectMMETel();
+
delete iAuthenticationData;
iAuthenticationData = NULL;
@@ -99,8 +101,9 @@
void CEapSimIsaInterface::QueryIMSIL()
{
EAP_TRACE_BEGIN(m_am_tools, TRACE_FLAGS_DEFAULT);
- EAP_TRACE_DEBUG(m_am_tools, TRACE_FLAGS_DEFAULT, (EAPL("ISA interface: Querying IMSI.\n")));
-
+ EAP_TRACE_DEBUG(m_am_tools, TRACE_FLAGS_DEFAULT, (EAPL("CEapSimIsaInterface::QueryIMSIL()\n")));
+ EAP_TRACE_RETURN_STRING(m_am_tools, "returns: CEapSimIsaInterface::QueryIMSIL()");
+
iQueryId = EQueryIMSI;
// Create MMETEl connection.
@@ -121,7 +124,8 @@
void CEapSimIsaInterface::QueryKcAndSRESL(const TDesC8& aRand)
{
EAP_TRACE_BEGIN(m_am_tools, TRACE_FLAGS_DEFAULT);
- EAP_TRACE_DEBUG(m_am_tools, TRACE_FLAGS_DEFAULT, (EAPL("ISA interface: Querying Kc and SRES.\n")));
+ EAP_TRACE_DEBUG(m_am_tools, TRACE_FLAGS_DEFAULT, (EAPL("CEapSimIsaInterface::QueryKcAndSRESL()\n")));
+ EAP_TRACE_RETURN_STRING(m_am_tools, "returns: CEapSimIsaInterface::QueryKcAndSRESL()");
iQueryId = EQuerySRESandKC;
@@ -161,10 +165,19 @@
void CEapSimIsaInterface::DoCancel()
{
- EAP_TRACE_DEBUG(m_am_tools, TRACE_FLAGS_DEFAULT, (EAPL("CEapSimIsaInterface::DoCancel() - Cancelling MMETEL query.\n") ) );
-
- // Cancel the request.
- iCustomAPI.CancelAsyncRequest( ECustomGetSimAuthenticationDataIPC );
+ EAP_TRACE_DEBUG(m_am_tools, TRACE_FLAGS_DEFAULT, (EAPL("CEapSimIsaInterface::DoCancel(): iQueryId=%d\n"),
+ iQueryId) );
+ EAP_TRACE_RETURN_STRING(m_am_tools, "returns: CEapSimIsaInterface::DoCancel()");
+
+ if (iQueryId == EQuerySRESandKC)
+ {
+ iQueryId = EQueryNone;
+
+ // Cancel the request.
+ iCustomAPI.CancelAsyncRequest( ECustomGetSimAuthenticationDataIPC );
+
+ EAP_TRACE_DEBUG(m_am_tools, TRACE_FLAGS_DEFAULT, (EAPL("CEapSimIsaInterface::DoCancel(): CANCELLED CUSTOM API REQUEST\n") ) );
+ }
}
//--------------------------------------------------
@@ -172,8 +185,11 @@
void CEapSimIsaInterface::RunL()
{
EAP_TRACE_BEGIN(m_am_tools, TRACE_FLAGS_DEFAULT);
- EAP_TRACE_DEBUG(m_am_tools, TRACE_FLAGS_DEFAULT, (EAPL("CEapSimIsaInterface::RunL(). iStatus.Int() =%d \n"), iStatus.Int() ));
-
+ EAP_TRACE_DEBUG(m_am_tools, TRACE_FLAGS_DEFAULT, (EAPL("CEapSimIsaInterface::RunL(). iStatus.Int()=%d, iQueryId=%d\n"),
+ iStatus.Int(),
+ iQueryId));
+ EAP_TRACE_RETURN_STRING(m_am_tools, "returns: CEapSimIsaInterface::RunL()");
+
TInt error = KErrNone;
eap_variable_data_c imsi(m_am_tools); // Keeping it here to avoid "error" in ARMV5 build.
@@ -193,7 +209,9 @@
EAP_TRACE_DATA_DEBUG(m_am_tools, TRACE_FLAGS_DEFAULT, (EAPL("IMSI"),
iSubscriberId.Ptr(),
iSubscriberId.Size()));
-
+
+ iQueryId = EQueryNone;
+
// Convert the IMSI from unicode to UTF8 characters.
completion_status = imsiInUnicode.set_buffer(iSubscriberId.Ptr(), iSubscriberId.Size(), false, false);
@@ -213,7 +231,9 @@
EAP_TRACE_DEBUG(m_am_tools, TRACE_FLAGS_DEFAULT, (EAPL("ISA interface: Could not convert IMSI from UNICODE to UTF8. Not proceeding further here.\n")));
}
}
-
+
+ DisconnectMMETel();
+
TRAP(error, iParent->complete_SIM_imsi_L(&imsi, completion_status));
break;
@@ -229,6 +249,8 @@
iEAPSim.iKC.Ptr(),
iEAPSim.iKC.Size()));
+ iQueryId = EQueryNone;
+
// Trim the length of SRES - Remove once the correct length is set for SRES, may be by the API or some where else.
iEAPSim.iSRES.SetLength(SIM_SRES_LENGTH);
EAP_TRACE_DATA_DEBUG(m_am_tools, TRACE_FLAGS_DEFAULT, (EAPL("SRES after Trimming"),
@@ -238,9 +260,8 @@
delete iAuthenticationData;
iAuthenticationData = NULL;
- // Close the custom API since we don't need it any more.
- iCustomAPI.Close();
-
+ DisconnectMMETel();
+
// Complete
TRAP(error, iParent->complete_SIM_kc_and_sres_L(iEAPSim.iKC, iEAPSim.iSRES, completion_status));
@@ -253,9 +274,9 @@
if( EQuerySRESandKC == iQueryId )
{
- // We have to close the custom API anyway.
- // Rest will be taken care in destructor.
- iCustomAPI.Close();
+ iQueryId = EQueryNone;
+
+ DisconnectMMETel();
// Handle duplicate RAND values.
// If duplicate RAND values are being used, we get KErrArgument here.
@@ -276,17 +297,24 @@
{
completion_status = m_am_tools->convert_am_error_to_eapol_error(iStatus.Int());
+ iQueryId = EQueryNone;
+
+ DisconnectMMETel();
+
TRAP(error, iParent->complete_SIM_imsi_L(&imsi, completion_status));
}
}
-
+
EAP_TRACE_END(m_am_tools, TRACE_FLAGS_DEFAULT);
}
+//--------------------------------------------------
+
TInt CEapSimIsaInterface::CreateMMETelConnectionL()
{
EAP_TRACE_BEGIN(m_am_tools, TRACE_FLAGS_DEFAULT);
- EAP_TRACE_DEBUG(m_am_tools, TRACE_FLAGS_DEFAULT, (EAPL("Creating MMETel connection.\n")));
+ EAP_TRACE_DEBUG(m_am_tools, TRACE_FLAGS_DEFAULT, (EAPL("CEapSimIsaInterface::CreateMMETelConnectionL()\n")));
+ EAP_TRACE_RETURN_STRING(m_am_tools, "returns: CEapSimIsaInterface::CreateMMETelConnectionL()");
TInt errorCode = KErrNone;
@@ -346,4 +374,30 @@
return errorCode;
}
+void CEapSimIsaInterface::DisconnectMMETel()
+{
+ EAP_TRACE_DEBUG(m_am_tools, TRACE_FLAGS_DEFAULT, (EAPL("CEapSimIsaInterface::DisconnectMMETel()\n")));
+ EAP_TRACE_RETURN_STRING(m_am_tools, "returns: CEapSimIsaInterface::DisconnectMMETel()");
+
+ iQueryId = EQueryNone;
+
+ // Close the custom API since we don't need it any more.
+ iCustomAPI.Close();
+
+ if( iMMETELConnectionStatus )
+ {
+ EAP_TRACE_DEBUG(m_am_tools, TRACE_FLAGS_DEFAULT, (EAPL("Closing RMobilePhone and MMETEL.\n")));
+
+ iPhone.Close();
+ iServer.Close(); // Phone module is unloaded automatically when RTelServer session is closed
+
+ iMMETELConnectionStatus = EFalse;
+ }
+ else
+ {
+ EAP_TRACE_DEBUG(m_am_tools, TRACE_FLAGS_DEFAULT, (EAPL("RMobilePhone and MMETEL already closed.\n")));
+ }
+}
+
+
// End of file
--- a/wlansecuritysettings/wpasecuritysettingsui/data/WPASecuritySettingsUI.rss Mon Jun 21 15:44:11 2010 +0300
+++ b/wlansecuritysettings/wpasecuritysettingsui/data/WPASecuritySettingsUI.rss Thu Aug 19 09:58:27 2010 +0300
@@ -16,7 +16,7 @@
*/
/*
-* %version: tr1cfwln#20 %
+* %version: tr1cfwln#21 %
*/
// RESOURCE IDENTIFIER
@@ -271,7 +271,12 @@
{
buf = qtn_wlan_sett_allow_tkip;
}
-
+
+RESOURCE TBUF r_wpa_unencrypted_conn
+ {
+ buf = qtn_wlan_sett_unencrypted_conn;
+ }
+
RESOURCE TBUF r_wpa_mode_eap
{
buf = qtn_wlan_sett_wpa_mode_eap;
@@ -292,6 +297,16 @@
buf = qtn_wlan_sett_tkip_not_allowed;
}
+RESOURCE TBUF r_wpa_unencrypted_conn_not_allow
+ {
+ buf = qtn_wlan_sett_unencrypted_conn_not_allow;
+ }
+
+RESOURCE TBUF r_wpa_unencrypted_conn_allow
+ {
+ buf = qtn_wlan_sett_unencrypted_conn_allow;
+ }
+
RESOURCE TBUF r_wpa_preshared_key_must_be_defined
{
buf = qtn_selec_setting_compulsory;
--- a/wlansecuritysettings/wpasecuritysettingsui/inc/WPASecuritySettingsDlg.h Mon Jun 21 15:44:11 2010 +0300
+++ b/wlansecuritysettings/wpasecuritysettingsui/inc/WPASecuritySettingsDlg.h Thu Aug 19 09:58:27 2010 +0300
@@ -16,7 +16,7 @@
*/
/*
-* %version: tr1cfwln#20 %
+* %version: tr1cfwln#21 %
*/
#ifndef WPA_SECURITY_SETTINGS_DLG_H
@@ -31,7 +31,8 @@
EWpaMode, // WPA mode
EWpaEapConfig, // EAP Plugin configuration
EWpaWpa2Only, // Wpa2 only mode
- EWpaPreSharedKey // Pre-shared key
+ EWpaPreSharedKey, // Pre-shared key
+ EWpaUnencryptedConn
};
--- a/wlansecuritysettings/wpasecuritysettingsui/inc/WPASecuritySettingsImpl.h Mon Jun 21 15:44:11 2010 +0300
+++ b/wlansecuritysettings/wpasecuritysettingsui/inc/WPASecuritySettingsImpl.h Thu Aug 19 09:58:27 2010 +0300
@@ -16,7 +16,7 @@
*/
/*
-* %version: tr1cfwln#26 %
+* %version: tr1cfwln#28 %
*/
#ifndef WPASECURITYSETTINGSIMPL_H
@@ -161,6 +161,20 @@
*/
inline void SetWpa2Only( const TBool aAllowed );
+
+ /**
+ * Tells if 802.1x Unencrypted connection is allowed
+ * @return ETrue if Unencrypted connection is allowed
+ */
+ inline TBool WPAUnencryptedConn() const;
+
+
+ /**
+ * Sets the 802.1x Unencrypted connection enabling variable
+ * @param aUnencryptedConn ETrue if Unencrypted connection is allowed
+ */
+ inline void SetWPAUnencryptedConn( const TBool aUnencryptedConn );
+
/**
* Returns the Pre-shared key
@@ -290,6 +304,9 @@
// WPA2 Only mode enabled or not
TBool iWpa2Only;
+
+ // 802.1x unencrypted connection allowed or not
+ TBool iWPAUnencryptedConn;
// The Id of the AP.
TUint32 iIapId;
--- a/wlansecuritysettings/wpasecuritysettingsui/inc/WPASecuritySettingsImpl.inl Mon Jun 21 15:44:11 2010 +0300
+++ b/wlansecuritysettings/wpasecuritysettingsui/inc/WPASecuritySettingsImpl.inl Thu Aug 19 09:58:27 2010 +0300
@@ -16,7 +16,7 @@
*/
/*
-* %version: tr1cfwln#15 %
+* %version: tr1cfwln#16 %
*/
#ifndef WPASECURITYSETTINGSIMPL_INL
@@ -54,6 +54,16 @@
// ---------------------------------------------------------
+// CWPASecuritySettingsImpl::WPAUnencryptedConn
+// ---------------------------------------------------------
+//
+inline TBool CWPASecuritySettingsImpl::WPAUnencryptedConn() const
+ {
+ return iWPAUnencryptedConn;
+ }
+
+
+// ---------------------------------------------------------
// CWPASecuritySettingsImpl::WPAPreSharedKey
// ---------------------------------------------------------
//
@@ -113,6 +123,15 @@
}
+// ---------------------------------------------------------
+// CWPASecuritySettingsImpl::SetWPAUnencryptedConn
+// ---------------------------------------------------------
+//
+inline void CWPASecuritySettingsImpl::SetWPAUnencryptedConn( const TBool aUnencryptedConn )
+ {
+ iWPAUnencryptedConn = aUnencryptedConn;
+ }
+
// ---------------------------------------------------------
// CWPASecuritySettingsImpl::SetWPAPreSharedKey
--- a/wlansecuritysettings/wpasecuritysettingsui/loc/wpasecuritysettingsui.loc Mon Jun 21 15:44:11 2010 +0300
+++ b/wlansecuritysettings/wpasecuritysettingsui/loc/wpasecuritysettingsui.loc Thu Aug 19 09:58:27 2010 +0300
@@ -16,7 +16,7 @@
*/
/*
-* %version: %
+* %version: tr1cfwln#7 %
*/
// LOCALISATION STRINGS
@@ -63,6 +63,14 @@
#define qtn_wlan_sett_allow_tkip "WPA2-only mode"
+//d:Fourth element of the Selection List
+//l:list_setting_pane_t1
+//w:
+//r:5.0
+//
+#define qtn_wlan_sett_unencrypted_conn "Unencrypted connection"
+
+
//d:Setting item for the first element of the Selection List
//d:(qtn_wlan_sett_wpa_mode)
//l:list_set_graphic_pane_t1
@@ -99,6 +107,24 @@
#define qtn_wlan_sett_tkip_not_allowed "Yes"
+//d:Setting item for the fourth element of the Selection List
+//d:(qtn_wlan_sett_unencrypted_conn)
+//l:list_set_graphic_pane_t1
+//w:
+//r:5.0
+//
+#define qtn_wlan_sett_unencrypted_conn_not_allow "Not allowed"
+
+
+//d:Setting item for the fourth element of the Selection List
+//d:(qtn_wlan_sett_unencrypted_conn)
+//l:list_set_graphic_pane_t1
+//w:
+//r:5.0
+//
+#define qtn_wlan_sett_unencrypted_conn_allow "Allowed"
+
+
//d:Information note for the user when the entered key is too short
//l:popup_snote_single_text_window
//w:
--- a/wlansecuritysettings/wpasecuritysettingsui/src/WPASecuritySettingsDlg.cpp Mon Jun 21 15:44:11 2010 +0300
+++ b/wlansecuritysettings/wpasecuritysettingsui/src/WPASecuritySettingsDlg.cpp Thu Aug 19 09:58:27 2010 +0300
@@ -16,7 +16,7 @@
*/
/*
-* %version: tr1cfwln#31 %
+* %version: tr1cfwln#33 %
*/
// INCLUDE FILES
@@ -115,20 +115,22 @@
{
CleanupStack::PushL( this );
- const TInt Titles_Wpa_Main[KNumOfFieldsMain+1] =
+ const TInt Titles_Wpa_Main[KNumOfFieldsMain+2] =
{
R_WPA_MODE,
R_WPA_EAP_CONFIG,
R_WPA_MODE_PRESHARED_KEY,
- R_WPA_TKIP_CIPHER
+ R_WPA_TKIP_CIPHER,
+ R_WPA_UNENCRYPTED_CONN
};
- const TInt Fields_Wpa_Main[KNumOfFieldsMain+1] =
+ const TInt Fields_Wpa_Main[KNumOfFieldsMain+2] =
{
EWpaMode,
EWpaEapConfig,
EWpaPreSharedKey,
- EWpaWpa2Only
+ EWpaWpa2Only,
+ EWpaUnencryptedConn
};
iSecuritySettings = aSecuritySettings;
@@ -383,7 +385,13 @@
default:
{
- __ASSERT_DEBUG( EFalse, Panic( EUnknownCase ) );
+ // New events like
+ // EEventPanningStarted
+ // EEventPanningStopped
+ // EEventFlickStarted
+ // EEventFlickStopped
+ // EEventEmptyListClicked
+ // EEventEmptyAreaClicked
break;
};
};
@@ -459,6 +467,14 @@
for( TInt i = 0; i < numOfFields; i++ )
{
+ // 802.1x has no WpaMode (PSK not supported) and no Wpa2Only selection
+ if ( iSecuritySettings->SecurityMode() == ESecurityMode8021x &&
+ (*wpaMember == EWpaMode ||*wpaMember == EWpaWpa2Only ) )
+ {
+ wpaMember++;
+ aRes++;
+ }
+ // If PSK in use, EAP plug-in configuration is not shown
if ( *wpaMember == EWpaEapConfig && iSecuritySettings->WPAMode() )
{
wpaMember++;
@@ -484,15 +500,20 @@
CleanupStack::PopAndDestroy( 2, title ); // itemText, title
+ // If Eap in use, PreSharedKey is not shown
wpaMember++;
aRes++;
}
- else // EWpaMode, EWpaPreSharedKey, EWpaWpa2Only:
+ else // EWpaMode, EWpaPreSharedKey, EWpaWpa2Only, EWpaUnencryptedConn:
{
- HBufC* itemText = CreateTextualListBoxItemL( *wpaMember, *aRes );
- CleanupStack::PushL( itemText );
- aItemArray.AppendL( itemText->Des() );
- CleanupStack::PopAndDestroy( itemText );
+ if (( *wpaMember != EWpaUnencryptedConn ) ||
+ (FeatureManager::FeatureSupported( KFeatureIdFfWlanAuthenticationOnlySupport ) ) )
+ {
+ HBufC* itemText = CreateTextualListBoxItemL( *wpaMember, *aRes );
+ CleanupStack::PushL( itemText );
+ aItemArray.AppendL( itemText->Des() );
+ CleanupStack::PopAndDestroy( itemText );
+ }
}
wpaMember++;
@@ -579,6 +600,13 @@
break;
}
+ case EWpaUnencryptedConn:
+ {
+ valueResourceID = iSecuritySettings->WPAUnencryptedConn() ?
+ R_WPA_UNENCRYPTED_CONN_ALLOW : R_WPA_UNENCRYPTED_CONN_NOT_ALLOW;
+ break;
+ }
+
case EWpaPreSharedKey:
{
valueResourceID =
@@ -645,9 +673,19 @@
{
TInt currvalue( 0 );
TBool retval( EFalse );
+ TInt attr_resid( 0 );
+
CDesCArrayFlat* items = FillPopupSettingPageLC( aData, currvalue );
- TInt attr_resid = aData == EWpaMode ? R_WPA_MODE : R_WPA_TKIP_CIPHER;
+
+ if ( aData == EWpaUnencryptedConn)
+ {
+ attr_resid = R_WPA_UNENCRYPTED_CONN;
+ }
+ else
+ {
+ attr_resid = aData == EWpaMode ? R_WPA_MODE : R_WPA_TKIP_CIPHER;
+ }
HBufC* titlebuf = iEikonEnv->AllocReadResourceLC( attr_resid );
CAknRadioButtonSettingPage* dlg = new ( ELeave )CAknRadioButtonSettingPage(
@@ -781,7 +819,7 @@
R_WPA_MODE_PRESHARED_KEY ) );
CleanupStack::PopAndDestroy();
}
- else // EWpaWpa2Only:
+ else if ( aData == EWpaWpa2Only )
{
items->AppendL( *iEikonEnv->AllocReadResourceLC(
R_WPA_CIPHER_ALLOWED ) );
@@ -792,7 +830,18 @@
aCurrvalue = iSecuritySettings->Wpa2Only();
}
+ else // EWpaUnencryptedConn
+ {
+ items->AppendL( *iEikonEnv->AllocReadResourceLC(
+ R_WPA_UNENCRYPTED_CONN_NOT_ALLOW ) );
+ CleanupStack::PopAndDestroy();
+ items->AppendL( *iEikonEnv->AllocReadResourceLC(
+ R_WPA_UNENCRYPTED_CONN_ALLOW ) );
+ CleanupStack::PopAndDestroy();
+ aCurrvalue = iSecuritySettings->WPAUnencryptedConn();
+ }
+
return items;
}
@@ -819,7 +868,7 @@
retVal = ETrue;
}
}
- else // EWpaWpa2Only:
+ else if ( aData == EWpaWpa2Only )
{
if ( iSecuritySettings->Wpa2Only() != aCurrvalue )
{
@@ -827,6 +876,14 @@
retVal = ETrue;
}
}
+ else // EWpaUnencryptedConn
+ {
+ if ( iSecuritySettings->WPAUnencryptedConn() != aCurrvalue )
+ {
+ iSecuritySettings->SetWPAUnencryptedConn( aCurrvalue );
+ retVal = ETrue;
+ }
+ }
return retVal;
}
@@ -858,10 +915,18 @@
itemIndex = ( Max( iList->CurrentItemIndex(), 0 ) );
- shift = ( itemIndex >= EWpaWpa2Only ||
- ( itemIndex == EWpaEapConfig &&
- iSecuritySettings->WPAMode() ) ) ? 1 : 0;
-
+ //In 802.1x the first item is EapConfig and second item is UncryptedConn
+ if (iSecuritySettings->SecurityMode() == ESecurityMode8021x)
+ {
+ shift = ( itemIndex == EWpaMode ) ? 1 : 3;
+ }
+ else
+ {
+ shift = ( itemIndex >= EWpaWpa2Only ||
+ ( itemIndex == EWpaEapConfig &&
+ iSecuritySettings->WPAMode() ) ) ? 1 : 0;
+ }
+
TWpaMember* ptr = iFieldsMain + itemIndex + shift;
TInt* titPtr = iTitlesMain + itemIndex + shift;
@@ -924,6 +989,27 @@
break;
}
+ case EWpaUnencryptedConn:
+ { // Setting item with two available values
+ TBool changed( ETrue );
+ if ( aQuick )
+ {
+ iSecuritySettings->SetWPAUnencryptedConn(
+ !iSecuritySettings->WPAUnencryptedConn() );
+ }
+ else
+ {
+ changed = ShowPopupSettingPageL( EWpaUnencryptedConn );
+ }
+
+ if ( changed )
+ {
+ UpdateTextualListBoxItemL( *ptr, *titPtr, itemIndex );
+ *iEventStore |= CWPASecuritySettings::EModified;
+ }
+ break;
+ }
+
case EWpaPreSharedKey:
{ // Text setting item
if ( ShowPopupTextSettingPageL() )
--- a/wlansecuritysettings/wpasecuritysettingsui/src/WPASecuritySettingsImpl.cpp Mon Jun 21 15:44:11 2010 +0300
+++ b/wlansecuritysettings/wpasecuritysettingsui/src/WPASecuritySettingsImpl.cpp Thu Aug 19 09:58:27 2010 +0300
@@ -16,7 +16,7 @@
*/
/*
-* %version: tr1cfwln#27 %
+* %version: tr1cfwln#29 %
*/
// INCLUDE FILES
@@ -69,7 +69,8 @@
TSecurityMode aSecurityMode )
: iSecurityMode( aSecurityMode ),
iWPAMode( EFalse ),
- iWpa2Only( EFalse )
+ iWpa2Only( EFalse ),
+ iWPAUnencryptedConn( EFalse )
{
iWPAEAPPlugin.Zero();
iWPAPreSharedKey.Zero();
@@ -123,18 +124,26 @@
TInt errorCode = wLanServiceTable->GotoFirstRecord();
if ( errorCode == KErrNone )
{
- // Get WPA Mode
- TRAPD( err, wLanServiceTable->ReadUintL( TPtrC( WLAN_ENABLE_WPA_PSK ),
- ( TUint32& ) iWPAMode ) );
- if ( err != KErrNone )
- { // do not leave if value is not present in table...
- if ( err != KErrUnknown )
- User::Leave( err );
+ if ( iSecurityMode == ESecurityMode8021x )
+ {
+ // in 802.1x PSK mode is not supported
+ iWPAMode = EFalse;
}
-
+ else
+ {
+ // Get WPA Mode
+ TRAPD( err, wLanServiceTable->ReadUintL( TPtrC( WLAN_ENABLE_WPA_PSK ),
+ ( TUint32& ) iWPAMode ) );
+ if ( err != KErrNone )
+ { // do not leave if value is not present in table...
+ if ( err != KErrUnknown )
+ User::Leave( err );
+ }
+ }
+
TUint32 secMode = 0;
// Get WPA2 Only Mode
- TRAP( err, wLanServiceTable->ReadUintL( TPtrC( WLAN_SECURITY_MODE ),
+ TRAPD( err, wLanServiceTable->ReadUintL( TPtrC( WLAN_SECURITY_MODE ),
secMode ) );
if ( err != KErrNone )
{ // do not leave if value is not present in table...
@@ -144,6 +153,19 @@
iWpa2Only = secMode == EWpa2;
+ // Get Unencrypted Connection mode for 802.1x
+ if ( iSecurityMode == ESecurityMode8021x )
+ {
+ // WLAN_WPA_KEY_LENGTH is used also for Unencrypted Connection mode
+ TRAPD( err2, wLanServiceTable->ReadUintL( TPtrC( WLAN_WPA_KEY_LENGTH ),
+ ( TUint32& ) iWPAUnencryptedConn ) );
+ if ( err2 != KErrNone )
+ { // do not leave if value is not present in table...
+ if ( err2 != KErrUnknown )
+ User::Leave( err2 );
+ }
+ }
+
// Get EAP list
iWPAEAPPlugin.Copy( *wLanServiceTable->ReadLongTextLC(
TPtrC( WLAN_EAPS ) ) );
@@ -248,8 +270,11 @@
}
// Get PreShared Key
- wLanServiceTable->ReadTextL( TPtrC( WLAN_WPA_PRE_SHARED_KEY ),
+ if ( iSecurityMode != ESecurityMode8021x )
+ {
+ wLanServiceTable->ReadTextL( TPtrC( WLAN_WPA_PRE_SHARED_KEY ),
iWPAPreSharedKey );
+ }
if ( !IsValidPsk( iWPAPreSharedKey ) )
{
@@ -293,8 +318,11 @@
}
// Save WPA Mode
- wLanServiceTable->WriteUintL( TPtrC( WLAN_ENABLE_WPA_PSK ),
+ if ( iSecurityMode != ESecurityMode8021x )
+ {
+ wLanServiceTable->WriteUintL( TPtrC( WLAN_ENABLE_WPA_PSK ),
( TUint32& ) iWPAMode );
+ }
TUint32 secMode;
@@ -331,13 +359,26 @@
iWPADisabledEAPPlugin?
(const TDesC8&)*iWPADisabledEAPPlugin:
(const TDesC8&)KNullDesC8 );
- // Save PreShared Key
- wLanServiceTable->WriteTextL( TPtrC( WLAN_WPA_PRE_SHARED_KEY ),
- iWPAPreSharedKey );
+
+
- // Save PreShared Key Length
- wLanServiceTable->WriteUintL( TPtrC( WLAN_WPA_KEY_LENGTH ),
- iWPAPreSharedKey.Length() );
+ if ( iSecurityMode == ESecurityMode8021x )
+ {
+ // In 802.1x WpaKeyLength is not used
+ // and the field is reused to save UnencryptedConn mode
+ wLanServiceTable->WriteUintL( TPtrC( WLAN_WPA_KEY_LENGTH ),
+ ( TUint32& ) iWPAUnencryptedConn );
+ }
+ else
+ {
+ // Save PreShared Key
+ wLanServiceTable->WriteTextL( TPtrC( WLAN_WPA_PRE_SHARED_KEY ),
+ iWPAPreSharedKey );
+
+ // Save PreShared Key Length
+ wLanServiceTable->WriteUintL( TPtrC( WLAN_WPA_KEY_LENGTH ),
+ iWPAPreSharedKey.Length() );
+ }
wLanServiceTable->PutRecordChanges();
@@ -542,16 +583,32 @@
if( generic->FindL( aSession) )
{
- // Get WPA mode
- CMDBField<TUint>* enableWpaPskField = static_cast<CMDBField<TUint>*>
+ if ( iSecurityMode == ESecurityMode8021x )
+ {
+ // in 802.1x PSK mode is not supported
+ iWPAMode = EFalse;
+ }
+ else
+ {
+ // Get WPA mode
+ CMDBField<TUint>* enableWpaPskField = static_cast<CMDBField<TUint>*>
( generic->GetFieldByIdL( KCDTIdWlanEnableWpaPsk ) );
- iWPAMode = *enableWpaPskField;
+ iWPAMode = *enableWpaPskField;
+ }
// Get WPA2 Only Mode
CMDBField<TUint>* secModeField = static_cast<CMDBField<TUint>*>
( generic->GetFieldByIdL( KCDTIdWlanSecMode ) );
TUint32 secMode = *secModeField;
iWpa2Only = secMode == EWpa2;
+
+ // Get 802.1x Unencrypted Connection saved in reused WpaKeyLengthField
+ if ( iSecurityMode == ESecurityMode8021x )
+ {
+ CMDBField<TUint>* WpaKeyLengthField = static_cast<CMDBField<TUint>*>
+ ( generic->GetFieldByIdL( KCDTIdWlanWpaKeyLength ) );
+ iWPAUnencryptedConn = *WpaKeyLengthField;
+ }
// Get EAP plugins
CMDBField<TDesC>* wlanEapsField = static_cast<CMDBField<TDesC>*>
@@ -652,10 +709,13 @@
}
// GetWPA preshared key
- CMDBField<TDesC8>* wpaPskField = static_cast<CMDBField<TDesC8>*>
+ if ( iSecurityMode != ESecurityMode8021x )
+ {
+ CMDBField<TDesC8>* wpaPskField = static_cast<CMDBField<TDesC8>*>
( generic->GetFieldByIdL( KCDTIdWlanWpaPreSharedKey ) );
- iWPAPreSharedKey = *wpaPskField;
-
+ iWPAPreSharedKey = *wpaPskField;
+ }
+
if ( !IsValidPsk( iWPAPreSharedKey ) )
{
// invalid key format
@@ -698,11 +758,14 @@
// If loading failed, WLAN service record will be
// created and StoreL()-d, otherwise, ModifyL()
-
- // Set WPA mode
- CMDBField<TUint>* enableWpaPskField = static_cast<CMDBField<TUint>*>
- ( generic->GetFieldByIdL( KCDTIdWlanEnableWpaPsk ) );
- enableWpaPskField->SetL( iWPAMode );
+
+ if ( iSecurityMode != ESecurityMode8021x )
+ {
+ // Set WPA mode
+ CMDBField<TUint>* enableWpaPskField = static_cast<CMDBField<TUint>*>
+ ( generic->GetFieldByIdL( KCDTIdWlanEnableWpaPsk ) );
+ enableWpaPskField->SetL( iWPAMode );
+ }
// Set security mode
TUint32 secMode;
@@ -745,15 +808,23 @@
(const TDesC8&)*iWPADisabledEAPPlugin:
(const TDesC8&)KNullDesC8 );
- // Save PreShared Key
- CMDBField<TDesC8>* wpaPskField = static_cast<CMDBField<TDesC8>*>
- ( generic->GetFieldByIdL( KCDTIdWlanWpaPreSharedKey ) );
- wpaPskField->SetL( iWPAPreSharedKey );
-
// Save PreShared Key length
CMDBField<TUint>* keyLengthField = static_cast<CMDBField<TUint>*>
( generic->GetFieldByIdL( KCDTIdWlanWpaKeyLength ) );
- keyLengthField->SetL( iWPAPreSharedKey.Length() );
+ if ( iSecurityMode == ESecurityMode8021x )
+ {
+ // In 802.1x keyLengthField is reused to contain Unencrypted Connection info
+ keyLengthField->SetL( iWPAUnencryptedConn );
+ }
+ else
+ {
+ keyLengthField->SetL( iWPAPreSharedKey.Length() );
+
+ // Save PreShared Key
+ CMDBField<TDesC8>* wpaPskField = static_cast<CMDBField<TDesC8>*>
+ ( generic->GetFieldByIdL( KCDTIdWlanWpaPreSharedKey ) );
+ wpaPskField->SetL( iWPAPreSharedKey );
+ }
TInt error( KErrNone );