All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Macros | Typedefs | Functions | Variables
rlm_radutmp.c File Reference

Tracks sessions. More...

#include <freeradius-devel/radiusd.h>
#include <freeradius-devel/radutmp.h>
#include <freeradius-devel/modules.h>
#include <freeradius-devel/rad_assert.h>
#include <fcntl.h>
#include "config.h"
+ Include dependency graph for rlm_radutmp.c:

Go to the source code of this file.

Data Structures

struct  nas_port
struct  rlm_radutmp_t


#define LOCK_LEN   sizeof(struct radutmp)


typedef struct nas_port NAS_PORT
typedef struct rlm_radutmp_t rlm_radutmp_t


static rlm_rcode_t CC_HINT (nonnull)
static NAS_PORTnas_port_find (NAS_PORT *nas_port_list, uint32_t nasaddr, uint16_t port)
static rlm_rcode_t radutmp_zap (REQUEST *request, char const *filename, uint32_t nasaddr, time_t t)


static const CONF_PARSER module_config []
static char const porttypes [] = "ASITX"
module_t rlm_radutmp

Detailed Description

Tracks sessions.


Definition in file rlm_radutmp.c.

Data Structure Documentation

struct nas_port

Definition at line 43 of file rlm_radutmp.c.

+ Collaboration diagram for nas_port:
Data Fields
uint32_t nasaddr
struct nas_port * next
off_t offset
uint16_t port
struct rlm_radutmp_t

Definition at line 50 of file rlm_radutmp.c.

+ Collaboration diagram for rlm_radutmp_t:
Data Fields
bool caller_id_ok
bool case_sensitive
bool check_nas
char const * filename
NAS_PORT * nas_port_list
uint32_t permission
char const * username

Macro Definition Documentation

#define LOCK_LEN   sizeof(struct radutmp)

Definition at line 35 of file rlm_radutmp.c.

Typedef Documentation

typedef struct nas_port NAS_PORT
typedef struct rlm_radutmp_t rlm_radutmp_t

Function Documentation

static rlm_rcode_t CC_HINT ( nonnull  )

Definition at line 146 of file rlm_radutmp.c.

+ Here is the call graph for this function:

static NAS_PORT* nas_port_find ( NAS_PORT nas_port_list,
uint32_t  nasaddr,
uint16_t  port 

Definition at line 129 of file rlm_radutmp.c.

+ Here is the caller graph for this function:

static rlm_rcode_t radutmp_zap ( REQUEST request,
char const *  filename,
uint32_t  nasaddr,
time_t  t 

Definition at line 75 of file rlm_radutmp.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

Variable Documentation

const CONF_PARSER module_config[]
Initial value:
= {
{ FR_CONF_OFFSET("username", PW_TYPE_STRING | PW_TYPE_REQUIRED | PW_TYPE_XLAT, rlm_radutmp_t, username), .dflt = "%{User-Name}" },
{ FR_CONF_OFFSET("case_sensitive", PW_TYPE_BOOLEAN, rlm_radutmp_t, case_sensitive), .dflt = "yes" },
{ FR_CONF_OFFSET("check_with_nas", PW_TYPE_BOOLEAN, rlm_radutmp_t, check_nas), .dflt = "yes" },
{ FR_CONF_OFFSET("permissions", PW_TYPE_INTEGER, rlm_radutmp_t, permission), .dflt = "0644" },
{ FR_CONF_OFFSET("caller_id", PW_TYPE_BOOLEAN, rlm_radutmp_t, caller_id_ok), .dflt = "no" },
#define RADUTMP
Definition: conf.h:12
Definition: conffile.h:289
#define PW_TYPE_XLAT
string will be dynamically expanded.
Definition: conffile.h:207
A truth value.
Definition: radius.h:56
32 Bit unsigned integer.
Definition: radius.h:34
File matching value must exist, and must be writeable.
Definition: conffile.h:205
#define FR_CONF_OFFSET(_n, _t, _s, _f)
Definition: conffile.h:168
Error out if no matching CONF_PAIR is found, and no dflt value is set.
Definition: conffile.h:200
String of printable characters.
Definition: radius.h:33

Definition at line 60 of file rlm_radutmp.c.

char const porttypes[] = "ASITX"

Definition at line 37 of file rlm_radutmp.c.

module_t rlm_radutmp
Initial value:
= {
.name = "radutmp",
.inst_size = sizeof(rlm_radutmp_t),
.config = module_config,
.methods = {
static rlm_rcode_t mod_accounting(void *instance, REQUEST *request)
Write accounting data to Couchbase documents.
Module is not threadsafe.
Definition: modules.h:76
Definition: modules.h:86
Will be restarted on HUP.
Definition: modules.h:79
4 methods index for checksimul section.
Definition: modules.h:45
3 methods index for accounting section.
Definition: modules.h:44
static rlm_rcode_t mod_checksimul(void *instance, REQUEST *request)
Check if a given user is already logged in.
struct rlm_radutmp_t rlm_radutmp_t
static const CONF_PARSER module_config[]
Definition: rlm_radutmp.c:60

Definition at line 741 of file rlm_radutmp.c.