2 * EAP method registration
3 * Copyright (c) 2004-2009, Jouni Malinen <j@w1.fi>
5 * This software may be distributed under the terms of the BSD license.
6 * See README for more details.
12 #include "eap_peer/eap_methods.h"
13 #include "eap_server/eap_methods.h"
14 #include "wpa_supplicant_i.h"
18 * eap_register_methods - Register statically linked EAP methods
19 * Returns: 0 on success, -1 or -2 on failure
21 * This function is called at program initialization to register all EAP
22 * methods that were linked in statically.
24 int eap_register_methods(void)
30 ret = eap_peer_md5_register();
35 ret = eap_peer_tls_register();
40 ret = eap_peer_mschapv2_register();
41 #endif /* EAP_MSCHAPv2 */
45 ret = eap_peer_peap_register();
50 ret = eap_peer_ttls_register();
55 ret = eap_peer_gtc_register();
60 ret = eap_peer_otp_register();
65 ret = eap_peer_sim_register();
70 ret = eap_peer_leap_register();
75 ret = eap_peer_psk_register();
80 ret = eap_peer_aka_register();
85 ret = eap_peer_aka_prime_register();
86 #endif /* EAP_AKA_PRIME */
90 ret = eap_peer_fast_register();
95 ret = eap_peer_pax_register();
100 ret = eap_peer_sake_register();
101 #endif /* EAP_SAKE */
105 ret = eap_peer_gpsk_register();
106 #endif /* EAP_GPSK */
110 ret = eap_peer_wsc_register();
115 ret = eap_peer_ikev2_register();
116 #endif /* EAP_IKEV2 */
118 #ifdef EAP_VENDOR_TEST
120 ret = eap_peer_vendor_test_register();
121 #endif /* EAP_VENDOR_TEST */
125 ret = eap_peer_tnc_register();
130 ret = eap_peer_pwd_register();
133 #ifdef EAP_SERVER_IDENTITY
135 ret = eap_server_identity_register();
136 #endif /* EAP_SERVER_IDENTITY */
138 #ifdef EAP_SERVER_MD5
140 ret = eap_server_md5_register();
141 #endif /* EAP_SERVER_MD5 */
143 #ifdef EAP_SERVER_TLS
145 ret = eap_server_tls_register();
146 #endif /* EAP_SERVER_TLS */
148 #ifdef EAP_SERVER_MSCHAPV2
150 ret = eap_server_mschapv2_register();
151 #endif /* EAP_SERVER_MSCHAPV2 */
153 #ifdef EAP_SERVER_PEAP
155 ret = eap_server_peap_register();
156 #endif /* EAP_SERVER_PEAP */
158 #ifdef EAP_SERVER_TLV
160 ret = eap_server_tlv_register();
161 #endif /* EAP_SERVER_TLV */
163 #ifdef EAP_SERVER_GTC
165 ret = eap_server_gtc_register();
166 #endif /* EAP_SERVER_GTC */
168 #ifdef EAP_SERVER_TTLS
170 ret = eap_server_ttls_register();
171 #endif /* EAP_SERVER_TTLS */
173 #ifdef EAP_SERVER_SIM
175 ret = eap_server_sim_register();
176 #endif /* EAP_SERVER_SIM */
178 #ifdef EAP_SERVER_AKA
180 ret = eap_server_aka_register();
181 #endif /* EAP_SERVER_AKA */
183 #ifdef EAP_SERVER_AKA_PRIME
185 ret = eap_server_aka_prime_register();
186 #endif /* EAP_SERVER_AKA_PRIME */
188 #ifdef EAP_SERVER_PAX
190 ret = eap_server_pax_register();
191 #endif /* EAP_SERVER_PAX */
193 #ifdef EAP_SERVER_PSK
195 ret = eap_server_psk_register();
196 #endif /* EAP_SERVER_PSK */
198 #ifdef EAP_SERVER_SAKE
200 ret = eap_server_sake_register();
201 #endif /* EAP_SERVER_SAKE */
203 #ifdef EAP_SERVER_GPSK
205 ret = eap_server_gpsk_register();
206 #endif /* EAP_SERVER_GPSK */
208 #ifdef EAP_SERVER_VENDOR_TEST
210 ret = eap_server_vendor_test_register();
211 #endif /* EAP_SERVER_VENDOR_TEST */
213 #ifdef EAP_SERVER_FAST
215 ret = eap_server_fast_register();
216 #endif /* EAP_SERVER_FAST */
218 #ifdef EAP_SERVER_WSC
220 ret = eap_server_wsc_register();
221 #endif /* EAP_SERVER_WSC */
223 #ifdef EAP_SERVER_IKEV2
225 ret = eap_server_ikev2_register();
226 #endif /* EAP_SERVER_IKEV2 */
228 #ifdef EAP_SERVER_TNC
230 ret = eap_server_tnc_register();
231 #endif /* EAP_SERVER_TNC */
233 #ifdef EAP_SERVER_PWD
235 ret = eap_server_pwd_register();
236 #endif /* EAP_SERVER_PWD */