Example #1
0
static int mod_load(void)
{
	if (fr_sim_init() < 0) return -1;

	sim_xlat_register();

	return 0;
}
Example #2
0
static int mod_load(void)
{
	if (virtual_server_namespace_register("eap-aka", mod_namespace_load) < 0) return -1;

	if (fr_sim_init() < 0) return -1;

	sim_xlat_register();

	return 0;
}
Example #3
0
static fr_sim_decode_ctx_t *test_ctx_init(TALLOC_CTX *ctx, uint8_t const *k_encr, size_t k_encr_len)
{
	fr_sim_decode_ctx_t	*test_ctx;
	fr_sim_keys_t		*keys;

	if (fr_sim_init() < 0) return NULL;

	test_ctx = talloc_zero(ctx, fr_sim_decode_ctx_t);
	test_ctx->keys = keys = talloc_zero(test_ctx, fr_sim_keys_t);
	memcpy(keys->k_encr, k_encr, k_encr_len);
	talloc_set_destructor(test_ctx, _test_ctx_free);

	return test_ctx;
}