2 * wpa_supplicant / WPS integration
3 * Copyright (c) 2008-2009, 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
12 * See README and COPYING for more details.
15 #ifndef WPS_SUPPLICANT_H
16 #define WPS_SUPPLICANT_H
21 #include "wps/wps_defs.h"
23 struct wps_new_ap_settings {
30 int wpas_wps_init(struct wpa_supplicant *wpa_s);
31 void wpas_wps_deinit(struct wpa_supplicant *wpa_s);
32 int wpas_wps_eapol_cb(struct wpa_supplicant *wpa_s);
33 enum wps_request_type wpas_wps_get_req_type(struct wpa_ssid *ssid);
34 int wpas_wps_start_pbc(struct wpa_supplicant *wpa_s, const u8 *bssid);
35 int wpas_wps_start_pin(struct wpa_supplicant *wpa_s, const u8 *bssid,
37 int wpas_wps_start_oob(struct wpa_supplicant *wpa_s, char *device_type,
38 char *path, char *method, char *name);
39 int wpas_wps_start_reg(struct wpa_supplicant *wpa_s, const u8 *bssid,
40 const char *pin, struct wps_new_ap_settings *settings);
41 int wpas_wps_ssid_bss_match(struct wpa_supplicant *wpa_s,
42 struct wpa_ssid *ssid, struct wpa_scan_res *bss);
43 int wpas_wps_ssid_wildcard_ok(struct wpa_supplicant *wpa_s,
44 struct wpa_ssid *ssid, struct wpa_scan_res *bss);
45 int wpas_wps_scan_pbc_overlap(struct wpa_supplicant *wpa_s,
46 struct wpa_scan_res *selected,
47 struct wpa_ssid *ssid);
48 void wpas_wps_notify_scan_results(struct wpa_supplicant *wpa_s);
49 int wpas_wps_searching(struct wpa_supplicant *wpa_s);
51 #else /* CONFIG_WPS */
53 static inline int wpas_wps_init(struct wpa_supplicant *wpa_s)
58 static inline void wpas_wps_deinit(struct wpa_supplicant *wpa_s)
62 static inline int wpas_wps_eapol_cb(struct wpa_supplicant *wpa_s)
67 static inline u8 wpas_wps_get_req_type(struct wpa_ssid *ssid)
72 static inline int wpas_wps_ssid_bss_match(struct wpa_supplicant *wpa_s,
73 struct wpa_ssid *ssid,
74 struct wpa_scan_res *bss)
79 static inline int wpas_wps_ssid_wildcard_ok(struct wpa_supplicant *wpa_s,
80 struct wpa_ssid *ssid,
81 struct wpa_scan_res *bss)
86 static inline int wpas_wps_scan_pbc_overlap(struct wpa_supplicant *wpa_s,
87 struct wpa_scan_res *selected,
88 struct wpa_ssid *ssid)
93 static inline void wpas_wps_notify_scan_results(struct wpa_supplicant *wpa_s)
97 static inline int wpas_wps_searching(struct wpa_supplicant *wpa_s)
102 #endif /* CONFIG_WPS */
104 #endif /* WPS_SUPPLICANT_H */