eapol/eapol_framework/eapol_common/include/eap_pac_store_message_base.h
branchRCL_3
changeset 19 c74b3d9f6b9e
parent 18 bad0cc58d154
equal deleted inserted replaced
18:bad0cc58d154 19:c74b3d9f6b9e
     1 /*
       
     2 * Copyright (c) 2001-2006 Nokia Corporation and/or its subsidiary(-ies).
       
     3 * All rights reserved.
       
     4 * This component and the accompanying materials are made available
       
     5 * under the terms of the License "Eclipse Public License v1.0"
       
     6 * which accompanies this distribution, and is available
       
     7 * at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     8 *
       
     9 * Initial Contributors:
       
    10 * Nokia Corporation - initial contribution.
       
    11 *
       
    12 * Contributors:
       
    13 *
       
    14 * Description:  EAP and WLAN authentication protocols.
       
    15 *
       
    16 */
       
    17 
       
    18 /*
       
    19 * %version: %
       
    20 */
       
    21 
       
    22 #if !defined(_EAP_PAC_STORE_MESSAGE_BASE_H_)
       
    23 #define _EAP_PAC_STORE_MESSAGE_BASE_H_
       
    24 
       
    25 #include "eap_tools.h"
       
    26 #include "eap_am_export.h"
       
    27 
       
    28 class eap_method_settings_c;
       
    29 class abs_eap_pac_store_message_c;
       
    30 
       
    31 /// A eap_pac_store_message_base_c class implements mapping of EAP authentication sessions.
       
    32 /// Network identity separates parallel EAP authentication sessions.
       
    33 class EAP_EXPORT eap_pac_store_message_base_c
       
    34 {
       
    35 private:
       
    36 	//--------------------------------------------------
       
    37 
       
    38 
       
    39 	//--------------------------------------------------
       
    40 protected:
       
    41 	//--------------------------------------------------
       
    42 
       
    43 	//--------------------------------------------------
       
    44 public:
       
    45 	//--------------------------------------------------
       
    46 
       
    47 	/**
       
    48 	 * The destructor of the eap_core class does nothing special.
       
    49 	 */
       
    50 	EAP_FUNC_IMPORT virtual ~eap_pac_store_message_base_c();
       
    51 
       
    52 	/**
       
    53 	 * The constructor initializes member attributes using parameters passed to it.
       
    54 	 * @param tools is pointer to the tools class. @see abs_eap_am_tools_c.
       
    55 	 * @param partner is back pointer to object which created this object.
       
    56 	 * @param is_client_when_true indicates whether the network entity should act
       
    57 	 * as a client (true) or server (false), in terms of EAP-protocol
       
    58 	 * whether this network entity is EAP-supplicant (true) or EAP-authenticator (false).
       
    59 	 */
       
    60 	EAP_FUNC_IMPORT eap_pac_store_message_base_c();
       
    61 
       
    62 	/**
       
    63 	 * This function must reset the state of object to same as 
       
    64 	 * state was after the configure() function call.
       
    65 	 * If object reset succeeds this function must return eap_status_ok.
       
    66 	 * If object reset fails this function must return corresponding error status.
       
    67 	 * @return This function returns the status of reset operation.
       
    68 	 */
       
    69 	virtual eap_status_e reset() = 0;
       
    70 
       
    71 	// This is documented in abs_eap_stack_interface_c::configure().
       
    72 	virtual eap_status_e configure() = 0;
       
    73 
       
    74 	// This is documented in abs_eap_stack_interface_c::shutdown().
       
    75 	virtual eap_status_e shutdown() = 0;
       
    76 
       
    77 	// This is documented in abs_eap_stack_interface_c::get_is_valid().
       
    78 	virtual bool get_is_valid() = 0;
       
    79 
       
    80 	virtual eap_status_e open_pac_store(
       
    81 		const eap_status_e completion_status) = 0;
       
    82 
       
    83 	virtual eap_status_e create_device_seed(
       
    84 		const eap_status_e completion_status) = 0;
       
    85 
       
    86 	virtual eap_status_e is_master_key_present(
       
    87 		const eap_status_e completion_status) = 0;
       
    88 
       
    89 	virtual eap_status_e is_master_key_and_password_matching(
       
    90 		const eap_variable_data_c * const pac_store_password
       
    91 		,const eap_status_e completion_status) = 0;
       
    92 
       
    93 	virtual eap_status_e create_and_save_master_key(
       
    94 		const eap_variable_data_c * const pac_store_password
       
    95 		,const eap_status_e completion_status) = 0;
       
    96 
       
    97 	virtual eap_status_e compare_pac_store_password(
       
    98 		eap_variable_data_c * const pac_store_password) = 0;
       
    99 
       
   100 	virtual eap_status_e is_pacstore_password_present() = 0;
       
   101 
       
   102 	virtual eap_status_e set_pac_store_password(
       
   103 		const eap_variable_data_c * pac_store_password
       
   104 		,const eap_status_e completion_status) = 0;
       
   105 
       
   106 	virtual eap_status_e destroy_pac_store(
       
   107 		const eap_status_e completion_status) = 0;
       
   108 
       
   109 	//--------------------------------------------------
       
   110 
       
   111 	static eap_pac_store_message_base_c * new_eap_pac_store_client_message_if_c(
       
   112 		abs_eap_am_tools_c * const tools,
       
   113 		abs_eap_pac_store_message_c * const partner);
       
   114 
       
   115 	//--------------------------------------------------
       
   116 }; // class eap_pac_store_message_base_c
       
   117 
       
   118 //--------------------------------------------------
       
   119 
       
   120 #endif //#if !defined(_EAP_PAC_STORE_MESSAGE_BASE_H_)
       
   121 
       
   122 //--------------------------------------------------
       
   123 
       
   124 
       
   125 
       
   126 // End.