eapol/eapol_framework/eapol_symbian/eap_server/include/EapCoreIf.h
branchRCL_3
changeset 46 c74b3d9f6b9e
parent 45 bad0cc58d154
child 55 9c2aa05919d9
equal deleted inserted replaced
45:bad0cc58d154 46:c74b3d9f6b9e
     1 /*
       
     2 * Copyright (c) 2001-2010 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-authentication interface in EAP-server.
       
    15 *
       
    16 */
       
    17 
       
    18 /*
       
    19 * %version: 12 %
       
    20 */
       
    21 
       
    22 
       
    23 #ifndef EAPCOREIF_H_
       
    24 #define EAPCOREIF_H_
       
    25 
       
    26 #include "abs_eap_am_message_if.h"
       
    27 #include "eap_am_message_if.h"
       
    28 #include "eap_tools.h"
       
    29 #include "AbsEapSendInterface.h"
       
    30 
       
    31 class eap_file_config_c;
       
    32 
       
    33 //--------------------------------------------------
       
    34 
       
    35 /** @file */
       
    36 
       
    37 /// This class is the EAP-authentication interface in EAP-server.
       
    38 class CEapCoreIf
       
    39 : public CBase
       
    40 , public abs_eap_am_message_if_c
       
    41 {
       
    42 
       
    43 private:
       
    44 
       
    45     // ----------------------------------------------------------------------
       
    46 
       
    47     /// This is pointer to the tools class.
       
    48     abs_eap_am_tools_c * const m_am_tools;
       
    49 
       
    50     // client interface
       
    51     AbsEapSendInterface * m_client_if;
       
    52 
       
    53     /// CEapCoreIf deletes m_server_if in destructor.
       
    54     eap_am_message_if_c * m_server_if;
       
    55 
       
    56     eap_file_config_c * m_fileconfig;
       
    57 
       
    58     bool m_use_asyncronous_test;
       
    59     
       
    60     bool iIsValid;
       
    61 
       
    62     // ----------------------------------------------------------------------
       
    63 
       
    64 public:
       
    65 
       
    66     // ----------------------------------------------------------------------
       
    67 
       
    68     CEapCoreIf(
       
    69         abs_eap_am_tools_c * const tools,
       
    70         eap_am_message_if_c * const server,
       
    71         AbsEapSendInterface * client);
       
    72 
       
    73     virtual ~CEapCoreIf();
       
    74 
       
    75     bool get_is_valid();
       
    76 
       
    77     eap_status_e configure(
       
    78 		const eap_variable_data_c * const client_configuration);
       
    79 
       
    80     eap_status_e send_data(const void * const data, const u32_t length);
       
    81 
       
    82     eap_status_e process_data(const void * const data, const u32_t length);
       
    83 
       
    84     eap_status_e shutdown();
       
    85 
       
    86     // ------------------------------------------------------
       
    87 
       
    88     static CEapCoreIf * new_CEapCoreIf(
       
    89         abs_eap_am_tools_c * const tools,
       
    90         const bool is_client_when_true,
       
    91         const u32_t MTU,
       
    92         AbsEapSendInterface * client);
       
    93 
       
    94     // ----------------------------------------------------------------------
       
    95 };
       
    96 
       
    97 #endif /* EAPCOREIF_H_ */