25 RCSID(
"$Id: 9893ce9add36d566546e1c0b1be509e02366167a $")
27 #include <freeradius-devel/radiusd.h>
28 #include <freeradius-devel/modules.h>
29 #include <freeradius-devel/rad_assert.h>
61 RINFO(
"Example-Paircmp called with \"%s\"", check->vp_strvalue);
63 if (strcmp(check->vp_strvalue,
"yes") == 0)
return 0;
106 RDEBUG(
"Found reply to access challenge");
122 RDEBUG(
"Sending Access-Challenge");
135 #ifdef WITH_ACCOUNTING
164 request->simul_count=0;
196 .config = module_config,
202 #ifdef WITH_ACCOUNTING
RFC2865 - Access-Challenge.
static rlm_rcode_t mod_accounting(void *instance, REQUEST *request)
Write accounting data to Couchbase documents.
The module is OK, continue.
Metadata exported by the module.
struct rlm_example_t rlm_example_t
static const CONF_PARSER module_config[]
static rlm_rcode_t mod_authorize(void *instance, REQUEST *request)
Handle authorization requests using Couchbase document data.
#define RLM_TYPE_THREAD_SAFE
Module is threadsafe.
#define CONF_PARSER_TERMINATOR
static rlm_rcode_t CC_HINT(nonnull)
static rlm_rcode_t mod_authenticate(void *instance, REQUEST *request) CC_HINT(nonnull)
Defines a CONF_PAIR to C data type mapping.
4 methods index for checksimul section.
3 methods index for accounting section.
Stores an attribute, a value and various bits of other data.
static rlm_rcode_t mod_checksimul(void *instance, REQUEST *request)
Check if a given user is already logged in.
static int mod_detach(UNUSED void *instance)
void void cf_log_err_cs(CONF_SECTION const *cs, char const *fmt,...) CC_HINT(format(printf
0 methods index for authenticate section.
enum rlm_rcodes rlm_rcode_t
Return codes indicating the result of the module call.
uint64_t magic
Used to validate module struct.
static int mod_instantiate(CONF_SECTION *conf, void *instance)
#define FR_CONF_OFFSET(_n, _t, _s, _f)
int paircompare_register_byname(char const *name, fr_dict_attr_t const *from, bool first_only, RAD_COMPARE_FUNC func, void *instance)
Register a function as compare function.
#define pair_make_reply(_a, _b, _c)
static int rlm_example_cmp(UNUSED void *instance, REQUEST *request, UNUSED VALUE_PAIR *thing, VALUE_PAIR *check, UNUSED VALUE_PAIR *check_pairs, UNUSED VALUE_PAIR **reply_pairs)
2 methods index for preacct section.
VALUE_PAIR * fr_pair_find_by_num(VALUE_PAIR *head, unsigned int vendor, unsigned int attr, int8_t tag)
Find the pair with the matching attribute.
fr_dict_attr_t const * da
Dictionary attribute defines the attribute.
fr_dict_attr_t const * fr_dict_attr_by_num(fr_dict_t *dict, unsigned int vendor, unsigned int attr)
Lookup a fr_dict_attr_t by its vendor and attribute numbers.
String of printable characters.
1 methods index for authorize section.
The module handled the request, so stop.