The FreeRADIUS server
$Id: 15bac2a4c627c01d1aa2047687b3418955ac7f00 $
|
Implements the EAP framework. More...
#include <freeradius-devel/server/base.h>
#include <freeradius-devel/server/module_rlm.h>
#include <freeradius-devel/server/dl_module.h>
#include <freeradius-devel/protocol/freeradius/freeradius.internal.h>
#include <freeradius-devel/unlang/interpret.h>
#include <freeradius-devel/unlang/module.h>
#include "rlm_eap.h"
Go to the source code of this file.
Data Structures | |
struct | eap_auth_rctx_t |
Resume context for calling a submodule. More... | |
Macros | |
#define | LOG_PREFIX mctx->mi->name |
Functions | |
static ssize_t | eap_identity_is_nai_with_realm (char const *identity) |
Basic tests to determine if an identity is a valid NAI. More... | |
static unlang_action_t | eap_method_select (rlm_rcode_t *p_result, module_ctx_t const *mctx, eap_session_t *eap_session) |
Select the correct callback based on a response. More... | |
static eap_type_t | eap_process_nak (module_ctx_t const *mctx, request_t *request, eap_type_t last_type, eap_type_data_t *nak) |
Process NAK data from EAP peer. More... | |
static int | eap_type_parse (UNUSED TALLOC_CTX *ctx, void *out, UNUSED void *parent, CONF_ITEM *ci, UNUSED conf_parser_t const *rule) |
Convert EAP type strings to eap_type_t values. More... | |
static unlang_action_t | mod_authenticate (rlm_rcode_t *p_result, module_ctx_t const *mctx, request_t *request) |
static void | mod_authenticate_cancel (module_ctx_t const *mctx, request_t *request, UNUSED fr_signal_t action) |
Cancel a call to a submodule. More... | |
static unlang_action_t | mod_authenticate_result (rlm_rcode_t *p_result, UNUSED module_ctx_t const *mctx, request_t *request, eap_session_t *eap_session, rlm_rcode_t result) |
Process the result of calling a submodule. More... | |
static unlang_action_t | mod_authenticate_result_async (rlm_rcode_t *p_result, module_ctx_t const *mctx, request_t *request) |
Call mod_authenticate_result asynchronously from the unlang interpreter. More... | |
static unlang_action_t | mod_authorize (rlm_rcode_t *p_result, module_ctx_t const *mctx, request_t *request) |
static int | mod_instantiate (module_inst_ctx_t const *mctx) |
static int | mod_load (void) |
static unlang_action_t | mod_post_auth (rlm_rcode_t *p_result, module_ctx_t const *mctx, request_t *request) |
static void | mod_unload (void) |
static int | submodule_parse (TALLOC_CTX *ctx, void *out, UNUSED void *parent, CONF_ITEM *ci, UNUSED conf_parser_t const *rule) |
static int | submodule_parse (TALLOC_CTX *ctx, void *out, void *parent, CONF_ITEM *ci, conf_parser_t const *rule) |
Loads submodules based on type = foo pairs. More... | |
Variables | |
static fr_dict_attr_t const * | attr_auth_type |
static fr_dict_attr_t const * | attr_eap_identity |
static fr_dict_attr_t const * | attr_eap_message |
static fr_dict_attr_t const * | attr_eap_type |
static fr_dict_attr_t const * | attr_message_authenticator |
static fr_dict_attr_t const * | attr_state |
static fr_dict_attr_t const * | attr_stripped_user_domain |
static fr_dict_attr_t const * | attr_user_name |
static fr_dict_t const * | dict_freeradius |
static fr_dict_t const * | dict_radius |
static const conf_parser_t | module_config [] |
static fr_table_num_sorted_t const | require_identity_realm_table [] |
static size_t | require_identity_realm_table_len = NUM_ELEMENTS(require_identity_realm_table) |
module_rlm_t | rlm_eap |
fr_dict_autoload_t | rlm_eap_dict [] |
fr_dict_attr_autoload_t | rlm_eap_dict_attr [] |
Implements the EAP framework.
Definition in file rlm_eap.c.
struct eap_auth_rctx_t |
Data Fields | ||
---|---|---|
char const * | caller | Original caller. |
eap_session_t * | eap_session | The eap_session we're continuing. |
rlm_eap_t * | inst | Instance of the rlm_eap module. |
rlm_rcode_t | rcode | The result of the submodule. |
|
static |
Basic tests to determine if an identity is a valid NAI.
In this version we mostly just care about realm.
[in] | identity | to check. |
Definition at line 521 of file rlm_eap.c.
|
static |
Select the correct callback based on a response.
Based on the EAP response from the supplicant, and setup a call on the unlang stack to the appropriate submodule.
Default to the configured EAP-Type for all Unsupported EAP-Types.
[out] | p_result | the result of the operation. |
[in] | mctx | module calling ctx. |
[in] | eap_session | State data that persists over multiple rounds of EAP. |
Definition at line 573 of file rlm_eap.c.
|
static |
|
static |
Convert EAP type strings to eap_type_t values.
[in] | ctx | unused. |
[out] | out | Where to write the eap_type_t value we found. |
[in] | parent | Base structure address. |
[in] | ci | CONF_PAIR specifying the name of the EAP method. |
[in] | rule | unused. |
Definition at line 207 of file rlm_eap.c.
|
static |
|
static |
|
static |
Process the result of calling a submodule.
[out] | p_result | Result of calling the module, one of:
|
[in] | request | The current request. |
[in] | mctx | module calling ctx. |
[in] | eap_session | the EAP session |
[in] | result | the input result from the submodule |
Definition at line 419 of file rlm_eap.c.
|
static |
Call mod_authenticate_result asynchronously from the unlang interpreter.
[out] | p_result | The result of the operation. |
[in] | mctx | module calling ctx. |
[in] | request | the current request. |
Definition at line 504 of file rlm_eap.c.
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
Loads submodules based on type = foo pairs.
[in] | ctx | to allocate data in (instance of rlm_eap_t). |
[out] | out | Where to write child conf section to. |
[in] | parent | Base structure address. |
[in] | ci | CONF_PAIR specifying the name of the type module. |
[in] | rule | unused. |
Definition at line 132 of file rlm_eap.c.
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
module_rlm_t rlm_eap |
fr_dict_autoload_t rlm_eap_dict |
fr_dict_attr_autoload_t rlm_eap_dict_attr |