141 //-------------------------------------------------- |
162 //-------------------------------------------------- |
142 |
163 |
143 /** |
164 /** |
144 * The destructor deletes the m_eap_core object. |
165 * The destructor deletes the m_eap_core object. |
145 */ |
166 */ |
146 EAP_FUNC_IMPORT virtual ~eap_core_server_message_if_c(); |
167 EAP_FUNC_VISIBILITY_EAP_CORE_SERVER_MESSAGE_IF_H virtual ~eap_core_server_message_if_c(); |
147 |
168 |
148 /** |
169 /** |
149 * The constructor creates the eap_core object and initializes the m_eap_core |
170 * The constructor creates the eap_core object and initializes the m_eap_core |
150 * to point the eap_core object. |
171 * to point the eap_core object. |
151 * @param tools is pointer to the tools class. @see abs_eap_am_tools_c. |
172 * @param tools is pointer to the tools class. @see abs_eap_am_tools_c. |
152 * @param partner is back pointer to object which created this object. |
173 * @param partner is back pointer to object which created this object. |
153 * @param is_client_when_true indicates whether the network entity should act |
174 * @param is_client_when_true indicates whether the network entity should act |
154 * as a client (true) or server (false), in terms of EAP-protocol whether |
175 * as a client (true) or server (false), in terms of EAP-protocol whether |
155 * this network entity is EAP-supplicant (true) or EAP-authenticator (false). |
176 * this network entity is EAP-supplicant (true) or EAP-authenticator (false). |
156 */ |
177 */ |
157 EAP_FUNC_IMPORT eap_core_server_message_if_c( |
178 EAP_FUNC_VISIBILITY_EAP_CORE_SERVER_MESSAGE_IF_H eap_core_server_message_if_c( |
158 abs_eap_am_tools_c * const tools, |
179 abs_eap_am_tools_c * const tools, |
159 const bool is_client_when_true, |
180 const bool is_client_when_true, |
160 const u32_t MTU); |
181 const u32_t MTU); |
161 |
182 |
162 EAP_FUNC_IMPORT void set_partner(abs_eap_am_message_if_c * const partner); |
183 EAP_FUNC_VISIBILITY_EAP_CORE_SERVER_MESSAGE_IF_H void set_partner(abs_eap_am_message_if_c * const partner); |
163 |
184 |
164 EAP_FUNC_IMPORT eap_status_e process_data(const void * const data, const u32_t length); |
185 EAP_FUNC_VISIBILITY_EAP_CORE_SERVER_MESSAGE_IF_H eap_status_e process_data(const void * const data, const u32_t length); |
165 |
186 |
166 /** |
187 /** |
167 * The class could send packets to partner class with this function. |
188 * The class could send packets to partner class with this function. |
168 * eap_core_server_message_if_c adds EAPOL header to the send packet. |
189 * eap_core_server_message_if_c adds EAPOL header to the send packet. |
169 * @param send_network_id carries the addresses (network identity) and type of the packet. |
190 * @param send_network_id carries the addresses (network identity) and type of the packet. |
208 |
229 |
209 /** |
230 /** |
210 * The unload_module() function unloads the module of a EAP-type. |
231 * The unload_module() function unloads the module of a EAP-type. |
211 * @see abs_eap_core_c::unload_module(). |
232 * @see abs_eap_core_c::unload_module(). |
212 */ |
233 */ |
213 EAP_FUNC_IMPORT eap_status_e unload_module( |
234 EAP_FUNC_VISIBILITY_EAP_CORE_SERVER_MESSAGE_IF_H eap_status_e unload_module( |
214 const eap_type_value_e type); |
235 const eap_type_value_e type); |
215 |
236 |
216 /** |
237 /** |
217 * Note this function is just an example. Parameters will change later. |
238 * Note this function is just an example. Parameters will change later. |
218 * The packet_data_crypto_keys() function gives the generated keys to lower level. |
239 * The packet_data_crypto_keys() function gives the generated keys to lower level. |
219 * After EAP-authentication has generated the keys it calls this function |
240 * After EAP-authentication has generated the keys it calls this function |
220 * to offer the keys to lower level. |
241 * to offer the keys to lower level. |
221 * @see abs_eap_base_type_c::packet_data_crypto_keys(). |
242 * @see abs_eap_base_type_c::packet_data_crypto_keys(). |
222 */ |
243 */ |
223 EAP_FUNC_IMPORT eap_status_e packet_data_crypto_keys( |
244 EAP_FUNC_VISIBILITY_EAP_CORE_SERVER_MESSAGE_IF_H eap_status_e packet_data_crypto_keys( |
224 const eap_am_network_id_c * const send_network_id, |
245 const eap_am_network_id_c * const send_network_id, |
225 const eap_master_session_key_c * const master_session_key |
246 const eap_master_session_key_c * const master_session_key |
226 ); |
247 ); |
227 |
248 |
228 // This is documented in abs_eap_stack_interface_c::configure(). |
249 // This is documented in abs_eap_stack_interface_c::configure(). |
229 EAP_FUNC_IMPORT eap_status_e configure( |
250 EAP_FUNC_VISIBILITY_EAP_CORE_SERVER_MESSAGE_IF_H eap_status_e configure( |
230 const eap_variable_data_c * const client_configuration); |
251 const eap_variable_data_c * const client_configuration); |
231 |
252 |
232 // This is documented in abs_eap_stack_interface_c::shutdown(). |
253 // This is documented in abs_eap_stack_interface_c::shutdown(). |
233 EAP_FUNC_IMPORT eap_status_e shutdown(); |
254 EAP_FUNC_VISIBILITY_EAP_CORE_SERVER_MESSAGE_IF_H eap_status_e shutdown(); |
234 |
255 |
235 /** |
256 /** |
236 * The read_configure() function reads the configuration data identified |
257 * The read_configure() function reads the configuration data identified |
237 * by the field string of field_length bytes length. Adaptation module must direct |
258 * by the field string of field_length bytes length. Adaptation module must direct |
238 * the query to some persistent store. |
259 * the query to some persistent store. |
239 * @see abs_eap_base_type_c::read_configure(). |
260 * @see abs_eap_base_type_c::read_configure(). |
240 */ |
261 */ |
241 EAP_FUNC_IMPORT eap_status_e read_configure( |
262 EAP_FUNC_VISIBILITY_EAP_CORE_SERVER_MESSAGE_IF_H eap_status_e read_configure( |
242 const eap_configuration_field_c * const field, |
263 const eap_configuration_field_c * const field, |
243 eap_variable_data_c * const data); |
264 eap_variable_data_c * const data); |
244 |
265 |
245 /** |
266 /** |
246 * The write_configure() function writes the configuration data identified |
267 * The write_configure() function writes the configuration data identified |
247 * by the field string of field_length bytes length. Adaptation module must direct |
268 * by the field string of field_length bytes length. Adaptation module must direct |
248 * the action to some persistent store. |
269 * the action to some persistent store. |
249 * @see abs_eap_base_type_c::write_configure(). |
270 * @see abs_eap_base_type_c::write_configure(). |
250 */ |
271 */ |
251 EAP_FUNC_IMPORT eap_status_e write_configure( |
272 EAP_FUNC_VISIBILITY_EAP_CORE_SERVER_MESSAGE_IF_H eap_status_e write_configure( |
252 const eap_configuration_field_c * const field, |
273 const eap_configuration_field_c * const field, |
253 eap_variable_data_c * const data); |
274 eap_variable_data_c * const data); |
254 |
275 |
255 // This is documented in abs_eap_stack_interface_c::set_is_valid(). |
276 // This is documented in abs_eap_stack_interface_c::set_is_valid(). |
256 EAP_FUNC_IMPORT void set_is_valid(); |
277 EAP_FUNC_VISIBILITY_EAP_CORE_SERVER_MESSAGE_IF_H void set_is_valid(); |
257 |
278 |
258 // This is documented in abs_eap_stack_interface_c::get_is_valid(). |
279 // This is documented in abs_eap_stack_interface_c::get_is_valid(). |
259 EAP_FUNC_IMPORT bool get_is_valid(); |
280 EAP_FUNC_VISIBILITY_EAP_CORE_SERVER_MESSAGE_IF_H bool get_is_valid(); |
260 |
281 |
261 // See abs_eap_base_type_c::state_notification(). |
282 // See abs_eap_base_type_c::state_notification(). |
262 EAP_FUNC_IMPORT void state_notification( |
283 EAP_FUNC_VISIBILITY_EAP_CORE_SERVER_MESSAGE_IF_H void state_notification( |
263 const abs_eap_state_notification_c * const state); |
284 const abs_eap_state_notification_c * const state); |
264 |
285 |
265 // See abs_eap_base_timer_c::timer_expired(). |
286 // See abs_eap_base_timer_c::timer_expired(). |
266 EAP_FUNC_IMPORT eap_status_e timer_expired( |
287 EAP_FUNC_VISIBILITY_EAP_CORE_SERVER_MESSAGE_IF_H eap_status_e timer_expired( |
267 const u32_t id, void *data); |
288 const u32_t id, void *data); |
268 |
289 |
269 // See abs_eap_base_timer_c::timer_delete_data(). |
290 // See abs_eap_base_timer_c::timer_delete_data(). |
270 EAP_FUNC_IMPORT eap_status_e timer_delete_data( |
291 EAP_FUNC_VISIBILITY_EAP_CORE_SERVER_MESSAGE_IF_H eap_status_e timer_delete_data( |
271 const u32_t id, void *data); |
292 const u32_t id, void *data); |
272 |
293 |
273 /** |
294 /** |
274 * This function tells lower layer to remove EAP session object asyncronously. |
295 * This function tells lower layer to remove EAP session object asyncronously. |
275 * @param send_network_id is pointer to network id that identifies the removed EAP session. |
296 * @param send_network_id is pointer to network id that identifies the removed EAP session. |
276 */ |
297 */ |
277 EAP_FUNC_IMPORT eap_status_e asynchronous_init_remove_eap_session( |
298 EAP_FUNC_VISIBILITY_EAP_CORE_SERVER_MESSAGE_IF_H eap_status_e asynchronous_init_remove_eap_session( |
278 const eap_am_network_id_c * const send_network_id); |
299 const eap_am_network_id_c * const send_network_id); |
279 |
300 |
280 /** |
301 /** |
281 * The upper layer calls the asynchronous_start_authentication() function |
302 * The upper layer calls the asynchronous_start_authentication() function |
282 * when EAP-authentication is needed with another peer. |
303 * when EAP-authentication is needed with another peer. |
283 * @see abs_eap_core_c::asynchronous_start_authentication(). |
304 * @see abs_eap_core_c::asynchronous_start_authentication(). |
284 */ |
305 */ |
285 EAP_FUNC_IMPORT eap_status_e asynchronous_start_authentication( |
306 EAP_FUNC_VISIBILITY_EAP_CORE_SERVER_MESSAGE_IF_H eap_status_e asynchronous_start_authentication( |
286 const eap_am_network_id_c * const /* receive_network_id */, |
307 const eap_am_network_id_c * const /* receive_network_id */, |
287 const bool /* is_client_when_true */); |
308 const bool /* is_client_when_true */); |
288 |
309 |
289 EAP_FUNC_IMPORT eap_status_e restart_authentication( |
310 EAP_FUNC_VISIBILITY_EAP_CORE_SERVER_MESSAGE_IF_H eap_status_e restart_authentication( |
290 const eap_am_network_id_c * const send_network_id, |
311 const eap_am_network_id_c * const send_network_id, |
291 const bool is_client_when_true, |
312 const bool is_client_when_true, |
292 const bool force_clean_restart, |
313 const bool force_clean_restart, |
293 const bool from_timer = false); |
314 const bool from_timer = false); |
294 |
315 |
295 // |
316 // |
296 EAP_FUNC_IMPORT eap_status_e set_timer( |
317 EAP_FUNC_VISIBILITY_EAP_CORE_SERVER_MESSAGE_IF_H eap_status_e set_timer( |
297 abs_eap_base_timer_c * const p_initializer, |
318 abs_eap_base_timer_c * const p_initializer, |
298 const u32_t p_id, |
319 const u32_t p_id, |
299 void * const p_data, |
320 void * const p_data, |
300 const u32_t p_time_ms); |
321 const u32_t p_time_ms); |
301 |
322 |
302 EAP_FUNC_IMPORT eap_status_e cancel_timer( |
323 EAP_FUNC_VISIBILITY_EAP_CORE_SERVER_MESSAGE_IF_H eap_status_e cancel_timer( |
303 abs_eap_base_timer_c * const p_initializer, |
324 abs_eap_base_timer_c * const p_initializer, |
304 const u32_t p_id); |
325 const u32_t p_id); |
305 |
326 |
306 // |
327 // |
307 EAP_FUNC_IMPORT eap_status_e check_is_valid_eap_type(const eap_type_value_e eap_type); |
328 EAP_FUNC_VISIBILITY_EAP_CORE_SERVER_MESSAGE_IF_H eap_status_e check_is_valid_eap_type(const eap_type_value_e eap_type); |
308 |
329 |
309 // See abs_eap_core_c::get_eap_type_list(). |
330 // See abs_eap_core_c::get_eap_type_list(). |
310 EAP_FUNC_IMPORT eap_status_e get_eap_type_list( |
331 EAP_FUNC_VISIBILITY_EAP_CORE_SERVER_MESSAGE_IF_H eap_status_e get_eap_type_list( |
311 eap_array_c<eap_type_value_e> * const eap_type_list); |
332 eap_array_c<eap_type_value_e> * const eap_type_list); |
312 |
333 |
313 /// @see abs_eap_core_c::add_rogue_ap(). |
334 /// @see abs_eap_core_c::add_rogue_ap(). |
314 EAP_FUNC_IMPORT eap_status_e add_rogue_ap(eap_array_c<eap_rogue_ap_entry_c> & rogue_ap_list); |
335 EAP_FUNC_VISIBILITY_EAP_CORE_SERVER_MESSAGE_IF_H eap_status_e add_rogue_ap(eap_array_c<eap_rogue_ap_entry_c> & rogue_ap_list); |
315 |
336 |
316 // This is documented in abs_eap_core_c::set_session_timeout(). |
337 // This is documented in abs_eap_core_c::set_session_timeout(). |
317 EAP_FUNC_IMPORT eap_status_e set_session_timeout( |
338 EAP_FUNC_VISIBILITY_EAP_CORE_SERVER_MESSAGE_IF_H eap_status_e set_session_timeout( |
318 const u32_t session_timeout_ms); |
339 const u32_t session_timeout_ms); |
319 |
340 |
320 #if defined(USE_EAP_SIMPLE_CONFIG) |
341 #if defined(USE_EAP_SIMPLE_CONFIG) |
321 |
342 |
322 EAP_FUNC_IMPORT eap_status_e save_simple_config_session( |
343 EAP_FUNC_VISIBILITY_EAP_CORE_SERVER_MESSAGE_IF_H eap_status_e save_simple_config_session( |
323 const simple_config_state_e state, |
344 const simple_config_state_e state, |
324 EAP_TEMPLATE_CONST eap_array_c<simple_config_credential_c> * const credential_array, |
345 EAP_TEMPLATE_CONST eap_array_c<simple_config_credential_c> * const credential_array, |
325 const eap_variable_data_c * const new_password, |
346 const eap_variable_data_c * const new_password, |
326 const simple_config_Device_Password_ID_e Device_Password_ID, |
347 const simple_config_Device_Password_ID_e Device_Password_ID, |
327 const simple_config_payloads_c * const other_configuration); |
348 const simple_config_payloads_c * const other_configuration); |
328 |
349 |
329 #endif // #if defined(USE_EAP_SIMPLE_CONFIG) |
350 #endif // #if defined(USE_EAP_SIMPLE_CONFIG) |
330 |
351 |
331 EAP_FUNC_IMPORT eap_status_e complete_get_802_11_authentication_mode( |
352 EAP_FUNC_VISIBILITY_EAP_CORE_SERVER_MESSAGE_IF_H eap_status_e complete_get_802_11_authentication_mode( |
332 const eap_status_e completion_status, |
353 const eap_status_e completion_status, |
333 const eap_am_network_id_c * const receive_network_id, |
354 const eap_am_network_id_c * const receive_network_id, |
334 const eapol_key_802_11_authentication_mode_e mode); |
355 const eapol_key_802_11_authentication_mode_e mode); |
335 |
356 |
336 //-------------------------------------------------- |
357 //-------------------------------------------------- |