All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
process.h
Go to the documentation of this file.
1 /*
2  * This program is free software; you can redistribute it and/or modify
3  * it under the terms of the GNU General Public License as published by
4  * the Free Software Foundation; either version 2 of the License, or
5  * (at your option) any later version.
6  *
7  * This program is distributed in the hope that it will be useful,
8  * but WITHOUT ANY WARRANTY; without even the implied warranty of
9  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
10  * GNU General Public License for more details.
11  *
12  * You should have received a copy of the GNU General Public License
13  * along with this program; if not, write to the Free Software
14  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
15  */
16 #ifndef _FR_PROCESS_H
17 #define _FR_PROCESS_H
18 /**
19  * $Id: 27c6144df7c497e88574896d51975d3a3cf66e97 $
20  *
21  * @file include/process.h
22  * @brief State machine for a server to process packets.
23  *
24  * @author Arran Cudbard-Bell <a.cudbardb@freeradius.org>
25  * @copyright 2012 The FreeRADIUS server project
26  * @copyright 2012 Alan DeKok <aland@deployingradius.com
27  */
28 RCSIDH(process_h, "$Id: 27c6144df7c497e88574896d51975d3a3cf66e97 $")
29 
30 #include <freeradius-devel/clients.h>
31 #include <freeradius-devel/listen.h>
32 
33 #ifdef __cplusplus
34 extern "C" {
35 #endif
36 
37 typedef enum fr_state_action_t { /* server action */
43 #ifdef WITH_PROXY
45 #endif
47 
48 /*
49  * Function handler for requests.
50  */
51 typedef int (*RAD_REQUEST_FUNP)(REQUEST *);
52 typedef void (*fr_request_process_t)(REQUEST *, int);
53 
54 extern time_t fr_start_time;
55 
56 #ifdef HAVE_PTHREAD_H
57 /*
58  * In threads.c
59  */
60 int request_enqueue(REQUEST *request);
61 #endif
62 
63 int request_receive(TALLOC_CTX *ctx, rad_listen_t *listener, RADIUS_PACKET *packet,
64  RADCLIENT *client, RAD_REQUEST_FUNP fun);
65 
66 #ifdef WITH_PROXY
68 #endif
69 
70 #ifdef __cplusplus
71 }
72 #endif
73 #endif /* _FR_PROCESS_H */
fr_state_action_t
Definition: process.h:37
#define RCSIDH(h, id)
Definition: build.h:136
int(* RAD_REQUEST_FUNP)(REQUEST *)
Definition: process.h:51
int request_receive(TALLOC_CTX *ctx, rad_listen_t *listener, RADIUS_PACKET *packet, RADCLIENT *client, RAD_REQUEST_FUNP fun)
Definition: process.c:1523
void(* fr_request_process_t)(REQUEST *, int)
Definition: process.h:52
Describes a host allowed to send packets to the server.
Definition: clients.h:35
int request_proxy_reply(RADIUS_PACKET *packet)
Definition: process.c:2418
time_t fr_start_time
Definition: process.c:52