Example #1
0
/*
 *	Accounting: Insert or update session data in our sql table
 */
static rlm_rcode_t mod_accounting(void *instance, REQUEST * request) {
	rlm_sql_t *inst = instance;

	if (inst->config->accounting) {
		return acct_redundant(inst, request, inst->config->accounting);
	}

	return RLM_MODULE_NOOP;
}
Example #2
0
/*
 *	Postauth: Write a record of the authentication attempt
 */
static rlm_rcode_t mod_post_auth(void *instance, REQUEST * request) {
	rlm_sql_t *inst = instance;

	if (inst->config->postauth) {
		return acct_redundant(inst, request, inst->config->postauth);
	}

	return RLM_MODULE_NOOP;
}
/*
 *	Postauth: Write a record of the authentication attempt
 */
static rlm_rcode_t CC_HINT(nonnull) mod_post_auth(void *instance, REQUEST * request) {
	rlm_sql_t *inst = instance;

	if (inst->config->postauth.reference_cp) {
		return acct_redundant(inst, request, &inst->config->postauth);
	}

	return RLM_MODULE_NOOP;
}