Skip to content

Commit

Permalink
More function renaming
Browse files Browse the repository at this point in the history
preproxy --> pre_proxy, etc.
  • Loading branch information
alandekok committed Mar 20, 2013
1 parent 2fd7418 commit 457b30b
Show file tree
Hide file tree
Showing 18 changed files with 90 additions and 90 deletions.
8 changes: 4 additions & 4 deletions src/modules/rlm_attr_filter/rlm_attr_filter.c
Expand Up @@ -338,7 +338,7 @@ static rlm_rcode_t attr_filter_common(void *instance, REQUEST *request,
return RLM_MODULE_UPDATED;
}

static rlm_rcode_t attr_filter_preacct(void *instance, REQUEST *request)
static rlm_rcode_t mod_preacct(void *instance, REQUEST *request)
{
return attr_filter_common(instance, request, request->packet);
}
Expand All @@ -360,7 +360,7 @@ static rlm_rcode_t attr_filter_postproxy(void *instance, REQUEST *request)
}
#endif

static rlm_rcode_t attr_filter_postauth(void *instance, REQUEST *request)
static rlm_rcode_t mod_post_auth(void *instance, REQUEST *request)
{
return attr_filter_common(instance, request, request->reply);
}
Expand All @@ -381,7 +381,7 @@ module_t rlm_attr_filter = {
{
NULL, /* authentication */
mod_authorize, /* authorization */
attr_filter_preacct, /* pre-acct */
mod_preacct, /* pre-acct */
mod_accounting, /* accounting */
NULL, /* checksimul */
#ifdef WITH_PROXY
Expand All @@ -390,7 +390,7 @@ module_t rlm_attr_filter = {
#else
NULL, NULL,
#endif
attr_filter_postauth /* post-auth */
mod_post_auth /* post-auth */
},
};

8 changes: 4 additions & 4 deletions src/modules/rlm_attr_rewrite/rlm_attr_rewrite.c
Expand Up @@ -447,7 +447,7 @@ static rlm_rcode_t mod_authenticate(void *instance, REQUEST *request)
return do_attr_rewrite(instance, request);
}

static rlm_rcode_t attr_rewrite_preacct(void *instance, REQUEST *request)
static rlm_rcode_t mod_preacct(void *instance, REQUEST *request)
{
return do_attr_rewrite(instance, request);
}
Expand All @@ -469,7 +469,7 @@ static rlm_rcode_t attr_rewrite_postproxy(void *instance, REQUEST *request)
}
#endif

static rlm_rcode_t attr_rewrite_postauth(void *instance, REQUEST *request)
static rlm_rcode_t mod_post_auth(void *instance, REQUEST *request)
{
return do_attr_rewrite(instance, request);
}
Expand All @@ -492,7 +492,7 @@ module_t rlm_attr_rewrite = {
{
mod_authenticate, /* authentication */
mod_authorize, /* authorization */
attr_rewrite_preacct, /* preaccounting */
mod_preacct, /* preaccounting */
mod_accounting, /* accounting */
mod_checksimul, /* checksimul */
#ifdef WITH_PROXY
Expand All @@ -501,6 +501,6 @@ module_t rlm_attr_rewrite = {
#else
NULL, NULL,
#endif
attr_rewrite_postauth /* post-auth */
mod_post_auth /* post-auth */
},
};
4 changes: 2 additions & 2 deletions src/modules/rlm_detail/rlm_detail.c
Expand Up @@ -515,7 +515,7 @@ static rlm_rcode_t mod_authorize(void *instance, REQUEST *request)
/*
* Outgoing Access-Request Reply - write the detail files.
*/
static rlm_rcode_t detail_postauth(void *instance, REQUEST *request)
static rlm_rcode_t mod_post_auth(void *instance, REQUEST *request)
{
return do_detail(instance,request,request->reply, FALSE);
}
Expand Down Expand Up @@ -604,7 +604,7 @@ module_t rlm_detail = {
#else
NULL, NULL,
#endif
detail_postauth /* post-auth */
mod_post_auth /* post-auth */
#ifdef WITH_COA
, mod_recv_coa,
mod_send_coa
Expand Down
2 changes: 1 addition & 1 deletion src/modules/rlm_eap/types/rlm_eap_peap/peap.c
Expand Up @@ -588,7 +588,7 @@ static int eappeap_postproxy(eap_handler_t *handler, void *data)
* FIXME: If rcode returns fail, do something
* intelligent...
*/
rcode = rad_postauth(fake);
rcode = mod_post_auth(fake);

if ((debug_flag > 0) && fr_log_fp) {
fprintf(fr_log_fp, "} # server %s\n", fake->server);
Expand Down
2 changes: 1 addition & 1 deletion src/modules/rlm_eap/types/rlm_eap_ttls/ttls.c
Expand Up @@ -871,7 +871,7 @@ static int eapttls_postproxy(eap_handler_t *handler, void *data)
* session.
*/
fake->options &= ~RAD_REQUEST_OPTION_PROXY_EAP;
rcode = rad_postauth(fake);
rcode = mod_post_auth(fake);
RDEBUG2("post-auth returns %d", rcode);

if ((debug_flag > 0) && fr_log_fp) {
Expand Down
4 changes: 2 additions & 2 deletions src/modules/rlm_example/rlm_example.c
Expand Up @@ -146,7 +146,7 @@ static rlm_rcode_t mod_authenticate(void *instance, REQUEST *request)
/*
* Massage the request before recording it or proxying it
*/
static rlm_rcode_t example_preacct(void *instance, REQUEST *request)
static rlm_rcode_t mod_preacct(void *instance, REQUEST *request)
{
/* quiet the compiler */
instance = instance;
Expand Down Expand Up @@ -215,7 +215,7 @@ module_t rlm_example = {
{
mod_authenticate, /* authentication */
mod_authorize, /* authorization */
example_preacct, /* preaccounting */
mod_preacct, /* preaccounting */
mod_accounting, /* accounting */
mod_checksimul, /* checksimul */
NULL, /* pre-proxy */
Expand Down
4 changes: 2 additions & 2 deletions src/modules/rlm_exec/rlm_exec.c
Expand Up @@ -374,7 +374,7 @@ static rlm_rcode_t exec_dispatch(void *instance, REQUEST *request)
*
* Then, call exec_dispatch.
*/
static rlm_rcode_t exec_postauth(void *instance, REQUEST *request)
static rlm_rcode_t mod_post_auth(void *instance, REQUEST *request)
{
int result;
int exec_wait = 0;
Expand Down Expand Up @@ -486,7 +486,7 @@ module_t rlm_exec = {
NULL, /* check simul */
exec_dispatch, /* pre-proxy */
exec_dispatch, /* post-proxy */
exec_postauth /* post-auth */
mod_post_auth /* post-auth */
#ifdef WITH_COA
, exec_dispatch,
exec_dispatch
Expand Down
8 changes: 4 additions & 4 deletions src/modules/rlm_files/rlm_files.c
Expand Up @@ -521,7 +521,7 @@ static rlm_rcode_t mod_authorize(void *instance, REQUEST *request)
* config_items. Reply items are Not Recommended(TM) in acct_users,
* except for Fallthrough, which should work
*/
static rlm_rcode_t file_preacct(void *instance, REQUEST *request)
static rlm_rcode_t mod_preacct(void *instance, REQUEST *request)
{
struct file_instance *inst = instance;

Expand Down Expand Up @@ -558,7 +558,7 @@ static rlm_rcode_t mod_authenticate(void *instance, REQUEST *request)
request->packet->vps, &request->reply->vps);
}

static rlm_rcode_t file_postauth(void *instance, REQUEST *request)
static rlm_rcode_t mod_post_auth(void *instance, REQUEST *request)
{
struct file_instance *inst = instance;

Expand All @@ -578,7 +578,7 @@ module_t rlm_files = {
{
mod_authenticate, /* authentication */
mod_authorize, /* authorization */
file_preacct, /* preaccounting */
mod_preacct, /* preaccounting */
NULL, /* accounting */
NULL, /* checksimul */
#ifdef WITH_PROXY
Expand All @@ -587,7 +587,7 @@ module_t rlm_files = {
#else
NULL, NULL,
#endif
file_postauth /* post-auth */
mod_post_auth /* post-auth */
},
};

4 changes: 2 additions & 2 deletions src/modules/rlm_ippool/rlm_ippool.c
Expand Up @@ -391,7 +391,7 @@ static rlm_rcode_t mod_accounting(void *instance, REQUEST *request)
return RLM_MODULE_OK;
}

static rlm_rcode_t ippool_postauth(void *instance, REQUEST *request)
static rlm_rcode_t mod_post_auth(void *instance, REQUEST *request)
{
rlm_ippool_t *data = (rlm_ippool_t *) instance;
int delete = 0;
Expand Down Expand Up @@ -816,6 +816,6 @@ module_t rlm_ippool = {
NULL, /* checksimul */
NULL, /* pre-proxy */
NULL, /* post-proxy */
ippool_postauth /* post-auth */
mod_post_auth /* post-auth */
},
};
4 changes: 2 additions & 2 deletions src/modules/rlm_ldap/rlm_ldap.c
Expand Up @@ -1159,7 +1159,7 @@ static rlm_rcode_t mod_accounting(void *instance, REQUEST * request) {
/** Check the user's password against ldap database
*
*/
static rlm_rcode_t ldap_postauth(void *instance, REQUEST * request)
static rlm_rcode_t mod_post_auth(void *instance, REQUEST * request)
{
ldap_instance_t *inst = instance;

Expand All @@ -1186,6 +1186,6 @@ module_t rlm_ldap = {
NULL, /* checksimul */
NULL, /* pre-proxy */
NULL, /* post-proxy */
ldap_postauth /* post-auth */
mod_post_auth /* post-auth */
},
};
8 changes: 4 additions & 4 deletions src/modules/rlm_realm/rlm_realm.c
Expand Up @@ -393,7 +393,7 @@ static rlm_rcode_t mod_authorize(void *instance, REQUEST *request)
* This does the exact same thing as the mod_authorize, it's just called
* differently.
*/
static rlm_rcode_t realm_preacct(void *instance, REQUEST *request)
static rlm_rcode_t mod_preacct(void *instance, REQUEST *request)
{
int rcode;
const char *name = (char *)request->username->vp_strvalue;
Expand Down Expand Up @@ -427,7 +427,7 @@ static rlm_rcode_t realm_preacct(void *instance, REQUEST *request)
* CoA realms via Operator-Name. Because the realm isn't in a
* User-Name, concepts like "prefix" and "suffix' don't matter.
*/
static rlm_rcode_t realm_coa(UNUSED void *instance, REQUEST *request)
static rlm_rcode_t realm_recv_coa(UNUSED void *instance, REQUEST *request)
{
VALUE_PAIR *vp;
REALM *realm;
Expand Down Expand Up @@ -484,14 +484,14 @@ module_t rlm_realm = {
{
NULL, /* authentication */
mod_authorize, /* authorization */
realm_preacct, /* preaccounting */
mod_preacct, /* preaccounting */
NULL, /* accounting */
NULL, /* checksimul */
NULL, /* pre-proxy */
NULL, /* post-proxy */
NULL /* post-auth */
#ifdef WITH_COA
, realm_coa, /* recv-coa */
, realm_recv_coa, /* recv-coa */
NULL /* send-coa */
#endif
},
Expand Down
22 changes: 11 additions & 11 deletions src/modules/rlm_replicate/rlm_replicate.c
Expand Up @@ -235,7 +235,7 @@ static rlm_rcode_t mod_authorize(void *instance, REQUEST *request)
request->packet->code);
}

static rlm_rcode_t replicate_preaccounting(void *instance, REQUEST *request)
static rlm_rcode_t mod_preaccounting(void *instance, REQUEST *request)
{
return replicate_packet(instance, request, PAIR_LIST_REQUEST,
request->packet->code);
Expand All @@ -247,25 +247,25 @@ static rlm_rcode_t mod_accounting(void *instance, REQUEST *request)
request->reply->code);
}

static rlm_rcode_t replicate_preproxy(void *instance, REQUEST *request)
static rlm_rcode_t mod_pre_proxy(void *instance, REQUEST *request)
{
return replicate_packet(instance, request, PAIR_LIST_PROXY_REQUEST,
request->proxy->code);
}

static rlm_rcode_t replicate_postproxy(void *instance, REQUEST *request)
static rlm_rcode_t mod_post_proxy(void *instance, REQUEST *request)
{
return replicate_packet(instance, request, PAIR_LIST_PROXY_REPLY,
request->proxy_reply->code);
}

static rlm_rcode_t replicate_postauth(void *instance, REQUEST *request)
static rlm_rcode_t mod_post_auth(void *instance, REQUEST *request)
{
return replicate_packet(instance, request, PAIR_LIST_REPLY,
return mod_packet(instance, request, PAIR_LIST_REPLY,
request->reply->code);
}

static rlm_rcode_t replicate_coarequest(void *instance, REQUEST *request)
static rlm_rcode_t mod_recv_coa(void *instance, REQUEST *request)
{
return replicate_packet(instance, request, PAIR_LIST_REQUEST,
request->packet->code);
Expand All @@ -289,14 +289,14 @@ module_t rlm_replicate = {
{
NULL, /* authentication */
mod_authorize, /* authorization */
replicate_preaccounting,/* preaccounting */
mod_preaccounting,/* preaccounting */
mod_accounting, /* accounting */
NULL, /* checksimul */
replicate_preproxy, /* pre-proxy */
replicate_postproxy, /* post-proxy */
replicate_postauth /* post-auth */
mod_pre_proxy, /* pre-proxy */
mod_post_proxy, /* post-proxy */
mod_post_auth /* post-auth */
#ifdef WITH_COA
, replicate_coarequest, /* coa-request */
, mod_recv_coa, /* coa-request */
NULL
#endif
},
Expand Down
40 changes: 20 additions & 20 deletions src/modules/rlm_ruby/rlm_ruby.c
Expand Up @@ -53,12 +53,12 @@ typedef struct rlm_ruby_t {
RLM_RUBY_STRUCT(preacct);
RLM_RUBY_STRUCT(accounting);
RLM_RUBY_STRUCT(checksimul);
RLM_RUBY_STRUCT(preproxy);
RLM_RUBY_STRUCT(postproxy);
RLM_RUBY_STRUCT(postauth);
RLM_RUBY_STRUCT(pre_proxy);
RLM_RUBY_STRUCT(post_proxy);
RLM_RUBY_STRUCT(post_auth);
#ifdef WITH_COA
RLM_RUBY_STRUCT(recvcoa);
RLM_RUBY_STRUCT(sendcoa);
RLM_RUBY_STRUCT(recv_coa);
RLM_RUBY_STRUCT(send_coa);
#endif
RLM_RUBY_STRUCT(detach);

Expand Down Expand Up @@ -409,12 +409,12 @@ static int mod_instantiate(CONF_SECTION *conf, void **instance)
RLM_RUBY_LOAD(preacct);
RLM_RUBY_LOAD(accounting);
RLM_RUBY_LOAD(checksimul);
RLM_RUBY_LOAD(preproxy);
RLM_RUBY_LOAD(postproxy);
RLM_RUBY_LOAD(postauth);
RLM_RUBY_LOAD(pre_proxy);
RLM_RUBY_LOAD(post_proxy);
RLM_RUBY_LOAD(post_auth);
#ifdef WITH_COA
RLM_RUBY_LOAD(recvcoa);
RLM_RUBY_LOAD(sendcoa);
RLM_RUBY_LOAD(recv_coa);
RLM_RUBY_LOAD(send_coa);
#endif
RLM_RUBY_LOAD(detach);

Expand All @@ -434,12 +434,12 @@ RLM_RUBY_FUNC(authenticate)
RLM_RUBY_FUNC(preacct)
RLM_RUBY_FUNC(accounting)
RLM_RUBY_FUNC(checksimul)
RLM_RUBY_FUNC(preproxy)
RLM_RUBY_FUNC(postproxy)
RLM_RUBY_FUNC(postauth)
RLM_RUBY_FUNC(pre_proxy)
RLM_RUBY_FUNC(post_proxy)
RLM_RUBY_FUNC(post_auth)
#ifdef WITH_COA
RLM_RUBY_FUNC(recvcoa)
RLM_RUBY_FUNC(sendcoa)
RLM_RUBY_FUNC(recv_coa)
RLM_RUBY_FUNC(send_coa)
#endif

static int mod_detach(UNUSED void *instance)
Expand Down Expand Up @@ -472,12 +472,12 @@ module_t rlm_ruby = {
mod_preacct, /* preaccounting */
mod_accounting, /* accounting */
mod_checksimul, /* checksimul */
mod_preproxy, /* pre-proxy */
mod_postproxy, /* post-proxy */
mod_postauth /* post-auth */
mod_pre_proxy, /* pre-proxy */
mod_post_proxy, /* post-proxy */
mod_post_auth /* post-auth */
#ifdef WITH_COA
, mod_recvcoa,
mod_sendcoa
, mod_recv_coa,
mod_send_coa
#endif
},
};
4 changes: 2 additions & 2 deletions src/modules/rlm_soh/rlm_soh.c
Expand Up @@ -135,7 +135,7 @@ static int mod_instantiate(CONF_SECTION *conf, void **instance)
return 0;
}

static rlm_rcode_t soh_postauth(UNUSED void * instance, REQUEST *request)
static rlm_rcode_t mod_post_auth(UNUSED void * instance, REQUEST *request)
{
#ifdef WITH_DHCP
int rcode;
Expand Down Expand Up @@ -229,6 +229,6 @@ module_t rlm_soh = {
NULL, /* checksimul */
NULL, /* pre-proxy */
NULL, /* post-proxy */
soh_postauth /* post-auth */
mod_post_auth /* post-auth */
},
};

0 comments on commit 457b30b

Please sign in to comment.