Expand PMF_FN_* macros.
[netbsd-mini2440.git] / dist / wpa / src / radius / radius_server.h
blob1012a1453b1fb2687cbdc537a855d1c2b992a2d4
1 /*
2 * hostapd / RADIUS authentication server
3 * Copyright (c) 2005-2007, Jouni Malinen <j@w1.fi>
5 * This program is free software; you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 2 as
7 * published by the Free Software Foundation.
9 * Alternatively, this software may be distributed under the terms of BSD
10 * license.
12 * See README and COPYING for more details.
15 #ifndef RADIUS_SERVER_H
16 #define RADIUS_SERVER_H
18 struct radius_server_data;
19 struct eap_user;
21 struct radius_server_conf {
22 int auth_port;
23 char *client_file;
24 void *conf_ctx;
25 void *eap_sim_db_priv;
26 void *ssl_ctx;
27 u8 *pac_opaque_encr_key;
28 char *eap_fast_a_id;
29 int eap_sim_aka_result_ind;
30 int tnc;
31 int ipv6;
32 int (*get_eap_user)(void *ctx, const u8 *identity, size_t identity_len,
33 int phase2, struct eap_user *user);
37 #ifdef RADIUS_SERVER
39 struct radius_server_data *
40 radius_server_init(struct radius_server_conf *conf);
42 void radius_server_deinit(struct radius_server_data *data);
44 int radius_server_get_mib(struct radius_server_data *data, char *buf,
45 size_t buflen);
47 void radius_server_eap_pending_cb(struct radius_server_data *data, void *ctx);
49 #else /* RADIUS_SERVER */
51 static inline struct radius_server_data *
52 radius_server_init(struct radius_server_conf *conf)
54 return NULL;
57 static inline void radius_server_deinit(struct radius_server_data *data)
61 static inline int radius_server_get_mib(struct radius_server_data *data,
62 char *buf, size_t buflen)
64 return 0;
67 static inline void
68 radius_server_eap_pending_cb(struct radius_server_data *data, void *ctx)
72 #endif /* RADIUS_SERVER */
74 #endif /* RADIUS_SERVER_H */