The FreeRADIUS server  $Id: 15bac2a4c627c01d1aa2047687b3418955ac7f00 $
mod_action.h
Go to the documentation of this file.
1 #pragma once
2 /*
3  * This program is free software; you can redistribute it and/or modify
4  * it under the terms of the GNU General Public License as published by
5  * the Free Software Foundation; either version 2, or (at your option)
6  * any later version.
7  *
8  * This program is distributed in the hope that it will be useful,
9  * but WITHOUT ANY WARRANTY; without even the implied warranty of
10  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11  * GNU General Public License for more details.
12  *
13  * You should have received a copy of the GNU General Public License
14  * along with this program; if not, write to the Free Software Foundation,
15  * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
16  */
17 
18 /**
19  * $Id: ac78e6c39cd230790bbb722b8b7505a81512c67c $
20  *
21  * @file unlang/mod_action.h
22  * @brief Unlang module actions
23  *
24  * @copyright 2024 The FreeRADIUS server project
25  */
26 
27 #ifdef __cplusplus
28 extern "C" {
29 #endif
30 
31 #include <freeradius-devel/server/rcode.h>
32 #include <freeradius-devel/util/retry.h>
33 
34 /* Actions may be a positive integer (the highest one returned in the group
35  * will be returned), or the keyword "return", represented here by
36  * MOD_ACTION_RETURN, to cause an immediate return.
37  * There's also the keyword "reject", represented here by MOD_ACTION_REJECT
38  * to cause an immediate reject. */
39 typedef enum {
43 
49 
50  /*
51  * If ubsan or the compiler complains
52  * about the missing enum values we'll
53  * need to add them here.
54  *
55  * Defining MOD_PRIORITY_MAX ensures the
56  * enum will always be large enough.
57  */
58  MOD_PRIORITY_MAX = 64
60 
61 typedef struct {
65 
71 
72 #ifdef __cplusplus
73 }
74 #endif
unlang_mod_actions_t const mod_actions_preacct
Definition: mod_action.c:59
unlang_mod_action_t
Definition: mod_action.h:39
@ MOD_PRIORITY_1
Definition: mod_action.h:45
@ MOD_ACTION_RETURN
Definition: mod_action.h:40
@ MOD_PRIORITY_2
Definition: mod_action.h:46
@ MOD_PRIORITY_3
Definition: mod_action.h:47
@ MOD_ACTION_REJECT
Definition: mod_action.h:41
@ MOD_PRIORITY_MAX
Definition: mod_action.h:58
@ MOD_ACTION_RETRY
Definition: mod_action.h:42
@ MOD_PRIORITY_4
Definition: mod_action.h:48
@ MOD_PRIORITY_MIN
Definition: mod_action.h:44
unlang_mod_actions_t const mod_actions_authenticate
Definition: mod_action.c:29
unlang_mod_actions_t const mod_actions_accounting
Definition: mod_action.c:74
fr_retry_config_t retry
Definition: mod_action.h:63
unlang_mod_actions_t const mod_actions_authorize
Definition: mod_action.c:44
unlang_mod_actions_t const mod_actions_postauth
Definition: mod_action.c:88
@ RLM_MODULE_NUMCODES
How many valid return codes there are.
Definition: rcode.h:50